DF Audio Player with IR Module

Hello guys,

i want to play sounds via the Dfplayer on the Arduino UNO.

The sounds should be played if I press a button on a IR module.

Both programs work separately fine, but seem to do not like each other when combined.

The following error appears:

In file included from /Users/benbehrendt/Documents/Arduino/IR_Receiver_Module_Moped/IR_Receiver_Module_Moped.ino:4:0:
/Users/benbehrendt/Documents/Arduino/libraries/IRremote-2.6.1/src/IRremote.h:183:16: error: expected unqualified-id before numeric constant
/Users/benbehrendt/Documents/Arduino/libraries/DFPlayerMini_Fast/src/DFPlayerMini_Fast.h:83:16: note: in expansion of macro ‘REPEAT’
const uint8_t REPEAT = 0;

exit status 1
Fehler beim Kompilieren für das Board Arduino Uno.

What does this mean?? What did I do wrong? Any ideas?

This is the code:
#include “IRremote.h”
#include <SoftwareSerial.h>
#include <DFPlayerMini_Fast.h>

SoftwareSerial mySerial(12, 13); // RX, TX
DFPlayerMini_Fast myMP3;

int receiver = 11; // Signal Pin of IR receiver to Arduino Digital Pin 11

/-----( Declare objects )-----/
IRrecv irrecv(receiver); // create instance of ‘irrecv’
decode_results results; // create instance of ‘decode_results’

/-----( Function )-----/
void translateIR() // takes action based on IR code received

// describing Remote IR codes



case 0xFFA25D: Serial.println(“POWER”); break;
case 0xFFE21D: Serial.println(“FUNC/STOP”); break;
case 0xFF629D: Serial.println(“VOL+”); break;
case 0xFF22DD: Serial.println(“FAST BACK”); break;
case 0xFF02FD: Serial.println(“PAUSE”); break;
case 0xFFC23D: Serial.println(“FAST FORWARD”); break;
case 0xFFE01F: Serial.println(“DOWN”); break;
case 0xFFA857: Serial.println(“VOL-”); break;
case 0xFF906F: Serial.println(“UP”); break;
case 0xFF9867: Serial.println(“EQ”); break;
case 0xFFB04F: Serial.println(“ST/REPT”); break;
case 0xFF6897: Serial.println(“0”); break;
case 0xFF30CF: myMP3.play(1); break;
case 0xFF18E7: Serial.println(“2”); break;
case 0xFF7A85: Serial.println(“3”); break;
case 0xFF10EF: Serial.println(“4”); break;
case 0xFF38C7: Serial.println(“5”); break;
case 0xFF5AA5: Serial.println(“6”); break;
case 0xFF42BD: Serial.println(“7”); break;
case 0xFF4AB5: Serial.println(“8”); break;
case 0xFF52AD: Serial.println(“9”); break;
case 0xFFFFFFFF: Serial.println(" REPEAT");break;

Serial.println(" other button ");

}// End Case

delay(500); // Do not get immediate repeat

} //END translateIR

void setup() /----( SETUP: RUNS ONCE )----/
Serial.println(“IR Receiver Button Decode”);
irrecv.enableIRIn(); // Start the receiver
Serial.println(“Setting volume to max”);

}/–(end setup )—/

void loop() /----( LOOP: RUNS CONSTANTLY )----/
if (irrecv.decode(&results)) // have we received an IR signal?

irrecv.resume(); // receive the next value
}/* --(end main loop )-- */

Please help mee :slight_smile: