Search This Blog

Monday, May 9, 2011

Yar! Ye computer can follow a map!

Good progress has been made. I fixed the compiling error and plugged in the bare minimum version of my navigation code. It is in need of refinement, but at least it drives in the right direction. Next, I took an old code to grab data points from a picture (right center), then using Google maps I gave the program  a rough set of way-points plotted in "Command Position" (top left). The resulting actual path driven by the kart is seen in the plot titled "position" (bottom left).

As you can see from the "steering command" plot (bottom right), every time the kart nears a way-point, the driver attempts to jerk the wheel since even being a little off will make the directional error grow rapidly. This will be one of the many refinements that will be made once all the bare-bone systems are in-place.





For the critical readers out there, you will notice that my kart probably went off the track in this simulation. You are correct in this conclusion. But I am not concerned since I did not attempt to tell the computer were the edge of the track might be. That is a constraint I will eventually add; however, that won't come until I get the optimization codes running. I will add that as a constraint since I would like the optimum driving line to not involve driving over narrow sections of dirt (in therefore skip large segments of the track) to cut down lap times.

The upcoming modification to the model will attempt to modify the 'suspension' of this model to account for the significant twisting of the chassis in a turn. This will result in the kart lifting-up the inside rear tire in turns as can be seen in the picture below.


This presents a substantial challenge to the dynamics of the problem, but I am sure I'll figure it out. Confirming my model will likely be more difficult than developing it. The trick is to keep the computations simple and accurate.


So until next time,

-S

No comments: