Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

dual PWM control of servos with 16f84

Status
Not open for further replies.

mrvanx

New Member
Hi people, bit if a random question here, ive setup a pwm program in my PIC to send out TWO pwm signals to control a pair of hitec hs300 servos. These have been modified for continuous running, they each have a potentiometer on the side.

The program works fine, it outputs a 1.5ms pulse (20ms cycle) and changes it accordingly with various inputs. Yesterday i finally got the servos connected for testing and they just do NOT stop when its set to the stop pulse (1.5ms). Could it be that since they are modified the stop position has changed? or is it more likely that i need to adjust the potentiometers so they stop when this signal is being sent??

P.S: I tried to adjust one of them it did slow down a bit but i lost my temper and gave up LOL!.
 
mrvanx said:
Hi people, bit if a random question here, ive setup a pwm program in my PIC to send out TWO pwm signals to control a pair of hitec hs300 servos. These have been modified for continuous running, they each have a potentiometer on the side.

The program works fine, it outputs a 1.5ms pulse (20ms cycle) and changes it accordingly with various inputs. Yesterday i finally got the servos connected for testing and they just do NOT stop when its set to the stop pulse (1.5ms). Could it be that since they are modified the stop position has changed? or is it more likely that i need to adjust the potentiometers so they stop when this signal is being sent??

Yes, you need to adjust the potentiometer so it stops at 1.5mS - the pot sets the zero point.
 
It can be difficult to get a servo to stop completly when you do that, especially if your PIC is running off of an internal RC because the clock drift at different temperatures will cause the PWM width to vary enough to cause it to start again. I'm not sure if there's any way to tweak a servo's dead band to prevent it from happening, but at the very least you're going to need to hot glue the pot knob down otherwise vibration alone might cause it to move a bit.
 
Yer the POT is literally adjusted with a screedriver and it fairly solid, i didnt have a screwdriver to hand when i was playing with them and used a pair of pliers which wasnt too good (which is why i lost ma temper hehe).
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top