Collection: HowTo config various BT modules
Collection: HowTo config various BT modules
Hi,
in order to relieve myself from storing notes all over the place I start compiling info here.
From my experience the dealers' documentation usually is contradictory and not really helpful. In one case I got one BT module with 3 files stating 2 different hardware specifics and 2 config ways for configuration. Take your pick.
So it seems the only way to identify the proper way to config is by identifying the BT via its name if it is a slave module.
For master modules that does not seem to work as the master modules I know do not advertise a name.
Rules: label each post with the BT module's name.
Hamburger
in order to relieve myself from storing notes all over the place I start compiling info here.
From my experience the dealers' documentation usually is contradictory and not really helpful. In one case I got one BT module with 3 files stating 2 different hardware specifics and 2 config ways for configuration. Take your pick.
So it seems the only way to identify the proper way to config is by identifying the BT via its name if it is a slave module.
For master modules that does not seem to work as the master modules I know do not advertise a name.
Rules: label each post with the BT module's name.
Hamburger
Last edited by Hamburger on Sun Jun 12, 2011 12:12 pm, edited 1 time in total.
linvar slave module
comes preconfigured with 9600 baud.
For setup, no hardware fiddling is required.
Ignore "PIO11 to high" notes, just run commands after power on. you have approx 1/2 second after poweron.
Best do it via a arduino sketch.
For setup with arduino use Serial.print("command");
no cr lf, no \r\n
prepare separate sketches for name setting and for baud setting or else the baud setting command becomes part of the name.
commands:
AT+NAMEname
AT+BAUDn with n from table (1=1200, 2=2400,...8=11520)
That's all there is to it.
For setup, no hardware fiddling is required.
Ignore "PIO11 to high" notes, just run commands after power on. you have approx 1/2 second after poweron.
Best do it via a arduino sketch.
For setup with arduino use Serial.print("command");
no cr lf, no \r\n
prepare separate sketches for name setting and for baud setting or else the baud setting command becomes part of the name.
commands:
AT+NAMEname
AT+BAUDn with n from table (1=1200, 2=2400,...8=11520)
That's all there is to it.
Omnitek_bluetooth slave
- requires pio11 set high via 10k pullup.
- powerup
- connect with 38400,N,1
- run commands
AT+NAME=newName
AT+UART=115200,0,0
- query with AT+name? and AT+uart?
- remove pullup
- power cycle
done.
- powerup
- connect with 38400,N,1
- run commands
AT+NAME=newName
AT+UART=115200,0,0
- query with AT+name? and AT+uart?
- remove pullup
- power cycle
done.
OBDII_Bluetooth Slave
pre configured at 38400 baud
setting PIO4 high returned 'OK' to the wired serial interface- no idea what it is okaying
setting PIO11 high has no effect on entering AT mode (tested with and with out 10k pullup)
never did manage to program it before a mishap ended it
setting PIO4 high returned 'OK' to the wired serial interface- no idea what it is okaying
setting PIO11 high has no effect on entering AT mode (tested with and with out 10k pullup)
never did manage to program it before a mishap ended it
Re: Collection: HowTo config various BT modules
programming the BT module can be done by connecting it to an arduino and run a tailored sketch on the arduino.
Sketch could be something like (save to a file named bt.pde, open in the Arduino IDE and upload to your arduino
Sketch could be something like (save to a file named bt.pde, open in the Arduino IDE and upload to your arduino
Code: Select all
void setup() {
pinMode(13, OUTPUT);
Serial.begin(9600);
//Serial.print("AT+NAMEBT.SL.115k" ); // BT slave module linvar , no trailing cr+lf !!! must exit after name setting or else all following commands get appended to name !!
}
void loop() {
Serial.print("AT+BAUD8" ); // BT slave mit shield und module linvar !!! no trailing cr+ lf
digitalWrite(13, HIGH); // set the LED on
delay(600); // wait f
digitalWrite(13, LOW); // set the LED off
delay(4000); // wait
}
Re: Collection: HowTo config various BT modules
Hello
I know that it's been a while since somebody posted to this thread but i think this information can be useful for somebody
Lazarus, i love you
After i spent hours on getting this thing to work your post gave me the last clue.
I got a Bluetooth-Module from Ebay that looks very similar to yours. The difference is that the text "sct 1052" isn't on mine.
You nearly solved the problem.
If i set Pin 28 (PIO5?) to high level the devices sends "OK" and the blinking of the LED gets slower. Now the module is in "command-mode". I can send AT-Commands with 38400 Baud. Everything works fine
Bye,
Alex
I know that it's been a while since somebody posted to this thread but i think this information can be useful for somebody

Lazarus, i love you

I got a Bluetooth-Module from Ebay that looks very similar to yours. The difference is that the text "sct 1052" isn't on mine.
You nearly solved the problem.
If i set Pin 28 (PIO5?) to high level the devices sends "OK" and the blinking of the LED gets slower. Now the module is in "command-mode". I can send AT-Commands with 38400 Baud. Everything works fine

Bye,
Alex
Re: Collection: HowTo config various BT modules
Hi there,
the info on this page did help me get my board up.
Got mine from e-bay too.
it did report
OBDII
as name
to identify the board :
the antenna has three loops toward the inside like so:
inside
|
| __ __ __
|_| |_| |_| |_______
Command mode can be enabled via pin 28 / pio5. gives an OK (*)
LED indicator is pin 31.
- command mode . slow blinking
- normal not active - fast blinking
- normal active - on
(*) Command mode will set 38k baud regardless of programmed baud rate
at+baud does not work
at+uart does work fine
at+pin does not work
at+pswd does work
I did use the at+name=
to change the device name
all AT commands also accept lower case
at+version reports +VERSION:Serial BT v2.1
maybe this picture will work ?

Michael
the info on this page did help me get my board up.

Got mine from e-bay too.
it did report
OBDII
as name
to identify the board :
the antenna has three loops toward the inside like so:
inside
|
| __ __ __
|_| |_| |_| |_______
Command mode can be enabled via pin 28 / pio5. gives an OK (*)
LED indicator is pin 31.
- command mode . slow blinking
- normal not active - fast blinking
- normal active - on
(*) Command mode will set 38k baud regardless of programmed baud rate
at+baud does not work
at+uart does work fine
at+pin does not work
at+pswd does work
I did use the at+name=
to change the device name
all AT commands also accept lower case
at+version reports +VERSION:Serial BT v2.1
maybe this picture will work ?
Michael
- Attachments
-
- bc417.jpg
- image
- (21.52 KiB) Not downloaded yet
Last edited by Meenzer on Wed Apr 04, 2012 5:32 pm, edited 1 time in total.
Re: Collection: HowTo config various BT modules
Michael,
for the OBDII module to set the name you use STNA= or NAME= ?
for the OBDII module to set the name you use STNA= or NAME= ?
Re: Collection: HowTo config various BT modules
The "linvar slave module" seems to be the easiest to config...Baud rate has to be changed to 11520 right? Where can I buy it? 

Re: Collection: HowTo config various BT modules
glb or emartee?
Just get a cheap one and figure things out. Only caveat: make sure you get one that is _not_ explicitly fixed to _master_ mode.
Just get a cheap one and figure things out. Only caveat: make sure you get one that is _not_ explicitly fixed to _master_ mode.
Re: Collection: HowTo config various BT modules
I have:
http://www.goodluckbuy.com/serial-bluet ... pin-1.html
It started as ‘linvar’.
I get no reply, ever…but I did stumble upon the correct Baud and could then see the LED slow when sending AT+BAUD8 and AT+NAMEwhatever.
I could always Pair and now MWConfig does open and close the correct port.
MWConfig will start but show nothing.
WinGui will start and show nothing but will pop-up ‘no valid answer’ error within a few seconds.
Am I correct in assuming that BT is connected to MEGAs serial 0? (MWv2.0)
Do I have to tell MW to speak BT? I see BTSERIAL but I do now want to fly via BT, just GUI.
http://www.goodluckbuy.com/serial-bluet ... pin-1.html
It started as ‘linvar’.
I get no reply, ever…but I did stumble upon the correct Baud and could then see the LED slow when sending AT+BAUD8 and AT+NAMEwhatever.
I could always Pair and now MWConfig does open and close the correct port.
MWConfig will start but show nothing.
WinGui will start and show nothing but will pop-up ‘no valid answer’ error within a few seconds.
Am I correct in assuming that BT is connected to MEGAs serial 0? (MWv2.0)
Do I have to tell MW to speak BT? I see BTSERIAL but I do now want to fly via BT, just GUI.
Re: Collection: HowTo config various BT modules
No btserial.
But try and swap tx rx lines between bt and mwii.
But try and swap tx rx lines between bt and mwii.
Re: Collection: HowTo config various BT modules
to reconfigure 'linvar' modules, you can use the arduino sketch I posted earlier.
Re: Collection: HowTo config various BT modules
Thanks guys, I did see the guide and the sketch is just a little over my head but..
Back at trying to get my BT working after a great weekend of flying.
As before I never get a reply when sending AT commands to Linvar.
But I did get the light to slow when sending AT+BAUD8 and
I am able to change and have changed its name.
Today while trying to make it work I had BT plugged into RX0 & TX0.
MWCONFIG can open and close the COM but no data flow.
Here’s where it came together for me.
With BT hooked up I plugged a cable to MEGA and my desktop computer, selected the proper COMport and MWCONFIG would do the same thing as with BT, open the COM but no data flow.
Now I unplug BT, restart the desktop MWCF and it works as usual.
WHILE MWCF is running on the desktop I plug BT back in, open MWCF on my laptop, point to the BT COM, hit start and IT WORKS. (everything but read and write)
Bummer, as soon as I stop the desktop, BT stops also.
I now know two things:
My BT is working.
My MEGA2560 does not like BT piggybacked onto RX0 & TX0.
Back at trying to get my BT working after a great weekend of flying.
As before I never get a reply when sending AT commands to Linvar.
But I did get the light to slow when sending AT+BAUD8 and
I am able to change and have changed its name.
Today while trying to make it work I had BT plugged into RX0 & TX0.
MWCONFIG can open and close the COM but no data flow.
Here’s where it came together for me.
With BT hooked up I plugged a cable to MEGA and my desktop computer, selected the proper COMport and MWCONFIG would do the same thing as with BT, open the COM but no data flow.
Now I unplug BT, restart the desktop MWCF and it works as usual.
WHILE MWCF is running on the desktop I plug BT back in, open MWCF on my laptop, point to the BT COM, hit start and IT WORKS. (everything but read and write)
Bummer, as soon as I stop the desktop, BT stops also.
I now know two things:
My BT is working.
My MEGA2560 does not like BT piggybacked onto RX0 & TX0.
Re: Collection: HowTo config various BT modules
Hello everyone I have a problem with crius SE second module is the "Serial Bluetooth RF Transceiver Module RS232" after a while I use gives me problems. connects to the phone but did not receive anything ... is the second module I is burned in this way ... I can only connect ... more why?
Re: Collection: HowTo config various BT modules
so i have the jy-mcu bt from glb, have change the baud rate and it replies back OK to AT at new baud rate. i can pair it but there is no data read or shown in the app...
my fc is http://www.goodluckbuy.com/mwc-multi...lticopter.html
running MW 2.0
is there any tests i can do to narrrow in on where the problem is ?
my fc is http://www.goodluckbuy.com/mwc-multi...lticopter.html
running MW 2.0
is there any tests i can do to narrrow in on where the problem is ?
Re: Collection: HowTo config various BT modules
Switch rx tx lines.
Re: Collection: HowTo config various BT modules
ive tried both ways, and all 3 serial ports with no difference... thanks for your suggestion though
-
- Posts: 317
- Joined: Wed Feb 08, 2012 8:42 pm
- Location: United states
Re: Collection: HowTo config various BT modules
You did click settings in android gui and choose the right mwc version didn't you ? I had that problem when i first used mine ! Said it was connected but i couldn't get any readings . It was set on 1.9 version and i needed it on 2.0 !
Re: Collection: HowTo config various BT modules
test against another computer with the correct GUI for your mwii version.
Use cable first, only then switch to BT bridging.
Use cable first, only then switch to BT bridging.
Re: Collection: HowTo config various BT modules
i did set mw versien.
i also have no problems with ftdi usb cable and windows.
i will look into trying between my laptop bluetooth and mw instead of via fone
i also have no problems with ftdi usb cable and windows.
i will look into trying between my laptop bluetooth and mw instead of via fone
-
- Posts: 317
- Joined: Wed Feb 08, 2012 8:42 pm
- Location: United states
Re: Collection: HowTo config various BT modules
http://www.rctimer.com/index.php?gOo=go ... oductname= i bought this and didnt have to configure anything in firmware and it works great ! CHEAP TOO! That is on my phone though , i havent tried pc yet and may have to change something to use on pc ! But i thought i'd share this with phone users !
Re: Collection: HowTo config various BT modules
yeah im thinking i will just have to buy a new one considering how cheap they are.
Re: Collection: HowTo config various BT modules
I have a Mega 2560 board (GLB $69 board w/ IMU) and a bluetooth module (JY-MCU v1.03). If I connect the BT module to the FTDI port on the FC, I get data in the GUI. If I connect the BT Module to any of the Serial ports on the FC, I do not get data. Is there anything that I need to change in the code to make this work on one of the Mega Serial ports instead of the FTDI?? Is it possible to run on a serial port?
Thanks
Thanks
Re: Collection: HowTo config various BT modules
i have this exact board and problem. ive tried two bluetooth boards now with no difference...
does anyone know if there's somewhere in the code to choose the port it is plugged into like with gps ?
does anyone know if there's somewhere in the code to choose the port it is plugged into like with gps ?
Re: Collection: HowTo config various BT modules
i got it working !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
i love open source !!!!!!!!!!!!!!!!!
so i started reading the code to work out how it does what it does via serial and it became clear that Serial 0 is the port its using for these messages for gui or phone via bt...
mega has 4 serial. on our board 0 is used for ftdi and bt, it would be nice to have bt on serial 1 (or whichever one you specify) instead !!!
ive been confused thinking ftdi pins on fc are a different type of port but they are really just a serial port with different pin numbers to the others, its on the ftdi/usb adapter where the translation occurs....
anyway you have to jack power from serial 1, here's my pic:
i love open source !!!!!!!!!!!!!!!!!
so i started reading the code to work out how it does what it does via serial and it became clear that Serial 0 is the port its using for these messages for gui or phone via bt...
mega has 4 serial. on our board 0 is used for ftdi and bt, it would be nice to have bt on serial 1 (or whichever one you specify) instead !!!
ive been confused thinking ftdi pins on fc are a different type of port but they are really just a serial port with different pin numbers to the others, its on the ftdi/usb adapter where the translation occurs....
anyway you have to jack power from serial 1, here's my pic:
Re: Collection: HowTo config various BT modules
haydent wrote:i got it working !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
i love open source !!!!!!!!!!!!!!!!!
so i started reading the code to work out how it does what it does via serial and it became clear that Serial 0 is the port its using for these messages for gui or phone via bt...
mega has 4 serial. on our board 0 is used for ftdi and bt, it would be nice to have bt on serial 1 (or whichever one you specify) instead !!!
ive been confused thinking ftdi pins on fc are a different type of port but they are really just a serial port with different pin numbers to the others, its on the ftdi/usb adapter where the translation occurs....
anyway you have to jack power from serial 1, here's my pic:
So did you find where in the code to change it from COM 0 ?
Re: Collection: HowTo config various BT modules
i found areas where it is specifying serial 0 for this job, i didnt look for them all though. but if you chango it you will also be changing your ftdi connection to that port (eg 1) as it doesnt differentiate between bt and ftdi/usb communications, they are all handled by the same protocol code regardless.
for now im not bothered trying to mod it as i can just switch my bt and ftdi plug as needed.
i did start a fix request here though viewtopic.php?f=7&t=2218
for now im not bothered trying to mod it as i can just switch my bt and ftdi plug as needed.
i did start a fix request here though viewtopic.php?f=7&t=2218