Skip to content

ESP32-S2 SD card won't mount? #3396

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

Closed
emard opened this issue Sep 11, 2020 · 1 comment · Fixed by #3448
Closed

ESP32-S2 SD card won't mount? #3396

emard opened this issue Sep 11, 2020 · 1 comment · Fixed by #3448
Assignees
Labels
bug busio espressif applies to multiple Espressif chips

Comments

@emard
Copy link

emard commented Sep 11, 2020

Is SD card supposed to work on ESP32-S2 WROVER?
I pulled latest driver bundle and tried this example to mount
SD card:

https://github.com/emard/esp32ecp5/blob/master/circuitpython/sdmount.py

If SD card is inserted (it has FAT and old ESP32 non-S2 is able to mount),
then ESP32-S2 prints

Traceback (most recent call last):
File "", line 1, in
File "sdmount.py", line 31, in
File "adafruit_sdcard.py", line 116, in init
File "adafruit_sdcard.py", line 177, in _init_card
File "adafruit_sdcard.py", line 155, in _init_card
OSError: couldn't determine SD card version

if SD card is not inserted then:
Traceback (most recent call last):
File "", line 1, in
File "sdmount.py", line 31, in
File "adafruit_sdcard.py", line 116, in init
File "adafruit_sdcard.py", line 177, in _init_card
File "adafruit_sdcard.py", line 145, in _init_card
OSError: no SD card

@jepler jepler added bug espressif applies to multiple Espressif chips labels Sep 13, 2020
@jepler
Copy link

jepler commented Sep 13, 2020

I think it's likely that it doesn't work due to the ignored value of write_value in common_hal_busio_spi_read, an esp32 flavored version of #3176. This function (at least handling the all-ones value 0xff) is required for SPI SD cards to work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug busio espressif applies to multiple Espressif chips
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants