Jump to content
CptSky

IRremote Library Not Working

Recommended Posts

Hello,

I'm using IRremote library and IRrecvDemo is working perfectly, however IRsendDemo is not working. I've commented out these lines in IRremote.cpp

//pinMode(TIMER_PWM_PIN, OUTPUT);
//digitalWrite(TIMER_PWM_PIN, LOW); // When not sending PWM, we want it low

and removed the if (Serial.read() != -1) condition, but it is still not working. Do you have any idea what might be the problem?

Thanks.

Share this post


Link to post
Share on other sites

Protocol mismatch? Wrong modulation frequency? Hardware problem? Use a mobile phone camera to see if there is any activity out of the IR diode,  assuming you are using one for transmission.

Share this post


Link to post
Share on other sites
5 hours ago, terjeio said:

Protocol mismatch? Wrong modulation frequency? Hardware problem? Use a mobile phone camera to see if there is any activity out of the IR diode,  assuming you are using one for transmission.

There is no output at pin P2_3, that’s the problem. Literally nothing happens. I debugged it and it enters the for loop but sends nothing.

Share this post


Link to post
Share on other sites

Hi @CptSky

You haven't provided much information - no code really, no information on the microcontroller, the pins used and how they are connected, etc.

If you have commented out code as described in your first post then of course there will be no output if  TIMER_PWM_PIN is P2_3.

//pinMode(TIMER_PWM_PIN, OUTPUT);
//digitalWrite(TIMER_PWM_PIN, LOW); // When not sending PWM, we want it low 

I don't think it is possible to give meaningful help without more information.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×