refractor usbd task

move control request data into task event
adding tusbd_msc_read10_cb, tusbd_msc_write10_cb (not fully supported)
This commit is contained in:
hathach
2013-11-25 16:42:04 +07:00
parent a5ba283557
commit 51def3f7ed
7 changed files with 150 additions and 116 deletions
+2 -2
View File
@@ -175,9 +175,9 @@ void endpoint_control_isr(void)
{
tusb_control_request_t control_request;
(void) sie_read(SIE_CMDCODE_ENDPOINT_SELECT_CLEAR_INTERRUPT+0, 1); // clear setup bit, can be omitted ???
(void) sie_read(SIE_CMDCODE_ENDPOINT_SELECT_CLEAR_INTERRUPT+0, 1); // clear setup bit
pipe_control_read(&control_request, 8);
pipe_control_read(&control_request, 8); // TODO read before clear setup above
usbd_setup_received_isr(0, &control_request);
}else