Thursday 22 March 2012

HOW TO CONVERT DC MOTOR INTO SERVO MOTOR

Working with servos is a bit costly so i all ways think about conversion of a ordinary DC motor into a servo motor.in a servo motor it consists of a rotatory encoder connected to the shaft of motor for position feed backall optical rotatory encoder are a bit costly. in my looo.....ong search of a cheep encoder i found one
guess what??????????????????????
                                                   POTENTIOMETER(POT) 





all of us familiar with this potentiometer.which act as a potential divider between three points.
it consists of three pins.the resistance between pins 1 and 3 is constant. but if we rotate the shaft then resistance between (1,2) or (2,3) varies.the center pin some times referred as wiper.    


   MAKING:
  take a10k pot and solder three wires to it as shown in the picture 


BLACK== GND, BROWN == O/PRED==Vcc

FOLLOW THE IMAGES































































OVER ALL BLOCK DIAGRAM


















PSEUDO CODE LOGIC:

main()
{
   config adc;

  config motor control pins;
 
   while(1)
  {
     read adc of control pot;
    read adc of motor pot;
    if(motor adc > control adc)
       motor forward;                            // could also be back ward
     else if( motor adc < control adc)  //the idea is to turn motor in direction than neutralizes                           motor back ward ;                    //error  between motor pot value and control pot value
     else
       motor stop;      // if no error motor stop
   }

}





9 comments:

vamsi said...

gud man bt sml thng its gng opposit of pod man make change

VAMSI DANDA said...

sir
that is simple sir that can be achieved by interchanging the Vcc and GND of POD

Anonymous said...

hello. could you post the code to program the atmega?

Dinesh Vyas said...

good it helps a lot

Unknown said...

wheres code?

Unknown said...

Good afternoon. can you post code for atmega please:)

Unknown said...

this guy is showing off his not posting no code or communicating with this his followers

Unknown said...

sir i need a help
i want to just convert a servo motor as, there will be two motors connected to the servo control board and if the servo goes up 1st motor will rotate in any direction and when the servo goes down the other one , the 2nd one , will rotate in any direction

Fasaz said...

Can u please post the code

Post a Comment