Hi,
I'm facing some problems in the use of the Logger module when the option NRF_LOG_FILTERS_ENABLED is set in the sdk_config.h file.
I'm working with the nRF5 SDK for Thread and Zigbee v4.0.0 (with the Thread network functionalities) and I'm using the CLI library over the USB_CDC_ACM interface which is also the only backend which I enabled for the logger module. When the NRF_LOG_FILTERS_ENABLED is disabled, I'm able to get the log printed correctly through the USB serial interface according to the log levels defined in the sdk_config.h file and the NRF_LOG_LEVEL defined in my own modules.
However, when I set the NRF_LOG_FILTERS_ENABLED macro, I'm not able to get any log over the USB serial and if I check the output of the log status command provided by the CLI, I get the list of the defined logger modules in which the "built-in" column shows the log levels which are defined as before, while the column "current" shows the none for all the modules. Of course, if I enable the module using CLI command log enable, I'm able to get the logs printed but I don't want to enable the modules manually each time.
The strange thing is that if I run the CLI example, I can see that the "current" column of the log status command shows different log levels but I'm not able to find where in the code the current log levels have been set (this is true even if I comment out the nrf_log_config_load() call in the main function).
Can you please explain the reason for this different behaviour? Is there a way to set the dynamic log level programmatically?
Thanks,
Paolo