View Single Post
  #9   Spotlight this post!  
Unread 19-01-2015, 16:57
wildaburk3160 wildaburk3160 is offline
Registered User
FRC #3160
 
Join Date: Sep 2013
Location: Grove, OK
Posts: 50
wildaburk3160 is an unknown quantity at this point
Re: am-2816a encoder

I am using the am-2816a encoder attached to the am-2161 motor. The encoder is wired into the DIO slots on the roboRIO and the motor is being run using PWM. Right now there is no load being put on the shaft of the motor.

We want the motor's home value to be zero and to be able to rotate 90 degrees clockwise and counterclockwise and to always be able to come back to its home position. However, when the shaft returns to home position, we have not been able to get it within an acceptable tolerance of angles.

I am not using a PID protocol but am scaling down the encoder pulse values returned to determine the output of the motor. Specifically, I get the encoder pulse value, then square root it, then it is further scaled down so that the motor output can never be given a value greater than 1. So basically, as the encoder pulse value gets closer to 0, the greater the reduction of the motor output. However, even with such a reduction, the motor still seemingly has too much momentum and still over travels even when the range of encoder values we have to tell the motor to stop is very small.

I have dabbled minimally with using PID protocols and don't have a full understanding of them currently, but do you believe that a PID system would be better and more precise than the system I have described? Or would another sensor such as a potentiometer be better for our purposes?
Reply With Quote