3 Simple Ways to
Share What You Make

With Instructables you can share what you make with the world — and tap into an ever-growing community of creative experts.

PhotosPhotos

Share one or more photos of a project, recipe, or whatever you've made, quickly and easily.

Step by StepStep-By-Step

Share your step-by-step photos with text instructions of what you made so others can do it too!

VideoVideo

Share your how-to video. You'll need your embed code from a video site such as YouTube.

Use a PIC Microcontroller to Control a Hobby Servo

Step 6Aside: Power Issues

I've run two or three small servos and a PIC off of a line-powered USB connection before, so there shouldn't be any issues using the same power supply for the servo and the logic. However, if your servo isn't as powerful as you know it should be or your PIC keeps randomly resetting or even breaking, these are indications that you have power issues. It might mean that your power supply can't source enough current or can't deal with the rate at which the current through the servo changes or that the servo is polluting the power lines with back EMF noise. Possible solutions include using a separate power supply for the PIC and for the servo (they'll have to have a common ground because that's the reference for the control signal), getting a beefier power supply, or making the decoupling capacitor (between pins 19 and 20) a little bigger.

I honestly don't know what best practice is in terms of decoupling and avoiding ground loops and such, but it's something I'm interested in. Can some one help me out here?
« Previous StepDownload PDFView All StepsNext Step »
2 comments
Aug 15, 2006. 11:34 PMofflogic says:
re: best practices: 1. Don't count on a higher level language like 'C' to execute quickly. If you have a deterministic time-frame in the millisecond domain, use assembler (c'mon, it's easy and deterministic, and doesn't eat up 50K for a 'HELLO WORLD' demonstration). 2. Nothing less than a 0.1uF cap across the supply pins of every device, placed right next to it. 3. The USB specification defines a unit load as 100mA, so watch out for your power demands, especially the little power spikes. Per 2 (above) more capacitance will help average these out. 4. Great Instructable!
Aug 6, 2006. 8:50 PMRelativity says:
Thanks for making this. Have dealth with servos before but you go pretty in depth. Understood most of it. Keep up the good work!

Pro

Get More Out of Instructables

Already have an Account?

close

All Steps Viewing
View all steps of an Instructable on the same page when you're a Pro Member.

Upgrade to Pro today!
2
Followers
1
Author:dtydc