Project idea
A dual-IR, direction-aware object counter for conveyors and entryways uses two break-beam positions to detect forward and reverse motion and shows the running count on multiplexed seven-segment displays.
Project description
Two IR transmitter–receiver pairs are mounted a short distance apart across the path; edge timing determines direction to increment or decrement the count, which the 8051 updates on 7‑segment displays. The concept extends to passenger counting, and can trigger an over-capacity alarm when a configured threshold is exceeded.
Total list of components (names only)
8051 microcontroller (AT89S52)
7‑segment displays (0.56 inch), 3 digits
IR break‑beam sensor pairs, 2 sets
11.0592 MHz crystal oscillator
33 pF capacitors (for crystal), 2 pcs
Resistors (assorted, incl. 220 Ω)
Transistors (BC547)
Diodes (1N4007)
Perfboard/PCB (7 × 9 cm)
LED (5 mm, red)
5 V, 1 A adapter
40‑pin IC socket
Push buttons (reset, set)
Switch (power)
Cables and connectors
Features
Direction sensing with two spaced IR beams for auto increment/decrement.
Debounced counting, display multiplexing, and nonvolatile max-capacity setting.
Expandable outputs for alarm/buzzer when capacity threshold is crossed.
Applications
Conveyor product counting in packaging and assembly lines.
People counting for buses, trains, classrooms, and halls.
Project Includes:
Fully assembled and tested circuit
Circuit diagram
Source code
(For DIY KITs - only the components will be provided)
Project Types:
- DIY KIT(Do IT YourSelf KIT) - We are providing only components in this kit for this project
- DIY KIT with Code & Circuit Connections - Along with the components, you will get the Code and the Circuit Connections file to help you build the project easily.
- Readymade Breadboard - We are providing fully assembled, tested and ready-made project using plug-n-play jumper wires and breadboard with all the other components, code & circuit diagram.
- Readymade Soldered - We are providing fully assembled, tested and ready-made project soldered on a PCB with all the other components, code & circuit diagram.
Dimensions (cm)
Approx 9 × 7 × 4 (assembled PCB with standoffs and display).
Shipping dimensions (cm)
Approx 20 × 15 × 8cm ( L x W x H) (boxed with padding, adapter, and cabling).
Weight
Approx 0.35–0.45 kg (board + displays + sensors + wiring).
Estimated project weight
Approx 0.50–0.65 kg including adapter and basic packaging.
Notes: All the products are made by LearnElectronics India and not for re-sale.

