View Single Post
  #10   Spotlight this post!  
Unread 03-02-2012, 19:33
mikets's Avatar
mikets mikets is offline
Software Engineer
FRC #0492 (Titan Robotics)
Team Role: Mentor
 
Join Date: Jan 2010
Rookie Year: 2008
Location: Bellevue, WA
Posts: 673
mikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of lightmikets is a glorious beacon of light
Re: Encoder Wiring Help Needed

Quote:
Originally Posted by its da PAT!!! View Post
Yes that's what I mean. But if you use PWM and use either A or B channel is it less accurate?
It's not a matter of accuracy, without two channels, it won't know the direction of rotation. Besides, unless you are writing code to "count" the pulses from the one digital channel yourself, the Encoder module provided by the WPI library expects both A and B channels.
Code:
Encoder(UINT32 aChannel, UINT32 bChannel, bool reverseDirection=false, EncodingType encodingType = k4X);
__________________

Last edited by mikets : 03-02-2012 at 19:38.