AnsweredAssumed Answered

Bug in CubeMX with FATFS on SD-Card and FreeRTOS

Question asked by andi475 on Feb 16, 2016
Latest reply on Mar 22, 2016 by STM32Cube-T
The MX_FATFS_Init function is beeing called in the main function and again in the default task. After the second call the SD_Path is invalid. I'm using CubeMX 4.13.0 with the STM32F417IGH6, the configuration is in the attachments.

int main(void)
{


  /* USER CODE BEGIN 1 */


  /* USER CODE END 1 */


  /* MCU Configuration----------------------------------------------------------*/


  /* Reset of all peripherals, Initializes the Flash interface and the Systick. */
  HAL_Init();


  /* Configure the system clock */
  SystemClock_Config();


  /* Initialize all configured peripherals */
  MX_GPIO_Init();
  MX_DMA_Init();
  MX_SDIO_SD_Init();
  MX_FATFS_Init();

...



/* StartDefaultTask function */
void StartDefaultTask(void const * argument)
{
  /* init code for FATFS */
  MX_FATFS_Init();


  /* USER CODE BEGIN 5 */
  /* Infinite loop */
  for(;;)
  {
    osDelay(1);
  }
  /* USER CODE END 5 */ 
}

Attachments

Outcomes