-
-
Notifications
You must be signed in to change notification settings - Fork 749
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
Why is shiftOut on ESP32 so much slower than on original Espruino boads? #1915
Comments
shiftOut differences:
so there is potential for optimisation. |
Compare simple functions like: |
I think in the JS execution case it's probably that while the CPU is fast it's having to grab the code to execute out of QSPI flash on demand? I imagine if you found the 'hot' interpreter functions and loaded them into RAM then execution speed would raise dramatically |
Yes, with ESP32 i2s parallel dma you can have about 500fps for a 64x64 panel without any flicker. |
Reading the esp32 technical reference manual state that pins are register mapped input
output
So the shiftOut for ESP32 will never be as fast as on STM32 boards But ESP32 offers i2s, which can do parallel shiftout with dma, whith nearly no cpu impact. Just added a sample video to this conversation |
It's possible that |
The ESP32 has a limit of 4MHz for setting gpio's via register. Just throttled i2s from 40MHz to 3MHz and the result is still ok.
Great! So working on this is a win for supported boards a well. For the ESP32 there is one register plus bitmap to set a pin and a different register plus bitmap to set a pin low. |
@jumjum123 can you please share your code for this. |
Hallo Mark,
welchen Code meinst Du ?
Ich bin heute ab ca. 19:00 zu Hause erreichbar.
Grüsse
Jürgen
Am Mi., 24. Apr. 2024 um 20:00 Uhr schrieb Mark Becker <
***@***.***>:
… @jumjum123 <https://github.com/jumjum123> can you please share your code
for this.
—
Reply to this email directly, view it on GitHub
<#1915 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAPYNHTUHGV7VI622KVZZI3Y67XNRAVCNFSM4QBXIEN2U5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TEMBXGU2TEOJTGE2A>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Those STM32 boards are so much faster when it comes to GPIO's than the ESP32 - amazing.
So why is the ESP32 with 240 MHz and a dual core so much slower?
The text was updated successfully, but these errors were encountered: