![]() |
MCUXpresso SDK API Reference Manual
Rev. 0
NXP Semiconductors
|
The MCUXpresso SDK provides a Infra-Red Modulator driver for MCUXpresso SDK devices.
Files | |
file | fsl_cic_irb.h |
file | fsl_cic_irb_private.h |
Data Structures | |
struct | cic_irb_config_t |
struct | cic_irb_instance_data_t |
Enumerations | |
enum | cic_irb_protocols_t |
enum | cic_irb_status_t |
enum | cic_irb_carrier_frequency_t |
enum | cic_irb_sirc_version_t |
enum | cic_irb_rcmm_mode_t |
enum | cic_irb_rcmm_signal_free_time_t |
CIC_IRB Get Default Configuration | |
cic_irb_status_t | CIC_IRB_GetDefaultConfig (cic_irb_config_t *config) |
CIC_IRB_GetDefaultConfig. More... | |
CIC_IRB Initialization | |
cic_irb_status_t | CIC_IRB_Init (CIC_IRB_Type *base, cic_irb_config_t *config) |
CIC_IRB_Init. More... | |
CIC_IRB Enable | |
cic_irb_status_t | CIC_IRB_Enable (CIC_IRB_Type *base) |
CIC_IRB_Enable. More... | |
CIC_IRB Send RC5 Packet | |
cic_irb_status_t | CIC_IRB_SendRC5Packet (CIC_IRB_Type *base, bool toggle, uint8_t address, uint8_t command) |
CIC_IRB_SendRC5Packet. More... | |
CIC_IRB Send RC6 Packet | |
cic_irb_status_t | CIC_IRB_SendRC6Packet (CIC_IRB_Type *base, bool toggle, uint8_t field, uint8_t address, uint8_t command) |
CIC_IRB_SendRC6Packet. More... | |
CIC_IRB Send SIRC Packet | |
cic_irb_status_t | CIC_IRB_SendSIRCPacket (CIC_IRB_Type *base, cic_irb_sirc_version_t version, uint8_t command, uint8_t address, uint8_t extendedBits) |
CIC_IRB_SendSIRCPacket. More... | |
CIC_IRB Send RCMM Packet | |
cic_irb_status_t | CIC_IRB_SendRCMMPacket (CIC_IRB_Type *base, cic_irb_rcmm_mode_t mode, uint8_t modeBits, uint8_t address, uint8_t customerId, uint32_t data, cic_irb_rcmm_signal_free_time_t signalFreeTime) |
CIC_IRB_SendRCMMPacket. More... | |
CIC_IRB Is Busy | |
cic_irb_status_t | CIC_IRB_IsBusy (CIC_IRB_Type *base, bool *isBusy) |
CIC_IRB_IsBusy. More... | |
CIC_IRB Disable | |
cic_irb_status_t | CIC_IRB_Disable (CIC_IRB_Type *base) |
CIC_IRB_Disable. More... | |
CIC_IRB Deinitializations | |
cic_irb_status_t | CIC_IRB_DeInit (CIC_IRB_Type *base) |
CIC_IRB_DeInit. More... | |
CIC_IRB Get Instance Data | |
cic_irb_instance_data_t * | CIC_IRB_GetInstanceData (CIC_IRB_Type *base) |
CIC_IRB_GetInstanceData. More... | |
CIC_IRB RC5 Initialise | |
void | CIC_IRB_RC5Initialise (CIC_IRB_Type *base) |
CIC_IRB_RC5Initialise. More... | |
CIC_IRB RC6 Initialise | |
void | CIC_IRB_RC6Initialise (CIC_IRB_Type *base) |
CIC_IRB_RC6Initialise. More... | |
CIC_IRB SIRC Initialise | |
void | CIC_IRB_SIRCInitialise (CIC_IRB_Type *base) |
CIC_IRB_SIRCInitialise. More... | |
CIC_IRB RCMM Initialise | |
void | CIC_IRB_RCMMInitialise (CIC_IRB_Type *base) |
CIC_IRB_RCMMInitialise. More... | |
CIC_IRB RC5 Get Instance | |
uint8_t | CIC_IRB_GetInstance (CIC_IRB_Type *base) |
CIC_IRB_GetInstance. More... | |
CIC_IRB Load And Send Fifo | |
void | CIC_IRB_LoadAndSendFifo (CIC_IRB_Type *base) |
CIC_IRB_LoadAndSendFifo. More... | |
CIC_IRB RCx Append Envelopes | |
void | CIC_IRB_RCxAppendEnvelopes (uint32_t bitPattern, uint8_t bitCount, cic_irb_instance_data_t *instanceData, uint8_t *previousEnvelopeLevel, int8_t *envelope, bool ManchesterEncodingIEEE802_3) |
CIC_IRB_RCxAppendEnvelopes. More... | |
struct cic_irb_config_t |
CIC IRB configuration structure
This structure holds the configuration settings for the CIC IRB peripheral. To initialize this structure to reasonable defaults, call the CIC_IRB_GetDefaultConfig() function and pass a pointer to the configuration structure instance.
struct cic_irb_instance_data_t |
CIC IRB instance data structure
enum cic_irb_protocols_t |
IR protocol types
enum cic_irb_status_t |
Status code responses from API calls
Status code responses from API calls
Sony SIRC version types
enum cic_irb_rcmm_mode_t |
RC-MM mode types
RC-MM signal free types
cic_irb_status_t CIC_IRB_GetDefaultConfig | ( | cic_irb_config_t * | config | ) |
This function get default configuration for IRB
config | pointer to a configuration structure |
cic_irb_status_t CIC_IRB_Init | ( | CIC_IRB_Type * | base, |
cic_irb_config_t * | config | ||
) |
Initialize the IRB peripheral. Attaches, configures and enables source and peripheral clocks, resets peripheral and initializes instance data. The peripheral is not enabled after this.
base | CIC_IRB peripheral base address |
config | pointer to a configuration structure |
cic_irb_status_t CIC_IRB_Enable | ( | CIC_IRB_Type * | base | ) |
Enable the IRB peripheral doing protocol specific initializations. The interrupts are enabled after this call.
base | CIC_IRB peripheral base address |
cic_irb_status_t CIC_IRB_SendRC5Packet | ( | CIC_IRB_Type * | base, |
bool | toggle, | ||
uint8_t | address, | ||
uint8_t | command | ||
) |
Send a RC-5 packet via the IRB peripheral. The peripheral instance must have been initialised and enabled and not busy.
base | CIC_IRB peripheral base address |
toggle | the state of the toggle bit to encode |
address | the 5 bit address to go into the message |
command | the 7 bit command to go into the message |
cic_irb_status_t CIC_IRB_SendRC6Packet | ( | CIC_IRB_Type * | base, |
bool | toggle, | ||
uint8_t | field, | ||
uint8_t | address, | ||
uint8_t | command | ||
) |
Send a RC-5 packet via the IRB peripheral. The peripheral instance must have been initialised and enabled and not busy.
base | CIC_IRB peripheral base address |
toggle | the state of the toggle bit to encode |
field | the 3 bit field to go into the message |
address | the 8 bit address to go into the message |
command | the 8 bit command to go into the message |
cic_irb_status_t CIC_IRB_SendSIRCPacket | ( | CIC_IRB_Type * | base, |
cic_irb_sirc_version_t | version, | ||
uint8_t | command, | ||
uint8_t | address, | ||
uint8_t | extendedBits | ||
) |
Send a SIRC packet via the IRB peripheral. The peripheral instance must have been initialised and enabled and not busy.
base | CIC_IRB peripheral base address |
version | the version of the protocol to use, varies the packet length command the 7 bit command to go into the message |
address | the 5 or 8 bit address to go into the message |
extendedBits | 8 bits of extra data in 20 bit message |
cic_irb_status_t CIC_IRB_SendRCMMPacket | ( | CIC_IRB_Type * | base, |
cic_irb_rcmm_mode_t | mode, | ||
uint8_t | modeBits, | ||
uint8_t | address, | ||
uint8_t | customerId, | ||
uint32_t | data, | ||
cic_irb_rcmm_signal_free_time_t | signalFreeTime | ||
) |
Send a RCMM packet via the IRB peripheral. The peripheral instance must have been initialised and enabled and not busy.
base | CIC_IRB peripheral base address The RC-MM message mode. See RC-MM documentation Bits The mode numerical value, varying number of bits |
address | RC-MM address data field in some modes |
customerId | RC-MM customer if in some modes |
data | the RC-MM data field, varying length depending on mode |
signalFreeTime | Silent period after packet transmission |
cic_irb_status_t CIC_IRB_IsBusy | ( | CIC_IRB_Type * | base, |
bool * | isBusy | ||
) |
Determine if the IRB peripheral instance is in the process of sending the previous message.
base | CIC_IRB peripheral base address |
isBusy | pointer to bool for result |
cic_irb_status_t CIC_IRB_Disable | ( | CIC_IRB_Type * | base | ) |
Disable the IRB peripheral such that it can be enabled again without doing another init. This stops interrupts and any part sent message is abandoned.
base | CIC_IRB peripheral base address |
cic_irb_status_t CIC_IRB_DeInit | ( | CIC_IRB_Type * | base | ) |
De-initialises the IRB peripheral instance. The clock is stopped.
base | CIC_IRB peripheral base address |
cic_irb_instance_data_t* CIC_IRB_GetInstanceData | ( | CIC_IRB_Type * | base | ) |
Get a pointer to the data structure containing context information for a peripheral instance
base | CIC_IRB peripheral base address. |
NOTES: Returns NULL if an instance not found for base
void CIC_IRB_RC5Initialise | ( | CIC_IRB_Type * | base | ) |
Initialise the peripheral ready to send RC5 messages.
base | CIC_IRB peripheral base address. |
void CIC_IRB_RC6Initialise | ( | CIC_IRB_Type * | base | ) |
Initialise the peripheral ready to send RC6 messages.
base | CIC_IRB peripheral base address. |
void CIC_IRB_SIRCInitialise | ( | CIC_IRB_Type * | base | ) |
Initialise the peripheral ready to send SIRC messages.
base | CIC_IRB peripheral base address. |
void CIC_IRB_RCMMInitialise | ( | CIC_IRB_Type * | base | ) |
Initialise the peripheral ready to send RCMM messages.
base | CIC_IRB peripheral base address. |
uint8_t CIC_IRB_GetInstance | ( | CIC_IRB_Type * | base | ) |
Get the CIC_IRB instance from peripheral base address.
base | CIC_IRB peripheral base address. |
NOTES: Returns FSL_FEATURE_SOC_CIC_IRB_COUNT if instance for base not found.
void CIC_IRB_LoadAndSendFifo | ( | CIC_IRB_Type * | base | ) |
Load the FIFO with the first part of a series of envelopes to send. If a message's complete set of envelopes fits within the FIFO size then the whole message will be sent. If not then the maximum number of envelopes is loaded into the FIFO that is possible. Subsequent FIFO loads for the remaining envelopes are loaded into the FIFO in the interrupt handler which is triggered when the FIFO becomes empty.
base | CIC_IRB peripheral base address. |
void CIC_IRB_RCxAppendEnvelopes | ( | uint32_t | bitPattern, |
uint8_t | bitCount, | ||
cic_irb_instance_data_t * | instanceData, | ||
uint8_t * | previousEnvelopeLevel, | ||
int8_t * | envelope, | ||
bool | ManchesterEncodingIEEE802_3 | ||
) |
Take a bit pattern that comprises part of a RCx message and encode this in envelopes using the appropriate type of Manchester encoding. The envelopes can be appended to an array of previously encoded envelopes or can be a complete message.
bitPattern | the binary data to encode into the message |
bitCount | the number of bits in bitPattern |
instanceData | pointer to the peripheral instance data structure |
previousEnvelopeLevel | the level of the last envelope of the preceding part of the encoded message |
envelope | pointer to array to add this bit pattern's encoded envelopes |
ManchesterEncodingIEEE802_3 | type of Manchester encoding, true for IEEE 802.3, false for Thomas |