Gesture Control with the PAJ7620 Sensor
Share
If you want to build a touchless light switch, a contactless menu, or a robot you wave commands at, describe it to Compoden's AI build assistant and it will recommend the PAJ7620 with the right board and code. The PAJ7620 recognises hand gestures directly on the chip, so your microcontroller receives a clean gesture event instead of having to interpret raw motion.
What the PAJ7620 Recognises
The PAJ7620 detects a set of distinct hand gestures, commonly up, down, left, right, forward, backward, and circular motions. It processes the movement internally and reports which gesture occurred, which spares you from writing complex motion-recognition code. This makes it a friendly way to add touchless control to a project, where waving a hand replaces buttons or a touchscreen, useful in kitchens, workshops, and hygienic settings.
How It Connects
The PAJ7620 communicates over I2C with SDA and SCL lines. It is a 3.3V part, so check whether your breakout includes level shifting before connecting it to a 5V board. Many boards also expose an interrupt pin that fires when a gesture is detected, so your code can sleep or do other work and react only when a hand moves, which is handy for low-power and responsive designs.
Wiring Basics
- VCC to 3.3V (use a level-shifted board if your microcontroller is 5V)
- GND to ground
- SDA to the board's I2C data pin
- SCL to the board's I2C clock pin
- INT to a spare digital pin if you want interrupt-driven gesture events (optional)
Keep the sensor's window clean and unobstructed, and present gestures within its effective close range for reliable detection.
Example Use and Code Notes
A popular project maps gestures to actions: swipe up to brighten a lamp, swipe down to dim it, or wave left and right to change a track. On Arduino and ESP32, the available PAJ7620 libraries initialise the sensor and return a code identifying the detected gesture, so your loop simply checks for a gesture and runs the matching action. Begin by printing each detected gesture to the serial monitor so you can confirm range and orientation before wiring it to real outputs.
Build it with Compoden's AI
Tell Compoden's AI build assistant which gestures you want and what they should control, and it checks the PAJ7620 against real stock, generates the wiring and code for your board, and ships the matched kit to your door in India. You start with gesture detection that already works, then focus on the actions you care about.
Want to control your project with a wave? Describe it to Compoden's AI build assistant and get a complete PAJ7620 gesture kit on the way.
Does the PAJ7620 recognise gestures on its own? Yes, it processes movement internally and reports the detected gesture, so your code does not have to interpret raw motion data.
What gestures can the PAJ7620 detect? It commonly recognises directional swipes such as up, down, left, and right, along with forward, backward, and circular motions.
How close does my hand need to be? The PAJ7620 works at close range, so present gestures within a short distance of the sensor window for reliable detection.