aboutsummaryrefslogtreecommitdiffstats
path: root/demos/LPC21xx/RT-LPC214x-OLIMEX
diff options
context:
space:
mode:
Diffstat (limited to 'demos/LPC21xx/RT-LPC214x-OLIMEX')
-rw-r--r--demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile4
-rw-r--r--demos/LPC21xx/RT-LPC214x-OLIMEX/main.c5
2 files changed, 7 insertions, 2 deletions
diff --git a/demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile b/demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile
index 7c49c63e5..57620a023 100644
--- a/demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile
+++ b/demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile
@@ -122,7 +122,9 @@ include $(CHIBIOS)/os/hal/osal/rt/osal.mk
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARM/compilers/GCC/mk/port_generic.mk
# Other files (optional).
-include $(CHIBIOS)/test/rt/test.mk
+include $(CHIBIOS)/test/lib/test.mk
+include $(CHIBIOS)/test/rt/rt_test.mk
+include $(CHIBIOS)/test/oslib/oslib_test.mk
# Define linker script file here
LDSCRIPT= $(STARTUPLD)/LPC2148.ld
diff --git a/demos/LPC21xx/RT-LPC214x-OLIMEX/main.c b/demos/LPC21xx/RT-LPC214x-OLIMEX/main.c
index bc52e4f58..2c63f6315 100644
--- a/demos/LPC21xx/RT-LPC214x-OLIMEX/main.c
+++ b/demos/LPC21xx/RT-LPC214x-OLIMEX/main.c
@@ -17,6 +17,7 @@
#include "ch.h"
#include "hal.h"
#include "rt_test_root.h"
+#include "oslib_test_root.h"
#define BOTH_BUTTONS (PAL_PORT_BIT(PA_BUTTON1) | PAL_PORT_BIT(PA_BUTTON2))
@@ -89,8 +90,10 @@ int main(void) {
while (true) {
if (!palReadPad(IOPORT1, PA_BUTTON1))
sdWrite(&SD1, (uint8_t *)"Hello World!\r\n", 14);
- if (!palReadPad(IOPORT1, PA_BUTTON2))
+ if (!palReadPad(IOPORT1, PA_BUTTON2)) {
test_execute((BaseSequentialStream *)&SD1, &rt_test_suite);
+ test_execute((BaseSequentialStream *)&SD1, &oslib_test_suite);
+ }
chThdSleepMilliseconds(500);
}
return 0;