RTEMS 6.1-rc5
|
Data Structures | |
struct | _dcic_config |
DCIC configuration. More... | |
struct | _dcic_region_config |
Region of interest (ROI) configuration. More... | |
Macros | |
#define | DCIC_REGION_COUNT DCIC_DCICRCS_COUNT |
#define | FSL_DCIC_DRIVER_VERSION (MAKE_VERSION(2, 0, 3)) |
DCIC driver version. | |
#define | DCIC_CRC32_POLYNOMIAL 0x04C11DB7UL |
CRC32 calculation polynomial. | |
#define | DCIC_CRC32_INIT_VALUE 0UL |
CRC32 calculation initialize value. | |
#define | DCIC_REGION_MISMATCH_STATUS(region) (1UL << (DCIC_DCICS_ROI_MATCH_STAT_SHIFT + (region))) |
ROI CRC32 value mismatch status. | |
Typedefs | |
typedef struct _dcic_config | dcic_config_t |
DCIC configuration. | |
typedef struct _dcic_region_config | dcic_region_config_t |
Region of interest (ROI) configuration. | |
Enumerations | |
enum | _DCIC_polarity_flags { kDCIC_VsyncActiveHigh = 0U , kDCIC_HsyncActiveHigh = 0U , kDCIC_DataEnableActiveHigh = 0U , kDCIC_DriveDataOnFallingClkEdge = 0U , kDCIC_VsyncActiveLow = DCIC_DCICC_VSYNC_POL_MASK , kDCIC_HsyncActiveLow = DCIC_DCICC_HSYNC_POL_MASK , kDCIC_DataEnableActiveLow = DCIC_DCICC_DE_POL_MASK , kDCIC_DriveDataOnRisingClkEdge = DCIC_DCICC_CLK_POL_MASK } |
DCIC display signal polarity flags . More... | |
enum | _DCIC_status_flags { kDCIC_FunctionalInterruptStatus = DCIC_DCICS_FI_STAT_MASK , kDCIC_ErrorInterruptStatus = DCIC_DCICS_EI_STAT_MASK , kDCIC_Region0MismatchStatus = DCIC_REGION_MISMATCH_STATUS(0U) , kDCIC_Region1MismatchStatus = DCIC_REGION_MISMATCH_STATUS(1U) , kDCIC_Region2MismatchStatus = DCIC_REGION_MISMATCH_STATUS(2U) , kDCIC_Region3MismatchStatus = DCIC_REGION_MISMATCH_STATUS(3U) , kDCIC_Region4MismatchStatus = DCIC_REGION_MISMATCH_STATUS(4U) , kDCIC_Region5MismatchStatus = DCIC_REGION_MISMATCH_STATUS(5U) , kDCIC_Region6MismatchStatus = DCIC_REGION_MISMATCH_STATUS(6U) , kDCIC_Region7MismatchStatus = DCIC_REGION_MISMATCH_STATUS(7U) , kDCIC_Region8MismatchStatus = DCIC_REGION_MISMATCH_STATUS(8U) , kDCIC_Region9MismatchStatus = DCIC_REGION_MISMATCH_STATUS(9U) , kDCIC_Region10MismatchStatus = DCIC_REGION_MISMATCH_STATUS(10U) , kDCIC_Region11MismatchStatus = DCIC_REGION_MISMATCH_STATUS(11U) , kDCIC_Region12MismatchStatus = DCIC_REGION_MISMATCH_STATUS(12U) , kDCIC_Region13MismatchStatus = DCIC_REGION_MISMATCH_STATUS(13U) , kDCIC_Region14MismatchStatus = DCIC_REGION_MISMATCH_STATUS(14U) , kDCIC_Region15MismatchStatus = DCIC_REGION_MISMATCH_STATUS(15U) } |
Status flags. . More... | |
enum | _dcic_interrupt_enable { kDCIC_FunctionalInterruptEnable = DCIC_DCICIC_FI_MASK_MASK , kDCIC_ErrorInterruptEnable = DCIC_DCICIC_EI_MASK_MASK } |
Interrupts. . More... | |
Variables | |
bool | _dcic_config::enableExternalSignal |
uint8_t | _dcic_config::polarityFlags |
uint32_t | _dcic_config::enableInterrupts |
bool | _dcic_region_config::lock |
uint16_t | _dcic_region_config::upperLeftX |
uint16_t | _dcic_region_config::upperLeftY |
uint16_t | _dcic_region_config::lowerRightX |
uint16_t | _dcic_region_config::lowerRightY |
uint32_t | _dcic_region_config::refCrc |
Initialization and deinitialization | |
void | DCIC_Init (DCIC_Type *base, const dcic_config_t *config) |
Initializes the DCIC. | |
void | DCIC_Deinit (DCIC_Type *base) |
Deinitialize the DCIC. | |
void | DCIC_GetDefaultConfig (dcic_config_t *config) |
Get the default configuration to initialize DCIC. | |
Region | |
void | DCIC_EnableRegion (DCIC_Type *base, uint8_t regionIdx, const dcic_region_config_t *config) |
Enable the region of interest (ROI) with configuration. | |
enum _DCIC_polarity_flags |
DCIC display signal polarity flags .
enum _DCIC_status_flags |
void DCIC_Deinit | ( | DCIC_Type * | base | ) |
Deinitialize the DCIC.
Disable the DCIC functions.
base | DCIC peripheral base address. |
void DCIC_EnableRegion | ( | DCIC_Type * | base, |
uint8_t | regionIdx, | ||
const dcic_region_config_t * | config | ||
) |
Enable the region of interest (ROI) with configuration.
Enable the ROI with configuration. To change the configuration except reference CRC value, the region should be disabled first by DCIC_DisableRegion, then call this function again. The reference CRC value could be changed by DCIC_SetRegionRefCrc without disabling the region. If the configuration is locked, only the reference CRC value could be changed, the region size and position, enable status could not be changed until reset.
base | DCIC peripheral base address. |
regionIdx | Region index, from 0 to (DCIC_REGION_COUNT - 1). |
config | Pointer to the configuration. |
void DCIC_GetDefaultConfig | ( | dcic_config_t * | config | ) |
Get the default configuration to initialize DCIC.
The default configuration is:
config | Pointer to the configuration. |
Get the default configuration to initialize DCIC.
The default configuration is:
config->polarityFlags = kDCIC_VsyncActiveLow | kDCIC_HsyncActiveLow | kDCIC_DataEnableActiveLow | kDCIC_DriveDataOnFallingClkEdge; config->enableExternalSignal = false; config->enableInterrupts = 0;
param config Pointer to the configuration.
void DCIC_Init | ( | DCIC_Type * | base, |
const dcic_config_t * | config | ||
) |
Initializes the DCIC.
This function resets DCIC registers to default value, then set the configurations. This function does not start the DCIC to work, application should call DCIC_DisableRegion to configure regions, then call DCIC_Enable to start the DCIC to work.
base | DCIC peripheral base address. |
config | Pointer to the configuration. |
bool _dcic_config::enableExternalSignal |
Enable the mismatch external signal. When enabled, the mismatch status could be monitored from the extern pin.
uint32_t _dcic_config::enableInterrupts |
Interrupts to enable, should be OR'ed of _dcic_interrupt_enable.
bool _dcic_region_config::lock |
Lock the region configuration except reference CRC32 value setting.
uint16_t _dcic_region_config::lowerRightX |
X of lower right corner. Range: 0 to 2^13-1.
uint16_t _dcic_region_config::lowerRightY |
Y of lower right corner. Range: 0 to 2^12-1.
uint8_t _dcic_config::polarityFlags |
Display signal polarity, logical OR'ed of _DCIC_polarity_flags.
uint32_t _dcic_region_config::refCrc |
Reference CRC32 value.
uint16_t _dcic_region_config::upperLeftX |
X of upper left corner. Range: 0 to 2^13-1.
uint16_t _dcic_region_config::upperLeftY |
Y of upper left corner. Range: 0 to 2^12-1.