View Single Post
  #6   Spotlight this post!  
Unread 07-02-2012, 15:59
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,065
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Shooter PID loop

Quote:
Originally Posted by j.cole View Post
@Ether You can't simply put the encoder into the PID process variable you have to find the speed of the motor using the encoder and put that into there. Correct? Unless I'm missing something.
You have to scale the process variable (the encoder signal) and/or the setpoint so they have the same range and offset.

Examples:

If your process variable (encoder signal) has been scaled to represent RPM, then you have to scale your setpoint so it also is in RPM (and not, say, -/+1).

Or you can do it the other way. If your setpoint has been scaled so that it has the value +1 when you want MaxRPM, and it has the value -1 when you want -MaxRPM, then you should scale your encoder signal so that it outputs +1 when the device it is measuring is spinning at MaxRPM, and it outputs -1 when the device it is measuring is spinning at -MaxRPM.


Last edited by Ether : 07-02-2012 at 16:07.
Reply With Quote