Go Down

Topic: How to get Bluetooth module working with Arduino UNO? (Read 2 times) previous topic - next topic

jeffmorris

How can I get Bluetooth module working with Arduino UNO?

https://www.sparkfun.com/products/10269

dxw00d

Connect it to a pair of serial pins. Hardware serial or SoftwareSerial should both work.

jeffmorris

How can I use hardware serial instead of software serial?

dxw00d


jeffmorris

There appear to be a conflict between the Bluetooth module and Software Serial. The Arduino UNO uses COM3 and the Bluetooth module uses COM5. Any suggestions?

WinstonP

OK, why is the bluetooth working on COM5? Is that your PC's bluetooth? If so, then ignore it for now. You only want the COM3 port talking to the UNO for starters and sketching.
Check these threads for samples: http://arduino.cc/forum/index.php/topic,120113.30.html and http://arduino.cc/forum/index.php/topic,105045.0.html We've been working on a few things with the bluetooth. Keep in mind that what we are working with is the Seeeduino Bluetooth Shield so your code for the void setupBlueToothConnection() is going to be different. You should be able to use any pins on the UNO (except pins D0 and D1 as these are used for the communications between the PC and the UNO). The "Wiring Example" given in the Sparkfun sample is very specific to the board that they were using. Also read this http://www.arduino.cc/playground/Learning/Tutorial01 it's the same as the Sparkfun info but has more details.
Remember, you have to setup the bluetooth module first and then get it to pair with the other bluetooth device before they'll start talking back and forth. The setup is usually easy but the pairing has been a bitch for some of us.
Make sure you read and read again the info given for you particular bluetooth module that you're connecting to the UNO.
This: http://www.sparkfun.com/datasheets/RF/BlueSMiRF_v1.pdf and this: http://www.sparkfun.com/datasheets/Wireless/Bluetooth/rn-bluetooth-um.pdf for some of the commands needed to setup the BT module. It's gonna be kind of hard to visualize all of the communications that are going to be taking place to get things working. Communication between the PC and UNO; the UNO and the BT module; and the BT module and what ever other Bluetooth device (whether the PC's BT or a smartphone/tablet)(I'd recommend a smartphone/tablet so there won't be any conflicts on the PC).

Good Luck... and remember, We're all counting on you.

jeffmorris

How can I do a loop-back test between Arduino UNO with Bluetooth module and a PC running a terminal program? For example, I type "A" and I should get "A". Which terminal program should I get? I tried to type $$$ and nothing happened.

WinstonP

Get a program called sscom32E.zip. It basically opens a terminal program using any available COM port you have. And you can open as many instances as you need. Use the Arduino Serial Monitor to watch the Arduino and use sscom32E to watch the bluetooth com port.

jeffmorris

I need step-by-step instructions on getting Bluetooth module to work with Arduino UNO and communicate with a PC. Do I need a RS232 to TTL converter? I found an article in Volume 28 of MAKE magazine on a project that uses Arduino UNO and Bluetooth module to fire a Nerf gun using your mind. http://hex-machina.com/hw/mindbullets

WinstonP

http://hex-machina.com/hw/mindbullets
Looks like you already have the step by step instructions. Have you tried following that website?

jeffmorris

I tried to follow that website but I don't have a Nerf gun and a NeuroSky MindSet. I want to have Arduino with Bluetooth and PC "communicating" with each other using terminal programs much like the Loop-Back Test. How do I find my PC's MAC address?

jeffmorris

I think that I got it working by following the tutorial at http://www.instructables.com/id/how-to-Control-arduino-by-bluetooth-from-PC-pock/ If you're using an Android phone or tablet, avoid ArduinoCommander. It doesn't work. How do I use microController BT?

Go Up