lv_ft81x.h

Typedefs

typedef void (*lv_ft81x_spi_cb_t)(lv_display_t *disp, lv_ft81x_spi_operation_t operation, void *data, uint32_t length)

Enums

enum lv_ft81x_spi_operation_t

Values:

enumerator LV_FT81X_SPI_OPERATION_CS_ASSERT
enumerator LV_FT81X_SPI_OPERATION_CS_DEASSERT
enumerator LV_FT81X_SPI_OPERATION_SEND
enumerator LV_FT81X_SPI_OPERATION_RECEIVE

Functions

lv_display_t *lv_ft81x_create(const lv_ft81x_parameters_t *params, void *partial_buf, uint32_t buf_size, lv_ft81x_spi_cb_t spi_cb, void *user_data)

Create a framebuffer-based ft81x driver display.

Parameters:
  • params – pointer to a struct of display panel properties. does not need to be static.

  • partial_buf – a single partial buffer

  • buf_size – size of the partial buffer

  • spi_cb – a callback called by the driver to perform SPI operations

  • user_data – use lv_ft81x_get_user_data to get this pointer inside the SPI callback

Returns:

pointer to the display

void *lv_ft81x_get_user_data(lv_display_t *disp)

Get the user_data parameter that was passed to lv_ft81x_create. Useful in the SPI callback.

Parameters:

disp – pointer to the ft81x display

Returns:

the user_data pointer

struct lv_ft81x_parameters_t

Public Members

uint16_t hor_res

active display width

uint16_t ver_res

active display height

uint16_t hcycle

total number of clocks per line, incl front/back porch

uint16_t hoffset

start of active line

uint16_t hsync0

start of horizontal sync pulse

uint16_t hsync1

end of horizontal sync pulse

uint16_t vcycle

total number of lines per screen, including pre/post

uint16_t voffset

start of active screen

uint16_t vsync0

start of vertical sync pulse

uint16_t vsync1

end of vertical sync pulse

uint8_t swizzle

FT8xx output to LCD - pin order

uint8_t pclkpol

LCD data is clocked in on this PCLK edge

uint8_t cspread

helps with noise, when set to 1 fewer signals are changed simultaneously, reset-default: 1

uint8_t pclk

60MHz / pclk = pclk frequency

bool has_crystal

has an external clock crystal

bool is_bt81x

is a BT series model, not FT