Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
cubexHal.pdf
Скачиваний:
110
Добавлен:
10.02.2016
Размер:
16.16 Mб
Скачать

HAL CEC Generic Driver

UM1725

7 HAL CEC Generic Driver

7.1CEC Firmware driver registers structures

7.1.1CEC_InitTypeDef

Data Fields

uint32_t SignalFreeTime

uint32_t Tolerance

uint32_t BRERxStop

uint32_t BREErrorBitGen

uint32_t LBPEErrorBitGen

uint32_t BroadcastMsgNoErrorBitGen

uint32_t SignalFreeTimeOption

uint32_t OwnAddress

uint32_t ListenMode

uint8_t InitiatorAddress

Field Documentation

uint32_t CEC_InitTypeDef::SignalFreeTime

Set SFT field, specifies the Signal Free Time. It can be one of CEC_Signal_Free_Time and belongs to the set {0,...,7} where 0x0 is the default configuration else means 0.5 + (SignalFreeTime - 1) nominal data bit periods

uint32_t CEC_InitTypeDef::Tolerance

Set RXTOL bit, specifies the tolerance accepted on the received waveforms, it can be a value of CEC_Tolerance : it is either CEC_STANDARD_TOLERANCE or CEC_EXTENDED_TOLERANCE

uint32_t CEC_InitTypeDef::BRERxStop

Set BRESTP bit CEC_BRERxStop : specifies whether or not a Bit Rising Error stops the reception. CEC_NO_RX_STOP_ON_BRE: reception is not stopped. CEC_RX_STOP_ON_BRE: reception is stopped.

uint32_t CEC_InitTypeDef::BREErrorBitGen

Set BREGEN bit CEC_BREErrorBitGen : specifies whether or not an Error-Bit is generated on the CEC line upon Bit Rising Error detection. CEC_BRE_ERRORBIT_NO_GENERATION: no error-bit generation. CEC_BRE_ERRORBIT_GENERATION: error-bit generation if BRESTP is set.

uint32_t CEC_InitTypeDef::LBPEErrorBitGen

Set LBPEGEN bit CEC_LBPEErrorBitGen : specifies whether or not an Error-Bit is generated on the CEC line upon Long Bit Period Error detection. CEC_LBPE_ERRORBIT_NO_GENERATION: no error-bit generation. CEC_LBPE_ERRORBIT_GENERATION: error-bit generation.

uint32_t CEC_InitTypeDef::BroadcastMsgNoErrorBitGen

Set BRDNOGEN bit CEC_BroadCastMsgErrorBitGen : allows to avoid an Error-Bit generation on the CEC line upon an error detected on a broadcast message.It supersedes BREGEN and LBPEGEN bits for a broadcast message error handling. It can take two values:1) CEC_BROADCASTERROR_ERRORBIT_GENERATION. a) BRE detection: error-bit generation on the CEC line if BRESTP=CEC_RX_STOP_ON_BRE and

146/900

DOCID025834 Rev 2

UM1725

HAL CEC Generic Driver

BREGEN=CEC_BRE_ERRORBIT_NO_GENERATION. b) LBPE detection: error-bit generation on the CEC line if LBPGEN=CEC_LBPE_ERRORBIT_NO_GENERATION.2) CEC_BROADCASTERROR_NO_ERRORBIT_GENERATION. no error-bit generation in case neither a) nor b) are satisfied. Additionally, there is no error-bit generation in case of Short Bit Period Error detection in a broadcast message while LSTN bit is set.

uint32_t CEC_InitTypeDef::SignalFreeTimeOption

Set SFTOP bit CEC_SFT_Option : specifies when SFT timer starts. CEC_SFT_START_ON_TXSOM SFT: timer starts when TXSOM is set by software. CEC_SFT_START_ON_TX_RX_END: SFT timer starts automatically at the end of message transmission/reception.

uint32_t CEC_InitTypeDef::OwnAddress

Set OAR field, specifies CEC device address within a 15-bit long field

uint32_t CEC_InitTypeDef::ListenMode

Set LSTN bit CEC_Listening_Mode : specifies device listening mode. It can take two values:CEC_REDUCED_LISTENING_MODE: CEC peripheral receives only message addressed to its own address (OAR). Messages addressed to different destination are ignored. Broadcast messages are always received.CEC_FULL_LISTENING_MODE:

CEC peripheral receives messages addressed to its own address (OAR) with positive acknowledge. Messages addressed to different destination are received, but without interfering with the CEC bus: no acknowledge sent.

uint8_t CEC_InitTypeDef::InitiatorAddress

7.1.2CEC_HandleTypeDef

Data Fields

CEC_TypeDef * Instance

CEC_InitTypeDef Init

uint8_t * pTxBuffPtr

uint16_t TxXferCount

uint8_t * pRxBuffPtr

uint16_t RxXferSize

uint32_t ErrorCode

HAL_LockTypeDef Lock

HAL_CEC_StateTypeDef State

Field Documentation

CEC_TypeDef* CEC_HandleTypeDef::Instance

CEC_InitTypeDef CEC_HandleTypeDef::Init

uint8_t* CEC_HandleTypeDef::pTxBuffPtr

uint16_t CEC_HandleTypeDef::TxXferCount

uint8_t* CEC_HandleTypeDef::pRxBuffPtr

uint16_t CEC_HandleTypeDef::RxXferSize

uint32_t CEC_HandleTypeDef::ErrorCode

HAL_LockTypeDef CEC_HandleTypeDef::Lock

HAL_CEC_StateTypeDef CEC_HandleTypeDef::State

DOCID025834 Rev 2

147/900

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]