Christine Jacinto
Published

Lane Tech HS - Monitoring sound with Big Sound Sensor

My neighbors are making a lot of noise with construction and I want to see when they are loudest so I can plan accordingly.

BeginnerFull instructions provided294
Lane Tech HS - Monitoring sound with Big Sound Sensor

Things used in this project

Hardware components

Argon
Particle Argon
×1
Big Sound Sensor
×1

Software apps and online services

CoolTerm
Particle Build Web IDE
Particle Build Web IDE
Google Sheets
Google Sheets
Microsoft Excel

Hand tools and fabrication machines

Multitool, Screwdriver
Multitool, Screwdriver

Story

Read more

Schematics

Diagram

Hand-drawn diagram of circuit

Code

bigsoundtrial2.ino

C/C++
Viewing analog sensor values from Elegoo Big Sound Sensor
int sensorPin = A0; //analog --> most helpful when recording realtime data!!
int sensorValue = 0; //define variable to store analog value

void setup()
{
    Serial.begin(9600);
    
    // Subscribe to the integration response event
    Particle.subscribe("hook-response/Sound triggered", myHandler, MY_DEVICES);
}

void myHandler(const char *event, const char *data) {
  // Handle the integration response
}

void loop()
{
    sensorValue = analogRead(sensorPin);
    Serial.println(String(sensorValue) );//print analog value onto serial monitor
    delay(250);
    
    // Get some data
    String data = String(sensorValue);
    // Trigger the integration
    Particle.publish("Sound triggered", data, PRIVATE);
    // Wait 3 seconds
    delay(3000);
}

Credits

Christine Jacinto

Christine Jacinto

2 projects • 4 followers

Comments

Add projectSign up / Login