Shop OBEX P1 Docs P2 Docs Learn Events
Continuous Servo motors — Parallax Forums

Continuous Servo motors

debonenedebonene Posts: 19
edited 2009-10-26 01:47 in BASIC Stamp
Am having problem with my continuous servo motor using the bs2 board as the interface for the program code. The code is suppose to rotate only from 0 to 180 degrees (back and fort) on one position but it keeps adding up in bits till it makes a 360 degree turn in groups of 180 degrees. pls view my attached code and see if anyone has any modifications·or ideas on how to program a continuous motor to rotate 180 degrees. Thanks

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2009-10-21 22:12
    You can't do it.

    The way a continuous servo motor is made is to disable the feedback mechanism in a standard servo that allows it to be repositioned fairly accurately to the same position repeatedly. The only way to move a continuous motion servo back and forth is to move it at a specific speed for a known amount of time over and over again. Unfortunately, the speed control and the timing cannot be done accurately enough to consistently reposition the servo to the same position.

    The only way to do this sort of movement is to go back to using a standard servo. You can buy some with extended motion (greater than 180 degrees). Some sold as winch motors for sailing ship models will turn 2-3 turns with control pulses over the 1-2ms range.

    Another alternative is to use a wheel encoder that allows you to determine the wheel's position accurately and use that to stop the motor at a particular position.
  • debonenedebonene Posts: 19
    edited 2009-10-21 22:15
    Thanks Mike Green and how do i get the wheel encoder?
  • Mike GreenMike Green Posts: 23,101
    edited 2009-10-21 22:22
    Parallax has a simple one designed for use with the BoeBot: www.parallax.com/StoreSearchResults/tabid/768/List/0/SortField/4/ProductID/80/Default.aspx?txtSearch=wheel+encoder.

    As another example, their Motor and Wheel Kit has a position encoder used with the position controller: www.parallax.com/Store/Accessories/MotorServos/tabid/163/CategoryID/57/List/0/Level/a/ProductID/507/Default.aspx?SortField=ProductName%2cProductName.

    You could also do a web search for "wheel encoder" and you'll get a lot of robotics suppliers and some tutorials on how they work and how to use them.
  • debonenedebonene Posts: 19
    edited 2009-10-21 22:25
    Thanks Mike Green
  • JDJD Posts: 570
    edited 2009-10-22 04:23
    Debonene,

    If you are looking for the action of moving back and forth here is something that should help. You can set the servo to a known position and with some fine tuning in the code you can simulate a·sweep from·0° to 180°

    If that doesn't work, you can always look at the products Mike suggested.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Respectfully,


    Joshua Donelson
    www.parallax.com
  • debonenedebonene Posts: 19
    edited 2009-10-25 23:45
    Hi Please can anyone help me with a code that can rotate a continuous servo motor from 0 - 180 degree and 180 to 0 degree precisely without the counter adding one each time. Thanks
  • debonenedebonene Posts: 19
    edited 2009-10-25 23:47
    i.e -



    0 -- 180 degree ( clockwise)

    180 -- 0 degree ( Counter clockwise)
  • Mike GreenMike Green Posts: 23,101
    edited 2009-10-26 00:50
    Again, you can't do it. You have to use a standard servo or a wheel position encoder.
  • PropabilityPropability Posts: 142
    edited 2009-10-26 01:47
    Maybe have a micro switch that is activated at the 90 deg position.That way you will have a reference to "home". Or just use the switch (in your case being 180 deg) as the limit of travel.
    ·
Sign In or Register to comment.