RTEMS 6.1-rc4
|
Data Structures | |
struct | _elcdif_pixel_format_reg |
The register value when using different pixel format. More... | |
struct | _elcdif_rgb_mode_config |
eLCDIF configure structure for RGB mode (DOTCLK mode). More... | |
struct | _elcdif_as_buffer_config |
eLCDIF alpha surface buffer configuration. More... | |
struct | _elcdif_as_blend_config |
eLCDIF alpha surface blending configuration. More... | |
Driver version | |
enum | _elcdif_polarity_flags { kELCDIF_VsyncActiveLow = 0U , kELCDIF_HsyncActiveLow = 0U , kELCDIF_DataEnableActiveLow = 0U , kELCDIF_DriveDataOnFallingClkEdge = 0U , kELCDIF_VsyncActiveHigh = LCDIF_VDCTRL0_VSYNC_POL_MASK , kELCDIF_HsyncActiveHigh = LCDIF_VDCTRL0_HSYNC_POL_MASK , kELCDIF_DataEnableActiveHigh = LCDIF_VDCTRL0_ENABLE_POL_MASK , kELCDIF_DriveDataOnRisingClkEdge = LCDIF_VDCTRL0_DOTCLK_POL_MASK } |
eLCDIF signal polarity flags More... | |
enum | _elcdif_interrupt_enable { kELCDIF_BusMasterErrorInterruptEnable = LCDIF_CTRL1_BM_ERROR_IRQ_EN_MASK , kELCDIF_TxFifoOverflowInterruptEnable = LCDIF_CTRL1_OVERFLOW_IRQ_EN_MASK , kELCDIF_TxFifoUnderflowInterruptEnable = LCDIF_CTRL1_UNDERFLOW_IRQ_EN_MASK , kELCDIF_CurFrameDoneInterruptEnable , kELCDIF_VsyncEdgeInterruptEnable } |
The eLCDIF interrupts to enable. More... | |
enum | _elcdif_interrupt_flags { kELCDIF_BusMasterError = LCDIF_CTRL1_BM_ERROR_IRQ_MASK , kELCDIF_TxFifoOverflow = LCDIF_CTRL1_OVERFLOW_IRQ_MASK , kELCDIF_TxFifoUnderflow = LCDIF_CTRL1_UNDERFLOW_IRQ_MASK , kELCDIF_CurFrameDone , kELCDIF_VsyncEdge = LCDIF_CTRL1_VSYNC_EDGE_IRQ_MASK } |
The eLCDIF interrupt status flags. More... | |
enum | _elcdif_status_flags { kELCDIF_LFifoFull = LCDIF_STAT_LFIFO_FULL_MASK , kELCDIF_LFifoEmpty = LCDIF_STAT_LFIFO_EMPTY_MASK , kELCDIF_TxFifoFull = LCDIF_STAT_TXFIFO_FULL_MASK , kELCDIF_TxFifoEmpty = LCDIF_STAT_TXFIFO_EMPTY_MASK } |
eLCDIF status flags More... | |
enum | _elcdif_pixel_format { kELCDIF_PixelFormatRAW8 = 0 , kELCDIF_PixelFormatRGB565 = 1 , kELCDIF_PixelFormatRGB666 = 2 , kELCDIF_PixelFormatXRGB8888 = 3 , kELCDIF_PixelFormatRGB888 = 4 } |
The pixel format. More... | |
enum | _elcdif_lcd_data_bus { kELCDIF_DataBus8Bit = LCDIF_CTRL_LCD_DATABUS_WIDTH(1) , kELCDIF_DataBus16Bit = LCDIF_CTRL_LCD_DATABUS_WIDTH(0) , kELCDIF_DataBus18Bit = LCDIF_CTRL_LCD_DATABUS_WIDTH(2) , kELCDIF_DataBus24Bit = LCDIF_CTRL_LCD_DATABUS_WIDTH(3) } |
The LCD data bus type. More... | |
enum | _elcdif_as_pixel_format { kELCDIF_AsPixelFormatARGB8888 = 0x0 , kELCDIF_AsPixelFormatRGB888 = 0x4 , kELCDIF_AsPixelFormatARGB1555 = 0x8 , kELCDIF_AsPixelFormatARGB4444 = 0x9 , kELCDIF_AsPixelFormatRGB555 = 0xC , kELCDIF_AsPixelFormatRGB444 = 0xD , kELCDIF_AsPixelFormatRGB565 = 0xE } |
eLCDIF alpha surface pixel format. More... | |
enum | _elcdif_alpha_mode { kELCDIF_AlphaEmbedded , kELCDIF_AlphaOverride , kELCDIF_AlphaMultiply , kELCDIF_AlphaRop } |
eLCDIF alpha mode during blending. More... | |
enum | _elcdif_rop_mode { kELCDIF_RopMaskAs = 0x0 , kELCDIF_RopMaskNotAs = 0x1 , kELCDIF_RopMaskAsNot = 0x2 , kELCDIF_RopMergeAs = 0x3 , kELCDIF_RopMergeNotAs = 0x4 , kELCDIF_RopMergeAsNot = 0x5 , kELCDIF_RopNotCopyAs = 0x6 , kELCDIF_RopNot = 0x7 , kELCDIF_RopNotMaskAs = 0x8 , kELCDIF_RopNotMergeAs = 0x9 , kELCDIF_RopXorAs = 0xA , kELCDIF_RopNotXorAs = 0xB } |
eLCDIF ROP mode during blending. More... | |
enum | _elcdif_lut { kELCDIF_Lut0 = 0 , kELCDIF_Lut1 } |
eLCDIF LUT More... | |
typedef enum _elcdif_pixel_format | elcdif_pixel_format_t |
The pixel format. | |
typedef enum _elcdif_lcd_data_bus | elcdif_lcd_data_bus_t |
The LCD data bus type. | |
typedef struct _elcdif_pixel_format_reg | elcdif_pixel_format_reg_t |
The register value when using different pixel format. | |
typedef struct _elcdif_rgb_mode_config | elcdif_rgb_mode_config_t |
eLCDIF configure structure for RGB mode (DOTCLK mode). | |
typedef enum _elcdif_as_pixel_format | elcdif_as_pixel_format_t |
eLCDIF alpha surface pixel format. | |
typedef struct _elcdif_as_buffer_config | elcdif_as_buffer_config_t |
eLCDIF alpha surface buffer configuration. | |
typedef enum _elcdif_alpha_mode | elcdif_alpha_mode_t |
eLCDIF alpha mode during blending. | |
typedef enum _elcdif_rop_mode | elcdif_rop_mode_t |
eLCDIF ROP mode during blending. | |
typedef struct _elcdif_as_blend_config | elcdif_as_blend_config_t |
eLCDIF alpha surface blending configuration. | |
typedef enum _elcdif_lut | elcdif_lut_t |
eLCDIF LUT | |
#define | FSL_ELCDIF_DRIVER_VERSION (MAKE_VERSION(2, 0, 5)) |
eLCDIF driver version | |
#define | ELCDIF_CTRL1_IRQ_MASK |
#define | ELCDIF_CTRL1_IRQ_EN_MASK |
#define | ELCDIF_AS_CTRL_IRQ_MASK 0U |
#define | ELCDIF_AS_CTRL_IRQ_EN_MASK 0U |
#define | FSL_FEATURE_LCDIF_HAS_PXP_HANDSHAKE 0 |
#define | ELCDIF_ADDR_CPU_2_IP(addr) (addr) |
#define | ELCDIF_LUT_ENTRY_NUM 256U |
eLCDIF initialization and de-initialization | |
void | ELCDIF_RgbModeInit (LCDIF_Type *base, const elcdif_rgb_mode_config_t *config) |
Initializes the eLCDIF to work in RGB mode (DOTCLK mode). | |
void | ELCDIF_RgbModeGetDefaultConfig (elcdif_rgb_mode_config_t *config) |
Gets the eLCDIF default configuration structure for RGB (DOTCLK) mode. | |
void | ELCDIF_Deinit (LCDIF_Type *base) |
Deinitializes the eLCDIF peripheral. | |
Module operation | |
void | ELCDIF_RgbModeSetPixelFormat (LCDIF_Type *base, elcdif_pixel_format_t pixelFormat) |
Set the pixel format in RGB (DOTCLK) mode. | |
void | ELCDIF_RgbModeStop (LCDIF_Type *base) |
Stop display in RGB (DOTCLK) mode and wait until finished. | |
void | ELCDIF_Reset (LCDIF_Type *base) |
Reset the eLCDIF peripheral. | |
Alpha surface | |
void | ELCDIF_SetAlphaSurfaceBufferConfig (LCDIF_Type *base, const elcdif_as_buffer_config_t *config) |
Set the configuration for alpha surface buffer. | |
void | ELCDIF_SetAlphaSurfaceBlendConfig (LCDIF_Type *base, const elcdif_as_blend_config_t *config) |
Set the alpha surface blending configuration. | |
#define ELCDIF_CTRL1_IRQ_EN_MASK |
#define ELCDIF_CTRL1_IRQ_MASK |
typedef enum _elcdif_lut elcdif_lut_t |
eLCDIF LUT
The Lookup Table (LUT) is used to expand the 8 bits pixel to 24 bits pixel before output to external displayer.
There are two 256x24 bits LUT memory in LCDIF, the LSB of frame buffer address determins which memory to use.
typedef struct _elcdif_pixel_format_reg elcdif_pixel_format_reg_t |
The register value when using different pixel format.
These register bits control the pixel format:
typedef enum _elcdif_pixel_format elcdif_pixel_format_t |
The pixel format.
This enumerator should be defined together with the array s_pixelFormatReg. To support new pixel format, enhance this enumerator and s_pixelFormatReg.
typedef enum _elcdif_rop_mode elcdif_rop_mode_t |
eLCDIF ROP mode during blending.
Explanation:
enum _elcdif_alpha_mode |
eLCDIF alpha mode during blending.
eLCDIF alpha surface pixel format.
The eLCDIF interrupts to enable.
The eLCDIF interrupt status flags.
enum _elcdif_lcd_data_bus |
enum _elcdif_lut |
enum _elcdif_pixel_format |
The pixel format.
This enumerator should be defined together with the array s_pixelFormatReg. To support new pixel format, enhance this enumerator and s_pixelFormatReg.
eLCDIF signal polarity flags
enum _elcdif_rop_mode |
eLCDIF ROP mode during blending.
Explanation:
enum _elcdif_status_flags |
void ELCDIF_Deinit | ( | LCDIF_Type * | base | ) |
Deinitializes the eLCDIF peripheral.
base | eLCDIF peripheral base address. |
brief Deinitializes the eLCDIF peripheral.
param base eLCDIF peripheral base address.
void ELCDIF_Reset | ( | LCDIF_Type * | base | ) |
Reset the eLCDIF peripheral.
base | eLCDIF peripheral base address. |
brief Reset the eLCDIF peripheral.
param base eLCDIF peripheral base address.
void ELCDIF_RgbModeGetDefaultConfig | ( | elcdif_rgb_mode_config_t * | config | ) |
Gets the eLCDIF default configuration structure for RGB (DOTCLK) mode.
This function sets the configuration structure to default values. The default configuration is set to the following values.
config | Pointer to the eLCDIF configuration structure. |
brief Gets the eLCDIF default configuration structure for RGB (DOTCLK) mode.
This function sets the configuration structure to default values. The default configuration is set to the following values. code config->panelWidth = 480U; config->panelHeight = 272U; config->hsw = 41; config->hfp = 4; config->hbp = 8; config->vsw = 10; config->vfp = 4; config->vbp = 2; config->polarityFlags = kELCDIF_VsyncActiveLow | kELCDIF_HsyncActiveLow | kELCDIF_DataEnableActiveLow | kELCDIF_DriveDataOnFallingClkEdge; config->bufferAddr = 0U; config->pixelFormat = kELCDIF_PixelFormatRGB888; config->dataBus = kELCDIF_DataBus24Bit; code
param config Pointer to the eLCDIF configuration structure.
void ELCDIF_RgbModeInit | ( | LCDIF_Type * | base, |
const elcdif_rgb_mode_config_t * | config | ||
) |
Initializes the eLCDIF to work in RGB mode (DOTCLK mode).
This function ungates the eLCDIF clock and configures the eLCDIF peripheral according to the configuration structure.
base | eLCDIF peripheral base address. |
config | Pointer to the configuration structure. |
brief Initializes the eLCDIF to work in RGB mode (DOTCLK mode).
This function ungates the eLCDIF clock and configures the eLCDIF peripheral according to the configuration structure.
param base eLCDIF peripheral base address. param config Pointer to the configuration structure.
void ELCDIF_RgbModeSetPixelFormat | ( | LCDIF_Type * | base, |
elcdif_pixel_format_t | pixelFormat | ||
) |
Set the pixel format in RGB (DOTCLK) mode.
base | eLCDIF peripheral base address. |
pixelFormat | The pixel format. |
brief Set the pixel format in RGB (DOTCLK) mode.
param base eLCDIF peripheral base address. param pixelFormat The pixel format.
void ELCDIF_RgbModeStop | ( | LCDIF_Type * | base | ) |
Stop display in RGB (DOTCLK) mode and wait until finished.
base | eLCDIF peripheral base address. |
brief Stop display in RGB (DOTCLK) mode and wait until finished.
param base eLCDIF peripheral base address.
void ELCDIF_SetAlphaSurfaceBlendConfig | ( | LCDIF_Type * | base, |
const elcdif_as_blend_config_t * | config | ||
) |
Set the alpha surface blending configuration.
base | eLCDIF peripheral base address. |
config | Pointer to the configuration structure. |
brief Set the alpha surface blending configuration.
param base eLCDIF peripheral base address. param config Pointer to the configuration structure.
void ELCDIF_SetAlphaSurfaceBufferConfig | ( | LCDIF_Type * | base, |
const elcdif_as_buffer_config_t * | config | ||
) |
Set the configuration for alpha surface buffer.
base | eLCDIF peripheral base address. |
config | Pointer to the configuration structure. |
brief Set the configuration for alpha surface buffer.
param base eLCDIF peripheral base address. param config Pointer to the configuration structure.
uint8_t _elcdif_as_blend_config::alpha |
User defined alpha value, only used when alphaMode is kELCDIF_AlphaOverride or kELCDIF_AlphaRop.
elcdif_alpha_mode_t _elcdif_as_blend_config::alphaMode |
Alpha mode.
uint32_t _elcdif_rgb_mode_config::bufferAddr |
Frame buffer address.
uint32_t _elcdif_as_buffer_config::bufferAddr |
Buffer address.
elcdif_lcd_data_bus_t _elcdif_rgb_mode_config::dataBus |
LCD data bus.
uint8_t _elcdif_rgb_mode_config::hbp |
Horizontal back porch.
uint8_t _elcdif_rgb_mode_config::hfp |
Horizontal front porch.
uint8_t _elcdif_rgb_mode_config::hsw |
HSYNC pulse width.
bool _elcdif_as_blend_config::invertAlpha |
Set true to invert the alpha.
uint16_t _elcdif_rgb_mode_config::panelHeight |
Display panel height, how many lines per panel.
uint16_t _elcdif_rgb_mode_config::panelWidth |
Display panel width, pixels per line.
elcdif_pixel_format_t _elcdif_rgb_mode_config::pixelFormat |
Pixel format.
elcdif_as_pixel_format_t _elcdif_as_buffer_config::pixelFormat |
Pixel format.
uint32_t _elcdif_rgb_mode_config::polarityFlags |
OR'ed value of _elcdif_polarity_flags, used to contol the signal polarity.
uint32_t _elcdif_pixel_format_reg::regCtrl |
Value of register CTRL.
uint32_t _elcdif_pixel_format_reg::regCtrl1 |
Value of register CTRL1.
elcdif_rop_mode_t _elcdif_as_blend_config::ropMode |
ROP mode, only valid when alphaMode is kELCDIF_AlphaRop.
uint8_t _elcdif_rgb_mode_config::vbp |
Vertical back porch.
uint8_t _elcdif_rgb_mode_config::vfp |
Vrtical front porch.
uint8_t _elcdif_rgb_mode_config::vsw |
VSYNC pulse width.