lpcware

USBHID in LPC1769

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by Sudee on Thu Nov 28 04:44:42 MST 2013
0:) hello.

i am sudeep,

I have designed the usb based data acquisition using the lpc1769 and a 16 bit ADC using lpc1769 as an usbhid device with FULL SPEED Operation.

I am using the labview to send command to the lpc1769 device to start , get the adc data from  the device and stop the operation.

All my IN and OUT transactions are based on the INTERRUPT ENDPOINT 1.

I set the data bytes for the OUT EP WITH 20 byes and IN EP with the 2 bytes only.

As my ADC data is 16 bit (i.e 2 bytes ) and the USB configured for the 8bits mode so i need to send the 16 bit by splitting it to 2bytes.

the device is getting the commands from  the PC correctly but the IN endpoint is seems to be not working properly 
in the  sense that

by keeping the lpc1769 in the debug mode and continuous exec mode

if i give sampling rate as 1000hz or 1kz and number of  samples will be 10 points then for each second i need to get 100 samples from the

usb device but i am getting only about 20 samples on the PC side.

but if i run with the breakpoints  i am getting the exact 100 samples

why its so and where may be the problem...........? whether on the usb device side or PC program side?

In my code i cant put delay between the each USBWriteEP fuction call as it is going to affect the speed of the ADC samples collection..

please help me.

and also how i can trace the speed of data sent by the USB device ?

regards


regards

Outcomes