当前位置:网站首页>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
边栏推荐
- [MySQL from introduction to proficiency] [advanced chapter] (IV) MySQL permission management and control
- Leetcode T48: rotating images
- sql优化之explain
- 潘多拉 IOT 开发板学习(RT-Thread)—— 实验3 按键实验(学习笔记)
- 阿里被裁员工,找工作第N天,猎头又传来噩耗...
- R language uses the mutation function of dplyr package to standardize the specified data column (using mean function and SD function), and calculates the grouping mean of the standardized target varia
- LVGL 8.2 Draw label with gradient color
- C language achievement management system for middle school students
- AI and Life Sciences
- The implementation of OSD on rk1126 platform supports color translucency and multi-channel support for Chinese
猜你喜欢
Map of mL: Based on Boston house price regression prediction data set, an interpretable case of xgboost model using map value
实时数据仓库
leetcode:6110. 网格图中递增路径的数目【dfs + cache】
Alcohol driving monitoring system based on stm32+ Huawei cloud IOT design
商业智能BI财务分析,狭义的财务分析和广义的财务分析有何不同?
潘多拉 IOT 开发板学习(RT-Thread)—— 实验3 按键实验(学习笔记)
Data warehouse interview question preparation
Transplant tinyplay for imx6q development board QT system
使用CLion编译OGLPG-9th-Edition源码
电商系统中红包活动设计
随机推荐
Respect others' behavior
No servers available for service: xxxx
Wt588f02b-8s (c006_03) single chip voice IC scheme enables smart doorbell design to reduce cost and increase efficiency
R language uses dplyr package group_ The by function and the summarize function calculate the mean and standard deviation of the target variables based on the grouped variables
[MySQL from introduction to proficiency] [advanced chapter] (IV) MySQL permission management and control
An overview of 2D human posture estimation
Progress in architecture
MySQL的触发器
C language set operation
【云原生】我怎么会和这个数据库杠上了?
Chapter 16 string localization and message Dictionary (2)
redis 日常笔记
Red envelope activity design in e-commerce system
A keepalived high availability accident made me learn it again
阿里被裁员工,找工作第N天,猎头又传来噩耗...
深度学习7 Transformer系列实例分割Mask2Former
【MySQL从入门到精通】【高级篇】(五)MySQL的SQL语句执行流程
Explain of SQL optimization
Digi XBee 3 rf: 4 protocols, 3 packages, 10 major functions
数据埋点的一些问题和想法