Skip to content

Commit b5213b0

Browse files
caco3CaCO3jomjol
authored
Update platform-espressif32 to 6.5.0 (jomjol#2770)
* Update ESP IDF to 6.5.0 * Migration to new IDF * Correct smtp vor v5.1 --------- Co-authored-by: CaCO3 <[email protected]> Co-authored-by: jomjol <[email protected]>
1 parent 473e458 commit b5213b0

File tree

8 files changed

+17
-22
lines changed

8 files changed

+17
-22
lines changed

code/components/jomjol_fileserver_ota/miniz/miniz.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@
153153
/*#define MINIZ_NO_MALLOC */
154154

155155
#ifdef MINIZ_NO_INFLATE_APIS
156-
#define MINIZ_NO_ARCHIVE_APIS
156+
//#define MINIZ_NO_ARCHIVE_APIS
157157
#endif
158158

159159
#ifdef MINIZ_NO_DEFLATE_APIS

code/components/jomjol_fileserver_ota/server_file.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -547,7 +547,7 @@ static esp_err_t download_get_handler(httpd_req_t *req)
547547
/* Get value of expected key from query string */
548548
if (httpd_query_key_value(buf, "readonly", param, sizeof(param)) == ESP_OK) {
549549
ESP_LOGI(TAG, "Found URL query parameter => readonly=%s", param);
550-
readonly = param && strcmp(param,"true")==0;
550+
readonly = (strcmp(param,"true") == 0);
551551
}
552552
}
553553
}

code/components/jomjol_helper/sdcard_check.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
#include <stdio.h>
44
#include <stdbool.h>
55
#include <stdint.h>
6+
#include <unistd.h>
67
#include <inttypes.h>
78
#include <sys/stat.h>
89

code/components/jomjol_time_sntp/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ FILE(GLOB_RECURSE app_sources ${CMAKE_CURRENT_SOURCE_DIR}/*.*)
22

33
idf_component_register(SRCS ${app_sources}
44
INCLUDE_DIRS "."
5-
REQUIRES esp-tflite-micro jomjol_logfile jomjol_configfile)
5+
REQUIRES esp_netif esp-tflite-micro jomjol_logfile jomjol_configfile)
66

77

code/components/jomjol_time_sntp/time_sntp.cpp

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@
1010
#include "esp_log.h"
1111
#include "esp_attr.h"
1212
#include "esp_sleep.h"
13-
#include "esp_sntp.h"
13+
#include "esp_netif_sntp.h"
14+
1415
#include "../../include/defines.h"
1516

1617
#include "ClassLogFile.h"
@@ -274,21 +275,13 @@ bool setupTime() {
274275

275276
if (useNtp) {
276277
LogFile.WriteToFile(ESP_LOG_INFO, TAG, "Configuring NTP Client...");
277-
sntp_setoperatingmode(SNTP_OPMODE_POLL);
278-
sntp_setservername(0, timeServer.c_str());
279-
sntp_set_time_sync_notification_cb(time_sync_notification_cb);
280-
setTimeZone(timeZone);
278+
esp_sntp_config_t config = ESP_NETIF_SNTP_DEFAULT_CONFIG(timeServer.c_str());
279+
config.sync_cb = time_sync_notification_cb;
280+
esp_netif_sntp_init(&config);
281281

282-
sntp_init();
283-
/*
284-
if (!wait_for_timesync())
285-
{
286-
LogFile.WriteToFile(ESP_LOG_INFO, TAG, "Timesync at startup failed.");
287-
}
288-
*/
282+
setTimeZone(timeZone);
289283
}
290284

291-
292285
/* The RTC keeps the time after a restart (Except on Power On or Pin Reset)
293286
* There should only be a minor correction through NTP */
294287

@@ -297,6 +290,7 @@ bool setupTime() {
297290
localtime_r(&now, &timeinfo);
298291
strftime(strftime_buf, sizeof(strftime_buf), "%Y-%m-%d %H:%M:%S", &timeinfo);
299292

293+
300294
if (getTimeIsSet()) {
301295
LogFile.WriteToFile(ESP_LOG_INFO, TAG, "Time is already set: " + std::string(strftime_buf));
302296
}

code/components/jomjol_wlan/connect_wlan.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,7 +378,7 @@ void wifi_scan(void)
378378
else {
379379
if (esp_wifi_scan_get_ap_records(&max_number_of_ap_found, wifi_ap_records) != ESP_OK) { // Retrieve results (and free internal heap)
380380
LogFile.WriteToFile(ESP_LOG_ERROR, TAG, "wifi_scan: esp_wifi_scan_get_ap_records: Error retrieving datasets");
381-
delete wifi_ap_records;
381+
delete[] wifi_ap_records;
382382
return;
383383
}
384384
}
@@ -401,7 +401,7 @@ void wifi_scan(void)
401401
APWithBetterRSSI = true;
402402
}
403403
}
404-
delete wifi_ap_records;
404+
delete[] wifi_ap_records;
405405
}
406406

407407

code/dependencies.lock

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
manifest_hash: 63f5c6c9f0bcebc7b9ca12d2aa8b26b2c5f5218d377dc4b2375d9b9ca1df7815
2-
target: esp32
3-
version: 1.0.0
1+
manifest_hash: 63f5c6c9f0bcebc7b9ca12d2aa8b26b2c5f5218d377dc4b2375d9b9ca1df7815
2+
target: esp32
3+
version: 1.0.0

code/platformio.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
[common:esp32-idf]
2121
extends = common:idf
22-
platform = platformio/espressif32 @ 6.3.2
22+
platform = platformio/espressif32 @ 6.5.0
2323
framework = espidf
2424
lib_deps =
2525
${common:idf.lib_deps}

0 commit comments

Comments
 (0)