How to make a water level meter using Arduino and LEDs

28 August 2024 2 minutes Author: Cyber Witcher

In this project, we will use an Arduino Nano and an HC-SR04 ultrasonic sensor to accurately measure water levels. The results will be displayed using LEDs, which will allow you to visually control the amount of liquid in the container. Such a system is easy to implement and ideal for home or educational automation projects.

Required components:

Connection diagram

Ultrasonic distance sensor HC-SR04

  • VCC → Arduino 5V pin

  • GND → Arduino GND pin

  • TRIG → Arduino pin A4

  • ECHO → Arduino pin A5

LEDs

  • Cathodes → all to GND Arduino

  • Anodes → to pins D12, D11, D2, D3, D4, D5, D6. If desired, all anodes can be connected through 220 Ohm resistors. This will increase their service life.

Firmware

**If you do not have the Arduino IDE installed, I advise you to watch the video tutorial, which shows how to install and configure it.

At this link you will find information on how to install the driver on the Arduino board.** Download the firmware from this link and upload it to the Arduino according to the instructions above. The scheme of the project can be found here.

Principle of operation

The sensor measures the distance to the water surface. Depending on how far the water is, different LEDs light up. We hope that everything worked out for you!

If you have any problems, you can contact us via [email protected].

Other related articles
Found an error?
If you find an error, take a screenshot and send it to the bot.