Hi, I want my arduino two-wheel car to run a certain distance & turn 90 degrees accurately.
But it is inaccurate after few rotations ,it would rotates overhead.
I have two attachInterrupt:
attachInterrupt(0,rotation_count,CHANGE);
attachInterrupt(1,rotation_count2,CHANGE);
function rotation_count&2 is just a count++(count is a global variable which sets 0)
void moveForward(void)
{
while(count<=48)
advance();//no delay
count=0;
stopRL();
delay(5);
}
I have a stupid solution : After few moveForward()'s , while(count<=x) for x<48 , maybe 45 to reduce
the error value.
2014 APEC(28th) Micromouse Contest Final, USA - YouTube their car are so fast and turn 90 so smooth without
any error.
ROBOTC: Intelligent Path Planning - YouTube also turns great 90.
How did they do it so well?