Shop OBEX P1 Docs P2 Docs Learn Events
IR distance changes - please help!!! — Parallax Forums

IR distance changes - please help!!!

jessejesse Posts: 1
edited 2005-06-14 18:03 in Robotics
I'm working on the FollowingBoeBot program and I have all the code right and it works exept it's very jumpy, it twitches trying to keep the correct distance from an object. I went to the appendix G: Tuning IR distance Detection and ran the FrequencySweep program and modifyed it to continue giving me the responce at each frequency. When I had the Boe Bot just sitting there in front of the white box it came in, like 6-8 inches away, it will randomly change the "YES" and "NO" at different frequencys, with no pattarn. I checked for interference and there was none, so I don't know what to do. How can I steady what frequencys it dectects and doesn't detect? Thank you for taking the time to read this, please help me, i want this to work, so I do cool stuff with it.

Comments

  • Russ FergusonRuss Ferguson Posts: 206
    edited 2005-06-14 13:07
    Jesse:

    It sounds like you are doing the same thing that I did.

    Andy was very helpful and told me that "appendix G: Tuning IR" was not a useful exercise for improving the performance of the FollowingBoeBot program.

    My class did FollowingBoeBot with 5 Boebots and they all did the "twitch". We found that the "twitching" added a "cute" factor to their behavor. The program worked great and provided us with 5 little lemmings.

    Russ
  • edited 2005-06-14 18:03
    The way to get rid of the twitching is to keep a running average of the distances. Try applying the integral algorithm introduced in the Stamps in Class forum PID Control Intro to your distance measurements.
Sign In or Register to comment.