Shop OBEX P1 Docs P2 Docs Learn Events
Please help.....servo only going one direction no matter what! — Parallax Forums

Please help.....servo only going one direction no matter what!

ArchiverArchiver Posts: 46,084
edited 2001-03-26 13:30 in General Discussion
I have 6 servo motor. They are not modify for 360 degree rotation. I
was able only to rotate in CW (clock wise) but not CCW (counter clock
wise). I have read the message post by other, but it didn't help
much. I already know how a servo operate and how to program them,
but the programming doesn't work. For examples, my HS-300 hitech
servo will be position at 0 degree at 1.5ms, -90 degree at 1 ms and
+90 at 2 ms.

if for example I want to rotate the motor CCW to -90 degree with my
BS2 I would type

for x = 1 to 300
pulsout 0, 500 'where 750 is the neutral position
pause 20
next

The sevo did not go CCW but CW. If I try any ohter pulse number like
750, 900, 100, etc. I will go only in one direction CW. Why is this?

I connect my motor to an external large 6V batteries.

Please help me out. 5 ohter people are having this problem. Thanks.

Douglas

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2001-03-25 23:06
    I don't know the specs on the servo motor you are using, but I have
    to make a couple of assumptions. I'm assuming that it is a standard
    DC motor.

    I would suggest that you verify that the motor is capable of going CW
    and CCW. To do this simply connect the power up in reverse, unless
    there is something in the specs that say not to. A normal DC motor
    will run in reverse when the current flows the opposite direction.
    Changing the pulse witdth won't affect the direction of current flow
    and therefore won't make the motor go the other way. Basically
    connect the motor directly to the battery, see if it goes one
    direction, then reverse the leads and verify that it goese the
    opposite direction.

    Normally when you are attempting to control the direction of a motor,
    you can either do it with a dpdt relay, or use several transistors,
    but you have to make the current go one way for CW and the opposite
    direction for CCW.

    Again, you need to pay attention to the specifications, because if
    the servo has internal circuitry, you may not want to reverse
    polarity on the motor. If this is the case then there should be
    something in the specs that indicate how to wire the motor for
    reverse direction.

    I hope this helps.

    Randy
    randle_lee@y...

    --- In basicstamps@y..., voltage91@h... wrote:
    > I have 6 servo motor. They are not modify for 360 degree rotation.
    I
    > was able only to rotate in CW (clock wise) but not CCW (counter
    clock
    > wise). I have read the message post by other, but it didn't help
    > much. I already know how a servo operate and how to program them,
    > but the programming doesn't work. For examples, my HS-300 hitech
    > servo will be position at 0 degree at 1.5ms, -90 degree at 1 ms and
    > +90 at 2 ms.
    >
    > if for example I want to rotate the motor CCW to -90 degree with my
    > BS2 I would type
    >
    > for x = 1 to 300
    > pulsout 0, 500 'where 750 is the neutral position
    > pause 20
    > next
    >
    > The sevo did not go CCW but CW. If I try any ohter pulse number
    like
    > 750, 900, 100, etc. I will go only in one direction CW. Why is
    this?
    >
    > I connect my motor to an external large 6V batteries.
    >
    > Please help me out. 5 ohter people are having this problem.
    Thanks.
    >
    > Douglas
  • ArchiverArchiver Posts: 46,084
    edited 2001-03-26 13:30
    If I remember correctly, you need to set the output "high" or "low" before
    the "pulsout" command. If you do:

    low 0
    ...
    ...
    pulsout 0,500
    ...

    you get a high pulse. If you do:

    high 0
    ...
    ...
    pulsout 0,500
    ...

    you get a low pulse. Try it!

    Johan Hoffsten, Vallentuna

    Original Message
    From: voltage91@h... [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=ffFKlX41G4ZF0MDGXaXFVGE2NlDxoDvOi6_sluQcyASlrL-kpmLbiGrCCyMWy-VSYQjzeZUNztgyn_gPMRI]voltage91@h...[/url
    Sent: den 25 mars 2001 07:36
    To: basicstamps@yahoogroups.com
    Subject: [noparse][[/noparse]basicstamps] Please help.....servo only going one direction no
    matter what!


    I have 6 servo motor. They are not modify for 360 degree rotation. I
    was able only to rotate in CW (clock wise) but not CCW (counter clock
    wise). I have read the message post by other, but it didn't help
    much. I already know how a servo operate and how to program them,
    but the programming doesn't work. For examples, my HS-300 hitech
    servo will be position at 0 degree at 1.5ms, -90 degree at 1 ms and
    +90 at 2 ms.

    if for example I want to rotate the motor CCW to -90 degree with my
    BS2 I would type

    for x = 1 to 300
    pulsout 0, 500 'where 750 is the neutral position
    pause 20
    next

    The sevo did not go CCW but CW. If I try any ohter pulse number like
    750, 900, 100, etc. I will go only in one direction CW. Why is this?

    I connect my motor to an external large 6V batteries.

    Please help me out. 5 ohter people are having this problem. Thanks.

    Douglas




    Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
Sign In or Register to comment.