Main Site Documentation

Fez Panda - Trying to read from SD on Adafruit WaveShield


#1

Just got my Panda last week. I’m working through some different examples, and trying to interface with some of the Arduino shields that I have. Trying to use the sample code from section 23.1 of the Beginner’s Guide (http://www.tinyclr.com/downloads/Beginners%20guide%20to%20NETMF.pdf) to list the contents of the SD card, but the code throws an exception @ the following line.

PersistentStorage sdPS = new PersistentStorage("SD");

The exception I’m getting is as follows:

[quote] #### Exception System.Exception - 0xffffffff (1) ####
#### Message:
#### GHIElectronics.NETMF.IO.PersistentStorage::.ctor [IP: 0000] ####
#### Test.Program::Main [IP: 0007] ####
A first chance exception of type ‘System.Exception’ occurred in GHIElectronics.NETMF.IO.dll[/quote]

I’m still wrapping my head around communicating with an SD card via SPI, so I’m not really sure where to start. The WaveShield is tested and works fine with an Arduino. Any light that can be shed is greatly appreciated.


#2

FEZ uses 4-bit real SD interface. Arduino shields with SD cards connectors rely on SPI bus. You can’t use SD cards on Arduino shields with FEZ.

Not to worry, you can easily wire and SD card to your Panda. See this http://www.microframeworkprojects.com/index.php?title=SD_Card_Connection_Guide

Or use the Micro SD board we offer on this website