Download as pdf or txt
Download as pdf or txt
You are on page 1of 16

21/6/2017 Digital 

Arduino Voltmeter

Electronics Project Kits For Students Click Here ×

ELECTRONICS HUB
P ROJ E C T S | T U T O RI A L S | C O U RS E S

HOME PROJECTS MINI PROJECTS FREE CIRCUITS TUTORIALS SYMBOLS DIY

PROJECT KITS COURSES CONTACT US

HOME » ARDUINO » DIGITAL ARDUINO VOLTMETER

Digital Arduino Voltmeter


SEPTEMBER 22, 2016 BY ADMINISTRATOR — LEAVE A COMMENT

Contents [hide]

1 Circuit Diagram
2 Components
3 Component Description
4 Circuit Design
5 Working
6 Applications
7 Code 1
8 Code 2
9 Related Articles

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
1/16
21/6/2017 Digital Arduino Voltmeter

Electronics Project Kits For Students Click Here ×

A Voltmeter or a Voltage Meter is a measuring instrument that is used for measuring voltage
or potential di erence between two points in a circuit. Voltmeters are an important piece of
equipment which are associated with any kind of electronics project. They are used in
measurement of both AC and DC voltages.

Voltmeters are again classi ed in to two types namely Analog Voltmeter and Digital Voltmeter.
Analog Voltmeter consists of pointer that moves across a scale and the movement is
proportional to the voltage measured.

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
2/16
21/6/2017 Digital Arduino Voltmeter

Electronics Project Kits For Students Click Here ×

Analog Voltmeters are further classi ed based on their principle of construction. Some of the
commonly known analog voltmeters are Permanent Magnet Moving Coil Voltmeter, Recti er
Type Voltmeter, Electrostatic Type Voltmeter, Moving Iron Type Voltmeter etc.

Select the Next Set of Arduino Projects You Want to Learn in Electronicshub: Arduino
Projects»

Analog Voltmeters generally have an error percentage of 5% and the parallax error is often an
issue. But analog voltmeters can be used to measure ranging from few volts to several
thousand volts.

To overcome the defects of analog voltmeters, Digital Voltmeters are introduced. Unlike
analog voltmeters, which scale and a pointer to show the measured voltage, digital voltmeters
directly display the measured voltage numerical on a digital display.

The percentage of error in digital voltmeters is usually less than 1% and the accuracy can be
increased in precision digital voltmeters with high speed measurement and option of storing
the values in a memory.

In this project, an Arduino based Digital Voltmeter which can measure voltages up to 50V is
designed.

Circuit Diagram

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
3/16
21/6/2017 Digital Arduino Voltmeter

Electronics Project Kits For Students Click Here ×

Figure 1 – Arduino Digital Voltmeter Circuit Diagram

Figure 2 – Arduino Digital Voltmeter Circuit Diagram

Components
Arduino UNO
16 x 2 LCD Display
10KΩ POT
100KΩ
10KΩ
Connecting Wires

Component Description
http://www.electronicshub.org/digital­arduino­voltmeter/ ×
4/16
21/6/2017 Digital Arduino Voltmeter

Component Description
Electronics Project Kits For Students Click Here ×
Arduino UNO

Arduino UNO is one of the most popular electronics prototyping board based on ATmega328P
Microcontroller. ATmega328P is an AVR architecture based 8-bit microcontroller.

16 x 2 LCD Display

A 16 x 2 LCD display is the most commonly used display unit for microcontroller based
applications.

It supports 16 characters in a row with two such rows. It also supports special characters and
even custom characters.

Circuit Design
For measuring voltages less than or equal to 5V, rst circuit can be used. For measuring
voltages up to 50V, second circuit can be used. The LCD part in both the circuits are same.

Pin 1 and 2 (Vss and Vdd) of the LCD power supply pins for display. They are connected to
ground and +5V supply respectively. Pin 3 (Vee) of the LCD is the contrast adjust pin of the
display. It is connected to the wiper terminal of the 10KΩ POT while the other terminals of the
POT are connected to +5V supply and ground respectively.

The next three pins of the LCD are control pins. Pins 4 and 6 (RS and E) of the LCD are
connected to digital input/output pins 2 and 3 of Arduino respectively. Pin 5 (RW) of the LCD is

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
5/16
21/6/2017 Digital Arduino Voltmeter

connected to ground. Electronics Project Kits For Students Click Here ×


