Hello!
Nextion display, how can I send accented characters?
The code is in the firmware of an 8266.
The current code is displayed on the screen as follows:
The code:
display:
- platform: nextion
id: disp
lambda: |-
auto time = id(ido).now();
it.set_component_text_printf("t0", "%d:%.2d", time.hour,time.minute);
it.set_component_text_printf("t4", "%d:%.2d:%.2d", time.year,time.month,time.day_of_month);
it.set_component_text_printf("t1", "Hőm: %.1f °C", id(terasz_hom).state);
it.set_component_text_printf("t2", "Pára: %.1f %%", id(terasz_para).state);
it.set_component_text_printf("t3", "Elem: %.0f %%", id(terasz_elem).state);
I tried this too, but it didn’t work:
the ttf file is copied to the fonts folder
font:
- file: 'fonts/Roboto-ThinItalic.ttf'
id: font2
glyphs: ['&', '@', '!', ',', '.', '"', '%', '(', ')', '+', '-', '_', ':', '°', '0',
'1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'Á', 'B', 'C', 'D', 'E',
'F', 'G', 'H', 'I', 'Í', 'J', 'K', 'L', 'M', 'N', 'O', 'Ó', 'Ö', 'Ő', 'P', 'Q', 'R', 'S', 'É',
'T', 'U', 'Ú', 'Ü', 'Ű', 'V', 'W', 'X', 'Y', 'Z', ' ', 'a', 'b', 'c', 'd', 'e', 'f',
'g', 'h', 'i', 'í', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't',
'u', 'v', 'w', 'x', 'y', 'z','á', 'é', 'ö', 'ő', 'ü', 'ű', 'ó', '/']