A database on board?

Hi, I was thinking about using some flash memory for a database (Sqlite), and saw a little 4MB module. I was actually looking for more like 256MB or even more.

Any ideas on how to have a persistent pretty big database on a Gadgeteer board? And is the SQlite feasible for that purpose.

I do not trust the SD cards for this purpose.

@ njbuch - I use USB thumb drives for file storage. I have never had a problem. Requires premium device.

1 Like

Brilliant (an obvious, ouch why didnt I think about that!) idea!

Does it work with SQlite?

@ njbuch - I see no reason why it should not work with sqlite.

Why a SD card when a USB Host thumb drive is an alternative?

How often do you see someone with a thumb drive problem?

You are right, I think… . But, does the use of a flash chip on a mainboard also make it an SD card? :slight_smile:

1 SD card for storage and 1 thumb drive for security backup or vice versa :stuck_out_tongue:

My experience is that SD cards wear out after being used frequently (logging to it for 2-20 times per day) for a couple of years in a microcontroller device. I am not aware of why, and if thumb-drives will show the same tendency.

the number of writes to a page in flash memory is “limited” by design. A driver is responsible for not always writing to the same location on flash disk but tries to devide using all available pages. (Wear leveling)

maybe this helps : https://www.ghielectronics.com/community/forum/topic?id=8514

Yeah SD cards aren’t the most reliable devices but they do the job. At the same time though all Solid state devices have limitations so I think your going to have problems no matter what you choose. Even standard hard disks can fail after a couple of years :frowning:

I would love to see a Gadgeteer device with a larger storage capacity but the price rises rather steeply with these chips. I had a look a while back.

At the end of the day all I can suggest is buying a reliable SD card brand and model and ensuring you make daily backups to another device such as the USB stick. Log every time a problem occurs on the SD card to give you an idea of any potential problems with the plugged in SD card and try to predict failiures :slight_smile:

Good luck :slight_smile:

Paul

Use Industrial grade memory, more expensive but more reliable.
Is use these:

http://www.transcendusa.com/support/dlcenter/EDM/UFM-EDM.pdf

1 Like

No-one really responded on the database thing, how well is the SQLite stuff working on a thumbdrive?

@ andre.m - ok, thats good to know!

I was looking for experience with having a larger database running on netmf. How big is ok, how many tables, sensitity to crashes and more.

@ njbuch - By the way, long time ago I have added a wrapper that makes working with SQLite similar to big .NET.

https://www.ghielectronics.com/community/codeshare/entry/142

Beautiful code! Would be useful to me I think!

@ andre.m - INTEGER, DOUBLE and TEXT

Yes, It is a wrapper for GHI’s implementation so whatever they support is supported.

@ njbuch - thanks :slight_smile: