Capacitive touch piezo buzzer
This project demonstrates how to set up capacitive touch sensing and simple piezo tone generation.
Here's a little Fritzing diagram that recreates Paul Badger's capacitive touch sensing tutorial on the Arduino website. I found the wiring description a little hard to follow, so hopefully this format will help others include this simple actuator in their projects.
Components
- Arduino UNO (others probably work too)
- Piezo like this one
- 1M resistor (or higher)
- jumper wire
- breadboard
Instructions
- Wire the circuit as shown in the diagram.
- Download and install the Capacitive Sensing Library. (thanks kmiddleton!)
- Upload the code to the Arduino.
- Touch your finger to the resistor leg closest to pin 6. This should casue the piezo to beep.
- If you'd like to change the touch sensitivity, open the serial monitor while the Arduino is running this program.
- Touch the resistor/antenna and note the floor/ceiling of the corresponding numerical reading.
- Edit the sensorTrip variable in the Arduino code.
Notes
- Badger talks about adding small capacitors but I couldn't get this to work. Check out his tutorial and see if you can figure it out!
- Higher resistor values = more sensitivity. At the upper ranges you can get the antenna to sense at a distance, even through an insulator like paper or tape.