I've been able to get an SD card to work on my pixl, but I'm having trouble to get the initialization process to be consistent. Sometimes the card will start to work within a few seconds (rare) and other times I've left it for about 30 minutes (or overnight) and it still doesn't initialize properly. Once initialized as long as I don't turn the pixl off/on it will work and I can read/write OK.
I'm using a Sandisk 16GB microsd and I've soldered connectors for a microsd->SD card adapter as per https://www.espruino.com/File+IO
the error I get when trying to reddir is:
Uncaught Error: Unable to mount media : NOT_READY
at line 1 col 27
things I've tried:
trying different microsd cards
Pull-up resistors on the CS pin (1k,2.7k, 3.7k, 4.7k,16k,50K, 76K) - I haven't noticed any difference / improvement from using the pull up resistors
manually running the initialization/reddir function in the left side of the interface when connected to the card
I've come up with a simple oninit function that will iterate through trying to get the card to work:
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
I've been able to get an SD card to work on my pixl, but I'm having trouble to get the initialization process to be consistent. Sometimes the card will start to work within a few seconds (rare) and other times I've left it for about 30 minutes (or overnight) and it still doesn't initialize properly. Once initialized as long as I don't turn the pixl off/on it will work and I can read/write OK.
I'm using a Sandisk 16GB microsd and I've soldered connectors for a microsd->SD card adapter as per https://www.espruino.com/File+IO
the error I get when trying to reddir is:
things I've tried:
I've come up with a simple oninit function that will iterate through trying to get the card to work:
I've attached a few pictures to show my setup (3 resistors with ~75K ohm). Perhaps I've wired something up wrong?
Any other suggestions on how I could troubleshoot this? Sadly I don't have an oscilliscope or that sort of thing for analyzing data lines etc
2 Attachments