sources/common/libs/STM32Cube_F4/Middlewares/ST/STM32_USB_Device_Library/Class/CCID/Src/usbd_ccid_cmd.c
/**
  * @brief  RDR_to_PC_NotifySlotChange
  *         Interrupt message to be sent to the host, Checks the card presence
  *         status and update the buffer accordingly
  * @param  pdev: device instance
  * @retval None
  */
@brief  RDR_to_PC_NotifySlotChange
Interrupt message to be sent to the host, Checks the card presence
status and update the buffer accordingly
@param  pdev: device instance
@retval None
@brief RDR_to_PC_NotifySlotChange Interrupt message to be sent to the host Checks the card presence status and update the buffer accordingly @param pdev : device instance @retval None
void RDR_to_PC_NotifySlotChange(USBD_HandleTypeDef  *pdev)
{
  USBD_CCID_HandleTypeDef  *hccid = (USBD_CCID_HandleTypeDef *)pdev->pClassDataCmsit[pdev->classId];
  hccid->UsbIntData[OFFSET_INT_BMESSAGETYPE] = RDR_TO_PC_NOTIFYSLOTCHANGE;
  if (SC_Detect() != 0U)
  {
    hccid->UsbIntData[OFFSET_INT_BMSLOTICCSTATE] = SLOT_ICC_PRESENT | SLOT_ICC_CHANGE;
  }
  else
  {
    hccid->UsbIntData[OFFSET_INT_BMSLOTICCSTATE] = SLOT_ICC_CHANGE;
    SC_Itf_IccPowerOff();
  }
}
void RDR_to_PC_NotifySlotChange ( USBD_HandleTypeDef * pdev ) { USBD_CCID_HandleTypeDef * hccid = ( USBD_CCID_HandleTypeDef * ) pdev -> pClassDataCmsit [ pdev -> classId ] ; hccid -> UsbIntData [ OFFSET_INT_BMESSAGETYPE ] = RDR_TO_PC_NOTIFYSLOTCHANGE ; if ( SC_Detect ( ) != 0U ) { hccid -> UsbIntData [ OFFSET_INT_BMSLOTICCSTATE ] = SLOT_ICC_PRESENT | SLOT_ICC_CHANGE ; } else { hccid -> UsbIntData [ OFFSET_INT_BMSLOTICCSTATE ] = SLOT_ICC_CHANGE ; SC_Itf_IccPowerOff ( ) ; } }
@brief  RDR_to_PC_NotifySlotChange
         Interrupt message to be sent to the host, Checks the card presence
         status and update the buffer accordingly
 @param  pdev: device instance
 @retval None
@brief RDR_to_PC_NotifySlotChange Interrupt message to be sent to the host Checks the card presence status and update the buffer accordingly @param pdev : device instance @retval None
/*
    SLOT_ICC_PRESENT 0x01 : LSb : (0b = no ICC present, 1b = ICC present)
    SLOT_ICC_CHANGE 0x02 : MSb : (0b = no change, 1b = change).
    */ /* Power OFF the card */