USBD_PHDC_Wr
Description
Write PHDC data. This function is blocking.
Files
usbd_phdc.h / usbd_phdc.c
Prototype
void USBD_PHDC_Wr (CPU_INT08U class_nbr, void *p_buf, CPU_INT16U buf_len, LATENCY_RELY_FLAGS latency_rely CPU_INT16U timeout, USBD_ERR *p_err);
Arguments
class_nbr
PHDC instance number.
p_buf
Pointer to buffer that will supply data.
buf_len
Buffer length in octets.
latency_rely
Latency / reliability of this transfer.
timeout
Timeout in milliseconds.
p_err
Pointer to variable that will receive the return error code from this function.
USBD_ERR_NONE
USBD_ERR_INVALID_ARG
USBD_ERR_NULL_PTR
USBD_ERR_TX
USBD_ERR_INVALID_CLASS_STATE
USBD_ERR_DEV_INVALID_NBR
USBD_ERR_DEV_INVALID_STATE
USBD_ERR_EP_INVALID_ADDR
USBD_ERR_EP_INVALID_STATE
USBD_ERR_EP_INVALID_TYPE
USBD_OS_ERR_TIMEOUT
USBD_OS_ERR_ABORT
USBD_OS_ERR_FAIL
Returned Value
None.
Callers
Application.
Notes / Warnings
USBD_PHDC_Wr()
should always be called after
if metadata message preambles are enabled by the host and if the latency of the transfer is not ‘low’.USBD_PHDC_PreambleWr()
- Application will have to call
USBD_PHDC_Wr()
‘nbr_xfers
’of times with the same latency / reliability parameter after a call toUSBD_PHDC_PreambleWr
.