There seems to be evidence that one of the two gear tooth sensors (GTS) sent in the FIRST KOP may be bad. We had one that worked and another that didn’t. Autonomous accuracy is very important to our strategy this year so we HAD to have good tracking on both sides of our drive train.
As of this writing, I am not aware of any replacements available for the GTSs sent in the KOP. So we set out to adapt a low-cost COTS GTS to the Andy-Mark gearboxes. This thread explains how we did it.
I’m telling this story now because as of today we verified that the implementation was working well and we have the accuracy predicted in the mathematical analysis. We considered encoders, but to mount them requires more tricky mechanical linkages and parts.
The sensors are Honeywell model 1GT101DC. They are available from DigiKeyfor about $25. All you need is one PWM cable and a 5K-ohm resistor to connect it to the robot controller. The signal lead needs to be connected to the +5VDC lead via the resistor (pull-up for the sensor’s open collector output). Software for reading the sensor’s output can be found in this thread.
The sensor outputs a digital high level when it does not detect a ferrous object at its tip. When a ferrous metal is sensed at the tip it pulls the output low. (Therefore it can also be used as a limit switch!) Generally we mount the sensor 0.5 to 1.5 mm away from the gear or sprocket teeth. You can find the optimum distance by observing the output on an oscilloscope; tune for a 50% duty cycle when the gear/sprocket is rotating rapidly. An advantage of this setup is that you can quickly remove the GTS at the competition to clean off debris that tends to collect on the magnetic parts (gear tooth filings).
Of course mounting them into the AM gearboxes requires some effort, but it is manageable if you have a drill press. We drilled a hole in the “top” of the gearbox as show in pictures 1 and 3. The main hole was drilled directly above the gear so that the sensor will point directly at it. A smaller hole was drilled and tapped for a 1/4" bolt used to secure the sensor to the gearbox. Add a spacer and you have a secure mount as shown in pictures 4 and 5. Adjusting the length of the spacer allows you get the sensor-to-gear distance just right.
You will notice a few things:
-We machined a replacement aluminum plate for the gear box to allow us to more easily mount it to our chassis. Our chassis is made from ITEM brand extrusion which allows quick and easy construction, adjustment, and excellent maintainability.
-The GTS is sensing the high-speed 50 tooth gear that is driven by the CIM motors. This gives us more resolution in distance measurement. Currently we see 0.07 inch-per-tooth resolution using this setup and a 15/22 tooth sprocket ratio driving 6 inch wheels.
-Picture 6 shows our controls breadboard. We have been able to develop our autonomous code without the need for a rolling robot using this arrangement since kickoff. Today we moved the controls to the chassis for the first time and were able to show precise autonomous movement forward and in turns. The team was amazed at the accuracy, and frankly so was I!
So that’s it. I hope to put this thread on the gearbox GTSs to rest. Hopefully FIRST (or someone else!) will make the KOP GTS boards available for purchase so teams can replace their faulty ones. Until then we are moving on to develop our autonomous and robocoach strategies.
Good luck teams!