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

in gpiote handler,call xEventGroupSetBitsFromISR will cause hardfault

my project is freertos+nrf52832 based the templete in SDK; A sensor pin is connect to P0.17, and I configure it low to high level trigger interrupt.In the handler I will call xEventGroupSetBitsFromISR to notify task, but when call this function, it will step into hardfault;The hardfault error information as the below:

hardfault: HARD FAULT at 0x000076EC<error> hardfault:   
R0:  0x7325203A  R1:  0x00004A1C  
R2:  0x65646F63  R3:  0x7265202C
<error> hardfault:   
R12: 0x00000003  LR:  0x0000859D  
PSR: 0x01000016<error> 
hardfault: Cause: Data bus error (return address in the stack frame is not related to the instruction that caused the error).

If in the handler, I call xEventGroupSetBits,the program can running normal.

So, what's wrong with it?Does GPIOTE handler is not ISR?

Parents Reply Children
No Data
Related