Maker Pro
Maker Pro

How I can configure an AVR microcontroller PWM to find the set point using a servo (DC ) motor?

A.L.Z

Apr 3, 2015
4
Joined
Apr 3, 2015
Messages
4
Hi .
Is there any one who can help me ?
I have a DC motor and I want to change it to servo. I just want to set PWM , using ATMGEA 8 , to access the set point and while this process , the speed may be decrease and finally the set point will be find. but I have a problem .
When I increase the PWM , the set point may be dis-match , on the other hand , one time the motor will be switch off before finding the set point and another time the motor stay on after the set point , therefore it can't find the goal correctly , Is there any one who has a source code to solve this error by PID controllers?
Please accept my apology if I can not tell you better the details.
I appreciate your kindly comments. Thanks for taking the time
 

BobK

Jan 5, 2010
7,682
Joined
Jan 5, 2010
Messages
7,682
Are you trying to control the position of a motor without feedback? If so, it is not going to work. To turn a DC motor into a servo, you have to mechanically drive a potentiometer that will be read by the micro to determine the position.

Bob
 
Top