Updated get_fattime to use rtc and provide a date/time. This has been an annoying missing feature.
Dependents: IoTGateway_Basic y_XBeeTest_5_read CameraC1098_picture LifeCam ... more
FATFileHandle.h@1:5baba5d5b728, 2012-04-02 (annotated)
- Committer:
- SomeRandomBloke
- Date:
- Mon Apr 02 22:06:35 2012 +0000
- Revision:
- 1:5baba5d5b728
- Parent:
- 0:93acdd9f65f4
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
SomeRandomBloke | 0:93acdd9f65f4 | 1 | /* mbed Microcontroller Library - FATFileHandle |
SomeRandomBloke | 0:93acdd9f65f4 | 2 | * Copyright (c) 2008, sford |
SomeRandomBloke | 0:93acdd9f65f4 | 3 | */ |
SomeRandomBloke | 0:93acdd9f65f4 | 4 | |
SomeRandomBloke | 0:93acdd9f65f4 | 5 | #ifndef MBED_FATFILEHANDLE_H |
SomeRandomBloke | 0:93acdd9f65f4 | 6 | #define MBED_FATFILEHANDLE_H |
SomeRandomBloke | 0:93acdd9f65f4 | 7 | |
SomeRandomBloke | 0:93acdd9f65f4 | 8 | #include "FileHandle.h" |
SomeRandomBloke | 0:93acdd9f65f4 | 9 | #include "ff.h" |
SomeRandomBloke | 0:93acdd9f65f4 | 10 | |
SomeRandomBloke | 0:93acdd9f65f4 | 11 | namespace mbed { |
SomeRandomBloke | 0:93acdd9f65f4 | 12 | |
SomeRandomBloke | 0:93acdd9f65f4 | 13 | class FATFileHandle : public FileHandle { |
SomeRandomBloke | 0:93acdd9f65f4 | 14 | public: |
SomeRandomBloke | 0:93acdd9f65f4 | 15 | |
SomeRandomBloke | 0:93acdd9f65f4 | 16 | FATFileHandle(FIL fh); |
SomeRandomBloke | 0:93acdd9f65f4 | 17 | virtual int close(); |
SomeRandomBloke | 0:93acdd9f65f4 | 18 | virtual ssize_t write(const void* buffer, size_t length); |
SomeRandomBloke | 0:93acdd9f65f4 | 19 | virtual ssize_t read(void* buffer, size_t length); |
SomeRandomBloke | 0:93acdd9f65f4 | 20 | virtual int isatty(); |
SomeRandomBloke | 0:93acdd9f65f4 | 21 | virtual off_t lseek(off_t position, int whence); |
SomeRandomBloke | 0:93acdd9f65f4 | 22 | virtual int fsync(); |
SomeRandomBloke | 0:93acdd9f65f4 | 23 | virtual off_t flen(); |
SomeRandomBloke | 0:93acdd9f65f4 | 24 | |
SomeRandomBloke | 0:93acdd9f65f4 | 25 | protected: |
SomeRandomBloke | 0:93acdd9f65f4 | 26 | |
SomeRandomBloke | 0:93acdd9f65f4 | 27 | FIL _fh; |
SomeRandomBloke | 0:93acdd9f65f4 | 28 | |
SomeRandomBloke | 0:93acdd9f65f4 | 29 | }; |
SomeRandomBloke | 0:93acdd9f65f4 | 30 | |
SomeRandomBloke | 0:93acdd9f65f4 | 31 | } |
SomeRandomBloke | 0:93acdd9f65f4 | 32 | |
SomeRandomBloke | 0:93acdd9f65f4 | 33 | #endif |