Skip to content

Conversation

@ArcaneNibble
Copy link
Collaborator

This is far from complete, but I wanted to make it known that I've hacked on some basic SD card support just to get an understanding of how the MMC/SD controller works.

This initialized a SDHC card (no legacy SD support) and prints out a bunch of its internal registers as debug spam.

@coveralls
Copy link

Coverage Status

coverage: 57.26% (+0.02%) from 57.239%
when pulling c211541 on ArcaneNibble:sdcard
into 4484552 on pybricks:master.

@ArcaneNibble
Copy link
Collaborator Author

Also, I just tried an SDXC card and it does seem to work just fine (goes through all of the initialization steps, but I haven't actually tried reading any sectors yet).

The hardware peripheral has no knowledge of what SD card capacity you've inserted -- this is entirely under software control. Data corruption (with ev3dev? with the stock firmware?) is probably just a software bug.

@laurensvalk
Copy link
Member

laurensvalk commented Dec 5, 2025

Thanks!

One way to work towards getting this merged, would be to get this to read a plain text config file on the card.

Could be anything that is unique to EV3 to start with. For example, we could set a hue value for this line so we can practically test it.

In the future this config file could be used to override system defaults such as volume, bluetooth enable, idle timeout, and so on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants