View Single Post
  #2   Spotlight this post!  
Unread Today, 05:14
bmfrc bmfrc is offline
Registered User
FRC #5554
 
Join Date: Feb 2017
Location: Israel
Posts: 11
bmfrc is an unknown quantity at this point
Re: encoder PIDController and set

Thanks Joe!
I'm really new to this stuff..

Quote:
Originally Posted by Joe Ross View Post
1x and 4x decoding affect which edges the FPGA counts, but not the reported distance. When you select 4x, WPILib scales the output to be the same as 1x, ie if DistancePerPulse is 1, in 4x you would get values of 1.0, 1.25, 1.50, 1.75, 2.0, and in 1x you would just get 1.0, 2.0, etc.
Im not sure i understand the scaling thing.
if 4X output higher resolution to 1.25, 1.50 VS 1, 2 of the 1x, where is the scaling?
Does it affect the DistancePerPulse calculation from our side? we devide the circumference by 360 or 1440?

Quote:
Originally Posted by Joe Ross View Post
It's much better to use 1x decoding for rate, so the same edge is always being counted. It's also better to use a lower resolution encoder, so that there is a longer time period between pulses.
What about measuring distance? should we use 4x decoding?
Reply With Quote