QR code(二维码)
显示原文
QR code generation with LVGL. Uses QR-Code-generator by nayuki.
使用 LVGL 生成二维码。使用 nayuki 的 QR-Code-generator 码生成器。
Usage(用法)
显示原文
Enable LV_USE_QRCODE
in lv_conf.h
.
Use lv_qrcode_create()
to create a qrcode object, and use
lv_qrcode_update()
to generate a QR code.
If you need to re-modify the size and color, use
lv_qrcode_set_size()
and lv_qrcode_set_dark_color()
or
lv_qrcode_set_light_color()
, and
call lv_qrcode_update()
again to regenerate the QR code.
在 lv_conf.h
中启用 LV_USE_QRCODE
。
使用 lv_qrcode_create()
创建qrcode对象,并使用 lv_qrcode_update()
以生成二维码。
如果需要重新修改尺寸和颜色,请使用 lv_qrcode_set_size()
和 lv_qrcode_set_dark_color()
或
lv_qrcode_set_light_color()
,以及再次调用 lv_qrcode_update()
以重新生成QR代码。
Notes(笔记)
显示原文
QR codes with less data are smaller, but they scaled by an integer number to best fit to the given size.
数据较少的二维码较小,但它们按整数缩放 数字以最适合给定的尺寸。
Example
Create a QR Code
C code
View on GitHub