diff --git a/homeassistant/components/modbus/binary_sensor.py b/homeassistant/components/modbus/binary_sensor.py index 00ed9ccafb7..28d1be24587 100644 --- a/homeassistant/components/modbus/binary_sensor.py +++ b/homeassistant/components/modbus/binary_sensor.py @@ -107,13 +107,9 @@ class ModbusBinarySensor(BasePlatform, RestoreEntity, BinarySensorEntity): """Update the state of the sensor.""" # do not allow multiple active calls to the same platform - if self._call_active: - return - self._call_active = True result = await self._hub.async_pb_call( self._slave, self._address, self._count, self._input_type ) - self._call_active = False if result is None: self._attr_available = False self._result = [] diff --git a/homeassistant/components/modbus/entity.py b/homeassistant/components/modbus/entity.py index 2d99d8f382c..35b7c02aa05 100644 --- a/homeassistant/components/modbus/entity.py +++ b/homeassistant/components/modbus/entity.py @@ -88,7 +88,6 @@ class BasePlatform(Entity): self._input_type = entry[CONF_INPUT_TYPE] self._value: str | None = None self._scan_interval = int(entry[CONF_SCAN_INTERVAL]) - self._call_active = False self._cancel_timer: Callable[[], None] | None = None self._cancel_call: Callable[[], None] | None = None @@ -389,13 +388,9 @@ class BaseSwitch(BasePlatform, ToggleEntity, RestoreEntity): return # do not allow multiple active calls to the same platform - if self._call_active: - return - self._call_active = True result = await self._hub.async_pb_call( self._slave, self._verify_address, 1, self._verify_type ) - self._call_active = False if result is None: self._attr_available = False return