diff options
author | Evgeny Zinoviev <me@ch1p.io> | 2023-05-11 04:18:08 +0300 |
---|---|---|
committer | Evgeny Zinoviev <me@ch1p.io> | 2023-05-11 04:18:12 +0300 |
commit | 0aba139aeff8ff80757c5d36502413299a0b449e (patch) | |
tree | 2b8e760ff14d4691783eb7c7d341f093199aab82 /src/sensors_mqtt_receiver.py | |
parent | 586d84b0c0a8b4dc1b5057733892b754397234ec (diff) |
mqtt, esp: add new esp8266-based device
Diffstat (limited to 'src/sensors_mqtt_receiver.py')
-rwxr-xr-x | src/sensors_mqtt_receiver.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/sensors_mqtt_receiver.py b/src/sensors_mqtt_receiver.py index 9637690..a377ddd 100755 --- a/src/sensors_mqtt_receiver.py +++ b/src/sensors_mqtt_receiver.py @@ -2,7 +2,7 @@ import paho.mqtt.client as mqtt import re -from home.mqtt import MQTTBase +from home.mqtt import MqttBase from home.config import config from home.mqtt.payload.sensors import Temperature from home.api.types import TemperatureSensorLocation @@ -16,7 +16,7 @@ def get_sensor_type(sensor: str) -> TemperatureSensorLocation: raise ValueError(f'unexpected sensor value: {sensor}') -class MQTTServer(MQTTBase): +class MqttServer(MqttBase): def __init__(self): super().__init__(clean_session=False) self.database = SensorsDatabase() @@ -49,5 +49,5 @@ class MQTTServer(MQTTBase): if __name__ == '__main__': config.load('sensors_mqtt_receiver') - server = MQTTServer() + server = MqttServer() server.connect_and_loop() |