- This topic has 5 replies, 3 voices, and was last updated 8 years, 1 month ago by .
Viewing 6 posts - 1 through 6 (of 6 total)
Viewing 6 posts - 1 through 6 (of 6 total)
- You must be logged in to reply to this topic.
Home › Forums › Mastering STM32 book support forum › USB middleware project
Ciao Carmine and All,
I need to write a file in a USB Flash drive, so my board is going to be the host.
This topic is not yet included in your book, but it seems to be implemented in the HAL libraries as middleware.
Following your book I’ve been able to implement the ADC on my own, but now I can’t figure out how to manually import a project in Eclipse using middleware libraries. I guess Liviu’s plugin doesn’t include this stuff.
I’d rather import the project from the STM32Cube_FW_F4 than generating and importing it with the CubeMX tool. The board for this project is a stm32f4Discovery.
Could you tell me what folders I need to import and where should they been placed in the Eclipse project tree?
Thank you very much.
Regards,
Pedro.
Hi Pedro,
I’ve plans to modify the CubeMXImporter tool so that it can import USB middleware library too, but I don’t know exactly when.
If memory serves, you have to drag the Middleware folder as-is inside the root of the Eclipse project. Then you have to add to include paths (in project settings) all folders containing .h files
“../Middlewares/ST/STM32_USB_Device_Library/Class/CDC/Inc”
“../Middlewares/ST/STM32_USB_Device_Library/Core/Inc”
This should be sufficient.
Thanks, Carmine.
I’ll give it a try.
Hi, sorry to bring this topic back up here.
I’m trying to create an USB audio project, if I copy all the middleware .h and .c files to the root source and inc folders it compiles and works, but if I try to have the middlewares in a separate folder under the root I get a lot of undefined references.
I’ve dragged and dropped the middlewares folder to my project’s root and then added the folders containing .h files into the C/C++ build settings under the GNU assembler, C complier and C++ compiler to no avail.
I am sure I am missing something stupid but I seem to be unable to know what it is…
thank you!
Two things to check:
that was it, folders were indeed excluded.
thank you so much Carmine