show and hide componente
This commit is contained in:
21
esphome.yaml
21
esphome.yaml
@@ -157,14 +157,14 @@ api:
|
|||||||
then:
|
then:
|
||||||
- lambda: 'id(disp1)->upload_tft();'
|
- lambda: 'id(disp1)->upload_tft();'
|
||||||
|
|
||||||
##### Service to send a command "printf" directly to the display. Useful for testing #####
|
##### Service to send a command "printf" directly to the display #####
|
||||||
- service: send_command_printf
|
- service: send_command_printf
|
||||||
variables:
|
variables:
|
||||||
cmd: string
|
cmd: string
|
||||||
then:
|
then:
|
||||||
- lambda: 'id(disp1).send_command_printf("%s", cmd.c_str());'
|
- lambda: 'id(disp1).send_command_printf("%s", cmd.c_str());'
|
||||||
|
|
||||||
##### Service to send a command "text_printf" directly to the display. Useful for testing #####
|
##### Service to send a command "text_printf" directly to the display #####
|
||||||
- service: send_command_text_printf
|
- service: send_command_text_printf
|
||||||
variables:
|
variables:
|
||||||
component: string
|
component: string
|
||||||
@@ -174,7 +174,7 @@ api:
|
|||||||
switch.is_on: nextion_init
|
switch.is_on: nextion_init
|
||||||
- lambda: 'id(disp1).set_component_text_printf(component.c_str(), "%s", message.c_str());'
|
- lambda: 'id(disp1).set_component_text_printf(component.c_str(), "%s", message.c_str());'
|
||||||
|
|
||||||
##### Service to send a command "component_value (Dualstate Button)" directly to the display. Useful for testing #####
|
##### Service to send a command "component_value (Dualstate Button)" directly to the display #####
|
||||||
- service: send_command_value
|
- service: send_command_value
|
||||||
variables:
|
variables:
|
||||||
component: string
|
component: string
|
||||||
@@ -184,7 +184,7 @@ api:
|
|||||||
switch.is_on: nextion_init
|
switch.is_on: nextion_init
|
||||||
- lambda: 'id(disp1).set_component_value(component.c_str(), message);'
|
- lambda: 'id(disp1).set_component_value(component.c_str(), message);'
|
||||||
|
|
||||||
##### Service to send a command "component_value (Dualstate Button)" directly to the display. Useful for testing #####
|
##### Service to send a command "hide componente" directly to the display #####
|
||||||
- service: send_command_hide
|
- service: send_command_hide
|
||||||
variables:
|
variables:
|
||||||
component: string
|
component: string
|
||||||
@@ -193,7 +193,16 @@ api:
|
|||||||
switch.is_on: nextion_init
|
switch.is_on: nextion_init
|
||||||
- lambda: 'id(disp1).hide_component(component.c_str());'
|
- lambda: 'id(disp1).hide_component(component.c_str());'
|
||||||
|
|
||||||
##### Service to send a command "component_value (Dualstate Button)" directly to the display. Useful for testing #####
|
##### Service to send a command "show componente" directly to the display #####
|
||||||
|
- service: send_command_show
|
||||||
|
variables:
|
||||||
|
component: string
|
||||||
|
then:
|
||||||
|
- wait_until:
|
||||||
|
switch.is_on: nextion_init
|
||||||
|
- lambda: 'id(disp1).show_component(component.c_str());'
|
||||||
|
|
||||||
|
##### Service to send a command "font color" directly to the display #####
|
||||||
- service: send_command_font_color
|
- service: send_command_font_color
|
||||||
variables:
|
variables:
|
||||||
component: string
|
component: string
|
||||||
@@ -202,7 +211,7 @@ api:
|
|||||||
- wait_until:
|
- wait_until:
|
||||||
switch.is_on: nextion_init
|
switch.is_on: nextion_init
|
||||||
- lambda: 'id(disp1).set_component_font_color(component.c_str(), message);'
|
- lambda: 'id(disp1).set_component_font_color(component.c_str(), message);'
|
||||||
##### Service to send a command "component_value (Dualstate Button)" directly to the display. Useful for testing #####
|
##### Service to send a command "background color" directly to the display #####
|
||||||
- service: send_command_background_color
|
- service: send_command_background_color
|
||||||
variables:
|
variables:
|
||||||
component: string
|
component: string
|
||||||
|
|||||||
Reference in New Issue
Block a user