Making Almost Anything <-> MAS.863 <-> Fall 2011
Kristopher Dos Santos <-> Personal Robots Group
Week 9 <-> The Proximity Sensor
(Sorry for the late update :( AVR programming is hard). This week, we got to play with different input devices. I had plans for my little Nova to utilize some capacitive sensing for proximity detection. But after failing in a variety of ways, I'll limit this page's notation of my endeavors to a few bullet points:
- Capacitive sensing is not perfect; resolution is a tough thing to obtain, especially with smaller electrodes.
- The TXRX arrange usually works better for smaller electrodes than a single load electrode.
- Using a higher capacitor filter helps reduce noise on the resistors when grouped closely together, and is more efficient at buffering input voltage (Brian Mayton suggested using 10.1uF instead of 1 uF).
- The bit delay time needs to be altered if an external crystal isn't being used. The internal clock can tend to get out of wack, so altering this number can make sure it's in sync. Run "rx.py", and look for Neil's signature framing pattern (1-2-3-4).
- PWM control is tough when using sensor input like this :(.
Below is a video showing what I did. I modified the hello.txrx.45.py file to do a bit of averaging on the sensor output. This gave a settled value by which to base proximity. Once I did that, I specified a certain percentage loss from the average to determine if someone was "too close" to Nova. I also specified a range that was higher than average that would detect touch. The indicators displayed in the terminal.
Back to home