Move modbus base entity to separate module (#126104)

This commit is contained in:
epenet 2024-09-17 15:38:10 +02:00 committed by GitHub
parent 4d140d81f9
commit 93f2b7c8a3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
8 changed files with 7 additions and 7 deletions

View File

@ -24,13 +24,13 @@ from homeassistant.helpers.update_coordinator import (
)
from . import get_hub
from .base_platform import BasePlatform
from .const import (
CALL_TYPE_COIL,
CALL_TYPE_DISCRETE,
CONF_SLAVE_COUNT,
CONF_VIRTUAL_COUNT,
)
from .entity import BasePlatform
from .modbus import ModbusHub
_LOGGER = logging.getLogger(__name__)

View File

@ -43,7 +43,6 @@ from homeassistant.helpers.restore_state import RestoreEntity
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from . import get_hub
from .base_platform import BaseStructPlatform
from .const import (
CALL_TYPE_REGISTER_HOLDING,
CALL_TYPE_WRITE_REGISTER,
@ -86,6 +85,7 @@ from .const import (
CONF_WRITE_REGISTERS,
DataType,
)
from .entity import BaseStructPlatform
from .modbus import ModbusHub
_LOGGER = logging.getLogger(__name__)

View File

@ -22,7 +22,6 @@ from homeassistant.helpers.restore_state import RestoreEntity
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from . import get_hub
from .base_platform import BasePlatform
from .const import (
CALL_TYPE_COIL,
CALL_TYPE_WRITE_COIL,
@ -34,6 +33,7 @@ from .const import (
CONF_STATUS_REGISTER,
CONF_STATUS_REGISTER_TYPE,
)
from .entity import BasePlatform
from .modbus import ModbusHub
PARALLEL_UPDATES = 1

View File

@ -11,8 +11,8 @@ from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from . import get_hub
from .base_platform import BaseSwitch
from .const import CONF_FANS
from .entity import BaseSwitch
from .modbus import ModbusHub
PARALLEL_UPDATES = 1

View File

@ -11,7 +11,7 @@ from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from . import get_hub
from .base_platform import BaseSwitch
from .entity import BaseSwitch
from .modbus import ModbusHub
PARALLEL_UPDATES = 1

View File

@ -27,8 +27,8 @@ from homeassistant.helpers.update_coordinator import (
)
from . import get_hub
from .base_platform import BaseStructPlatform
from .const import CONF_SLAVE_COUNT, CONF_VIRTUAL_COUNT
from .entity import BaseStructPlatform
from .modbus import ModbusHub
_LOGGER = logging.getLogger(__name__)

View File

@ -11,7 +11,7 @@ from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
from . import get_hub
from .base_platform import BaseSwitch
from .entity import BaseSwitch
from .modbus import ModbusHub
PARALLEL_UPDATES = 1