Skip to the content
2 layers120.7 × 66 mmESP32 Visitor Counter, the printed circuit board in 3D

ESP32 visitor counter with dual IR sensors and OLED display that auto-switches off the AC load via relay when a room is empty. Custom 2-layer KiCad PCB. Non-profit student project, Marwadi University, India.

Size
120.7 × 66 mm
Copper layers
2
Thickness
1.6 mm
Parts
26
Nets
41
Pads
112
Tracks, vias
182, 0
Pours
1
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
30 Oct 2026
Updated
1 Nov 2026

Overview

ESP32 Visitor Counter is an open-source printed circuit board by HarshParmar029, from the HarshParmar029/ESP32-Smart-Visitor-Counter repository on GitHub, published under the MIT licence. It is a 2-layer board of 120.7 × 66 mm with 26 parts on 41 nets, routed with 182 tracks and 0 vias.

It is built around the L7805 and BC547. Its parts include 8 connectors, 6 resistors, 4 capacitors, 4 diodes and 2 switches. It belongs with the lEDs and displays and home automation and IoT boards and the ESP32 boards of this library.

Main components

2

README

README.md

ESP32 Smart Visitor Counter & Energy Saver

Bi-directional visitor counter built on the ESP32 with a custom 2-layer KiCad PCB. Two IR sensors detect entry and exit using a sequential state machine; a 0.96" I2C OLED shows the live occupancy count; a 5V opto-isolated relay switches the AC load OFF automatically when the room is empty.

Non-profit student project by Harsh, B.Tech ICT, Marwadi University, Rajkot, India.

How it works

  • Entry: Sensor A then Sensor B -> count + 1
  • Exit: Sensor B then Sensor A -> count - 1 (never below 0)
  • Count > 0 -> relay ON, count = 0 -> relay OFF

Hardware

ESP32, 2x IR sensors, 0.96" I2C OLED (128x64), 5V opto-isolated relay module, USB-C 5V power input.

PCB

KiCad, 2-layer FR-4, 1 oz copper, HASL, 120.65 mm x 66.04 mm, copper ground pours on both layers, DRC 0 errors / 0 warnings. Fabricated with PCBWay sponsorship.

Safety

The relay switches 220V AC mains. Keep mains wiring isolated from the low-voltage section and use proper enclosure and insulation.

Future scope

Wi-Fi cloud logging (Blynk / AWS IoT) and ToF/LiDAR sensors for side-by-side entry detection.

Parts

26
QtyValueFootprintReferences
2100nCapacitor_THT:C_Disc_D3.8mm_W2.6mm_P2.50mmC2, C4
210kResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR2, R3
21N5819Diode_THT:D_DO-41_SOD81_P10.16mm_HorizontalD2, D4
21kResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR1, R4
25.1kResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR5, R6
1100uCapacitor_THT:CP_Radial_Tantal_D8.0mm_P2.50mmC3
11N4007Diode_THT:D_DO-41_SOD81_P10.16mm_HorizontalD3
1470uCapacitor_THT:CP_Radial_Tantal_D8.0mm_P2.50mmC1
1BC547Package_TO_SOT_THT:TO-92_InlineQ1
1Barrel_JackConnector_BarrelJack:BarrelJack_HorizontalJ1
1Conn_01x03TerminalBlock_Phoenix:TerminalBlock_Phoenix_MKDS-1,5-3-5.08_1x03_P5.08mm_HorizontalJ7
1J_LEFTConnector_PinHeader_2.54mm:PinHeader_1x15_P2.54mm_VerticalJ2
1J_RIGHTConnector_PinHeader_2.54mm:PinHeader_1x15_P2.54mm_VerticalJ3
1L7805Package_TO_SOT_THT:TO-220-3_VerticalU1
1LEDLED_THT:LED_D5.0mmD1
1OLED_I2CConnector_PinHeader_2.54mm:PinHeader_1x04_P2.54mm_VerticalJ6
1Relay_SPDTRelay_THT:Relay_SPDT_SANYOU_SRD_Series_Form_CK1
1SW_SPDTButton_Switch_THT:SW_Slide_SPDT_Straight_CK_OS102011MS2QSW2
1Sensor_AConnector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_VerticalJ4
1Sensor_BConnector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_VerticalJ5
1USB_C_Receptacle_PowerOnly_6PConnector_USB:USB_C_Receptacle_HRO_TYPE-C-31-M-12J8

Similar boards

  • 2 layers132.1 × 45.7 mmIPoS, the printed circuit board in 3D

    IPoS

    peterheinrich/InternetOverSpaghetti

    Transmitting IP packages over a pair of spaghetti thus demonstrating how media independent IP really is.

    42 parts342
  • 2 layers167.8 × 200.6 mmRandom Jazz Generator, the printed circuit board in 3D

    Random Jazz Generator

    telec16/modular-synth

    Little side project, don't expect much updates.

    132 parts16
  • 2 layers117.5 × 56.4 mmDIY Oxygen Analyzer, the printed circuit board in 3D

    DIY Oxygen Analyzer

    ashishkumarpardeshi/DIY_Oxygen_Analyzer

    This repository is for Design and Development of DIY Oxygen Analyzer Prototyping Board, Writing Code and Calibration.

    42 parts11
  • 2 layers100 × 50 mmC6021light, the printed circuit board in 3D

    C6021light

    deltaphi/c6021light

    Feature-compact DIY version of the c6021

    79 parts5GPL-3.0
  • 2 layers259.7 × 159.5 mmBLDC inverter, the printed circuit board in 3D

    BLDC inverter

    vladBaciu/Sensorless-BLDC-HW

    Bachelor thesis project

    104 parts3
  • 2 layers50.8 × 94 mmClockdivider, the printed circuit board in 3D

    Clockdivider

    bmatthieu3/clockdivider

    A simple clock divider module made with an Atmega328p

    41 parts2MIT
  • 2 layers99.7 × 48.3 mmTexteditor, the printed circuit board in 3D

    Texteditor

    ajackson2681/codex

    The Codex is an attempt at an open-source, distraction-free writing device inspired somewhat by the AlphaSmart Neo (at least the display was).

    18 parts1GPL-3.0

Questions

How big is the ESP32 Visitor Counter PCB?

It measures 120.7 × 66 mm and has 2 copper layers, 1.6 mm thick.

What parts does the ESP32 Visitor Counter use?

26 parts, built around the L7805 and BC547. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the ESP32 Visitor Counter KiCad files?

From the HarshParmar029/ESP32-Smart-Visitor-Counter repository on GitHub, at the commit this page was made from: the board is ESP32_Visitor_Counter.kicad_pcb and its schematic ESP32_Visitor_Counter.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the ESP32 Visitor Counter design in my own project?

Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).