Forum >Bluetooth V3 - BlueSoleil incompatible with Intel Centrino Advanced-N 6230
General

Bluetooth V3 - BlueSoleil incompatible with Intel Centrino Advanced-N 6230

userHead drewmon79 2012-01-22 10:47:25 11455 Views7 Replies
I have the DFRduino Romeo V1.0 and the RB-DFR-10 bluetoothV3 adaptor. My laptop has an Intel Centrino Advanced-N 6230 WI-FI adapter with bluetooth. I couldn't get the bluetooth to pair with the Centrino, so I decided to download the BlueSoleil software as directed in the WIKI only to find out that BlueSoleil is incompatible with the Centrino bluetooth adapter. Do I have to use BlueSoleil? Has anyone encountered this problem or know a solution.
2012-01-26 22:05:30 Hi,


Its not possible to upload code through bluetooth. The Arduino requires a reset just before code is uploaded. The bluetooth module is not capable of doing this. Also you must upload code at the particular speed of the microcontroller you are programming. Duemillanove, UNO, MEGA, ROMEO all have different baudrate requirements. If you want to do wireless uploading I recommend our WPM modules.


They are the only commercially available modules which will allow you to upload code wirelessly.
userHeadPic Hector
2012-01-26 16:54:57 Okay, in my devices under Generic Bluetooth Adapter I
disabled:
Bluetooth Device (Personal Area Network)
Microsoft Bluetooth Enumerator

I left the following enabled:
Generic Bluetooth Adapter
Bluetooth Device (RFCOMM Protocol TDI)

and now I have two-way serial bluetooth communications using Putty. Arduino IDE still doesn't recognize COM6 when bluetooth is paired.

The only other thing I'd really like to get working for now is code upload.

My Win7 has a command called Bluetooth File Transfer that sends and receives files. This works for my Android phone, but does not work for this Bluetooth module.

When I click send I just get "Bluetooth Transfer not completed" which is not helpful. Is there a way to transfer files with Putty? or any ideas on what could make this work?
userHeadPic drewmon79
2012-01-25 20:08:12 Hi,


Yes, you should be using the same baud rate for all communications. Otherwise you will have a speed mismatch which will cause either erroneous readings or just trash to show up on your monitor. Please set all baud rates to 9600.


That means:
1. bluetooth, already set.
2. Serial monitor. (Arduino IDE, or Putty)
3. Arduino sketch.




alternatively, you could change the bluetooth's baudrate to a higher speed. But this is a bit complicated, and I would wait until you have everything working to start experimenting with this.


I noticed that the code you posted is already using 9600...


userHeadPic Hector
2012-01-25 19:14:37 I noticed that the bluetooth requires a 9600 baud rate, but the version of this code posted on the Romeo wiki uses a 19200 baud rate for USB serial communication. Does this change in my code to accomodate bluetooth matter? userHeadPic drewmon79
2012-01-25 19:03:05 I tried the serial.print("Hello World") test with the Arduino IDE  and had no success with the serial monitor. Win7 detects the bluetooth device on COM6 and I set the serial port to COM 6 when it's not gray. I retried several times with no success.

I downloaded a free version of Hyperterminal, but could not connect. Then I downloaded PuTTY and that worked, I got the Hello World transmissions.

So next I tried a simple program to transmit commands from the pc keyboard to the Romeo. However, this didn't work. The Romeo reacts to the commands but not in the correct way. This code doesn't send anything to digital pin 9 or 10 but some servos that are connected move when I type "w". According to the code, the dc motors connected t pins 4-7 are supposed to move. (This hardware has been tested and works without bluetooth) When I right click the mouse the motors toggle forward/backward a few times.

Here's the code that I'm using:

//Standard PWM DC control

int E1 = 5;    //M1 Speed Control
int E2 = 6;    //M2 Speed Control
int M1 = 4;    //M1 Direction Control
int M2 = 7;    //M1 Direction Control



void stop(void)                    //Stop
        {
          digitalWrite(E1,LOW); 
          digitalWrite(E2,LOW);     
        } 
void advance(char a,char b)          //Move forward
        {
          analogWrite (E1,a);      //PWM Speed Control
          digitalWrite(M1,HIGH);   
          analogWrite (E2,b);   
          digitalWrite(M2,HIGH);
        } 
void back_off (char a,char b)          //Move backward
        {
          analogWrite (E1,a);
          digitalWrite(M1,LOW); 
          analogWrite (E2,b);   
          digitalWrite(M2,LOW);
}
void turn_L (char a,char b)            //Turn Left
        {
          analogWrite (E1,a);
          digitalWrite(M1,LOW);   
          analogWrite (E2,b);   
          digitalWrite(M2,HIGH);
        }
void turn_R (char a,char b)            //Turn Right
        {
          analogWrite (E1,a);
          digitalWrite(M1,HIGH);   
          analogWrite (E2,b);   
          digitalWrite(M2,LOW);
        }
void setup(void)
{
    int i;
    for(i=4;i<=7;i++)
    pinMode(i, OUTPUT); 
    Serial.begin(9600);      //Set Baud Rate
}
void loop(void)
{
    char val = Serial.read();
    if(val!=-1)
      {
          switch(val)
          {
            case 'w'://Move Forward
                    advance (100,100);  //PWM Speed Control
                    break;
            case 's'://Move Backward
                    back_off (100,100);
                    break;
            case 'a'://Turn Left
                    turn_L (100,100);
                    break;     
            case 'd'://Turn Right
                    turn_R (100,100);
                    break;         
            }   
          delay(40);
      }
      else stop(); 
}

Any ideas on what could be wrong with the bluetooth transmitted key commands?
userHeadPic drewmon79
2012-01-25 03:31:44 Hi,


With win7 you don't need to use BlueSoleil. You can just use the windows software directly. By the description in your second post it seems that windows is picking up the bluetooth just fine. Does it ask you for the pin? (1234)


Once you are connected to it you should be able to connect to the Romeo through a serial monitor. You can use something like Putty, or the Arduino IDE integrated serial terminal. I would suggest you upload a simple script to the romeo which repeatedly prints "hello world" or something like that. Once you are connected, open the serial monitor to COM6 and you should see the message start to print on your monitor.
userHeadPic Hector
2012-01-22 12:53:34 The hardware detected by my laptop is called "Bluetooth_V3"
The Hardware device function name is "Standard Serial over Bluetooth link (COM 6)".
The type is "Ports (COM & LPT)"
The location is "on Bluetooth Device (RFCOMM Protocol TDI)
It uses "Serial port (SPP) 'Dev B' ... COM6" bluetooth services
The connection has been authenticated and it states that the device is working properly.
The Port Settings are: 9600 bps; 8 data bits; parity: none; stop bits 1; flow control: none
The drier provider is Microsoft, version 6.1.7600.16385 dated 6/21/2006

I'm running Windows 7 (64 bit).

If there's any other information that would be useful, let me know.
userHeadPic drewmon79