Skip to content

Commit d884b5c

Browse files
committed
Update logging
1 parent a00c553 commit d884b5c

File tree

1 file changed

+5
-9
lines changed

1 file changed

+5
-9
lines changed

src/main.cpp

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ void setup() {
6464
#endif
6565

6666
LOGI(TAG, "SafeBoot Version: %s", __COMPILED_APP_VERSION__);
67-
LOGI(TAG, "Chip ID: %s", getChipIDStr().c_str());
6867

6968
// Set next boot partition
7069
const esp_partition_t* partition = esp_partition_find_first(esp_partition_type_t::ESP_PARTITION_TYPE_APP, esp_partition_subtype_t::ESP_PARTITION_SUBTYPE_APP_OTA_0, nullptr);
@@ -105,7 +104,7 @@ void setup() {
105104

106105
espConnect.listen([](Mycila::ESPConnect::State previous, Mycila::ESPConnect::State state) {
107106
if (state == Mycila::ESPConnect::State::NETWORK_TIMEOUT) {
108-
LOGW(TAG, "Connect timeout! Starting AP mode instead...");
107+
LOGW(TAG, "Connect timeout! Starting AP mode...");
109108
// if ETH DHCP times out, we start AP mode
110109
espConnectConfig.apMode = true;
111110
espConnect.setConfig(espConnectConfig);
@@ -115,19 +114,18 @@ void setup() {
115114
// connect...
116115
espConnect.begin(espConnectConfig.hostname.c_str(), "", espConnectConfig);
117116

118-
LOGI(TAG, "Connected to network!");
119117
LOGI(TAG, "IP Address: %s", espConnect.getIPAddress().toString().c_str());
120118
LOGI(TAG, "Hostname: %s", espConnect.getHostname().c_str());
121119
if (espConnect.getWiFiSSID().length()) {
122-
LOGI(TAG, "WiFi SSID: %s", espConnect.getWiFiSSID().c_str());
120+
LOGI(TAG, "SSID: %s", espConnect.getWiFiSSID().c_str());
123121
}
124122
if (espConnectConfig.apMode) {
125123
LOGI(TAG, "Access Point: %s", espConnect.getAccessPointSSID().c_str());
126124
}
127125

128-
// starte http
129-
LOGI(TAG, "Starting HTTP server...");
126+
// start http
130127
webServer.begin();
128+
LOGI(TAG, "Web Server started");
131129

132130
#ifndef MYCILA_SAFEBOOT_NO_MDNS
133131
// Start mDNS
@@ -136,13 +134,11 @@ void setup() {
136134
#endif
137135

138136
// Start OTA
139-
LOGI(TAG, "Starting OTA server...");
140137
ArduinoOTA.setHostname(espConnectConfig.hostname.c_str());
141138
ArduinoOTA.setRebootOnSuccess(true);
142139
ArduinoOTA.setMdnsEnabled(true);
143140
ArduinoOTA.begin();
144-
145-
LOGI(TAG, "Done!");
141+
LOGI(TAG, "Arduino OTA Server started on port 3232");
146142
}
147143

148144
void loop() {

0 commit comments

Comments
 (0)