Shop OBEX P1 Docs P2 Docs Learn Events
QTI Sensors making boe-bot movement jittery — Parallax Forums

QTI Sensors making boe-bot movement jittery

Al MericaAl Merica Posts: 3
edited 2006-02-20 16:33 in BASIC Stamp
I recently acquired several qti sensors and mounted them on by boe-bot. when I run the boe-bot the movement is very jittery. Did anyone ever run into this type of issues? Have any suggestions?


-Almerica

Comments

  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2006-02-20 14:38
    A lot of times the Boe-bot becomes jittery if you take too much time away from the sub-routine that services the servos. Essentially, while you are doing one-thing, you are not doing the other. The servos are waiting, so it appears as jitter.

    The best solution [noparse][[/noparse]if you plan to really load the Boe-bot with extras] is have a second processor: one is dedicated to motion and the other is dedicated to navigation. When ever navigation concludes its chores, it can redirect the motion processor. The motion processor would merely drive the motors in most cases.

    You might add a quick response to collisions and dropoffs on the motion processor's circuitry as the navigation sensors may overlook such factors. These would merely cause a back up and turn routine. Then control would go back to navigation.

    Communication between the two can be RS-232 serial, but in many cases just having 4 pinouts indicating left, right, forward, reverse might be more efficent and less of a challange to write the software. This might be gotten down to 2 or 3 pins through thoughtful programing.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "When all think alike, no one is thinking very much.' - Walter Lippmann (1889-1974)

    ······································································ Warm regards,····· G. Herzog [noparse][[/noparse]·黃鶴 ]·in Taiwan
  • Al MericaAl Merica Posts: 3
    edited 2006-02-20 14:42
    What about if I was to buy a Sumo-Bot from parallax, Would the bot have the same jittery motion because it only has 1 processor?
  • Steve JoblinSteve Joblin Posts: 784
    edited 2006-02-20 15:36
    Yes... the trick is to keep track of how much time you are spending doing other things in between each pulse to the servo...

    lets say that the servo needs a pulse every 20 ms...· your program would look like this:
    pulse_servo
    pause 20
    goto pulse_servo

    Now supose that you want to read a sensor that takes 5 ms to read the device and process the logic... your program would look like this:
    pulse_servo
    read sensor and determine what to do (this will take 5 ms)
    pause 15
    goto pulse_servo

    get the idea?
  • JonathanJonathan Posts: 1,023
    edited 2006-02-20 16:22
    Almerica,

    One slim possibility for you to check...

    I once got a batch of QTI's that had a .1uF cap instead of a .01uF cap mounted on them. It was an accident when they were assembled. The cap on the QTI should be marked 103, if it has a 104, that is the problem. The larger cap means the sensor takes much longer to read.,

    If not, it's probably that you are taking too long to refresh the servos. Remove some code and see if it gets better. If you have access to an oscilloscope, you can look and see if the refresh rate is higher than ~ 20mS.

    Jonathan

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
  • Al MericaAl Merica Posts: 3
    edited 2006-02-20 16:33
    OK, Thanks everyone. I will try these suggestions tonight and get back to everyone tomorrow.
Sign In or Register to comment.