Quote:
Originally Posted by Mr. Lim
I've noticed in the WPILib documentation that the FPGA is only mentioned when using the 4x encoder mode. In 1x mode, the documentation mentions that a Counter object is used instead. If we use 1x mode, is the FPGA NOT used to count pulses? If the FPGA is not used, does this reduce our maximum count rate by more than a factor of 4? Does this basically mean the 4x mode is always our best bet when using encoders?
|
The FPGA implements 4 encoders and 8 counters. The encoders are used in 4x mode while the counters are looking at only one of the phases in either 1x or 2x mode. The FPGA is doing the counting in either case.
If you're just counting pulses, you'll get the highest resolution with 4x. However, if you're using the rate feature, you will probably get better results (less noise) with 1x, as it is always counting the same transition.
As for the maximum rate question:
http://decibel.ni.com/content/message/12523#12523