Skip to content

Instantly share code, notes, and snippets.

@velophonic
velophonic / velophonic_wheel.ino
Created November 29, 2016 12:38
Arduino code
/* Knock Sensor sound
This sketch reads a piezo element to detect a knocking sound.
It reads an analog pin and compares the result to a set threshold.
If the result is greater than the threshold, it writes
"knock" to the serial port, and toggles the LED on pin 13.
This example plays every .WAV file it finds on the SD card when piezo is "knocked"
*/