Content originally posted in LPCWare by Fernando on Mon Feb 28 16:46:37 MST 2011
Hello. I´m developing an application using the on-chip USB driver and some questions arised.
First of all, the drivers require two callback functions to handle the in/out transactions.
In the report OUT function callback, the user must provide a pointer to some data area where the incoming usb data will be stored. The question is, if i reserved 384 bytes of RAM memory needed for the drivers, why do i need to use more memory?
am i wrong with this?
The second question is where are the callback functions called?? inside the usb interrupt?? I want to know, in order to develop efficient code, if its called from an isr or from any other function. Because is not the same to make a big callback function with command parsing and data processing than a callback function that only stores the data and sets a flag.
Best regards,
Fernando