COMBINE BLUETOOTH + DF MINIPLAYER + INFRARED

Best regards, I was writing to receive your help. I was able to arrange two separate Bluetooth codes with the miniplayer df

Saludos cordiales les escribía para recibir su ayuda.Ya pude combinar dos códigos separados el bluetooth con el df miniplayer.

Now I would like to increase one more infrared code but it makes me an error

Ahora quisiera aumentar un código mas el infrarrojo pero me marca error

examples bluetooth + df mini player codigo okey

/*
Autor: Ivan
control de voz = android + bluetooth + infrared
*/

/**DFPlayer Mini/
#include <SoftwareSerial.h>
#include <DFRobotDFPlayerMini.h>
SoftwareSerial mySoftwareSerial(10,11);
DFRobotDFPlayerMini myDFPlayer;

/**INFRARROJO/
#include "IRremote.h"
int receiver = 11;

IRrecv irrecv(receiver);
decode_results results;

String mensaje;

void setup() {
Serial.begin(9600);//Iniciando comunicación Serial a 9600 baudios
pinMode(2, OUTPUT); //declarando

/**DFPlayer Mini/
mySoftwareSerial.begin(9600);
Serial.begin(9600);
myDFPlayer.begin(mySoftwareSerial);
Serial.println("Modulo funcionando");
myDFPlayer.volume(30);/Volumen maximo/

/**INFRARROJO/

Serial.begin(9600);
Serial.println("ARTIFICIAL INTELLIGENCE ");
irrecv.enableIRIn();
pinMode(17, OUTPUT);//MALAGASY

}

void loop() {
while (Serial.available()) { //Confirmando que la comunicación Serial esté disponible para hacer la lectura del mensaje
delay(10);//para dar estabilidad al programa
char c = Serial.read();//c almacena la lectura de la comunicación serial
mensaje += c; //sumando el contenido de la variable c en la variable mensaje
}
if (mensaje.length() > 0)

{ //verificando que la variable mensaje no esté vacía
if (mensaje == "*hello") {
digitalWrite(2, HIGH);
delay(200);
myDFPlayer.play(1);//Reproduce canción 0001.mp3 planificada asi

}
else if (mensaje == "*bye") {
myDFPlayer.play(2);//Reproduce canción 0002.mp3
digitalWrite(2, LOW); //y ejecutando instrucciones
}

}

mensaje = ""; //reseteando variable
}

this is the original infrared that if it works separately with a Sony control

But when I want to combine the void loop () I get an error.

How do I have to agree this part.

Can someone please help me

I want the df mini player to work with Bluetooth and infrared

#include "IRremote.h"
int receiver = 11;

IRrecv irrecv(receiver);
decode_results results;

void setup()
{
Serial.begin(9600);
Serial.println("ARTIFICIAL INTELLIGENCE ");
irrecv.enableIRIn();

pinMode(17, OUTPUT);//MALAGASY

void loop()
{
if (irrecv.decode(&results))

{
switch (results.value)
{

case 0x2CE9: Serial.println("Tecla: Play");
digitalWrite(17, !digitalRead(17));
delay(200);
digitalWrite(17, LOW);
break;

}
irrecv.resume();
}
delay(300);
}

Please read the forum guide in the "read this" sticky post. The way you are posting code is breaking forum rules. Modify your 2 posts and correct them. Thank you.