Move imports to top for tof (#29203)
* Move imports to top for tof * Isorted importspull/29208/head
parent
7b33e57e86
commit
0e4920d6a1
|
@ -1,15 +1,16 @@
|
|||
"""Platform for Time of Flight sensor VL53L1X from STMicroelectronics."""
|
||||
|
||||
import asyncio
|
||||
import logging
|
||||
from functools import partial
|
||||
import logging
|
||||
|
||||
from VL53L1X2 import VL53L1X # pylint: disable=import-error
|
||||
import voluptuous as vol
|
||||
|
||||
from homeassistant.components.sensor import PLATFORM_SCHEMA
|
||||
import homeassistant.helpers.config_validation as cv
|
||||
from homeassistant.components import rpi_gpio
|
||||
from homeassistant.components.sensor import PLATFORM_SCHEMA
|
||||
from homeassistant.const import CONF_NAME
|
||||
import homeassistant.helpers.config_validation as cv
|
||||
from homeassistant.helpers.entity import Entity
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
@ -51,7 +52,6 @@ def init_tof_1(xshut):
|
|||
|
||||
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
|
||||
"""Reset and initialize the VL53L1X ToF Sensor from STMicroelectronics."""
|
||||
from VL53L1X2 import VL53L1X # pylint: disable=import-error
|
||||
|
||||
name = config.get(CONF_NAME)
|
||||
bus_number = config.get(CONF_I2C_BUS)
|
||||
|
|
Loading…
Reference in New Issue