... | ... | @@ -120,6 +120,17 @@ First, we tried to integrate the entire PID pseudo code solution into our applic |
|
|
|
|
|
Given the nature of big bang integration, the cause of this behaviour can be numerous factors. Most likely would be the amount of power given to the robots motors and variables directly translated from the source application.
|
|
|
|
|
|
##### Proportional algorithm #####
|
|
|
Instead of trying to fix issues with the entire PID algorithm we wrote, we instead reverted the algorithm to a form factoring in only the 'P' of PID, namely the proportional factor. In short terms, the idea behind a proportional algorithm is to have the robot change direction based on linear calculations instead of prompting a big change at a specific value. This reduces jaggedness in the robots behaviour such that it takes smaller turns depending on values read.
|
|
|
|
|
|
After implementing this, our robot seemed more responsive to the black line but still didn't work. The issue was soon found to be a software bug however, and after correcting for integers (by multiplying all factors by 100 and then dividing the resulting effect by 100), the robot behaved well. As can be seen in the video <<<ref>>>, movements are still abrupt, but much better than in previous exercises.
|
|
|
|
|
|
##### Integrating to correct behaviour given history and using derivative to predict future state #####
|
|
|
By integrating from an amount of previous samples, the application can classify its situation better, which allows the program to follow the line more closely. By taking the derivative of the last two error measures, we can also predict future states better.
|
|
|
|
|
|
We played around with this ....
|
|
|
SNAK OM DE TRE VÆRDIER, INDSÆT EN MASSE FILM
|
|
|
|
|
|
### Color Sensor ###
|
|
|
|
|
|
#### Description ####
|
... | ... | |