From 748ce8d634a8276616c3ba3b970f248fe617316a Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Mon, 22 Mar 2021 08:44:08 +0000 Subject: [PATCH] It runs... git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@14078 27425a3e-05d8-49a3-a47f-9c15f0e5edd8 --- demos/RP/RT-RP2040-PICO/Makefile | 6 +++--- demos/RP/RT-RP2040-PICO/main.c | 14 +++++--------- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/demos/RP/RT-RP2040-PICO/Makefile b/demos/RP/RT-RP2040-PICO/Makefile index 054045685..933cc61b6 100644 --- a/demos/RP/RT-RP2040-PICO/Makefile +++ b/demos/RP/RT-RP2040-PICO/Makefile @@ -5,7 +5,7 @@ # Compiler options here. ifeq ($(USE_OPT),) - USE_OPT = -O2 -ggdb -fomit-frame-pointer -falign-functions=16 + USE_OPT = -O0 -ggdb -fomit-frame-pointer -falign-functions=16 endif # C specific options here (added to USE_OPT). @@ -150,10 +150,10 @@ CPPWARN = -Wall -Wextra -Wundef # # List all user C define here, like -D_DEBUG=1 -UDEFS = +UDEFS = -DCRT0_VTOR_INIT=1 # Define ASM defines here -UADEFS = +UADEFS = -DCRT0_VTOR_INIT=1 # List all user directories here UINCDIR = diff --git a/demos/RP/RT-RP2040-PICO/main.c b/demos/RP/RT-RP2040-PICO/main.c index b0ca9a623..70e53b0e4 100644 --- a/demos/RP/RT-RP2040-PICO/main.c +++ b/demos/RP/RT-RP2040-PICO/main.c @@ -14,7 +14,6 @@ limitations under the License. */ -#if 0 #include "ch.h" #include "hal.h" #include "rt_test_root.h" @@ -29,20 +28,18 @@ static THD_FUNCTION(Thread1, arg) { (void)arg; chRegSetThreadName("blinker"); while (true) { - palClearLine(LINE_LED_GREEN); +// palClearLine(LINE_LED_GREEN); chThdSleepMilliseconds(500); - palSetLine(LINE_LED_GREEN); +// palSetLine(LINE_LED_GREEN); chThdSleepMilliseconds(500); } } -#endif /* * Application entry point. */ int main(void) { -#if 0 /* * System initializations. * - HAL initialization, this also initializes the configured device drivers @@ -57,14 +54,13 @@ int main(void) { * Activates the Serial or SIO driver using the default configuration. */ // sdStart(&LPSD1, NULL); - sioStart(&LPSIOD1, NULL); - sioStartOperation(&LPSIOD1, NULL); +// sioStart(&LPSIOD1, NULL); +// sioStartOperation(&LPSIOD1, NULL); /* * Creates the blinker thread. */ chThdCreateStatic(waThread1, sizeof(waThread1), NORMALPRIO, Thread1, NULL); -#endif /* * Normal main() thread activity, in this demo it does nothing except @@ -76,8 +72,8 @@ int main(void) { test_execute((BaseSequentialStream *)&LPSIOD1, &rt_test_suite); test_execute((BaseSequentialStream *)&LPSIOD1, &oslib_test_suite); } - chThdSleepMilliseconds(500); #endif + chThdSleepMilliseconds(500); } }