Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions components/utilities/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,14 @@ menuconfig RT_USING_ULOG
It will enable the log filter.
Such as level filter, log tag filter, log kw filter and tag's level filter.

config ULOG_USING_FINSH_CMD
bool "Enable ulog finsh/msh commands"
depends on ULOG_USING_FILTER && RT_USING_FINSH
default y
help
Enable this option to use ulog commands in finsh/msh,
such as ulog_lvl, ulog_tag, ulog_kw and so on.

config ULOG_USING_SYSLOG
bool "Enable syslog format log and API."
select ULOG_OUTPUT_TIME
Expand Down
4 changes: 2 additions & 2 deletions components/utilities/ulog/ulog.c
Original file line number Diff line number Diff line change
Expand Up @@ -1084,7 +1084,7 @@ const char *ulog_global_filter_kw_get(void)
return ulog.filter.keyword;
}

#ifdef RT_USING_FINSH
#if defined(RT_USING_FINSH) && defined(ULOG_USING_FINSH_CMD)
#include <finsh.h>

static void _print_lvl_info(void)
Expand Down Expand Up @@ -1259,7 +1259,7 @@ static void ulog_filter(uint8_t argc, char **argv)
}
}
MSH_CMD_EXPORT(ulog_filter, Show ulog filter settings);
#endif /* RT_USING_FINSH */
#endif /* RT_USING_FINSH && ULOG_USING_FINSH_CMD */
#endif /* ULOG_USING_FILTER */

/**
Expand Down
Loading