IR and Ping
Hi Guys,
I am trying to build an accessory for my Boe Bot. I have made a panning gizmo for the front of my Boe Bot and I would like to use IR for roaming but I would like it to work just like roamimg with Ping. My problem is that I am more of a machinist then I am a programmer. Has anyone written any code to substitute the Ping sensor code with IR distance code to make their Boe Bot behave just like it does with "roaming with ping"? I think this should work if the IR side sensors are pointed down and back·about 80 degrees from foward( this should keep the panning IR assy from picking up IR from side IR emitters). When I look at the code for roaming with ping and the code for figuring distance with IR zones I get that helpless feeling when I try to combine the 2 codes to get a working code. If anyone out there with alittle more programming brain power then I can muster up would like to share their thoughts on this I would be grateful.
Thanks
Tom
I am trying to build an accessory for my Boe Bot. I have made a panning gizmo for the front of my Boe Bot and I would like to use IR for roaming but I would like it to work just like roamimg with Ping. My problem is that I am more of a machinist then I am a programmer. Has anyone written any code to substitute the Ping sensor code with IR distance code to make their Boe Bot behave just like it does with "roaming with ping"? I think this should work if the IR side sensors are pointed down and back·about 80 degrees from foward( this should keep the panning IR assy from picking up IR from side IR emitters). When I look at the code for roaming with ping and the code for figuring distance with IR zones I get that helpless feeling when I try to combine the 2 codes to get a working code. If anyone out there with alittle more programming brain power then I can muster up would like to share their thoughts on this I would be grateful.
Thanks
Tom
Comments
·
Thanks for the tip. I would like to do exactly that with a panning servo to pan area with 1 IR pair just like the roaming with ping sensor. In the roaming with Ping code the Boe Bot moves forward and when the ping sensor senses an obstacle it will stop and pan area, gather information about which is the clearest path then the Boe Bot will turn in the direction of clearest path and go forward. If I could, I would love to get my Boe Bot to do the same with 1 IR pair in place of the Ping sensor on the panning servo. The reason I like the way this works is because it illustrates visually that the Boe Bot is looking around for a clear path. Any kid who sees this working will know that The Boe Bot is trying to make a decision, as opposed to just stopping and turning based on ( unseen by us humans) IR signals only.
Tom
As the author of the Roaming With PING))) code I can tell you that I actually rewrote it after trying to do what you describe. I actually had the code working for the most part too. Here’s is why I changed it…In a few rare instances the PING))) would be approaching a table leg or corner at just the right angle and not see it while rotating the opposite way. By the time the PING))) rotated back to the left it was already hitting the corner at a steep angle and would roll over. It’s kind of hard to describe this. My first thought was to speed up the PING))) panning speed. I found there is a practical limit to this which still wasn’t fast enough. My next idea was to slow the wheels down. This worked but in order to make it consistent the wheels were so slow that the BOE-Bot took forever to cross the room. Finally I decided to mimic the Roaming with IR but give the BOE-Bot the ability to pick the clearest path.
Dave in Tech Support created a code called the Duck Bot which does pan the PING))) while moving. It doesn’t use IR so it does suffer the same potential problems my original code did, which is why I abandoned it, however if you would like to try it we can post it. Take care.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
I would be interested in the Duck Bot code. I am in the initial steps of setting up my Boe-bot as a maze solver using a Ping on the bracket as the sensor.
Ron
Dave
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Dave Andreae
Parallax Tech Support
Thanks for the code. I'll try to work with it today.
Ron
Thanks for the tips and code. I have been away from the puter for a few days. I have been in the shop engineering my exstreme Boe Bot.
Check out Boe Bot Mattracks Post.
Tom
Post Edited (T0m) : 3/22/2007 11:52:58 PM GMT
Dave
Update: I got the Quack code to work I had to change the servo freq values to get the servo to work properly but I didn't change the condition for the if else loops. problem solved.... for now.
Post Edited (Dgswaner) : 3/26/2007 1:56:17 PM GMT