Closed DreamPWJ closed 1 year ago
hi @DreamPWJ
Do you have this assert after ota fails? After ota succeeds, you need to call this function esp_restart
.
@xueyunfei998 I did a reboot, I don't think we're talking about a problem, please read the title and content section
hi @DreamPWJ Can I reproduce this problem locally, or which example in idf do you use to reproduce this bug?
I wonder if the esp_https_ota method only works for wifi networks, not for nb-iot networks? @xueyunfei998
@DreamPWJ I don't know about NB_IOT network. Do NB_iot devices have ip addresses? Do need tcpip protocol stack?
@DreamPWJ If NBIOT network has no ip address probability, ota function should not be supported.
@xueyunfei998 NB-IOT has ip
@DreamPWJ Please upload the complete test log.
@DreamPWJ How is the NBiot device connected with espC3? Can you simply draw a circuit diagram?
@DreamPWJ How is the NBiot device connected with espC3? Can you simply draw a circuit diagram?
uart AT command
@DreamPWJ Have you found a solution? I'm getting the same error message on an ESP32 with SIM800 GSM module.
Hi. I'm having the same problem using ESP32 with the ENC28J60 module and InfluxDB client.
I am able to see this warning when compiling:
warning: "ntohs" redefined
I don't know really if this warning can be related to the bug discussed here.
Thanks, Gabriel.
know really if this warning can be related to
@DreamPWJ Have you found a solution? I'm getting the same error message on an ESP32 with SIM800 GSM module. hello , ı faced same error how can I solve ? did you solve ?
@DreamPWJ Have you found a solution? I'm getting the same error message on an ESP32 with SIM800 GSM module.
@marcosterland Have you found a solution? I'm getting the same error message on an ESP32 with SIM800 GSM module.
@DreamPWJ¿Has encontrado una solución? Recibo el mismo mensaje de error en un ESP32 con módulo SIM800 GSM.
@marcosterland¿Has encontrado una solución? Recibo el mismo mensaje de error en un ESP32 con módulo SIM800 GSM.
Hola, pudiste resolverlo? tengo el mismo inconveniente
Yep, I'm getting this error when trying to open a socket. I'm using an az-delivery dev kit V4. No complicating NB-IoT or SIMCom module issues.
Short background: Using PlatformIO I have another ESP32 project where httpClient retrieves ~2kb of JSON reliably then crashes after ~630 consecutive requests - every time. Memory leak perhaps? Error messages suggested issue was in WiFiClient.cpp so I want to write my own tcp client to see if I can beat this 630 request limit. Simply creating a socket threw this error: assert failed: tcpip_send_msg_wait_sem IDF/components/lwip/lwip/src/api/tcpip.c:455 (Invalid mbox)
Here's what you need to reproduce the problem:
/ Insert this to run only once in loop() / if ((m_sockfd = socket(AF_INET, SOCK_STREAM, 0)) < 0) { return; } setsockopt(m_sockfd, SOL_SOCKET, SO_KEEPALIVE, 0, 0);
Code compiles fine in the Expressive 6.0.1 but crashes on the ESP32 when it hits if ((m_sockfd = socket(AF_INET, SOCK_STREAM, 0)) < 0) {
I don't try connecting to any tcp server - no point if I can't get past socket creation. Any suggestions to get past this are most welcome.
Oops. Didn't have the WiFi up. Now the socket opens. Maybe you guys are having issues because your NB-IoT & SIM800 modules have not connected to the network?
@superf-lewis i dont understand , can you solve , if you solve , can you write solution please
@ceren16 I don't think I solved anything. I made a mistake for my case. If the tcp/ip stack is not initialised, then there is nothing to open a socket on. Do something that opens a socket and, "boom", assert failed: tcpip_send_msg_wait_sem IDF/components/lwip/lwip/src/api/tcpip.c:455 (Invalid mbox) I assumed that creating a socket without the stack initialised might cause some grumbles and warnings but not a full on-abort and reboot.
In my case, I had not started WiFi. Starting WiFi initialises the tcp/ip stack. So, if I get the same error as you guys when I do tcp/ip stuff before the stack is initialised, perhaps the same thing is happening to you? If your project has not triggered something that initialises the tcp/ip stack and it tries to do some socket-related operation, then it crashes. Do you start the WiFi before doing anything on the SIM800?
My experience with a SIM800 was on a full Linux OS. The pppd issued AT commands over the serial interface to start a ppp session, then it magically tied the data stream into the tcp/ip stack (I wish I knew how that mechanism worked). The ESP32 is a lot less than a full Linux OS. The SIM800 has it's own tcp/ip stack which you can drive with AT commands (kind of like steering from the back seat). I have not tried this but it's how I assume you'd do it with something like an ESP32. ...Unless there is some driver to connect/integrate the SIM800 data stream to the ESP32 tcp/ip stack that I don't know about (there's plenty I don't know about).
Sorry, this is no solution. I can only suggest you look at what your application is doing and make sure it doesn't do any tcp/ip stuff before the stack has been started. Check and/or rearrange the order you start things in Setup(). Good luck!
Oops. Didn't have the WiFi up. Now the socket opens. Maybe you guys are having issues because your NB-IoT & SIM800 modules have not connected to the network?
Thanks! I was suffering from the same issue, and found that I didn't setup the Wi-Fi either. After Wi-Fi is setup, it works fine.
I had this issue, came here, and it turned out to be that I set too short of a password on the ESP32 - DevKitC v1. Once i changed it from 5 chars to 8 chars, it worked fine. Is there some WPA protocol thing that must be dependent?
Had a similar issue, it was caused by a memory leak, after some time my code didn`t have any heap avaiable
How did you solve it?
Sorry for the bump, I had a similar issue with my ESP32-Cam and found a solution to the issue. After a bit of research it seemed the problem comes from a lack of a TCPIP stack init. The way I solved this was by initializing the WiFi library and setting the modem mode to station (in my application).
I hope this helps!
Answers checklist.
IDF version.
4.4
Operating System used.
Windows
How did you build your project?
Command line with CMake
If you are using Windows, please specify command line type.
No response
Development Kit.
ESP32-C3
Power Supply used.
USB
What is the expected behavior?
NB-IOT use esp_https_ota
What is the actual behavior?
assert failed: tcpip_send_msg_wait_sem IDF/components/lwip/lwip/src/api/tcpip.c:455 (Invalid mbox)
Steps to reproduce.
Debug Logs.
More Information.
No response