|
Re: Position and velocity PIDControllers using same encoder
In your code where you set a set point on your velocity PID Controller couldn't you set the encoder to kRate mode and then in the code where you set a set point on your position PID Controller couldn't you set the encoder to kDistance mode? Unless I'm misunderstanding the use case you aren't going to be running both the position and the velocity PID Controllers at the same time so this should work.
__________________
"May the coms be with you"
Is this a "programming error" or a "programmer error"?
|