The next connections are with respect to data pins. The LCD is used in 4-bit data mode and
hence data pins D4 to D7 are used. Connect pins 11 to 14 (D4 to D7) of the LCD are connected to
digital input/output pins 4 to 7 of the Arduino. Pins 15 and 16 are the supply pins of the
backlight LEDs. Pin 15 (LED+) of the LCD is connected to +5V supply through a current limiting
resistor of 220Ω. Pin 16 (LED-) of the LCD is connected to ground.

In the rst circuit, which is used to measure voltages up to 5V, there are no additional
connections and the voltage to be measured is connected directly to the analog input A0 of
the Arduino UNO.

In the second circuit, which is used to measure voltages up to 50V, we need to connect a
voltage circuit additionally. The output of the voltage divider circuit consisting of 100KΩ
resistor and 10KΩ resistor is connected to the analog input pin A0 of the Arduino UNO with
other end of the 100KΩ resistor connected to the voltage to be measured and the other end of
the 10KΩ resistor connected to the ground.

The ground terminal of the input voltage to be measured and Arduino UNO must be common.

Working
The aim of the project is to build a digital voltmeter using Arduino UNO. The components
required and the construction of the project is very simple. The working of the project is
explained here.

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
6/16
21/6/2017 Digital Arduino Voltmeter

In a digital voltmeter, the Electronics


voltages toProject
be measured, which are inClick Here
Kits For Students analog form, are converted to
digital form with the help of Analog to Digital Converters (ADC). Hence, the ADC feature of the
×
Arduino UNO is utilized in this project.

In the rst circuit, which is used to measure a maximum voltage of 5V, the input voltage is
given to the analog input pin of the Arduino. The reference voltage of the ADC is 5V. The ADC in
Arduino UNO is of 10-bit resolution. Hence, the input voltage is calculated by multiplying the
analog value at the analog pin with 5 and dividing the value with 210 i.e. 1024.

The range of voltages for Arduino UNOs analog input is 0V to 5V. Hence, in order to increase
this range, a voltage divider circuit must be used.

In the second circuit, the range of the analog input of Arduino UNO is increased up to 50V by
using a voltage divider consisting of 100KΩ resistor and 10KΩ resistor. With the help of the
voltage divider circuit, the input voltage being measured is brought down to the range of
Arduino UNOs analog input.

The rest of the calculations are made in the programming part of the Arduino UNO.

NOTE

The disadvantage of using voltage divider based voltmeter is the error of measurement.
Hence, we need multiple ranges of voltmeter.
In order to reduce the error, the ratio of R1 and R2 in the voltage divider must be
minimum.
For example, to measure an input voltage of 50V, the ratio of R1 and R2 must be greater
than ((50/5) – 1) i.e.

R1/R2 > ((50/5) – 1)

R1/R2 > 9

Hence, if we choose R1 as 100KΩ and R2 as 10KΩ, then it is possible to measure the voltages
up to 50V.

Applications
An Arduino based Digital Voltmeter is designed in this project which can be used to
measure di erent ranges of DC voltages.
The circuit can be extended to measure even AC voltages with slight modi cation in
circuit and code.

Code 1
http://www.electronicshub.org/digital­arduino­voltmeter/ ×
7/16
21/6/2017 Digital Arduino Voltmeter

1
2
#include "LiquidCrystal.h"
Electronics Project Kits For Students Click Here ×
3 LiquidCrystal lcd(2, 3, 4, 5, 6, 7);
4
5 float voltage = 0.0;
6 float temp=0.0;
7 int analog_value;
8
9 void setup()
10 {
11    lcd.begin(16, 2); 
12    lcd.setCursor (0,0);
13    lcd.print(" Arduino based ");
14    lcd.setCursor(0,1); 
15    lcd.print("Digital Voltmeter");
16 delay(2000);
17 }
18 void loop() 
19 {
20
21    

22    analog_value = analogRead(A0);
23    temp = (analog_value * 5.0) / 1024.0; 
24
25    voltage = temp/(0.0909);
26    if (voltage < 0.1) 
27    {
28      voltage=0.0;
29    } 
30     lcd.clear();
31     lcd.setCursor(0, 0);
32     lcd.print("Voltage= ");
33     lcd.print(voltage);

34     lcd.setCursor(13,1);
35     lcd.print("V");
36     delay(30);
37 }

Arduino Digital Voltmeter Code 1 hosted with by GitHub view raw

Code 2

1 #include "LiquidCrystal.h"
2
3 LiquidCrystal lcd(2, 3, 4, 5, 6, 7);

4
5 float voltage = 0.0;
6 float temp=0.0;

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
8/16
21/6/2017 Digital Arduino Voltmeter

