This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

SPM HARD FAULT by changing the UART0 baud rate setting

For my project I need to set the UART0 speed to 9600 baud.

So for testing I tried to compile the "Hello word" example by setting the board configuration file (ncs\v1.6.1\ zephyr\ boards\ arm\ nrf9160dk_nrf9160 \ nrf9160dk_nrf9160_common.dts) as follows:

&uart0 {
status = "okay";
current-speed = <9600>;
tx-pin = <29>;
rx-pin = <28>;
rts-pin = <27>;
cts-pin = <26>;
};

Rebuilding the project the system HALT. See the following log:

*** Booting Zephyr OS build v2.6.0-rc1-ncs1  ***
Flash regions           Domain          Permissions
00 01 0x00000 0x10000   Secure          rwxl
02 31 0x10000 0x100000  Non-Secure      rwxl

Non-secure callable region 0 placed in flash region 1 with size 32.

SRAM region             Domain          Permissions
00 07 0x00000 0x10000   Secure          rwxl
08 31 0x10000 0x40000   Non-Secure      rwxl

Peripheral              Domain          Status
00 NRF_P0               Non-Secure      OK
01 NRF_CLOCK            Non-Secure      OK
02 NRF_RTC0             Non-Secure      OK
03 NRF_RTC1             Non-SecureE: ***** HARD FAULT *****
E:   Bus fault on vector table read
E: r0/a1:  0xfefa125b  r1/a2:  0x00000000  r2/a3:  0x00000021
E: r3/a4:  0x00000000 r12/ip:  0x00000000 r14/lr:  0x00000000
E:  xpsr:  0x00000000
E: Faulting instruction address (r15/pc): 0x0000910b
E: >>> ZEPHYR FATAL ERROR 0: CPU exception on CPU 0
E: Current thread: 0x20000218 (unknown)

If I replace the original setting 

&uart0 {
status = "okay";
current-speed = <115200>;
tx-pin = <29>;
rx-pin = <28>;
rts-pin = <27>;
cts-pin = <26>;
};

everything is ok. See the following log:

*** Booting Zephyr OS build v2.6.0-rc1-ncs1  ***
Flash regions           Domain          Permissions
00 01 0x00000 0x10000   Secure          rwxl
02 31 0x10000 0x100000  Non-Secure      rwxl

Non-secure callable region 0 placed in flash region 1 with size 32.

SRAM region             Domain          Permissions
00 07 0x00000 0x10000   Secure          rwxl
08 31 0x10000 0x40000   Non-Secure      rwxl

Peripheral              Domain          Status
00 NRF_P0               Non-Secure      OK
01 NRF_CLOCK            Non-Secure      OK
02 NRF_RTC0             Non-Secure      OK
03 NRF_RTC1             Non-Secure      OK
04 NRF_NVMC             Non-Secure      OK
05 NRF_UARTE1           Non-Secure      OK
06 NRF_UARTE2           Secure          SKIP
07 NRF_TWIM2            Non-Secure      OK
08 NRF_SPIM3            Non-Secure      OK
09 NRF_TIMER0           Non-Secure      OK
10 NRF_TIMER1           Non-Secure      OK
11 NRF_TIMER2           Non-Secure      OK
12 NRF_SAADC            Non-Secure      OK
13 NRF_PWM0             Non-Secure      OK
14 NRF_PWM1             Non-Secure      OK
15 NRF_PWM2             Non-Secure      OK
16 NRF_PWM3             Non-Secure      OK
17 NRF_WDT              Non-Secure      OK
18 NRF_IPC              Non-Secure      OK
19 NRF_VMC              Non-Secure      OK
20 NRF_FPU              Non-Secure      OK
21 NRF_EGU1             Non-Secure      OK
22 NRF_EGU2             Non-Secure      OK
23 NRF_DPPIC            Non-Secure      OK
24 NRF_REGULATORS       Non-Secure      OK
25 NRF_PDM              Non-Secure      OK
26 NRF_I2S              Non-Secure      OK
27 NRF_GPIOTE1          Non-Secure      OK

SPM: NS image at 0x10000
SPM: NS MSP at 0x200107b0
SPM: NS reset vector at 0x11795
Ê*** Booting Zephyr OS build v2.6.0-rc1-ncs1  ***
Hello World! nrf9160dk_nrf9160

I tryed also other sample like http_update\application_update with the same result.

I also tried with different serial baud speed with the same result.

Please help me to understand what is wrong.

I'm using nRF9160-DK board and SDK 1.6.1.

Parents Reply Children
No Data
Related