Ciao to everybody, just want you to know that today I finally made my EM406, ArduIMU and Ardupilot work together with a simple trick. From http://seniord.ece.iastate.edu/dec0803/manuals/EM-406%20Product_Guide1.pdf we see that the output baud rate of the infamous EM406 is 4800 bps. Adjusting the code for arduIMU, ardupilot to work at 4800 everything works very fast, ever without the "first time" GPS locking procedure. All right.The only problem is that one might desire a higher than 4800 output rate. Argh, I am a very newbie to arduino and I am still searching for the solution.
UPDATE!
So, with the help of Hopslink, I finally got it all working.
This made my arduIMU connect with the so-hatred EM406 module without using the NMEA protocol.
If you make arduPilot communicate with arduIMU @ 38400 bps you're really done. That's it.
Comments
All the best!
One weird thing when connecting the EM406 to ArduIMU using the uBlox adapter board is you need to connect OUT to IN and IN to OUT - makes sense I guess.
So my basic observation is that IMU software is designed to deal with the EM406 "fresh from the factory"..
The third one should be the charm... (hopefully). Apparently binary mode configuration requires a different message format. DIYDrones' Ken has supplied code to reset to NMEA mode - here.
Attached below is Ken's reset code as a sketch. Run that, then try the latest IMU code from the repository.
Sorry, I can't test these properly as I don't have an EM406. If it doesn't work shout as I have found a datasheet with details of the binary protocol and it is possible to just change binary baud rate on the fly.
EM406_reset.pde
Find attached an updated version. The last had a possible error due to me coding/uploading in haste (was on my way out of the house and keeping my better half waiting), my apologies!
GPS_EM406_jeff2.pde
Suspect you have hit the nail on the head. If have a lock with ArduPilot then the GPS is set for 57kbit/s binary mode, and those settings are retained until the onboard supercap discharges (up to a week).
The IMU initialisation code assumes the GPS is in the default 4800/9600kbit/s NMEA mode. Try swapping your current GPS_EM406.pde with the one attached below, which also tries initialisation at 57kbit/s. Otherwise you may have to wait for discharge.
Please let us know if this works or not. Thanks.
GPS_EM406_jeff.pde
Yes, once you set one baud rate you have to maintain it through the data flow. Hope you have good luck with this issue, it took me several weeks to get resolved! My key was the baud rate TO the gps