Pages: [1]   Go Down
Author Topic: Looking for USB Host Shield *WORKING* library  (Read 251 times)
0 Members and 1 Guest are viewing this topic.
BHZ, MG, Brazil
Offline Offline
Sr. Member
****
Karma: 10
Posts: 346
Android developer; Arduino enthusiast
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I've been trying, without any success, to use Felis' USB Host Shield 2.0 Library.

The problem is that this library won't compile in IDE 1.0.4.

My final objective is to have his PTP 2.0 Library working, but none of the examples in that library compile.

So, my question is: can anyone please refer me to a working USB Host Shield library that actually works with IDE 1.0.4 ?
Logged

Learn to live: Live to learn.
Showing off my work: http://arduino.cc/forum/index.php/topic,126197.0.html

Massachusetts, USA
Offline Offline
Tesla Member
***
Karma: 180
Posts: 8084
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I just downloaded the 2.0 library from: https://github.com/felis/USB_Host_Shield_2.0 by clicking on the ZIP button.  I copied USB_Host_Shield_2.0-master.zip into Documents/Arduino/libraries/.  Unzipped the file. Renamed the new USB_Host_Shield_2.0-master folder to 'usbhub'.  Re-started the IDE.  Then File->Examples->usbhub->HID->USBHIDJoystick compiled without error.

Could you have skipped one of those steps?
Logged

Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

BHZ, MG, Brazil
Offline Offline
Sr. Member
****
Karma: 10
Posts: 346
Android developer; Arduino enthusiast
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, John.

That is pretty much what I did. the only difference is that the library folder is inside my sketchbook\libraries folder, so it is visible across all the IDEs I use.

This is what I get when I try to compile that very same sketch:

USBHIDJoystick.pde: At global scope:
USBHIDJoystick:22: error: redefinition of 'USB Usb'
USBHIDJoystick:22: error: 'USB Usb' previously declared here
USBHIDJoystick:23: error: redefinition of 'USBHub Hub'
USBHIDJoystick:23: error: 'USBHub Hub' previously declared here
USBHIDJoystick:24: error: redefinition of 'HIDUniversal Hid'
USBHIDJoystick:24: error: 'HIDUniversal Hid' previously declared here
USBHIDJoystick:25: error: redefinition of 'JoystickEvents JoyEvents'
USBHIDJoystick:25: error: 'JoystickEvents JoyEvents' previously declared here
USBHIDJoystick:26: error: redefinition of 'JoystickReportParser Joy'
USBHIDJoystick:26: error: 'JoystickReportParser Joy' previously declared here
USBHIDJoystick.pde: In function 'void setup()':
USBHIDJoystick:28: error: redefinition of 'void setup()'
USBHIDJoystick:28: error: 'void setup()' previously defined here
USBHIDJoystick.pde:39: warning: only initialized variables can be placed into program memory area
USBHIDJoystick.pde: In function 'void loop()':
USBHIDJoystick:42: error: redefinition of 'void loop()'
USBHIDJoystick:42: error: 'void loop()' previously defined here



I know some of those messages make absolutely no sense.

I've made sure there are no other USB-like libraries in use.

Also, I've tried the above in 2 IDEs, with the same unsuccessful results: Arduino 1.0.3 and ERW 1.0.3
« Last Edit: May 15, 2013, 11:25:22 am by AlxDroidDev » Logged

Learn to live: Live to learn.
Showing off my work: http://arduino.cc/forum/index.php/topic,126197.0.html

Pages: [1]   Go Up
Jump to: