When debugging, send ao_panic message to ao_debug_out
[fw/altos] / src / core / ao_panic.c
index 244917a8af9a32a44c0bc1bc756bee7f00750f90..25dc145eea69ecd9c3b7320bee32a4b43b3f67f7 100644 (file)
@@ -45,6 +45,10 @@ ao_panic(uint8_t reason)
 {
        uint8_t n;
 
+#if LOW_LEVEL_DEBUG
+       ao_cur_task = NULL;
+       printf ("panic %d\n", reason);
+#endif
        __critical for (;;) {
                ao_panic_delay(20);
                for (n = 0; n < 5; n++) {