Serial Modem Communication
Trevor
Posts: 8
I am currently working on a project that involves a family of autonomous vehicles. Our unmanned ground vehicle is currently using the propeller in conjunction with several other sensors including GPS, digital compass, ultrasonic, video, thermal and other components including MaxStream 9xStream serial radio modems.
The MaxStream RF modems interface via a DB-9 serial connection, so I therefore attempted to build a serial communication interface to allow the modem to communicate with the propeller. I built my interface off of a Maxim MAX3232 serial transciever in the same fashion as the PropStick serial interface, however as I need the circuit for communication rather than programming omitted the transistor circuit off of R1OUT in the attached schematic. I also am using general purpose pins rather than pins A31 & A30 as in the schematic.
However, after some experimentation I have so far been unable to transmit serial ASCII data over my RF modem and am unsure as to if my interface circuit is actually performing correctly. My code test code is very simple, yet I am rather new to Spin so it too of course could be to blame.
CON
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000
OBJ
TestSerial : "FullDuplexSerial"
Pub TestS
testserial.start(-1, 0, 2, 9600)
testserial.str(string("Testing 1,2,3"))
I am unsure if anyone else out there has tried something similar to transmitting serial data from the propeller to an RF modem and could give me any hints or suggestions.
The MaxStream RF modems interface via a DB-9 serial connection, so I therefore attempted to build a serial communication interface to allow the modem to communicate with the propeller. I built my interface off of a Maxim MAX3232 serial transciever in the same fashion as the PropStick serial interface, however as I need the circuit for communication rather than programming omitted the transistor circuit off of R1OUT in the attached schematic. I also am using general purpose pins rather than pins A31 & A30 as in the schematic.
However, after some experimentation I have so far been unable to transmit serial ASCII data over my RF modem and am unsure as to if my interface circuit is actually performing correctly. My code test code is very simple, yet I am rather new to Spin so it too of course could be to blame.
CON
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000
OBJ
TestSerial : "FullDuplexSerial"
Pub TestS
testserial.start(-1, 0, 2, 9600)
testserial.str(string("Testing 1,2,3"))
I am unsure if anyone else out there has tried something similar to transmitting serial data from the propeller to an RF modem and could give me any hints or suggestions.
Comments
testserial.start(1,0,0,9600)
There are many including myself who have been using the XBee's.
The Extended_FDSerial object was partially written with them in mind, and I'll be releasing a more dedicated one for the XBee's sometime soon (this qtr?).
Also, see my Prop ProtoBoard to Xbee images.
http://www.selmaware.com/appbee
Why do you have -1 for a pin number?? Makes no sense.
-Martin
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
StampPlot - GUI and Plotting, and XBee Wireless Adapters
Southern Illinois University Carbondale, Electronic Systems Technologies
-MH
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
StampPlot - GUI and Plotting, and XBee Wireless Adapters
Southern Illinois University Carbondale, Electronic Systems Technologies
I am using an 9xStream 900Mhz OEM module with a MaxStream RS232/485 Interface board. I'm a student and I'm not sure exactly who told me that a serial transciever circuit is required however I will certainly try your method and get back to you.
Thanks!
Disregard my advice.
That -1 is still messed up though.... And you probably want 0 for mode.
-Martin
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
StampPlot - GUI and Plotting, and XBee Wireless Adapters
Southern Illinois University Carbondale, Electronic Systems Technologies
I left my lab and my breadboard behind so I dont remember my exact wiring, but bypassing the circuit and connecting straight to the DB9 I was able to send serial ASCII from the Propeller through the 9xStream to another 9xStream and recieve the text on a WinXP desktop.
Broadcasting ASCII back the opposite direction through the propeller and then to a LCD was a little trickier but I did manage to get it working a once or twice before I left.
In either case, thanks for the advice, I would have still been fooling around with that MAX3232 if you hadn't said anything.
-Martin
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
StampPlot - GUI and Plotting, and XBee Wireless Adapters
Southern Illinois University Carbondale, Electronic Systems Technologies