SD Card Libraries

Hi,

I am working on a project in which I want to use an SD card as an input/output source.

I need it to be as fast as possible! Code size may be an issue, memory usage also.

I don’t need to be able to
Format the card.
Understand or traverse directories, apart from recognising they are not files.
Support large cards or multiple formats.

Everything can be saved in the root directory so FAT32 would be good to allow for more than 512 entries but will happily accept FAT16 only.
The files will all be small <10k so again don’t need to support large cards.

I do need to be able to react to a read/write failure, card ejected/not present etc.

Card not present should not be required for setup initialisation.

The documentation for the current Arduino default SD library is so rubbish as to make it nearly unusable.

So is there anything close out there or do I have to write my own?

Lastly I do plan to sell the completed project, but only in small quantities, but am prepared to pay a reasonable licence fee.

What's exactly the idea?

For fast read/write operations: don't close (reopen) or flush the file too often, and don't let the files get fragmented.
In order to not traverse directories: never use '/' in the path (i.e. in SD.open()).

Is possible to react to a read/write failure in the included library; nevertheless you have to implement such handlers.
It's also possible to detect the card's presense, by calling SD.begin() to be sure. But to detect insertion or removal at the moment it happens, it's only achievable with the required hardware (e.g. some kind of switch in the slot) and an interrupt.

GrahamB:
The documentation for the current Arduino default SD library is so rubbish as to make it nearly unusable.

It was made to be more beginner-friendly; so of course it's very likely to lack the information an advanced programmer may need.
For the more advanced stuff, you may wanna make use of what SdFat has to offer.

PD: why you need this so reliable?