serout and rf modules
Hi,
I have a BS2P40 and have come across a pair of rf modules.
Documentation is unfortunately thin however here is where I'm at.
connections as follows:
1 power supply Gnd
2 3.3 to 5v power
3 Rxd/TTL level
4 Txd/TTL level
5 digital ground
6 Tx/RS-232
7 Rx/RS-232
8 sleep TTL high level sleep
9 reset
There is a windows app to go online to the module and change channel etc. I can do this by providing power and using pins 6 and 7 above to serial port on the computer.
Also from here I can enter some data and manually Tx and there is a red led on the unit that indicates data tx'ing I assume.
On the 2P40 I just want to transmit and on another Rx
So have used power and tried both pin 4 or 6 of module connected to X15 (pin20) on the 2P40
yet i have never seen the Tx led light up yet.
' {$STAMP BS2p}
' {$PBASIC 2.5}
Radio_Tx CON 15 'Radio on pin 16
Radio_Baud CON 110 'Radio baud 9600 8-N-1 copied from serial LCD program
Main program which call subroutine Radio_update
Radio_update:
SEROUT Radio_Tx, Radio_Baud, [noparse][[/noparse] x ]
PAUSE 100
RETURN
I have tried lots of different things between the brackets.
I am unsure of the CON 110 data except to say it works on the Serial LCD module. I am not sure where the chart is for deciphering this.
Also unsure whether I should be on pin 4 or 6 and whether any hardware is required inbetween (MAX232??) or infact whether any form of initialisation string is required.
Any thoughts appreciated cause this newbie is confused.
Cheers
Richard
I have a BS2P40 and have come across a pair of rf modules.
Documentation is unfortunately thin however here is where I'm at.
connections as follows:
1 power supply Gnd
2 3.3 to 5v power
3 Rxd/TTL level
4 Txd/TTL level
5 digital ground
6 Tx/RS-232
7 Rx/RS-232
8 sleep TTL high level sleep
9 reset
There is a windows app to go online to the module and change channel etc. I can do this by providing power and using pins 6 and 7 above to serial port on the computer.
Also from here I can enter some data and manually Tx and there is a red led on the unit that indicates data tx'ing I assume.
On the 2P40 I just want to transmit and on another Rx
So have used power and tried both pin 4 or 6 of module connected to X15 (pin20) on the 2P40
yet i have never seen the Tx led light up yet.
' {$STAMP BS2p}
' {$PBASIC 2.5}
Radio_Tx CON 15 'Radio on pin 16
Radio_Baud CON 110 'Radio baud 9600 8-N-1 copied from serial LCD program
Main program which call subroutine Radio_update
Radio_update:
SEROUT Radio_Tx, Radio_Baud, [noparse][[/noparse] x ]
PAUSE 100
RETURN
I have tried lots of different things between the brackets.
I am unsure of the CON 110 data except to say it works on the Serial LCD module. I am not sure where the chart is for deciphering this.
Also unsure whether I should be on pin 4 or 6 and whether any hardware is required inbetween (MAX232??) or infact whether any form of initialisation string is required.
Any thoughts appreciated cause this newbie is confused.
Cheers
Richard
Comments
I think the baud constant should be 240 for 9600 on the BS2p (Radio_Baud CON 240) you can double check by looking at the help file that comes with the IDE.
It also looks like Pin 3 of the rf module (RXD/TTL)·is where Pin 15 of the Stamp should be connected for the module to receive data.
Jeff T.
EDIT that should have been P15 (Pin 20)
Post Edited (Unsoundcode) : 11/11/2007 3:32:03 PM GMT
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen
The digital ground I had not connected as I wasn't useing sleep or reset function, do I infact need to connect this to the same point as pin1 0volts ??
I appreciate the help.
Rich