/* Request to send a reset on a port.  */
USBPD_StatusTypeDef USBPD_PHY_ResetRequest(uint8_t PortNum, USBPD_SOPType_TypeDef Type)
/* Request to send a reset on a port.  */
USBPD_StatusTypeDef USBPD_PHY_ResetRequest(uint8_t PortNum, USBPD_SOPType_TypeDef Type)
{
  if (USBPD_PHY_SendMessage(PortNum, Type, NULL, 0) != USBPD_OK)
  {
    return USBPD_ERROR;
  }
  PHY_Ports[PortNum].State = PHY_StateBusy;
  PHY_TxBuffer_Reset(PortNum);
  if (PHY_Ports[PortNum].cbs->USBPD_PHY_ResetCompleted != NULL)
  {
    PHY_Ports[PortNum].cbs->USBPD_PHY_ResetCompleted(PortNum, Type);
  }
  PHY_Ports[PortNum].State = PHY_StateNone;
  return USBPD_OK;
}