0
\$\begingroup\$

I'm trying to create a servo drive function on an ATMEL microcontroller without using the built in PWM functions. Basically just with the ISR timer.

My question is... what is the general resolution for Hitec (or Futaba) servos. Is it 10 degrees, 5 degrees, <1 degree? What would be a realistic upper target for my timer's resolution, for it to be robust for most servos?

Assuming a 180 degree rotation servo (1.25ms for 0, 1.5ms at 90, and 1.75ms at 180), I would have 500us for 180 degrees, or 2.779us per degree at 1 degree of resolution. For a 20MHz clock, I would have 50ns per clock cycle or 55.58 clock cycles per degree of resolution.

This would be quite a burden if peripheral processes were running and I'm wondering if I need to increase the CPU speed or if the resolution is even appropriate (too high or low).

For applications, this is rather open ended as I'm trying to build a tool for a myriad of open robotics projects but I would say it should be comparable to the Lynx Motion SSC-32 (http://www.lynxmotion.com/p-395-ssc-32-servo-controller.aspx).

\$\endgroup\$
  • \$\begingroup\$ Keep in mind that these servos usually have a several microsecond dead band. \$\endgroup\$ – Matt Young Feb 2 '16 at 16:43
  • 1
    \$\begingroup\$ If you are trying to drive multiple servos concurrently keep in mind how low the duty cycle is (1-2ms high, 18-19ms low). You can switch between servos every 2 ms, giving a pulse to each one in turn, allowing you to spread the CPU load over a longer timeframe. This also allows you to control up to 10 servos precisely even when their positions are close to each other. \$\endgroup\$ – jms Feb 2 '16 at 20:20
1
\$\begingroup\$

I used micro servos and their resolution was between 1 and 2 degrees. When I stepped them in 1 degree steps not all steps generated motion, but 2 degree steps did.

\$\endgroup\$
-1
\$\begingroup\$

The PCM servo drives I have come across have used 10 bit (1 part in 1024) resolution, as being 'much better' than the mechanical resolution of any servo they are likely to be used on.

Mount a mirror on your servo shaft, and use a laser pen to investigate the repeatability with backlash of your servo (or look up the manufacturer's specification (better still do both)). I doubt it will perform better than 1 degree.

Once your drive resolution is a few times better than that of the servo, you can regard it as perfect.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.