I am so glad finally I am able to solve with your helps and suggestions to power on/off my AC now.
I bypass resistor that connected to IR LED. Seem it makes the signal IR LED become more stronger and stable. but the range work ~1.5 Meter only. Any idea how to amplified the signal so make it longer distance?
Below the code that I use (seem it works with 450 or 435):
#include <IRremote.h>
IRsend irsend;
//remove below to power on/off
//power off
//unsigned int Signal_0_0[] = {3500,1750,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,9996,3500,1750,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,1300,450,450,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,1300,450,450,450,1300,450,450,450,1300,450}; //AnalysIR Batch Export (IRremote) - RAWint khz=38;
//power on
//unsigned int Signal_0_0[] = {3500,1750,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,9996,3500,1752,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,450,450,450,450,1300,450,456,420,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,1300,450,1300,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1324,450,1300,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,1300,450,450,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,1300,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,1300,450,450,450,450,450,450,450,450,450,450,450,450,450,1324,450,450,450,450,450,450,450,456,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,456,450,450,450,450,450,450,450,450,450,1300,450,1300,450,450,450,1300,450}; //AnalysIR Batch Export (IRremote) - RAWint khz=38;
int khz=38;
void setup() {
//insert your own setup code here
Serial.begin(115200); //change BAUD rate as required
}
void loop() {
Serial.println("send AC signal @38k");
irsend.sendRaw(Signal_0_0, sizeof(Signal_0_0)/sizeof(int), khz); //AnalysIR Batch Export (IRremote) - RAW
delay(5000); //a good idea to have gaps between signals
}