update
This commit is contained in:
parent
be32fda966
commit
46160694af
4
MQTT.py
4
MQTT.py
|
@ -34,8 +34,8 @@ class MQTTClient:
|
|||
self.topic = topic
|
||||
self.username = username
|
||||
self.password = password
|
||||
self.client = mqtt.Client(client_id=device_name)
|
||||
self.client.username_pw_set(self.username, self.password)
|
||||
self.client = mqtt.Client()
|
||||
# self.client.username_pw_set(self.username, self.password)
|
||||
self.client.on_connect = self.on_connect
|
||||
self.client.on_message = self.on_message
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ class DataUploadClient:
|
|||
self.topic = topic
|
||||
self.username = username
|
||||
self.password = password
|
||||
self.client = mqtt.Client(client_id=device_name)
|
||||
self.client = mqtt.Client()
|
||||
self.client.username_pw_set(self.username, self.password)
|
||||
self.client.on_connect = self.on_connect
|
||||
self.client.on_disconnect = self.on_disconnect
|
||||
|
|
Loading…
Reference in New Issue