PersistentStorage in

PersistentStorage don’t throw any exception if SD card is not pressent when I try the latest SDK… It just hangs on

SdStorage = new PersistentStorage("SD");

Anyone else having this problem?

I should get my SD module on Monday, then I will try.
But you can check if a card is present in advance.
I think it’s a static method/property of PersistentStorage

1 Like

Which device?


@ Honken - Same behaviour here - works fine with card in but hangs with no card on G120HDR

I confirm this behaviour with:
G120HDR + SD Card Module (1.4, connected to the same pins as on Cobra II board).

on new PersistenStorage(“SD”);

everything is fine if an SD card is pluged in.

If no SD card is pluged in the call blocks.
Even if the card is inserted later, it still blocks.
It blocks in a way, that even VS can not reboot it to deploy and start a new debug session.

@ Honken - This issue has been logged and is awaiting verification. Thank you for your cooperation.

Also, could everyone seeing this issue please state the type of SD Card it is (SD/SDHC/SDXC/MMC), what class the card is and whether it is a MicroSD or not?

I have a
SDHC Card (not micro)
The label also shows the digit ‘4’ in a circle wich is open to the right. Don’t know if this is important.

The number in the circle shows the Class, which is used to group cards according to their read/write speed.

Has this issue been resolved?

I am using a SanDisk 64 MB SD (Not micro) class 1 and get the following message everytime I try to create a new instance using: pStore = new PersistentStorage(“SD”);

The thread ‘’ (0x2) has exited with code 0 (0x0).
Using mainboard GHI Electronics FEZSpider version 1.0
#### Exception System.InvalidOperationException - CLR_E_INVALID_OPERATION (1) ####
#### Message:
#### GHI.Premium.IO.PersistentStorage::.ctor [IP: 0000] ####
#### BabyFaceDemo.Program::ProgramStarted [IP: 004b] ####
A first chance exception of type ‘System.InvalidOperationException’ occurred in GHI.Premium.IO.dll
Exception was thrown: System.InvalidOperationException



This issue was reported over 10 months ago. Please provide your code so we can look into it. Format your drive and try FAT and FAT32. Also try different drive please. Also, it massive better to start a new fresh thread.

Hi Gus,

I’m having trouble using PersistentStorage, but my environment is a little different. Should I open a new thread?

Thank you,
Andrew Paes

@ Andrew Paes - Always open new threads if your problem is not exactly the same or if the other thread is already old.
You can add a link to the other thread.