283 lines
9.9 KiB
YAML
283 lines
9.9 KiB
YAML
samsung_the_frame:
|
|
module: samsungtheframe
|
|
class: SamsungTheFrame
|
|
|
|
volume_up_events:
|
|
- the_frame_volume_up
|
|
volume_down_events:
|
|
- the_frame_volume_down
|
|
|
|
ip_address: 10.0.0.58
|
|
#broadcast_address: 10.0.0.255
|
|
#mac_address: 98:06:3C:85:93:38
|
|
#wol_switch: switch.theframewol
|
|
wake_up_service: "esphome/ir_bridge_turn_on_the_frame"
|
|
app_list: # https://github.com/tavicu/homebridge-samsung-tizen/issues/291
|
|
- 3201907018807 # Netflix
|
|
- 3201910019365 # Prime
|
|
|
|
virtual_sensors:
|
|
default_values:
|
|
binary_sensor.tv_auto_shutdown: false
|
|
binary_sensor.is_tv_on: false
|
|
sensors:
|
|
value_selector.samsung_the_frame_target_state:
|
|
power_off:
|
|
trigger_conditions:
|
|
- binary_sensor.is_everybody_sleeping or binary_sensor.is_living_room_sleeping or not binary_sensor.someone_home
|
|
- binary_sensor.projector_on or binary_sensor.projector_screen_down
|
|
hdmi: binary_sensor.vertex2_has_input_signal and not binary_sensor.projector_screen_down
|
|
manual: binary_sensor.is_tv_on and not binary_sensor.tv_auto_shutdown
|
|
tv_off: not binary_sensor.living_room_occupancy
|
|
art_mode: True
|
|
|
|
tv_state: sensor.samsung_the_frame_target_state
|
|
|
|
output_sensors:
|
|
is_on: binary_sensor.is_tv_on
|
|
is_art_mode: binary_sensor.tv_in_art_mode
|
|
tv_auto_shutdown: binary_sensor.tv_auto_shutdown
|
|
|
|
input_sensors:
|
|
power_plug: switch.the_frame_power_plug
|
|
power_plug_power: sensor.the_frame_power_plug_power
|
|
|
|
w4000i:
|
|
module: smartprojector_benq_over_telnet
|
|
class: SmartProjector
|
|
entity: switch.projector
|
|
|
|
telnet_connection:
|
|
ip: 10.0.0.40
|
|
port: 8000
|
|
|
|
power_plug:
|
|
entity: switch.living_room_projector_plug
|
|
power_sensor: sensor.living_room_projector_plug_power
|
|
power_threeshold: 5
|
|
conditions:
|
|
trigger_conditions:
|
|
- binary_sensor.someone_home and not (binary_sensor.is_everybody_sleeping or binary_sensor.is_living_room_sleeping)
|
|
- sensor.living_room_projector_plug_power > 10 or binary_sensor.projector_on # don't remove this one or it will fry the projector
|
|
|
|
virtual_sensors:
|
|
sensors:
|
|
value_selector.projector_icon:
|
|
projector_off:
|
|
conditions: not super
|
|
value: "'mdi:projector-off'"
|
|
projector_on:
|
|
conditions: True
|
|
value: "'mdi:projector'"
|
|
continuous_condition.projector_ready:
|
|
conditions: switch.living_room_projector_plug
|
|
time: 30
|
|
continuous_condition.has_allm_signal_for_a_while:
|
|
conditions: binary_sensor.vertex2_allm
|
|
time: 5
|
|
|
|
attributes_override:
|
|
icon: sensor.projector_icon
|
|
friendly_name: Projecteur
|
|
|
|
press_enter_event: send_projector_enter
|
|
press_enter_events:
|
|
vertex2_allm:
|
|
event_name: state_changed
|
|
event_data:
|
|
entity_id: binary_sensor.has_allm_signal_for_a_while
|
|
new_state:
|
|
state: "on"
|
|
apple_tv_mute_short_press:
|
|
event_name: state_changed
|
|
event_data:
|
|
entity_id: binary_sensor.ir_bridge_apple_tv_mute_button_short_press
|
|
old_state:
|
|
state: "off"
|
|
new_state:
|
|
state: "on"
|
|
|
|
projector_ready_conditions: binary_sensor.projector_ready
|
|
|
|
#state_conditions: binary_sensor.projector_on
|
|
#cooling_down_sensor: binary_sensor.projector_cooling_down
|
|
|
|
smart_conditions:
|
|
trigger_conditions: binary_sensor.vertex2_has_input_signal and binary_sensor.projector_screen_down
|
|
disable_conditions:
|
|
- self == 'unavailable'
|
|
#- self == 'off' and not binary_sensor.projector_screen_down
|
|
#- not binary_sensor.projector_screen_down
|
|
#- binary_sensor.projector_cooling_down
|
|
- switch.projector.warming_up
|
|
|
|
bravia_theatre:
|
|
module: smartswitch
|
|
class: SmartSwitch
|
|
entity: media_player.bravia_theatre
|
|
|
|
smart_conditions:
|
|
#trigger_conditions: binary_sensor.vertex2_has_input_signal
|
|
trigger_conditions: sensor.vertex2_output_selected == 'Projector' or input_boolean.use_bravia_theater_for_the_frame
|
|
blocking_conditions: not binary_sensor.vertex2_has_input_signal
|
|
|
|
projection_screen:
|
|
module: smartshutter
|
|
class: SmartShutter
|
|
entity: cover.living_room_projection_screen
|
|
close_position: 22
|
|
|
|
toggle_events:
|
|
apple_tv_mute_long_press:
|
|
event_name: state_changed
|
|
event_data:
|
|
entity_id: binary_sensor.ir_bridge_apple_tv_mute_button_long_press
|
|
old_state:
|
|
state: "off"
|
|
new_state:
|
|
state: "on"
|
|
|
|
# close_conditions: # close mean screen down
|
|
# # when the projector is turn back on, it can happen that this condition is evaluated before projector_off_for_a_while is updated
|
|
# # so I need to test both binary_sensor.projector_on and not binary_sensor.projector_off_for_a_while
|
|
# trigger_conditions: binary_sensor.projector_on or not binary_sensor.projector_off_for_a_while
|
|
# disable_conditions:
|
|
# - binary_sensor.day_interval_night and not binary_sensor.projector_on
|
|
# - binary_sensor.is_everybody_sleeping and not binary_sensor.projector_on
|
|
|
|
open_conditions: # close mean screen up
|
|
trigger_conditions: binary_sensor.projector_off_for_a_while
|
|
|
|
vertex_2:
|
|
module: vertex2
|
|
class: Vertex2
|
|
priority: 5
|
|
|
|
input_config:
|
|
default:
|
|
name: None
|
|
icon: mdi:television-off
|
|
0:
|
|
name: AppleTV
|
|
icon: mdi:apple
|
|
#reboot_when_leaving: True
|
|
1:
|
|
name: Xbox
|
|
icon: mdi:microsoft-xbox
|
|
2:
|
|
name: Playstation
|
|
icon: mdi:sony-playstation
|
|
3:
|
|
name: Switch
|
|
icon: mdi:nintendo-switch
|
|
|
|
output_config:
|
|
default:
|
|
name: None
|
|
icon: mdi:television-off
|
|
0:
|
|
name: TV
|
|
icon: mdi:television
|
|
1:
|
|
name: Projector
|
|
icon: mdi:projector
|
|
|
|
# vertex2_power_plug:
|
|
# entity: switch.fibaro_vertex_plug_51
|
|
# # power_consumption: sensor.fibaro_vertex_plug_51_power
|
|
# conditions:
|
|
# trigger_conditions: binary_sensor.someone_home
|
|
# blocking_conditions:
|
|
# - binary_sensor.is_everybody_sleeping or binary_sensor.is_salon_sleeping
|
|
# - binary_sensor.vertex2_unreachable and not binary_sensor.is_tv_on and not binary_sensor.projector_on
|
|
|
|
mutetx0_conditions: input_boolean.use_bravia_theater_for_the_frame
|
|
|
|
#filmmaker_mode_conditions: sensor.vertex2_input_select_tx0 == 'AppleTV'
|
|
|
|
output_selection:
|
|
Projector: binary_sensor.projector_screen_down
|
|
TV: True
|
|
|
|
# input_selection:
|
|
# None: binary_sensor.vertex2_has_input_signal # this will prevent input change if the current input is still active
|
|
# Switch: binary_sensor.is_playing_switch
|
|
# AppleTV: not binary_sensor.is_appletv_standy
|
|
# Playstation: switch.ps5_136_power
|
|
# Xbox: True
|
|
|
|
vertex2_address: http://10.0.0.33
|
|
vertex2_tcp_port: 2220
|
|
|
|
video_tx_signal_sensor: sensor.vertex2_video_signal
|
|
allm_sensor: binary_sensor.vertex2_allm
|
|
audio_out_signal_sensor: sensor.vertex2_audio_signal
|
|
output_selected_sensor: sensor.vertex2_output_selected
|
|
input_selected_sensor: sensor.vertex2_input_selected
|
|
unreachable_sensor: binary_sensor.vertex2_unreachable
|
|
|
|
use_bravia_theater_for_the_frame:
|
|
module: smartswitch
|
|
class: SmartSwitch
|
|
|
|
entity: input_boolean.use_bravia_theater_for_the_frame
|
|
|
|
toggle_events:
|
|
- toggle_use_bravia_theater_for_the_frame
|
|
|
|
|
|
apple_remote:
|
|
module: virtualevents
|
|
class: VirtualEvents
|
|
|
|
priority: 100 # default priority app is 50, since the virtual_events doesn't create any sensor but is based on sensor created by many app, it's important it's created last
|
|
|
|
virtual_events:
|
|
toggle_use_bravia_theater_for_the_frame:
|
|
event_name: toggle_use_bravia_theater_for_the_frame
|
|
event_condition: binary_sensor.is_tv_on and binary_sensor.ir_bridge_apple_tv_mute_button_short_press
|
|
|
|
# Volume buttons received by the IR bridge: Bravia > TV > Sonos.
|
|
homecinema_volume:
|
|
module: eventsforwarder
|
|
class: EventsForwarder
|
|
priority: 100
|
|
|
|
forwarders:
|
|
volume_up:
|
|
events_to_listen:
|
|
- esphome.ir_bridge_volume_up
|
|
events_to_send:
|
|
the_frame:
|
|
event_name: the_frame_volume_up
|
|
event_condition: not (media_player.bravia_theatre == 'on' or media_player.bravia_theatre == 'playing' or media_player.bravia_theatre == 'paused' or media_player.bravia_theatre == 'idle') and binary_sensor.is_tv_on == 'on'
|
|
services_to_call:
|
|
bravia:
|
|
service: media_player/volume_up
|
|
event_condition: (media_player.bravia_theatre == 'on' or media_player.bravia_theatre == 'playing' or media_player.bravia_theatre == 'paused' or media_player.bravia_theatre == 'idle')
|
|
data:
|
|
entity_id: media_player.bravia_theatre
|
|
sonos:
|
|
service: media_player/volume_up
|
|
event_condition: not (media_player.bravia_theatre == 'on' or media_player.bravia_theatre == 'playing' or media_player.bravia_theatre == 'paused' or media_player.bravia_theatre == 'idle') and binary_sensor.is_tv_on != 'on'
|
|
data:
|
|
entity_id: media_player.living_room_sonos
|
|
volume_down:
|
|
events_to_listen:
|
|
- esphome.ir_bridge_volume_down
|
|
events_to_send:
|
|
the_frame:
|
|
event_name: the_frame_volume_down
|
|
event_condition: not (media_player.bravia_theatre == 'on' or media_player.bravia_theatre == 'playing' or media_player.bravia_theatre == 'paused' or media_player.bravia_theatre == 'idle') and binary_sensor.is_tv_on == 'on'
|
|
services_to_call:
|
|
bravia:
|
|
service: media_player/volume_down
|
|
event_condition: (media_player.bravia_theatre == 'on' or media_player.bravia_theatre == 'playing' or media_player.bravia_theatre == 'paused' or media_player.bravia_theatre == 'idle')
|
|
data:
|
|
entity_id: media_player.bravia_theatre
|
|
sonos:
|
|
service: media_player/volume_down
|
|
event_condition: not (media_player.bravia_theatre == 'on' or media_player.bravia_theatre == 'playing' or media_player.bravia_theatre == 'paused' or media_player.bravia_theatre == 'idle') and binary_sensor.is_tv_on != 'on'
|
|
data:
|
|
entity_id: media_player.living_room_sonos
|