Students will
- Explain how the piezo can act as either an input or output
- Capture and compare brief analog peaks
- Calibrate and test a knock event without assuming a universal threshold
Arduino Uno R3
Use the kit piezo as a vibration sensor, observe its brief analog signal, and calibrate a knock threshold from evidence.
Reviewed connection map
Read before uploading
const int PIEZO_PIN = A0;
const int LED_PIN = LED_BUILTIN;
int threshold = 100;
void setup() {
pinMode(LED_PIN, OUTPUT);
Serial.begin(9600);
}
void loop() {
int reading = analogRead(PIEZO_PIN);
bool knock = reading >= threshold;
digitalWrite(LED_PIN, knock ? HIGH : LOW);
if (knock) Serial.println(reading);
delay(10);
}Optional engineering record
Choose the prompts that help students explain predictions, evidence, debugging, and transfer. Saving creates a new entry in this browser’s Rudi notebook.
Use these prompts if they help students capture evidence, decisions, or questions. You do not need to complete every prompt or create an entry at every step.
Secure the piezo, raise the threshold from recorded evidence, and separate taps with a short quiet interval.
Verify A0, GND, the resistor placement across the piezo, part condition, and Serial Monitor timing.
2026 middle school standards
These are evidence-based crosswalk candidates for curriculum review—not a claim of official alignment.
Students collect repeated sensor readings, identify limitations, and support a threshold or response with evidence.
Lesson evidence: Knock and background reading tableohms-law · power-and-signals · sketch-foundations
Starting point, not verified curriculum. Review the actual hardware, circuit, code, power requirements, and classroom conditions.
After teaching this lesson