GeekTrack/2.Firmware/simulator/LVGL.Simulator/lv_fs_if
詹力 7b3cab933d 调通第一版固件 2022-09-18 18:40:49 +08:00
..
.gitignore 调通第一版固件 2022-09-18 18:40:49 +08:00
LICENSE 调通第一版固件 2022-09-18 18:40:49 +08:00
README.md 调通第一版固件 2022-09-18 18:40:49 +08:00
dirent.h 调通第一版固件 2022-09-18 18:40:49 +08:00
lv_fs_fatfs.c 调通第一版固件 2022-09-18 18:40:49 +08:00
lv_fs_if.c 调通第一版固件 2022-09-18 18:40:49 +08:00
lv_fs_if.h 调通第一版固件 2022-09-18 18:40:49 +08:00
lv_fs_pc.c 调通第一版固件 2022-09-18 18:40:49 +08:00
lv_fs_posix.c 调通第一版固件 2022-09-18 18:40:49 +08:00

README.md

File System Interface

LVGL has a File system module to attach memories which can manipulate with files. Here you can find interfaces to

  • FATFS
  • PC (Linux and Windows using C standard function .e.g fopen, fread)
  • POSIX (Linux and Windows using POSIX function .e.g open, read) file systems.

You still need to provide the drivers and libraries, this repo gives "only" the bridge between FATFS/PC/etc and LittlevGL.

Usage

  1. Add these lines to you lv_conf.h:
/*File system interface*/
#define LV_USE_FS_IF	1
#if LV_USE_FS_IF
#  define LV_FS_IF_FATFS    '\0'
#  define LV_FS_IF_PC       '\0'
#  define LV_FS_IF_POSIX    '\0'
#endif  /*LV_USE_FS_IF*/
  1. Enable an interface you need by changing '\0' to letter you want to use for that drive. E.g. 'S' for SD card with FATFS.

  2. Call lv_fs_if_init() to register the enabled interfaces.