Skip to content

Commit

Permalink
Update SD Card sample
Browse files Browse the repository at this point in the history
  • Loading branch information
jorgedevs committed Mar 27, 2024
1 parent 2f11c88 commit 735fae6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Source/Meadow F7/OS/SDCard/MeadowApp.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ public class MeadowApp : App<F7CoreComputeV2>
{
public override Task Run()
{
if (!Device.PlatformOS.SdStorageSupported)
{
Resolver.Log.Error($"SD card support is not enabled in 'meadow.config.yaml'");
return Task.CompletedTask;
}

Device.PlatformOS.FileSystem.ExternalStorageEvent += PlatformOS_ExternalStorageEvent;

var drive = Device.PlatformOS.FileSystem.Drives.FirstOrDefault(d => d is IExternalStorage);
Expand Down

0 comments on commit 735fae6

Please sign in to comment.