Close Menu
  • Articles
    • Learn Electronics
    • Product Review
    • Tech Articles
  • Electronics Circuits
    • 555 Timer Projects
    • Op-Amp Circuits
    • Power Electronics
  • Microcontrollers
    • Arduino Projects
    • STM32 Projects
    • AMB82-Mini IoT AI Camera
    • BLE Projects
  • IoT Projects
    • ESP8266 Projects
    • ESP32 Projects
    • ESP32 MicroPython
    • ESP32-CAM Projects
    • LoRa/LoRaWAN Projects
  • Raspberry Pi
    • Raspberry Pi Projects
    • Raspberry Pi Pico Projects
    • Raspberry Pi Pico W Projects
  • Electronics Calculator
Facebook X (Twitter) Instagram
  • About Us
  • Disclaimer
  • Privacy Policy
  • Contact Us
  • Advertise With Us
Facebook X (Twitter) Instagram Pinterest YouTube LinkedIn
How To Electronics
  • Articles
    • Learn Electronics
    • Product Review
    • Tech Articles
  • Electronics Circuits
    • 555 Timer Projects
    • Op-Amp Circuits
    • Power Electronics
  • Microcontrollers
    • Arduino Projects
    • STM32 Projects
    • AMB82-Mini IoT AI Camera
    • BLE Projects
  • IoT Projects
    • ESP8266 Projects
    • ESP32 Projects
    • ESP32 MicroPython
    • ESP32-CAM Projects
    • LoRa/LoRaWAN Projects
  • Raspberry Pi
    • Raspberry Pi Projects
    • Raspberry Pi Pico Projects
    • Raspberry Pi Pico W Projects
  • Electronics Calculator
How To Electronics
Home » Digital Tachometer using IR Sensor with Arduino for measuring RPM
Arduino Projects

Digital Tachometer using IR Sensor with Arduino for measuring RPM

Mamtaz AlamBy Mamtaz AlamUpdated:February 2, 20259 Comments4 Mins Read
Share Facebook Twitter LinkedIn Telegram Reddit WhatsApp
Digital Tachometer using IR Sensor with Arduino
Share
Facebook Twitter LinkedIn Pinterest Email Reddit Telegram WhatsApp

Introduction

In this project, we have designed Digital Tachometer using an IR Sensor with Arduino for measuring the number of rotations of the rotating Motor in RPM. Simply we have interfaced the IR sensor module with Arduino and the 16*2 LCD module for display. The IR sensor module consists of IR Transmitter & Receiver in a single pair that can work as a Digital Tachometer for speed measurement of any rotating object.

The Tachometer is an RPM counter which counts the no. of rotation per minute. There are two types of tachometer one mechanical and another one is digital. Here we are going to design an Arduino-based digital tachometer using an IR sensor module to detect objects for count rotation of any rotating body. IR transmits IR rays which reflect back to the IR receiver and then IR Module generates an output or pulse which is detected by the Arduino controller when we press the start button. It counts continuously for 5 seconds.

You can also make: Fan Speed Measurement Device as well as GPS Speedometer.




Components Required

For designing Digital Tachometer using IR Sensor with Arduino & LCD we need the following components:

C++
1
2
3
4
5
6
1. Arduino UNO Board
2. 16*2 LCD
3. IR Sensor module containing both transmitter and receiver
4. Tact Switch (Reset Switch)
4. Breadboard
5. Connecting Jumper Wires


Digital Tachometer using IR Sensor with Arduino for measuring RPM

Now after managing these components do this following connection for designing Digital Tachometer using IR Sensor with Arduino for measuring RPM

LCD Pins 1, 3 ,5 ,16 ——— GND
LCD Pins 2, 15————— VCC (+5V)
LCD Pin 4 ——————– Arduino pin D7
LCD Pin 6 ——————– Arduino pin D6
LCD Pin 11 ——————- Arduino pin D5
LCD Pin 12 ——————- Arduino pin D4
LCD Pin 13 ——————- Arduino pin D3
LCD Pin 14 ——————- Arduino pin D2
IR Sensor Module Pin -GND —— GND
IR Sensor Pin +VCC —— VCC
IR Sensor Pin OUT — Arduino Pin D9
Tact Switch one end ————- Arduino PinD12
Tact Switch another end ————-GND

A connection diagram is given below as well. Simply assemble the circuit like this.

Digital Tachometer using IR Sensor with Arduino


IR Sensor Module

Introduction

An infrared sensor is an electronic instrument that is used to sense certain characteristics of its surroundings by either emitting and/or detecting infrared radiation. Infrared sensors are also capable of measuring the heat being emitted by an object and detecting motion.

The wavelength region which ranges from 0.75 to 3µm is known as the near-infrared region. The region between 3 and 6µm is known as the mid-infrared and infrared radiation which has a wavelength greater higher than 6µm is known as far-infrared.


