Pause TV automations

Hi All,

I’m trying to create an automation that when I’m watching a movie, if motion is detected somewhere, the movie pauses.

I’ve created a toggle called movie. Linked this to a button that shows the state so I know when it’s On.

My trigger is a motion detector.

My condition is a state.

I can force the automation and the TV pauses. However when I test the condition I get the red icon to say the state isn’t “on”.

When I physically test the automation it doesn’t run.

What am I missing?

‘’’
alias: Test
description: ‘’
trigger:

  • type: motion
    platform: device
    device_id: 1570e475d958c31fd7221baebcf7fdd8
    entity_id: binary_sensor.hallway_ms
    domain: binary_sensor
    condition:
  • condition: state
    entity_id: input_boolean.movie_night
    state: ‘On’
    action:
  • service: media_player.media_pause
    data: {}
    target:
    device_id:
    - b379e02f555ed5a82ce9988780026692
    - f04b6881a0be780a290093726822f6d3
    mode: restart
    ‘’’

You need:

state: ‘on’

No Caps!

1 Like