Instruction manual
Renesas USB MCU and USB ASSP USB Basic Host and Peripheral firmware
R01AN0512EJ0210 Rev.2.10 Page 43 of 157
Apr 1, 2013
R_usb_pstd_ControlEnd
Control transfer end request
Format
void R_usb_pstd_ControlEnd (USB_UTR_t *ptr, uint16_t status)
Argument
*ptr Pointer to a USB Transfer Structure
status Status
Return Value
-
Description
This function issues a request for control transfer status stage execution to PCD. It is called at the control transfer
status stage.
Besides above arguments, also set the following value for the status argument.
・USB_CTRL_END
Status stage normal end.
・USB_DATA_STOP
Return NAK to host at status stage.
・USB_DATA_OVR
Return STALL to host at status stage.
Note
1. Besides above arguments, also set the following members of the USB Transfer Structure.
USB_REGADR_t ipp :USB register base address
uint16_t ip :USB IP number
2. Please call this function at the control transfer status stage. Refer to
4.4 Peripheral Control Transfer.,
Example
void usb_smp_task(USB_UTR_t *ptr)
{
:
R_usb_pstd_ControlEnd(ptr, (uint16_t)USB_CTRL_END);
:
}