Skip to content

Commit 7bc48f6

Browse files
author
Andrew Boie
committed
Revert "misc: Remove generic PRINT macros from power samples"
This reverts commit 6f992e2. Change-Id: I14767699b02d147a245db1cb8ac5cef430782232 Signed-off-by: Andrew Boie <[email protected]>
1 parent ebf02d4 commit 7bc48f6

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

samples/power/power_hooks/prj.conf

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,3 @@ CONFIG_STDOUT_CONSOLE=y
22
CONFIG_SYS_POWER_MANAGEMENT=y
33
CONFIG_DEVICE_POWER_MANAGEMENT=y
44
CONFIG_TICKLESS_IDLE=y
5-
CONFIG_SYS_LOG=y

samples/power/power_hooks/src/main.c

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,17 @@
1717
#include <zephyr.h>
1818
#include <power.h>
1919

20-
#define SYS_LOG_LEVEL SYS_LOG_LEVEL_INFO
21-
#include <misc/sys_log.h>
20+
#if defined(CONFIG_STDOUT_CONSOLE)
21+
#include <stdio.h>
22+
#define PRINT printf
23+
#else
24+
#include <misc/printk.h>
25+
#define PRINT printk
26+
#endif
2227

2328
void main(void)
2429
{
25-
SYS_LOG_INF("Power management template!");
30+
PRINT("Power management template!\n");
2631
}
2732

2833
/**

0 commit comments

Comments
 (0)