/* configures OUT endpoint 0 to receive SETUP packets  */
void usb_ctlep_startout(usb_core_driver *udev)
/* configures OUT endpoint 0 to receive SETUP packets  */
void usb_ctlep_startout(usb_core_driver *udev)
{
    udev->regs.er_out[0]->DOEPLEN = DOEP0_TLEN(8U * 3U) | DOEP0_PCNT(1U) | DOEP0_STPCNT(3U);
    if ((uint8_t)USB_USE_DMA == udev->bp.transfer_mode) {
        udev->regs.er_out[0]->DOEPDMAADDR = (uint32_t)&udev->dev.control.req;
        udev->regs.er_out[0]->DOEPCTL |= DEPCTL_EPACT | DEPCTL_EPEN;
    }
}