break;
case REQUEST_TO_INTERFACE:
if ((USB_Configuration != 0) && (SetupPacket.wIndex.WB.L < USB_NumInterfaces)) {
+ //*((uint16_t __attribute__((packed)) *)EP0Buf) = 0;
*ep0 = 0;
EP0Data.pData = EP0Buf;
} else {
n = SetupPacket.wIndex.WB.L & 0x8F;
m = (n & 0x80) ? ((1 << 16) << (n & 0x0F)) : (1 << n);
if (((USB_Configuration != 0) || ((n & 0x0F) == 0)) && (USB_EndPointMask & m)) {
+ // *((uint16_t __attribute__((packed)) *)EP0Buf) = (USB_EndPointHalt & m) ? 1 : 0;
*ep0 = (USB_EndPointHalt & m) ? 1 : 0;
EP0Data.pData = EP0Buf;
} else {
return (TRUE);
}
+
/*
* Get Configuration USB Request
* Parameters: None (global SetupPacket)
case REQUEST_TO_DEVICE:
// Added cast to avoid warnings due to USB_Configuration being volatile (KTownsend)
EP0Data.pData = (uint8_t *)&USB_Configuration;
+ //EP0Data.pData = &USB_Configuration;
break;
default:
return (FALSE);
return (set);
}
+
/*
* USB Endpoint 0 Event Callback
* Parameters: event