Skip to content

Commit 93a4449

Browse files
committedJul 14, 2021
Things suggested by @tore-espressif
See [here](lvgl#70 (review)) in lvgl#70
1 parent befa5d0 commit 93a4449

File tree

4 files changed

+19
-9
lines changed

4 files changed

+19
-9
lines changed
 

‎Kconfig

+5-5
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ menu "LVGL ESP Drivers"
44

55
rsource "lvgl_touch/Kconfig"
66

7-
menu "I2C Port Settings"
8-
depends on LV_I2C && !HAVE_I2C_MANAGER
7+
endmenu
8+
9+
menu "I2C Port Settings"
10+
depends on LV_I2C && !HAVE_I2C_MANAGER
911

10-
rsource "lvgl_i2c/Kconfig"
11-
12-
endmenu
12+
rsource "lvgl_i2c/Kconfig"
1313

1414
endmenu

‎lvgl_i2c/README.md

+2-4
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
### I2C Manager support
1010

11-
`lvgl_esp32_drivers` comes with built-in I2C support by integrating I2C Manager, which is used in case you select a touch sensor or screen that uses the I2C bus. If you're just using LVGL you don't need to do anything special.
11+
`lvgl_esp32_drivers` integrates [I2C Manager](https://github.com/ropg/i2c_manager), which is used in case you select a touch sensor or screen that uses the I2C bus. If you're just using LVGL you don't need to do anything special.
1212

1313
I2C Manager can help if you are in a situation where you want to avoid "bus conflicts" on the I2C bus. Suppose you use LVGL with a touch sensor that uses I2C, and your device also has another I2C device that needs to be read frequently, such as a 3D-accelerometer. ESP-IDF is not inherently "thread-safe". So if you read that from another task than the one LVGL uses to read the touch data, you need some kind of mechanism to keep these communications from interfering.
1414

@@ -27,15 +27,13 @@ lvgl_driver_init();
2727
2828
The `lvgl_i2c_locking` part will cause the LVGL I2C driver to play nice with anything else that uses the I2C port(s) through I2C Manager.
2929
30-
Refer to the [I2C Manager GitHub repository](https://github.com/ropg/i2c_manager) for much more information.
31-
3230
3331
 
3432
3533
3634
## Information for LVGL driver developers
3735
38-
I2C support in the LVGL ESP drivers is provided exclusively by the files in this directory. Code from all over the project that was talking to the I2C hardware directly has been replaced by code that communicates through the functions provided in `i2c_manager.h`. I2C is handled by the I2C Manager that was built into `lvlg_esp32_drivers`, but the code would be the same if it was routed through I2C Manager as a separate component. If you are providing a driver, you need not worry about any of this.
36+
I2C support in the LVGL ESP drivers is provided exclusively by the files in this directory. Driver code that uses I2C communicates through the functions provided in `i2c_manager.h`.
3937
4038
4139
 

‎lvgl_tft/Kconfig

+6
Original file line numberDiff line numberDiff line change
@@ -1006,10 +1006,16 @@ menu "LVGL TFT Display controller"
10061006
config LV_I2C_DISPLAY_PORT_0
10071007
bool
10081008
prompt "I2C port 0"
1009+
help
1010+
I2C is shared peripheral managed by I2C Manager. In order to configure I2C Manager (pinout, etc.) see menu
1011+
Component config->I2C Port Settings.
10091012

10101013
config LV_I2C_DISPLAY_PORT_1
10111014
bool
10121015
prompt "I2C port 1"
1016+
help
1017+
I2C is shared peripheral managed by I2C Manager. In order to configure I2C Manager (pinout, etc.) see menu
1018+
Component config->I2C Port Settings.
10131019

10141020
endchoice
10151021

‎lvgl_touch/Kconfig

+6
Original file line numberDiff line numberDiff line change
@@ -492,10 +492,16 @@ menu "LVGL Touch controller"
492492
config LV_I2C_TOUCH_PORT_0
493493
bool
494494
prompt "I2C port 0"
495+
help
496+
I2C is shared peripheral managed by I2C Manager. In order to configure I2C Manager (pinout, etc.) see menu
497+
Component config->I2C Port Settings.
495498

496499
config LV_I2C_TOUCH_PORT_1
497500
bool
498501
prompt "I2C port 1"
502+
help
503+
I2C is shared peripheral managed by I2C Manager. In order to configure I2C Manager (pinout, etc.) see menu
504+
Component config->I2C Port Settings.
499505

500506
endchoice
501507

0 commit comments

Comments
 (0)
Please sign in to comment.