Quote:
Originally Posted by j.cole
Should this code work to get the velocity of the motor using an encoder. (See pictures they should explain better than I could). Plug that number into the process variable and see if it works. I'm going to increase the refresh rate to get a more accurate reading.
|
Does the "50" in Capture1.PNG mean 50 milliseconds? If so you are copying CurrentRotations into PreviousRotations every 50ms, which is 0.05 seconds not 0.5 seconds (as stated in Capture.PNG).
Can't you just use a feedback node to compare CurrentRotations to the previous value?