Hello, I've not found any real alternative to this library, and it seems that it doesn't work for me. The hardware setup is fine: emitter led connected to pin 3 and working if used as a normal led with "blink" example. When I load the "IRsendDemo" example from this library, the led does nothing, it does not turn on either. I tried using
irsend.sendSony() and irsend.sendNEC() with multimple configurations, and nothing could at least turn on the emitter. What's the problem? Any alternative to this library?
I must point out that the IRreceive example did actually work with my IR receiver.
Can you clarify what type of LED you are using ?
If it is an IR LED how do you know that it is not working ? If it is a standard LED, which seems likely from your description, what are you expecting to see ?
This sounds like a hardware or wiring problem. Have you removed and reconnected the LED since you tried it with the Blink sketch ? When did you last try it with the Blink sketch using pin 3 ?
No, I didn't. I loaded the blink sketch, watched if it worked (it did), and one minute later, without touching anything, loaded the IRsendDemo and later experimented with variations of the sketch.
First of all IRremote is very robust and has been used successfully many times by people with all levels of experience. I made a silly mistake a couple of days ago when using it, myself.
Try the following
void loop() {
irsend.sendSony(0xa90, 12); // Sony TV power code
delay(20);
}
It may be that sending just one burst every second isnt enough to show up on your camera with this LED. The code above will send an IR command 5 times evey second and may show up brighter on your phone. There is no need to let it run for more than a few seconds. If you are not using a transistor, you will typically get very short range with IR.
If that doesnt work, confirm you have the LED wired the correct way and then let us know how you get on & maybe upload a sketch of your circuit.
I've checked and double-checked it, it's well connected. The resistance isn't too large, I didn't measure it, but when I loaded the blink sketch I adjusted it for being bright enough.
I didn't mean a good connection, I meant connected in reverse.
Did you confirm that the shot lead/pin of the IR LED is connected to GND?
If that doesn't work replace the IR led with a normal LED (red, yellow, or green etc). This will allow a visible check to confirm if the IR LED is defective.
After, that you may need to use an oscilloscope or other test equipment to verify if the signal is being sent or if the LED is defective.
Just realised from your photo that you may be using an Arduino MEGA of some sort. There may be issues with that.
Check the following post, in case you have to change the pin for Tx. http://forum.arduino.cc/index.php/topic,28434.0.html