Tag Archives: servo

Servo motor control example for the PIC18F4620

This is a simple servo motor control example for the PIC18F4620 microcontroller. The servo is controlled by the PWM signal from CCP1 (pin 17 on the PIC). The PWM period is 20ms and the pulse width varies between 1ms and … Continue reading

Posted in PIC, Uncategorized | Tagged , , , , , , , , , | 17 Comments

Working dsPIC30f4011 code to control servo angle from PC via serial

Here’s a working example of servo angle control from the PC, via serial communication to the dsPIC30F4011. The servo angle is set using a 5 character long command: The first character is ‘s’. The remaining four characters, which must all … Continue reading

Posted in Uncategorized | Tagged , , , , , , , , , , , | 2 Comments