• Skip to main content
  • Skip to primary sidebar

Homemade Circuit Projects

Need circuit help? Post them in the comments! I've answered over 50,000!

Blog | Categories | About | Contact | Calculators-online
You are here: Home / Arduino Projects / Arduino Frequency Meter Using 16×2 Display

DIY Circuits | Learn Basics | Arduino Coding




Arduino Frequency Meter Using 16×2 Display

Last Updated on February 9, 2026 by Swagatam 4 Comments

In this article I will show how to construct a digital frequency meter using Arduino whose readings will be showcased on a 16x2 LCD display and will have a measuring range from 35 Hz to 1MHz.

Introduction

Being electronics enthusiast, we all would have come across a point where we need to measure frequency in our projects.

At that point we would have realized that an oscilloscope is such a useful tool for measuring frequency. But, we all know that an oscilloscope is an expensive tool not all hobbyists can afford one and oscilloscope might be an overkill tool for beginners.

To overcome the issue of measuring frequency, hobbyist don’t need an expensive oscilloscope, we just need a frequency meter which can measure frequency with reasonable accuracy.

In this article we are going to make a frequency meter, which is simple to construct and beginner friendly, even noob in Arduino can accomplish with ease.

Before going into constructional details, let’s explore what is frequency and how it can be measured.

What is Frequency? (For noobs)

We are familiar with the term frequency, but what really it means?

Well, frequency is defined as number of oscillations or cycles per second. What does this definition mean?

It means the number of times the amplitude of “something” goes up and down in ONE second. For example frequency of AC power at our residence: The amplitude of “voltage” (‘something’ is replaced by ‘voltage’) goes up (+) and down (-) in one second, which is 50 times in most countries.

One cycle or one oscillation comprises of up and down. So one cycle/oscillation is the amplitude goes from zero to positive peak and come back to zero and goes negative peak and return to zero.

“Time period” is also a term used while dealing with frequency. The time period is the time taken to complete “one cycle”. It is also the inverse value of frequency. For example 50 Hz has 20 ms time period.

1/50 = 0.02 second or 20 millisecond  

By now you would have some idea about frequency and its related terms.

How frequency is measured?

We know that one cycle is combination of high and low signal. To measure the duration of high and low signals, we use “pulseIn” in arduino. pulseIn(pin, HIGH) measure duration of high signals and pulseIn(pin, LOW) measure duration of low signals. The pulse duration of both is added which give time period of one cycle.

The determined time period is then calculated for one second. This is done by following formula:

  Freq =  1000000/time period in microseconds

The time period from arduino is obtained in microseconds. The arduino don’t sample the input frequency for entire second, but it predict the frequency accurately by analysing just one cycle’s time period.

Now you know how the arduino measures and calculates the frequency.

The circuit: 

The circuit consists of arduino which is the brain of the project, 16x2 LCD display, IC 7404 inverter and one potentiometer for adjusting contrast of LCD display.

The proposed setup can measure ranging from 35Hz to 1 MHz.

Arduino display connection:

The above diagram is self-explanatory, the wiring connection between arduino and display is standard and we can find similar connections on other arduino and LCD based projects.

Arduino Frequency Meter Using 16x2 Display

The above diagram consists of inverter IC 7404. The role of IC 7404 is to eliminate noise from the input, so that the noise won’t propagate to arduino which might give false readings and IC 7404 can tolerate short spike voltage which will not pass to arduino pins. IC 7404 only outputs rectangular waves where arduino can measure easily compare to analogue waves.

NOTE: The maximum peak to peak input should not exceed 5V.

Program:

//----- Program Developed by R.Girish -----//

#include <LiquidCrystal.h>

// LCD pin configuration: RS, E, D4, D5, D6, D7
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

// Variables to store pulse timings
unsigned long X;        // HIGH pulse width in microseconds
unsigned long Y;        // LOW pulse width in microseconds
unsigned long Time;     // Total period time
float frequency;        // Calculated frequency in Hz

// Pin definitions
const int input = A0;   // Frequency input pin
const int test  = 9;    // Test signal output (PWM)

void setup()
{
  // Configure pin modes
  pinMode(input, INPUT);
  pinMode(test, OUTPUT);

  // Initialize LCD
  lcd.begin(16, 2);

  // Generate a 50% duty cycle PWM on pin 9 for testing
  analogWrite(test, 127);

  // Initial LCD message
  lcd.setCursor(0, 0);
  lcd.print("Frequency Meter");
}

void loop()
{
  // Measure HIGH and LOW pulse widths
  X = pulseIn(input, HIGH);
  Y = pulseIn(input, LOW);

  // Total time period in microseconds
  Time = X + Y;

  // Clear LCD before updating values
  lcd.clear();
  lcd.setCursor(0, 0);
  lcd.print("Frequency Meter");

  // Avoid division by zero or invalid readings
  if (Time == 0)
  {
    lcd.setCursor(0, 1);
    lcd.print("0.00 Hz");
  }
  else
  {
    // Frequency calculation (Hz)
    frequency = 1000000.0 / Time;

    // Display frequency
    lcd.setCursor(0, 1);
    lcd.print(frequency);
    lcd.print(" Hz");
  }

  // Update rate: 1 second
  delay(1000);
}

