lpcware

usbhid problems

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by raphaelh on Wed Nov 03 03:27:00 MST 2010
Hi All,

I need some help because I cannot make any sense of what I get when I try to run the usbhid example on my lcp1343 board.
I behaves all the time differently I don't where to start to have some consistency.
How can I make this example work on the first time I run "Debug 'usbhid'"???
Where should I look first to fix this?
Below is a summary of the results I get.

And another question: about the usbmsd example: when I run it the device is enumerated ok but when I try to read the drive I get:
Please insert a disk into removable disk instead of the readme file:
(usbmsd USB example that implements a Mass Storage Class
device with a readme.txt file on it.)


Thanks,
raphael



[B]1) After power up of my board if i run the "Debug 'usbhid'":
[/B]I see the "initializing lpc link" and the device being configured.
Then I get the error message:


LPCXpresso Debug Driver v2.0 (Aug 31 2010 23:36:44)
Looked for chip XML file in C:/nxp/lpcxpresso_3.5/bin/LPC1343.xml
Looked for vendor directory XML file in    
C:/nxp/lpcxpresso_3.5/bin/nxp_directory.xml
Found generic directory XML file in 
C:/nxp/lpcxpresso_3.5/bin/crt_directory.xml
02: Failed on connect: Ee(82). Device not found
31: No connection to emulator device

And I see that the usb is enumerated as a drive with a file called: firmware.bin

[B]2) I rerun the "Debug 'usbhid'" a second time
[/B]
I dont see the "initializing lpc link" window
I get into debug mode and it works, I can use the application :
"LPC1343 HID Demonstration.exe"

I just have the message: "Stalled on bus operation" blinking very fast in the bottom left of eclipse

[B]3)Then if I stop the debugger and rerun the "Debug 'usbhid'" a third time
[/B]I get:
LPCXpresso Debug Driver v2.0 (Aug 31 2010 23:36:44)
Looked for chip XML file in C:/nxp/lpcxpresso_3.5/bin/LPC1343.xml
Looked for vendor directory XML file in C:/nxp/lpcxpresso_3.5/bin/nxp_directory.xml
Found generic directory XML file in C:/nxp/lpcxpresso_3.5/bin/crt_directory.xml
02: Failed on connect: Ee(82). Device not found
31: No connection to emulator device

I this I get now every time I try to rerun the debug mode
I need to power down the board to start again


[B]Sometime I also get things like that:
[/B] Flash write Done
nSRST assert (if available)
Executing in user flash.
Stopped (Was Reset)  [Reset from  PowerOn, External, SysRes]
GDB trying to set entry point of 0x0124, but correct entry is 0x1FFF0104
Stopped: Breakpoint #1

[B]And sometime I also get things like that:
LPCXpresso Debug Driver v2.0 (Aug 31 2010 23:36:44)
Looked for chip XML file in C:/nxp/lpcxpresso_3.5/bin/LPC1343.xml
Looked for vendor directory XML file in C:/nxp/lpcxpresso_3.5/bin/nxp_directory.xml
Found generic directory XML file in C:/nxp/lpcxpresso_3.5/bin/crt_directory.xml
Emu(0): Conn&Reset. DpID: 2BA01477. Info: T1S6RGRIA
SWD Frequency: 3000 KHz. RTCK: False. Vector catch: False.
Packet delay: 0  Poll delay: 0.
Invalid LPC1343 Part ID: 0x3000002B

Outcomes