miosix::Filesystem Class Reference

#include <filesystem.h>

List of all members.

Public Member Functions

char mount ()
void umount ()
bool isMounted () const

Static Public Member Functions

static Filesysteminstance ()

Detailed Description

This class allows low level access to the filesystem. It contains member functions to mount and unmount the filesystem, and to check if it is mounted. There are also functions to perform file access that are primarily meant to be used by the C/C++ standard library integration layer (syscalls.cpp).

Member Function Documentation

Filesystem & miosix::Filesystem::instance (  )  [static]

the instance of the filesystem (singleton).

bool miosix::Filesystem::isMounted (  )  const [inline]

true if the filesystem is mounted

char miosix::Filesystem::mount (  ) 

Try to mount the flesystem. Might take a long time (~ 1 sec if no errors, up to 3 sec in case of errors)

  • 0 = on success
  • 1 = in case of errors
  • 2 = if no drive was found (for example there is no uSD card)
  • 3 = if the filesystem is already mounted

void miosix::Filesystem::umount (  ) 

Unmounts the filesystem if it is mounted. All files that are open at this point are closed, and their file descriptors are invalidated. Allows safely removing the drive (example uSD card)

The documentation for this class was generated from the following files:

Generated on Mon Aug 30 00:05:00 2010 for Miosix by  doxygen 1.5.9