Particle Photon with Samsung Split AC

Post Reply
tmoreira2020
Posts: 2
Joined: Mon Feb 19, 2018 7:48 am

Particle Photon with Samsung Split AC

Post by tmoreira2020 »

Hi there, I built a simple signal dumper and got this codes from the remote control of my AC.

Code: Select all

Encoding  : SANYO
Code      : FFFFFFFF (0 bits)
Timing[115]:
     + 550, - 450     + 500, -1450     + 550, - 400     + 550, - 450
     + 550, - 450     + 550, - 400     + 550, - 450     + 550, - 450
     + 500, - 500     + 500, -1450     + 500, - 500     + 500, - 450
     + 500, -1500     + 500, -1450     + 500, - 450     + 550, -1450
     + 500, -1450     + 500, -1450     + 550, -1400     + 550, -1450
     + 500, - 450     + 550, - 450     + 500, - 450     + 550, - 500
     + 500, - 450     + 500, - 500     + 500, - 450     + 500, - 500
     + 500, - 500     + 500, - 450     + 550, - 450     + 500, - 450
     + 550, - 450     + 550, - 450     + 500, - 450     + 550, - 450
     + 500, - 500     + 500, - 450     + 550, - 450     + 500, - 450
     + 550, - 450     + 500, - 500     + 500, - 500     + 450, - 500
     + 500, - 500     + 500, - 500     + 450, - 500     + 500, - 500
     + 500, - 450     + 550, - 450     + 500, - 500     + 500, - 450
     + 550, - 450     + 500, - 450     + 550, -1450     + 500, -1450
     + 500, -2900     +3000
unsigned int  rawData[115] = {550,450, 500,1450, 550,400, 550,450, 550,450, 550,400, 550,450, 550,450, 500,500, 500,1450, 500,500, 500,450, 500,1500, 500,1450, 500,450, 550,1450, 500,1450, 500,1450, 550,1400, 550,1450, 500,450, 550,450, 500,450, 550,500, 500,450, 500,500, 500,450, 500,500, 500,500, 500,450, 550,450, 500,450, 550,450, 550,450, 500,450, 550,450, 500,500, 500,450, 550,450, 500,450, 550,450, 500,500, 500,500, 450,500, 500,500, 500,500, 450,500, 500,500, 500,450, 550,450, 500,500, 500,450, 550,450, 500,450, 550,1450, 500,1450, 500,2900, 3000};  // SANYO FFFFFFFF
unsigned int  data = 0xFFFFFFFF;

Encoding  : SANYO
Code      : FFFFFFFF (0 bits)
Timing[113]:
     + 500, -1450     + 550, - 400     + 550, - 450     + 550, - 450
     + 500, - 450     + 550, - 450     + 550, - 450     + 500, - 500
     + 500, - 450     + 500, -1450     + 550, - 450     + 500, - 500
     + 500, -1450     + 550, -1400     + 550, -1400     + 550, -1450
     + 500, - 450     + 550, -1400     + 550, -1450     + 500, -1450
     + 550, -1450     + 500, -1450     + 500, -1450     + 500, -1450
     + 550, -1400     + 550, - 450     + 550, - 450     + 500, - 450
     + 550, -1450     + 500, -1450     + 500, -1450     + 550, - 450
     + 500, - 500     + 500, - 450     + 500, - 500     + 500, - 500
     + 500, - 450     + 500, -1450     + 550, -1450     + 500, - 450
     + 550, -1450     + 500, - 450     + 550, - 450     + 500, - 450
     + 550, -1450     + 500, - 450     + 550, - 450     + 500, - 500
     + 500, - 450     + 550, - 450     + 500, - 500     + 500, - 450
     + 500, - 500     + 500, - 500     + 500, -1450     + 500, -1450
     + 550
unsigned int  rawData[113] = {500,1450, 550,400, 550,450, 550,450, 500,450, 550,450, 550,450, 500,500, 500,450, 500,1450, 550,450, 500,500, 500,1450, 550,1400, 550,1400, 550,1450, 500,450, 550,1400, 550,1450, 500,1450, 550,1450, 500,1450, 500,1450, 500,1450, 550,1400, 550,450, 550,450, 500,450, 550,1450, 500,1450, 500,1450, 550,450, 500,500, 500,450, 500,500, 500,500, 500,450, 500,1450, 550,1450, 500,450, 550,1450, 500,450, 550,450, 500,450, 550,1450, 500,450, 550,450, 500,500, 500,450, 550,450, 500,500, 500,450, 500,500, 500,500, 500,1450, 500,1450, 550};  // SANYO FFFFFFFF
unsigned int  data = 0xFFFFFFFF;
With these codes I built a simple sender code like this which gives the following reads on my "signal dumper"

Code: Select all

#include <BeanSQ-IRremote.h>

IRsend irsend;

void setup(){}

void loop() {
  int khz = 38;
  unsigned int on1[115] = {600,450, 500,1400, 600,400, 550,450, 550,450, 500,450, 550,450, 550,400, 550,450, 550,1400, 550,450, 550,450, 500,1400, 550,500, 500,450, 550,1400, 550,1400, 600,1400, 550,1350, 600,1400, 550,450, 550,450, 550,400, 550,500, 500,450, 500,500, 500,450, 500,500, 500,500, 500,450, 550,450, 550,400, 550,450, 550,450, 500,450, 550,450, 550,400, 550,450, 550,450, 500,450, 550,450, 550,450, 500,500, 500,450, 500,500, 500,450, 550,450, 550,450, 500,450, 550,450, 550,450, 500,450, 550,1400, 550,1400, 550,1400, 600,1400, 500,2900, 3000};
  unsigned int on2[113] = {550,1400, 550,450, 550,450, 500,450, 550,450, 500,450, 550,450, 550,450, 500,450, 500,1500, 500,450, 550,450, 550,1400, 550,450, 550,1400, 550,1400, 550,450, 550,1400, 550,1400, 550,1450, 500,1450, 550,1400, 550,1450, 500,1450, 550,1400, 550,450, 550,400, 550,450, 550,1400, 550,1400, 550,1450, 550,400, 550,450, 550,450, 500,450, 550,450, 500,500, 500,1450, 550,1400, 550,450, 550,1400, 550,450, 550,400, 550,450, 550,1400, 550,450, 550,400, 550,450, 550,450, 500,500, 500,450, 500,500, 500,1450, 550,1400, 550,1450, 500,1450, 500};
  
  irsend.sendRaw(on1, sizeof(on1) / sizeof(on1[0]), khz);
  delay(50);
  irsend.sendRaw(on2, sizeof(on2) / sizeof(on2[0]), khz);
  
  delay(5000); //In this example, the signal will be repeated every 5 seconds, approximately.
}

Code: Select all

Encoding  : UNKNOWN
Code      : C5504CE4 (32 bits)
Timing[115]:
     + 600, - 400     + 550, -1350     + 650, - 350     + 600, - 400
     + 600, - 350     + 550, - 450     + 550, - 450     + 600, - 350
     + 550, - 450     + 550, -1350     + 600, - 400     + 600, - 400
     + 500, -1400     + 550, - 500     + 500, - 450     + 550, -1350
     + 600, -1350     + 600, -1400     + 550, -1300     + 650, -1350
     + 550, - 450     + 550, - 450     + 550, - 400     + 550, - 500
     + 500, - 450     + 500, - 500     + 500, - 400     + 550, - 450
     + 550, - 500     + 500, - 450     + 550, - 450     + 550, - 350
     + 600, - 450     + 550, - 450     + 500, - 450     + 550, - 400
     + 600, - 400     + 550, - 450     + 550, - 450     + 500, - 400
     + 600, - 400     + 600, - 450     + 500, - 500     + 500, - 400
     + 550, - 450     + 550, - 400     + 600, - 450     + 550, - 450
     + 500, - 450     + 500, - 450     + 600, - 400     + 550, - 400
     + 600, -1350     + 550, -1400     + 550, -1400     + 550, -1350
     + 550, -2850     +2950
