we can check the Buffer1_full bit is set or not after selecting the End point. anyway, thanks a lot. -----Original Message----- From: lpc2000@yahoogroups.com [mailto:lpc2000@yahoogroups.com]On Behalf Of Manisha Kalita Sent: Friday, April 07, 2006 8:22 PM To: lpc2000@yahoogroups.com Subject: [lpc2000] A new problem:: checking for data receive in USB Endpoint hi the previous problem got solved. actually i was not checking the DataValid bit,. But, now, a new bug has come, the PKT_RDY is set only when interrupt is enabled, however, in the spec i suppose, this is not mentioned anywhere. and according to the design, i am using polling mode for data reception. so, can anyone help me to check for data reception in polling? thanks. -----Original Message----- From: lpc2000@yahoogroups.com [mailto:lpc2000@yahoogroups.com]On Behalf Of ian.scanlon Sent: Friday, April 07, 2006 7:33 PM To: lpc2000@yahoogroups.com Subject: [lpc2000] Re: Please help:: checking for data receive in USB Endpoint --- In lpc2000@yahoogroups.com, Manisha Kalita <manisha@...> wrote: > > can you give me the proper link for IAR code? > > about my code: > > /*Enable Read Mode and program the LOG_ENDPOINT High*/ > USB_CTRL = (DATA_TRANS_EP << 2) | CTRL_RD_EN; > > & then i am checking for PKT_RDY bit as below. > if (RX_PLENGTH & PKT_RDY) > read the data. > > > & here the if condition is always true. thats the main problem. > > regards, > Manisha > > > -----Original Message----- > From: lpc2000@yahoogroups.com [mailto:lpc2000@yahoogroups.com]On Behalf > Of ian.scanlon > Sent: Friday, April 07, 2006 7:13 PM > To: lpc2000@yahoogroups.com > Subject: [lpc2000] Re: Please help:: checking for data receive in USB > Endpoint > > > --- In lpc2000@yahoogroups.com, Manisha Kalita <manisha@> wrote: > > > > ya its lpc 2148 board > > ARM7 running at 60MHz, flash of 512 KB, RAM with 32 KB + 8 KB > Shared with > > USB DMA & USB 2.0 Device controller (Full Speed)DMA supported. > using gcc. & > > yes some help from sample code, i dont remeber the source. > > > > Regards, > > Manisha > > > > -----Original Message----- > > From: lpc2000@yahoogroups.com [mailto:lpc2000@yahoogroups.com]On > Behalf > > Of ian.scanlon > > Sent: Friday, April 07, 2006 6:36 PM > > To: lpc2000@yahoogroups.com > > Subject: [lpc2000] Re: Please help:: checking for data receive in > USB > > Endpoint > > > > > > --- In lpc2000@yahoogroups.com, Manisha Kalita <manisha@> wrote: > > > > > > Hi all, > > > > > > i am designing an USB driver in lpc2000 board. > > > > lpc2000 board?? what hardware? compiler? using example code from > > ____? PC test application? > > > > > > > > it is sending the data > > > properly. however, during reception, i am checking if any data is > > there in > > > the deveice register RXPLENGTH. if there is any peacket, PKT-RDY > > bit of this > > > register is set. but, in my case, even though no data is sent from > > the host, > > > PKT_RDY bit is always set. i am using interrupt transfer and so > > using > > > logical endpoint as 1. > > > > > Can't really say why your code doesn't work, but the example code > from Keil and IAR works well (mostly). > > Take a look at the IAR USB sample code. LPC_USB.c -> USB_EpRead (... > It is copyrighted so I won't post it here. Did you write the Read > enable bit? > > > > > > > > > > Yahoo! Groups Links > > > > > > > > The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s)and may contain confidential or privileged information. If you are not the intended recipient, please notify the sender or administrator@... > Look here for the IAR code. http://www.olimex.com/dev/soft/arm/LPC/LPC2148_USB.zip You will have to spend your own time at the IAR site or Keil site for more.(www.IAR.com, www.keil.com) I emailed you the IAR epRead function from IAR -Ian Yahoo! Groups Links The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s)and may contain confidential or privileged information. If you are not the intended recipient, please notify the sender or administrator@... Yahoo! Groups Links The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s)and may contain confidential or privileged information. If you are not the intended recipient, please notify the sender or administrator@...
Message
SOLVED:: new problem:: checking for data receive in USB Endpoint
2006-04-07 by Manisha Kalita
Attachments
- No local attachments were found for this message.