summaryrefslogtreecommitdiff
path: root/stm32/debug.h
diff options
context:
space:
mode:
Diffstat (limited to 'stm32/debug.h')
-rw-r--r--stm32/debug.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/stm32/debug.h b/stm32/debug.h
new file mode 100644
index 0000000..d542317
--- /dev/null
+++ b/stm32/debug.h
@@ -0,0 +1,11 @@
+
+#ifndef DEBUG_H_
+#define DEBUG_H_
+
+#ifdef DEBUG
+#define DBG_P(lvl, ...) if (DEBUG>=lvl) fprintf( stderr, __VA_ARGS__ )
+#else
+#define DBG_P(lvl, ...)
+#endif
+
+#endif /* DEBUG_H_ */