- // TODO: Data toggle?
- // TODO: Multi-packet transfers
- if( Type & 0x80 )
- {
- void *hdl2;
-
- LOG("IN");
- hdl = Host->HostDef->SendIN(Host->Ptr, dest, 0, NULL, NULL, Data, Len);
-
- LOG("OUT (Done)");
- hdl2 = Host->HostDef->SendOUT(Host->Ptr, dest, 0, INVLPTR, NULL, NULL, 0);
- LOG("Wait...");
- while( Host->HostDef->IsOpComplete(Host->Ptr, hdl2) == 0 )
- Time_Delay(1);
+ LOG("Send");
+ if( Type & 0x80 ) {
+ // Inbound data
+ hdl = Host->HostDef->SendControl(Host->Ptr, dest_hdl, USB_int_WakeThread, thisthread, 0,
+ &req, sizeof(req),
+ NULL, 0,
+ Data, Len
+ );