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

Data Bus Hard fault when handling secure connection bonding

Hello,
I am working on an application which is freeRTOS based, now I wanted to integrate Glucose sensor app which supports secure connection and bonding. In 

ble_evt_handler, if I take out pm_handler_secure_on_connection(p_ble_evt); then my code still works it's just doesn't bond properly. However, if I leave this line of code in, I got hard fault instantly as soon as the bonding process is initiated. Could you help pointing me to the right direction to troubleshoot this issue ?
I have a feeling it has to do with  freeRTOS but I am not so sure.

Uart output:

<error> hardfault: HARD FAULT at 0x0002C8FC

<error> hardfault: R0: 0x00000000 R1: 0x4605FE50 R2: 0x20009208 R3: 0x20009208

<error> hardfault: R12: 0x200089C0 LR: 0x0002C8F1 PSR: 0x8100000E

<error> hardfault: Cause: Data bus error (PC value stacked for the exception return points to the instruction that caused the fault).

<error> hardfault: Bus Fault Address: 0x4605FE50

Call stack:

void HardFault_c_Handler()   @ 0x00029F58

void PendSV_Handler()         @ 0x0002C8EC

void PendSV_Handler()         @ 0x0002C8EC

Thank you !

Parents Reply
  • sorry my project is an company code that run on dedicated hardware.

    the issue doesn't occurs on optimization level "Debug".

    the fault I get while pushing button ( then no issue when call the same function the button call by software).

    another fault I get is:

    <error> hardfault: HARD FAULT at 0x00000004
    <error> hardfault: R0: 0x20006594 R1: 0x200064E8 R2: 0x2000D444 R3: 0x2000D444
    <error> hardfault: R12: 0x20008278 LR: 0x00000004 PSR: 0x6000000E
    <error> hardfault: Cause: The processor has attempted to execute an instruction that makes illegal use of the EPS

Children
Related