adafruit / Adafruit_Seesaw

Arduino library driver for seesaw multi-use chip
93 stars 64 forks source link

Potential lock up with many rapid keypresses. #18

Closed caternuson closed 3 years ago

caternuson commented 5 years ago

https://forums.adafruit.com/viewtopic.php?f=8&t=144551

ladyada commented 5 years ago

replied to thread, the code is not easy to debug, so not sure if/when i'll get to it. delays may solve the problem

griv commented 4 years ago

I've just hit this issue. I've got a single Neotrellis wired to a D1 Mini. My app connects to an MQTT broker using the PubSub library and subscribes to 16 topics. As the subscription messages come in the Neotrellis locks up after 4 messages. I'm not pressing any Trellis buttons, just writing the LED colours. The D1 mini continues as I can still see more messages coming in in the serial console.

Loading the example code of basic and interrupt I can press buttons for about 10 seconds and then it locks up. I've tried powering it with 5v and 3.3v with similar results.

Update: also tried cutting the 3v Vi2c trace and soldering to Vin. Same results (tried both 3.3 & 5v).

Update: seems it is a D1 Mini issue. Works fine on a Mega. I rebuilt my app on a D32 and it's solid. Not sure if it is a library conflict (I have heaps of libraries installed). I did try a few D1 Minis all with the same result.

ladyada commented 3 years ago

found this bug, https://github.com/adafruit/seesaw/pull/48 i think disabling IRQ support helps/fixes - ironically :( so comment out ss.setGPIOInterrupts(button_mask, 1); or whatever is enabling GPIO irqs closing for now because im pretty sure its fixed - have been smashing these MX keys