Author Topic: Controlling Servos for 20 degree motion  (Read 2453 times)

0 Members and 1 Guest are viewing this topic.

Offline pusghatoleTopic starter

  • Beginner
  • *
  • Posts: 1
  • Helpful? 0
Controlling Servos for 20 degree motion
« on: December 16, 2008, 09:53:12 PM »
Hi all,

I am making a bipedal robot and I am using HS-311 servo from Hitec. Now this servo needs to be programmed to get a 20 degree motion from the starting point and i need to hold this servo in the same position for some amount of time say 2 sec. I am not able to write any code for this motion...can anybody please help.... or can anyone suggest some site...where i can get this.... I am using Atmega32 microcontroller...plz its urgent... :'(

Offline bulkhead

  • Full Member
  • ***
  • Posts: 102
  • Helpful? 0
Re: Controlling Servos for 20 degree motion
« Reply #1 on: December 18, 2008, 02:29:28 AM »
Some info here: http://www.societyofrobots.com/actuators_servos.shtml#control

In your case you need to experimentally verify what pulse duration (between 1 - 2ms) will result in the "start point", and also what pulse duration will result in the "start point + 20 degrees".  The code would initially send out the pulse for the start position, then send out the pulse duration for the next position (keep sending it for 2 sec).

Read up on "PWM" for servo control.

 


data_list