Skip to content

Commit 9a66a72

Browse files
update LVGL_Demo example
1 parent bd97eb5 commit 9a66a72

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

libraries/Arduino_H7_Video/examples/LVGLDemo/LVGLDemo.ino

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
#include "lvgl.h"
1313

1414
Arduino_H7_Video Display(800, 480, GigaDisplayShield); /* Arduino_H7_Video Display(1024, 768, USBCVideo); */
15-
Arduino_GigaDisplayTouch Touch;
15+
Arduino_GigaDisplayTouch TouchDetector;
1616

1717
void gigaTouchHandler(uint8_t contacts, GDTpoint_t* points) {
1818
if (contacts > 0) {
@@ -27,8 +27,8 @@ void setup() {
2727
Serial.begin(115200);
2828

2929
Display.begin();
30-
Touch.begin();
31-
Touch.attach(gigaTouchHandler);
30+
TouchDetector.begin();
31+
TouchDetector.onDetect(gigaTouchHandler);
3232

3333
/* Change the active screen's background color */
3434
lv_obj_set_style_bg_color(lv_scr_act(), lv_color_hex(0x03989e), LV_PART_MAIN);

0 commit comments

Comments
 (0)