Quote:
Originally Posted by Mike Mahar
Kevin,
In your gyro initialization code in teleop.c, you have two static ints that you use as counters. (i, j) You increment both every time through the function. When you wish to print out the gyro you have the following:
Code:
if(i == 35 && j >= 300)
Since i has been incrementing all along, it will be equal to j. The next time i == 35 j will also be equal to 35. Putting i = 0 into the body should fix that. You also need to put i = 0 into the body of the
Code:
if(==35 && i >= 300)
statement if you aren't using the encoder code.
|
Thanks, I'll have a look to see if I can clean it up a bit.
-Kevin