This commit is contained in:
e2002
2023-05-19 14:43:27 +03:00
parent 57a5666868
commit b975057b3f
25 changed files with 323 additions and 98 deletions

View File

@@ -144,7 +144,7 @@ class yoradioDevice(MediaPlayerEntity):
if js['on']==1:
self._state = STATE_PLAYING if js['status']==1 else STATE_IDLE
else:
self._state = STATE_OFF
self._state = STATE_PLAYING if js['status']==1 else STATE_OFF
self._current_source = str(js['station']) + '. ' + js['name']
try:
self.async_schedule_update_ha_state()