/** * @brief Main program * @param None * @retval None */ int main(void) { /* STM32F3xx HAL library initialization: - Configure the Flash prefetch - Systick timer is configured by default as source of time base, but user can eventually implement his proper time base source (a general purpose timer for example or other time source), keeping in mind that Time base duration should be kept 1ms since PPP_TIMEOUT_VALUEs are defined and handled in milliseconds basis. - Set NVIC Group Priority to 4 - Low Level Initialization */ HAL_Init(); /* Configure the system clock to have a system clock = 64 Mhz */ SystemClock_Config(); /* Check the availability of adafruit 1.8" TFT shield on top of STM32NUCLEO board. This is done by reading the state of IO PB.00 pin (mapped to JoyStick available on adafruit 1.8" TFT shield). If the state of PB.00 is high then the adafruit 1.8" TFT shield is available. */ if(TFT_ShieldDetect() == SHIELD_DETECTED) { /* Initialize the LCD */ BSP_LCD_Init(); /* Configure SD card */ SDCard_Config(); /* Display on TFT Images existing on SD card */ TFT_DisplayImages(); } else /* Shield not mounted */ { LED2_Blink(); } /* Infinite loop */ while (1) { } }
/** * @brief Main program * @param None * @retval None */ int main(void) { /* STM32F4xx HAL library initialization: - Configure the Flash prefetch, instruction and Data caches - Configure the Systick to generate an interrupt each 1 msec - Set NVIC Group Priority to 4 - Global MSP (MCU Support Package) initialization */ HAL_Init(); /* Configure the system clock to 100 MHz */ SystemClock_Config(); /* Check the availability of adafruit 1.8" TFT shield on top of STM32NUCLEO board. This is done by reading the state of IO PB.00 pin (mapped to JoyStick available on adafruit 1.8" TFT shield). If the state of PB.00 is high then the adafruit 1.8" TFT shield is available. */ if(TFT_ShieldDetect() == SHIELD_DETECTED) { /* Initialize the LCD */ BSP_LCD_Init(); /* Configure SD card */ SDCard_Config(); /* Display on TFT Images existing on SD card */ TFT_DisplayImages(); } else /* Shield not mounted */ { LED2_Blink(); } /* Infinite loop */ while (1) { } }