To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.handyboardOpen lugnet.robotics.handyboard in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / Handy Board / 7173
7172  |  7174
Subject: 
Servomotor
Newsgroups: 
lugnet.robotics.handyboard
Date: 
Sat, 4 Dec 1999 05:06:26 GMT
Viewed: 
853 times
  
i'm using digital pin 9 to generate the control signal for my TS-53 servo.
however when i try to make it move, it only turns a little bit for the first
command but just stops there, the motor continues vibrating though.

the idea behind my code: set servo position to '3040', then wait 10 seconds.
After that turn to '2000', wait 10 seconds and then back to '3040'. if the stop
button is pressed, the loop terminates.

void main()
{
      fd(1);               /* turns on motor driver 1  */
      servo_a7_init(1);    /* enables digital pin 9 (Port A bit 7) */

       while (stop_button()==0)
{
          servo_a7_pulse=3040;  /*gives a 1.5 ms pulse
          sleep(10.0);

          servo_a7_pulse=2000;
          sleep(10.0);
         }

      ao();
      servo_a7_init(0);    /* disables digital pi 9
} /* end*/



please help!!



1 Message in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR