Thorgal789 wrote: ↑Saturday 27 April 2024 12:13
Ha yes, I m reading the value, data don't contain "open" or "closed" but the level (except for 0 and 100 value, so only full closed or full open)
if (d->level < TYPE_BLINDS && strcmp(d->data, "Closed") == 0)
doesn't print 'Closed' in the icon.
Am i doing something wrong?
I like to have 'Open', 'Closed' and, if possible the level between them.
I can see in the data the level status as:
// Display a open/clode state for covering
if (d->type == TYPE_BLINDS)
{
lv_obj_t * label = lv_label_create(Button_icon);
lv_obj_set_style_text_color(label, color, 0);
lv_obj_align_to(label, img, LV_ALIGN_OUT_RIGHT_BOTTOM, 0, 0);
if (strcmp(d->data, "Closed") == 0)
{
lv_label_set_text(label, " Dicht");
}
if (strcmp(d->data, "Open") == 0)
{
lv_label_set_text(label, " Open");
}
if ((strcmp(d->data, "Closed") != 0) && (strcmp(d->data, "Open") != 0))
{
lv_label_set_text_fmt(label, " %d %%",d->level );
}
}
With this as result (and some translation):
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Wednesday 15 May 2024 18:11
by Thorgal789
Ha, so the data contain "open" or "close" or a level ? there is 3 possibles values ?
BTW I will take your capture for the project ^^.
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Friday 17 May 2024 10:13
by Rik60
Yes, the data can contain 3 possible values:
Open
Closed
Level %
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Saturday 01 June 2024 8:05
by ElMyggo
I get this 7" displayboard and wonder if this can work with same software, do i have to make the driver myself?
Panlee ZX7D00CE01S-V13 http://en.smartpanle.com/product-item-19.html
I m not using the same code than them for the touch, but it seem you have a GT911 too and the code I m using is already tested for another device.
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Saturday 01 June 2024 15:01
by ElMyggo
Super! i do some testing
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Sunday 02 June 2024 10:07
by ElMyggo
Have done som testing now and i get no backlight so dont know if screen is working, touchdriver seems to work, i can calibrate screen according to log.
No backlight
--- Terminal on COM5 | 115200 8-N-1
--- Available filters and text transformations: colorize, debug, default, direct, esp32_exception_decoder, hexlify, log2file, nocontrol, printable, send_on_enter, time
--- More details at https://bit.ly/pio-monitor-filters
--- Quit: Ctrl+C | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H
ESP-ROM:esp32s3-20210327
Build:Mar 27 2021
rst:0x1 (POWERON),boot:0x8 (SPI_FAST_FLASH_BOOT)
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fce3808,len:0x128
load:0x403c9700,len:0xb90
load:0x403cc700,len:0x28cc
entry 0x403c98b8
Starting application
Config version: 0
Clearing Global Config
Init 911 driver
Driver GT911 started: (800x480)
Check ACK on addr request on 0x
5D
: SUCCESS
Starting calibration
Calibration coef: 1.2 , -1.4
Calibration offset: -103.8 , 602.4
Display buffer size: 38400 bytes
Screen init done
Brightness value: 255
I tested the files from https://github.com/fbiego/jarvis-lvgl-esp32 and then i get backlight and working screen for 1 second then start flickering one line.. i have marked photo to see that the backlight is on
backlight.jpg (72.39 KiB) Viewed 1289 times
flicker.jpg (72.07 KiB) Viewed 1289 times
I try to find out how the backlight is turning on and do some more testing
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
For the second part, file to edit is screen_driver.cpp around line 524
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Sunday 02 June 2024 15:26
by ElMyggo
I added #define GFX_BL 45 in driver file and i get picture , i have to change resolution to 800x481 because a white line at bottom (read this on the other link you find)
But i cant swipe right (settings) screen get white and restart, swipe left is working.
I upload a video here:
(Havent fix the custom font)
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Sunday 02 June 2024 19:32
by Thorgal789
Nice, updating the code (not sure I have set the 481 at good place, in the platformio.ini file ?
Ok so you have crash on the "tool" panel (There is in order, tool/home/home_bis/group/info)
This page display hardware information, there is perhaps something bad on memory stuff ATM for your device
Can you try to catch logs using the serial monitor ?
Else I think the guilty code is here, the rest only display 2 buttons.
About the issue, have made some search but I can't say if the issue is from the config or the hardware. But there is others users with the same issue.
According the jarvis project can try to replace in the platoformio.ini file
Perhaps your device don't have psram, but from the ALI express link it have 8M, there is different version ?
If you can't avoid the crash I will disable it for all board, but it can be usefull later ...
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Wednesday 05 June 2024 17:29
by ElMyggo
Have now tested many different settings whitout any luck so i continue to have psram disabled.
I should have 8M memory but i can get a faulty board or something else.
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Wednesday 05 June 2024 19:41
by Thorgal789
Don't worry, I will disable it by defaut for all OS.
For the moment it's just an information, the code don't use them, so not usefull.
I will re-enable it later when needed.
Code is updated (just disabled the psram debug output)
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Monday 24 June 2024 14:13
by Thorgal789
For thoses one that use the "stand by" mode, or don't use intensely the device, gizmocuz have added a new feature on recent domoticz version.
It's possible now to subscribe on websocket notification only for needed devices.
(For the moment only possible if you don't use "Bonus Home page panel")
On the "tool panel" I have added the Running time, and the total data received by the device by Websocket. the difference is just incredible, at start you will have a enormous JSON, but after it something like 20 time lighter without problem on hudge installation.
Re: New project, a small wall display to control Domoticz using CYD (Cheap ESP32 touchscreen)
Posted: Monday 24 June 2024 16:31
by gizmocuz
Perhaps if you put all used devices in a roomplan, and use this in your initial query, you have a lot less data at startup.
(See the example www/templates/custom.example)