IRLib wont loop.

Hi!
I'm fairly new to the arduino and have got a problem with the new IR library from IRLib | CY's Tech Talk

I want to be able to use some of the buttons on the tuner remote to also controll the TV. I've had some success but it seems like the code wont loop, as I can only do something once before I have to reset it. All the buttons work, but only one time.. I have code from the sendDemo and the Servo examples in the library as inspiration. I also changed the switch to check the serial just in case it was the my_reciever.resume() that was faulty.

Any ideas why it apparently wont loop??

why.ino (1.15 KB)

Is that library designed to receive AND send? Ken's had problems doing both, IIRC.

Yes it does. It does exactly what I want it to do, when it recieves a signal it sends another one. The problem is that it will only response once..

It does exactly what I want it to do, when it recieves a signal it sends another one. The problem is that it will only response once..

That's what happened in Ken's library, too. Try commenting out the sends. If the receiver receives every signal correctly, then the send functions are not resetting to receive mode when they are done.

Thanks for the response, but I also tried to just make the led blink every time it recieved a signal, and that also just happened once.

Thanks for the response, but I also tried to just make the led blink every time it recieved a signal, and that also just happened once.

I've tried a lot of things when writing code. When nothing works, and I hold a code review, I don't show up with a blank pad of paper.

I'm sorry but wha do you mean by "I don't show up with a blank pad of paper"?

...a bit late but in case anyone else has a similar problem.

At least with IRremote you must (re) enable receive after every send as send disable receive so as to avoid echo.

I preseume IRlib is the same because it is modeled on IRremote.

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