Question about connecting bluetooth module to Arduino

Hello everyone,

I've bought the following bluetooth module:

Link1

From what i've googled, i found that these chips were used with basebords like here:

Link2

Now, the question is why do i need such a baseboard (with resistors and etc.) if it said that the chip already has txd, rxd, vcc(+3.3v which arduino can supply) and gnd pins?

BW,
Sharapolas

Now, the question is why do i need such a baseboard (with resistors and etc.) if it said that the chip already has txd, rxd, vcc(+3.3v which arduino can supply) and gnd pins?

I got one from the firm shown in your second link. The base board on mine includes a 3.3vdc regulator, but if you use arduino 3.3v power then there is no technical reason for using the 'baseboard'. The 'baseboard' does include a LED that gives the connection status of the link, and I found that very useful in testing and operation. Also the baseboard makes for an easy .1" spaced interface pins and soldering wires directly to the bluetooth model would otherwise be pretty challenging as there is little room between it's pins. Note that I did wire in a two resistor voltage divider to cut down the arduino +5vdc transmit signal pin to allow connection to the module;s receive pin.

I couldn't get the module to work with my windows XP PC using window's default bluetooth driver software. But a user around here posted about finding a Toshiba bluetooth driver stack software download that did work, it created a com40 serial port and it works well at 57600 baud and I've tested to around 60-70ft range with no errors. The Toshiba driver is a 30day OEM trial version with no means for a end user to buy a license, so it has to be uninstalled and then reinstalled every 30 days, but that doesn't take too long to do.

Lefty

So I've connected the Bluetooth module (BM) to Arduino (AR) in the following way:

1. BM Uart Rxd <- AR Tx
2. BM Uart Txd -> AR Rx
3. BM 3.3V input <- AR 3.3V output
4. BM GND -> AR GND

I"ve also set up a voltage divider for the second connection in such way:

AR Tx -> 1k Ohm resistor -> Junction A -> BM Uart Rxd

  • Junction A -> 2.2k Ohm resistor -> BM GND*

So, this should change the Arduino Tx signal from 5V to 5V * 2200/(1000+2200)~=3.44V which should be close to being ideal (3.3V). Maybe it should be below 3.3V? I did not find what voltage BM can handle on TX and RX. Only note is that "working voltage is: 2.7-3 .3 V", but as i understand this is about power source.

I've added it to my laptop bluetooth device list (Running Windows 7) and paired it. Next, I uploaded this code to AR:

void setup() {
  Serial.begin(9600);
}

void loop() {
  Serial.println("Everything is OK");
  delay(500);
}

First, when i connect the BM to my PC, in my device list two com ports appear (com7 and com8). When I view it in the device list it shows that it is using com7. But in the arduino software under the tools menu there is only com8 visible. Why? And if I try to monitor the com8 - it shows me nothing. Where did I go wrong?

Also, the arduino TX lights aren't blinking. Should they blink or should they not?

Thanks for your help in advance!

BW,
Sharapolas

When I view it in the device list it shows that it is using com7. But in the arduino software under the tools menu there is only com8 visible. Why? And if I try to monitor the com8 - it shows me nothing. Where did I go wrong?

I don't know, that is what I got also using windows XP and it's default bluetooth driver software. Only when I down loaded the Toshiba bluetooth driver stack did I then get a functional com40 port that worked with either the arduino IDE serial monitor or a serial terminal program (Brey terminal).

Also, the arduino TX lights aren't blinking. Should they blink or should they not?

No, the send and receive leds are driven by the USB serial convertor chip and are only active when there is a USB connection active. The 328 chip can still send and receive serial data from pins 0 and 1 as when you wire them to the BT modem module.

Lefty

I bought this device too so I joint to this thread :wink:
I have some question about AT commands - in manual they say that all changes must be done when device is unpaired... So what I must do ? Write some code for arduino and simply run this (Serial.write() and setup loop) ?
Can I use voltage regulator for 5V to 3.3V conversion on Tx/Rx ?

@Max89:

Welcome Max89,

sadly I can tell you nothing about the AT commands. At least for now. I see no reason why you can't use the power regulator, but maybe someone knows some..

@retrofly:

I tried the toshiba BT stack driver, but it won't install on my system so i'm searching for a workaround.

Correct me if i'm wrong. Default win software opens two serial ports for the bluetooth device, one IN and one OUT. The only problem why I can't use the Arduino serial monitor is because it can monitor only one serial port. But if i had software which can read two ports simultaneously, this would be no problem. Am I right?

I have a feeling that in Linux serial communication might be easier...Maybe anyone has experience with it?

Ok, next problem - I Connected this module using 4 wires (Tx/Rx and GND and 3.3 V) how to make it visible for Windows...

@Max89 - i was able to find the bluetooth module right after powering it. Just go to your bluetooth devices ->> add a device and there you should find "linvor" or smth like that if your device is similar to mine.

This was all i could do up to now. Now i'm waiting for someone to answer my former question about multiple com ports :slight_smile:

Correct me if i'm wrong. Default win software opens two serial ports for the bluetooth device, one IN and one OUT. The only problem why I can't use the Arduino serial monitor is because it can monitor only one serial port. But if i had software which can read two ports simultaneously, this would be no problem. Am I right?

I tried that too with the default windows bluetooth driver. I opened two instances of my PC terminal program (brey terminal) opened one at one of the comm ports the other to the other comm port, wired a loop back wire between the rec and send pins of the BT modem, but nothing worked, however I suspect the the brey terminal disconnects one instance's comm port when you select the other instance, so maybe not a valid test.

As I said I could get nowhere until I installed the toshiba BT driver stack. With the toshiba it creates a lot of comm ports for various BT applications that it also installs, but the comm40 port it creates seems to work for any application including the Arduino IDE serial monitor.

Lefty

Ok, I'm back with a set of new problems:

I gave up on trying to connect arduino to Windows 7 via bluetooth. Now i'm running ubuntu 11.04 from USB. At the moment i have my arduino connected to bluetooth module. On linux the only thing i've done is pushed the bluetooth icon on system tray and pushed "set up new device". Then i've paired my PC with the Bluetooth module. Next, i've uploaded the following code to arduino:

void setup() {
  Serial.begin(9600);
}

void loop() {
  Serial.println(sensorValue, DEC);
}

Next, i tried running this command on linux terminal

sudo gtk-term

It starts running, but shows the error:

Control signals read: Input/output error

In port configuration i've only changed the bitrate to 9600, everything else is default (Parity = none, Bits= 8, Stopbits=1, flow control=none)

First question is: how to know which port my device is using?
Second question is: how to get it working?