
06-02-2005, 23:25
|
 |
La Caņada High School
 FRC #2429
Team Role: Mentor
|
|
Join Date: Jan 2002
Rookie Year: 2001
Location: La Caņada, California
Posts: 1,335
|
|
|
Re: Problems with PID- PLEASE HELP!!!
Quote:
|
Originally Posted by thinkpad
Thanks for responding Mr. Watson.
I just double-checked the code and it is set as per your reccomendations, but we get the same undesired results.
Is there a way to see the readings of the encoder counts in the PID files, i tried adding in printf statements in the PID.c file where the encoder count values are being called:
long int Get_Encoder_Count(int motor)
{
if (motor == 0)
{
temp = Get_Left_Encoder_Count();
printf("/rLeft count: %5d", (int)temp);
return (temp);
}
else if (motor == 1)
{
temp = Get_Right_Encoder_Count();
printf("/rRight count: %5d", (int)temp);
return (temp);
}
but this just prints out the values of Right count: 0 and Left count: 0. Can anyone tell why this can be?
I know i am being annoying, but we are really desperate about this, so please keep the inputs flowing.
Thanks for your suport,
Vick.
|
How did you hook up the encoders (electrically and mechanically)?
-Kevin
__________________
Kevin Watson
Engineer at stealth-mode startup
http://kevin.org
|