Local Positioning System DEMO
- Ultra sonic ranging
The demo setup shows the current project status. We use the transmitter and receiver made in Boston in january, and have a shortcut/hacked assambly code made for the demo based on the "original" code from Boston.
- Transmitter
This was the TX13 board, schematic and assambly code. The board sends out 25kHz bursts consisting of 50 pulses. Time between pulses is approx. 1 ms, timed with counter0 and interrupt.
- Receiver
The RX1 board, schematic and assambly code give a "almost perfect" sonar ranging for 0-120 cm. This number is put through the serial cable using Neils usual printing stuff.
The board is actually not very good at all, and we have (instead of making a new board!) tried to hack the assambly code to give some approximate length results. Detection is done using the "slow" ADC on the tiny 15 microcontroller (uC), and we implemented a 4 (prepared for 8) point averaging routine in assambly.
The main problem with the detection, is that the threshold level is hard to set. Instead of using a constant threshold, we inplemented (at first a software bug!) a decreasing level based on the earlier sampling. This actually corresponds well to the decreasing power as the distance between transmitter and receiver increases, but a extra short hack was needed to provide a almost linear behavior in the length 0-120 cm. Note that the uC clock is timed slower than 1.6MHz, and only one counter is used, to give out cm directly through the serial communication.
Yngve, 15. aug. 2005.
edit