Hi all,
I'm a little blown away by the complexity of logging for this application (its highly likely I'm missing a few key elements to my understanding).
I'm under the impression that by default, the device logs to LTE Link Monitor. I can't seem to get that to happen whatsoever, although my modem is offline if that is important. Furthermore, I've tried following some resources regarding RTT logging with Segger, but to no avail. It seems that whenever I run my project through segger ( Build > Build & Debug), I run into `Unknown function at 0xFFFFFFFE`. I've tried disabling all of the VBM exceptions. If I instead run (Build > Build & Run), I get no output at all from anything, and I'm unable to connect the RTT terminal using the window on the right.
For some samples, my code:
#include <zephyr.h> #include <logging/log.h> LOG_MODULE_REGISTER(main); void main(void) { while (1) { LOG_INF("looped loginf"); k_sleep(K_MSEC(150)); } }
My prj.conf
CONFIG_SERIAL=y CONFIG_TRUSTED_EXECUTION_NONSECURE=y CONFIG_UART_INTERRUPT_DRIVEN=y CONFIG_MAIN_STACK_SIZE=4096 CONFIG_STDOUT_CONSOLE=y #CONFIG_GPIO=y #debug CONFIG_DEBUG=y CONFIG_LOG=y # Segger RTT CONFIG_USE_SEGGER_RTT=y CONFIG_RTT_CONSOLE=y CONFIG_UART_CONSOLE=n CONFIG_LOG_BACKEND_RTT=y CONFIG_LOG_BACKEND_UART=n
Is there a comprehensive guide I can follow somewhere to just connect printk to RTT and get logging working?
Overall, I'm trying to upskill and familiarize myself with one of our contractor's work, and logging + trial and error goes a huge way for me in understanding whats going on
Thanks in advance, team.