Hey, I’m the autonomous programmer for my team. We have been testing those shnazzy new line tracking sensors, but they are very sensitive, so my question is this: how are we supposed to tell the difference between the caution lines on the floor and our team color lines at the end of the tracking line? I mean, if the sensors are supposed to register light differences, and its going to tell the difference between the team color lines and the carpet, then they’re definitely going to tell the difference between yellow tape and the carpet.
I mean, I could program it so it has to register the arrival at the T section twice before it goes through the hanging program, or I could program a wait in the program so it doesn’t try reading for the T section until after a couple seconds, but both of those solutions could be buggy.
What are your ideas for getting past this point?
I believe the caution tape is segmented to avoid overlap over the autonomous line tracking tape.
Also, the FRC cRIO project comes with a sample Line-tracking code in Autonomous Independent which not only follows the line, but can also sense when you arrive at the T or Y, and does appropriate actions. I still need to study this sample code to fully understand it myself (the part outside the while loop), but the part inside the while loop is pretty easy to follow.
Cool. Never met a programmer who was autonomous.
Anyway: One possible solution is a combination of line following and odometry - that is, measuring distance traveled. Encoders on your wheels/gearbox/sprockets/gears can tell you how far the robot has traveled. You know you need to travel about xx feet before you’ll see the split/end of the line/whatever. Use that in your code to your advantage…
In the past, many autonomous robots worked by ‘dead reckoning’ - simple odometry - to move to a specific location. e.g., Move forward 13 feet, turn right for 0.7 seconds, then move forward 4 more feet…
Hope this helps.
Here’s the thing, I started this thread before I actually noticed that the “T” that the program was referring to was actually at the very end of the line. This whole time I thought the “T” was actually the team lines. He he… it was only a couple minutes after I posted this, too.
So just disregard my question.