music map init, dip scan added
This commit is contained in:
parent
12a64ff24b
commit
91efe74365
10 changed files with 97 additions and 49 deletions
|
|
@ -717,12 +717,14 @@ void send_mouse(report_mouse_t *report) {
|
|||
}
|
||||
osalSysUnlock();
|
||||
|
||||
/* TODO: LUFA manually waits for the endpoint to become ready
|
||||
* for about 10ms for mouse, kbd, system; 1ms for nkro
|
||||
* is this really needed?
|
||||
*/
|
||||
|
||||
osalSysLock();
|
||||
if(usbGetTransmitStatusI(&USB_DRIVER, MOUSE_IN_EPNUM)) {
|
||||
/* Need to either suspend, or loop and call unlock/lock during
|
||||
* every iteration - otherwise the system will remain locked,
|
||||
* no interrupts served, so USB not going through as well.
|
||||
* Note: for suspend, need USB_USE_WAIT == TRUE in halconf.h */
|
||||
osalThreadSuspendS(&(&USB_DRIVER)->epc[MOUSE_IN_EPNUM]->in_state->thread);
|
||||
}
|
||||
usbStartTransmitI(&USB_DRIVER, MOUSE_IN_EPNUM, (uint8_t *)report, sizeof(report_mouse_t));
|
||||
osalSysUnlock();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue