

Final Competition
Here are the photos and videos of Tart from the final competition. Overall, we are very happy with how Tart turned out despite not getting first place. Notably, we are pleasantly surprised Tart did well on the Frequency Response Track given how long our robot is.


Frequency Response Track: Video
Here is Tart performing on the Frequency Response Track. We made it to Mark 5 in 14 seconds.

Frequency Response: Sp+PID Values
Here are the Sp + PID values for this track. To keep it brief, we used the same PID values for all tracks (it just works!) and altered the speed depending on what each track demanded. Here, we lowered the speed (with reference to the Drag Race) to give more time to read the lines and compensate for turns. Tart was only ever able to make it to Mark 5 regardless of speed, so we aimed to increase speed as much as possible while still reaching that mark.



Drag Race: Video
Here is Tart performing in the Drag Race. Our overall time to the finish line was around 10.5 seconds.

Drag Race: Sp + PID Values
Here are the Sp + PID values for this track. PID remained the same for all tracks, but we increased the speed to near maximum to reach the end as fast as possible. We later ran the track with speed at maximum and it was only marginally faster, not fast enough to beat the next fastest team. We likely could have gone faster with the same settings had we lowered the weight of the robot as it was very stable going down the track at maximum speed.


Circuit Loop Track: Video
Here is Tart performing on the Circuit Loop. We were able to complete 14.5 loops in 2 minutes.

Circuit Loop Track: Sp + PID Values
Here are the Sp + PID values for this track. PID remained the same for all tracks, but we had to lower the speed for this track, slightly lower than what we had for the Frequency Response Track. During our runs, oscillations/stability on straighter portions became the largest issue closely followed by running too fast to make the tight lemon-shaped turns in time. The easiest way to fix this was to lower the speed until Tart was able to make the turns consistently.

A note on Sp + PID Values
PID controls are very common, so for the sake of brevity we won't explain them here (here's a link to the Wikipedia article that explains them in depth).
We largely kept default values (which were Speed Range [0-255], Kp = 1, Ki = 0.001, Kd = 0.01), though we doubled Kd to 0.02 as we wanted to lower the impact of oscillations while going in a straight line (this ended up being more effective for us than changing Kp or Ki with the potentiometers or in the code to lower oscillations).
We kept both the code and the potentiometers for P, I and D largely the same for each track, with minute modifications on the Loop Track as we required (somewhat surprisingly) a lower proportional coefficient than the others to keep Tart from overcorrecting and flying off the track.
Speed was majorly changed per track as evidenced by the photos of the potentiometers (no code was changed for any individual track), being near maximum for the Drag Race, near half for the Frequency Response, and near a quarter of the max for the Loop Track. This became our main tuning mechanism during the competition as our PID values ended up working decently well on all tracks.
Overall, we had a relatively low Kp and Ki (as seen with the position of the potentiometers) as we were turning with the back of the robot and reading from the front. Any small turn in the back led to a large left or right sweep from the sensors in the front that could throw the sensors off the track, so we wanted to minimize the turning power while still being able to complete turns. For this same reason, we greatly increased the Kd value with the potentiometers (as well as with the code) as we wanted to dampen as many straight-line oscillations as we could, as they could make Tart swing back and forth so much that it went off the track.

Final photo of Tart
Here is Tart after the competition had finally finished! Overall, we got 2nd place in Frequency Response and 2nd in number of loops finished in the loop track. We could have done better in the Drag Race, but Tart was *very* backheavy which slowed it down (we weren't last place, just not sure if we got 3rd or 4th).
