Megasquirt Forum Area is for discussing Megasquirt EMS

Megasquirt $14 Bluetooth now working on MS2

Thread Tools
 
Search this Thread
 
Old 10-30-11, 01:25 PM
  #1  
S5 powered Lotus 7 clone

Thread Starter
 
rx7locost's Avatar
 
Join Date: Aug 2008
Location: Illinois
Posts: 115
Likes: 0
Received 0 Likes on 0 Posts
IL $14 Bluetooth now working on MS2

I've gotten so much inspiration and help from this forum, I thought I'd share my recent efforts. I have just finished a Bluetooth installation on my MS2. It has limited testing but so far, it seems to work. The range is limited to ~15 ft. It will automatically reconnect when I return in range. I purchased an eBay serial - bluetooth slave module that has true RS-232 level inputs and comes with both a male and female DB9 connector. It runs on 5V, which is great for the MS. However, it does not get power thru the DB9 connector. I modified it so that it now gets power from the DB9M-pin9. This unit requires no handshaking modifications to the Megasquirt, unlike the "recommended" SOCKET adapter. It plugs into the serial port on the MS, so it can be removed for a cable connection if necessary. Unlike some other implementations I considered, the PCB mounted antenna is outside the MS enclosure, ensuring a good signal. Total cost was just under 14 bucks. No more wires! Here are the step by step instructions for the DIYer:

1) Purchased a true rs232 level, dual DB9, 5V, Serial - Bluetooth module (slave) from eBay for ~14 bucks.
2) Carefully cut away their heat shrink sleeving
3) Solder a temporary jumper from 3.3V to PIO11 for setup of baud rate (the mfgr recommend 10K resistor but I tried a 4.7K and it was too high a resistance. I just shorted the two terminals together)
4) Plug DB9-F into a true computer serial port (a USB to serial cable might work) and apply a temporary ~5V (I used 4 AAA batteries) to the +V and –V terminals on the 4 pin header.
5) Send AT command “AT+BAUD8” via any terminal program to set module to 115200 baud rate. (I used Hyperterminal)
6) Remove temporary jumper from step 3
7) If not already done, de-solder pins 6, 7, 8 & 9 (from the DB9-M connector)
8) Insulate under pins 6, 7, 8 & 9
9) Add jumper wire from DB9-M pin 9 connector to +V on 4-pin header. (optional: remove the DB9-F connector)
10) Add heat shrink or wrap in insulating material.
11) Plug module into the Megasquirt serial port.
12) Turn on MS and laptop. Search for new Bluetooth devices.
13) Enter default pairing code “1234”
14) Determine the com port the module is using by viewing Bluetooth devices, right click the Bluetooth icon “Linvor” and then “Services”. It will tell you which com port has been assigned to the Module.
15) Open TunerStudio’s “Communication” then “Settings” tabs and set the Com Port to match.
16) Done. You should now be connected.
Attached Thumbnails  Bluetooth now working on MS2-modified-bluetooth-db9.jpg    Bluetooth now working on MS2-finished.jpg    Bluetooth now working on MS2-purchased.jpg  
Old 11-07-11, 12:35 PM
  #2  
Rotary Freak

iTrader: (7)
 
Shainiac's Avatar
 
Join Date: Jun 2006
Location: Lyme, CT
Posts: 1,575
Received 42 Likes on 31 Posts
Awesome! Thanks for the thorough writeup.
Old 11-07-11, 01:26 PM
  #3  
Sharp Claws

iTrader: (30)
 
RotaryEvolution's Avatar
 
Join Date: Oct 2003
Location: Central Florida
Posts: 5,107
Likes: 0
Received 41 Likes on 40 Posts
more reasons for me to start using MS, keep em coming. hell, i could tune cars from a recliner sitting next to the dyno inside a glass case!
Old 11-07-11, 01:45 PM
  #4  
Engine, Not Motor

iTrader: (1)
 
Aaron Cake's Avatar
 
Join Date: Feb 2001
Location: London, Ontario, Canada
Posts: 29,789
Likes: 0
Received 108 Likes on 91 Posts
Originally Posted by Karack
more reasons for me to start using MS, keep em coming. hell, i could tune cars from a recliner sitting next to the dyno inside a glass case!
Once you've gone Megasquirt, you don't go back!

At the office I have some Ethernet to serial converters that I have tested with a Megasquirt. Someone could be in Florida with one connected to their 'Squirt and I could tune it in real time from London while they are on the dyno via the Internet.
Old 11-07-11, 05:31 PM
  #5  
Senior Member

 
elturbonitroso's Avatar
 
Join Date: Nov 2006
Location: connecticut
Posts: 461
Likes: 0
Received 13 Likes on 12 Posts
Originally Posted by Aaron Cake
Once you've gone Megasquirt, you don't go back!

At the office I have some Ethernet to serial converters that I have tested with a Megasquirt. Someone could be in Florida with one connected to their 'Squirt and I could tune it in real time from London while they are on the dyno via the Internet.
like this one could you share more.
Old 11-08-11, 08:50 AM
  #6  
Engine, Not Motor

iTrader: (1)
 
Aaron Cake's Avatar
 
Join Date: Feb 2001
Location: London, Ontario, Canada
Posts: 29,789
Likes: 0
Received 108 Likes on 91 Posts
Basically these:

http://ca.startech.com/Networking-IO...ter~NETRS232_1

We use them to manage phone systems.
Old 11-08-11, 05:29 PM
  #7  
Senior Member

 
elturbonitroso's Avatar
 
Join Date: Nov 2006
Location: connecticut
Posts: 461
Likes: 0
Received 13 Likes on 12 Posts
thank you
Old 11-15-11, 02:31 PM
  #8  
Rotary Enthusiast
iTrader: (5)
 
kutukutu1's Avatar
 
Join Date: Jan 2008
Location: Southfield, MI
Posts: 1,296
Received 59 Likes on 38 Posts
That's bad ***. Good job man, maybe after i build my megasquirt ill do the same. Do you think it could work with wifi as well instead of bluetooth?
Old 11-15-11, 06:57 PM
  #9  
S5 powered Lotus 7 clone

Thread Starter
 
rx7locost's Avatar
 
Join Date: Aug 2008
Location: Illinois
Posts: 115
Likes: 0
Received 0 Likes on 0 Posts
I can see 3 issues to overcome with WIFI. 1) there are precious few serial-wifi adapters. There are plenty of USB-WIFI adapters though. You might run the USB-WIFI adapter with a serial-usb adapter cable but that adds multiple interfaces and might not get things to talk together. 2) My tuning software only has the capability of communicating thru a com port. That would require some sort of software on your PC to allow WIFI to create a virtual serial port. This may be commonly available, it may even come with a pre-assembled serial-wifi adapter. You'd have to check. 3)The serial-usb and usb-WIFI adapters and port software may still not work. Since not all serial-USB adapters function properly with the MS, I was skeptical in trying out expensive WIFI alternatives. It may cost you $100+ just to experiment and then find out it doesn't work.

My needs were small and my serial-bluetooth adapter fits them. It is a light, small, inexpensive device. It doesn't require modifying an already in-place and operating Megasquirt and doesn't require any additional mounting methods as it just hangs off the DB9 connector. It allows me to tune from the driver's seat without getting tangled with wires or by standing along-side the car. Trying it only took only a small investment to experiment, something I was willing to eat if it didn't work out. I know others want a longer range capability, but I didn't need it. I'd suggest you Google Megasquirt and WIFI and see what you find.

If you find a successfull method, share it with the rest of us.
Old 11-15-11, 09:22 PM
  #10  
Rotary Enthusiast
iTrader: (5)
 
kutukutu1's Avatar
 
Join Date: Jan 2008
Location: Southfield, MI
Posts: 1,296
Received 59 Likes on 38 Posts
FL

Originally Posted by rx7locost
I can see 3 issues to overcome with WIFI. 1) there are precious few serial-wifi adapters. There are plenty of USB-WIFI adapters though. You might run the USB-WIFI adapter with a serial-usb adapter cable but that adds multiple interfaces and might not get things to talk together. 2) My tuning software only has the capability of communicating thru a com port. That would require some sort of software on your PC to allow WIFI to create a virtual serial port. This may be commonly available, it may even come with a pre-assembled serial-wifi adapter. You'd have to check. 3)The serial-usb and usb-WIFI adapters and port software may still not work. Since not all serial-USB adapters function properly with the MS, I was skeptical in trying out expensive WIFI alternatives. It may cost you $100+ just to experiment and then find out it doesn't work.

My needs were small and my serial-bluetooth adapter fits them. It is a light, small, inexpensive device. It doesn't require modifying an already in-place and operating Megasquirt and doesn't require any additional mounting methods as it just hangs off the DB9 connector. It allows me to tune from the driver's seat without getting tangled with wires or by standing along-side the car. Trying it only took only a small investment to experiment, something I was willing to eat if it didn't work out. I know others want a longer range capability, but I didn't need it. I'd suggest you Google Megasquirt and WIFI and see what you find.

