Irremoteesp8266: Restarting if continues ir received

Created on 6 Apr 2016  Â·  16Comments  Â·  Source: crankyoldgit/IRremoteESP8266

i like to say thank you for this library creator and supporting members,
its decoding perfectly but ESP8266 Restarting, If receive continuous IR Signal ,
Iam using gpio13 to connect ir receiver(TSOP1738)

iam using samsung TV remote
pic1
pic2

Most helpful comment

As igrr suggested, changing the ISR method signatures has resolved all of the issues with receiving repetitive IR signals causing WDT resets for me.

Changes applied:

(_IRemoteESP8266.cpp, line 478_)

static void ICACHE_FLASH_ATTR gpio_intr(void *arg) {

to:

static void ICACHE_RAM_ATTR gpio_intr(void *arg) {

and (_IRemoteESP8266.cpp, line 470_):

static void ICACHE_FLASH_ATTR read_timeout(void *arg) {

to

static void ICACHE_RAM_ATTR read_timeout(void *arg) {

All 16 comments

Don't encode the values in hex and print, mine worked pretty well without
encoding the output in hex

On Thu, 7 Apr 2016 12:55 am Rajasekar, [email protected] wrote:

i like to say thank you for this library creator and supporting members,
its decoding perfectly but ESP8266 Restarting, If receive continuous IR
Signal ,
Iam using gpio13 to connect ir receiver(TSOP1738)

iam using samsung TV remote
[image: pic1]
https://cloud.githubusercontent.com/assets/4434178/14329905/649c8490-fc5b-11e5-8cfa-6f65d5871bd8.png
[image: pic2]
https://cloud.githubusercontent.com/assets/4434178/14329912/6e2716b0-fc5b-11e5-9d52-611e770ba37e.png

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
https://github.com/markszabo/IRremoteESP8266/issues/22

kindly explain why don't encode in to hex value,
how to use switch case without convert hex,have any other way to use switch case

You can directly use the values, by assigning results.value to a variable , i have given a example snipped below
`
code = results.value;
switch(code){
//case 1
case 3778927144:
//do something

}
`

Thanks for your code, I tested but still restarting, can you please share your hardware schematic diagram

I am replying form my mobile device so i cannot upload a schematic ,
I am using a ESP-12E and have attached my tsop1738 to Gpio 5 , and have
provided it with a independent power supply , and is not sharing it with
the esp , as it creates issues sometimes.

On Fri, 8 Apr 2016 at 00:56 Rajasekar [email protected] wrote:

Thanks for your code, I tested but still restarting, can you please share
your hardware schematic diagram

—
You are receiving this because you commented.

Reply to this email directly or view it on GitHub
https://github.com/markszabo/IRremoteESP8266/issues/22#issuecomment-207057733

Thanks,I will check my connection, if you send schematic diagram, this is my diagram
20160408_092629
Tsop I connected like this
20160408_093200

It's restart again and again if receive few ir codes

TSOP1738 is working very fine with 3.3V directly connect Vin to 3.3V, GND to GND, and output to some GPIO pin. I'm able to decode the my Videcon DTH remote. The problem with me is, I'm not able to send the messages using IRsend.sendNEC(). If you have tried it please reply.

@sivanandareddy Try connecting a normal led to the output pin while sending. It should blink for a short time. If it does, then try decoding it with an other arduino/esp8266. Usually the receiver will pick up the signal from a normal led, though you need to put them close to each other. Then try with the IR led. Also (if possible) try sending the IR codes from an arduino.

I'm sure it is blinking something. I'll try with another arduino board and decode it. Another strange thing that I have found is that, carrier freqency of IR transmission is only 34.5kHz instead of 38kHz. I'm using NodeMCU with ESP12-E

@rajasekarsarangapani See section Timing and delays in the esp8266/arduino reference link https://github.com/esp8266/Arduino/blob/master/doc/reference.md. They say not to use delay as it blocks the some wifi routines which will reset the chip, if wifi is enabled.

Thanks for the info, I will try

FYI, a lot of these Exception (0) issues reported here have to do with the fact that GPIO ISR handler is placed into flash. ISR handler should instead be marked with IRAM_ATTR for placement into RAM. Otherwise if the interrupt happens while flash cache is disabled, ISR code will not be accessible, causing exception 0.

Is any Solution for this problem available? My ESP restarts with the demo rcv example if delay() is used ....

As igrr suggested, changing the ISR method signatures has resolved all of the issues with receiving repetitive IR signals causing WDT resets for me.

Changes applied:

(_IRemoteESP8266.cpp, line 478_)

static void ICACHE_FLASH_ATTR gpio_intr(void *arg) {

to:

static void ICACHE_RAM_ATTR gpio_intr(void *arg) {

and (_IRemoteESP8266.cpp, line 470_):

static void ICACHE_FLASH_ATTR read_timeout(void *arg) {

to

static void ICACHE_RAM_ATTR read_timeout(void *arg) {

@tekker / @igrr : Thank you. I've spent ages trying to figure out the problem and these fixes solved it for me. If you guys are ever in Cape Town, South Africa I will gladly buy you a beverage of your choosing!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

wizkidorg picture wizkidorg  Â·  7Comments

the-mentor picture the-mentor  Â·  5Comments

mariusmotea picture mariusmotea  Â·  7Comments

MehranMazhar picture MehranMazhar  Â·  5Comments

crankyoldgit picture crankyoldgit  Â·  3Comments