Problems with USB Host in LPC1768

22 Jul 2012

Hi,

I'm having problems with the library USB Host of Igor Skochinsky.

I imported the sample program, MSCUsbHost, but the library mbed is outdated (version 17 and 41 is new).

When you update the library, an error occurs on debug (27 errors and 13 warnings).

I need the library mbed updated and do not know what to do!

Thank you for listening and I await an answer.

Carlos Alberto.

22 Jul 2012

It is easier to help if you would copy which error(s) you get, and link to which library exactly you are using. I picked the first one I saw, and there I had to manually add the FatFileSystem library, I assume you did that too?

After I then update the mbed library I do indeed get errors. In the past c files were compiled as cpp files, that doesnt happen anymore. Renaming every *.c file in both the USBHost library as in the FatFileSystem library to *.cpp removes the errors, then they are all again compiled as they used to be. No idea which file exactly is responsible, but renaming all works.

22 Jul 2012

Dear Erik Olieman,

I'm sorry, I'm new on Mbed.

In this page, you can import my program: http://mbed.org/users/carlos_nascimento08/code/MSCUsbHost_v2/rev/ebf86c956c58

Thank you for listening. Carlos Alberto.

23 Jul 2012

Hi Carlos,

Latest mbed library seems not to work with the other imported libraries. Replacing the mbed library with the old one (rev.39) would fix the problem.

Hiroshi

23 Jul 2012

That was indeed a slightly different version of the fatfilesystem than I found. Still the solution is the same. In the USBHostLite directory there are two *.c files, usbhost_lpc7xx.c and usbhost_ms.c. Simply right click both these files, and choose rename. Then name them usbhost_lpc7xx.cpp and usbhost_ms.cpp. Then it compiles fine for me again.

23 Jul 2012

Hi All,

I have republished the library with this fix.

The back ground to all this can be read about here :

http://mbed.org/forum/news-announcements/topic/3686/

Thanks, Chris