mirror of
https://github.com/Laxilef/OTGateway.git
synced 2026-11-23 23:03:06 +05:00
fix: use unique device defaults and MQTT client identifiers
Allow empty hostname and MQTT prefix defaults to use chip-derived names. Use the configured MQTT prefix as the broker client identifier.
This commit is contained in:
1 parent
7e1d0ddff2
commit
d6e1ccb22b
2 files changed
+3
-3
No files matched your search
+2
-2
@@ -5,7 +5,7 @@ serial_enabled = true
|
|||||||
serial_baud = 115200
|
serial_baud = 115200
|
||||||
webserial_enabled = true
|
webserial_enabled = true
|
||||||
log_level = ESP_LOG_INFO
|
log_level = ESP_LOG_INFO
|
||||||
hostname = opentherm
|
hostname =
|
||||||
|
|
||||||
ap_ssid = OpenTherm Gateway
|
ap_ssid = OpenTherm Gateway
|
||||||
ap_password = otgateway123456
|
ap_password = otgateway123456
|
||||||
@@ -21,4 +21,4 @@ mqtt_server =
|
|||||||
mqtt_port = 1883
|
mqtt_port = 1883
|
||||||
mqtt_user =
|
mqtt_user =
|
||||||
mqtt_password =
|
mqtt_password =
|
||||||
mqtt_prefix = opentherm
|
mqtt_prefix =
|
||||||
+1
-1
@@ -715,7 +715,7 @@ static void connect() {
|
|||||||
.keepAlive = static_cast<uint16_t>(settings.mqtt.interval * 10u),
|
.keepAlive = static_cast<uint16_t>(settings.mqtt.interval * 10u),
|
||||||
.username = settings.mqtt.user,
|
.username = settings.mqtt.user,
|
||||||
.password = settings.mqtt.password,
|
.password = settings.mqtt.password,
|
||||||
.clientId = networkSettings.hostname,
|
.clientId = settings.mqtt.prefix,
|
||||||
.willTopic = mqttTopic("status"),
|
.willTopic = mqttTopic("status"),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user