I am sure you know those volume meters we mostly find in professional recording studios. That’s what this project is about, a simple volume meter (or decibel meter) made with Arduino, a microphone and few LEDs.
The Arduino program for this project is very optimized and shortened so you can see what a properly written program looks like.
Let’s start with a list of components we need for the project:
Basically, you can use every microphone that is compatible with Arduino just make sure that it has an analog output.
- 10 x LEDs (5 green, 3 yellow, 2 red) Color doesn’t matter so much, but it looks more awesome with different colors.
- 10 x 200-220Ω resistors
- Jumper wires
- 1 x Breadboard
Connect everything using the breadboard and make sure you are properly connecting the LEDs with resistors, it is very easy to make a mistake here.
Use male-male cables to connect everything. The microphone module can also be plugged into the breadboard.
You can use a smaller breadboard as well, no need to use a huge one as I am doing.
You will find the program to upload to the Arduino board below, as I’ve already mentioned, I have tried to reduce the whole thing in 17 lines comments excluded. That is what we called efficient programming right here! 😉
The first loop is the LEDs setup and the second is to control the LEDs. You can adjust the sensitivity by changing the value in the map function. You can change the value where you see 700: smaller for more sensitive or bigger for less sensitive.
Here we have it!
A good exercise will be to try adding more LEDs to the project. You can also try using the RGB LED strip instead of the LEDs we have just used.
You might also like:
- Arduino hx711 tutorial
- Arduino magnetic switch
- Best Arduino Kits
- gifts for engineering students
- gifts for engineers
- mpu6050 Arduino projects
- Current sensor Arduino
- Soil Moisture Sensor With Arduino
- Arduino Count up Timer Using the Nokia 5110 LCD
- Arduino Yun: Integrating or Juxtaposing Arduino with Linux
- Arduino Projects: Line Follower Robot
- Arduino RFID Project for Beginners
- Arduino MOSFET Project
- Which Arduino Should You Buy
- What Can You Do With Arduino Boards?
- Great Alternatives to the Arduino Microcontroller
- Arduino Projects: Color Sensor
- Arduino IDE Alternatives
- Arduino Mega vs. Uno
- Arduino Projects: Arduino LCD Display
- Read Arduino Rotary Encoders
- Arduino Simulators
- Arduino Projects: IR Receiver
- Arduino Light Sensor Project
- Arduino Projects: Arduino Decibel Meter
- Arduino Stopwatch Project
- Arduino Bluetooth RC Car Project
- Arduino Temperature Logger Project
- Arduino Projects: Arduino 7 Segment Display
- Arduino Projects: Clap ON Clap OFF Light
- Arduino Relay Project
- Install a Library Onto the Arduino IDE
- Arduino Projects: Rainfall Detector
- Arduino Projects: RGB LED Arduino
- Arduino Stepper Motor Project
- Arduino Projects: Arduino DC Motor Control
- The Top Affordable Arduino Robot Kit
- Arduino 3D Printed Case
- Arduino Projects: Asynchronous LEDs Blink
- Arduino Projects: Ultrasonic Distance Sensor
- Arduino Projects: LED – 4X4X4 LED Cube
- Arduino Car Projects: Build an Obstacle Avoiding Robot With Less Than $30
- Arduino Projects: Servo Potentiometer Control
- Arduino LED Project: Knight Rider
- Arduino Projects: PIR Motion Sensor
- Arduino vs Raspberry Pi
- Top 9 Books Every Engineer Should Read
- Top Used Sensors for Arduino
- First Hand on the Arduino Uno Board
Works great! I made one, though I used 100 ohm and 470 ohm resistors because I didn’t have any 220 ohm resistors. I used the 100 ohm ones before the 470 ohm resistors so the first 5 LEDs would at least be brighter. The whole thing still works wonderfully. Thanks!
Great!
I have made it so it only works for 5 leds, with an arduino MEGA it doesn´t work. what did I do wrong??, I am a complete newbie in electronics.
int led[5] = {30, 31, 32, 33, 34};
int input, i;
void setup()
{
for (i = 30; i < 35; i++)
pinMode(led[i], OUTPUT);
Serial.begin(9600);
}
void loop()
{
input = analogRead(A0);
//Serial.println(s);
input = input / 5; //By changing the denomintor the sensitivity can be changed
if (input < 5)
{
if (input == 0)
{
for (i = 30; i < 35; i++)
{
digitalWrite(led[i], LOW);
}
}
else
{
for (i = 30; (i-30) < input; i++)
{
digitalWrite(led[i], HIGH);
delay(4);
}
for (i = i; i < 35; i++)
{
digitalWrite(led[i], LOW);
}
}
}
}
why the leds lights the same time
Hello,
Great project !
I’m new to Arduino coding and I’m trying to understand to make a similar project.
How could I adapt your code to display the amount of décibels on a WS2812B led strip ?
It is for my wife’s classroom.
Thank you