This looks fine, note however that ESPHome compiler and editor won’t complain if you have the name of the entity wrong in either your homeassistant binary sensory or service call.
Yes i’m define physical button on pin 14, and want by pressing this button turn on or off switch in HA depend of its state. Defining switch from HA it’s for displaying state from it on screen.
Entity ids seems to be ok, in logs nothing, except message from trigger.
[00:22:12][D][binary_sensor:036]: 'Switch screen': Sending state ON
[00:22:12][D][binary_sensor:036]: 'Switch screen': Sending state OFF
[00:22:13][D][binary_sensor:036]: 'Screen action': Sending state ON
[00:22:13][D][binary_sensor:036]: 'Screen action': Sending state OFF
[00:22:18][D][binary_sensor:036]: 'Switch screen': Sending state ON
[00:22:18][D][binary_sensor:036]: 'Switch screen': Sending state OFF
[00:22:19][D][binary_sensor:036]: 'Switch screen': Sending state ON
[00:22:19][D][binary_sensor:036]: 'Switch screen': Sending state OFF
[00:22:19][D][binary_sensor:036]: 'Switch screen': Sending state ON
[00:22:20][D][binary_sensor:036]: 'Switch screen': Sending state OFF
[00:22:20][D][binary_sensor:036]: 'Switch screen': Sending state ON
[00:22:21][D][binary_sensor:036]: 'Switch screen': Sending state OFF
[00:22:22][D][binary_sensor:036]: 'Switch screen': Sending state ON
[00:22:22][D][binary_sensor:036]: 'Switch screen': Sending state OFF
[00:22:24][D][binary_sensor:036]: 'Screen action': Sending state ON
[00:22:24][D][main:166]: Lights Page
[00:22:24][D][binary_sensor:036]: 'Screen action': Sending state OFF