Thread: Motor Twitch...
View Single Post
  #2   Spotlight this post!  
Unread 18-01-2016, 17:41
Kevin Sevcik's Avatar
Kevin Sevcik Kevin Sevcik is offline
(Insert witty comment here)
FRC #0057 (The Leopards)
Team Role: Mentor
 
Join Date: Jun 2001
Rookie Year: 1998
Location: Houston, Texas
Posts: 3,622
Kevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond repute
Send a message via AIM to Kevin Sevcik Send a message via Yahoo to Kevin Sevcik
Re: Motor Twitch...

Quote:
Originally Posted by johnny_Bet View Post
Hello people of Chief Delphi! I'm the programmer for team 4643. We are experiencing difficulties with twitching motors. When code is disabled the motors don't twitch, leading me to conclude that it's a programming issue. I will be putting my code on github soon as well as a link to the repository but I can't right this second. Any help is appreciated!
Are you controlling your motors via PWM or CAN? Poorly wired robots can occasionally generate or pick up electrical noise that can make PWM controlled motors twitch.

If it's not electrical, then the next most popular option is commanding the motor multiple times in a control loop. As soon as you call motor->Set(x), the output is set. Calling motor-Set(0) later will largely insure that the motor won't move much since the 0 will be active longer, but it could still twitch from the momentary setting to an actual value.
__________________
The difficult we do today; the impossible we do tomorrow. Miracles by appointment only.

Lone Star Regional Troubleshooter
Reply With Quote