Add SonosController and player configuration with event handling for play, cycle radio, and album features
This commit is contained in:
39
apps/global/sonos.yaml
Normal file
39
apps/global/sonos.yaml
Normal file
@@ -0,0 +1,39 @@
|
||||
sonos_controller:
|
||||
module: sonoscontroller
|
||||
class: SonosController
|
||||
|
||||
players:
|
||||
sonos_garage:
|
||||
entity: media_player.garage
|
||||
|
||||
off_conditions: binary_sensor.is_everybody_sleeping or not binary_sensor.someone_home
|
||||
|
||||
play_stop_events:
|
||||
btn_play_stop:
|
||||
event_name: state_changed
|
||||
debounce_seconds: 0.5
|
||||
event_data:
|
||||
entity_id: event.garage_bilresa_button_bouton_1
|
||||
new_state:
|
||||
attributes:
|
||||
event_type: multi_press_1
|
||||
|
||||
cycle_radio_events:
|
||||
btn_play_stop:
|
||||
event_name: state_changed
|
||||
debounce_seconds: 0.5
|
||||
event_data:
|
||||
entity_id: event.garage_bilresa_button_bouton_1
|
||||
new_state:
|
||||
attributes:
|
||||
event_type: long_press
|
||||
|
||||
cycle_album_events:
|
||||
btn_play_stop:
|
||||
event_name: state_changed
|
||||
debounce_seconds: 0.5
|
||||
event_data:
|
||||
entity_id: event.garage_bilresa_button_bouton_2
|
||||
new_state:
|
||||
attributes:
|
||||
event_type: multi_press_1
|
||||
Reference in New Issue
Block a user