View Single Post
  #3   Spotlight this post!  
Unread 24-10-2012, 12:12
MrRoboSteve MrRoboSteve is offline
Mentor
AKA: Steve Peterson
FRC #3081 (Kennedy RoboEagles)
Team Role: Mentor
 
Join Date: Mar 2012
Rookie Year: 2011
Location: Bloomington, MN
Posts: 578
MrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond reputeMrRoboSteve has a reputation beyond repute
Re: Bench top setup for demonstrating PID

The Robodox paper proposes implementing a PIDSource subclass (RPMSource) that wraps an RPM value, which is the wired to the WPILib PIDController. On each turn of the Execute() crank in our command, we take the elapsed time and change in encoder count to calculate an RPM value, which is fed into the RPMSource instance.

apalard -- it does look like we're not too far from doing all of the calculations ourselves, so we will probably give that a try if the build-in controller fails us. One item that hasn't been obvious is how far back in time to accumulate errors.