Hello,
Till yesterday i was working on HA 0.77.3 and all works good.
After i updated to 0.81.1, my broadlink mp1 doesn’t work.
Thhis is my switch config file:
- platform: broadlink
host: 192.168.1.142
mac: '34:EA:34:XX:XX:XX'
type: mp1
friendly_name: 'Regleta'
slots:
slot_1: 'GW_Xiaomi'
slot_2: 'TV_Play'
slot_3: 'AppleTV'
slot_4: 'Decoder_RU'
here my logs:
2018-10-29 20:54:07 ERROR (MainThread) [homeassistant.helpers.entity] Update for switch.appletv fails
Traceback (most recent call last):
File "/usr/src/app/homeassistant/helpers/entity.py", line 221, in async_update_ha_state
await self.async_device_update()
File "/usr/src/app/homeassistant/helpers/entity.py", line 349, in async_device_update
await self.hass.async_add_executor_job(self.update)
File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 358, in update
self._parent_device.update()
File "/usr/src/app/homeassistant/util/__init__.py", line 324, in wrapper
result = method(*args, **kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 377, in update
self._update()
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 382, in _update
states = self._device.check_power()
File "/usr/local/lib/python3.6/site-packages/broadlink/__init__.py", line 369, in check_power
data['s1'] = bool(state & 0x01)
TypeError: unsupported operand type(s) for &: 'NoneType' and 'int'
2018-10-29 20:54:07 ERROR (MainThread) [homeassistant.helpers.entity] Update for switch.gw_xiaomi fails
Traceback (most recent call last):
File "/usr/src/app/homeassistant/helpers/entity.py", line 221, in async_update_ha_state
await self.async_device_update()
File "/usr/src/app/homeassistant/helpers/entity.py", line 349, in async_device_update
await self.hass.async_add_executor_job(self.update)
File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 358, in update
self._parent_device.update()
File "/usr/src/app/homeassistant/util/__init__.py", line 324, in wrapper
result = method(*args, **kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 377, in update
self._update()
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 382, in _update
states = self._device.check_power()
File "/usr/local/lib/python3.6/site-packages/broadlink/__init__.py", line 369, in check_power
data['s1'] = bool(state & 0x01)
TypeError: unsupported operand type(s) for &: 'NoneType' and 'int'
2018-10-29 20:54:07 ERROR (MainThread) [homeassistant.helpers.entity] Update for switch.tv_play fails
Traceback (most recent call last):
File "/usr/src/app/homeassistant/helpers/entity.py", line 221, in async_update_ha_state
await self.async_device_update()
File "/usr/src/app/homeassistant/helpers/entity.py", line 349, in async_device_update
await self.hass.async_add_executor_job(self.update)
File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 358, in update
self._parent_device.update()
File "/usr/src/app/homeassistant/util/__init__.py", line 324, in wrapper
result = method(*args, **kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 377, in update
self._update()
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 382, in _update
states = self._device.check_power()
File "/usr/local/lib/python3.6/site-packages/broadlink/__init__.py", line 369, in check_power
data['s1'] = bool(state & 0x01)
TypeError: unsupported operand type(s) for &: 'NoneType' and 'int'
2018-10-29 20:54:07 ERROR (MainThread) [homeassistant.helpers.entity] Update for switch.decoder_ru fails
Traceback (most recent call last):
File "/usr/src/app/homeassistant/helpers/entity.py", line 221, in async_update_ha_state
await self.async_device_update()
File "/usr/src/app/homeassistant/helpers/entity.py", line 349, in async_device_update
await self.hass.async_add_executor_job(self.update)
File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 358, in update
self._parent_device.update()
File "/usr/src/app/homeassistant/util/__init__.py", line 324, in wrapper
result = method(*args, **kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 377, in update
self._update()
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 382, in _update
states = self._device.check_power()
File "/usr/local/lib/python3.6/site-packages/broadlink/__init__.py", line 369, in check_power
data['s1'] = bool(state & 0x01)
TypeError: unsupported operand type(s) for &: 'NoneType' and 'int'
2018-10-29 20:54:23 ERROR (MainThread) [homeassistant.helpers.entity] Update for switch.tv_play fails
Traceback (most recent call last):
File "/usr/src/app/homeassistant/helpers/entity.py", line 221, in async_update_ha_state
await self.async_device_update()
File "/usr/src/app/homeassistant/helpers/entity.py", line 349, in async_device_update
await self.hass.async_add_executor_job(self.update)
File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 358, in update
self._parent_device.update()
File "/usr/src/app/homeassistant/util/__init__.py", line 324, in wrapper
result = method(*args, **kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 377, in update
self._update()
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 382, in _update
states = self._device.check_power()
File "/usr/local/lib/python3.6/site-packages/broadlink/__init__.py", line 369, in check_power
data['s1'] = bool(state & 0x01)
TypeError: unsupported operand type(s) for &: 'NoneType' and 'int'
2018-10-29 20:54:30 ERROR (MainThread) [homeassistant.helpers.entity] Update for switch.tv_play fails
Traceback (most recent call last):
File "/usr/src/app/homeassistant/helpers/entity.py", line 221, in async_update_ha_state
await self.async_device_update()
File "/usr/src/app/homeassistant/helpers/entity.py", line 349, in async_device_update
await self.hass.async_add_executor_job(self.update)
File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 358, in update
self._parent_device.update()
File "/usr/src/app/homeassistant/util/__init__.py", line 324, in wrapper
result = method(*args, **kwargs)
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 377, in update
self._update()
File "/usr/src/app/homeassistant/components/switch/broadlink.py", line 382, in _update
states = self._device.check_power()
File "/usr/local/lib/python3.6/site-packages/broadlink/__init__.py", line 369, in check_power
data['s1'] = bool(state & 0x01)
TypeError: unsupported operand type(s) for &: 'NoneType' and 'int'
Something changed in last updated about configuration?
thanks