50 #define DIRECT_CONV_DATA 0x3B 51 #define INVERSE_CONV_DATA 0x3F 54 #define SCn_CR1_CONTROL_BITMASK 0x0000ffffuL 55 #define SCn_CR2_CONTROL_BITMASK 0x0000ffffuL 56 #define SCn_CR3_CONTROL_BITMASK 0x00ffffffuL 62 #define SCn_BLOCKING_TIMEOUT 0xffffuL // (0xFFFFFFFFuL) 68 #define SCn_IFSR_RSTA ((uint32_t)(1 << 23)) 69 #define SCn_IFSR_SER ((uint32_t)(1 << 22)) 70 #define SCn_IFSR_SED ((uint32_t)(1 << 21)) 71 #define SCn_IFSR_CONER ((uint32_t)(1 << 20)) 72 #define SCn_IFSR_CONED ((uint32_t)(1 << 19)) 73 #define SCn_IFSR_TRYER ((uint32_t)(1 << 18)) 74 #define SCn_IFSR_SCIN ((uint32_t)(1 << 17)) 75 #define SCn_IFSR_BLED ((uint32_t)(1 << 16)) 76 #define SCn_IFSR_DOR ((uint32_t)(1 << 15)) 77 #define SCn_IFSR_FE ((uint32_t)(1 << 14)) 78 #define SCn_IFSR_PE ((uint32_t)(1 << 13)) 79 #define SCn_IFSR_RXBUSY ((uint32_t)(1 << 12)) 80 #define SCn_IFSR_RTO ((uint32_t)(1 << 6)) 81 #define SCn_IFSR_TXC ((uint32_t)(1 << 2)) 82 #define SCn_IFSR_RXC ((uint32_t)(1 << 0)) 83 #define SCn_IFSR_BITMASK ((uint32_t)(0x00FFFFFF)) 85 //******************************************************************************
uint8_t HAL_SC_GetSCnINST(SCn_Type *SCx)
Get the SCnIN Pin Status.
HAL_Status_Type HAL_SC_DeInit(SCn_Type *SCx)
Deinitialize the SCn peripheral registers to their default reset values.
HAL_Status_Type HAL_SC_SetT34DR(SCn_Type *SCx, uint32_t SCnT3data, uint32_t SCnT4data)
SCn T3DR and T4DR Registers Set.
SCn_DATA_BIT_Type Databits
Contains the ABOV typedefs for C standard types. It is intended to be used in ISO C conforming develo...
HAL_Status_Type HAL_SC_SetExGuardTime(SCn_Type *SCx, uint32_t TxExGuardTime)
SCn Transmit Extra Guard Time Register Set.
HAL_Status_Type HAL_SC_AutoConvDet(SCn_Type *SCx)
SCn Auto Convention Detection.
HAL_Status_Type HAL_SC_Init(SCn_Type *SCx, SCn_CFG_Type *SCn_Config)
Initialize the SCn peripheral with the specified parameters.
FlagStatus HAL_SC_CheckBusy(SCn_Type *SCx)
Check whether if SCn is busy or not.
HAL_Status_Type HAL_SC_TransmitByte(SCn_Type *SCx, uint8_t Data)
Transmit a single data through SCn peripheral.
HAL_Status_Type HAL_SC_AutoAct(SCn_Type *SCx)
SCn Auto Activation and Cold Reset.
SCn_OVR_SAMP_Type Oversampling
HAL_Status_Type HAL_SC_SetInPol(SCn_Type *SCx, SCn_INPUT_POLARITY_Type In_pol)
SCn Input Pin Polarity Set.
HAL_Status_Type HAL_SC_AutoWarmRst(SCn_Type *SCx)
SCn Auto Warm Reset.
uint32_t Extra_guard_time
HAL_Status_Type HAL_SC_SetRxBlkLen(SCn_Type *SCx, uint8_t blk_len)
SCn Rx block length set with the specified parameters.
HAL_Status_Type HAL_SC_SetRxTimeOutData(SCn_Type *SCx, uint32_t RxTimeOutD)
SCn Receive Time Out Data Register Set.
HAL_Status_Type HAL_SC_ConfigStructInit(SCn_CFG_Type *SCn_Config, SCn_OPMODE_Type mode, uint32_t Baudrate)
Fills each SCn_Config member with its default value:
HAL_Status_Type HAL_SC_Enable(SCn_Type *SCx, FunctionalState state)
SCn enable control.
HAL_Status_Type HAL_SC_SetLevel(SCn_Type *SCx, SCn_CR2_LEVEL_POS SelectPin, SetState SetLevel)
Set Level for SCn peripheral when Smartcard Interface Mode.
HAL_Status_Type HAL_SC_ConfigRetry(SCn_Type *SCx, uint8_t retry_num, SCn_DTIME_Type retry_dly)
SCn Retry Configuration with the specified parameters.
uint32_t Baud_rate_Compensation
HAL_Status_Type HAL_SC_ClearStatus(SCn_Type *SCx, SCn_STATUS_Type Status)
Clear Status register in SCn peripheral.
uint32_t HAL_SC_GetStatus(SCn_Type *SCx)
Get current value of Status register in SCn peripheral.
HAL_Status_Type HAL_SC_AutoDeAct(SCn_Type *SCx)
SCn Auto Deactivation.
uint32_t HAL_SC_Receive(SCn_Type *SCx, uint8_t *rxbuf, uint32_t buflen, TRANSFER_BLOCK_Type flag)
Receive a block of data via SCn peripheral.
SCn_STOP_BIT_Type Stopbits
uint8_t HAL_SC_GetRxLineBusy(SCn_Type *SCx)
Get the Rx Line Busy bit.
HAL_Status_Type HAL_SC_ControlConfig(SCn_Type *SCx, SCn_CR1_CONTROL_Type Mode, FunctionalState NewState)
Configure Control mode for SCn peripheral.
HAL_Status_Type HAL_SC_RxCntEnable(SCn_Type *SCx, SCn_RXCNT_EN_DISABLE RxCnt_en)
SCn Receive Byte Count Enable.
HAL_Status_Type HAL_SC_ConfigInterrupt(SCn_Type *SCx, SCn_INT_Type SCn_IntCfg, FunctionalState NewState)
Configure the interrupt source of selected SCn peripheral.
HAL_Status_Type HAL_SC_RetryEnable(SCn_Type *SCx, SCn_RETRY_EN_DISABLE retry_en)
SCn Retry Enable.
uint32_t HAL_SC_Transmit(SCn_Type *SCx, uint8_t *txbuf, uint32_t buflen, TRANSFER_BLOCK_Type flag)
Send a block of data via SCn peripheral.
SCn_PARITY_BIT_Type Parity
uint8_t HAL_SC_ReceiveByte(SCn_Type *SCx)
Receive a single data from SCn peripheral.
SCn_PARITY_EN_DISABLE ParityEnDis
HAL_Status_Type HAL_SC_SetConv(SCn_Type *SCx, SCn_CONV_Type conv_sel)
SCn Convention Selection.