-
Notifications
You must be signed in to change notification settings - Fork 245
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
Newer IDF Support #75
Comments
Not yet. But I don't think it should make much difference. Perhaps the focus is on wifi connection and uart related API? Anyway, give it a try and feel free to discussing the details here :) |
I did give it a quick try and there was quite a long list of compile errors, many from the SPI drivers I think. |
SPI operates by directly reading and writing registers. I'm not sure if the spi ip has changed. |
Ah, I was trying to build for C6 so yeah, it's probably different registers there. I basically just naively copied the C3 implementation as a first try, but I know C6 requires newer IDF and newer APIs in it, it would make sense that different IP / register layout would be behind that. |
Interestingly, the register layout of C3 and S3 seems to be the same. Not sure if the new version of sdk changes the layout like C3. I think it could first check if C3 and C6 have similar registers in v5.2 sdk. |
I was going to try building with S3 instead to see how much effort it would take, but thought I'd better get the current master tested first on the S3 to be sure any changes made worked properly. Unfortunately I can't make the S3 work correctly however. Oscilloscope shows signals on swdio and swclk so the pinout appears correct, just not actually working. This is all a separate issue to the IDF version certainly, it's just blocking me from doing much else currently. |
Try to use lower speed? May be < 1Mhz? |
|
Is the oscilloscope showing the expected waveform? It is also possible that the GPIO is not reading the correct input, have you connected the 3.3V pin? |
I'm not too certain about what the expected waveform is, but both SWD lines have some switching / communication when trying to start a debug session. I think I've got a basic esp32 somewhere, if I can find that I'll try it instead, see if I can get basic operation going at least |
You can just post the waveform you captured here. I think you can see at least 50 cycles of SWCLK at the beginning |
Ah, sorry I've looked through many other issues here and it looks like I've just run into some similar issues to others, like #68 (comment) and #31 (comment) With pyocd locking the freq to 10mhz did make it work on a samd21 target I was testing with ! I gather there's some surprising timing issues with the likes of pyocd / openocd that trips it up on some targets. I found a original ESP32 and programmed it up, got the same results as the S3. I don't have keil to test with, I use vscode / linux for my embedded work. |
Glad to heart that. When you select 10MHz speeds, you're actually using 40MHz SPI output. All other lower speeds are output directly from the GPIO. Openocd doesn't seem to like using high rates in the beginning, stable connection must be established before increase the clock. Not sure what's going on here. |
Hello guys, I did some test on ESP-S2, but in my test, I found we can't use the SPI to only receive 3-bit . if i did this in the code , although i could found the 3 pluses, but i could not get data in the spi data registers. in the S2 and S3's TRM , I found this note "The length of transferred data must be in unit of bytes, otherwise the extra bits will be lost. The extra bits here |
Hello,
Has any work been done to support newer IDF versions?
I'd like to port this project to ESP32C6 to use this tiny module: https://docs.m5stack.com/en/core/M5NanoC6
However, it requires IDF 5.2 or newer, which has compatibility changes in things like the SPI drivers etc.
The text was updated successfully, but these errors were encountered: