mirror of
https://github.com/jomjol/AI-on-the-edge-device.git
synced 2026-01-31 14:51:02 +03:00
add debug, changed upload size to 8MB
This commit is contained in:
@@ -49,8 +49,8 @@ extern "C" {
|
|||||||
|
|
||||||
/* Max size of an individual file. Make sure this
|
/* Max size of an individual file. Make sure this
|
||||||
* value is same as that set in upload_script.html */
|
* value is same as that set in upload_script.html */
|
||||||
#define MAX_FILE_SIZE (2000*1024) // 200 KB
|
#define MAX_FILE_SIZE (8000*1024) // 8 MB
|
||||||
#define MAX_FILE_SIZE_STR "2000KB"
|
#define MAX_FILE_SIZE_STR "8MB"
|
||||||
|
|
||||||
|
|
||||||
/* Scratch buffer size */
|
/* Scratch buffer size */
|
||||||
@@ -489,7 +489,7 @@ static esp_err_t upload_post_handler(httpd_req_t *req)
|
|||||||
|
|
||||||
while (remaining > 0) {
|
while (remaining > 0) {
|
||||||
|
|
||||||
ESP_LOGI(TAG_FILESERVER, "Remaining size : %d", remaining);
|
//ESP_LOGI(TAG_FILESERVER, "Remaining size : %d", remaining);
|
||||||
/* Receive the file part by part into a buffer */
|
/* Receive the file part by part into a buffer */
|
||||||
if ((received = httpd_req_recv(req, buf, MIN(remaining, SCRATCH_BUFSIZE))) <= 0) {
|
if ((received = httpd_req_recv(req, buf, MIN(remaining, SCRATCH_BUFSIZE))) <= 0) {
|
||||||
if (received == HTTPD_SOCK_ERR_TIMEOUT) {
|
if (received == HTTPD_SOCK_ERR_TIMEOUT) {
|
||||||
@@ -757,7 +757,7 @@ std::string unzip_new(std::string _in_zip_file, std::string _target_zip, std::st
|
|||||||
p = mz_zip_reader_extract_file_to_heap(&zip_archive, archive_filename, &uncomp_size, 0);
|
p = mz_zip_reader_extract_file_to_heap(&zip_archive, archive_filename, &uncomp_size, 0);
|
||||||
if (!p)
|
if (!p)
|
||||||
{
|
{
|
||||||
printf("mz_zip_reader_extract_file_to_heap() failed!\n");
|
printf("mz_zip_reader_extract_file_to_heap() failed on file %s\n", archive_filename);
|
||||||
mz_zip_reader_end(&zip_archive);
|
mz_zip_reader_end(&zip_archive);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user