Quote:
Originally Posted by Woolly
Right, I know for our shooter wheel we had to average the last 5 10ms samples to get consistent data out of our US Digital 256 count encoder.
|
This should not be necessary with that encoder if the counter object is set up properly so that the FPGA, not your code, is doing the period computation. You should be able to get very accurate and rock-solid rpm readings without doing that kind of averaging.
Averaging like that introduces phase lag in the sensor signal. Bang-bang does not like phase lag.
What language were you using?
Quote:
|
Not to mention we complicated our controller by using an equation to look up the approximate base power needed for the RPM we wanted,
|
That's called feedforward, and is totally unnecessary with bang-bang.
Quote:
|
After all this fuss, it has become quite reliable though.
|
If it's working well for you, now is not the time to be changing the competition code on your robot. But if you'd be interested in exploring this further (maybe on an old robot), start another thread and we can have a discussion about it.