My diy GPS-rover

80 views
Skip to first unread message

RP6conrad

unread,
Dec 11, 2016, 10:07:32 AM12/11/16
to diyrovers
I want to present here my GPS RC-car : 
Base is a 1/10 Tamiya RC-car with frontdrive, DC-motor and 6 cells NiCad (still going strong after 10 years !). The controller is a STM32 F401 RE (nucleo) board. GPS is a Ublox M8N, update rate is set to 10 Hz. A normal 35 MHz Transmitter / Receiver is used for manual control. The Rx-Sum Signal is analyzed by the µ, so all channels can be used in the software. For data logging, a BT HC05 can transmit serial data. I also mounted a WS2812 Led strip for visual indications. A 9dof IMU (MPU9250) is used as compass. For distance/speed measurements, I also have a encoder on the motor.
Here some videos of the car in action : 
The next goal is to achieve higher speeds. I already implemented next control-loops : 
- Lower P-control for direction with higher speeds (direction instability at high speeds due to GPS lag)
- Switch to the next waypoint is function of speed : low speed, distance to the waypoint has to be smaller dan 1 m, with higher speeds this distance gets higher.
- Speed regulation depends on the difference  actual heading / next heading.
The problem that I have now is the Compass : On flat level, it is very good, but on a ramp / hill, there is a big mismatch. I tried to use the MPU9250 Lib from Kris Winer, but this has a unacceptable lag (seconds).
Greetings from Belgium  !

Michael Shimniok

unread,
Dec 11, 2016, 11:52:18 AM12/11/16
to diyrovers

Looks and sounds fantastic!

Does the board have 3 axis gyro too?


--
You received this message because you are subscribed to the Google Groups "diyrovers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to diyrovers+...@googlegroups.com.
To post to this group, send email to diyr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/diyrovers/db25507f-cac2-4441-941a-9efb96ee5b89%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

RP6conrad

unread,
Dec 12, 2016, 2:00:30 AM12/12/16
to diyrovers
Yes, de MPU9250 is a 9 DOF. With the Algoritme of Kris Winer (Mahony / Madgwick fusion), I have a lag  that is to big (seconds). I seems to work, but with heading changes, there is a mismatch and then the heading slowly drifts to right value.  For now, I only use the z-gyro combined with the x/y compas. I have good results (update rate is 200 Hz), but still a problem if the rover is not horizontal. Maybe I have a problem with the gain of the gyros, as I noticed that the z-gyro gain was 9% wrong. I didnt measure the gain of the X/Y gyro yet. So, still work to do.

Greetings, Jan.

Op zondag 11 december 2016 17:52:18 UTC+1 schreef Michael Shimniok:

RP6conrad

unread,
Dec 22, 2016, 5:59:45 AM12/22/16
to diyrovers
I did some software tuning on my rover, with good results. The rover can now "race" the track with  a top-speed from 8 m/s. Here a video of the result : GPS_Racing
These were the basic rules for optimizing the speed : 
1. Proportianal gain is af function of Speed : the higher the speed, the lower the gain.
2. Switch over to the next waypoint is a function of speed : with high speeds, the distance becomes larger.
3. The speed is function of the upcoming corner : the sharper the corner, the lower the speed.
All these rules are mainly for compensating the GPS/system lag. Off course, on sharp corners you see a lot of overshoot. Here you have to choose between accuracy = low corner speed, or fast lap.
The GPS was set to a update rate of 10 Hz, but the measured lag was rather 400 ms (difference IMU heading / GPS heading shows the lag).
Greetings, Jan. 

Op zondag 11 december 2016 16:07:32 UTC+1 schreef RP6conrad:

Wayne Holder

unread,
Dec 22, 2016, 6:14:30 AM12/22/16
to diyr...@googlegroups.com
Nicely done!

Wayne

--
You received this message because you are subscribed to the Google Groups "diyrovers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to diyrovers+unsubscribe@googlegroups.com.

To post to this group, send email to diyr...@googlegroups.com.

Rich B (Roadrunner)

unread,
Dec 23, 2016, 9:51:29 AM12/23/16
to diyrovers
Well done!
Reply all
Reply to author
Forward
0 new messages