'HANDS-FREE'
a door opening mechanism



The elderly and people with special needs often have trouble navigating through their environment and managing objects that we often take for granted. There will also be an increase in the number of elderly as the population ages. Hence, it is necessary that everyday objects be reinvented and redesigned, taking into account the difficulties and struggles faced by this group of people. The aim of this project is to redesign the door handle to increase convenience for people with limited hand mobility and strength. The challenge here is to create a system that is completely hardware (i.e. no use of microprocessors). The electronics used are also limited to the basic few components (e.g. D flip flops, logic gates, IR sensors).

Components Used

Item No Item Name Model Quantity
1OpampLM3587
2D Flip Flop40134
3NAND gate40111
4NPN BJTBC108B4
5IR EmitterTIL812
6IR ReceiverTIL382
7Diode-4
8DC Motor-1
9Push Button-1
10Plastic Board-3 pieces
Resistors
114.7k ohms-1
1222, 39, 12k, 22k, 180k ohms-4 each
13470, 1k, 27k, 47k, 100k, 560k, 1M ohms-2 each
Capacitors
144.7uF-5
153.3uF-1
16330p, 1800p, 3300pF-2 each


Design Outline

In order to create the door-opening mechanism, a box is used as the controller and swiping across the box opens and closes the door. First, the system has to identify the region in which the hand is in. This is done by attaching an IR emitter-receiver pair on both sides of the box.



By comparing the amplitude of the signal received by the receivers, the position of the hand relative to the IR pair in the box can be determined. Next, a swipe direction detection circuit has to be designed to differentiate between a right swipe and a left swipe. Finally, a motor control circuit is required to turn the motor clockwise when a right swipe is detected and anti-clockwise when a left swipe is detected.



IR Proximity Sensing Circuit

In order to make our proximity sensing circuit resistant to noise from ambient light fluctuations, the infrared signal emitted from the emitter is modulated at a frequency of 5kHz. The signal received by the receiver is then passed through a high pass filter of 0.5kHz to filter out the DC noise. The recovered 5kHz signal is then converted to a DC signal by passing it through a weak passive RC filter. As the signal is too weak for any decent comparison, an amplifier is used to amplify the resultant DC signal before it proceeds to the amplitude comparison part of the system.

IR Emitter Circuit

To modulate the signal emitted by the IR emitter, a relaxation oscillator is used to drive the IR emitter. In order to achieve a frequency of 5kHz, the RC values at the inverting input of the opamp is determined to be 330pF and 270k ohms. These values gave a resulting square wave with a frequency of about 4.24kHz.


1. Circuit diagram of relaxation oscillator in LTSpice; 2. Achieved square wave

IR Receiver Circuit

At the receiver, a non-inverting high pass filter has to be used to filter out the DC noise and retain the 5kHz signal received from the emitter. Since noise contains frequencies below 0.5kHz, a high pass filter with a cut-off frequency of 0.5kHz is used. This also ensures a safety margin should the frequency of the emitted IR signal deviates slightly. The RC values of the high pass filter is determined to be 1800pF and 180k ohms. The filter is also designed to have a gain of about 6 times. With these values, an AC simulation of the filter is done in LTSpice. The filtered signal received by the receiver gives rounded edges due to the decreased bandwidth of the filter as a result of gain > 1 (i.e. higher frequencies are filtered out).


1. Circuit diagram of high pass in LTSpice; 2. AC simulation; 3. Filtered signal from IR receiver

Next, the signal is passed through a passive RC filter to convert the oscillating signal to a DC signal. This is to allow a more accurate comparison of the signal amplitude at the amplitude comparison stage of the system. The RC values at this stage are determined through LTSpice simulation as shown in Figures 10 and 11. In the simulation, a square wave with 5kHz frequency is passed through the high pass filter followed by the passive RC filter. The RC values are determined to be 560k ohms and 3300pF.


1. Simulation circuit to determine RC values of filter; 2. Voltage output of RC filter (red curve)

