Using two microphones, give your SegBot the ability to track a low frequency emitter in a room! With the Electret microphones and a band pass filter, the SegBot identifies frequencies between 100 to 200Hz and tracks the emitter through the sea of sound waves bouncing throughout the area. The system is accurate to distances 1-3m (10ft) depending on the acoustics of the environment.
Attach a microphone to the left and right side of your SegBot, the further apart the better. Though I didn't experiment with mounting the microphones at different heights, there may be merit in doing so depending on the floor's texture. Next construct an arena or grid on the floor with masking tape. The arena can be any shape, but should be at least one square meter large. This will be important for calibrating your SegBot to the environment. With this quick setup, and a simple driving algorithm (take a look a the commented code), you can begin to tune your SegBot. Start with the motors off to prevent interference from motor sound (we'll go over how to account for motor sound more later).
Place the SegBot at the origin of your arena with your emitter at the closest nearby node. Start emitting a 150Hz sine wave from your emitter at the lowest volume and take a look at the serial readings from your SegBot. Experiment with the volume of the tone and get an idea for how the volume translates to serial readings. Identify the lowest volume at which the SegBot picks up sound as well as the volume at which the microphone readings start to saturate. With these values in mind, start placing the emitter at different nearby nodes and continue the experiments.
Depending on these values, weight your left and right microphone readings to be able to accurately identify the emitter position based on the data. These weight calibrations are integral when optimizing the driving algorithm to the environment. Now turn your motors back on and test your new driving algorithm out with your emitter on the arena.
Improving the weight calibrations becomes even more important once the motors are turned on. As you might have noticed, whenever the SegBot begins to pick up speed, the motor sound interferes with the microphones and the SegBot hesitates along its path. Without careful calibration, the SegBot is prone to going off path and has to tediously reorient itself. Nearby obstructions and walls can also interfere with SegBots ability to judge the origin of the sound waves. These challenges can be accounted for with overlapping conditional statements in the driving algorithm and by capping the maximum acceleration of the motors. The changes may limit the tracking speed of the SegBot, but they each help improve the success rate of the overall system.
Once your SegBot has mastered the arena, test it out in different environments and at larger ranges! You'll find the acoustics of the room to be limiting to the performance of the SegBot but in many ways its like watching a living organism navigate an environment. There is plenty of room for improvement with the driving algorithm and setup that could allow for more universal use of the system, but perhaps that's not its most useful application.
With some simple reconfigurations, the SegBot could be made to track not the emitter of the low frequency tone, but instead any obstacles interfering with the acoustics of said tone. Similar to echolocation, this system would allow the SegBot to track both stagnant and moving foreign obstructions through a known acoustic environment by tracking changes in the sea of sound waves!
A special thanks to Dan Block for the SegBot and TI for their F28379D Launchpad board. The board's great sampling and computing capabilities made the entire system possible!
Comments
Please log in or sign up to comment.