View Single Post
  #8   Spotlight this post!  
Unread 23-01-2011, 09:31
tluks tluks is offline
Registered User
None #1126 (sparx)
Team Role: Mentor
 
Join Date: Jan 2009
Rookie Year: 2008
Location: new york
Posts: 5
tluks is an unknown quantity at this point
Re: Encoder fixed in WPILib 2011?

Quote:
Originally Posted by ZonChau View Post
Wonder if this code might work for you to cling onto hope you don't need to have that pseudo code.



I think I understand you are saying you need to initialize the encoders twice for each one.
I'd describe just a little differently. I don't think it has to do with the variable initialization. It is more like every other "new'ed" encoder's getRate method doesn't work right. So you have to new one and throw it away, to new the next one which will work. It is like something in the construction of one encoder has side effects that impact the construction of the next one.