CreaLab / Mbed 2 deprecated MJBot2

Dependencies:   LED_WS2812 mbed X_NUCLEO_IHM02A1

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers Robot.h Source File

Robot.h

00001 //#include "AsyncServo.h"
00002 #include "LED_WS2812.h"
00003 //#include "AsyncBuzzer.h"
00004 
00005 // --- USB Debug Port -----------
00006 
00007 // #define DEBUG(...) { pc_uart.printf(__VA_ARGS__); bt_uart.printf(__VA_ARGS__);}
00008 #define DEBUG(...) {   __disable_irq();bt_uart.printf(__VA_ARGS__); pc_uart.printf(__VA_ARGS__);__enable_irq();}
00009 // #define DEBUG(...) { bt_uart.printf(__VA_ARGS__); }
00010 
00011 #define CATCH_BUTTON(button, func) button.fall(&func)
00012 
00013 #define CASE(letter, text, commands) case letter: if(flaghelp) DEBUG("\t%c : %s\n\r", letter,text);if(!flaghelp) {commands;break;};
00014 
00015