Infrared receiver

From Microduino Wiki
Jump to: navigation, search


Microduino-IR receiver is used to receive infrared signal from Infrared transmission. It can receive infrared signal within 10m.


  • Electrical specification
    • Operation voltage: 3.3V~5V
  • Tech parameters
    • Sensing distance:10m
  • Size
    • Size of the LED: 5mm
    • Size of the board: 10mm*20mm
    • 1.27mm-pitch 4PIN interface
  • Connection Method
    • GND, VCC, signal port and NC. The signal port can be defined by users.



Module Number Function
mCookie-CoreUSB 1 Core board
mCookie-Hub 1 Sensor pin board
Microduino-IR Receiver 1 Infrared receiving


Setup 1: Connect the IR receiver's interface with the Hub's D10 digital port.

  • Setup 2: Connect the core, Hub and IR receiver to a computer with a USB cable.


  • Open " IRsendDemo " program in the libraries.
  • include <IRremote.h> Use infrared library function
  • int RECV_PIN = 10; Define the infrared receiving pin as 10, which can also be changed by users. (For example: Change " RECV_PIN = 11" in the program examples to " RECV_PIN = 10". )
  • IRrecv irrecv(RECV_PIN); Define infrared receiving object
  • irrecv.enableIRIn(); Start infrared receiving
  • Receive infrared signal and output
 if (irrecv.decode(&results)) {      
   Serial.println(results.value, HEX);
  • You can open the serial monitor and use the infrared remote controller to send signals to the infrared receiving head. When you see the LED light on the IR-receiver blinks once, it means the receiving head has gotten the signals while the serial console will print decoded data.


It can be used in infrared remote control, which is able to be matched with all kinds of infrared remote controller. You need to make sure the infrared signal type and protocol format before using.