//----- Program Developed by R.Girish -----//

Testing the frequency meter:

Once you successfully constructed the project, it is necessary to check whether everything is working fine. We have to use a known frequency to confirm the readings. To accomplish this we are using arduino’s inbuilt PWM functionality which has frequency of 490Hz.

In the program pin #9 is enabled to give 490Hz at 50% duty cycle, the user can grab the input wire of the frequency meter and insert in pin #9 of arduino as shown in figure, we can see 490 Hz on the LCD display (with some tolerance), if the mentioned procedure was successful, you frequency meter is ready to serve you experiments.

Author’s prototype:

Arduino Frequency Meter Prototype Image

The user may also test this Arduino frequency meter circuit prototype by using external frequency generator which is shown in above image.

You'll also like:

  • Testing Capacitor with ArduinoDigital Capacitance Meter Circuit Using Arduino
  • P 20160905 014952Password Security Lock Circuit Using 4×4 Keypad and Arduino
  • EVM 2Electronic Voting Machine with SD Card Module
  • How To Use And Program ATmega Microcontrollers From Scratch Without Arduino

Filed Under: Arduino Projects, Meters and Testers Tagged With: 16x2, Arduino, Display, Frequency, Meter

About Swagatam

I am an electronics engineer and doing practical hands-on work from more than 15 years now. Building real circuits, testing them and also making PCB layouts by myself. I really love doing all these things like inventing something new, designing electronics and also helping other people like hobby guys who want to make their own cool circuits at home.

And that is the main reason why I started this website homemade-circuits.com, to share different types of circuit ideas..

If you are having any kind of doubt or question related to circuits then just write down your question in the comment box below, I am like always checking, so I guarantee I will reply you for sure!

Previous Post: « Arduino Pure Sine Wave Inverter Circuit with Full Program Code
Next Post: Making a Single Channel Oscilloscope using Arduino »

Reader Interactions

Comments

rajesh says:
September 17, 2017 at 9:12 am

can we cheq motherboard 32mhz crystal frequency with this curcuit

Reply
GR says:
September 17, 2017 at 9:29 am

Hi Rajesh,

If you are connecting the crystal terminals directly to the input of frequency counter, then NO.
Also this frequency counter can only read under 1 MHz, that’s my assumption.

Regards

Reply
GR says:
September 17, 2017 at 9:32 am

* not just assumption but, the maximum limit of the circuit.

Reply
Swagatam says:
September 17, 2017 at 9:18 am

Mr. GR will answer your question soon….

Reply

Need Help? Please Leave a Comment! We value your input—Kindly keep it relevant to the above topic! Cancel reply

Your email address will not be published. Required fields are marked *

Primary Sidebar

circuit simulator image



Subscribe to get New Circuits in your Email



Categories

  • Arduino Projects (95)
  • Audio and Amplifier Projects (133)
  • Automation Projects (18)
  • Automobile Electronics (103)
  • Battery Charger Circuits (87)
  • Datasheets and Components (109)
  • Electronics Theory (149)
  • Energy from Magnets (27)
  • Games and Sports Projects (11)
  • Grid and 3-Phase (20)
  • Health related Projects (27)
  • Home Electrical Circuits (13)
  • Indicator Circuits (16)
  • Inverter Circuits (95)
  • Lamps and Lights (159)
  • Meters and Testers (71)
  • Mini Projects (28)
  • Motor Controller (68)
  • Oscillator Circuits (28)
  • Pets and Pests (15)
  • Power Supply Circuits (91)
  • Remote Control Circuits (50)
  • Renewable Energy (12)
  • Security and Alarm (64)
  • Sensors and Detectors (106)
  • SMPS and Converters (34)
  • Solar Controller Circuits (60)
  • Temperature Controllers (43)
  • Timer and Delay Relay (49)
  • Voltage Control and Protection (42)
  • Water Controller (37)
  • Wireless Circuits (31)





Other Links

  • Privacy Policy
  • Cookie Policy
  • Disclaimer
  • Copyright
  • Videos
  • Sitemap



People also Search

555 Circuits | 741 Circuits | LM324 Circuits | LM338 Circuits | 4017 Circuits | Ultrasonic Projects | SMPS Projects | Christmas Projects | MOSFETs | Radio Circuits | Laser Circuits | PIR Projects |

Social Profiles

  • Twitter
  • YouTube
  • Instagram
  • Pinterest
  • My Facebook-Page
  • Stack Exchange
  • Linkedin



Recent Comments

  • Swagatam on 9 Simple Solar Battery Charger Circuits
  • Swagatam on Arduino 2-Step Programmable Timer Circuit
  • Karthik B S on 9 Simple Solar Battery Charger Circuits
  • Ghulam Mohio Din on Arduino 2-Step Programmable Timer Circuit
  • Swagatam on Make this Radio Repeater Circuit at Home

© 2026 · Swagatam Innovations