IR remote error

I just ran into that myself. That error is the result of running code written with the old IRRemote library. The new version of the library has made significant changes. There are several examples to help learn the new version.

Here is the code written with the newer library that does the kind of the same as your posted code.

#include <IRremote.h>

const byte IR_RECEIVE_PIN = 11;

void setup()
{
   Serial.begin(115200);
   Serial.println("IR Receive test");
   IrReceiver.begin(IR_RECEIVE_PIN, ENABLE_LED_FEEDBACK);
}

void loop()
{
   if (IrReceiver.decode())
   {
      Serial.println(IrReceiver.decodedIRData.command, HEX);
      IrReceiver.resume();
   }
}

This is actually kind of a bummer cause I have a lot of code written for the old library.

You have 2 choices. Learn the new library or roll back to (install) a previous version. Previous versions are available through the library manager.

2 Likes