ESP32 - ULP doesn't wake up SOC completely

jesper
Posts: 27
Joined: Thu Nov 09, 2017 4:38 pm

ESP32 - ULP doesn't wake up SOC completely

Postby jesper » Sun May 11, 2025 4:26 pm

I tried the ulp samples and they worked fine.
I then tried to integrate the ULP wakeup in my "regular" code, but the processor doesn't wake up completely, it just writes "ets" or "ets J", so it kinda wakes up, but then nothing more happens.
I commented out virtually all other code, except for a few things and managed to get it to work somewhat.
It's extremely sensitive for other code.
Just uncommenting a function (that is not even called), will make it not work.

C code setup is as the samples, ULP code is simply a wake, halt, set to trigger every 2 seconds.
I have even copied the sdkconfig over from the samples to make sure it wasn't a setting there that messed it up.

It seems to be more sensitive if I call a function than if I write the same code directly in the main file.
Very peculiar.

I'm have tried with ESP-IDF 5.3.1 and 5.4.1

What can be the cause of this?
MagicMicros Co., Ltd. - Rayong, Thailand
Electronics design, PCB layout & programming.

ahsrabrifat
Posts: 201
Joined: Sat Jan 18, 2025 2:31 pm

Re: ESP32 - ULP doesn't wake up SOC completely

Postby ahsrabrifat » Mon May 12, 2025 1:48 pm

The ULP program should not run too long (limit to a few ms).

If your ULP loop is long, you could cause the system to trigger the RTC watchdog.

Try reducing ULP wake frequency temporarily to verify:

Code: Select all

ulp_set_wakeup_period(0, 1000000); // 1 sec

Who is online

Users browsing this forum: Barkrowler, Qwantbot and 2 guests