Author Topic: Infrared frequency heater remote  (Read 2004 times)

0 Members and 1 Guest are viewing this topic.

Offline max246Topic starter

  • Newbie
  • Posts: 2
  • Country: gb
Infrared frequency heater remote
« on: October 08, 2018, 01:32:58 pm »
I am trying to hack my heater and re-produce the infrared signal of the 6 buttons, but it seems a bit odd how to decode this sort of stuff.

I used an arduino sketch which allow me to read and repeat the codes and it worked with different remote controller but not for this specifi one.

The board is powered by a button battery and it only has a chip  BEC5104S,  I have even soldered a infrared emitter that does 38Khz so I think it is running at 38khz the signal.

After testing here and there I was aim to test on the oscilloscope and send raw signals but still not success.

I attach here some pictures and hopefully someone cal help me out to figure out what frequency is running and how to send raw codes via an arduino.
 

Offline alsetalokin4017

  • Super Contributor
  • ***
  • Posts: 2055
  • Country: us
Re: Infrared frequency heater remote
« Reply #1 on: October 08, 2018, 10:53:33 pm »
Well, that shouldn't be too hard. Just eyeballing your scope trace I see short HI pulses of about 400 microseconds and long pulses of three times that length, and separated by one or three LO periods of 400 us also. So use the scope to zoom in on one of the short pulses and measure it accurately, then program the Arduino to send the sequence of pulses of the appropriate lengths to a regular IR LED (or the 38 MHz transducer), which will be multiples of the basic short pulse duration you measured accurately using the scope.

Then to get the appropriate repetition rate of the pulse train from the remote, zoom the scope out so that you can see several instances and measure the interval between them.

I have used this method to control my window AC unit.

The easiest person to fool is yourself. -- Richard Feynman
 

Offline alsetalokin4017

  • Super Contributor
  • ***
  • Posts: 2055
  • Country: us
Re: Infrared frequency heater remote
« Reply #2 on: October 08, 2018, 11:02:48 pm »
So the pulse train in the scopeshot above may be represented by the following string:
111011101000111011101000100010001110100010001
where the basic time unit is "about" 400 microseconds and where 1 means HI and 0 means LO and a sequence like "111" means a HI pulse of 3x units duration.
The easiest person to fool is yourself. -- Richard Feynman
 

Offline t1d

  • Super Contributor
  • ***
  • Posts: 1255
  • Country: us
Re: Infrared frequency heater remote
« Reply #3 on: October 10, 2018, 03:01:24 pm »
I am noobish, so this may not help... This type of inexpensive Logic Analyzer has a good reputation, for a Chinese gizmo... Download Saleae's Sigrock and PulseView, to use it with a laptop. They're freeware. YouTube has really good instructionals, about it.

https://www.ebay.com/itm/USB-Logic-Analyzer-Device-Set-Compatible-to-Saleae-24MHz-8CH-for-ARM-FPGA-M100/223119091948?hash=item33f2ef28ec:g:NNoAAOSwjXVaoiyH:rk:8:pf:0
 

Offline hexreader

  • Frequent Contributor
  • **
  • Posts: 272
  • Country: england
Re: Infrared frequency heater remote
« Reply #4 on: October 10, 2018, 04:34:42 pm »
The Chinese version of BEC5104S datasheet is just readable enough to be able to easily decode your scope trace as 110110001000

Try different buttons to see what codes they produce.

As far as I can tell, that chip produces unmodulated signals. Remote controls usually need modulation. Maybe the modulation is done elsewhere on your remote control. I cannot tell.

Just adding an IR LED to that signal won't help.

Put scope probe directly onto the remote control's IR LED (the original one, not the one that you added) to check modulated signal, assuming that it is modulated at all.
 

Offline max246Topic starter

  • Newbie
  • Posts: 2
  • Country: gb
Re: Infrared frequency heater remote
« Reply #5 on: October 25, 2018, 02:39:26 pm »
Sorry if I sound a bit too stupid, but are you saying that I will just make my own "on and off" procedure?

