Participating in the Parallax Expo LFO (Line Following Open) 2012
The LFO only had 3 robots, 2 that competed, 1 that could line-follow and respond to predefined map. That 1 was my StringRay. I won by default - but a win is a win so I will take it!
Robot:
Sensor:
Prop Objects:
Theory of Operation:
Mapping Logic:
Daniel provided a course lay out prior to the event. The course had all kinds of intersecting lines and funny patterns to deal with. This was not going to be a straight line and you are done kind of run.
To stub out the program I color coded the different intersections to make it easier to align methods. Contestants were allowed only a small amount of time just prior to the official run to setup the logic for following the map. The blue line was the actual course, the black line is what I practiced with. To recap - the course was posted before the event, the actual path to follow was given just prior to participating in the event.
LESSONS LEARNED:
OTHER NOTES:
I didn't run the video transmitter during the event. Good thing because after I tried to repeat the run with the TX on, it wasn't working. To much interference with the sensor.
The course was suppose to be black top. We found that it was really gray top given the condition of the aggregate. A few very white (near reflective) rocks close to the silver line had to be covered in black tape or sharpie marker.
WRAP UP:
Over all it was a lot of fun. It got me a lot more comfortable with SPIN and back into micro controller programming. I combined the winnings with what I had planned to spend at the Expo to get an Elev-8 and some sensors. Built the Elev-8 over the past week, flew it - had a blast. Now I am looking at advanced line following, GPS tracking and perhaps hacking Elev-8 for a 3D experience.
Thanks Parallax - I hope this contest will be back next year!!
Robot:
- Parallax StringRay chassis
- Parallax MSR-1 Propeller control board (now discontinued)
Sensor:
- Parallax line following kit with 8 IR sensors and on-board adjustable PWM driver
Prop Objects:
- 582 - Stingray Motor Control (modified by me)
- ### - IR Line Sensor (new object by me, needs clean before OBEX posting)
Theory of Operation:
- Detect line, adjust motors (left %power, right %power) base on line input to keep line in center. If off line continue with prior sensor reading.
- Detect line conditions; e.g. T-intersection, Right-intersection, Left-intersection.
Mapping Logic:
Daniel provided a course lay out prior to the event. The course had all kinds of intersecting lines and funny patterns to deal with. This was not going to be a straight line and you are done kind of run.
To stub out the program I color coded the different intersections to make it easier to align methods. Contestants were allowed only a small amount of time just prior to the official run to setup the logic for following the map. The blue line was the actual course, the black line is what I practiced with. To recap - the course was posted before the event, the actual path to follow was given just prior to participating in the event.
LESSONS LEARNED:
- Don't mess around with the robot that will be competing at the Expo. I was demoing the 2.5 Watt video transmitter and RC Teleop function when I broke the gear box. Stripped out 2 gears. OUCH. Being that it was STOCK Parallax parts, I bought a new one, did some field repair and I was back in business. Problem was I had tuned some method timings based on the old motor - old and new weren't performing the same...
- Encoding would be nice.
- Bring more tools then I thought I would need.
- Bring water, was out in the back in the full sun most of the afternoon tweaking things within the code.
- Test more consistent conditions as the course. I used electrical tape for function testing. Worked great. My logic was backwards compared to the actual course. If the silver line was under a sensor, it would register a '0'. At home, if the black tape line was under a sensor, it would register a '1'. So when I arrived to test, I quickly had to reverse all my code. Next time I am going to build that logic function switch into the code. I also had to adjust the PWM freq on the sensor to pick up the difference in the type of line.
- Be prepared adjust clearance on sensor. The Parallax stock line follower kit has a spacer that gets the sensor nice and close to the ground. On the course, pebbles would get stuck or the sensor would rub on the tape damaging the course. Raised it up a little, no more issues.
- This event drove a lot of interest. Next year I am going to prepare a poster board with the theory on it in hopes of getting more people interested. Met a lot of great people while explaining what I was doing hunch over the laptop.
- Get power for laptop
- Have a separate program ready for just debugging.
- Develop a audio based debug method. I couldn't see the LED that I was using. I tried to add a buzzer before, but I didn't have time to tweak it.
OTHER NOTES:
I didn't run the video transmitter during the event. Good thing because after I tried to repeat the run with the TX on, it wasn't working. To much interference with the sensor.
The course was suppose to be black top. We found that it was really gray top given the condition of the aggregate. A few very white (near reflective) rocks close to the silver line had to be covered in black tape or sharpie marker.
WRAP UP:
Over all it was a lot of fun. It got me a lot more comfortable with SPIN and back into micro controller programming. I combined the winnings with what I had planned to spend at the Expo to get an Elev-8 and some sensors. Built the Elev-8 over the past week, flew it - had a blast. Now I am looking at advanced line following, GPS tracking and perhaps hacking Elev-8 for a 3D experience.
Thanks Parallax - I hope this contest will be back next year!!
Comments
I'm happy with second place, considering the relative amount of effort and expense...
If it was really black top, I might have put up a better challenge. As it was, I'm glad my bot followed any of the lines for a while...
The grey surface cause my bot serious grief...
Maybe next year I'll be better prepared...
I'm actually very glad you were there. It would have been a very, very sad competition without you. It would have been very emberrassing in front of all the kids...
At least they got to see one bot do well...
Not sure if modulation would help...
Having Parallax show us the way is a good idea though. I think next time I'd like to see Parallax show us a bot that can complete the course
I am already planning for next year. Will have some additional hardware and better software to knock out the whole thing and do it fast! Will knock it out and will have a presentation if anyone wants to hear it
ms