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

Resetting system after enabling internal RC (Zephyr)

Hi,

I am using a custom board that uses Arm Cortex-A7 and embedding an nRF52840, There is no external low-frequency crystal 32kHz connected to the nrf52 chip, so I've enabled the internal RC by

CONFIG_CLOCK_CONTROL_NRF_K32SRC_RC=y
CONFIG_CLOCK_CONTROL_NRF_K32SRC_20PPM=y
CONFIG_UART_CONSOLE=y
in prj.conf and added nrf52840dk_nrf52840.overlay to my project.
&uart0 {
	status = "okay";
	current-speed = <19200>;
	tx-pin = <6>;
	rx-pin = <8>;
};
then compiled direct_test_mode example and flashed it using j-link. the custom board starts booting up continuously and showing the below message:

*** Booting Zephyr OS build zephyr-v2.4.0-198-ga4ead9805140  ***
Starting Direct Test Mode example
P0.31 set to high & P0.2,P0.29 set to low.
ASSERTION FAIL [r >= 0] @ WEST_TOPDIR/zephyr/drivers/sensor/nrf5/temp_nrf5.c:61
E: r0/a1:  0x00000004  r1/a2:  0x0000003d  r2/a3:  0x00000001
E: r3/a4:  0x00002761 r12/ip:  0x00000000 r14/lr:  0x000043eb
E:  xpsr:  0x61000000
E: Faulting instruction address (r15/pc): 0x000086c0
E: >>> ZEPHYR FATAL ERROR 4: Kernel panic on CPU 0
E: Current thread: 0x20000410 (unknown)
E: Resetting system
*** Booting Zephyr OS build zephyr-v2.4.0-198-ga4ead9805140  ***
Starting Direct Test Mode example

Any suggestions to solve this issue?

Parents Reply
  • I'm not sure why you're not seeing the serial log. Are you able to use RTT logging?

    Could you try to debug your device (e.g. by using Ozone), to see if everything behaves as expected? 

    What do you get if you run nrfjprog --memrd 0x40000418 (read this register).

    I don't have access to an nRF52 device without/with a defect XTAL, so I'm not able to test this myself. Tomorrow I'll get hold of one and do some testing.

    Best regards,

    Simon

Children
Related