summaryrefslogtreecommitdiff
path: root/src/ao_panic.c
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2011-03-06 20:56:25 -0800
committerKeith Packard <keithp@keithp.com>2011-03-16 15:57:37 -0700
commit02611efea0c485d78fad08c696c1f56e868d36b8 (patch)
treef51ef97cbc62c88a9084c4de05d4446de58e7142 /src/ao_panic.c
parentfdd15a254c6fab5ba2d02320ba0ceb3e6a56354c (diff)
altos: Make serial, usb, beeper and accelerometer optional components
Not all boards will have these, so fix places that use them to deal with that. Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src/ao_panic.c')
-rw-r--r--src/ao_panic.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/ao_panic.c b/src/ao_panic.c
index e996371e..fdada201 100644
--- a/src/ao_panic.c
+++ b/src/ao_panic.c
@@ -17,6 +17,14 @@
#include "ao.h"
+#ifndef HAS_BEEP
+#error Please define HAS_BEEP
+#endif
+
+#if !HAS_BEEP
+#define ao_beep(x)
+#endif
+
static void
ao_panic_delay(uint8_t n)
{