each time my program start, I get the error m_evt_schedule_func
error 4
what's the cause of this error? is it because I spend lot of time on the handler??? the handler running long task
each time my program start, I get the error m_evt_schedule_func
error 4
what's the cause of this error? is it because I spend lot of time on the handler??? the handler running long task
is this in the softdevice_handler (SOFTDEVICE_EVT_IRQHandler) or the app_timer (timeout_handler_exec)? Error code 0x4 means NRF_ERROR_NO_MEM.
The reason is probably that the scheduler queue size is full, therefore app_sched_event_put(...)
will return NRF_ERROR_NO_MEM because APP_SCHED_QUEUE_FULL() returns true. The reason is probably that too many app_timer timeouts happens while the you are doing something in the handler (you said you are spending a lot of time in the handler). You can increase the APP_TIMER_OP_QUEUE_SIZE to increase the queue size. If you still are getting the error you need to spend less time in the handler somehow.
you're right, I could check that APP_SCHED_QUEUE_FULL
return true, I raised the size of the schceculaer, now it happens less but still happening (APP_SCHED_QUEUE_FULL
still return true but less frequeent)??
Hi, nodirc, I encountered the same problem, then i increase SCHED_QUEUE_SIZE to 88, and queue full error still happend, but much less. I can't increase queue size any more, because the ram is not enough. I use SDK version 10.0.0 currently, can i optimize this problem by upgrading sdk.
Hope to reply! thanks!