An IR sensor consists of an IR LED and an IR Photodiode; together they are called Photo–Coupler or Opto–Coupler. As said before, the Infrared Obstacle Sensor has a built-in IR transmitter and IR receiver. An infrared Transmitter is a light-emitting diode (LED) that emits infrared radiation. Hence, they are called IR LEDs. Even though an IR LED looks like a normal LED, the radiation emitted by it is invisible to the human eye. Infrared receivers are also called infrared sensors as they detect the radiation from an IR transmitter. IR receivers come in the form of photodiodes and phototransistors. Infrared Photodiodes are different from normal photodiodes as they detect only infrared radiation. When the IR transmitter emits radiation, it reaches the object and some of the radiation reflects back to the IR receiver. Based on the intensity of the reception by the IR receiver, the output of the sensor is defined.

Features

C++
1
2
3
4
5
1. Operating Voltage: 3.0V – 5.0V
2. Detection range: 2cm – 30cm (Adjustable using potentiometer)
3. Current Consumption:at 3.3V : ~23 mA,at 5.0V: ~43 mA
4. Active output level: Outputs Low logic level when an obstacle is detected
5. Onboard Obstacle Detection LED indicator

Working Mechanism

In this circuit, the IR sensor module is interfaced with Arduino to measure fan rotation speed in RPM. The calculation is done on this basis.

After 5 seconds Arduino calculates RPM for a minute using the given formula.

RPM= Count x 12 for single object rotating body.
But here we demonstrate this project using a ceiling fan. So we have done some changes that is given below:

RPM=count x 12 / objects

Where object = number of the blade in a fan.


Arduino Source Code/Program:

So here is a source code for designing Digital Tachometer using IR Sensor with Arduino. Simply copy the code and upload it to your Arduino board using Arduino IDE.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#include <LiquidCrystal.h>
LiquidCrystal lcd(7, 6, 5, 4, 3, 2);
#define sensor 9
#define start 12
int delay1()
{
//unsigned int long k;
int i,j;
unsigned int count=0;
for(i=0;i<1000;i++)
{
for(j=0;j<1000;j++)
{
if(digitalRead(sensor))
{
count++;
while(digitalRead(sensor));
}
}
}
return count;
}
void setup()
{
pinMode(sensor, INPUT);
pinMode(start, INPUT);
pinMode(2, OUTPUT);
lcd.begin(16, 2);
lcd.print(” Tachometer”);
delay(2000);
digitalWrite(start, HIGH);
}
void loop()
{
unsigned int time=0,RPM=0;
lcd.clear();
lcd.print(” Please Press “);
lcd.setCursor(0,1);
lcd.print(“Button to Start “);
while(digitalRead(start));
lcd.clear();
lcd.print(“Reading RPM…..”);
time=delay1();
lcd.clear();
lcd.print(“Please Wait…..”);
RPM=(time*12)/3;
delay(2000);
lcd.clear();
lcd.print(“RPM=”);
lcd.print(RPM);
delay(5000);
}



Video Preview & Explanation

Tachometer (RPM Measurement) using IR Sensor & Arduino
Watch this video on YouTube.

You can also use the IR sensor for designing a Bidirectional Visitor Counter.

Share. Facebook Twitter Pinterest LinkedIn Tumblr Email Reddit Telegram WhatsApp
Previous ArticleDS18B20 Thermometer using Arduino & 4 Digits 7 Segment Display
Next Article Interfacing DHT11 Humdity & Temperature Sensor with Arduino & LCD

Related Posts

DC Energy Meter using Arduino

Build a DC Energy Meter using Arduino – 32V/5A

Updated:August 26, 20252K
Interfacing ADXL375 Accelerometer with Arduino

Interfacing ADXL375 Accelerometer with Arduino (±200g)

Updated:June 28, 2025
PZEM-004T Arduino Energy Meter

DIY AC Energy Meter using PZEM-004T & Arduino

Updated:March 6, 20258K
Interfacing BMI160 Accelerometer & Gyroscope with Arduino

Interfacing BMI160 Accelerometer & Gyroscope with Arduino

Updated:February 2, 20259K
Password Based Door Lock Security System Using Arduino & Keypad

Password Based Door Lock Security System Using Arduino & Keypad

Updated:February 2, 20252436K
Earthquake Detector Alarm with with Accelerometer & Arduino

Earthquake Detector Alarm with Accelerometer & Arduino

Updated:February 2, 2025661K
View 9 Comments

