Go Down

Topic: Raw Infrared Data Problem for IR Remote Controller (Read 13522 times) previous topic - next topic

heidiheweidy

Hello, here's my IRRecvDump output:
Code: [Select]
4A6D830F
Unknown encoding: 4A6D830F (32 bits)
Raw (212): 32428, 3750, -1850, 500, -400, 500, -1350, 550, -400, 500, -1350, 500, -450, 500, -1350, 550, -400, 500, -1350, 500, -450, 500, -1350, 500, -450, 500, -1350, 500, -1350, 500, -450, 500, -1350, 500, -450, 500, -1350, 500, -1400, 450, -1400, 500, -1350, 500, -450, 500, -400, 500, -1400, 450, -1400, 500, -450, 500, -400, 550, -400, 500, -450, 500, -1350, 500, -400, 550, -400, 500, -450, 500, -400, 500, -450, 500, -450, 450, -1400, 500, -450, 450, -450, 500, -450, 500, -450, 450, -1400, 500, -400, 500, -450, 500, -450, 500, -1350, 500, -450, 500, -400, 500, -450, 500, -1350, 550, -400, 500, -400, 550, -400, 500, -450, 450, -1400, 500, -450, 450, -450, 550, -400, 500, -450, 500, -400, 500, -450, 500, -400, 500, -450, 500, -450, 500, -400, 550, -400, 500, -450, 500, -400, 550, -1350, 500, -400, 500, -450, 500, -400, 550, -400, 500, -450, 500, -400, 500, -450, 500, -450, 450, -450, 550, -400, 500, -400, 500, -1400, 500, -450, 500, -400, 500, -450, 500, -400, 500, -450, 500, -450, 500, -400, 500, -450, 500, -450, 450, -450, 550, -1300, 500, -450, 500, -1350, 500, -1400, 450, -1400, 500, -1350, 500, -1400, 500, -400, 550, -400, 500, -450, 500, -400, 500, -450, 500, -1350, 500, -1350, 500,

AnalysIR

Good...

Attached is an image of the signal trace, which looks clean.

Below is some automatically generated C code from AnalysIR to send this signal using IRremote. You should just incorporate this into your sketch.
Code: [Select]
/*
Automatically Generated by AnalysIR - Batch Export Utility
Registered to:
Session History
Type : Key : Value : Bits
0 : RAW :  :  : 0
*/
int khz=38;//modulation frequency of 38kHz

// NB: Not all protocols are supported by IRremote or IRLib. You may need to edit the code below manually
// Automatically Generated by AnalysIR for xx, visit http://www.AnalysIR.com or email info@....... for further details


unsigned int Signal_0_0[] = {3750,1850,500,400,500,1350,550,400,500,1350,500,450,500,1350,550,400,500,1350,500,450,500,1350,500,450,500,1350,500,1350,500,450,500,1350,500,450,500,1350,500,1400,450,1400,500,1350,500,450,500,400,500,1400,450,1400,500,450,500,400,550,400,500,450,500,1350,500,400,550,400,500,450,500,400,500,450,500,450,450,1400,500,450,450,450,500,450,500,450,450,1400,500,400,500,450,500,450,500,1350,500,450,500,400,500,450,500,1350,550,400,500,400,550,400,500,450,450,1400,500,450,450,450,550,400,500,450,500,400,500,450,500,400,500,450,500,450,500,400,550,400,500,450,500,400,550,1350,500,400,500,450,500,400,550,400,500,450,500,400,500,450,500,450,450,450,550,400,500,400,500,1400,500,450,500,400,500,450,500,400,500,450,500,450,500,400,500,450,500,450,450,450,550,1300,500,450,500,1350,500,1400,450,1400,500,1350,500,1400,500,400,550,400,500,450,500,400,500,450,500,1350,500,1350,500,1000}; //AnalysIR Batch Export - RAW

irsend.sendRaw(Signal_0_0, sizeof(Signal_0_0)/sizeof(int), khz); //AnalysIR Batch Export - RAW
// AnalysIR IR Protocol: RAW, Key:  


I am not sure which AC unit you are trying to control. Please let us know the AC model & the model of remote control, just for reference.

However, the signal has some of the characteristics of a Panasonic signal. If I am correct the signal above can be cleaned up further by replacing the values to one of the following.
3840
1920
480
1380
Just replace the values in the code above to the nearest ones in this list, if the code example does not work out.

PS: could you also let me know which model of IR receiver you are using? tnx

heidiheweidy

it's working now!!! thank u so much! :D
im using arduino uno
i just want to know what exactly u did to convert such an array into those values that u sent

AnalysIR

Great...


i just want to know what exactly u did to convert such an array into those values that u sent


I just imported the 'RAW' IRremote output you posted into AnalysIR, which also has a facility to export the 'C' code of any imported or recorded Infrared signal in IRremote, IRLib and several other common IR formats. For other signals all you have to do is just replace the timing values to match the new signal.

Also, please let us know, for future reference:
1. The model no of your Sharp Air Conditioner
2. The model no of your remote control
3. The model no of the IR receiver you used (or a link to the data sheet)
4. Finally, it might be useful to others if you posted the final Arduino code that worked for you.

