SDCard on Core Compute Dev Board

I can’t see any mention of the SD Card in the Meadow libraries. Is the SD Card supported in any way?

Andy

SD Card support for CCM is in the next release.

Regards,
Mark

Thanks Mark - any feeling on when that release might be available?

Andy

Today.

Regards,
Mark

1 Like

So I have updated my CCM to RC-2 and enabled SD card in meadow.config.yaml - are there any examples of how to use the SD card? Can I use this code directly or do I have to tell Meadow to use the SD card?

CreateFile(MeadowOS.FileSystem.TempDirectory, "hello.txt");

private void CreateFile(string path, string filename)
{
    if (!Directory.Exists(path)) {
        Directory.CreateDirectory(path);
    }

    try {
        using (var fs = File.CreateText(Path.Combine(path,filename))) {
            fs.WriteLine("Hello Meadow File!");
        }
    } catch (Exception ex) {
        Console.WriteLine(ex.Message);
    }
}

Andy

Can anyone point me to information on using the newly released SD card support ?!

Andy

Does this help:

Regards,
Mark

Thanks Mark.
Not sure how I missed that when I was looking through the sample repositories :frowning:

Andy

There’s also this page that talks about the various SD events, if it helps. I imagine that samples is as good a place to start as any, though.
http://developer.wildernesslabs.co/Meadow/Meadow.OS/Core-Compute_SD_Card/

@adam.patridge Adam, thanks for that - I don’t seem to be doing well at finding this readily available information :frowning:

I have tried the sample @mark.stevens linked to but cannot get that code to recognise a FAT32 SD card inserted into the CCM development board - I will read through the information on the page you linked and see if it enlightens me :crossed_fingers:

Andy

Okay, that page did the trick :slight_smile:
Despite the examples meadow.config.yaml not showing it, you do need to put the following in there:

Device:
    # Enable if your Meadow build is using SD card hardware.
    SdStorageSupported: true

Many thanks for your help.

Andy

Glad that helped. Yep, definitely need to explicitly declare SD use in config. I’ll have to see if we can get the sample updated to the latest as well.