Sensor alignment

By | March 29, 2008

IMG_2514 For consistent results, the sensors on a micromouse need to be carefully aligned and then fixed in place. In a perfect world, the emitters would all have the same radiation pattern and would generate the same amount of illumination for a given current. Well, that is never going to happen without hand-picking the devices. That would take a long time so we make do with what we have and work around their limitations. Similarly, the detectors have variations to cope with as well. The first step is to get the emitters lined up and pointing where they should…

A small section maze – well, one square, is set up on the bench for the alignment process. Simple jigs and lines drawn on the floor allow the mouse to be positioned exactly and repeatably in relation to the walls. On the walls a series of pencil marks show where the emitters should have their beams pointing. To detect the IR beams, I have a cheap webcam modified to allow it to respond to IR light. This is an easy adaptation in many webcams and just involved removing a filter and replacing it with a material opaque to visible light but transparent to IR. If you still have some old floppy disks handy, the recording film on those is good for that.

The converted camera is actually too sensitive and produces very poor pictures so a bit of fiddling is needed to get good results. A much better alternative would be a handy-cam like some of the Sony types that can be set to respond to IR.

Cam00005 To help see where the IR is falling, small circles of black paper are placed over the points where the beam should lie. These reflect much less light than the walls and makes it much easier to see with the now over-sensitive camera. To an extent, you can also use the black disks by aligning the emitters so that a minimum of light is reflected to the detectors. If the disks are the right size for the emitter pattern this can be quite reliable but the camera is better.

Once the emitters have been lined up, they are fixed in place with epoxy glue. You really need to get this right. Changing things later is not an easy option. Try not to burn out an emitter!. The emitters on Decimus are well shielded from the detectors. Even so, it is a good idea to put a short length of heatshrink tubing around them as that will make it a bit easier to replace them later if necessary.

With the emitters aligned, the detectors can be moved about to give a reasonable range of results. The sensors are arranged in pairs but it is very unlikely they will give closely similar responses so some software compensation will be needed. This can be simple threshold values or complete look-up tables. Don’t however get to tied in to the values that work for your particular maze walls. Remember that the mouse will have to work in any maze under a variety of lighting conditions.

Leave a Reply