Sound Sensor

In this project, you'll learn how to use a sound sensor to detect sound.

Parts needed:
  • Arduino
  • A sound sensor
  • Wires
Sound sensor     
1 Making the connections
  • Connect VCC on the sound sensor to 5V on the Arduino.
  • Connect GND on the sound sensor to GND on the Arduino.
  • Connect OUT on the sound sensor to pin 6 on the Arduino.
2 Create a new Bare Minimum program and type in this program.
void setup() {
  pinMode(13, OUTPUT);
  pinMode(6, INPUT);

void loop() {
  int s = digitalRead(6);
  digitalWrite(13, !s);
4 The internal LED connected to pin 13 on the Arduino will turn on and off just like the LED on the sound sensor.