Bluetooth in place of RS-232
preyes
Posts: 7
I'm trying to·integrate a BlueSmirf Bluetooth module with my oem BS2 and use this module in place of the serial cable for communicating with my PC.· The module has CTS-1, PWR, GWD, TX-0, RX-1, and RTS-0 pins.· PWR and GWD are connected to their own power source seperate from the 9V power source of the BS2 and when powered on my computer recognizes the module but cannot communicate with the BS2.··The other pins i'm not sure where they would go.· Has anyone successfully done what I'm trying to do?
Comments
I have not used the Bluetooth module that you are using, but I have used an EB500 bluetooth module a bunch.
When you say that your PC recognizes your device, does it establish a connection? Are you using software on the PC to make the connection? They way I do it with the EB500 is I have the EB500 connect to the PC. This way the connection process is programed in PBASIC and done by the Stamp, no PC software involved.
Once you have a connection, all you should have to do is send serial data to the TX pin of your module, and it should be passed to the PC. You can use a program like Hyperterminal to view the data. Make sure the settings in Hyperterminal are correct, for example 9600 baud, no parity, one stop bit. What settings you actually use depend on what you are sending to the bluetooth module.
If this doesn't help, give u more detail about your project and what you have tried already.
Jonathan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
I have a USB Bluetooth dongle that I connected to my PC and loaded the drivers and all that. I tested this dongle capability using a pocket PC and it works fine.
Now, on a breadboard I have the sparkfun.com Bluetooth Smirf module. I powered this with a 9V battery and once I did this the dongle recognized it as a serial port communcations device.
The problem that I'm having is using this module in place of the serial cable that I use to communicate with my oem basic stamp. I basically don't know where the CTS-1, TX-0, RX-1, and RTS-0 pins on my bluetooth module connect to my oem basic stamp. I hope that makes a little more sense. I'll try to upload some pictures later to show what I'm talking about.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com
Chris brings up a good point. Are you trying to program the Stamp, or simply send data to a PC? Assuming the latter...
Most likely all you need to do is connect the TX pin to a Stamp pin, and the RX line up to anothet Stamp pin. If you are not using flow control, this should be all you need. Check the docs to see if flow control is default , and if so, turn it off if you can. You may want flow control later, but get it working without first. If baud rates and parity mean nothing to you, read the Stampworks or other information available here on Parallax's site and read up on serial comunicatons and the SERIN/SEROUT commands. You will use SEROUT commands on the TX pin to send data to the PC, and use the SERIN command to read data sent from the PC.
Now, I don't know what you are sending the data to, but starting with Hyperterminal is handy. The easiest way to test is to start by trying to send a byte to the PC. Set up a simple loop that sends a byte using the SEROUT command on the TX pin every 1/2 second or so. Make sure you set Hyperterminal settings to the same as you are using in the SEROUT command.
Knowing what you are trying to do would make it easier for folks to help.
Jonathan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info - Home of the Hydrogen Fuel Cell Robot