views:

15

answers:

0

I have a LPC1768 microcontroler that I am trying to use to read a joystick. I am using the usblite sample code provided with the microcontroller to get a head start. It is meant for a flash drive but from what I have read the enumeration is the same no matter what the device is. However when I connect any hid device, it fails to write to the device. The code checks HOST_TDControlStatus to see if it is 0 but it is actually equal to 5. HOST_TDControlStatus = (TDHead->Control >> 28) & 0xf; However I don't know what it is supposed to be monitoring. Could the device be responding where the code isn't expecting it to be?Is the enumeration not the same across devices or is something else wrong?