Just create my code that does digitalWrite HIGH and LOW on the same timing of what I see on the screen?

what about if I want to use the IR library from arduino? I see I can send "RAW" data, but I am not sure if measuring the "delta" of each spike was correct.


Also, how can I confirm that this is 38KHZ ? I just want to make sure I am  able to reproduce this signal so I can "hack " my heater.
 

Offline hexreader

  • Frequent Contributor
  • **
  • Posts: 272
  • Country: england
Re: Infrared frequency heater remote
« Reply #6 on: October 25, 2018, 04:23:54 pm »
I think the honest reply is that I simply do not know enough about your heater and it's remote to be able to give meaningful advice.

Sorry

Are you trying to make your own IR remote?, or are you trying to wire 6 buttons directly to the heater? or are you trying to control your heater from a computer of some kind?   .. or am I missing the point entirely?

I have very limited Arduino knowledge, but I suspect that there is no library to create the raw signal that you seem to want, so my guess is... yes, you will need to use digitalWrite high/low (or direct port manipulation) with appropriate delays.

Maybe mentioning 38kHz was a mistake, since re-reading the above, it seems that you really do want the raw signal (presumably to inject into the point in the circuit where  the IR receiver output goes/went to?)

It is possible that I completely misunderstand, in which case please just ignore my guesswork.
« Last Edit: October 25, 2018, 04:40:01 pm by hexreader »
 

Offline hexreader

  • Frequent Contributor
  • **
  • Posts: 272
  • Country: england
Re: Infrared frequency heater remote
« Reply #7 on: October 25, 2018, 06:35:20 pm »
This sketch seems to produce a scope trace to match yours:

Code: [Select]
// produce raw command for 6 button heater control
// currently only know one button code, so for now, just repeatedly send that one code
// written by amateur coder who accepts no reponsibility for anything, anywhere, ever

// pin allocation
int heatPin = 13;                             // LED connected to digital pin 13

// function prototypes
void send0();
void send1();
void sendmessage(signed int send_data);

void setup() {
  pinMode(heatPin, OUTPUT);                   // sets the digital pin as output
  digitalWrite(heatPin, LOW);                 // sets the output low - quiescent state
}

// test program - send same button code over and over
void loop() {
  sendmessage(0xD88);                        // button 1 code
  delay(2000);                               // repeat every 2 seconds
}

// send a 12 bit message plus stop bit
void sendmessage(signed int send_data){
signed char bitnum;                          // count through 12 bits

  for (bitnum = 11 ; bitnum >= 0 ; bitnum--){
    if ((send_data >> bitnum) & 0x001){      // test bit 0 after shifting n bits
      send1();
    }
    else{
      send0(); 
    }
  }
  send0();                                    // stop bit of zero
}

// send a one (1200uS high followed 400uS low)
void send1(){
  digitalWrite(heatPin, HIGH);                // sets the output high
  delayMicroseconds(1200);                    // high time
  digitalWrite(heatPin, LOW);                 // sets the output low
  delayMicroseconds(400);                     // low time
}

// send a zero (400uS high followed 1200uS low)
void send0(){
  digitalWrite(heatPin, HIGH);                // sets the output high
  delayMicroseconds(400);                     // high time
  digitalWrite(heatPin, LOW);                 // sets the output low
  delayMicroseconds(1200);                    // low time
}
« Last Edit: October 25, 2018, 07:13:55 pm by hexreader »
 

Offline alsetalokin4017

  • Super Contributor
  • ***
  • Posts: 2055
  • Country: us
Re: Infrared frequency heater remote
« Reply #8 on: October 25, 2018, 07:06:21 pm »
check the comments on the last two function definitions
The easiest person to fool is yourself. -- Richard Feynman
 

Offline hexreader

  • Frequent Contributor
  • **
  • Posts: 272
  • Country: england
Re: Infrared frequency heater remote
« Reply #9 on: October 25, 2018, 07:12:17 pm »
Well spotted...

.... fixed with edit
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf