Menu Close

Arduino Sound Detection Sensor

 

Arduino Sound Detection Sensor Modul LM393

Arduino Sound Detection Sensor

Parts Required:

–  Arduino NANO v3.0
–  Sound Detection Sensor Modul LM393
–  LED (1)
–  Wires to connect it all together

 

Arduino Code:

uper

// Example by Hisham Marzouk
// Officialhrm.com

int LED = 3;
int brightness = 0;
int fadeAmount = 1;

void setup(){
pinMode (LED, OUTPUT);
Serial.begin(9600);
}

void loop() {
int statusSensor = analogRead(A1);

if(statusSensor > 800){

for(int i = 0; i < 255; i++){
analogWrite(LED, brightness);
brightness = brightness  + fadeAmount;
if (brightness <= 0 || brightness >= 255) {
fadeAmount = fadeAmount ;
delay(30);
}
Serial.println (brightness);
}
}
else{
digitalWrite(LED, LOW);
}
}

Down



Arduino Sound Detection Sensor

 

Download: Arduino_Sound_Sensor

It uses a microphone which supplies the input to an amplifier, peak detector and buffer.
When the sensor detects sound, it processes an output signal voltage which issent to a microcontroller then performs necessary processing.

 

 

For more Please make sure to subscribe to Officialhrm YouTube channel and like Facebook Page.

Thank you for visiting OfficialhrmPlease don’t forget to share this website with your friends.

 

Posted in Arduino

Leave a Reply

Your email address will not be published. Required fields are marked *