Christmas is here and I wish you all a merry Christmas! I finally got my house decorated before Christmas, including a beautiful Christmas tree, a bunch of presents, and wreaths,candles, etc. The newly added coloured lights are also very nice, I also made a coloured light controller, which can not only adjust the colours of the lights as you wish, but also control the time when the lights go off, well, the icing on the cake!
The MaTouch ESP32 S3 2.1 Rotary TFT with Touch is not compatible with the TFT_eSPI library, so I use the GFX_Library_of_Arduino library instead of the driver.
Since I did not use the TFT_eSPI library, it is needed to delete or comment all the codes related to the TFT_eSPI library.
Initialising the input device,and we need to associate the encoder with the color wheel
To create a group use lv_group_t * g = lv_group_create(), to add an object to the group use lv_group_add_obj(g, obj), and to associate a group with an input device use lv_indev_set_group(indev, g);
Choose the Arduino and enter in parameters. According to the features of MaTouch ESP32 S3 2.1 Rotary TFT with Touch, the resolution is 480*480, the shape is a circle, and the color depth is 16-bit.
Design the screen
Add the colorwheel, switch, and buttons on the interface, the color wheel for getting colors, the switch for light switch, and buttons for timed triggers,and you can modify the parameters of them on the Inspector panel. After that, you can select some other widgets to decorate your interface, all is determined by your preference.