Close
  • 4
    Train the audio model and import it into Arduino App Lab
  • In Edge Impulse, create four classes: glass_breaking, falling, fire_alarm, and noise. Use multiple 5-second audio samples, then we switch to 1-second audio samples

  • Set the audio frequency to 18 kHz.
  • Collect training data for each class, then train the model.
  • Export the trained model for Linux aarch64. This produces the .eim file in the Files tab.
  • Before adding the model, run a Hello World model example in Arduino App Lab. This confirms the Uno Q is connected and running code.
  • Import the .eim model into Arduino App Lab so the Uno Q can run it.
  • 5
    Upgrade and add features

    Once the basics worked, we kept improving the device and adding features, and tested each change on the Uno Q before moving on.

    1. Improve accuracy. Add more training data, retrain the model in Edge Impulse, and import the new .eim into Arduino App Lab.
    2. Tune the app. Adjust the Python code so detections respond quickly and alerts show clearly on the LED matrix.
    3. Add features one at a time. 
    4. Test after every change. Play each sound near the microphone and check that the matching icon still appears on the LED matrix before adding the next feature.
  • 6
    Integrate, box it up, and test

    We placed the Uno Q, breadboard, and LED matrix inside the cover box, with the LED matrix facing out and the microphone left uncovered.

    To test, we played different sounds, including breaking glass and a fire alarm, and checked that the matching icon appeared on the LED matrix.

    After the main functions worked, we took on the bonus requirement: sending an email and calling when a critical sound is detected.

  • Discussions