Page 1 of 2

Dropbear bluetooth connection

Posted: Tue Jun 14, 2022 4:19 am
by MadScientistDad
Hello All,

So, I see that there is a spot on the Dropbear board for a bluetooth header. What serial port is this attached to and how do I use it? I have looked all over the wiki but I can't find any information on it. Any help is greatly appreciated.

Re: Dropbear bluetooth connection

Posted: Tue Jun 14, 2022 2:51 pm
by MadScientistDad
Good Morning Everyone,

So, I apologize on my very vague question last night. I was kinda at my wit's end trying to get it to work. Let me elaborate a bit. So I have an HC-06 module that I have done the reprogramming on (Baudrate 115200, New name, New Pin, etc) per the wiki. I am able to connect to the unit with my phone (Android) and use a terminal app to send and receive text via the Arduino serial monitor. So I know the unit functions. The problem is when I try to connect to the ECU. I select the correct com port (COM9), and the light on the BT board stops flashing and goes solid indicating a connection. But that is as far as I can get. I have tried connecting to MSDroid, a simple terminal app, Real dash, nothing will receive data from the Speeduino. Same with TS on my PC. It shows connected to the BT in the device manager but TS does not read it at all. I can connect to TS with a USB cable no problem. I have enabled secondary serial in TS, I have tried enabling CAN commands, I have checked every setting I know to check with no success. I have not been trying to use both the BT and the USB at the same time as I read that they could possibly interfere with each other. I am currently using the newest firmware version. Any one have any ideas?

Re: Dropbear bluetooth connection

Posted: Tue Jun 14, 2022 10:05 pm
by JanKovalski
It's attached to Serial3. There's no official support for it yet. You can make it work by altering the sources yourself.

If you want to use it for primary serial, find this line:
https://github.com/noisymime/speeduino/ ... bals.h#L72
and add
Code: Select all
#define Serial Serial3
under it. Note that this way you will loose your USB connection, you'll be able to connect with TS/MSDroid only over bluetooth.

If you want to use it for secondary serial, change Serial2 to Serial3 here:
https://github.com/noisymime/speeduino/ ... ms.ino#L46

Re: Dropbear bluetooth connection

Posted: Wed Jun 15, 2022 6:16 pm
by MadScientistDad
Hey Jan,

Thank you so much for the info. I appreciate the help.

Re: Dropbear bluetooth connection

Posted: Mon Jun 20, 2022 6:24 pm
by MadScientistDad
Hello All,

Happy belated Father's day to all you Dad's out there. So, I tried to set the secondary serial to Serial 3 but after I compile the .ini and install it, the ECU will no longer connect to TS. I admit, I'm no computer wiz but I do successfully update the ECU according to the Arduino IDE. If I reload the standard firmware using speedyloader, I have no problems. Any Ideas? The ONLY thing I am changing is Serial2 to Serial3 for the Teensy board in the Comms tab.

Re: Dropbear bluetooth connection

Posted: Mon Jun 20, 2022 6:53 pm
by jonbill
you compiled the firmware from the master branch, not the. ini, right?
the ini and the firmware versions need to match, so update your ini file in tuner studio properties with the one in master.

Re: Dropbear bluetooth connection

Posted: Mon Jun 20, 2022 9:07 pm
by MadScientistDad
Thanks Jon, I will give it a try tonight and report back. I did compile using the master and not just the .ini.

Re: Dropbear bluetooth connection

Posted: Tue Jun 21, 2022 4:06 am
by MadScientistDad
Alas, another unsuccessful attempt to change Serial2 to Serial3. Same thing as before, if I compile it using the Arduino IDE, it won't communicate with TS. If I use Speedy loader, it works just fine. If there is any snippet of code or something I can post to see if anyone can figure out what I'm doing wrong, please let me know. I have read the wiki and followed it step by step but to no avail. Maybe this is God's way of telling me I am a gearhead not a programmer LOL. Any suggestions?

Re: Dropbear bluetooth connection

Posted: Tue Jun 21, 2022 7:11 am
by jonbill
do you get any errors reported? are you connecting TS via primary serial?

Re: Dropbear bluetooth connection

Posted: Tue Jun 21, 2022 7:02 pm
by MadScientistDad
Hey Jon,

No errors, and yes I'm connecting via usb to the front of the Dropbear. Could it have anything to do with the arduino IDE settings for the Teensy? I noticed that there were a ton of Serial options, MCU speed options, etc. I am comiling using the speeduino.ino in speeduino-master>speeduino>speeduino.ino. Is that the correct file? That is the same location that I changed the cancomms.ino file. From there, I hit upload and it compiles then brings up the Teensyduino loader and that's it.