heidiheweidy

so, my remote controller is CRMC-A808JBEZ
my AC is SHARP model is AY-A12LSE
my ir receiver type is: Infrared Receiver Diode IR004
and the code that finally made turning the AC on work (thanks to analysir) is:
Code: [Select]
/*
* IRremote: IRsendDemo - demonstrates sending IR codes with IRsend
* An IR LED must be connected to Arduino PWM pin 3.
* Version 0.1 July, 2009
* Copyright 2009 Ken Shirriff
* http://arcfn.com
*/

#include <IRremote.h>

IRsend irsend;

int RECV_PIN = 11;
IRrecv irrecv(RECV_PIN);
decode_results results;
unsigned long value;
/*
Automatically Generated by AnalysIR - Batch Export Utility
Registered to:
Session History
Type : Key : Value : Bits
0 : RAW :  :  : 0
*/
int khz=38;//modulation frequency of 38kHz

// NB: Not all protocols are supported by IRremote or IRLib. You may need to edit the code below manually
// Automatically Generated by AnalysIR for xx, visit http://www.AnalysIR.com or email info@....... for further details


unsigned int Signal_0_0[] = {3750,1850,500,400,500,1350,550,400,500,1350,500,450,500,1350,550,400,500,1350,500,450,500,1350,500,450,500,1350,500,1350,500,450,500,1350,500,450,500,1350,500,1400,450,1400,500,1350,500,450,500,400,500,1400,450,1400,500,450,500,400,550,400,500,450,500,1350,500,400,550,400,500,450,500,400,500,450,500,450,450,1400,500,450,450,450,500,450,500,450,450,1400,500,400,500,450,500,450,500,1350,500,450,500,400,500,450,500,1350,550,400,500,400,550,400,500,450,450,1400,500,450,450,450,550,400,500,450,500,400,500,450,500,400,500,450,500,450,500,400,550,400,500,450,500,400,550,1350,500,400,500,450,500,400,550,400,500,450,500,400,500,450,500,450,450,450,550,400,500,400,500,1400,500,450,500,400,500,450,500,400,500,450,500,450,500,400,500,450,500,450,450,450,550,1300,500,450,500,1350,500,1400,450,1400,500,1350,500,1400,500,400,550,400,500,450,500,400,500,450,500,1350,500,1350,500,1000}; //AnalysIR Batch Export - RAW



void setup()
{
  Serial.begin(9600);
    irrecv.enableIRIn(); // Start the receiver

}

void loop() {
  while(Serial.available()>= 0){
         if (Serial.read() == '0') {
         Serial.println("Transmitting");
         for (int i = 0; i < 3; i++) {
irsend.sendRaw(Signal_0_0, sizeof(Signal_0_0)/sizeof(int), khz); //AnalysIR Batch Export - RAW
// AnalysIR IR Protocol: RAW, Key: 
            delay(40);

         }
       }else if (irrecv.decode(&results)) {
       Serial.println("Receiving");
       Serial.println(results.value, HEX);
       value = results.value;

      irrecv.resume(); // Receive the next value
         }
  }
}
   

madmexx

#20
May 03, 2014, 02:25 pm Last Edit: May 03, 2014, 02:28 pm by madmexx Reason: 1
hi,can you please upload full sketch? thank you
Code: [Select]

Code:

for (int i = 0; i < count; i++) {
     Serial.print(results->rawbuf[i]*USECPERTICK, DEC);
     Serial.print(",");
   }

GUNASEELAN

Carrier Air Conditioners  On/Off :

Switch On :

9368D502
Unknown encoding: 9368D502 (32 bits)
Raw (100): 7048 4450 -4300 600 -1550 600 -500 600 -1550 650 -1550 600 -500 600 -500 600 -1550 600 -500 600 -500 600 -1550 600 -500 600 -500 600 -1550 600 -1600 600 -450 650 -1550 600 -500 600 -450 650 -1550 600 -1550 650 -1550 600 -1550 650 -1550 600 -1550 650 -1550 600 -1550 600 -500 600 -500 600 -500 600 -450 650 -450 650 -450 600 -500 600 -500 600 -450 650 -450 650 -450 600 -500 600 -500 600 -500 600 -1550 600 -1550 650 -1550 600 -1550 650 -1550 600 -1550 650 -1550 600 -1550 600


Switch Off :

FA36E9A0
Unknown encoding: FA36E9A0 (32 bits)
Raw (100): 7206 4450 -4300 650 -1550 600 -500 600 -1550 600 -1550 650 -450 650 -450 600 -1600 600 -450 650 -450 600 -1600 600 -450 650 -450 650 -1550 600 -1550 600 -500 600 -1550 650 -450 600 -1600 600 -1550 600 -1600 600 -1550 600 -500 600 -1550 650 -1550 600 -1550 600 -500 600 -500 600 -500 600 -450 650 -1550 600 -500 600 -450 650 -1550 600 -1550 650 -1550 600 -500 600 -450 650 -450 650 -450 600 -500 600 -500 600 -450 650 -450 650 -1550 600 -1550 600 -1600 600 -1550 600 -1550 600

