10 static const char *
const TAG =
"ili9341";
30 LOG_DISPLAY(
"",
"ili9341",
this);
33 LOG_PIN(
" DC Pin: ", this->
dc_pin_);
35 LOG_PIN(
" Backlight Pin: ", this->
led_pin_);
36 LOG_UPDATE_INTERVAL(
this);
69 uint8_t
data = 0x10 + index;
94 uint32_t start_pos = ((this->y_low_ * this->
width_) + x_low_);
95 for (uint16_t row = 0; row <
h; row++) {
96 uint32_t pos = start_pos + (row *
width_);
109 this->x_low_ = this->
width_;
132 *dst++ = (uint8_t)(color565 >> 8);
133 *dst++ = (uint8_t) color565;
163 uint32_t pos = (y *
width_) + x;
190 uint8_t
cmd, x, num_args;
191 const uint8_t *addr = init_cmd;
203 uint16_t x2 = (x1 + w - 1), y2 = (y1 + h - 1);
234 for (uint32_t i = 0; i < sz; ++i) {
242 *dst++ = (uint8_t)(color >> 8);
243 *dst++ = (uint8_t) color;
virtual void digital_write(bool value)=0
void init_lcd_(const uint8_t *init_cmd)
static uint16_t color_to_565(Color color, ColorOrder color_order=ColorOrder::COLOR_ORDER_RGB)
void invert_display_(bool invert)
int get_height_internal() override
void send_command(uint8_t command_byte, const uint8_t *data_bytes, uint8_t num_data_bytes)
void write_byte(uint8_t data)
void initialize() override
void init_internal_(uint32_t buffer_length)
void fill(Color color) override
void set_addr_window_(uint16_t x, uint16_t y, uint16_t w, uint16_t h)
void initialize() override
static uint8_t color_to_332(Color color, ColorOrder color_order=ColorOrder::COLOR_ORDER_RGB)
int16_t width_
Display width as modified by current rotation.
static Color index8_to_color_palette888(uint8_t index, const uint8_t *palette)
void draw_absolute_pixel_internal(int x, int y, Color color) override
uint32_t buffer_to_transfer_(uint32_t pos, uint32_t sz)
DisplayRotation rotation_
const float PROCESSOR
For components that use data from sensors like displays.
uint8_t progmem_read_byte(const uint8_t *addr)
ILI9341ColorMode buffer_color_mode_
void dump_config() override
int get_width_internal() override
static uint8_t color_to_index8_palette888(Color color, const uint8_t *palette)
void write_array(const uint8_t *data, size_t length)
uint8_t read_command(uint8_t command_byte, uint8_t index)
float get_setup_priority() const override
int16_t height_
Display height as modified by current rotation.
void command(uint8_t value)
uint8_t transfer_buffer_[64]
static Color rgb332_to_color(uint8_t rgb332_color)
uint32_t get_buffer_length_()
void initialize() override
void fill_internal_(Color color)
void IRAM_ATTR HOT delay(uint32_t ms)