Added ota hostname

This commit is contained in:
Nis Wechselberg 2017-09-26 00:11:17 +02:00
parent b32b5dbdee
commit 001219c80e
11 changed files with 329 additions and 16 deletions

View file

@ -2,12 +2,15 @@
const char* ssid = "http://kiel.freifunk.net/";
const char* password = "";
// OTA Hostname
const char* ota_hostname = "TeufelSub";
// MQTT Broker
const char* mqtt_server = "broker.mqtt-dashboard.com";
// Device identification
const char* mqtt_device = "livingroom/teufelSub";
const char* mqtt_device = "teufelSub";
// MQTT topics
const char* mqtt_topic_power = "livingroom/teufelSub/power";
const char* mqtt_topic_powerState = "livingroom/teufelSub/powerState";
const char* mqtt_topic_power = "teufelSub/power";
const char* mqtt_topic_powerState = "teufelSub/powerState";

View file

@ -108,7 +108,7 @@ void setup_wifi() {
Serial.print("My IP address: ");
Serial.println(WiFi.localIP());
}
ArduinoOTA.setHostname("esp8266-TeufelSub");
ArduinoOTA.setHostname(ota_hostname);
ArduinoOTA.begin();
}