mulicheng/fx2lib — pull request #9 by dewyatt (2013-08-17 16:26:17+00:00)
Title: Add descriptor handling hook

Simple hook to allow user handling of descriptor requests (to support HID, etc). This allows, for example, fw/fw.c to do something like:

```c
void handle_get_descriptor() {
switch ( SETUPDAT[3] ) {
case DSCR_HID: //HID Descriptor
SUDPTRH = MSB((WORD)&hid_dscr);
SUDPTRL = LSB((WORD)&hid_dscr);
return true;
case DSCR_REPORT: //Report Descriptor
//...
return true;
}
//did not handle the request
return false;
}
```