mirror of
https://github.com/hathach/tinyusb.git
synced 2025-01-31 05:52:55 +08:00
get pass set address
This commit is contained in:
parent
72b5b61597
commit
d55f9ecef1
@ -126,7 +126,8 @@ void endpoint_control_isr(uint8_t coreid)
|
|||||||
usbd_isr(0, TUSB_EVENT_SETUP_RECEIVED);
|
usbd_isr(0, TUSB_EVENT_SETUP_RECEIVED);
|
||||||
}else
|
}else
|
||||||
{
|
{
|
||||||
//ASSERT(false, (void) 0); // not current supported
|
// RxPLen should be zero for zero-length status phase. Current not support any out control with data yet
|
||||||
|
ASSERT(LPC_USB->USBRxPLen == 0, (void) 0);
|
||||||
}
|
}
|
||||||
sie_command_write(SIE_CMDCODE_ENDPOINT_SELECT+0, 0, 0);
|
sie_command_write(SIE_CMDCODE_ENDPOINT_SELECT+0, 0, 0);
|
||||||
sie_command_write(SIE_CMDCODE_BUFFER_CLEAR, 0, 0);
|
sie_command_write(SIE_CMDCODE_BUFFER_CLEAR, 0, 0);
|
||||||
|
@ -109,13 +109,13 @@ void usbd_setup_received(uint8_t coreid)
|
|||||||
case TUSB_REQUEST_SET_ADDRESS:
|
case TUSB_REQUEST_SET_ADDRESS:
|
||||||
p_device->address = (uint8_t) p_device->setup_packet.wValue;
|
p_device->address = (uint8_t) p_device->setup_packet.wValue;
|
||||||
dcd_device_set_address(coreid, p_device->address);
|
dcd_device_set_address(coreid, p_device->address);
|
||||||
|
dcd_pipe_control_write_zero_length(coreid);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// dcd_pipe_control_write_zero_length(coreid);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------+
|
//--------------------------------------------------------------------+
|
||||||
|
Loading…
x
Reference in New Issue
Block a user