Finally, the signal has to be amplified using a non-inverting amplifier with a gain of 3 times. This is achieved with R values 22kΩ and 47kΩ. The amplifying stage is added to the LTSpice simulation. A DC sweep is done at the input and the derivative of the voltage output is plotted. The amplifier achieved a gain of about 3 times. The resultant amplified voltage (2.4V) is about 3 times that of the original voltage (0.8V).


1. Simulation Circuit with amplifying stage; 2. Simulation of amplifier; 3. Voltage output after amplification (turquoise curve)

The complete IR receiver circuit with the 3 stages is as shown below:



IR Characterisation

Using the amplified signal, characterisation has to be done to determine the relationship between the signal amplitude change and the distance an object is away from the sensor. This will allow us to better design the amplitude comparison stage of the system. For characterisation, a hand placed at a distance from the both left and right sensors and the resultant amplitude is recorded. While the left IR pair is more sensitive than the right IR pair, both curves follow a similar trend where the sensitivity of the sensors increases with decreasing distance. Hence, there is a need for 2 pairs of sensors for more accurate detection of the presence of a hand on either side of the box.



Amplitude Comparison

The aim of this stage of the system is to differentiate transitions between different regions of the controller. A transition from one region to another is characterised by a rising edge from the respective pins.



A series of 3 comparators are used to differentiate 6 different transitions between regions 1 and 2, 2 and 3, as well as 3 and 4. For a transition between regions 2 and 3, a comparator is used compare the amplitudes of the signals from the 2 IR-pairs. Since the amplitude of both proximity sensing circuits have similar characteristics with respect to distance, both signals can be compared. An object in region 2 will result in signal from IR circuit 1 being of higher amplitude than that of IR circuit 2. Hence, the comparator output will be low. Conversely, an object in region 3 will result in a high comparator output. A transition from region 2 to 3 will therefore give a rising edge. A NOT gate (derived from a NAND gate with shorted inputs) can be used to give a rising edge for transitions from 3 to 2.

Similarly, transitions between region 1 and 2 as well as region 3 and 4 uses a comparator set at a threshold voltage. As the sensitivity of the sensors differs slightly for different skin tones, a variable resistor is used in a voltage divider to vary the threshold voltage (e.g. a darker hand tend to reflect less IR and hence voltage threshold has to be reduced).

Swipe Detection



To differentiate between right and left swipes, a series of D Flip Flops are used. Since output pins 1, 4 and 6 (from the Amplitude Comparison stage) give a rising edge for transitions from region 1 to 2, 2 to 3 and 3 to 4 respectively, the Q at subsequent D Flip Flops will be pulled down one after another when a right swipe occurs. A completed right swipe will give a low Q at the last D Flip Flop. Once a swipe is detected, the circuit has to be reset through a push button which gives a high to the SET pins of all 3 D Flip Flops before it can detect another right swipe. The detection circuit for a left swipe is similar with the output pins 2, 3 and 5 (from the Amplitude Comparison stage) as inputs into the detection circuit.

Motor Control



In order for the DC motor to rotate bidirectionally, a H-bridge is used. The degree of rotation of the motor also has to be controlled. To achieve this, a timing circuit it required. A capacitor is used to time the circuit and stop rotation of the motor after a certain period of time. The output of the swipe detection circuit is connected as input to the motor control circuit. If a swipe is not detected, the capacitor will stay charged. Hence, the inverting input of the comparator will be of a higher value than 5V (i.e. 6V). The comparator therefore gives a low output. The transistor connected to the comparator output will be turned off and the motor will not rotate. When a swipe is detected, the input pin is pulled low. This discharges the capacitor and the voltage of at the inverting input of the opamp falls below 5V. The output of the comparator will therefore be pulled high until the capacitor charges back up to 6V. The transistor will therefore be turned on for the capacitor charge and discharge time period and the motor will rotate for that time period.

Implementation

Plastic sheets are used to make the controller box and holes are drilled to house the IR emitters and detectors. The following video is a short demonstration of the system.




1. Circuit implementation of door opening mechanism; 2. Controller box with IR sensors

Improvements

There are plenty of improvements that can be made to the system. The first and most obvious improvement is to automatically reset the swipe detection circuit without using the push button. The turn of the door can also controlled to a finer degree. I might just work on the improved version over the holidays - I just need an oscilloscope and a power source...