Pins
Card detect - The CD pin is connected to ground when there’s no card in the socket. In the simulator, there’s always a card in the socket, so this pin is always disconnected.
SPI data output (MISO)
Ground
SPI clock
Voltage supply
SPI data input (MOSI)
Chip select
Filesystem
When you start the simulation, Wokwi creates a FAT16 file system and attaches it to the microSD card. By default, Wokwi copies all your project files into the microSD card.Uploading binary files
Paying users can upload custom binary files (e.g. bitmaps, sounds, etc.) to the microSD card’s filesystem. After adding a microSD card to your project, you’ll see a new “SD Card” tab next to the other tabs in the code editor. Click on the “Upload Files” buttons and select any files you wish to upload. You can also upload a complete folder tree (useful if you have a physical SD card attached to your computer and you want to upload all the data from it, as-as). Click on the small arrow next to the “Upload Files” button and select “Upload complete folder”. Then select the folder with the files you want to upload. Wokwi stores the uploaded files for you, alongside with your project. Anyone who opens your project and starts the simulation will have to wait for all the micro SD card files to download before the simulation starts. Example: microSD Card project with a custom bitmap fileArduino code example
The example below uses the popular SdFat Arduino library. It prints a list of all the files in the card. The code assumes the following connections:| SD card pin | Arduino Uno pin |
|---|---|
| SCK | 13 |
| DO | 12 |
| DI | 11 |
| CS | 10 |