To use the hard disk, one really good approach might be to just create a file manually (or have the app remount,rw create the file and them remount,ro again).

Then use the FIBMAP ioctl() call to find out where exactly the file is stored -- LBA numbers. With that info, the app can open the raw disk r/w (not the filesystem), and just read/write those blocks directly.

Takes a bit of fuss to get the correct absolute sector numbers from the FIBMAP data, but hdparm knows how to do it (source available).

I'm traveling right now, and trying not to program (much). smile