Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ESP32 S3 Wroom Startup is too slow (IDFGH-14081) #14895

Open
3 tasks done
weoiss1998 opened this issue Nov 15, 2024 · 11 comments
Open
3 tasks done

ESP32 S3 Wroom Startup is too slow (IDFGH-14081) #14895

weoiss1998 opened this issue Nov 15, 2024 · 11 comments
Labels
Status: Opened Issue is new Type: Bug bugs in IDF

Comments

@weoiss1998
Copy link

Answers checklist.

  • I have read the documentation ESP-IDF Programming Guide and the issue is not addressed there.
  • I have updated my IDF branch (master or release) to the latest version and checked that the issue is present there.
  • I have searched the issue tracker for a similar issue and not found a similar issue.

IDF version.

5.3.1 and 5.2.3

Espressif SoC revision.

ESP32S3 Wroom

Operating System used.

Windows

How did you build your project?

VS Code IDE

If you are using Windows, please specify command line type.

None

Development Kit.

ESP32 S3 Wroom Dev Kit

Power Supply used.

USB

What is the expected behavior?

https://docs.espressif.com/projects/esp-techpedia/en/latest/esp-friends/advanced-development/performance/reduce-boot-time.html says after optimizing the startup will be around 27ms.

What is the actual behavior?

In my tests it's at the minimum of 56ms.

Steps to reproduce.

Make optimizations of https://docs.espressif.com/projects/esp-techpedia/en/latest/esp-friends/advanced-development/performance/reduce-boot-time.html and check when a pin goes high.

Debug Logs.

No response

More Information.

I tried it with 5.2.3 and 5.3.1. There is practically no difference.
Here is a picture of my logic analyzer:
grafik

@weoiss1998 weoiss1998 added the Type: Bug bugs in IDF label Nov 15, 2024
@github-actions github-actions bot changed the title ESP32 S3 Wroom Startup is too slow ESP32 S3 Wroom Startup is too slow (IDFGH-14081) Nov 15, 2024
@espressif-bot espressif-bot added the Status: Opened Issue is new label Nov 15, 2024
@zztiger123
Copy link
Collaborator

Hi @weoiss1998

May I know if you have done every optimization? Especially Disable Boot ROM Log Printing. Need to burn refuses :
企业微信截图_17318958393243

@weoiss1998
Copy link
Author

weoiss1998 commented Nov 18, 2024

Hi @zztiger123 ,

yeah i did this aswell.

grafik

I have discovered that it is an ESP32 S3 WROOM 2, is this perhaps the reason?

@Xiehanxin
Copy link

hi @weoiss1998 here is my test result. I try the example/system/deep_sleep example, and set gpio 6 level to 1 on call_start_cpu0() ( as this function is the entry of appmain https://docs.espressif.com/projects/esp-idf/en/latest/esp32s3/api-guides/startup.html#first-stage-rom-bootloader )and the top of app main, my setting GPIO code is like this:

image

image

I don't use the genneral GPIO API beacuse this it would be faster to directlty use lower apis.

企业微信截图_1731996401136
from the result you can use it takes 27.5 ms to entry the start cpu0 ,which I think is the flag to finish boot, enter application, and 40 ms to print in appmain.

however, it seems there are still some differences between your result and mine. I want to confirm the level change timing in your logic

@weoiss1998
Copy link
Author

I will try it in the next few days.
My measurement is from Power on to app_main. Maybe you can check this by your side aswell?

@Xiehanxin
Copy link

Yes, I have set the GPIO level on the top of app_main, I think it is same.

@weoiss1998
Copy link
Author

My spontaneous guess is that the ESP32 S3 boots from deep sleep faster than if the power is completely disconnected.

@weoiss1998
Copy link
Author

Hi @Xiehanxin, how can I modify the cpu_start.c or where do you add void IRAM_ATTR call_start_cpu0(void)?

@Xiehanxin
Copy link

Xiehanxin commented Nov 20, 2024

you can found in components/esp_system/port/cpu_start.c

@weoiss1998
Copy link
Author

I found it but the Pin Output doesn't change on my side.

@Xiehanxin
Copy link

may I know which pin do you use?

@weoiss1998
Copy link
Author

I tried it with 4 and 6, when I use your Implementation nothing Changes, when I use gpio_set_direction and gpio_set_level it works

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Opened Issue is new Type: Bug bugs in IDF
Projects
None yet
Development

No branches or pull requests

4 participants