sd-card

SD card write performance

I am writing a little application, which is writing jpeg images at a constant rate on a SD card. I choose an EXT3 filesystem, but the same behaviour was observed with an EXT2 filesystem. My writing loop looks like this : get_image() fwrite() fsync() Or like this : get_image() fopen() fwrite() fsync() fclose() I also display some ...

Why are my programs running from my SD card so slow?

When moving my .Net Compact Framework application to the SD-card of a Windows CE device, the program executes slower then running it from the internal memory. I thought, the start-up might be slower, but it is the whole program. There is no IO to the storage card. Why is my application so slow and how does the compact framework handles...

Software to mark bad blocks on SD card?

Do any one know a software to check AND mark bad blocks on SD card? To clarify - bad block is a block of card which can't store data. The problem is - no error reported on read or write operation. The only way to check it is to write data and then read it. There is tool to check and find those blocks, but it will not mark them as bad. ...

micro-SD card initialization using SPI interface

I'm using a micro-SD card in an embedded design. The card is connected to a microcontroller using the SPI interface. It worked fine for all cards I've used before, but now my new card will not initialize. The card is a Transcend 2GB micro-SD card (TS2GUSD). After sending the initial clock train to switch to SPI mode I do the following: ...

How to diagnose Fatal Application Errors in WinCE?

We recently moved our Windows CE application to the SD Card. Since then the QA - Team reported some "Fatal Application Errors". Our application is a .net application and we are using wrapper DLLs to access device specific hardware. Is there a way to log or debug such an error? ...

SD-Card Life while using it to store a data structure

I have come up with a disk-based data structure to store incoming realtime data, this is not in memory becuase the array can fill up and cause the jvm to crash. The data-strcture and algorithm work great. My only question is that does this greatly affect the life of an sdcard? I know sdcards have limited read and writes on them, but how...

Retrieve SD Card serial number on Windows XP/Vista/7?

There is a manufacturer's serial number on SD cards, and there are a number of pages on the 'net that describe how to retrieve it on various mobile devices (including this one). But I need to retrieve it under desktop versions of Windows, and the code that works for mobile versions of Windows doesn't seem to translate. The question: how...

How to backup database file to sdcard on android?

I'd like to add a feature to my android app that automatically backs up the sqlite database to the sd card. What's the best way to go about this? Any examples/tutorials available? ...

Android: good practices for organizing dirs and files on storage SD card?

Are there any guidelines where should my app store resource files downloaded from internet? ...

Why is my SD Card not writable (Android)?

In the emulator I can't seem to write to the attached SDCard. The following code always spits out the "can't write root" log message, but not the "can't read root" one. File routesRoot = Environment.getExternalStorageDirectory(); if (!routesRoot.canWrite()) Log.v(getClass().getSimpleName(), "can't write root"); if (!routesRoot.canRe...

Android - Storing images downloaded from the web

Hello everyone, I had a question related to whether or not (and how) I should store images loaded from the web. Let's say I am calling a web service from my Android app. In this web service I get a URL for an image on the web. I download and show this image on the left side of a list item in a ListView. My question is, what method s...

How can I listen for SD card mounting in android?

I have a program that uses the SD card, so I want to be informed if the state of the card changes by registering a listener if possible. I'm aware of the Environment class and its methods, but I don't really want to be constantly polling the state. I'd rather not have my program force close when running cause someone mounted the sd card ...

Initializing SD card in SPI issues

Sorry for the length of this question, but I thought it best to show as much detail to fend of questions asking if I had done A when I had already done A... ;-) I've had a look at the "micro-SD card initialization using SPI interface" thread and didn't see any answers that matched my issue (i.e. things I haven't already tried). I have a...

How to read raw bytes from an SD card?

On a Windows PC, is there a way to read the raw bytes from an SD card attached trough a USB card reader? The SD card gets written from an embedded system using no file system at all, so I can't use standard file access routines. This is similar to what the unix dd utility does, but I need to integrate this into a .NET application. ...

Decoding bitmaps in Android with the right size

I decode bitmaps from the SD card using BitmapFactory.decodeFile. Sometimes the bitmaps are bigger than what the application needs or that the heap allows, so I use BitmapFactory.Options.inSampleSize to request a subsampled (smaller) bitmap. The problem is that the platform does not enforce the exact value of inSampleSize, and I sometim...

(re)mounting the SD card on android emulator

On the emulator, I can unmount the SD card from the Settings. I can then mount it on my OS, then unmount it normally. I haven't been able to figure out how to re-mount it then on the emulator (without rebooting it). hints: the adb command remount is unrelated: it's about /system the emulator command is unrelated: it's only about sta...

Downloading game assets to SD card on Android

I'm developing an Android game that has to download some assets to the SD card to keep the size of the app as small as possible. I was thinking of using an uncompressed zip file to bundle all the assets. A requirement from the client is to protect these assets as much as possible. Being part of the apk is considered enough protection, b...

ls command on Busy Box on a SD card doesnot work gives no error. SD card shows file inside on windows xp

I have a 2 gb sd i saved few files on that from windows xp fat32 partition. Now when I tried using ls command on same sd card(I was able to mount) ls command doesnt do anything.It does not throw any error also. ...

SD card initialization SPI

Hi People I saw a lot of infos about MMC/SD cards and I tried to make a lib to read this.. (modifying the Procyon Avrlib) But I have some problems here. I Don´t change the original code and tried here. My problem is about the init of SD card. I have 2 here, a 256mb and another 1GB. I send the init commands like this order: CMD0, CMD55...

Android Mediaplayer: setDataSource issue for downloaded media file

I have an application that will record and play audio files. Some of the audio files are downloaded using simple standard http downloads using httpclient. It worked like a charm for a long time. Now all of a sudden I cannot play the files I download. It fails with this stack. I store the files on the SDCard and I experience the problem b...