7
\$\begingroup\$

I'm trying to make a project using the Arduino ADK board and a Sony Ericsson Xperia Play running Android 2.3.4. For starters all I want to do is blink a LED from my Android device, using the nice tutorial found here. I managed to compile the Android app but I'm having big difficulties on the Arduino sketch. I can't resolve the imports and it won't compile. I understant there are some Arduino IDE version issues. I tried compiling on both 0023 and on 1.0. The furthest I could go with the code was getting these compile errors:

D:\arduino-0023\libraries\AndroidAccessory/AndroidAccessory.h:37: error: 'EP_RECORD' does not name a type
D:\arduino-0023\libraries\AndroidAccessory/AndroidAccessory.h:50: error: 'EP_RECORD' has not been declared
D:\arduino-0023\libraries\AndroidAccessory/AndroidAccessory.h:50: error: 'EP_RECORD' has not been declared
D:\arduino-0023\libraries\AndroidAccessory/AndroidAccessory.h:64: error: 'USB_NAK_LIMIT' was not declared in this scope

I think I read the whole documentation and I can't find a solution to my problem. Setting this up is such a pain... I really need to make this work.

\$\endgroup\$
1
\$\begingroup\$

The library was written and tested in:

Arduino Alpha 0022

Have you tried this?

#if defined(ARDUINO) && ARDUINO >= 100
  #include "Arduino.h"
#else
  #include "WProgram.h" #endif 
\$\endgroup\$
  • 1
    \$\begingroup\$ yes I did :( this small header edit got me this far but still left me with the errors you see above... \$\endgroup\$ – androidu Feb 1 '12 at 21:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.