9 Comments

  1. Milon Mukherjee on August 7, 2019 10:11 PM

    Actually Pin no. 15 of 16*2 LCD display is connected with +5V Vcc. But you mistakenly have written there pin no. 16 is connected with the +5V Vcc , so please fix that typing mistake. By the way your post is explaining everything about that project is very good with detailed instruction with the application of each components. Hope now I can also do it very easily.

    Reply
    • Alex Newton on August 7, 2019 10:14 PM

      Thanks for referring the mistake. And all the best for your project.

      Reply
      • Milon Mukherjee on August 7, 2019 10:18 PM

        Thank you.

  2. Milon Mukherjee on August 7, 2019 10:45 PM

    You also did another mistake there i think. Because you mentioned that you connected the humidity sensor’s vcc pin with +5v vcc. But I think that you didn’t use the humidity sensor over here and can you check the whole post once again ?

    Reply
    • Alex Newton on August 7, 2019 11:02 PM

      Corrected. Thank you again 🙂

      Reply
  3. Ishaan Kumar on November 21, 2019 12:57 AM

    Why did you use a nested for loop till 1000?

    Reply
  4. microdigisoft50ae5c39ef on December 1, 2020 9:55 PM

    nice idea!!!!!!!!

    Reply
  5. Milt Fisher on May 17, 2021 3:09 AM

    What’s the maximum RPM that this circuit can read? Can it do 1000rpm, 5000rpm?

    Reply
  6. Vaibhav on January 26, 2023 8:00 AM

    In the formula stated above why is it that we are multiplying the value obtained with 12?

    Reply

CommentsCancel reply

Latest Posts
ESP32 Fingerprint Attendance System with Live Web Dashboard

ESP32 Fingerprint Attendance System with Live Web Dashboard

June 16, 2026
IoT Based PM & Air Quality Monitoring System using ESP32

IoT Based PM & Air Quality Monitoring System using ESP32

June 14, 2026
DIY ESP32 MLX90640 IR Thermal Camera with Live Web Display

DIY ESP32 MLX90640 IR Thermal Camera with Live Web Display

May 10, 2026
IoT Activity Tracker with ESP32 & Accelerometer Gyroscope

IoT Activity Tracker with ESP32 & Accelerometer/Gyroscope

May 2, 2026
A Guide to Sourcing Obsolete ICs for Vintage Projects

Beyond AliExpress: A Guide to Sourcing Obsolete ICs for Vintage Projects

April 21, 2026

ESP32 IoT Vehicle Motion Analyzer with MPU6050 & LIS3MDL

April 27, 2026
Building a Smart Sensor Node with a BLE Microcontroller

Building a Smart Sensor Node with a BLE Microcontroller

February 26, 2026
High-Accuracy Pitch, Roll, Yaw with ESP32 & BNO08x IMU

High-Accuracy Pitch, Roll, Yaw with ESP32 & BNO08x IMU

April 27, 2026
Top Posts & Pages
  • IoT Based PM & Air Quality Monitoring System using ESP32
    IoT Based PM & Air Quality Monitoring System using ESP32
  • IoT AC Energy Meter with PZEM-004T & ESP32 WebServer
    IoT AC Energy Meter with PZEM-004T & ESP32 WebServer
  • 12V DC to 220V AC Inverter Circuit & PCB
    12V DC to 220V AC Inverter Circuit & PCB
  • Buck Converter: Basics, Working, Design & Application
    Buck Converter: Basics, Working, Design & Application
  • How to use Modbus RTU with ESP32 to read Sensor Data
    How to use Modbus RTU with ESP32 to read Sensor Data
  • RS-485 Simplex Communication with Arduino & MAX485
    RS-485 Simplex Communication with Arduino & MAX485
  • ESP32 CAN Bus Tutorial | Interfacing MCP2515 CAN Module with ESP32
    ESP32 CAN Bus Tutorial | Interfacing MCP2515 CAN Module with ESP32
  • L293D Dual H-Bridge Motor Driver IC Pins, Circuit, Working
    L293D Dual H-Bridge Motor Driver IC Pins, Circuit, Working
Categories
  • Arduino Projects (197)
  • Articles (60)
    • Learn Electronics (19)
    • Product Review (15)
    • Tech Articles (28)
  • Electronics Circuits (46)
    • 555 Timer Projects (21)
    • Op-Amp Circuits (7)
    • Power Electronics (13)
  • IoT Projects (205)
    • ESP32 MicroPython (7)
    • ESP32 Projects (82)
    • ESP32-CAM Projects (15)
    • ESP8266 Projects (76)
    • LoRa/LoRaWAN Projects (22)
  • Microcontrollers (38)
    • AMB82-Mini IoT AI Camera (4)
    • BLE Projects (18)
    • STM32 Projects (19)
  • Raspberry Pi (93)
    • Raspberry Pi Pico Projects (57)
    • Raspberry Pi Pico W Projects (12)
    • Raspberry Pi Projects (24)
Follow Us
  • Facebook
  • Twitter
  • Pinterest
  • Instagram
  • YouTube
About Us

“‘How to Electronics’ is a vibrant community for electronics enthusiasts and professionals. We deliver latest insights in areas such as Embedded Systems, Power Electronics, AI, IoT, and Robotics. Our goal is to stimulate innovation and provide practical solutions for students, organizations, and industries. Join us to transform learning into a joyful journey of discovery and innovation.

Copyright © How To Electronics. All rights reserved.
  • About Us
  • Disclaimer
  • Privacy Policy
  • Contact Us
  • Advertise With Us

Type above and press Enter to search. Press Esc to cancel.

Ad Blocker Enabled!
Ad Blocker Enabled!
Looks like you're using an ad blocker. Please allow ads on our site. We rely on advertising to help fund our site.