Skip to content

Commit 817c74f

Browse files
MaureenHelmcarlescufi
authored andcommitted
tests: counter: Enable debug logging
Enables debug logging in the counter_basic_api test. Fixes a build error in the nrf counter drivers when logging is enabled. Signed-off-by: Maureen Helm <[email protected]>
1 parent f5584b8 commit 817c74f

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

drivers/counter/counter_nrfx_rtc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#define LOG_LEVEL CONFIG_COUNTER_LOG_LEVEL
1212
#define LOG_MODULE_NAME counter_rtc
1313
#include <logging/log.h>
14-
LOG_MODULE_REGISTER();
14+
LOG_MODULE_REGISTER(LOG_MODULE_NAME, LOG_LEVEL);
1515

1616
#define RTC_CLOCK 32768
1717
#define COUNTER_MAX_TOP_VALUE RTC_COUNTER_COUNTER_Msk

drivers/counter/counter_nrfx_timer.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
#define LOG_LEVEL CONFIG_COUNTER_LOG_LEVEL
1010
#define LOG_MODULE_NAME counter_timer
1111
#include <logging/log.h>
12-
LOG_MODULE_REGISTER();
12+
LOG_MODULE_REGISTER(LOG_MODULE_NAME, LOG_LEVEL);
1313

1414
#define TIMER_CLOCK 16000000
1515

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
CONFIG_COUNTER=y
22
CONFIG_BT=n
33
CONFIG_ZTEST=y
4+
CONFIG_LOG=y
5+
CONFIG_COUNTER_LOG_LEVEL=4

0 commit comments

Comments
 (0)