If you find a successfull method, share it with the rest of us.

Thank you, will research it an let everyone know if there is any positive to it.
Old 12-08-11, 05:42 PM
  #11  
Senior Member

 
13bdarren's Avatar
 
Join Date: Jun 2004
Location: Canada
Posts: 442
Likes: 0
Received 0 Likes on 0 Posts
Could some one show how to do the 3rd step. I am lost. I tried to search for a diagram to see what is the 3.3v and PI011 is. The rest seems simple. Thanks
Old 12-08-11, 06:14 PM
  #12  
Senior Member

 
13bdarren's Avatar
 
Join Date: Jun 2004
Location: Canada
Posts: 442
Likes: 0
Received 0 Likes on 0 Posts
I think I found it but still would like someone to confirm that I am doing it right.
http://www.emartee.com/Attachment.php?name=41656.pdf
Old 12-09-11, 12:53 PM
  #13  
S5 powered Lotus 7 clone

Thread Starter
 
rx7locost's Avatar
 
Join Date: Aug 2008
Location: Illinois
Posts: 115
Likes: 0
Received 0 Likes on 0 Posts
Yep. Just temporarily jumper pin 12 to pin 34 on the smaller PCB per the pdf you linked to. I soldered a jumper in place, then unsoldered it when done.

Let me know how it works out for you.
Attached Thumbnails  Bluetooth now working on MS2-jumper.jpg  
Old 12-09-11, 05:09 PM
  #14  
Senior Member

 
13bdarren's Avatar
 
Join Date: Jun 2004
Location: Canada
Posts: 442
Likes: 0
Received 0 Likes on 0 Posts
That is what I have done. Thanks for the pic. I am having a problem with hyperterminal. I don't have a pc with a serial port on it. I am using a usb to serial converter. Any suggestion on what I could try to get the baud rate set.
Old 12-09-11, 07:55 PM
  #15  
S5 powered Lotus 7 clone

Thread Starter
 
rx7locost's Avatar
 
Join Date: Aug 2008
Location: Illinois
Posts: 115
Likes: 0
Received 0 Likes on 0 Posts
I was having some trouble early on with a USB-Serial converter. It may heve been just me getting confused between which com port was what setup and..... well, i won't go into that. I ended firing up the old desktop that had a dedicated serial port. One thing I learned after making the change to the desktop was that I needed to copy/paste the commands into Hyperterminal from some other program such as notepad. Otherwise my typing speed was too slow and it would not work properly. The only command I could type directly into Hyperterminal was "AT"; in which the coverter replied "OK". All other commands were too entered too slowly.
Old 12-12-11, 05:47 PM
  #16  
Senior Member

 
13bdarren's Avatar
 
Join Date: Jun 2004
Location: Canada
Posts: 442
Likes: 0
Received 0 Likes on 0 Posts
I am having no luck with hyperterminal. Send at command reply ok but when I send at+baud8 I get a error message. I gave on this project for now will try again in the spring.
Old 12-13-11, 09:17 AM
  #17  
S5 powered Lotus 7 clone

Thread Starter
 
rx7locost's Avatar
 
Join Date: Aug 2008
Location: Illinois
Posts: 115
Likes: 0
Received 0 Likes on 0 Posts
Sorry you couldn't get it to work. It sounds like you got past the USB-Serial port adapter issue that I couldn't. It would appera that you are so close. Did you copy the "at+baud8" from a notepad and paste it into Hyperterminal? The adapter needs to see the full command entered in less than a second.

There would appear to be two different versions of serial/BT adapters on eBay. They look almost exactly the same. The one I used can be identified with the JY_MCU BT<=>RS232 V1.2 marking on it. I don't know about the other one.
Old 12-13-11, 03:50 PM
  #18  
Senior Member

 
13bdarren's Avatar
 
Join Date: Jun 2004
Location: Canada
Posts: 442
Likes: 0
Received 0 Likes on 0 Posts
I did try the copy and paste method. No luck I might try to actually use a resistor instead of a jumper. The one I bought has the same marking as yours. I think the problem is the idiot on the key board. I have never had any luck using hyperterminal. Thanks for all the help.
Old 12-19-11, 10:18 PM
  #19  
Junior Member
 
ErnestChristley's Avatar
 
Join Date: May 2011
Posts: 29
Likes: 0
Received 0 Likes on 0 Posts
I got one of these tonight. I could not get it to communicate until I broke the connection that I had soldered between the pins. I got the data rate set and then verified the datalink. While it was connected to the computer I set the baud rate with, I paired with my laptop and saw the keys I was typing come up in Putty.

