7c72b78660
Extended logging v2 to support frontend api. Contrary to v1, it is possible to have frontend and backends in the system. Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
92 lines
2.5 KiB
Plaintext
92 lines
2.5 KiB
Plaintext
# Copyright (c) 2021 Nordic Semiconductor ASA
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
menu "Output Formatting"
|
|
|
|
menu "Prepend non-hexdump log message with function name"
|
|
depends on !LOG_FRONTEND_ONLY
|
|
|
|
config LOG_FUNC_NAME_PREFIX_ERR
|
|
bool "Error messages prepended"
|
|
|
|
config LOG_FUNC_NAME_PREFIX_WRN
|
|
bool "Warning messages prepended"
|
|
|
|
config LOG_FUNC_NAME_PREFIX_INF
|
|
bool "Info messages prepended"
|
|
|
|
config LOG_FUNC_NAME_PREFIX_DBG
|
|
bool "Debug messages prepended"
|
|
default y
|
|
|
|
endmenu
|
|
|
|
config LOG_MIPI_SYST_ENABLE
|
|
bool "MIPI SyS-T format output"
|
|
select MIPI_SYST_LIB
|
|
help
|
|
Enable MIPI SyS-T format output for the logger system.
|
|
|
|
config LOG_DICTIONARY_SUPPORT
|
|
bool
|
|
depends on LOG2
|
|
help
|
|
Enable support for dictionary based logging.
|
|
|
|
Dictionary based logging is binary based where predefined strings
|
|
are replaced with their equivalent addresses from the built binary
|
|
image file in log output. This reduces the size required to store
|
|
the log output when there are long format strings to be logged.
|
|
|
|
This should be selected by the backend automatically.
|
|
|
|
config LOG_IMMEDIATE_CLEAN_OUTPUT
|
|
bool "Clean log output"
|
|
depends on LOG_MODE_IMMEDIATE
|
|
help
|
|
If enabled, interrupts are locked during whole log message processing.
|
|
As a result, processing on one log message cannot be interrupted by
|
|
another one and output is clean, not interleaved. However, enabling
|
|
this option is causing interrupts locking for significant amount of
|
|
time (up to multiple milliseconds).
|
|
|
|
config LOG_BACKEND_SHOW_COLOR
|
|
bool "Colors in the backend"
|
|
depends on LOG_BACKEND_UART || LOG_BACKEND_NATIVE_POSIX || LOG_BACKEND_RTT \
|
|
|| LOG_BACKEND_SWO || LOG_BACKEND_XTENSA_SIM
|
|
default y
|
|
help
|
|
When enabled selected backend prints errors in red and warning in yellow.
|
|
|
|
if LOG_BACKEND_SHOW_COLOR
|
|
|
|
config LOG_INFO_COLOR_GREEN
|
|
bool "Use green color for info level logs"
|
|
|
|
endif # LOG_BACKEND_SHOW_COLOR
|
|
|
|
config LOG_TAG_MAX_LEN
|
|
int "Tag max length"
|
|
default 0
|
|
range 0 64
|
|
help
|
|
Setting non-zero value enables option to specify a tag which is
|
|
prepended to each log message. Tag can be changed at runtime.
|
|
|
|
config LOG_TAG_DEFAULT
|
|
string "Default tag"
|
|
depends on LOG_TAG_MAX_LEN > 0
|
|
default ""
|
|
help
|
|
Initial tag.
|
|
|
|
config LOG_BACKEND_FORMAT_TIMESTAMP
|
|
bool "Timestamp formatting in the backend"
|
|
depends on LOG_BACKEND_UART || LOG_BACKEND_NATIVE_POSIX || LOG_BACKEND_RTT \
|
|
|| LOG_BACKEND_SWO || LOG_BACKEND_XTENSA_SIM || LOG_BACKEND_FS
|
|
default y
|
|
help
|
|
When enabled timestamp is formatted to hh:mm:ss:ms,us.
|
|
|
|
endmenu
|