SUPPORT FOR ESPS3 BOARDS? #312
Replies: 10 comments 8 replies
-
ESP32S3 has no DAC, which is used to generate video. |
Beta Was this translation helpful? Give feedback.
-
Hi Vitasam. That's interesting. So, does this mean that the lack of actual hardware DACs on the S3 (vs. the older ESP32s) should in theory not be an obstacle. I'm a bit confused about the use of resistor ladder vs. physical DACs. If all it takes is implementing the resistors then there's hope! |
Beta Was this translation helpful? Give feedback.
-
Thanks Vistasam. I was implementing that layout in my proto-schematic. So good to know I was heading in the right direction! I'll have to replace the Audio Line Out elements as the ESP32S3 does not have a hardware DAC and I am 99.9% sure that is why pin 25 was selected for audio on this schematic for FabGL. I actually removed the audio library imports from Bitluni's VGA example and it reduced the library/compile errors considerably. I expect that would be the same for FabGL. Worth a try. I would replace it with I2S using a Max chip or something similar. Though it would be interesting to know if it could work with a resistor ladder similar to what is being used for VGA. It looks like hardware DACs are becoming an endangered species with Espressif's newest ESP chips. Shame actually. They kept these for the S2 but that appears to be deprecated now. I'm going to have another go at FabGL in Arduino and see how far I can get. If I can get it to compile on the S3 then I will order some boards for VGA testing and post my results. |
Beta Was this translation helpful? Give feedback.
-
I'm not sure about the performance. I've read that the S3 is a bit faster. Certainly there are differences in the capabilities. Overall I'd say the older ESP is a bit more flexible in that it offered Ethernet and DAC. But, it's not easy to compare them 1:1 as they are quite different. Each has it's strengths and weakness. It's actually really difficult to find a really good comparison as comparisons tend to focus on the ESP32-S2 not the S3. It's definately in the same ballpark. Here are the nitty gritty details: The big plus to the S3 (and the S2) is that they have provide native USB OTG support. So, if you are using Circuit Python or Arduino (with USB-OTG) you can program the device without a UART chip being required. That is very convenient and it reduces the cost of the boards a little bit. Even cheapo UART chips are not cheap. CP looks like it will support the ESP32 eventually, but it is a bit of a bodge at this point. |
Beta Was this translation helpful? Give feedback.
-
Specs on the ESP32-S3 https://cdn-shop.adafruit.com/product-files/5477/esp32-s3_datasheet_en.pdf |
Beta Was this translation helpful? Give feedback.
-
So, I tried compiling for the S3 and I received the following error: fatal error: soc/frc_timer_reg.h: No such file or directory No idea why this is happening. I don't get the error if I compile for a regular ESP32. The quest continues. |
Beta Was this translation helpful? Give feedback.
-
I did some reading and indeed the core timers are different between the regular ESP32 and the S series ESPs. So it does make sense as you suggested that this header file could be missing from the IDF framework (in the case of the S series units). It's not in the FabGL code. So almost certainly from the IDF provided codebase. It is probably replaced with something similar but not the same as for the older ESPs. I'm not much of a coder but I will investigate this. |
Beta Was this translation helpful? Give feedback.
-
This file is in the Users (on Windows anyway) AppData directory. I am pretty sure that this is compiled from the location of the "IDF" libraries. On my system this appears to be located in ....AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.6\tools\sdk There is a folder there for each type of ESP (ESP, C3, S2, and S3) and if you dig deeper you can find the .h files. I think this is where the deviation actually occurs. I believe that frc_timer_reg.h is most likely replaced with system_timer_reg.h. Certainly frc_timer is not in the S3 codebase. It is in the S2 codebase. But I'm not certain what the extent of the variations are and of course the codebase is quite different. According to ESP the frc_timer code was "replaced with simpler LAC timer" for the S3. Sigh... Interestingly the S2 fails much later in the compile process, and it does not generate that many errors. Those that it does mostly relate to E-fuse differences and the SPI clock (with a recommended library alternative for the SPI). The ESP-S2 was a lot closer to the original ESP32, so this makes sense as the hardware was similar. Very few errors on the S2. So, to implement an S3 solution I think this would take a revisiting of the FabGL codebase to specifically target the S3. It's probably not that difficult (only speculation on my part!) if the author did this as they know what their codebase actually needs to function properly and they could work around any issues they encounter. But clearly not trivial. Perhaps forking the codebase specifically for the ESP32S3 and/or the S2. I just don't see this being at all easy to address if we need to both modify the authors code to target the S3 while resolving cascade errors that are almost certain to occur due to variances with the original codebase, variables and dependent libraries. As it stands it is looking like this could work but it's not going to be trivial. |
Beta Was this translation helpful? Give feedback.
-
Agreed. It would be wonderful if it happened but I understand this is quite an undertaking. A combination of an ESPS3, I2S audio and perhaps even USB device support (using a CH559 MCU as per Bitluni's work perhaps) would make for a pretty awesome kit. Even more so if the coding of the apps could be written in Circuit Python as code development would be very immediate (no compiling etc.) and the storage system is so slick. It would be like to days when 8 bit game could be written by anyone with an interest in exploring. One can always dream! If someone decides they are up to the challenge I'm prepped to design some boards for testing! |
Beta Was this translation helpful? Give feedback.
-
I just found out that Bitluni has added VGA support to the ESP32S3! Hat's off to him for this clearly herculean task. It's a work in progress |
Beta Was this translation helpful? Give feedback.
-
I was really hopeful that I would be able to use FabGL in Arduino with an ESP32S3 board. It fails at the compile stage
with (i.e., no soc/frc_timer_reg.h). So it appears the FabGL codebase is not S3 compatible. Has anyone tried FabGL with the newer ESP32S3 boards? I know that the S3 does not have hardware DAC's (a big shame IMO), but I'm wondering if the audio side of things at least could be addressed by utilizing I2S audio perhaps?
From a display standpoint Is there something that FabGL requires to be present that renders it incapable of ever being able to generate VGA signals with an S3 based board. If not, It would be amazing if we could get ESP32S3 support added to FabGL as this is the newest design from Espressif and the extra IO is really useful. Would be great to have FabGL for ESP32S3 if such a thing is possible.
Beta Was this translation helpful? Give feedback.
All reactions