top of page

Hand Scanner and Electronics

Goal

The goal of the electronics is to create a robust system that will detect a person near the system with ultrasonic sensors. When a person is near, the system will turn on and run one full cycle of the operation. If there are no people nearby, the system will finish its cycle, and remain still until another person is detected.

Components

The system uses a SparkFun RedBoard, which has the same microprocessor and bootloader as Arduino. The Arduino is connected to a potentiometer, a transistor, and 2 ultrasonic sensors.

Show above: SparkFun RedBoard, ATMega328 microcontroller (left) | HC-SR04 Ultrasonic Sensor (right)

 

Schematic

The RedBoard is connected to the potentiometer to regulate the DC motor speed. It reads the analog voltage after the drop from the potentiometer to determine the PWM signal to be sent to the transistor. Transistor is a PN2222A NPN BJT with base connected to the digital output of the RedBoard. Collector and emitter are connected to + and - terminals of a 24V power supply respectively. The PWM signal sent to the transistor creates the same effect to the motor, thereby slowing it down. A 0.1 uF ceramic capacitor is placed in parallel to the motor to reduce motor noise and allow for smooth transient response.

 

The ultrasonic sensors are connected to the RedBoard, with their pins connected to the digital input. When a certain distance is met, the ultrasonic sensor will "ping" and send a signal to the RedBoard. If either of the sensors ping, the RedBoard begins the cycle and sends the PWM signal, turning on the motor. Once one cycle is done, the sensors search for people once more.

bottom of page