How to port LVGL to the RA6M3 processor?

Hello,

If you are on version 8.3.9 or higher, there is actually support for the RA6M3’s GPU driver (r_drw, Dave2D).

See the corresponding option in lv_conf.h: #define LV_USE_GPU_RA6M3_G2D

If you enable this and then follow the instructions here: Renesas — LVGL documentation
it should not be to hard to get working. Make sure to enable the driver in the corresponding thread you use for the graphical interface, then put the header file of that thread into the #define below this lv_conf option.

My Dave2D version of flushing and display driver setup now looks like this:

//DISP. DRIVER SETUP
    lv_disp_draw_buf_init(drawBuffer, buffer1, buffer2, horRes * bufLines);

    lv_disp_drv_init(displayDriver);
    displayDriver->draw_buf = drawBuffer;
    displayDriver->hor_res = (lv_coord_t)horRes;
    displayDriver->ver_res = (lv_coord_t)verRes;
    displayDriver->flush_cb = simple_buffer_flush_cb;

    lv_draw_ra6m3_g2d_init();

    lv_disp_drv_register(displayDriver);
//FLUSH
void simple_buffer_flush_cb(lv_disp_drv_t* disp_drv, const lv_area_t* area, lv_color_t* color_p)
{
    lv_port_gpu_blit(area->x1, area->y1, color_p, area);
    lv_disp_flush_ready(disp_drv);
}

That is all! Let me know if it works. There’s also the possibility to use DMA (Direct memory access) via the DMAC. I have a topic on that here: Using DMA to transfer to the screen's framebuffer. Through testing I have found DMA to be quicker than using the special graphical processor, however the GPU can be expanded upon much more and I believe it may be much quicker if properly implemented in conjuction with DMA.