static void prvQueueReceiveTask( void *pvParameters ) { uint32_t ulReceivedValue, ulLEDStatus; const uint32_t ulExpectedValue = 100UL; /* Remove compiler warning about unused parameter. */ ( void ) pvParameters; /* Initial cursor position to skip a line) */ g_printf_rcc( 5, 2, DEFAULT_SCREEN_COLOR, "LED on the Galileo board should be blinking." ); for( ;; ) { /* Wait until something arrives in the queue - this task will block indefinitely provided INCLUDE_vTaskSuspend is set to 1 in FreeRTOSConfig.h. */ xQueueReceive( xQueue, &ulReceivedValue, portMAX_DELAY ); /* To get here something must have been received from the queue, but is it the expected value? If it is, write a message to the COMP port. */ if( ulReceivedValue == ulExpectedValue ) { /* Toggle the LED, and also print the LED toggle state to the UART. */ ulLEDStatus = ulBlinkLED(); /* Print the LED status */ g_printf_rcc( 6, 2, DEFAULT_SCREEN_COLOR, "LED State = %d\r\n", ( int ) ulLEDStatus ); ulReceivedValue = 0U; } } }
void vPrintBanner( void ) { if (bGalileoSerialPortInitialized) { /* Print an RTOSDemo Loaded message */ ClearScreen(); g_printf_rcc(1, 2, DEFAULT_BANNER_COLOR, "%c[1mHELLO from the multiboot compliant FreeRTOS kernel!%c[0m", (char) 0x1B, (char) 0x1B ); printf(ANSI_HIDE_CURSOR); } }