Add device info for sonos (#16263)

* Add device info for sonos

* Sets
This commit is contained in:
Paulus Schoutsen 2018-08-29 16:27:08 +02:00 committed by GitHub
parent 3934f7bf3a
commit 16a885824d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -388,6 +388,18 @@ class SonosDevice(MediaPlayerDevice):
"""Return the name of the device."""
return self._name
@property
def device_info(self):
"""Return information about the device."""
return {
'identifiers': {
(SONOS_DOMAIN, self._unique_id)
},
'name': self._name,
'model': self._model.replace("Sonos ", ""),
'manufacturer': 'Sonos',
}
@property
@soco_coordinator
def state(self):