Reading the SD Card of another device

Post here about your Arduino projects, get help - for Adafruit customers!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
theox
 
Posts: 2
Joined: Sat Jun 02, 2012 9:52 pm

Reading the SD Card of another device

Post by theox »

Ok, looking for a hint to get started on this project. Here is what I'm looking to do:

Have my Trail Camera send me a text (or, even better send me the photo) over GSM/GPRS.

My trail cam has a SD Card slot, so my thought was read from that slot. I got the pinout for a SD slot but I am stuck on how to send the data from my trailcam to the Arduino for storage and possible transmission.

Here are some thoughts on this that I had (be gentle :)

1) A "shared" SD card between the 2 devices.
2) Direct send of the data from the camera to the Arduino from the SD slot by connecting the pins from the SD card to the Arduino.

Anyone have any suggestions?

Additional thought: I see SIM cards with 1MB limits per month. Are there SIMs that have higher allowances?

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Reading the SD Card of another device

Post by adafruit_support_rick »

My trail cam has a SD Card slot, so my thought was read from that slot. I got the pinout for a SD slot but I am stuck on how to send the data from my trailcam to the Arduino for storage and possible transmission.
The SD pinout is simply SPI, so you should be able to set up the arduino as an SPI slave and read whatever the trail cam sends you.
I see two possibilities: 1) write a package to emulate an SD card or 2) write a package that simply passes commands and data between the trail cam and a real SD card on the arduino.

Option 2) appears immensely simpler to me. You don't have to know anything. You just read and forward anonymous chunks of data. The only potential pitfall I can see would be timing - i.e., if the round-trip from camera to SD card and back taking too long. Only one way to find out for sure :wink:.

I image you could perform some surgery on a dead SD card to patch in some wires. Insert that in your camera, so you don't have to hack the camera itself...

mtbf0
 
Posts: 1645
Joined: Sat Nov 10, 2007 12:59 am

Re: Reading the SD Card of another device

Post by mtbf0 »

driverblock wrote:I image you could perform some surgery on a dead SD card to patch in some wires. Insert that in your camera, so you don't have to hack the camera itself...
or use something like this.

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Reading the SD Card of another device

Post by adafruit_support_rick »

mtbf0 wrote:or use something like this.
Now that's cool

User avatar
cstratton
 
Posts: 294
Joined: Wed Sep 29, 2010 3:52 pm

Re: Reading the SD Card of another device

Post by cstratton »

driverblock wrote:The SD pinout is simply SPI, so you should be able to set up the arduino as an SPI slave and read whatever the trail cam sends you.
No, it's not "simply SPI". SPI is available on most cards as a lower-bandwidth legacy interface, which is great for all the embedded hackers out there who want to use them as storage media in custom projects. But SPI mode is not what cameras are likely to use, especially if they are megapixel class or do video.

Even with access to the full SD interface spec, it's unclear that an arduino would have the bandwidth to keep up - and where is it going to stash the data?
I image you could perform some surgery on a dead SD card to patch in some wires. Insert that in your camera, so you don't have to hack the camera itself...
What might be workable would be to use some kind of bus multiplexor chip to switch the card between being electrically available to the camera and being available to the arduino, however you would also have to have a means of telling the camera that it is going to loose access (such as switching off its power?)

There are also SD cards out there with built-in wifi back end engines for pushing the data to an external computer for ultimate storage.

In terms of the SIM question, 1 MByte limit would be comically small in this age of smartphones, though you might effectively have something like that on a non-data plan. Speaking of phones, an old one running android might be an alternate solution for the whole project, if the camera is of suitable quality.

ral6639
 
Posts: 7
Joined: Wed Aug 15, 2012 7:32 pm

Re: Reading the SD Card of another device

Post by ral6639 »

Did you have any luck? Would it be more simple to have the camera save the file to a sd card integrated to a gsm module?

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino”