On Fri, Apr 26, 2024 at 07:58:00PM +0200, Tomek CEDRO wrote:
> Can you please elaborate more on why / how system hangs?

Nothing I can easily answer.
I have a complex codebase for a custom SAM4X board that I ported over to
a custom ESP32 board.
As part of that there is running HTTP code that I ported over from NutOS.
during the initializisation of that the system hangs, however, the parts
that created the hangs weren't importand, so I disabled them.
The service is a listen loop, pthread_create for the tasks.
Now I can do multiple requests via wget.
But when I try with a browser the system hangs.
That could be because the first request is a static romfs files, which I
also get with the browser and the browser will continue with dynamic content.
I get nothing on the console when it hangs.

It also hangs after a while when doing a normal ping.

Didn't wanted to hog other peoples time with that.
It probably is a local problem or because of older nuttx.
With the memory question however I checked that the question was still
valid with current git code.

> Do you know the cause?

No, so far I know multiple triggers.
It could be something hidden in my code, but the common points are mostly
memory related, that's why I digged into that first.

> 
> Does that happen only with your firmware or clean examples too?

Clean code won't easily run on my hardware.

> How often hangs happen?
> 
> Do you get any sort of traces or device just gets unresponsive?

So far it just hangs.
I also just have the console uart for debugging.
On the SAM4X board I would have had SWD for gdb.

> What NuttX version do you work on?

Can't say that either - it was a trunk import a while ago.
That project is old, I just gave up because I didn't need it.
At that time it was hard to get the chips needed and was living on
stocked parts, so I did a test board with ethernet alteratives and once
it did some basic functionality I could get chips.
Now I'm reviving the old prototype because I need something with WiFi
as well.
The same NuttX code worked fine on the SAM4X, so my guess would be that
it is just triggered with the ESP32 or ESP32 specific.
Or it is hardware related...

> I also experience random hangs on ESP32. Not using BLE nor WIFI. But I
> suspect EMC related issues (motor control).

I can't imagine that my hardware is a fault, but I don't know either.
It did run stable with Tasmota, but that was without ethernet in WiFi.
So faar I'm just at the beginning to debug.

-- 
B.Walter <be...@bwct.de> https://www.bwct.de
Modbus/TCP Ethernet I/O Baugruppen, ARM basierte FreeBSD Rechner uvm.

Reply via email to