When I put the adapter on my ECU. I could get it to pair, but I could not get TunerStudio to talk to the ECU with the same laptop. At this point, I'm thinking that I pressed the reset button, and the unit is back at 9600-8N1. I will find out about that tomorrow.

BTW, where can one find the full documentation for these devices? There is a link to a spec sheet posted above, but that isn't for the entire dongle, just the chipset.

Last edited by ErnestChristley; 12-19-11 at 10:26 PM. Reason: Left out question, which was the reason for making the post in the first place.
Old 12-20-11, 01:12 PM
  #20  
S5 powered Lotus 7 clone

Thread Starter
 
rx7locost's Avatar
 
Join Date: Aug 2008
Location: Illinois
Posts: 115
Likes: 0
Received 0 Likes on 0 Posts
Ernest. Congratulations on getting this far so quickly. I too, accidentally hit the reset button and had to reset the baud rate during my first connection to the MS. Hopefully you will find that you did in fact hit the reset button. Please let us know of your findings.

Unfortunately, I have not been able to obtain nor find complete documentation for the assembly. The one I got from the seller was for a different board with the module. The command set is a very abbreviated set that includes something like:

AT
AT+BAUD
AT+VER
AT+PASSWORD
AT+NAME

That may be the extent of it.
Old 12-20-11, 11:35 PM
  #21  
Junior Member
 
ErnestChristley's Avatar
 
Join Date: May 2011
Posts: 29
Likes: 0
Received 0 Likes on 0 Posts
NC No good

It's not the baud rate. I went through the steps to set it again, and verified that it was working. I can't get TunerStudio to talk to my MS 3.0 board. It first gives an error message that it is possibly a noisy connection, and trying it again sends TS into high processor usage la-la land.
I reconnected with the USB-to-serial dongle to verify that it TS and MS were still on talking terms, and everything was good.
The LED on the adapter blinks when when I plug it into the MS, so I know that it is getting power.
I verified that my bluetooth enable laptop would talk to the serial port weilding computer, so I know that step is good.
Put it all together, and nuthin'.
One strangeness is that the AT+NAME command doesn't seem to work. No matter what I follow it with, it echos something like ATsetname. I still haven't figured out what that is about.
Old 12-21-11, 03:20 PM
  #22  
S5 powered Lotus 7 clone

Thread Starter
 
rx7locost's Avatar
 
Join Date: Aug 2008
Location: Illinois
Posts: 115
Likes: 0
Received 0 Likes on 0 Posts
AT+NAME command should return ATsetname. This is normal, You have just set the name to " " (none). The full command should be AT+SETNAMExxxxx where xxxxx is the name you want to assign the device. Regardless of the actual name you enter, it returns "ATsetname". This is suimilar to setting the PIN. it returns "ATsetPIN" not the actual PIN number.

I am currently reviewing my complete setup for more detailed instructions with screenshots etc. I've got up to setting up Hyperterminal and getting the complete cammand set documented. Next is the connecting via BT and then to Tunerstudio. KEEP THE FAITH. You are so close......
Old 12-21-11, 05:33 PM
  #23  
S5 powered Lotus 7 clone

Thread Starter
 
rx7locost's Avatar
 
Join Date: Aug 2008
Location: Illinois
Posts: 115
Likes: 0
Received 0 Likes on 0 Posts
Ernest, you have a PM. I would attach my writeup here, but it exceeds the size limit allowed.
Old 12-21-11, 10:11 PM
  #24  
Turbo vert

iTrader: (33)
 
just startn's Avatar
 
Join Date: Aug 2005
Location: Elyria, OH
Posts: 2,698
Likes: 0
Received 2 Likes on 2 Posts
Originally Posted by Aaron Cake
Once you've gone Megasquirt, you don't go back!

At the office I have some Ethernet to serial converters that I have tested with a Megasquirt. Someone could be in Florida with one connected to their 'Squirt and I could tune it in real time from London while they are on the dyno via the Internet.
Reallyyy...i need your help lol.
Old 12-22-11, 08:28 PM
  #25  
Senior Member

 
.::evil inside::.'s Avatar
 
Join Date: Jun 2004
Location: Australia
Posts: 263
Received 2 Likes on 2 Posts
Good write up, I ordered mine the other day. I can't wait for it to get here so I can start using ShadowLogger on my SGS. I also can't wait for the day that a tuning interface is available on android! Soon I hope.


Quick Reply: Megasquirt $14 Bluetooth now working on MS2



All times are GMT -5. The time now is 09:36 AM.