ROBOTC.net forums
http://robotc.net/forums/

DC Motor PID control and Sync?
http://robotc.net/forums/viewtopic.php?f=52&t=10220
Page 1 of 1

Author:  BisonBot5209 [ Fri Jan 09, 2015 10:21 pm ]
Post subject:  DC Motor PID control and Sync?

I've been having serious problems with this mini bot I built. Because it's so light, I had something added to weigh down one wheel so it would grip and actually move. However, this perpetually makes it want to grip and drift.

I haven't seen anywhere saying that you can't use PID with DC motors, but I think they need encoders? Can you use PID without encoders? If so, what else do I need to add beside the nPidUpdateInterval = 20; code?

And for Syncing, can you sync DC motors? The code says that you can "syncBC" or something like that, but my DC motors show up as mtr_S1_C1_1, which I can't put into that command. Am I missing something or is this just not possible?

Author:  BurningLights [ Mon Jan 12, 2015 11:47 am ]
Post subject:  Re: DC Motor PID control and Sync?

Yes, the only way to do PID on a motor is to have an encoder on it. Also, there is no way to have ROBOTC internally sync DC motors. The syncing functionality sadly only works for NXT motors.

Author:  MHTS [ Mon Jan 12, 2015 10:54 pm ]
Post subject:  Re: DC Motor PID control and Sync?

Regarding on using PID on motors without encoders, PID is close-loop control, so it requires feedback. Encoder is one way to give feedback to PID control but other sensors may work as well depending on the application. If it's a robot arm, it could be a potentiometer. I have tried once using accelerometer instead of encoders. It didn't work too well but it could be done if you understand the restrictions.

Author:  BisonBot5209 [ Tue Jan 13, 2015 10:00 am ]
Post subject:  Re: DC Motor PID control and Sync?

MHTS wrote:
Regarding on using PID on motors without encoders, PID is close-loop control, so it requires feedback. Encoder is one way to give feedback to PID control but other sensors may work as well depending on the application. If it's a robot arm, it could be a potentiometer. I have tried once using accelerometer instead of encoders. It didn't work too well but it could be done if you understand the restrictions.


Would you mind giving an example of this? How do you give feedback to the encoders? What kind of feedback is needed?

Author:  Darwin [ Mon Jan 18, 2016 12:22 pm ]
Post subject:  Re: DC Motor PID control and Sync?

BisonBot5209 wrote:
MHTS wrote:
I just discovered this Best CBD Oils blog so it requires feedback. Encoder is one way to give feedback to PID control but other sensors may work as well depending on the application. If it's a robot arm, it could be a potentiometer. I have tried once using accelerometer instead of encoders. It didn't work too well but it could be done if you understand the restrictions.


Would you mind giving an example of this? How do you give feedback to the encoders? What kind of feedback is needed?


Good question, how do you give feedback to the encoders?

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/