This blog will guide you on interfacing HW-201 IR proximity sensor with ARIES v3.0 boards. Here, an AC remote is used as the IR source and sensor(HW-201) as the IR receiver.
IR source
An IR (infrared) sensor is an electronic component that detects and measures the infrared radiation ( IR signals are not observable by the human eye) in its environment. When a human, object, or anything comes closer to the sensor, the IR from the LED reflects off of the object and is detected by the receiver..
We can use any device which can radiate infrared. Other way we can say any thing having temperature radiates infrared. Like surface of the earth, Sun, human body, optical fibers, thermal imaging cameras, electric heaters, remote control, etc all these will emit infrared waves that is not visible to our naked eyes.
IR receiver
Receiver will receive infrared waves and sense it. This receiver module act as sensor which will help us to get the IR codes in a proper format. HW-201 is an IR detection module consists of an infrared transmitter, an infrared detector and its circuit but in this case I am using only infrared detector and remove the infrared transmitter from the module.
Prerequisites
- Windows 10 or above/Linux (64 bit)
- Arduino IDE
- VEGA ARIES Board support package
Components Required
- ARIES v3.0 Board
- USB type C to USB type A cable
- HW-201 IR Proximity sensor
- Jumper Wires
Circuit Diagram
Connections:
HW201 IR Proximity sensor | ARIES V3 board |
GND | GND |
VCC | 3V3 |
OUT | GPIO-4 |
Procedure
Open and set up the Arduino IDE as described in Getting Started with ARIES v3.0.
- Make sure you have selected ARIES v3 Board from Tools -> Board -> VEGA Processor: ARIES Boards -> ARIES v3
- Select Tools -> Flash Mode -> Enabled
- Select Programmer as VEGA FLASHER from Tools -> Programmer -> VEGA FLASHER
- Also select appropriate port from Tools -> Port -> COM* (ARIES Board)
Now, Open Files -> Examples -> Under Examples for ARIES v3 -> GPIO-> IR_Sensor_HW201
Finally Upload the code to ARIES v3.0 board
Output
GREEN LED on the aries board will ON when the IR sensor receives infrared waves. You can show an AC remote or TV remote to test the output
Note: IR proximity sensor is sensitive to light, so make sure bright light is not directly falling on the sensor to get exact output.
Figure: IR proximity sensor connected to ARIES v3.0 board
With IR objects (AC Remote) infront of IR sensor the internal GREEN LED in ARIES board and indicator LEDs are ON
With IR objects (TV Remote) infront of IR sensor the internal GREEN LED in ARIES board and indicator LEDs are ON