Mapping to dos
This commit is contained in:
@@ -2354,7 +2354,7 @@ script:
|
|||||||
return not retry;
|
return not retry;
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef ARDUINO
|
#ifdef ARDUINO // arduino # To do: Move to Nextion component on ESPHome
|
||||||
auto upload_by_chunks_arduino = [&](HTTPClient *http, const std::string &url, int range_start) -> int
|
auto upload_by_chunks_arduino = [&](HTTPClient *http, const std::string &url, int range_start) -> int
|
||||||
{
|
{
|
||||||
static const char *const TAG = "script.upload_tft.upload_by_chunks_arduino";
|
static const char *const TAG = "script.upload_tft.upload_by_chunks_arduino";
|
||||||
@@ -2618,7 +2618,7 @@ script:
|
|||||||
|
|
||||||
return upload_end_(false);
|
return upload_end_(false);
|
||||||
};
|
};
|
||||||
#elif defined(ESP_PLATFORM) // esp-idf
|
#elif defined(ESP_PLATFORM) // esp-idf # To do: Move to Nextion component on ESPHome
|
||||||
auto upload_by_chunks_esp_idf = [&](const std::string &url, int range_start) -> int
|
auto upload_by_chunks_esp_idf = [&](const std::string &url, int range_start) -> int
|
||||||
{
|
{
|
||||||
int range_end;
|
int range_end;
|
||||||
@@ -2744,7 +2744,7 @@ script:
|
|||||||
};
|
};
|
||||||
esp_http_client_handle_t http = esp_http_client_init(&config);
|
esp_http_client_handle_t http = esp_http_client_init(&config);
|
||||||
esp_http_client_set_header(http, "Range", "bytes=0-255");
|
esp_http_client_set_header(http, "Range", "bytes=0-255");
|
||||||
esp_http_client_set_header(http, "User-Agent", "curl/7.68.0");
|
esp_http_client_set_header(http, "User-Agent", "curl/7.68.0"); // Is this required?
|
||||||
|
|
||||||
int tries = 1;
|
int tries = 1;
|
||||||
int status = esp_http_client_perform(http);
|
int status = esp_http_client_perform(http);
|
||||||
|
|||||||
Reference in New Issue
Block a user