Hello everyone,
I have trouble with https request,
I have bad data sometimes between buffer read.
len = sizeof(buf) - 1;
memset(buf, 0, sizeof(buf));
ret = esp_tls_conn_read(tls, (char *)buf, len);
I am trying to received a binary file for ota. but sometimes ret < len and I have bad data the next read so my binary is corrupted...
Any idea ? it looks like the error appears at the same place each time. If I copy paste my request in a browser the file is downloaded correctly...
Have a good day.
Arnaud
esp_tls_conn_read bad data
-
- Posts: 17
- Joined: Mon Dec 21, 2020 10:29 am
esp_tls_conn_read bad data
Last edited by campestring on Mon Feb 28, 2022 11:26 am, edited 1 time in total.
-
- Posts: 188
- Joined: Wed Jan 24, 2018 6:51 am
Re: esp_tls_conn_read bad data
Could you please share your application code? Please take a look at https://github.com/espressif/esp-idf/bl ... ple_main.c as starting point here.
Mahavir
https://github.com/mahavirj/
https://github.com/mahavirj/
-
- Posts: 17
- Joined: Mon Dec 21, 2020 10:29 am
Re: esp_tls_conn_read bad data
Thank you I solved the problem, the problem came from the server not the ESP32. Have a good day !
Who is online
Users browsing this forum: Google [Bot], Majestic-12 [Bot] and 128 guests