-->
Page 1 of 1

Callbacks

PostPosted: Sat Jan 31, 2015 3:58 pm
by kartman
There are a number of callbacks that are done via an interrupt context - gpio trigger and timer alarms for instance. Does this not cause atomicity problems with the lua code? I've noticed that when i get a number of callbacks in operation that lua reports a panic and reboots. Should the callbacks put the event in a queue and have a dispatch method that makes the lua side work cleanly?

Re: Callbacks

PostPosted: Wed Feb 04, 2015 8:16 pm
by iHaveESP
Can you post example code?

Re: Callbacks

PostPosted: Thu Feb 05, 2015 4:43 pm
by kartman
My question is - is it flawed by design? Different chunks are called in different contexts - how is atomicity ensured? Would this explain random panics i observe?