Draw after LVGL initialization

Important: unclear posts may not receive useful answers.

Before posting

  • Get familiar with Markdown to format and structure your post
  • Be sure to update lvgl from the latest version from the master branch.
  • Be sure you have checked the FAQ and read the relevant part of the documentation.
  • If applicable use the Simulator to eliminate hardware related issues.

Delete this section if you read and applied the mentioned points.

Description

What MCU/Processor/Board and compiler are you using?

SSD1327 + STM32L476RG

What LVGL version are you using?

v8.3

What do you want to achieve?

SSD1327 did not send a command to send the changed buffer through I2C, but it is drawn white on the LCD screen after LVGL initialization. Why is that?

What have you tried so far?

Code to reproduce

Add a code snippet which can run in the simulator. It should contain only the relevant code that compiles without errors when separated from your main code base.

The code block(s) should be formatted like:

static void my_flush_cb(lv_disp_drv_t *disp_drv, const lv_area_t *area, lv_color_t *color_p) 
{
	int16_t x, y;

	for(y = area->y1; y <= area->y2; y++) {
		for(x = area->x1; x <= area->x2; x++) {
			SSD1327_DrawPixel(x, y, (uint8_t)color_p->full);
			color_p++;
		}
	}

	// SSD1327_Display(); 
	lv_disp_flush_ready(disp_drv);

}

Screenshot and/or video

If possible, add screenshots and/or videos about the current state.

Do yo mean no data is sent via I2C at all? If so are you sure my_flush_cb is called? Have you tested the SSD1327 library without LVGL to be sure I2C is working well?

I checked that SSD1327 I2C works properly without LVGL, and I have to write an I2C transfer command within the my_flush_cb function to see the screen!

Are you sure the flush_cb is called? If so, I don’t see why the I2C functions shouldn’t work from there.