7
8
int analog_value;
Electronics Project Kits For Students Click Here ×
9 void setup()
10 {
11    lcd.begin(16, 2); 
12    lcd.setCursor (0,0);
13    lcd.print(" Arduino based ");
14    lcd.setCursor(0,1); 
15    lcd.print("Digital Voltmeter");

16 delay(2000);
17 }
18 void loop() 
19 {
20
21    
22    analog_value = analogRead(A0);
23    voltage = (analog_value * 5.0) / 1024.0; 
24
25    if (voltage < 0.1) 
26    {
27      voltage=0.0;

28    } 
29     lcd.clear();
30     lcd.setCursor(0, 0);
31     lcd.print("Voltage= ");
32     lcd.print(voltage);
33     lcd.setCursor(13,1);
34     lcd.print("V");
35     delay(30);
36 }

Arduino Digital Voltmeter Code 2 hosted with by GitHub view raw

Related Articles
http://www.electronicshub.org/digital­arduino­voltmeter/ ×
9/16
21/6/2017 Digital Arduino Voltmeter

Related ArticlesElectronics Project Kits For Students Click Here ×

Arduino Relay Control Arduino LED Matrix Arduino Introduction Arduino RFID Reader

Stepper Motor Control Portable Ultrasonic Rotary Encoder With Arduino Based Digital
Using Arduino Range Meter Arduino – Know it all Thermometer

FILED UNDER: ARDUINO

Leave a Reply
Your email address will not be published. Required elds are marked *

Comment

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
10/16
21/6/2017 Digital Arduino Voltmeter

Electronics Project Kits For Students Click Here ×

Name *

Email *

Website

I'm not a robot


reCAPTCHA
Privacy - Terms

  POST COMMENT

Search this website …

Suggest A Topic [or] Project

COMPLETE STEP BY STEP GUIDE

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
11/16
21/6/2017 Digital Arduino Voltmeter

Electronics Project Kits For Students Click Here ×

Electronics Hub

YouTube 16K

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
12/16
21/6/2017 Digital Arduino Voltmeter

Electronics Project Kits For Students Click Here


Electronics Hub ×

Ikuti di Pinterest 

Electronics Hub

Follow +1

+ 71,296

SUBSCRIBE FOR FREE PROJECT CIRCUITS

Enter your email address:

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
13/16
21/6/2017 Digital Arduino Voltmeter

Electronics Project Kits For Students Click Here SUBSCRIBE ×


Delivered by FeedBurner

Electronics Hub
665.069 suka

Sukai Halaman Daftar

Jadilah orang pertama yang menyukai ini.

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
14/16
21/6/2017 Digital Arduino Voltmeter

Electronics Project Kits For Students Click Here


PROJECTS BY CATEGORY ×

Arduino Projects (200+)


Electronics Projects (250+)
Mini Project Circuits (160+)
Mini Project Ideas (150+)
ECE Projects (150+)
EEE Projects (150+)
8051 Projects (110+)
Raspberry Pi Projects (101+)
Electrical Project Ideas (100+)
Embedded Projects (100+)
Latest Electronics Ideas (100+)
Microcontroller Mini Projects (100+)
Robotics Projects (100+)
VLSI Projects (100+)
Solar Projects (100+)
IOT Projects (100+)

Communication Projects (70+)


LED Projects (70+)
Power Electronics Projects (60+)
RFID Projects (60+)
Home Automation Projects (50+)
Matlab Projects (50+)
EIE Projects (50+)
Wireless Projects (50+)
LabView Projects (45+)
Zigbee Projects (45+)
GSM Projects (40+)
555 Timer Circuits (40+)
Sensor Projects (40+)
ARM Projects (60+)
DTMF Projects (30+)
PIC Projects (30+)
Electrical Mini Projects (25)

GENERAL PROJECTS PROJECTS

Tutorials Electrical Mini projects


Symbols Electronics Microcontroller

http://www.electronicshub.org/digital­arduino­voltmeter/ ×
15/16
21/6/2017 Digital Arduino Voltmeter

Courses Embedded
Electronics Project Kits ForAurdino
Students Click Here ×
Calculator Power Solar
Contact Robotics Free circuits
ARM Home Automation
IOT
TUTORIALS

Capcitors
Resitors
Filters
Diodes
Transistors

TUTORIALS FOLLOW US

Ampli ers Facebook


IO Devices Youtube
Thyristors Google Plus
DC Circuits Twitter
Nummber System

Copyright © 2017 Electronicshub.org

http://www.electronicshub.org/digital­arduino­voltmeter/ 16/16

You might also like