Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -637,7 +637,7 @@ omit =
homeassistant/components/somfy/*
homeassistant/components/somfy_mylink/*
homeassistant/components/sonarr/sensor.py
homeassistant/components/songpal/media_player.py
homeassistant/components/songpal/*
homeassistant/components/sonos/*
homeassistant/components/sony_projector/switch.py
homeassistant/components/spc/*
Expand Down
14 changes: 0 additions & 14 deletions homeassistant/components/media_player/services.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -243,17 +243,3 @@ yamaha_enable_output:
enabled:
description: Boolean indicating if port should be enabled or not.
example: true

songpal_set_sound_setting:
description: Change sound setting.

fields:
entity_id:
description: Target device.
example: 'media_player.my_soundbar'
name:
description: Name of the setting.
example: 'nightMode'
value:
description: Value to set.
example: 'on'
3 changes: 3 additions & 0 deletions homeassistant/components/songpal/const.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
"""Constants for the Songpal component."""
DOMAIN = "songpal"
SET_SOUND_SETTING = "set_sound_setting"
5 changes: 2 additions & 3 deletions homeassistant/components/songpal/media_player.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@

from homeassistant.components.media_player import MediaPlayerDevice, PLATFORM_SCHEMA
from homeassistant.components.media_player.const import (
DOMAIN,
SUPPORT_SELECT_SOURCE,
SUPPORT_TURN_OFF,
SUPPORT_TURN_ON,
Expand All @@ -33,6 +32,8 @@
from homeassistant.exceptions import PlatformNotReady
import homeassistant.helpers.config_validation as cv

from .const import DOMAIN, SET_SOUND_SETTING

_LOGGER = logging.getLogger(__name__)

CONF_ENDPOINT = "endpoint"
Expand All @@ -42,8 +43,6 @@

PLATFORM = "songpal"

SET_SOUND_SETTING = "songpal_set_sound_setting"

SUPPORT_SONGPAL = (
SUPPORT_VOLUME_SET
| SUPPORT_VOLUME_STEP
Expand Down
13 changes: 13 additions & 0 deletions homeassistant/components/songpal/services.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
set_sound_setting:
description: Change sound setting.

fields:
entity_id:
description: Target device.
example: 'media_player.my_soundbar'
name:
description: Name of the setting.
example: 'nightMode'
value:
description: Value to set.
example: 'on'