当前位置:网站首页>LVGL 8.2 LED
LVGL 8.2 LED
2022-07-04 14:35:00 【Fairy sword love】
establish 3 individual LED Example
static void lv_example_led_1(void)
{
/*Create a LED and switch it OFF*/
lv_obj_t* led1 = lv_led_create(lv_scr_act()); // establish LED object
lv_obj_align(led1, LV_ALIGN_CENTER, -80, 0); //LV_ALIGN_CENTER Alignment -80,0
lv_led_off(led1); // LED OFF
/*Copy the previous LED and set a brightness*/
lv_obj_t* led2 = lv_led_create(lv_scr_act()); // establish LED object
lv_obj_align(led2, LV_ALIGN_CENTER, 0, 0); //LV_ALIGN_CENTER Alignment 0,0
lv_led_set_brightness(led2, 150); // Set up LED brightness
lv_led_set_color(led2, lv_palette_main(LV_PALETTE_RED)); // Red
/*Copy the previous LED and switch it ON*/
lv_obj_t* led3 = lv_led_create(lv_scr_act()); // establish LED object
lv_obj_align(led3, LV_ALIGN_CENTER, 80, 0); //LV_ALIGN_CENTER Alignment 80,0
lv_led_on(led3); // LED ON
}
Running effect
- Will be the first 2 individual LED Lighten up
lv_led_on(led2);
- Running effect
边栏推荐
- 统计php程序运行时间及设置PHP最长运行时间
- Leetcode 61: 旋转链表
- No servers available for service: xxxx
- MySQL的触发器
- 商业智能BI财务分析,狭义的财务分析和广义的财务分析有何不同?
- Digi XBee 3 RF: 4个协议,3种封装,10个大功能
- Solutions aux problèmes d'utilisation de l'au ou du povo 2 dans le riz rouge k20pro MIUI 12.5
- Classify boost libraries by function
- Test process arrangement (2)
- Real time data warehouse
猜你喜欢
Leetcode 61: 旋转链表
Data center concept
LVGL 8.2 text shadow
leetcode:6109. Number of people who know the secret [definition of DP]
Digi重启XBee-Pro S2C生产,有些差别需要注意
阿里被裁员工,找工作第N天,猎头又传来噩耗...
Test process arrangement (2)
《opencv学习笔记》-- 线性滤波:方框滤波、均值滤波、高斯滤波
Combined with case: the usage of the lowest API (processfunction) in Flink framework
Stm32f1 and stm32subeide programming example -max7219 drives 8-bit 7-segment nixie tube (based on GPIO)
随机推荐
codeforce:C. Sum of Substrings【边界处理 + 贡献思维 + 灵光一现】
PyTorch的自动求导机制详细解析,PyTorch的核心魔法
【C语言】指针笔试题
架构方面的进步
LifeCycle
数据中台概念
Leetcode T49: 字母异位词分组
Node mongodb installation
聊聊保证线程安全的 10 个小技巧
《opencv学习笔记》-- 线性滤波:方框滤波、均值滤波、高斯滤波
Nowcoder reverse linked list
關於miui12.5 紅米k20pro用au或者povo2出現問題的解决辦法
[information retrieval] experiment of classification and clustering
[cloud native] how can I compete with this database?
【MySQL从入门到精通】【高级篇】(五)MySQL的SQL语句执行流程
[MySQL from introduction to proficiency] [advanced chapter] (V) SQL statement execution process of MySQL
Industrial Internet has greater development potential and more industry scenarios
R language ggplot2 visualization: gganimate package creates dynamic line graph animation (GIF) and uses transition_ The reveal function displays data step by step along a given dimension in the animat
LVGL 8.2 Draw label with gradient color
【云原生】我怎么会和这个数据库杠上了?