Evdev compilation


It looks like evdev driver is not lined up with indev interface in version 6.1.1.

There are some compilation problems:

  1. function bool evdev_read(lv_indev_data_t * data), does not have
    struct _lv_indev_drv_t * indev_drv argument (ref. lv_indev_drv_t::read_cb).
  2. evdev.h:26 #include "lvgl/lv_hal/lv_hal_indev.h" is missig \src\ subdir
  3. there is no evdev_exit() function (to close the event file handle)

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

It is a compilation problem.

What do you experience?

It does not compile.
indev_drv.read_cb = evdev_read;

What do you expect?

Successful compilation :slight_smile:

Code to reproduce

lv_indev_drv_t indev_drv;
indev_drv.type 		= LV_INDEV_TYPE_POINTER;
indev_drv.read_cb 	= evdev_read;

Screenshot and/or video

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

Make sure you’re using the latest lv_drivers from GitHub. That version works with the 6.x series.

Great, thank you.
If so, the drivers zip in the downloadable package 6.1.1 is not up to date.
There is ,even in github source, no evdev_exit (like in mouse drvier) for the event file handle release.

Linux will close file handles automatically when the process exits, so the evdev_exit function isn’t strictly necessary.