The Hex codes , which i receive is the same everytime.  smiley  but the raw data varies ..

Now How should  I, write the irsend to send this code for the air conditioner?

borntoroll

#22
Jul 20, 2016, 05:29 pm Last Edit: Jul 23, 2016, 10:47 pm by borntoroll
Assistance is needed. Can't change the rawbuf size. Tried adding the #define RAWBUF 200 // Length of raw duration buffer to the irremote.h and the scetch and i get 100 every time. Thanks

 Quick update: Managed to get the job done (recording a long A/C IR signal) with the help of AnalysIR sketch which is easy available through some searching the www. But the question remains.

AnalysIR

Assistance is needed. Can't change the rawbuf size. Tried adding the #define RAWBUF 200 // Length of raw duration buffer to the irremote.h and the scetch and i get 100 every time. Thanks

 Quick update: Managed to get the job done (recording a long A/C IR signal) with the help of AnalysIR sketch which is easy available through some searching the www. But the question remains.
You can alter RAWBUF within the library, in the file named IRremoteInt.h
The maximum value is 255, which will cover many but not all AC signals.

To ensure the value is updated properly, you may have to restart the IDE to force a recompile of the library.

Another possible issue is not editing the correct copy of the file - if you have multiple versions of the IDE installed.

NourAmin

Hello ,
I have SHARP AC , now i can send signal ON and OFF only, but i want to change temperature , speed of fan and swing , can anyone send codes of them ?

thanks in advance

AnalysIR

It is most likely you will have to reverse engineer the protocol.

If someone already has that done, they would need at least the make and model number of both AC unit & remote control (not just the manufacturer's name)

NourAmin

#26
Sep 26, 2018, 02:18 pm Last Edit: Sep 26, 2018, 03:51 pm by NourAmin
Sharp AC
model number of remote CRMC-A922JBEZ ,
model number of AC is AY-AP24NME
on and off works well, but i can't change temperature, swing or fan

here are codes of on, off, change temperature

//on AC


      unsigned int Signal_ON_0[] = {3828,1824,532,408,536,1348,536,408,560,1324,536,408,536,1348,536,408,560,1328,512,432,536,1348,536,408,536,1352,564,1324,540,404,536,1356,532,408,536,1348,540,1352,536,1348,536,1352,560,380,540,404,536,1348,540,1348,536,408,536,404,536,408,560,380,564,1324,536,408,532,416,560,380,536,1348,536,412,532,408,564,1328,536,404,564,384,532,408,536,404,540,1352,560,384,536,404,536,408,536,1348,536,412,536,404,536,404,540,408,532,1352,536,408,532,412,532,408,536,1352,536,404,540,404,540,404,536,408,536,408,532,412,536,408,536,404,564,380,536,412,536,404,540,404,540,404,536,1352,536,408,544,400,540,408,532,408,560,380,540,404,564,380,536,404,540,408,532,408,564,376,540,1352,536,404,536,408,536,408,536,404,564,380,564,380,568,372,564,380,536,412,532,408,540,404,564,380,536,1352,536,1356,536,1352,536,1352,540,1352,536,408,536,408,532,412,532,412,536,1348,536,408,536,1352,536};

//off AC

      unsigned int Signal_OFF_1[] = {3832,1820,540,404,536,1356,532,408,536,1352,536,404,540,1348,560,380,536,1352,560,376,536,1352,536,404,540,1348,536,1348,536,408,536,1348,536,412,536,1348,536,1356,536,1352,532,1352,540,408,532,408,536,1352,564,1328,532,404,564,380,536,408,536,404,536,1352,536,404,540,404,564,380,536,1348,564,380,536,404,536,1352,532,404,540,404,536,412,532,412,536,1348,564,380,536,404,544,404,532,412,536,1348,564,384,536,408,560,380,536,1352,540,408,536,404,532,412,536,1348,536,408,512,428,536,408,532,412,536,404,536,404,536,408,536,404,540,404,536,408,536,404,540,404,564,380,536,1352,540,404,536,408,560,384,536,404,536,412,532,408,540,404,536,408,536,408,536,408,536,408,512,1372,540,404,540,408,532,408,536,408,532,412,532,412,536,404,536,408,532,412,536,404,564,380,536,408,560,1324,564,1324,536,1352,536,1352,536,1356,508,440,528,408,536,408,540,1348,536,412,536,404,564,1328,536};

//change temperature to 25 with one degree of fan
  unsigned int Signal_25_FAN_1[] = {3850,1800,500,450,500,1350,500,400,550,1350,500,450,500,1350,500,450,500,1350,550,400,500,1400,500,450,500,1350,500,1350,550,400,500,1350,550,450,500,1350,500,1350,500,1400,500,1350,500,450,500,450,500,1350,500,1400,500,400,550,400,500,450,500,400,550,1350,500,450,500,450,500,450,500,400,500,450,500,400,550,1350,500,450,500,450,500,400,500,450,500,1400,450,450,500,450,500,450,500,1350,500,1400,500,400,500,450,500,450};
     

Go Up