cancel
Showing results for 
Search instead for 
Did you mean: 

Stm32F7 USB HOST USB DISK f_mount cause HardFault_Handler

PZamb.2
Associate III

Hi

I have a custom board with STM32F799 and USB host device for read a data file from flash Key.

The development software is STM32CUBEIDE V1.13.0

The firmware include TouchGFX with FREETOS V1 for manage a graphix display.

I configured USB_Host for Mass storage Host Class and include FATFS for USB DISK

In the FreeTOS I allocate the Task for USB with 2048 stack size priority Low default dynamic.

The start of task initialize MX_USB_HOST_Init(); ,it  detect the USB device and in usb_host.c start Mount of USB device.

The problem is when active f_mount(&USBHFatFS, USBHPath, 1); the execution end with HardFault_Handler.

The Fault Analizer indicate Bus , memory management or usage fault (forced) / precise data access violation (PRECISERR) 0xa00ef2d4

I have another firmware without FREETOS thar read flash kay and run fine on the same board.

Someone have idea where is the problem?

Another question About USH_HOST

STM32CubeIDE auto generate the library wen istance device but the version of USB_HOST is 1.0 and there is an error in usbh_ctlreg.c line 561, I shall replace any time the row.

Is There a way to update the library in STM32CubeIDE?

Thank

 

 

0 REPLIES 0