unsigned int  rawData[115] = {600,400, 550,1350, 650,350, 600,400, 600,350, 550,450, 550,450, 600,350, 550,450, 550,1350, 600,400, 600,400, 500,1400, 550,500, 500,450, 550,1350, 600,1350, 600,1400, 550,1300, 650,1350, 550,450, 550,450, 550,400, 550,500, 500,450, 500,500, 500,400, 550,450, 550,500, 500,450, 550,450, 550,350, 600,450, 550,450, 500,450, 550,400, 600,400, 550,450, 550,450, 500,400, 600,400, 600,450, 500,500, 500,400, 550,450, 550,400, 600,450, 550,450, 500,450, 500,450, 600,400, 550,400, 600,1350, 550,1400, 550,1400, 550,1350, 550,2850, 2950};  // UNKNOWN C5504CE4

Encoding  : UNKNOWN
Code      : F9C134EE (32 bits)
Timing[113]:
     + 550, -1400     + 550, - 450     + 500, - 450     + 500, - 450
     + 600, - 400     + 550, - 450     + 500, - 500     + 500, - 450
     + 550, - 400     + 550, -1450     + 500, - 450     + 550, - 400
     + 600, -1350     + 550, - 500     + 500, -1400     + 550, -1400
     + 500, - 450     + 550, -1400     + 550, -1400     + 550, -1400
     + 500, -1450     + 550, -1350     + 550, -1450     + 500, -1450
     + 500, -1400     + 550, - 450     + 550, - 400     + 550, - 450
     + 550, -1400     + 550, -1350     + 550, -1400     + 550, - 450
     + 550, - 450     + 550, - 450     + 500, - 450     + 500, - 500
     + 450, - 550     + 500, -1400     + 550, -1400     + 500, - 500
     + 550, -1400     + 500, - 450     + 550, - 400     + 550, - 450
     + 550, -1400     + 500, - 500     + 500, - 450     + 550, - 450
     + 550, - 450     + 500, - 500     + 450, - 500     + 450, - 550
     + 500, -1400     + 550, -1400     + 500, -1450     + 500, -1450
     + 500
unsigned int  rawData[113] = {550,1400, 550,450, 500,450, 500,450, 600,400, 550,450, 500,500, 500,450, 550,400, 550,1450, 500,450, 550,400, 600,1350, 550,500, 500,1400, 550,1400, 500,450, 550,1400, 550,1400, 550,1400, 500,1450, 550,1350, 550,1450, 500,1450, 500,1400, 550,450, 550,400, 550,450, 550,1400, 550,1350, 550,1400, 550,450, 550,450, 550,450, 500,450, 500,500, 450,550, 500,1400, 550,1400, 500,500, 550,1400, 500,450, 550,400, 550,450, 550,1400, 500,500, 500,450, 550,450, 550,450, 500,500, 450,500, 450,550, 500,1400, 550,1400, 500,1450, 500,1450, 500};  // UNKNOWN F9C134EE
The thing is my signal dumper isn't able to identify the "Encoding" and "Code" values, which I think makes the magic happen. What I'm doing wrong? I double checked the values of the array and they are "equals" once you encode them by range:

Code: Select all

0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0,1,0,1,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,1,0,1,0,2,2,
0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0,1,0,1,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,1,0,1,0,2,2,

0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,1,0,1,0,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,0,0,0,0,0,0,1,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,1,0,1,0,
0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,1,0,1,0,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,0,0,0,0,0,0,1,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,1,0,1,0,
Thanks in advance
User avatar
AnalysIR
Site Admin
Posts: 776
Joined: Sat Aug 31, 2013 3:51 pm
Location: Dublin, Ireland
Contact:

Re: Particle Photon with Samsung Split AC

Post by AnalysIR »

It seems you may have an issue with your signal dumper.

Based on a quick visual inspection of your captures, it could be that you are storing the timing values reversed in the array you recorded.
(i.e. the first value is the last one in the array).
...i may be wrong.

As I said that is based on a quick look at your values.

You will find a sketch that records long AC values if you search our blog. It should be trivial to adjust that to work on the Photon.
tmoreira2020
Posts: 2
Joined: Mon Feb 19, 2018 7:48 am

Re: Particle Photon with Samsung Split AC

Post by tmoreira2020 »

I'm using this dumper https://github.com/babean/BeanSQ-IRremo ... DumpV2.ino with adjustments to run on port D6 and fix the lack of USECPERTICK constant.

Do you see any error on it?
Post Reply