From 0c3f04f34e81a0c13c093e8fa2cc5720d58e78b6 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Sun, 4 Aug 2013 22:09:52 +0000 Subject: improved board config for MPU chibios git-svn-id: https://svn.spreadspace.org/mur.sat@822 7de4ea59-55d0-425e-a1af-a3118ea81d4c --- software/mpu/main.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'software/mpu/main.c') diff --git a/software/mpu/main.c b/software/mpu/main.c index dd34960..e4c6a5b 100644 --- a/software/mpu/main.c +++ b/software/mpu/main.c @@ -38,9 +38,9 @@ static msg_t Thread1(void *arg) { (void)arg; chRegSetThreadName("blinker"); while (TRUE) { - palClearPad(GPIOC, GPIOC_LED); + palClearPad(GPIOA, GPIOA_LED); chThdSleepMilliseconds(500); - palSetPad(GPIOC, GPIOC_LED); + palSetPad(GPIOA, GPIOA_LED); chThdSleepMilliseconds(500); } } @@ -70,13 +70,16 @@ int main(void) { */ chThdCreateStatic(waThread1, sizeof(waThread1), NORMALPRIO, Thread1, NULL); + /* + * run tests after initialization is complete + */ + TestThread(&SD2); + /* * Normal main() thread activity, in this demo it does nothing except - * sleeping in a loop and check the button state. + * sleeping in a loop. */ while (TRUE) { - if (palReadPad(GPIOA, GPIOA_BUTTON)) - TestThread(&SD2); chThdSleepMilliseconds(500); } } -- cgit v1.2.3