mirror of
https://github.com/Threnklyn/esphome-dev.git
synced 2026-06-07 05:13:31 +02:00
add-black (#1593)
* Add black Update pre commit Update pre commit add empty line * Format with black
This commit is contained in:
committed by
GitHub
parent
2b60b0f1fa
commit
69879920eb
@@ -4,18 +4,20 @@ from esphome import pins
|
||||
from esphome.const import CONF_ID, CONF_PIN
|
||||
|
||||
MULTI_CONF = True
|
||||
AUTO_LOAD = ['sensor']
|
||||
AUTO_LOAD = ["sensor"]
|
||||
|
||||
CONF_ONE_WIRE_ID = 'one_wire_id'
|
||||
dallas_ns = cg.esphome_ns.namespace('dallas')
|
||||
DallasComponent = dallas_ns.class_('DallasComponent', cg.PollingComponent)
|
||||
ESPOneWire = dallas_ns.class_('ESPOneWire')
|
||||
CONF_ONE_WIRE_ID = "one_wire_id"
|
||||
dallas_ns = cg.esphome_ns.namespace("dallas")
|
||||
DallasComponent = dallas_ns.class_("DallasComponent", cg.PollingComponent)
|
||||
ESPOneWire = dallas_ns.class_("ESPOneWire")
|
||||
|
||||
CONFIG_SCHEMA = cv.Schema({
|
||||
cv.GenerateID(): cv.declare_id(DallasComponent),
|
||||
cv.GenerateID(CONF_ONE_WIRE_ID): cv.declare_id(ESPOneWire),
|
||||
cv.Required(CONF_PIN): pins.gpio_input_pin_schema,
|
||||
}).extend(cv.polling_component_schema('60s'))
|
||||
CONFIG_SCHEMA = cv.Schema(
|
||||
{
|
||||
cv.GenerateID(): cv.declare_id(DallasComponent),
|
||||
cv.GenerateID(CONF_ONE_WIRE_ID): cv.declare_id(ESPOneWire),
|
||||
cv.Required(CONF_PIN): pins.gpio_input_pin_schema,
|
||||
}
|
||||
).extend(cv.polling_component_schema("60s"))
|
||||
|
||||
|
||||
def to_code(config):
|
||||
|
||||
Reference in New Issue
Block a user