diff --git a/libraries/AP_Common/AP_Common.h b/libraries/AP_Common/AP_Common.h index 98cb5bd618..0cfdbc3da1 100644 --- a/libraries/AP_Common/AP_Common.h +++ b/libraries/AP_Common/AP_Common.h @@ -34,7 +34,6 @@ typedef struct { } prog_char_t; #include -#include "include/menu.h" /// simple menu subsystem #include "c++.h" // c++ additions //#include "AP_Vector.h" //#include "AP_Loop.h" diff --git a/libraries/AP_Common/menu.cpp b/libraries/AP_Menu/AP_Menu.cpp similarity index 99% rename from libraries/AP_Common/menu.cpp rename to libraries/AP_Menu/AP_Menu.cpp index 784dd60643..ab912dac2d 100644 --- a/libraries/AP_Common/menu.cpp +++ b/libraries/AP_Menu/AP_Menu.cpp @@ -11,7 +11,7 @@ #include #include -#include "include/menu.h" +#include "AP_Menu.h" // statics char Menu::_inbuf[MENU_COMMANDLINE_MAX]; diff --git a/libraries/AP_Common/include/menu.h b/libraries/AP_Menu/AP_Menu.h similarity index 98% rename from libraries/AP_Common/include/menu.h rename to libraries/AP_Menu/AP_Menu.h index 452daa0562..7a95403769 100644 --- a/libraries/AP_Common/include/menu.h +++ b/libraries/AP_Menu/AP_Menu.h @@ -13,8 +13,8 @@ /// Arguments passed to the handler function are pre-converted to both /// long and float for convenience. -#ifndef __AP_COMMON_MENU_H -#define __AP_COMMON_MENU_H +#ifndef __AP_MENU_H__ +#define __AP_MENU_H__ #include @@ -140,4 +140,4 @@ private: static const char __menu_name__ ## name[] PROGMEM = prompt; \ static Menu name(__menu_name__ ## name, commands, sizeof(commands) / sizeof(commands[0]), preprompt) -#endif +#endif // __AP_COMMON_MENU_H__ diff --git a/libraries/AP_Menu/examples/menu/Makefile b/libraries/AP_Menu/examples/menu/Makefile new file mode 100644 index 0000000000..d1f40fd90f --- /dev/null +++ b/libraries/AP_Menu/examples/menu/Makefile @@ -0,0 +1 @@ +include ../../../AP_Common/Arduino.mk diff --git a/libraries/AP_Common/examples/menu/menu.pde b/libraries/AP_Menu/examples/menu/menu.pde similarity index 94% rename from libraries/AP_Common/examples/menu/menu.pde rename to libraries/AP_Menu/examples/menu/menu.pde index 05a4dfdbee..32d016e535 100644 --- a/libraries/AP_Common/examples/menu/menu.pde +++ b/libraries/AP_Menu/examples/menu/menu.pde @@ -1,6 +1,8 @@ #include #include +#include +#include FastSerialPort0(Serial);