This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

internal error from SWI2_IRQHandler

www.dropbox.com/.../Screenshot 2014-04-03 11.41.25.png

I guess has nothing to do with crc16?

the call stall seems unreasonable, is it because my stack is messup?

everything is good till this morning, keep getting this error, sometimes stuck in URAT

this happened after a successful bonding, seems still related to bonding

Parents
  • The error is on the call to your scheduler function, and the error code is 0x0004. The error code is defined in nrf_error.h and its: NRF_ERROR_NO_MEM

    You have no memory to add the event into the scheduler queue. Try adjusting the define "SCHED_QUEUE_SIZE" in your main.c file.

    -H

  • The queue size is application specific, and will vary depending on how many tasks you schedule. There's no specific answer on which value it should be set to, you will have to evaluate this.

    The same goes for the stack size. You will have to monitor the stack in order to evaluate how much memory your auto-variables use in the worst case. Monitoring the stack can for instance be done by filling the RAM with known values, run the application as it should, then evaluate which RAM areas are still "intact".

    Note: Heap is generally only used by malloc, which none of our examples use. If you check "Use microlib" in Keil, it will automatically remove the HEAP if it's not used.

Reply
  • The queue size is application specific, and will vary depending on how many tasks you schedule. There's no specific answer on which value it should be set to, you will have to evaluate this.

    The same goes for the stack size. You will have to monitor the stack in order to evaluate how much memory your auto-variables use in the worst case. Monitoring the stack can for instance be done by filling the RAM with known values, run the application as it should, then evaluate which RAM areas are still "intact".

    Note: Heap is generally only used by malloc, which none of our examples use. If you check "Use microlib" in Keil, it will automatically remove the HEAP if it's not used.

Children
No Data
Related