Hey folks,
I am trying to use the lv_qrcode library with my Zephyr Nordic nRFConnect project.
I keep getting CMake build errors such as below when I try access functions from lv_qrcode.h in my application.
In function ‘qrcode_scr_lvgl_create’:
[build] /workspaces/app_nrf_fw/src/graphic_manager/qrcode_screen.c:87:9: error: implicit declaration of function ‘lv_qrcode_create’; did you mean ‘lv_group_create’? [-Werror=implicit-function-declaration]
[build] 87 | lv_qrcode_create( qrcode_screen, QRCODE_DIMENSION_PIXELS, lv_color_hex3( LV_COLOR_HEX3_DARKEST ), lv_color_hex3( LV_COLOR_HEX3_LIGHTEST ) );
[build] | ^~~~~~~~~~~~~~~~
[build] | lv_group_create
[build] /workspaces/app_nrf_fw/src/graphic_manager/qrcode_screen.c:86:12: error: assignment to ‘lv_obj_t *’ {aka ‘struct _lv_obj_t *’} from ‘int’ makes pointer from integer without a cast [-Werror=int-conversion]
[build] 86 | qr_obj =
[build] | ^
This is the CMake file I am working with./cfs-file/__key/communityserver-components-multipleuploadfilemanager/c0c5a53f_2D00_52b8_2D00_4c7e_2D00_9422_2D00_535ad2ea53f0-130336-
I see that lv_qrcode.c is included in https://github.com/zephyrproject-rtos/zephyr/blob/main/modules/lvgl/CMakeLists.txt
And this is in my prj.conf
# LVGL
CONFIG_LVGL=y
CONFIG_LV_CONF_MINIMAL=y
CONFIG_LV_Z_BITS_PER_PIXEL=1
CONFIG_LV_Z_VDB_SIZE=100
CONFIG_LV_MEM_CUSTOM=y
CONFIG_LV_Z_MEM_POOL_NUMBER_BLOCKS=3
CONFIG_LV_COLOR_DEPTH_1=y
CONFIG_LV_USE_LABEL=y
CONFIG_LV_USE_IMG=y
CONFIG_LV_USE_QRCODE=y
C
ONFIG_LV_USE_CANVAS=y
I also see this line in my build log:
[build] [265/448 58% :: 2.346] Building C object modules/lvgl/CMakeFiles/modules__lvgl.dir/workdir/nrfconnect/modules/lib/gui/lvgl/src/extra/libs/qrcode/lv_qrcode.c.o
Any and all tips would be appreciated! Thank you