"r" or "rb" | + *Open a file for reading. The file must exist. | + *
"w" or "wb" | + *Truncate an existing to zero length or create an empty file + * for writing. | + *
"wx" or "wbx" | + *Create a file for writing. Fails if the file already exists. | + *
"a" or "ab" | + *Append; open or create file for writing at end-of-file. | + *
"r+" or "rb+" or "r+b" | + *Open a file for update (reading and writing). | + *
"w+" or "w+b" or "wb+" | + *Truncate an existing to zero length or create a file for update. | + *
"w+x" or "w+bx" or "wb+x" | + *Create a file for update. Fails if the file already exists. | + *
"a+" or "a+b" or "ab+" | + *Append; open or create a file for update, writing at end-of-file. | + *
+ SdFat
+
+ |
+
ArduinoInStream and ArduinoOutStream classes. +More...
+#include <bufstream.h>
+Classes | |
class | ArduinoInStream |
Input stream for Arduino Stream objects. More... | |
class | ArduinoOutStream |
Output stream for Arduino Print objects. More... | |
ArduinoInStream and ArduinoOutStream classes.
+
+ SdFat
+
+ |
+
Sd2Card class for V2 SD/SDHC cards. +More...
++Classes | |
class | Sd2Card |
Raw access to SD and SDHC flash memory cards. More... | |
+Variables | |
uint8_t const | SD_CARD_ERROR_ACMD23 = 0X9 |
uint8_t const | SD_CARD_ERROR_ACMD41 = 0XA |
uint8_t const | SD_CARD_ERROR_BAD_CSD = 0XB |
uint8_t const | SD_CARD_ERROR_CMD0 = 0X1 |
uint8_t const | SD_CARD_ERROR_CMD12 = 0X3 |
uint8_t const | SD_CARD_ERROR_CMD17 = 0X4 |
uint8_t const | SD_CARD_ERROR_CMD18 = 0X5 |
uint8_t const | SD_CARD_ERROR_CMD24 = 0X6 |
uint8_t const | SD_CARD_ERROR_CMD25 = 0X7 |
uint8_t const | SD_CARD_ERROR_CMD58 = 0X8 |
uint8_t const | SD_CARD_ERROR_CMD59 = 0X1A |
uint8_t const | SD_CARD_ERROR_CMD8 = 0X2 |
uint8_t const | SD_CARD_ERROR_ERASE = 0XC |
uint8_t const | SD_CARD_ERROR_ERASE_SINGLE_BLOCK = 0XD |
uint8_t const | SD_CARD_ERROR_ERASE_TIMEOUT = 0XE |
uint8_t const | SD_CARD_ERROR_INIT_NOT_CALLED = 0X19 |
uint8_t const | SD_CARD_ERROR_READ = 0XF |
uint8_t const | SD_CARD_ERROR_READ_CRC = 0X1B |
uint8_t const | SD_CARD_ERROR_READ_REG = 0X10 |
uint8_t const | SD_CARD_ERROR_READ_TIMEOUT = 0X11 |
uint8_t const | SD_CARD_ERROR_SCK_RATE = 0X18 |
uint8_t const | SD_CARD_ERROR_SPI_DMA = 0X1C |
uint8_t const | SD_CARD_ERROR_STOP_TRAN = 0X12 |
uint8_t const | SD_CARD_ERROR_WRITE = 0X13 |
uint8_t const | SD_CARD_ERROR_WRITE_BLOCK_ZERO = 0X14 |
uint8_t const | SD_CARD_ERROR_WRITE_MULTIPLE = 0X15 |
uint8_t const | SD_CARD_ERROR_WRITE_PROGRAMMING = 0X16 |
uint8_t const | SD_CARD_ERROR_WRITE_TIMEOUT = 0X17 |
uint8_t const | SD_CARD_TYPE_SD1 = 1 |
uint8_t const | SD_CARD_TYPE_SD2 = 2 |
uint8_t const | SD_CARD_TYPE_SDHC = 3 |
Sd2Card class for V2 SD/SDHC cards.
+uint8_t const SD_CARD_ERROR_ACMD23 = 0X9 | +
SET_WR_BLK_ERASE_COUNT failed
+ +uint8_t const SD_CARD_ERROR_ACMD41 = 0XA | +
ACMD41 initialization process timeout
+ +uint8_t const SD_CARD_ERROR_BAD_CSD = 0XB | +
card returned a bad CSR version field
+ +uint8_t const SD_CARD_ERROR_CMD0 = 0X1 | +
timeout error for command CMD0 (initialize card in SPI mode)
+ +uint8_t const SD_CARD_ERROR_CMD12 = 0X3 | +
card returned an error response for CMD12 (stop multiblock read)
+ +uint8_t const SD_CARD_ERROR_CMD17 = 0X4 | +
card returned an error response for CMD17 (read block)
+ +uint8_t const SD_CARD_ERROR_CMD18 = 0X5 | +
card returned an error response for CMD18 (read multiple block)
+ +uint8_t const SD_CARD_ERROR_CMD24 = 0X6 | +
card returned an error response for CMD24 (write block)
+ +uint8_t const SD_CARD_ERROR_CMD25 = 0X7 | +
WRITE_MULTIPLE_BLOCKS command failed
+ +uint8_t const SD_CARD_ERROR_CMD58 = 0X8 | +
card returned an error response for CMD58 (read OCR)
+ +uint8_t const SD_CARD_ERROR_CMD59 = 0X1A | +
card returned an error for CMD59 (CRC_ON_OFF)
+ +uint8_t const SD_CARD_ERROR_CMD8 = 0X2 | +
CMD8 was not accepted - not a valid SD card
+ +uint8_t const SD_CARD_ERROR_ERASE = 0XC | +
erase block group command failed
+ +uint8_t const SD_CARD_ERROR_ERASE_SINGLE_BLOCK = 0XD | +
card not capable of single block erase
+ +uint8_t const SD_CARD_ERROR_ERASE_TIMEOUT = 0XE | +
Erase sequence timed out
+ +uint8_t const SD_CARD_ERROR_INIT_NOT_CALLED = 0X19 | +
init() not called
+ +uint8_t const SD_CARD_ERROR_READ = 0XF | +
card returned an error token instead of read data
+ +uint8_t const SD_CARD_ERROR_READ_CRC = 0X1B | +
invalid read CRC
+ +uint8_t const SD_CARD_ERROR_READ_REG = 0X10 | +
read CID or CSD failed
+ +uint8_t const SD_CARD_ERROR_READ_TIMEOUT = 0X11 | +
timeout while waiting for start of read data
+ +uint8_t const SD_CARD_ERROR_SCK_RATE = 0X18 | +
incorrect rate selected
+ +uint8_t const SD_CARD_ERROR_SPI_DMA = 0X1C | +
SPI DMA error
+ +uint8_t const SD_CARD_ERROR_STOP_TRAN = 0X12 | +
card did not accept STOP_TRAN_TOKEN
+ +uint8_t const SD_CARD_ERROR_WRITE = 0X13 | +
card returned an error token as a response to a write operation
+ +uint8_t const SD_CARD_ERROR_WRITE_BLOCK_ZERO = 0X14 | +
attempt to write protected block zero
+ +uint8_t const SD_CARD_ERROR_WRITE_MULTIPLE = 0X15 | +
card did not go ready for a multiple block write
+ +uint8_t const SD_CARD_ERROR_WRITE_PROGRAMMING = 0X16 | +
card returned an error to a CMD13 status check after a write
+ +uint8_t const SD_CARD_ERROR_WRITE_TIMEOUT = 0X17 | +
timeout occurred during write programming
+ +uint8_t const SD_CARD_TYPE_SD1 = 1 | +
Standard capacity V1 SD card
+ +uint8_t const SD_CARD_TYPE_SD2 = 2 | +
Standard capacity V2 SD card
+ +uint8_t const SD_CARD_TYPE_SDHC = 3 | +
High Capacity SD card
+ +
+ SdFat
+
+ |
+
SdBaseFile class. +More...
+#include <Arduino.h>
#include <SdFatConfig.h>
#include <SdVolume.h>
#include <utility/FatApiConstants.h>
+Classes | |
struct | FatPos_t |
internal type for istream do not use in user apps More... | |
class | SdBaseFile |
Base class for SdFile with Print and C++ streams. More... | |
+Macros | |
#define | PGM_P const char* |
#define | pgm_read_byte(addr) (*(const unsigned char*)(addr)) |
#define | pgm_read_word(addr) (*(const uint16_t*)(addr)) |
#define | PROGMEM const |
#define | PSTR(x) (x) |
+Variables | |
uint8_t const | FAT_FILE_TYPE_CLOSED = 0 |
uint8_t const | FAT_FILE_TYPE_MIN_DIR = FAT_FILE_TYPE_ROOT_FIXED |
uint8_t const | FAT_FILE_TYPE_NORMAL = 1 |
uint8_t const | FAT_FILE_TYPE_ROOT32 = 3 |
uint8_t const | FAT_FILE_TYPE_ROOT_FIXED = 2 |
uint8_t const | FAT_FILE_TYPE_SUBDIR = 4 |
SdBaseFile class.
+#define PGM_P const char* | +
pointer to flash for ARM
+ +#define pgm_read_byte | +( | ++ | addr | ) | +(*(const unsigned char*)(addr)) | +
read 8-bits from flash for ARM
+ +#define pgm_read_word | +( | ++ | addr | ) | +(*(const uint16_t*)(addr)) | +
read 16-bits from flash for ARM
+ +#define PROGMEM const | +
store in flash for ARM
+ +#define PSTR | +( | ++ | x | ) | +(x) | +
store literal string in flash for ARM
+ +uint8_t const FAT_FILE_TYPE_CLOSED = 0 | +
This file has not been opened.
+ +uint8_t const FAT_FILE_TYPE_MIN_DIR = FAT_FILE_TYPE_ROOT_FIXED | +
Test value for directory type
+ +uint8_t const FAT_FILE_TYPE_NORMAL = 1 | +
A normal file
+ +uint8_t const FAT_FILE_TYPE_ROOT32 = 3 | +
A FAT32 root directory
+ +uint8_t const FAT_FILE_TYPE_ROOT_FIXED = 2 | +
A FAT12 or FAT16 root directory
+ +uint8_t const FAT_FILE_TYPE_SUBDIR = 4 | +
A subdirectory file
+ +
+ SdFat
+
+ |
+
#include <SdFile.h>
#include <SdStream.h>
#include <StdioStream.h>
#include <ArduinoStream.h>
#include <MinimumSerial.h>
+Classes | |
class | SdFat |
Integration class for the SdFat library. More... | |
+Macros | |
#define | DBG_FAIL_MACRO |
#define | SD_FAT_VERSION 20141025 |
SdFat class.
+#define DBG_FAIL_MACRO | +
Macro for debug.
+ +#define SD_FAT_VERSION 20141025 | +
SdFat version YYYYMMDD
+ +
+ SdFat
+
+ |
+
configuration definitions +More...
+#include <stdint.h>
+Macros | |
#define | AVR_SOFT_SPI 0 |
#define | DESTRUCTOR_CLOSES_FILE 0 |
#define | DUE_SOFT_SPI 0 |
#define | ENABLE_SPI_TRANSACTION 0 |
#define | ENABLE_SPI_YIELD 0 |
#define | ENDL_CALLS_FLUSH 0 |
#define | FAT12_SUPPORT 0 |
#define | LEONARDO_SOFT_SPI 0 |
#define | MEGA_SOFT_SPI 0 |
#define | SD_FILE_USES_STREAM 0 |
#define | TEENSY3_SOFT_SPI 0 |
#define | USE_ARDUINO_SPI_LIBRARY 0 |
#define | USE_MULTI_BLOCK_SD_IO 1 |
#define | USE_MULTIPLE_CARDS 0 |
#define | USE_SD_CRC 0 |
#define | USE_SEPARATE_FAT_CACHE 0 |
#define | USE_SERIAL_FOR_STD_OUT 0 |
+Variables | |
uint8_t const | SOFT_SPI_CS_PIN = 10 |
uint8_t const | SOFT_SPI_MISO_PIN = 12 |
uint8_t const | SOFT_SPI_MOSI_PIN = 11 |
uint8_t const | SOFT_SPI_SCK_PIN = 13 |
const uint8_t | SPI_SCK_INIT_DIVISOR = 128 |
configuration definitions
+#define AVR_SOFT_SPI 0 | +
Set AVR_SOFT_SPI nonzero to use software SPI on all AVR Arduinos.
+ +#define DESTRUCTOR_CLOSES_FILE 0 | +
Set DESTRUCTOR_CLOSES_FILE nonzero to close a file in its destructor.
+Causes use of lots of heap in ARM.
+ +#define DUE_SOFT_SPI 0 | +
Set DUE_SOFT_SPI nonzero to use software SPI on Due Arduinos.
+ +#define ENABLE_SPI_TRANSACTION 0 | +
Set ENABLE_SPI_TRANSACTION nonzero to enable the SPI transaction feature of the standard Arduino SPI library. You must include SPI.h in your sketches when ENABLE_SPI_TRANSACTION is nonzero.
+ +#define ENABLE_SPI_YIELD 0 | +
Set ENABLE_SPI_YIELD nonzero to enable release of the SPI bus during SD card busy waits.
+This will allow interrupt routines to access the SPI bus if ENABLE_SPI_TRANSACTION is nonzero.
+Setting ENABLE_SPI_YIELD will introduce some extra overhead and will slightly slow transfer rates. A few older SD cards may fail when ENABLE_SPI_YIELD is nonzero.
+ +#define ENDL_CALLS_FLUSH 0 | +
Call flush for endl if ENDL_CALLS_FLUSH is nonzero
+The standard for iostreams is to call flush. This is very costly for SdFat. Each call to flush causes 2048 bytes of I/O to the SD.
+SdFat has a single 512 byte buffer for SD I/O so it must write the current data block to the SD, read the directory block from the SD, update the directory entry, write the directory block to the SD and read the data block back into the buffer.
+The SD flash memory controller is not designed for this many rewrites so performance may be reduced by more than a factor of 100.
+If ENDL_CALLS_FLUSH is zero, you must call flush and/or close to force all data to be written to the SD.
+ +#define FAT12_SUPPORT 0 | +
Set FAT12_SUPPORT nonzero to enable use if FAT12 volumes. FAT12 has not been well tested and requires additional flash.
+ +#define LEONARDO_SOFT_SPI 0 | +
Set LEONARDO_SOFT_SPI nonzero to use software SPI on Leonardo Arduinos. LEONARDO_SOFT_SPI allows an unmodified 328 Shield to be used on Leonardo Arduinos.
+ +#define MEGA_SOFT_SPI 0 | +
Set MEGA_SOFT_SPI nonzero to use software SPI on Mega Arduinos. MEGA_SOFT_SPI allows an unmodified 328 Shield to be used on Mega Arduinos.
+ +#define SD_FILE_USES_STREAM 0 | +
#define TEENSY3_SOFT_SPI 0 | +
Set TEENSY3_SOFT_SPI nonzero to use software SPI on Teensy 3.x boards.
+ +#define USE_ARDUINO_SPI_LIBRARY 0 | +
Set USE_ARDUINO_SPI_LIBRARY nonzero to force use of Arduino Standard SPI library. This will override native and software SPI for all boards.
+ +#define USE_MULTI_BLOCK_SD_IO 1 | +
Set USE_MULTI_BLOCK_SD_IO nonzero to use multi-block SD read/write.
+Don't use mult-block read/write on small AVR boards.
+ +#define USE_MULTIPLE_CARDS 0 | +
To use multiple SD cards set USE_MULTIPLE_CARDS nonzero.
+Using multiple cards costs about 200 bytes of flash.
+Each card requires about 550 bytes of SRAM so use of a Mega is recommended.
+ +#define USE_SD_CRC 0 | +
To enable SD card CRC checking set USE_SD_CRC nonzero.
+Set USE_SD_CRC to 1 to use a smaller slower CRC-CCITT function.
+Set USE_SD_CRC to 2 to used a larger faster table driven CRC-CCITT function.
+ +#define USE_SEPARATE_FAT_CACHE 0 | +
Set USE_SEPARATE_FAT_CACHE nonzero to use a second 512 byte cache for FAT table entries. Improves performance for large writes that are not a multiple of 512 bytes.
+ +#define USE_SERIAL_FOR_STD_OUT 0 | +
For AVR
+Set USE_SERIAL_FOR_STD_OUT nonzero to use Serial (the HardwareSerial class) for error messages and output from print functions like ls().
+If USE_SERIAL_FOR_STD_OUT is zero, a small non-interrupt driven class is used to output messages to serial port zero. This allows an alternate Serial library like SerialPort to be used with SdFat.
+You can redirect stdOut with SdFat::setStdOut(Print* stream) and get the current stream with SdFat::stdOut().
+ +uint8_t const SOFT_SPI_CS_PIN = 10 | +
Define software SPI pins. Default allows Uno shields to be used on other boards.Default Software SPI chip select pin
+ +uint8_t const SOFT_SPI_MISO_PIN = 12 | +
Software SPI Master In Slave Out pin
+ +uint8_t const SOFT_SPI_MOSI_PIN = 11 | +
Software SPI Master Out Slave In pin
+ +uint8_t const SOFT_SPI_SCK_PIN = 13 | +
Software SPI Clock pin
+ +const uint8_t SPI_SCK_INIT_DIVISOR = 128 | +
SPI SCK divisor for SD initialization commands. or greater
+ +
+ SdFat
+
+ |
+
Useful utility functions. +More...
+#include <SdFat.h>
+Macros | |
#define | PgmPrint(x) SerialPrint_P(PSTR(x)) |
#define | PgmPrintln(x) SerialPrintln_P(PSTR(x)) |
+Functions | |
int | SdFatUtil::FreeRam () |
void | SdFatUtil::print_P (Print *pr, PGM_P str) |
void | SdFatUtil::println_P (Print *pr, PGM_P str) |
void | SdFatUtil::SerialPrint_P (PGM_P str) |
void | SdFatUtil::SerialPrintln_P (PGM_P str) |
Useful utility functions.
+#define PgmPrint | +( | ++ | x | ) | +SerialPrint_P(PSTR(x)) | +
Store and print a string in flash memory.
+ +#define PgmPrintln | +( | ++ | x | ) | +SerialPrintln_P(PSTR(x)) | +
Store and print a string in flash memory followed by a CR/LF.
+ +
+ SdFat
+
+ |
+
+Classes | |
class | File |
Arduino SD.h style File API. More... | |
class | SdFile |
SdBaseFile with Arduino Stream. More... | |
+Macros | |
#define | FILE_READ O_READ |
#define | FILE_WRITE (O_RDWR | O_CREAT | O_AT_END) |
SdFile class.
+#define FILE_READ O_READ | +
Arduino SD.h style flag for open for read.
+ +#define FILE_WRITE (O_RDWR | O_CREAT | O_AT_END) | +
Arduino SD.h style flag for open at EOF for read/write with create.
+ +
+ SdFat
+
+ |
+
SdSpi class for V2 SD/SDHC cards. +More...
++Classes | |
class | SdSpi |
SPI class for access to SD and SDHC flash memory cards. More... | |
+Macros | |
#define | USE_AVR_NATIVE_SPI_INLINE 1 |
+Variables | |
uint8_t const | SD_CHIP_SELECT_PIN = SS |
SdSpi class for V2 SD/SDHC cards.
+#define USE_AVR_NATIVE_SPI_INLINE 1 | +
inline avr native functions if nonzero.
+ +uint8_t const SD_CHIP_SELECT_PIN = SS | +
The default chip select pin for the SD card is SS.
+ +
+ SdFat
+
+ |
+
fstream, ifstream, and ofstream classes +More...
++Classes | |
class | fstream |
SD file input/output stream. More... | |
class | ifstream |
SD file input stream. More... | |
class | ofstream |
SD card output stream. More... | |
class | SdStreamBase |
Base class for SD streams. More... | |
+ SdFat
+
+ |
+
+Classes | |
union | cache_t |
Cache for an SD data block. More... | |
class | SdVolume |
Access FAT16 and FAT32 volumes on SD and SDHC cards. More... | |
SdVolume class.
+
+ SdFat
+
+ |
+
StdioStream class. +More...
+#include <limits.h>
#include <Arduino.h>
#include <SdFat.h>
#include <SdBaseFile.h>
#include <stdio.h>
+Classes | |
class | StdioStream |
StdioStream implements a minimal stdio stream. More... | |
+Macros | |
#define | EOF (-1) |
#define | NULL 0 |
#define | SEEK_CUR 1 |
#define | SEEK_END 2 |
#define | SEEK_SET 0 |
+Variables | |
const uint8_t | STREAM_BUF_SIZE = 64 |
const uint8_t | UNGETC_BUF_SIZE = 2 |
StdioStream class.
+#define EOF (-1) | +
End-of-file return value.
+ +#define NULL 0 | +
Null pointer
+ +#define SEEK_CUR 1 | +
Seek relative to current position.
+ +#define SEEK_END 2 | +
Seek relative to end-of-file.
+ +#define SEEK_SET 0 | +
Seek relative to start-of-file.
+ +const uint8_t STREAM_BUF_SIZE = 64 | +
Total size of stream buffer. The entire buffer is used for output. During input UNGETC_BUF_SIZE of this space is reserved for ungetc.
+ +const uint8_t UNGETC_BUF_SIZE = 2 | +
Amount of buffer allocated for ungetc during input.
+ +
+ SdFat
+
+ |
+
CArduinoInStream | Input stream for Arduino Stream objects |
CArduinoOutStream | Output stream for Arduino Print objects |
Ccache_t | Cache for an SD data block |
CFatPos_t | Internal type for istream do not use in user apps |
CFile | Arduino SD.h style File API |
Cfstream | SD file input/output stream |
Cibufstream | Parse a char string |
Cifstream | SD file input stream |
Cios | Error and state information for all streams |
Cios_base | Base class for all streams |
Ciostream | Input/Output stream |
Cistream | Input Stream |
CMinimumSerial | Mini serial class for the SdFat library |
Cobufstream | Format a char string |
Cofstream | SD card output stream |
Costream | Output Stream |
Cpgm | Type for string in flash |
CSd2Card | Raw access to SD and SDHC flash memory cards |
CSdBaseFile | Base class for SdFile with Print and C++ streams |
CSdFat | Integration class for the SdFat library |
CSdFile | SdBaseFile with Arduino Stream |
CSdSpi | SPI class for access to SD and SDHC flash memory cards |
CSdStreamBase | Base class for SD streams |
CSdVolume | Access FAT16 and FAT32 volumes on SD and SDHC cards |
Csetfill | Type for setfill manipulator |
Csetprecision | Type for setprecision manipulator |
Csetw | Type for setw manipulator |
CStdioStream | StdioStream implements a minimal stdio stream |
+ SdFat
+
+ |
+
ibufstream and obufstream classes +More...
+#include <iostream.h>
+Classes | |
class | ibufstream |
parse a char string More... | |
class | obufstream |
format a char string More... | |
ibufstream and obufstream classes
+
+ SdFat
+
+ |
+
This is the complete list of members for ArduinoInStream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ArduinoInStream(Stream &hws, char *buf, size_t size) | ArduinoInStream | inline |
ate | ios_base | static |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
cur enum value | ios_base | |
dec | ios_base | static |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
fail() const | ios | inline |
failbit | ios_base | static |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
fmtflags typedef | ios_base | |
gcount() const | istream | inline |
get() | istream | |
get(char &ch) | istream | |
get(char *str, streamsize n, char delim= '\n') | istream | |
getline(char *str, streamsize count, char delim= '\n') | istream | |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
ibufstream() | ibufstream | inline |
ibufstream(const char *str) | ibufstream | inlineexplicit |
ignore(streamsize n=1, int delim=-1) | istream | |
in | ios_base | static |
init(const char *str) | ibufstream | inline |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
istream() (defined in istream) | istream | inline |
left | ios_base | static |
oct | ios_base | static |
off_type typedef | ios_base | |
openmode typedef | ios_base | |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator>>(istream &(*pf)(istream &str)) | istream | inline |
operator>>(ios_base &(*pf)(ios_base &str)) | istream | inline |
operator>>(ios &(*pf)(ios &str)) | istream | inline |
operator>>(char *str) | istream | inline |
operator>>(char &ch) | istream | inline |
operator>>(signed char *str) | istream | inline |
operator>>(signed char &ch) | istream | inline |
operator>>(unsigned char *str) | istream | inline |
operator>>(unsigned char &ch) | istream | inline |
operator>>(bool &arg) | istream | inline |
operator>>(short &arg) | istream | inline |
operator>>(unsigned short &arg) | istream | inline |
operator>>(int &arg) | istream | inline |
operator>>(unsigned int &arg) | istream | inline |
operator>>(long &arg) | istream | inline |
operator>>(unsigned long &arg) | istream | inline |
operator>>(double &arg) | istream | inline |
operator>>(float &arg) | istream | inline |
operator>>(void *&arg) | istream | inline |
out | ios_base | static |
peek() | istream | |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
rdstate() const | ios | inline |
readline() | ArduinoInStream | inline |
right | ios_base | static |
seekdir enum name | ios_base | |
seekg(pos_type pos) | istream | inline |
seekg(off_type off, seekdir way) | istream | inline |
seekoff(off_type off, seekdir way) | ArduinoInStream | inlineprotected |
seekpos(pos_type pos) | ArduinoInStream | inlineprotected |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipWhite() | istream | |
skipws | ios_base | static |
streamsize typedef | ios_base | |
tellg() | istream | inline |
trunc | ios_base | static |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
+ SdFat
+
+ |
+
Input stream for Arduino Stream objects. + More...
+ +#include <ArduinoStream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
ArduinoInStream (Stream &hws, char *buf, size_t size) | |
bool | bad () const |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
streamsize | gcount () const |
int | get () |
istream & | get (char &ch) |
istream & | get (char *str, streamsize n, char delim= '\n') |
istream & | getline (char *str, streamsize count, char delim= '\n') |
bool | good () const |
istream & | ignore (streamsize n=1, int delim=-1) |
void | init (const char *str) |
operator const void * () const | |
bool | operator! () const |
istream & | operator>> (istream &(*pf)(istream &str)) |
istream & | operator>> (ios_base &(*pf)(ios_base &str)) |
istream & | operator>> (ios &(*pf)(ios &str)) |
istream & | operator>> (char *str) |
istream & | operator>> (char &ch) |
istream & | operator>> (signed char *str) |
istream & | operator>> (signed char &ch) |
istream & | operator>> (unsigned char *str) |
istream & | operator>> (unsigned char &ch) |
istream & | operator>> (bool &arg) |
istream & | operator>> (short &arg) |
istream & | operator>> (unsigned short &arg) |
istream & | operator>> (int &arg) |
istream & | operator>> (unsigned int &arg) |
istream & | operator>> (long &arg) |
istream & | operator>> (unsigned long &arg) |
istream & | operator>> (double &arg) |
istream & | operator>> (float &arg) |
istream & | operator>> (void *&arg) |
int | peek () |
int | precision () const |
int | precision (unsigned int n) |
iostate | rdstate () const |
void | readline () |
istream & | seekg (pos_type pos) |
istream & | seekg (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
void | skipWhite () |
pos_type | tellg () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
bool | seekoff (off_type off, seekdir way) |
bool | seekpos (pos_type pos) |
Input stream for Arduino Stream objects.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inline | +
Constructor
[in] | hws | hardware stream |
[in] | buf | buffer for input line |
[in] | size | size of input buffer |
+
|
+ +inlineinherited | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract a character if one is available.
+
+
|
+ +inherited | +
Extract a character if one is available.
+[out] | c | location to receive the extracted character. |
+
|
+ +inherited | +
Extract characters.
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, n is less than 1, n-1 characters are extracted, or the next character equals delim (delim is not extracted). If no characters are extracted failbit is set. If end-of-file occurs the eofbit is set.
+
+
|
+ +inherited | +
Extract characters
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, the next character equals delim (delim is extracted), or n-1 characters are extracted.
+The failbit is set if no characters are extracted or n-1 characters are extracted. If end-of-file occurs the eofbit is set.
+
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract characters and discard them.
+[in] | n | maximum number of characters to ignore. |
[in] | delim | Delimiter. |
Characters are extracted until extraction fails, n characters are extracted, or the next input character equals delim (the delimiter is extracted). If end-of-file occurs the eofbit is set.
+Failures are indicated by the state of the stream.
+
+
|
+ +inlineinherited | +
Initialize an ibufstream
[in] | str | pointer to string to be parsed Warning: The string will not be copied so must stay in scope. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a value of type bool.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type double.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type float.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type void*.
[out] | arg | location to store the value. |
+
|
+ +inherited | +
Return the next available character without consuming it.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
+
|
+ +inline | +
read a line.
+ +Set the stream position
[in] | pos | The absolute position in which to move the read pointer. |
+
|
+ +inlineprotected | +
Internal - do not use.
[in] | off | |
[in] | way |
+
|
+ +inlineprotected | +
Internal - do not use.
[in] | pos |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inherited | +
used to implement ws()
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for ArduinoOutStream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ArduinoOutStream(Print &pr) | ArduinoOutStream | inlineexplicit |
ate | ios_base | static |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
cur enum value | ios_base | |
dec | ios_base | static |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
fail() const | ios | inline |
failbit | ios_base | static |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
flush() | ostream | inline |
fmtflags typedef | ios_base | |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
left | ios_base | static |
oct | ios_base | static |
off_type typedef | ios_base | |
openmode typedef | ios_base | |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator<<(ostream &(*pf)(ostream &str)) | ostream | inline |
operator<<(ios_base &(*pf)(ios_base &str)) | ostream | inline |
operator<<(bool arg) | ostream | inline |
operator<<(const char *arg) | ostream | inline |
operator<<(const signed char *arg) | ostream | inline |
operator<<(const unsigned char *arg) | ostream | inline |
operator<<(char arg) | ostream | inline |
operator<<(signed char arg) | ostream | inline |
operator<<(unsigned char arg) | ostream | inline |
operator<<(double arg) | ostream | inline |
operator<<(float arg) | ostream | inline |
operator<<(short arg) | ostream | inline |
operator<<(unsigned short arg) | ostream | inline |
operator<<(int arg) | ostream | inline |
operator<<(unsigned int arg) | ostream | inline |
operator<<(long arg) | ostream | inline |
operator<<(unsigned long arg) | ostream | inline |
operator<<(const void *arg) | ostream | inline |
operator<<(pgm arg) | ostream | inline |
operator<<(const __FlashStringHelper *arg) | ostream | inline |
ostream() (defined in ostream) | ostream | inline |
out | ios_base | static |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
put(char ch) | ostream | inline |
rdstate() const | ios | inline |
right | ios_base | static |
seekdir enum name | ios_base | |
seekp(pos_type pos) | ostream | inline |
seekp(off_type off, seekdir way) | ostream | inline |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipws | ios_base | static |
streamsize typedef | ios_base | |
tellp() | ostream | inline |
trunc | ios_base | static |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
+ SdFat
+
+ |
+
Output stream for Arduino Print objects. + More...
+ +#include <ArduinoStream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
ArduinoOutStream (Print &pr) | |
bool | bad () const |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
ostream & | flush () |
bool | good () const |
operator const void * () const | |
bool | operator! () const |
ostream & | operator<< (ostream &(*pf)(ostream &str)) |
ostream & | operator<< (ios_base &(*pf)(ios_base &str)) |
ostream & | operator<< (bool arg) |
ostream & | operator<< (const char *arg) |
ostream & | operator<< (const signed char *arg) |
ostream & | operator<< (const unsigned char *arg) |
ostream & | operator<< (char arg) |
ostream & | operator<< (signed char arg) |
ostream & | operator<< (unsigned char arg) |
ostream & | operator<< (double arg) |
ostream & | operator<< (float arg) |
ostream & | operator<< (short arg) |
ostream & | operator<< (unsigned short arg) |
ostream & | operator<< (int arg) |
ostream & | operator<< (unsigned int arg) |
ostream & | operator<< (long arg) |
ostream & | operator<< (unsigned long arg) |
ostream & | operator<< (const void *arg) |
ostream & | operator<< (pgm arg) |
ostream & | operator<< (const __FlashStringHelper *arg) |
int | precision () const |
int | precision (unsigned int n) |
ostream & | put (char ch) |
iostate | rdstate () const |
ostream & | seekp (pos_type pos) |
ostream & | seekp (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
pos_type | tellp () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
Output stream for Arduino Print objects.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inlineexplicit | +
constructor
+[in] | pr | Print object for this ArduinoOutStream. |
+
|
+ +inlineinherited | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inlineinherited | +
Flushes the buffer associated with this stream. The flush function calls the sync function of the associated file.
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Output bool
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output double
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output float
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output pointer
[in] | arg | value to output |
Output a string from flash using the pstr() macro
[in] | arg | pgm struct pointing to string |
+
|
+ +inlineinherited | +
Output a string from flash using the Arduino F() macro.
[in] | arg | pointing to flash string |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
Puts a character in a stream.
+The unformatted output function inserts the element ch. It returns *this.
+[in] | ch | The character |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the write pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for File, including all inherited members.
+available() | File | inline |
clearWriteError() | File | inline |
close() | SdBaseFile | |
contiguousRange(uint32_t *bgnBlock, uint32_t *endBlock) | SdBaseFile | |
createContiguous(SdBaseFile *dirFile, const char *path, uint32_t size) | SdBaseFile | |
curCluster() const | SdBaseFile | inline |
curPosition() const | SdBaseFile | inline |
cwd() | SdBaseFile | inlinestatic |
dateTimeCallback(void(*dateTime)(uint16_t *date, uint16_t *time)) | SdBaseFile | inlinestatic |
dateTimeCallbackCancel() | SdBaseFile | inlinestatic |
dirEntry(dir_t *dir) | SdBaseFile | |
dirName(const dir_t &dir, char *name) | SdBaseFile | static |
exists(const char *name) | SdBaseFile | |
fgets(char *str, int16_t num, char *delim=0) | SdBaseFile | |
fileSize() const | SdBaseFile | inline |
firstCluster() const | SdBaseFile | inline |
flush() | File | inline |
getFilename(char *name) | SdBaseFile | |
getpos(FatPos_t *pos) | SdBaseFile | |
getWriteError() | File | inline |
isDir() const | SdBaseFile | inline |
isDirectory() | File | inline |
isFile() const | SdBaseFile | inline |
isOpen() const | SdBaseFile | inline |
isRoot() const | SdBaseFile | inline |
isSubDir() const | SdBaseFile | inline |
ls(Print *pr, uint8_t flags=0, uint8_t indent=0) | SdBaseFile | |
ls(uint8_t flags=0) | SdBaseFile | |
mkdir(SdBaseFile *dir, const char *path, bool pFlag=true) | SdBaseFile | |
name() | File | inline |
open(SdBaseFile *dirFile, uint16_t index, uint8_t oflag) | SdBaseFile | |
open(SdBaseFile *dirFile, const char *path, uint8_t oflag) | SdBaseFile | |
open(const char *path, uint8_t oflag=O_READ) | SdBaseFile | |
openNext(SdBaseFile *dirFile, uint8_t oflag) | SdBaseFile | |
openNextFile(uint8_t mode=O_READ) | File | inline |
openRoot(SdVolume *vol) | SdBaseFile | |
operator bool() | File | inline |
peek() | File | inline |
position() | File | inline |
printCreateDateTime(Print *pr) | SdBaseFile | |
printFatDate(uint16_t fatDate) | SdBaseFile | static |
printFatDate(Print *pr, uint16_t fatDate) | SdBaseFile | static |
printFatTime(uint16_t fatTime) | SdBaseFile | static |
printFatTime(Print *pr, uint16_t fatTime) | SdBaseFile | static |
printField(float value, char term, uint8_t prec=2) | SdBaseFile | |
printField(int16_t value, char term) | SdBaseFile | |
printField(uint16_t value, char term) | SdBaseFile | |
printField(int32_t value, char term) | SdBaseFile | |
printField(uint32_t value, char term) | SdBaseFile | |
printFileSize(Print *pr) | SdBaseFile | |
printModifyDateTime(Print *pr) | SdBaseFile | |
printName() | SdBaseFile | |
printName(Print *pr) | SdBaseFile | |
read() | File | inline |
read(void *buf, size_t nbyte) | File | inline |
readDir(dir_t *dir) | SdBaseFile | |
remove(SdBaseFile *dirFile, const char *path) | SdBaseFile | static |
remove() | SdBaseFile | |
rename(SdBaseFile *dirFile, const char *newPath) | SdBaseFile | |
rewind() | SdBaseFile | inline |
rewindDirectory() | File | inline |
rmdir() | SdBaseFile | |
rmRfStar() | SdBaseFile | |
SdBaseFile() | SdBaseFile | inline |
SdBaseFile(const char *path, uint8_t oflag) | SdBaseFile | |
seek(uint32_t pos) | File | inline |
seekCur(int32_t offset) | SdBaseFile | inline |
seekEnd(int32_t offset=0) | SdBaseFile | inline |
seekSet(uint32_t pos) | SdBaseFile | |
setpos(FatPos_t *pos) | SdBaseFile | |
size() | File | inline |
sync() | SdBaseFile | |
timestamp(SdBaseFile *file) | SdBaseFile | |
timestamp(uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) | SdBaseFile | |
truncate(uint32_t size) | SdBaseFile | |
type() const | SdBaseFile | inline |
volume() const | SdBaseFile | inline |
write(uint8_t b) | File | inline |
write(const void *buf, size_t nbyte) | File | |
write(const uint8_t *buf, size_t size) | File | inline |
writeError | SdBaseFile |
+ SdFat
+
+ |
+
Arduino SD.h style File API. + More...
+ +#include <SdFile.h>
+Public Member Functions | |
int | available () |
void | clearWriteError () |
bool | close () |
bool | contiguousRange (uint32_t *bgnBlock, uint32_t *endBlock) |
bool | createContiguous (SdBaseFile *dirFile, const char *path, uint32_t size) |
uint32_t | curCluster () const |
uint32_t | curPosition () const |
bool | dirEntry (dir_t *dir) |
bool | exists (const char *name) |
int16_t | fgets (char *str, int16_t num, char *delim=0) |
uint32_t | fileSize () const |
uint32_t | firstCluster () const |
void | flush () |
bool | getFilename (char *name) |
void | getpos (FatPos_t *pos) |
bool | getWriteError () |
bool | isDir () const |
bool | isDirectory () |
bool | isFile () const |
bool | isOpen () const |
bool | isRoot () const |
bool | isSubDir () const |
void | ls (Print *pr, uint8_t flags=0, uint8_t indent=0) |
void | ls (uint8_t flags=0) |
bool | mkdir (SdBaseFile *dir, const char *path, bool pFlag=true) |
char * | name () |
bool | open (SdBaseFile *dirFile, uint16_t index, uint8_t oflag) |
bool | open (SdBaseFile *dirFile, const char *path, uint8_t oflag) |
bool | open (const char *path, uint8_t oflag=O_READ) |
bool | openNext (SdBaseFile *dirFile, uint8_t oflag) |
File | openNextFile (uint8_t mode=O_READ) |
bool | openRoot (SdVolume *vol) |
operator bool () | |
int | peek () |
uint32_t | position () |
bool | printCreateDateTime (Print *pr) |
int | printField (float value, char term, uint8_t prec=2) |
int | printField (int16_t value, char term) |
int | printField (uint16_t value, char term) |
int | printField (int32_t value, char term) |
int | printField (uint32_t value, char term) |
size_t | printFileSize (Print *pr) |
bool | printModifyDateTime (Print *pr) |
size_t | printName () |
size_t | printName (Print *pr) |
int | read () |
int | read (void *buf, size_t nbyte) |
int8_t | readDir (dir_t *dir) |
bool | remove () |
bool | rename (SdBaseFile *dirFile, const char *newPath) |
void | rewind () |
void | rewindDirectory () |
bool | rmdir () |
bool | rmRfStar () |
bool | seek (uint32_t pos) |
bool | seekCur (int32_t offset) |
bool | seekEnd (int32_t offset=0) |
bool | seekSet (uint32_t pos) |
void | setpos (FatPos_t *pos) |
uint32_t | size () |
bool | sync () |
bool | timestamp (SdBaseFile *file) |
bool | timestamp (uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) |
bool | truncate (uint32_t size) |
uint8_t | type () const |
SdVolume * | volume () const |
size_t | write (uint8_t b) |
int | write (const void *buf, size_t nbyte) |
size_t | write (const uint8_t *buf, size_t size) |
+Static Public Member Functions | |
static SdBaseFile * | cwd () |
static void | dateTimeCallback (void(*dateTime)(uint16_t *date, uint16_t *time)) |
static void | dateTimeCallbackCancel () |
static void | dirName (const dir_t &dir, char *name) |
static void | printFatDate (uint16_t fatDate) |
static void | printFatDate (Print *pr, uint16_t fatDate) |
static void | printFatTime (uint16_t fatTime) |
static void | printFatTime (Print *pr, uint16_t fatTime) |
static bool | remove (SdBaseFile *dirFile, const char *path) |
+Public Attributes | |
bool | writeError |
Arduino SD.h style File API.
+
+
|
+ +inline | +
+
|
+ +inline | +
Set writeError to zero
+ +
+
|
+ +inherited | +
Close a file and force cached data and directory information to be written to the storage device.
+
+
|
+ +inherited | +
Check for contiguous file and return its raw block range.
+[out] | bgnBlock | the first block address for the file. |
[out] | endBlock | the last block address for the file. |
+
|
+ +inherited | +
Create and open a new contiguous file of a specified size.
+[in] | dirFile | The directory where the file will be created. |
[in] | path | A path with a valid DOS 8.3 file name. |
[in] | size | The desired file size. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlinestaticinherited | +
+
|
+ +inlinestaticinherited | +
Set the date/time callback function
+[in] | dateTime | The user's call back function. The callback function is of the form: |
Sets the function that is called when a file is created or when a file's directory entry is modified by sync(). All timestamps, access, creation, and modify, are set when a file is created. sync() maintains the last access date and last modify date/time.
+See the timestamp() function.
+ +
+
|
+ +inlinestaticinherited | +
Cancel the date/time callback function.
+ +
+
|
+ +inherited | +
Return a file's directory entry.
+[out] | dir | Location for return of the file's directory entry. |
+
|
+ +staticinherited | +
Format the name field of dir into the 13 byte array name in standard 8.3 short name format.
+[in] | dir | The directory structure containing the name. |
[out] | name | A 13 byte char array for the formatted name. |
+
|
+ +inherited | +
Test for the existence of a file in a directory
+[in] | name | Name of the file to be tested for. |
The calling instance must be an open directory file.
+dirFile.exists("TOFIND.TXT") searches for "TOFIND.TXT" in the directory dirFile.
+
+
|
+ +inherited | +
Get a string from a file.
+fgets() reads bytes from a file into the array pointed to by str, until num - 1 bytes are read, or a delimiter is read and transferred to str, or end-of-file is encountered. The string is then terminated with a null byte.
+fgets() deletes CR, '\r', from the string. This insures only a '\n' terminates the string for Windows text files which use CRLF for newline.
+[out] | str | Pointer to the array where the string is stored. |
[in] | num | Maximum number of characters to be read (including the final null byte). Usually the length of the array str is used. |
[in] | delim | Optional set of delimiters. The default is "\n". |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inline | +
Ensure that any bytes written to the file are saved to the SD card.
+ +
+
|
+ +inherited | +
Get a file's name
+[out] | name | An array of 13 characters for the file's name. |
+
|
+ +inherited | +
get position for streams
[out] | pos | struct to receive position |
+
|
+ +inline | +
+
|
+ +inlineinherited | +
+
|
+ +inline | +
This function reports if the current file is a directory or not.
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
List directory contents.
+[in] | pr | Print stream for list. |
[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+[in] | indent | Amount of space before file name. Used for recursive list to indicate subdirectory level. |
+
|
+ +inherited | +
List directory contents to stdOut.
+[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+ +
+
|
+ +inherited | +
Make a new directory.
+[in] | parent | An open SdFat instance for the directory that will contain the new directory. |
[in] | path | A path with a valid 8.3 DOS name for the new directory. |
[in] | pFlag | Create missing parent directories if true. |
+
|
+ +inline | +
+
|
+ +inherited | +
Open a file by index.
+[in] | dirFile | An open SdFat instance for the directory. |
[in] | index | The index of the directory entry for the file to be opened. The value for index is (directory file position)/32. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags O_READ, O_WRITE, O_TRUNC, and O_SYNC. |
See open() by path for definition of flags.
+
|
+ +inherited | +
Open a file or directory by name.
+[in] | dirFile | An open SdFat instance for the directory containing the file to be opened. |
[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags from the following list |
O_READ - Open for reading.
+O_RDONLY - Same as O_READ.
+O_WRITE - Open for writing.
+O_WRONLY - Same as O_WRITE.
+O_RDWR - Open for reading and writing.
+O_APPEND - If set, the file offset shall be set to the end of the file prior to each write.
+O_AT_END - Set the initial position at the end of the file.
+O_CREAT - If the file exists, this flag has no effect except as noted under O_EXCL below. Otherwise, the file shall be created
+O_EXCL - If O_CREAT and O_EXCL are set, open() shall fail if the file exists.
+O_SYNC - Call sync() after each write. This flag should not be used with write(uint8_t), write_P(PGM_P), writeln_P(PGM_P), or the Arduino Print class. These functions do character at a time writes so sync() will be called after each byte.
+O_TRUNC - If the file exists and is a regular file, and the file is successfully opened and is not read only, its length shall be truncated to 0.
+WARNING: A given file must not be opened by more than one SdBaseFile object or file corruption may occur.
+
+
|
+ +inherited | +
Open a file in the current working directory.
+[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of open flags. see SdBaseFile::open(SdBaseFile*, const char*, uint8_t). |
+
|
+ +inherited | +
Open the next file or subdirectory in a directory.
+[in] | dirFile | An open SdFat instance for the directory containing the file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags O_READ, O_WRITE, O_TRUNC, and O_SYNC. |
See open() by path for definition of flags.
+
|
+ +inline | +
Opens the next file or folder in a directory.
+[in] | mode | open mode flags. |
+
|
+ +inherited | +
Open a volume's root directory.
+[in] | vol | The FAT volume containing the root directory to be opened. |
+
|
+ +inline | +
The parenthesis operator.
+
+
|
+ +inline | +
Return the next available byte without consuming it.
+
+
|
+ +inline | +
+
|
+ +inherited | +
Print a file's creation date and time
+[in] | pr | Print stream for output. |
+
|
+ +staticinherited | +
Print a directory date field to stdOut.
+Format is yyyy-mm-dd.
+[in] | fatDate | The date field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory date field.
+Format is yyyy-mm-dd.
+[in] | pr | Print stream for output. |
[in] | fatDate | The date field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory time field to stdOut.
+Format is hh:mm:ss.
+[in] | fatTime | The time field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory time field.
+Format is hh:mm:ss.
+[in] | pr | Print stream for output. |
[in] | fatTime | The time field from a directory entry. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
[in] | prec | Number of digits after decimal point. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a file's size.
+[in] | pr | Print stream for output. |
+
|
+ +inherited | +
Print a file's modify date and time
+[in] | pr | Print stream for output. |
+
|
+ +inherited | +
Print a file's name to stdOut
+
+
|
+ +inherited | +
Print a file's name
+[in] | pr | Print stream for output. |
+
|
+ +inline | +
Read the next byte from a file.
+
+
|
+ +inline | +
Read data from a file starting at the current position.
+[out] | buf | Pointer to the location that will receive the data. |
[in] | nbyte | Maximum number of bytes to read. |
+
|
+ +inherited | +
Read the next directory entry from a directory file.
+[out] | dir | The dir_t struct that will receive the data. |
+
|
+ +staticinherited | +
Remove a file.
+The directory entry and all data for the file are deleted.
+[in] | dirFile | The directory that contains the file. |
[in] | path | Path for the file to be removed. |
+
|
+ +inherited | +
Remove a file.
+The directory entry and all data for the file are deleted.
+
+
|
+ +inherited | +
Rename a file or subdirectory.
+[in] | dirFile | Directory for the new path. |
[in] | newPath | New path name for the file/directory. |
+
|
+ +inlineinherited | +
Set the file's current position to zero.
+ +
+
|
+ +inline | +
Rewind a file if it is a directory
+ +
+
|
+ +inherited | +
Remove a directory file.
+The directory file will be removed only if it is empty and is not the root directory. rmdir() follows DOS and Windows and ignores the read-only attribute for the directory.
+
+
|
+ +inherited | +
Recursively delete a directory and all contained files.
+This is like the Unix/Linux 'rm -rf *' if called with the root directory hence the name.
+Warning - This will remove all contents of the directory including subdirectories. The directory will then be removed if it is not root. The read-only attribute for files will be ignored.
+
+
|
+ +inline | +
Seek to a new position in the file, which must be between 0 and the size of the file (inclusive).
+[in] | pos | the new file position. |
+
|
+ +inlineinherited | +
Set the files position to current position + pos. See seekSet().
[in] | offset | The new position in bytes from the current position. |
+
|
+ +inlineinherited | +
Set the files position to end-of-file + offset. See seekSet().
[in] | offset | The new position in bytes from end-of-file. |
+
|
+ +inherited | +
Sets a file's position.
+[in] | pos | The new position in bytes from the beginning of the file. |
+
|
+ +inherited | +
set position for streams
[out] | pos | struct with value for new position |
+
|
+ +inline | +
+
|
+ +inherited | +
The sync() call causes all modified data and directory fields to be written to the storage device.
+
+
|
+ +inherited | +
Copy a file's timestamps
+[in] | file | File to copy timestamps from. |
+
|
+ +inherited | +
Set a file's timestamps in its directory entry.
+[in] | flags | Values for flags are constructed by a bitwise-inclusive OR of flags from the following list |
T_ACCESS - Set the file's last access date.
+T_CREATE - Set the file's creation date and time.
+T_WRITE - Set the file's last write/modification date and time.
+[in] | year | Valid range 1980 - 2107 inclusive. |
[in] | month | Valid range 1 - 12 inclusive. |
[in] | day | Valid range 1 - 31 inclusive. |
[in] | hour | Valid range 0 - 23 inclusive. |
[in] | minute | Valid range 0 - 59 inclusive. |
[in] | second | Valid range 0 - 59 inclusive |
+
|
+ +inherited | +
Truncate a file to a specified length. The current file position will be maintained if it is less than or equal to length otherwise it will be set to end of file.
+[in] | length | The desired length for the file. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inline | +
Write a byte to a file. Required by the Arduino Print class.
[in] | b | the byte to be written. Use getWriteError to check for errors. |
int File::write | +( | +const void * | +buf, | +
+ | + | size_t | +nbyte | +
+ | ) | ++ |
Write data to an open file.
+[in] | buf | Pointer to the location of the data to be written. |
[in] | nbyte | Number of bytes to write. |
+
|
+ +inline | +
Write data to an open file. Form required by Print.
+[in] | buf | Pointer to the location of the data to be written. |
[in] | size | Number of bytes to write. |
+
|
+ +inherited | +
+ SdFat
+
+ |
+
This is the complete list of members for MinimumSerial, including all inherited members.
+begin(uint32_t baud) | MinimumSerial | |
read() | MinimumSerial | |
write(uint8_t b) | MinimumSerial |
+ SdFat
+
+ |
+
mini serial class for the SdFat library. + More...
+ +#include <MinimumSerial.h>
+Public Member Functions | |
void | begin (uint32_t baud) |
int | read () |
size_t | write (uint8_t b) |
mini serial class for the SdFat library.
+void MinimumSerial::begin | +( | +uint32_t | +baud | ) | ++ |
Set baud rate for serial port zero and enable in non interrupt mode. Do not call this function if you use another serial library.
[in] | baud | rate |
int MinimumSerial::read | +( | +) | ++ |
Unbuffered read
size_t MinimumSerial::write | +( | +uint8_t | +b | ) | ++ |
Unbuffered write
+[in] | b | byte to write. |
+ SdFat
+
+ |
+
This is the complete list of members for Sd2Card, including all inherited members.
+begin(uint8_t chipSelectPin=SD_CHIP_SELECT_PIN, uint8_t sckDivisor=SPI_FULL_SPEED) | Sd2Card | |
cardSize() | Sd2Card | |
erase(uint32_t firstBlock, uint32_t lastBlock) | Sd2Card | |
eraseSingleBlockEnable() | Sd2Card | |
error(uint8_t code) | Sd2Card | inline |
errorCode() const | Sd2Card | inline |
errorData() const | Sd2Card | inline |
init(uint8_t sckDivisor=SPI_FULL_SPEED, uint8_t chipSelectPin=SD_CHIP_SELECT_PIN) | Sd2Card | inline |
isBusy() | Sd2Card | |
readBlock(uint32_t block, uint8_t *dst) | Sd2Card | |
readCID(cid_t *cid) | Sd2Card | inline |
readCSD(csd_t *csd) | Sd2Card | inline |
readData(uint8_t *dst) | Sd2Card | |
readOCR(uint32_t *ocr) | Sd2Card | |
readStart(uint32_t blockNumber) | Sd2Card | |
readStop() | Sd2Card | |
sckDivisor() | Sd2Card | inline |
Sd2Card() | Sd2Card | inline |
type() const | Sd2Card | inline |
writeBlock(uint32_t blockNumber, const uint8_t *src) | Sd2Card | |
writeData(const uint8_t *src) | Sd2Card | |
writeStart(uint32_t blockNumber, uint32_t eraseCount) | Sd2Card | |
writeStop() | Sd2Card |
+ SdFat
+
+ |
+
Raw access to SD and SDHC flash memory cards. + More...
+ +#include <Sd2Card.h>
+Public Member Functions | |
bool | begin (uint8_t chipSelectPin=SD_CHIP_SELECT_PIN, uint8_t sckDivisor=SPI_FULL_SPEED) |
uint32_t | cardSize () |
bool | erase (uint32_t firstBlock, uint32_t lastBlock) |
bool | eraseSingleBlockEnable () |
void | error (uint8_t code) |
int | errorCode () const |
int | errorData () const |
bool | init (uint8_t sckDivisor=SPI_FULL_SPEED, uint8_t chipSelectPin=SD_CHIP_SELECT_PIN) |
bool | isBusy () |
bool | readBlock (uint32_t block, uint8_t *dst) |
bool | readCID (cid_t *cid) |
bool | readCSD (csd_t *csd) |
bool | readData (uint8_t *dst) |
bool | readOCR (uint32_t *ocr) |
bool | readStart (uint32_t blockNumber) |
bool | readStop () |
uint8_t | sckDivisor () |
Sd2Card () | |
int | type () const |
bool | writeBlock (uint32_t blockNumber, const uint8_t *src) |
bool | writeData (const uint8_t *src) |
bool | writeStart (uint32_t blockNumber, uint32_t eraseCount) |
bool | writeStop () |
Raw access to SD and SDHC flash memory cards.
+
+
|
+ +inline | +
Construct an instance of Sd2Card.
+ +bool Sd2Card::begin | +( | +uint8_t | +chipSelectPin = SD_CHIP_SELECT_PIN , |
+
+ | + | uint8_t | +sckDivisor = SPI_FULL_SPEED |
+
+ | ) | ++ |
Initialize an SD flash memory card.
+[in] | chipSelectPin | SD chip select pin number. |
[in] | sckDivisor | SPI SCK clock rate divisor. |
uint32_t Sd2Card::cardSize | +( | +) | ++ |
Determine the size of an SD flash memory card.
+bool Sd2Card::erase | +( | +uint32_t | +firstBlock, | +
+ | + | uint32_t | +lastBlock | +
+ | ) | ++ |
Erase a range of blocks.
+[in] | firstBlock | The address of the first block in the range. |
[in] | lastBlock | The address of the last block in the range. |
bool Sd2Card::eraseSingleBlockEnable | +( | +) | ++ |
Determine if card supports single block erase.
+
+
|
+ +inline | +
Set SD error code.
[in] | code | value for error code. |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
Initialize an SD flash memory card.
+[in] | chipSelectPin | SD chip select pin number. |
[in] | sckDivisor | SPI SCK clock rate divisor. |
bool Sd2Card::isBusy | +( | +) | ++ |
Check for busy. MISO low indicates the card is busy.
+bool Sd2Card::readBlock | +( | +uint32_t | +blockNumber, | +
+ | + | uint8_t * | +dst | +
+ | ) | ++ |
Read a 512 byte block from an SD card.
+[in] | blockNumber | Logical block to be read. |
[out] | dst | Pointer to the location that will receive the data. |
+
|
+ +inline | +
Read a card's CID register. The CID contains card identification information such as Manufacturer ID, Product name, Product serial number and Manufacturing date.
+[out] | cid | pointer to area for returned data. |
+
|
+ +inline | +
Read a card's CSD register. The CSD contains Card-Specific Data that provides information regarding access to the card's contents.
+[out] | csd | pointer to area for returned data. |
bool Sd2Card::readData | +( | +uint8_t * | +dst | ) | ++ |
Read one data block in a multiple block read sequence
+[in] | dst | Pointer to the location for the data to be read. |
bool Sd2Card::readOCR | +( | +uint32_t * | +ocr | ) | ++ |
Read OCR register.
+[out] | ocr | Value of OCR register. |
bool Sd2Card::readStart | +( | +uint32_t | +blockNumber | ) | ++ |
Start a read multiple blocks sequence.
+[in] | blockNumber | Address of first block in sequence. |
bool Sd2Card::readStop | +( | +) | ++ |
End a read multiple blocks sequence.
+
+
|
+ +inline | +
Return SCK divisor.
+
+
|
+ +inline | +
Return the card type: SD V1, SD V2 or SDHC
bool Sd2Card::writeBlock | +( | +uint32_t | +blockNumber, | +
+ | + | const uint8_t * | +src | +
+ | ) | ++ |
Writes a 512 byte block to an SD card.
+[in] | blockNumber | Logical block to be written. |
[in] | src | Pointer to the location of the data to be written. |
bool Sd2Card::writeData | +( | +const uint8_t * | +src | ) | ++ |
Write one data block in a multiple block write sequence
[in] | src | Pointer to the location of the data to be written. |
bool Sd2Card::writeStart | +( | +uint32_t | +blockNumber, | +
+ | + | uint32_t | +eraseCount | +
+ | ) | ++ |
Start a write multiple blocks sequence.
+[in] | blockNumber | Address of first block in sequence. |
[in] | eraseCount | The number of blocks to be pre-erased. |
bool Sd2Card::writeStop | +( | +) | ++ |
End a write multiple blocks sequence.
+
+ SdFat
+
+ |
+
This is the complete list of members for SdBaseFile, including all inherited members.
+available() | SdBaseFile | inline |
clearWriteError() | SdBaseFile | inline |
close() | SdBaseFile | |
contiguousRange(uint32_t *bgnBlock, uint32_t *endBlock) | SdBaseFile | |
createContiguous(SdBaseFile *dirFile, const char *path, uint32_t size) | SdBaseFile | |
curCluster() const | SdBaseFile | inline |
curPosition() const | SdBaseFile | inline |
cwd() | SdBaseFile | inlinestatic |
dateTimeCallback(void(*dateTime)(uint16_t *date, uint16_t *time)) | SdBaseFile | inlinestatic |
dateTimeCallbackCancel() | SdBaseFile | inlinestatic |
dirEntry(dir_t *dir) | SdBaseFile | |
dirName(const dir_t &dir, char *name) | SdBaseFile | static |
exists(const char *name) | SdBaseFile | |
fgets(char *str, int16_t num, char *delim=0) | SdBaseFile | |
fileSize() const | SdBaseFile | inline |
firstCluster() const | SdBaseFile | inline |
getFilename(char *name) | SdBaseFile | |
getpos(FatPos_t *pos) | SdBaseFile | |
getWriteError() | SdBaseFile | inline |
isDir() const | SdBaseFile | inline |
isFile() const | SdBaseFile | inline |
isOpen() const | SdBaseFile | inline |
isRoot() const | SdBaseFile | inline |
isSubDir() const | SdBaseFile | inline |
ls(Print *pr, uint8_t flags=0, uint8_t indent=0) | SdBaseFile | |
ls(uint8_t flags=0) | SdBaseFile | |
mkdir(SdBaseFile *dir, const char *path, bool pFlag=true) | SdBaseFile | |
open(SdBaseFile *dirFile, uint16_t index, uint8_t oflag) | SdBaseFile | |
open(SdBaseFile *dirFile, const char *path, uint8_t oflag) | SdBaseFile | |
open(const char *path, uint8_t oflag=O_READ) | SdBaseFile | |
openNext(SdBaseFile *dirFile, uint8_t oflag) | SdBaseFile | |
openRoot(SdVolume *vol) | SdBaseFile | |
peek() | SdBaseFile | |
printCreateDateTime(Print *pr) | SdBaseFile | |
printFatDate(uint16_t fatDate) | SdBaseFile | static |
printFatDate(Print *pr, uint16_t fatDate) | SdBaseFile | static |
printFatTime(uint16_t fatTime) | SdBaseFile | static |
printFatTime(Print *pr, uint16_t fatTime) | SdBaseFile | static |
printField(float value, char term, uint8_t prec=2) | SdBaseFile | |
printField(int16_t value, char term) | SdBaseFile | |
printField(uint16_t value, char term) | SdBaseFile | |
printField(int32_t value, char term) | SdBaseFile | |
printField(uint32_t value, char term) | SdBaseFile | |
printFileSize(Print *pr) | SdBaseFile | |
printModifyDateTime(Print *pr) | SdBaseFile | |
printName() | SdBaseFile | |
printName(Print *pr) | SdBaseFile | |
read() | SdBaseFile | |
read(void *buf, size_t nbyte) | SdBaseFile | |
readDir(dir_t *dir) | SdBaseFile | |
remove(SdBaseFile *dirFile, const char *path) | SdBaseFile | static |
remove() | SdBaseFile | |
rename(SdBaseFile *dirFile, const char *newPath) | SdBaseFile | |
rewind() | SdBaseFile | inline |
rmdir() | SdBaseFile | |
rmRfStar() | SdBaseFile | |
SdBaseFile() | SdBaseFile | inline |
SdBaseFile(const char *path, uint8_t oflag) | SdBaseFile | |
SdFat (defined in SdBaseFile) | SdBaseFile | friend |
seekCur(int32_t offset) | SdBaseFile | inline |
seekEnd(int32_t offset=0) | SdBaseFile | inline |
seekSet(uint32_t pos) | SdBaseFile | |
setpos(FatPos_t *pos) | SdBaseFile | |
sync() | SdBaseFile | |
timestamp(SdBaseFile *file) | SdBaseFile | |
timestamp(uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) | SdBaseFile | |
truncate(uint32_t size) | SdBaseFile | |
type() const | SdBaseFile | inline |
volume() const | SdBaseFile | inline |
write(const void *buf, size_t nbyte) | SdBaseFile | |
writeError | SdBaseFile |
+ SdFat
+
+ |
+
Base class for SdFile with Print and C++ streams. + More...
+ +#include <SdBaseFile.h>
+Public Member Functions | |
uint32_t | available () |
void | clearWriteError () |
bool | close () |
bool | contiguousRange (uint32_t *bgnBlock, uint32_t *endBlock) |
bool | createContiguous (SdBaseFile *dirFile, const char *path, uint32_t size) |
uint32_t | curCluster () const |
uint32_t | curPosition () const |
bool | dirEntry (dir_t *dir) |
bool | exists (const char *name) |
int16_t | fgets (char *str, int16_t num, char *delim=0) |
uint32_t | fileSize () const |
uint32_t | firstCluster () const |
bool | getFilename (char *name) |
void | getpos (FatPos_t *pos) |
bool | getWriteError () |
bool | isDir () const |
bool | isFile () const |
bool | isOpen () const |
bool | isRoot () const |
bool | isSubDir () const |
void | ls (Print *pr, uint8_t flags=0, uint8_t indent=0) |
void | ls (uint8_t flags=0) |
bool | mkdir (SdBaseFile *dir, const char *path, bool pFlag=true) |
bool | open (SdBaseFile *dirFile, uint16_t index, uint8_t oflag) |
bool | open (SdBaseFile *dirFile, const char *path, uint8_t oflag) |
bool | open (const char *path, uint8_t oflag=O_READ) |
bool | openNext (SdBaseFile *dirFile, uint8_t oflag) |
bool | openRoot (SdVolume *vol) |
int | peek () |
bool | printCreateDateTime (Print *pr) |
int | printField (float value, char term, uint8_t prec=2) |
int | printField (int16_t value, char term) |
int | printField (uint16_t value, char term) |
int | printField (int32_t value, char term) |
int | printField (uint32_t value, char term) |
size_t | printFileSize (Print *pr) |
bool | printModifyDateTime (Print *pr) |
size_t | printName () |
size_t | printName (Print *pr) |
int16_t | read () |
int | read (void *buf, size_t nbyte) |
int8_t | readDir (dir_t *dir) |
bool | remove () |
bool | rename (SdBaseFile *dirFile, const char *newPath) |
void | rewind () |
bool | rmdir () |
bool | rmRfStar () |
SdBaseFile () | |
SdBaseFile (const char *path, uint8_t oflag) | |
bool | seekCur (int32_t offset) |
bool | seekEnd (int32_t offset=0) |
bool | seekSet (uint32_t pos) |
void | setpos (FatPos_t *pos) |
bool | sync () |
bool | timestamp (SdBaseFile *file) |
bool | timestamp (uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) |
bool | truncate (uint32_t size) |
uint8_t | type () const |
SdVolume * | volume () const |
int | write (const void *buf, size_t nbyte) |
+Static Public Member Functions | |
static SdBaseFile * | cwd () |
static void | dateTimeCallback (void(*dateTime)(uint16_t *date, uint16_t *time)) |
static void | dateTimeCallbackCancel () |
static void | dirName (const dir_t &dir, char *name) |
static void | printFatDate (uint16_t fatDate) |
static void | printFatDate (Print *pr, uint16_t fatDate) |
static void | printFatTime (uint16_t fatTime) |
static void | printFatTime (Print *pr, uint16_t fatTime) |
static bool | remove (SdBaseFile *dirFile, const char *path) |
+Public Attributes | |
bool | writeError |
+Friends | |
+class | SdFat |
Base class for SdFile with Print and C++ streams.
+
+
|
+ +inline | +
Create an instance.
+ +SdBaseFile::SdBaseFile | +( | +const char * | +path, | +
+ | + | uint8_t | +oflag | +
+ | ) | ++ |
Create a file object and open it in the current working directory.
+[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of open flags. see SdBaseFile::open(SdBaseFile*, const char*, uint8_t). |
+
|
+ +inline | +
+
|
+ +inline | +
Set writeError to zero
+ +bool SdBaseFile::close | +( | +) | ++ |
Close a file and force cached data and directory information to be written to the storage device.
+bool SdBaseFile::contiguousRange | +( | +uint32_t * | +bgnBlock, | +
+ | + | uint32_t * | +endBlock | +
+ | ) | ++ |
Check for contiguous file and return its raw block range.
+[out] | bgnBlock | the first block address for the file. |
[out] | endBlock | the last block address for the file. |
bool SdBaseFile::createContiguous | +( | +SdBaseFile * | +dirFile, | +
+ | + | const char * | +path, | +
+ | + | uint32_t | +size | +
+ | ) | ++ |
Create and open a new contiguous file of a specified size.
+[in] | dirFile | The directory where the file will be created. |
[in] | path | A path with a valid DOS 8.3 file name. |
[in] | size | The desired file size. |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inlinestatic | +
+
|
+ +inlinestatic | +
Set the date/time callback function
+[in] | dateTime | The user's call back function. The callback function is of the form: |
Sets the function that is called when a file is created or when a file's directory entry is modified by sync(). All timestamps, access, creation, and modify, are set when a file is created. sync() maintains the last access date and last modify date/time.
+See the timestamp() function.
+ +
+
|
+ +inlinestatic | +
Cancel the date/time callback function.
+ +bool SdBaseFile::dirEntry | +( | +dir_t * | +dir | ) | ++ |
Return a file's directory entry.
+[out] | dir | Location for return of the file's directory entry. |
+
|
+ +static | +
Format the name field of dir into the 13 byte array name in standard 8.3 short name format.
+[in] | dir | The directory structure containing the name. |
[out] | name | A 13 byte char array for the formatted name. |
bool SdBaseFile::exists | +( | +const char * | +name | ) | ++ |
Test for the existence of a file in a directory
+[in] | name | Name of the file to be tested for. |
The calling instance must be an open directory file.
+dirFile.exists("TOFIND.TXT") searches for "TOFIND.TXT" in the directory dirFile.
+int16_t SdBaseFile::fgets | +( | +char * | +str, | +
+ | + | int16_t | +num, | +
+ | + | char * | +delim = 0 |
+
+ | ) | ++ |
Get a string from a file.
+fgets() reads bytes from a file into the array pointed to by str, until num - 1 bytes are read, or a delimiter is read and transferred to str, or end-of-file is encountered. The string is then terminated with a null byte.
+fgets() deletes CR, '\r', from the string. This insures only a '\n' terminates the string for Windows text files which use CRLF for newline.
+[out] | str | Pointer to the array where the string is stored. |
[in] | num | Maximum number of characters to be read (including the final null byte). Usually the length of the array str is used. |
[in] | delim | Optional set of delimiters. The default is "\n". |
+
|
+ +inline | +
+
|
+ +inline | +
bool SdBaseFile::getFilename | +( | +char * | +name | ) | ++ |
Get a file's name
+[out] | name | An array of 13 characters for the file's name. |
void SdBaseFile::getpos | +( | +FatPos_t * | +pos | ) | ++ |
get position for streams
[out] | pos | struct to receive position |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
void SdBaseFile::ls | +( | +Print * | +pr, | +
+ | + | uint8_t | +flags = 0 , |
+
+ | + | uint8_t | +indent = 0 |
+
+ | ) | ++ |
List directory contents.
+[in] | pr | Print stream for list. |
[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+[in] | indent | Amount of space before file name. Used for recursive list to indicate subdirectory level. |
void SdBaseFile::ls | +( | +uint8_t | +flags = 0 | ) | ++ |
List directory contents to stdOut.
+[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+ +bool SdBaseFile::mkdir | +( | +SdBaseFile * | +parent, | +
+ | + | const char * | +path, | +
+ | + | bool | +pFlag = true |
+
+ | ) | ++ |
Make a new directory.
+[in] | parent | An open SdFat instance for the directory that will contain the new directory. |
[in] | path | A path with a valid 8.3 DOS name for the new directory. |
[in] | pFlag | Create missing parent directories if true. |
bool SdBaseFile::open | +( | +SdBaseFile * | +dirFile, | +
+ | + | uint16_t | +index, | +
+ | + | uint8_t | +oflag | +
+ | ) | ++ |
Open a file by index.
+[in] | dirFile | An open SdFat instance for the directory. |
[in] | index | The index of the directory entry for the file to be opened. The value for index is (directory file position)/32. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags O_READ, O_WRITE, O_TRUNC, and O_SYNC. |
See open() by path for definition of flags.
bool SdBaseFile::open | +( | +SdBaseFile * | +dirFile, | +
+ | + | const char * | +path, | +
+ | + | uint8_t | +oflag | +
+ | ) | ++ |
Open a file or directory by name.
+[in] | dirFile | An open SdFat instance for the directory containing the file to be opened. |
[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags from the following list |
O_READ - Open for reading.
+O_RDONLY - Same as O_READ.
+O_WRITE - Open for writing.
+O_WRONLY - Same as O_WRITE.
+O_RDWR - Open for reading and writing.
+O_APPEND - If set, the file offset shall be set to the end of the file prior to each write.
+O_AT_END - Set the initial position at the end of the file.
+O_CREAT - If the file exists, this flag has no effect except as noted under O_EXCL below. Otherwise, the file shall be created
+O_EXCL - If O_CREAT and O_EXCL are set, open() shall fail if the file exists.
+O_SYNC - Call sync() after each write. This flag should not be used with write(uint8_t), write_P(PGM_P), writeln_P(PGM_P), or the Arduino Print class. These functions do character at a time writes so sync() will be called after each byte.
+O_TRUNC - If the file exists and is a regular file, and the file is successfully opened and is not read only, its length shall be truncated to 0.
+WARNING: A given file must not be opened by more than one SdBaseFile object or file corruption may occur.
+bool SdBaseFile::open | +( | +const char * | +path, | +
+ | + | uint8_t | +oflag = O_READ |
+
+ | ) | ++ |
Open a file in the current working directory.
+[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of open flags. see SdBaseFile::open(SdBaseFile*, const char*, uint8_t). |
bool SdBaseFile::openNext | +( | +SdBaseFile * | +dirFile, | +
+ | + | uint8_t | +oflag | +
+ | ) | ++ |
Open the next file or subdirectory in a directory.
+[in] | dirFile | An open SdFat instance for the directory containing the file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags O_READ, O_WRITE, O_TRUNC, and O_SYNC. |
See open() by path for definition of flags.
bool SdBaseFile::openRoot | +( | +SdVolume * | +vol | ) | ++ |
Open a volume's root directory.
+[in] | vol | The FAT volume containing the root directory to be opened. |
int SdBaseFile::peek | +( | +) | ++ |
Return the next available byte without consuming it.
+bool SdBaseFile::printCreateDateTime | +( | +Print * | +pr | ) | ++ |
Print a file's creation date and time
+[in] | pr | Print stream for output. |
+
|
+ +static | +
Print a directory date field to stdOut.
+Format is yyyy-mm-dd.
+[in] | fatDate | The date field from a directory entry. |
+
|
+ +static | +
Print a directory date field.
+Format is yyyy-mm-dd.
+[in] | pr | Print stream for output. |
[in] | fatDate | The date field from a directory entry. |
+
|
+ +static | +
Print a directory time field to stdOut.
+Format is hh:mm:ss.
+[in] | fatTime | The time field from a directory entry. |
+
|
+ +static | +
Print a directory time field.
+Format is hh:mm:ss.
+[in] | pr | Print stream for output. |
[in] | fatTime | The time field from a directory entry. |
int SdBaseFile::printField | +( | +float | +value, | +
+ | + | char | +term, | +
+ | + | uint8_t | +prec = 2 |
+
+ | ) | ++ |
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
[in] | prec | Number of digits after decimal point. |
int SdBaseFile::printField | +( | +int16_t | +value, | +
+ | + | char | +term | +
+ | ) | ++ |
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
int SdBaseFile::printField | +( | +uint16_t | +value, | +
+ | + | char | +term | +
+ | ) | ++ |
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
int SdBaseFile::printField | +( | +int32_t | +value, | +
+ | + | char | +term | +
+ | ) | ++ |
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
int SdBaseFile::printField | +( | +uint32_t | +value, | +
+ | + | char | +term | +
+ | ) | ++ |
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
size_t SdBaseFile::printFileSize | +( | +Print * | +pr | ) | ++ |
Print a file's size.
+[in] | pr | Print stream for output. |
bool SdBaseFile::printModifyDateTime | +( | +Print * | +pr | ) | ++ |
Print a file's modify date and time
+[in] | pr | Print stream for output. |
size_t SdBaseFile::printName | +( | +) | ++ |
Print a file's name to stdOut
+size_t SdBaseFile::printName | +( | +Print * | +pr | ) | ++ |
Print a file's name
+[in] | pr | Print stream for output. |
int16_t SdBaseFile::read | +( | +) | ++ |
Read the next byte from a file.
+int SdBaseFile::read | +( | +void * | +buf, | +
+ | + | size_t | +nbyte | +
+ | ) | ++ |
Read data from a file starting at the current position.
+[out] | buf | Pointer to the location that will receive the data. |
[in] | nbyte | Maximum number of bytes to read. |
int8_t SdBaseFile::readDir | +( | +dir_t * | +dir | ) | ++ |
Read the next directory entry from a directory file.
+[out] | dir | The dir_t struct that will receive the data. |
+
|
+ +static | +
Remove a file.
+The directory entry and all data for the file are deleted.
+[in] | dirFile | The directory that contains the file. |
[in] | path | Path for the file to be removed. |
bool SdBaseFile::remove | +( | +) | ++ |
Remove a file.
+The directory entry and all data for the file are deleted.
+bool SdBaseFile::rename | +( | +SdBaseFile * | +dirFile, | +
+ | + | const char * | +newPath | +
+ | ) | ++ |
Rename a file or subdirectory.
+[in] | dirFile | Directory for the new path. |
[in] | newPath | New path name for the file/directory. |
+
|
+ +inline | +
Set the file's current position to zero.
+ +bool SdBaseFile::rmdir | +( | +) | ++ |
Remove a directory file.
+The directory file will be removed only if it is empty and is not the root directory. rmdir() follows DOS and Windows and ignores the read-only attribute for the directory.
+bool SdBaseFile::rmRfStar | +( | +) | ++ |
Recursively delete a directory and all contained files.
+This is like the Unix/Linux 'rm -rf *' if called with the root directory hence the name.
+Warning - This will remove all contents of the directory including subdirectories. The directory will then be removed if it is not root. The read-only attribute for files will be ignored.
+
+
|
+ +inline | +
Set the files position to current position + pos. See seekSet().
[in] | offset | The new position in bytes from the current position. |
+
|
+ +inline | +
Set the files position to end-of-file + offset. See seekSet().
[in] | offset | The new position in bytes from end-of-file. |
bool SdBaseFile::seekSet | +( | +uint32_t | +pos | ) | ++ |
Sets a file's position.
+[in] | pos | The new position in bytes from the beginning of the file. |
void SdBaseFile::setpos | +( | +FatPos_t * | +pos | ) | ++ |
set position for streams
[out] | pos | struct with value for new position |
bool SdBaseFile::sync | +( | +) | ++ |
The sync() call causes all modified data and directory fields to be written to the storage device.
+bool SdBaseFile::timestamp | +( | +SdBaseFile * | +file | ) | ++ |
Copy a file's timestamps
+[in] | file | File to copy timestamps from. |
bool SdBaseFile::timestamp | +( | +uint8_t | +flags, | +
+ | + | uint16_t | +year, | +
+ | + | uint8_t | +month, | +
+ | + | uint8_t | +day, | +
+ | + | uint8_t | +hour, | +
+ | + | uint8_t | +minute, | +
+ | + | uint8_t | +second | +
+ | ) | ++ |
Set a file's timestamps in its directory entry.
+[in] | flags | Values for flags are constructed by a bitwise-inclusive OR of flags from the following list |
T_ACCESS - Set the file's last access date.
+T_CREATE - Set the file's creation date and time.
+T_WRITE - Set the file's last write/modification date and time.
+[in] | year | Valid range 1980 - 2107 inclusive. |
[in] | month | Valid range 1 - 12 inclusive. |
[in] | day | Valid range 1 - 31 inclusive. |
[in] | hour | Valid range 0 - 23 inclusive. |
[in] | minute | Valid range 0 - 59 inclusive. |
[in] | second | Valid range 0 - 59 inclusive |
bool SdBaseFile::truncate | +( | +uint32_t | +length | ) | ++ |
Truncate a file to a specified length. The current file position will be maintained if it is less than or equal to length otherwise it will be set to end of file.
+[in] | length | The desired length for the file. |
+
|
+ +inline | +
+
|
+ +inline | +
int SdBaseFile::write | +( | +const void * | +buf, | +
+ | + | size_t | +nbyte | +
+ | ) | ++ |
Write data to an open file.
+[in] | buf | Pointer to the location of the data to be written. |
[in] | nbyte | Number of bytes to write. |
bool SdBaseFile::writeError | +
+ SdFat
+
+ |
+
This is the complete list of members for SdFat, including all inherited members.
+begin(uint8_t chipSelectPin=SD_CHIP_SELECT_PIN, uint8_t sckDivisor=SPI_FULL_SPEED) | SdFat | |
card() | SdFat | inline |
chdir(bool set_cwd=false) | SdFat | |
chdir(const char *path, bool set_cwd=false) | SdFat | |
chvol() | SdFat | |
errorHalt() | SdFat | |
errorHalt(char const *msg) | SdFat | |
errorHalt_P(PGM_P msg) | SdFat | |
errorPrint() | SdFat | |
errorPrint(char const *msg) | SdFat | |
errorPrint_P(PGM_P msg) | SdFat | |
exists(const char *name) | SdFat | |
initErrorHalt() | SdFat | |
initErrorHalt(char const *msg) | SdFat | |
initErrorHalt_P(PGM_P msg) | SdFat | |
initErrorPrint() | SdFat | |
initErrorPrint(char const *msg) | SdFat | |
initErrorPrint_P(PGM_P msg) | SdFat | |
ls(uint8_t flags=0) | SdFat | |
ls(const char *path, uint8_t flags=0) | SdFat | |
ls(Print *pr, uint8_t flags=0) | SdFat | |
ls(Print *pr, const char *path, uint8_t flags=0) | SdFat | |
mkdir(const char *path, bool pFlag=true) | SdFat | |
open(const char *path, uint8_t mode=FILE_READ) | SdFat | inline |
remove(const char *path) | SdFat | |
rename(const char *oldPath, const char *newPath) | SdFat | |
rmdir(const char *path) | SdFat | |
SdFat() (defined in SdFat) | SdFat | inline |
setStdOut(Print *stream) | SdFat | inlinestatic |
stdOut() | SdFat | inlinestatic |
truncate(const char *path, uint32_t length) | SdFat | |
vol() | SdFat | inline |
vwd() | SdFat | inline |
+ SdFat
+
+ |
+
Integration class for the SdFat library. + More...
+ +#include <SdFat.h>
+Public Member Functions | |
bool | begin (uint8_t chipSelectPin=SD_CHIP_SELECT_PIN, uint8_t sckDivisor=SPI_FULL_SPEED) |
Sd2Card * | card () |
bool | chdir (bool set_cwd=false) |
bool | chdir (const char *path, bool set_cwd=false) |
void | chvol () |
void | errorHalt () |
void | errorHalt (char const *msg) |
void | errorHalt_P (PGM_P msg) |
void | errorPrint () |
void | errorPrint (char const *msg) |
void | errorPrint_P (PGM_P msg) |
bool | exists (const char *name) |
void | initErrorHalt () |
void | initErrorHalt (char const *msg) |
void | initErrorHalt_P (PGM_P msg) |
void | initErrorPrint () |
void | initErrorPrint (char const *msg) |
void | initErrorPrint_P (PGM_P msg) |
void | ls (uint8_t flags=0) |
void | ls (const char *path, uint8_t flags=0) |
void | ls (Print *pr, uint8_t flags=0) |
void | ls (Print *pr, const char *path, uint8_t flags=0) |
bool | mkdir (const char *path, bool pFlag=true) |
File | open (const char *path, uint8_t mode=FILE_READ) |
bool | remove (const char *path) |
bool | rename (const char *oldPath, const char *newPath) |
bool | rmdir (const char *path) |
bool | truncate (const char *path, uint32_t length) |
SdVolume * | vol () |
SdBaseFile * | vwd () |
+Static Public Member Functions | |
static void | setStdOut (Print *stream) |
static Print * | stdOut () |
Integration class for the SdFat library.
+error if old IDE
+bool SdFat::begin | +( | +uint8_t | +chipSelectPin = SD_CHIP_SELECT_PIN , |
+
+ | + | uint8_t | +sckDivisor = SPI_FULL_SPEED |
+
+ | ) | ++ |
Initialize an SdFat object.
+Initializes the SD card, SD volume, and root directory.
+[in] | chipSelectPin | SD chip select pin. See Sd2Card::init(). |
[in] | sckDivisor | value for SPI SCK divisor. See Sd2Card::init(). |
+
|
+ +inline | +
bool SdFat::chdir | +( | +bool | +set_cwd = false | ) | ++ |
Change a volume's working directory to root
+Changes the volume's working directory to the SD's root directory. Optionally set the current working directory to the volume's working directory.
+[in] | set_cwd | Set the current working directory to this volume's working directory if true. |
bool SdFat::chdir | +( | +const char * | +path, | +
+ | + | bool | +set_cwd = false |
+
+ | ) | ++ |
Change a volume's working directory
+Changes the volume working directory to the path subdirectory. Optionally set the current working directory to the volume's working directory.
+Example: If the volume's working directory is "/DIR", chdir("SUB") will change the volume's working directory from "/DIR" to "/DIR/SUB".
+If path is "/", the volume's working directory will be changed to the root directory
+[in] | path | The name of the subdirectory. |
[in] | set_cwd | Set the current working directory to this volume's working directory if true. |
void SdFat::chvol | +( | +) | ++ |
Set the current working directory to a volume's working directory.
+This is useful with multiple SD cards.
+The current working directory is changed to this volume's working directory.
+This is like the Windows/DOS <drive letter>: command.
+ +void SdFat::errorHalt | +( | +) | ++ |
Print any SD error code and halt.
+ +void SdFat::errorHalt | +( | +char const * | +msg | ) | ++ |
Print msg, any SD error code, and halt.
+[in] | msg | Message to print. |
void SdFat::errorHalt_P | +( | +PGM_P | +msg | ) | ++ |
Print msg, any SD error code, and halt.
+[in] | msg | Message in program space (flash memory) to print. |
void SdFat::errorPrint | +( | +) | ++ |
Print any SD error code.
+ +void SdFat::errorPrint | +( | +char const * | +msg | ) | ++ |
Print msg, any SD error code.
+[in] | msg | Message to print. |
void SdFat::errorPrint_P | +( | +PGM_P | +msg | ) | ++ |
Print msg, any SD error code.
+[in] | msg | Message in program space (flash memory) to print. |
bool SdFat::exists | +( | +const char * | +name | ) | ++ |
Test for the existence of a file.
+[in] | name | Name of the file to be tested for. |
void SdFat::initErrorHalt | +( | +) | ++ |
Print error details and halt after SdFat::init() fails.
+ +void SdFat::initErrorHalt | +( | +char const * | +msg | ) | ++ |
Print message, error details, and halt after SdFat::init() fails.
+[in] | msg | Message to print. |
void SdFat::initErrorHalt_P | +( | +PGM_P | +msg | ) | ++ |
Print message, error details, and halt after SdFat::init() fails.
+[in] | msg | Message in program space (flash memory) to print. |
void SdFat::initErrorPrint | +( | +) | ++ |
Print error details after SdFat::init() fails.
+ +void SdFat::initErrorPrint | +( | +char const * | +msg | ) | ++ |
Print message and error details and halt after SdFat::init() fails.
+[in] | msg | Message to print. |
void SdFat::initErrorPrint_P | +( | +PGM_P | +msg | ) | ++ |
Print message and error details after SdFat::init() fails.
+[in] | msg | Message in program space (flash memory) to print. |
void SdFat::ls | +( | +uint8_t | +flags = 0 | ) | ++ |
List the directory contents of the volume working directory to stdOut.
+[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+ +void SdFat::ls | +( | +const char * | +path, | +
+ | + | uint8_t | +flags = 0 |
+
+ | ) | ++ |
List the directory contents of the volume working directory to stdOut.
+[in] | path | directory to list. |
[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+ +void SdFat::ls | +( | +Print * | +pr, | +
+ | + | uint8_t | +flags = 0 |
+
+ | ) | ++ |
List the directory contents of the volume working directory.
+[in] | pr | Print stream for the list. |
[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+ +void SdFat::ls | +( | +Print * | +pr, | +
+ | + | const char * | +path, | +
+ | + | uint8_t | +flags = 0 |
+
+ | ) | ++ |
List the directory contents of the volume working directory to stdOut.
+[in] | pr | Print stream for the list. |
[in] | path | directory to list. |
[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+ +bool SdFat::mkdir | +( | +const char * | +path, | +
+ | + | bool | +pFlag = true |
+
+ | ) | ++ |
Make a subdirectory in the volume working directory.
+[in] | path | A path with a valid 8.3 DOS name for the subdirectory. |
[in] | pFlag | Create missing parent directories if true. |
+
|
+ +inline | +
open a file
+[in] | path | location of file to be opened. |
[in] | mode | open mode flags. |
bool SdFat::remove | +( | +const char * | +path | ) | ++ |
Remove a file from the volume working directory.
+[in] | path | A path with a valid 8.3 DOS name for the file. |
bool SdFat::rename | +( | +const char * | +oldPath, | +
+ | + | const char * | +newPath | +
+ | ) | ++ |
Rename a file or subdirectory.
+[in] | oldPath | Path name to the file or subdirectory to be renamed. |
[in] | newPath | New path name of the file or subdirectory. |
The newPath object must not exist before the rename call.
+The file to be renamed must not be open. The directory entry may be moved and file system corruption could occur if the file is accessed by a file object that was opened before the rename() call.
+bool SdFat::rmdir | +( | +const char * | +path | ) | ++ |
Remove a subdirectory from the volume's working directory.
+[in] | path | A path with a valid 8.3 DOS name for the subdirectory. |
The subdirectory file will be removed only if it is empty.
+
+
|
+ +inlinestatic | +
Set stdOut Print stream for messages.
[in] | stream | The new Print stream. |
+
|
+ +inlinestatic | +
bool SdFat::truncate | +( | +const char * | +path, | +
+ | + | uint32_t | +length | +
+ | ) | ++ |
Truncate a file to a specified length. The current file position will be maintained if it is less than or equal to length otherwise it will be set to end of file.
+[in] | path | A path with a valid 8.3 DOS name for the file. |
[in] | length | The desired length for the file. |
+
|
+ +inline | +
+
|
+ +inline | +
+ SdFat
+
+ |
+
This is the complete list of members for SdFile, including all inherited members.
+available() | SdFile | inline |
clearWriteError() | SdFile | inline |
close() | SdBaseFile | |
contiguousRange(uint32_t *bgnBlock, uint32_t *endBlock) | SdBaseFile | |
createContiguous(SdBaseFile *dirFile, const char *path, uint32_t size) | SdBaseFile | |
curCluster() const | SdBaseFile | inline |
curPosition() const | SdBaseFile | inline |
cwd() | SdBaseFile | inlinestatic |
dateTimeCallback(void(*dateTime)(uint16_t *date, uint16_t *time)) | SdBaseFile | inlinestatic |
dateTimeCallbackCancel() | SdBaseFile | inlinestatic |
dirEntry(dir_t *dir) | SdBaseFile | |
dirName(const dir_t &dir, char *name) | SdBaseFile | static |
exists(const char *name) | SdBaseFile | |
fgets(char *str, int16_t num, char *delim=0) | SdBaseFile | |
fileSize() const | SdBaseFile | inline |
firstCluster() const | SdBaseFile | inline |
flush() | SdFile | inline |
getFilename(char *name) | SdBaseFile | |
getpos(FatPos_t *pos) | SdBaseFile | |
getWriteError() | SdFile | inline |
isDir() const | SdBaseFile | inline |
isFile() const | SdBaseFile | inline |
isOpen() const | SdBaseFile | inline |
isRoot() const | SdBaseFile | inline |
isSubDir() const | SdBaseFile | inline |
ls(Print *pr, uint8_t flags=0, uint8_t indent=0) | SdBaseFile | |
ls(uint8_t flags=0) | SdBaseFile | |
mkdir(SdBaseFile *dir, const char *path, bool pFlag=true) | SdBaseFile | |
open(SdBaseFile *dirFile, uint16_t index, uint8_t oflag) | SdBaseFile | |
open(SdBaseFile *dirFile, const char *path, uint8_t oflag) | SdBaseFile | |
open(const char *path, uint8_t oflag=O_READ) | SdBaseFile | |
openNext(SdBaseFile *dirFile, uint8_t oflag) | SdBaseFile | |
openRoot(SdVolume *vol) | SdBaseFile | |
peek() | SdFile | inline |
printCreateDateTime(Print *pr) | SdBaseFile | |
printFatDate(uint16_t fatDate) | SdBaseFile | static |
printFatDate(Print *pr, uint16_t fatDate) | SdBaseFile | static |
printFatTime(uint16_t fatTime) | SdBaseFile | static |
printFatTime(Print *pr, uint16_t fatTime) | SdBaseFile | static |
printField(float value, char term, uint8_t prec=2) | SdBaseFile | |
printField(int16_t value, char term) | SdBaseFile | |
printField(uint16_t value, char term) | SdBaseFile | |
printField(int32_t value, char term) | SdBaseFile | |
printField(uint32_t value, char term) | SdBaseFile | |
printFileSize(Print *pr) | SdBaseFile | |
printModifyDateTime(Print *pr) | SdBaseFile | |
printName() | SdBaseFile | |
printName(Print *pr) | SdBaseFile | |
read() | SdFile | inline |
read(void *buf, size_t nbyte) | SdFile | inline |
readDir(dir_t *dir) | SdBaseFile | |
remove(SdBaseFile *dirFile, const char *path) | SdBaseFile | static |
remove() | SdBaseFile | |
rename(SdBaseFile *dirFile, const char *newPath) | SdBaseFile | |
rewind() | SdBaseFile | inline |
rmdir() | SdBaseFile | |
rmRfStar() | SdBaseFile | |
SdBaseFile() | SdBaseFile | inline |
SdBaseFile(const char *path, uint8_t oflag) | SdBaseFile | |
SdFile() (defined in SdFile) | SdFile | inline |
SdFile(const char *name, uint8_t oflag) | SdFile | |
seekCur(int32_t offset) | SdBaseFile | inline |
seekEnd(int32_t offset=0) | SdBaseFile | inline |
seekSet(uint32_t pos) | SdBaseFile | |
setpos(FatPos_t *pos) | SdBaseFile | |
sync() | SdBaseFile | |
timestamp(SdBaseFile *file) | SdBaseFile | |
timestamp(uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) | SdBaseFile | |
truncate(uint32_t size) | SdBaseFile | |
type() const | SdBaseFile | inline |
volume() const | SdBaseFile | inline |
write(uint8_t b) | SdFile | |
write(const char *str) | SdFile | |
write(const void *buf, size_t nbyte) | SdFile | |
write(const uint8_t *buf, size_t size) | SdFile | inline |
write_P(PGM_P str) | SdFile | |
writeError | SdBaseFile | |
writeln_P(PGM_P str) | SdFile |
+ SdFat
+
+ |
+
SdBaseFile with Arduino Stream. + More...
+ +#include <SdFile.h>
+Public Member Functions | |
int | available () |
void | clearWriteError () |
bool | close () |
bool | contiguousRange (uint32_t *bgnBlock, uint32_t *endBlock) |
bool | createContiguous (SdBaseFile *dirFile, const char *path, uint32_t size) |
uint32_t | curCluster () const |
uint32_t | curPosition () const |
bool | dirEntry (dir_t *dir) |
bool | exists (const char *name) |
int16_t | fgets (char *str, int16_t num, char *delim=0) |
uint32_t | fileSize () const |
uint32_t | firstCluster () const |
void | flush () |
bool | getFilename (char *name) |
void | getpos (FatPos_t *pos) |
bool | getWriteError () |
bool | isDir () const |
bool | isFile () const |
bool | isOpen () const |
bool | isRoot () const |
bool | isSubDir () const |
void | ls (Print *pr, uint8_t flags=0, uint8_t indent=0) |
void | ls (uint8_t flags=0) |
bool | mkdir (SdBaseFile *dir, const char *path, bool pFlag=true) |
bool | open (SdBaseFile *dirFile, uint16_t index, uint8_t oflag) |
bool | open (SdBaseFile *dirFile, const char *path, uint8_t oflag) |
bool | open (const char *path, uint8_t oflag=O_READ) |
bool | openNext (SdBaseFile *dirFile, uint8_t oflag) |
bool | openRoot (SdVolume *vol) |
int | peek () |
bool | printCreateDateTime (Print *pr) |
int | printField (float value, char term, uint8_t prec=2) |
int | printField (int16_t value, char term) |
int | printField (uint16_t value, char term) |
int | printField (int32_t value, char term) |
int | printField (uint32_t value, char term) |
size_t | printFileSize (Print *pr) |
bool | printModifyDateTime (Print *pr) |
size_t | printName () |
size_t | printName (Print *pr) |
int | read () |
int | read (void *buf, size_t nbyte) |
int8_t | readDir (dir_t *dir) |
bool | remove () |
bool | rename (SdBaseFile *dirFile, const char *newPath) |
void | rewind () |
bool | rmdir () |
bool | rmRfStar () |
SdFile (const char *name, uint8_t oflag) | |
bool | seekCur (int32_t offset) |
bool | seekEnd (int32_t offset=0) |
bool | seekSet (uint32_t pos) |
void | setpos (FatPos_t *pos) |
bool | sync () |
bool | timestamp (SdBaseFile *file) |
bool | timestamp (uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) |
bool | truncate (uint32_t size) |
uint8_t | type () const |
SdVolume * | volume () const |
size_t | write (uint8_t b) |
int | write (const char *str) |
int | write (const void *buf, size_t nbyte) |
size_t | write (const uint8_t *buf, size_t size) |
void | write_P (PGM_P str) |
void | writeln_P (PGM_P str) |
+Static Public Member Functions | |
static SdBaseFile * | cwd () |
static void | dateTimeCallback (void(*dateTime)(uint16_t *date, uint16_t *time)) |
static void | dateTimeCallbackCancel () |
static void | dirName (const dir_t &dir, char *name) |
static void | printFatDate (uint16_t fatDate) |
static void | printFatDate (Print *pr, uint16_t fatDate) |
static void | printFatTime (uint16_t fatTime) |
static void | printFatTime (Print *pr, uint16_t fatTime) |
static bool | remove (SdBaseFile *dirFile, const char *path) |
+Public Attributes | |
bool | writeError |
SdBaseFile with Arduino Stream.
+SdFile::SdFile | +( | +const char * | +path, | +
+ | + | uint8_t | +oflag | +
+ | ) | ++ |
Create a file object and open it in the current working directory.
+[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of open flags. see SdBaseFile::open(SdBaseFile*, const char*, uint8_t). |
+
|
+ +inline | +
+
|
+ +inline | +
Set writeError to zero
+ +
+
|
+ +inherited | +
Close a file and force cached data and directory information to be written to the storage device.
+
+
|
+ +inherited | +
Check for contiguous file and return its raw block range.
+[out] | bgnBlock | the first block address for the file. |
[out] | endBlock | the last block address for the file. |
+
|
+ +inherited | +
Create and open a new contiguous file of a specified size.
+[in] | dirFile | The directory where the file will be created. |
[in] | path | A path with a valid DOS 8.3 file name. |
[in] | size | The desired file size. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlinestaticinherited | +
+
|
+ +inlinestaticinherited | +
Set the date/time callback function
+[in] | dateTime | The user's call back function. The callback function is of the form: |
Sets the function that is called when a file is created or when a file's directory entry is modified by sync(). All timestamps, access, creation, and modify, are set when a file is created. sync() maintains the last access date and last modify date/time.
+See the timestamp() function.
+ +
+
|
+ +inlinestaticinherited | +
Cancel the date/time callback function.
+ +
+
|
+ +inherited | +
Return a file's directory entry.
+[out] | dir | Location for return of the file's directory entry. |
+
|
+ +staticinherited | +
Format the name field of dir into the 13 byte array name in standard 8.3 short name format.
+[in] | dir | The directory structure containing the name. |
[out] | name | A 13 byte char array for the formatted name. |
+
|
+ +inherited | +
Test for the existence of a file in a directory
+[in] | name | Name of the file to be tested for. |
The calling instance must be an open directory file.
+dirFile.exists("TOFIND.TXT") searches for "TOFIND.TXT" in the directory dirFile.
+
+
|
+ +inherited | +
Get a string from a file.
+fgets() reads bytes from a file into the array pointed to by str, until num - 1 bytes are read, or a delimiter is read and transferred to str, or end-of-file is encountered. The string is then terminated with a null byte.
+fgets() deletes CR, '\r', from the string. This insures only a '\n' terminates the string for Windows text files which use CRLF for newline.
+[out] | str | Pointer to the array where the string is stored. |
[in] | num | Maximum number of characters to be read (including the final null byte). Usually the length of the array str is used. |
[in] | delim | Optional set of delimiters. The default is "\n". |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inline | +
Ensure that any bytes written to the file are saved to the SD card.
+ +
+
|
+ +inherited | +
Get a file's name
+[out] | name | An array of 13 characters for the file's name. |
+
|
+ +inherited | +
get position for streams
[out] | pos | struct to receive position |
+
|
+ +inline | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
List directory contents.
+[in] | pr | Print stream for list. |
[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+[in] | indent | Amount of space before file name. Used for recursive list to indicate subdirectory level. |
+
|
+ +inherited | +
List directory contents to stdOut.
+[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+ +
+
|
+ +inherited | +
Make a new directory.
+[in] | parent | An open SdFat instance for the directory that will contain the new directory. |
[in] | path | A path with a valid 8.3 DOS name for the new directory. |
[in] | pFlag | Create missing parent directories if true. |
+
|
+ +inherited | +
Open a file by index.
+[in] | dirFile | An open SdFat instance for the directory. |
[in] | index | The index of the directory entry for the file to be opened. The value for index is (directory file position)/32. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags O_READ, O_WRITE, O_TRUNC, and O_SYNC. |
See open() by path for definition of flags.
+
|
+ +inherited | +
Open a file or directory by name.
+[in] | dirFile | An open SdFat instance for the directory containing the file to be opened. |
[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags from the following list |
O_READ - Open for reading.
+O_RDONLY - Same as O_READ.
+O_WRITE - Open for writing.
+O_WRONLY - Same as O_WRITE.
+O_RDWR - Open for reading and writing.
+O_APPEND - If set, the file offset shall be set to the end of the file prior to each write.
+O_AT_END - Set the initial position at the end of the file.
+O_CREAT - If the file exists, this flag has no effect except as noted under O_EXCL below. Otherwise, the file shall be created
+O_EXCL - If O_CREAT and O_EXCL are set, open() shall fail if the file exists.
+O_SYNC - Call sync() after each write. This flag should not be used with write(uint8_t), write_P(PGM_P), writeln_P(PGM_P), or the Arduino Print class. These functions do character at a time writes so sync() will be called after each byte.
+O_TRUNC - If the file exists and is a regular file, and the file is successfully opened and is not read only, its length shall be truncated to 0.
+WARNING: A given file must not be opened by more than one SdBaseFile object or file corruption may occur.
+
+
|
+ +inherited | +
Open a file in the current working directory.
+[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of open flags. see SdBaseFile::open(SdBaseFile*, const char*, uint8_t). |
+
|
+ +inherited | +
Open the next file or subdirectory in a directory.
+[in] | dirFile | An open SdFat instance for the directory containing the file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags O_READ, O_WRITE, O_TRUNC, and O_SYNC. |
See open() by path for definition of flags.
+
|
+ +inherited | +
Open a volume's root directory.
+[in] | vol | The FAT volume containing the root directory to be opened. |
+
|
+ +inline | +
Return the next available byte without consuming it.
+
+
|
+ +inherited | +
Print a file's creation date and time
+[in] | pr | Print stream for output. |
+
|
+ +staticinherited | +
Print a directory date field to stdOut.
+Format is yyyy-mm-dd.
+[in] | fatDate | The date field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory date field.
+Format is yyyy-mm-dd.
+[in] | pr | Print stream for output. |
[in] | fatDate | The date field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory time field to stdOut.
+Format is hh:mm:ss.
+[in] | fatTime | The time field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory time field.
+Format is hh:mm:ss.
+[in] | pr | Print stream for output. |
[in] | fatTime | The time field from a directory entry. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
[in] | prec | Number of digits after decimal point. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a file's size.
+[in] | pr | Print stream for output. |
+
|
+ +inherited | +
Print a file's modify date and time
+[in] | pr | Print stream for output. |
+
|
+ +inherited | +
Print a file's name to stdOut
+
+
|
+ +inherited | +
Print a file's name
+[in] | pr | Print stream for output. |
+
|
+ +inline | +
Read the next byte from a file.
+
+
|
+ +inline | +
Read data from a file starting at the current position.
+[out] | buf | Pointer to the location that will receive the data. |
[in] | nbyte | Maximum number of bytes to read. |
+
|
+ +inherited | +
Read the next directory entry from a directory file.
+[out] | dir | The dir_t struct that will receive the data. |
+
|
+ +staticinherited | +
Remove a file.
+The directory entry and all data for the file are deleted.
+[in] | dirFile | The directory that contains the file. |
[in] | path | Path for the file to be removed. |
+
|
+ +inherited | +
Remove a file.
+The directory entry and all data for the file are deleted.
+
+
|
+ +inherited | +
Rename a file or subdirectory.
+[in] | dirFile | Directory for the new path. |
[in] | newPath | New path name for the file/directory. |
+
|
+ +inlineinherited | +
Set the file's current position to zero.
+ +
+
|
+ +inherited | +
Remove a directory file.
+The directory file will be removed only if it is empty and is not the root directory. rmdir() follows DOS and Windows and ignores the read-only attribute for the directory.
+
+
|
+ +inherited | +
Recursively delete a directory and all contained files.
+This is like the Unix/Linux 'rm -rf *' if called with the root directory hence the name.
+Warning - This will remove all contents of the directory including subdirectories. The directory will then be removed if it is not root. The read-only attribute for files will be ignored.
+
+
|
+ +inlineinherited | +
Set the files position to current position + pos. See seekSet().
[in] | offset | The new position in bytes from the current position. |
+
|
+ +inlineinherited | +
Set the files position to end-of-file + offset. See seekSet().
[in] | offset | The new position in bytes from end-of-file. |
+
|
+ +inherited | +
Sets a file's position.
+[in] | pos | The new position in bytes from the beginning of the file. |
+
|
+ +inherited | +
set position for streams
[out] | pos | struct with value for new position |
+
|
+ +inherited | +
The sync() call causes all modified data and directory fields to be written to the storage device.
+
+
|
+ +inherited | +
Copy a file's timestamps
+[in] | file | File to copy timestamps from. |
+
|
+ +inherited | +
Set a file's timestamps in its directory entry.
+[in] | flags | Values for flags are constructed by a bitwise-inclusive OR of flags from the following list |
T_ACCESS - Set the file's last access date.
+T_CREATE - Set the file's creation date and time.
+T_WRITE - Set the file's last write/modification date and time.
+[in] | year | Valid range 1980 - 2107 inclusive. |
[in] | month | Valid range 1 - 12 inclusive. |
[in] | day | Valid range 1 - 31 inclusive. |
[in] | hour | Valid range 0 - 23 inclusive. |
[in] | minute | Valid range 0 - 59 inclusive. |
[in] | second | Valid range 0 - 59 inclusive |
+
|
+ +inherited | +
Truncate a file to a specified length. The current file position will be maintained if it is less than or equal to length otherwise it will be set to end of file.
+[in] | length | The desired length for the file. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
size_t SdFile::write | +( | +uint8_t | +b | ) | ++ |
Write a byte to a file. Required by the Arduino Print class.
[in] | b | the byte to be written. Use getWriteError to check for errors. |
int SdFile::write | +( | +const char * | +str | ) | ++ |
Write a string to a file. Used by the Arduino Print class.
[in] | str | Pointer to the string. Use getWriteError to check for errors. |
int SdFile::write | +( | +const void * | +buf, | +
+ | + | size_t | +nbyte | +
+ | ) | ++ |
Write data to an open file.
+[in] | buf | Pointer to the location of the data to be written. |
[in] | nbyte | Number of bytes to write. |
+
|
+ +inline | +
Write data to an open file. Form required by Print.
+[in] | buf | Pointer to the location of the data to be written. |
[in] | size | Number of bytes to write. |
void SdFile::write_P | +( | +PGM_P | +str | ) | ++ |
Write a PROGMEM string to a file.
[in] | str | Pointer to the PROGMEM string. Use getWriteError to check for errors. |
void SdFile::writeln_P | +( | +PGM_P | +str | ) | ++ |
Write a PROGMEM string followed by CR/LF to a file.
[in] | str | Pointer to the PROGMEM string. Use getWriteError to check for errors. |
+
|
+ +inherited | +
+ SdFat
+
+ |
+
This is the complete list of members for SdSpi, including all inherited members.
+begin() | SdSpi | |
init(uint8_t spiDivisor) | SdSpi | |
receive() | SdSpi | |
receive(uint8_t *buf, size_t n) | SdSpi | |
send(uint8_t data) | SdSpi | |
send(const uint8_t *buf, size_t n) | SdSpi |
+ SdFat
+
+ |
+
SPI class for access to SD and SDHC flash memory cards. + More...
+ +#include <SdSpi.h>
+Public Member Functions | |
void | begin () |
void | init (uint8_t spiDivisor) |
uint8_t | receive () |
uint8_t | receive (uint8_t *buf, size_t n) |
void | send (uint8_t data) |
void | send (const uint8_t *buf, size_t n) |
SPI class for access to SD and SDHC flash memory cards.
+void SdSpi::begin | +( | +) | ++ |
Initialize the SPI bus
+ +void SdSpi::init | +( | +uint8_t | +spiDivisor | ) | ++ |
Set SPI options for access to SD/SDHC cards.
+[in] | spiDivisor | SCK clock divider relative to the system clock. |
uint8_t SdSpi::receive | +( | +) | ++ |
Receive a byte.
+uint8_t SdSpi::receive | +( | +uint8_t * | +buf, | +
+ | + | size_t | +n | +
+ | ) | ++ |
Receive multiple bytes.
+[out] | buf | Buffer to receive the data. |
[in] | n | Number of bytes to receive. |
void SdSpi::send | +( | +uint8_t | +data | ) | ++ |
Send a byte.
+[in] | data | Byte to send |
void SdSpi::send | +( | +const uint8_t * | +buf, | +
+ | + | size_t | +n | +
+ | ) | ++ |
Send multiple bytes.
+[in] | buf | Buffer for data to be sent. |
[in] | n | Number of bytes to send. |
+ SdFat
+
+ |
+
This is the complete list of members for SdStreamBase, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
available() | SdBaseFile | inlineprotected |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
clearWriteError() | SdBaseFile | inlineprotected |
close() | SdBaseFile | protected |
contiguousRange(uint32_t *bgnBlock, uint32_t *endBlock) | SdBaseFile | protected |
createContiguous(SdBaseFile *dirFile, const char *path, uint32_t size) | SdBaseFile | protected |
cur enum value | ios_base | |
curCluster() const | SdBaseFile | inlineprotected |
curPosition() const | SdBaseFile | inlineprotected |
cwd() | SdBaseFile | inlineprotectedstatic |
dateTimeCallback(void(*dateTime)(uint16_t *date, uint16_t *time)) | SdBaseFile | inlineprotectedstatic |
dateTimeCallbackCancel() | SdBaseFile | inlineprotectedstatic |
dec | ios_base | static |
dirEntry(dir_t *dir) | SdBaseFile | protected |
dirName(const dir_t &dir, char *name) | SdBaseFile | protectedstatic |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
exists(const char *name) | SdBaseFile | protected |
fail() const | ios | inline |
failbit | ios_base | static |
fgets(char *str, int16_t num, char *delim=0) | SdBaseFile | protected |
fileSize() const | SdBaseFile | inlineprotected |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
firstCluster() const | SdBaseFile | inlineprotected |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
fmtflags typedef | ios_base | |
getFilename(char *name) | SdBaseFile | protected |
getpos(FatPos_t *pos) | SdBaseFile | protected |
getWriteError() | SdBaseFile | inlineprotected |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
isDir() const | SdBaseFile | inlineprotected |
isFile() const | SdBaseFile | inlineprotected |
isOpen() const | SdBaseFile | inlineprotected |
isRoot() const | SdBaseFile | inlineprotected |
isSubDir() const | SdBaseFile | inlineprotected |
left | ios_base | static |
ls(Print *pr, uint8_t flags=0, uint8_t indent=0) | SdBaseFile | protected |
ls(uint8_t flags=0) | SdBaseFile | protected |
mkdir(SdBaseFile *dir, const char *path, bool pFlag=true) | SdBaseFile | protected |
oct | ios_base | static |
off_type typedef | ios_base | |
open(SdBaseFile *dirFile, uint16_t index, uint8_t oflag) | SdBaseFile | protected |
open(SdBaseFile *dirFile, const char *path, uint8_t oflag) | SdBaseFile | protected |
open(const char *path, uint8_t oflag=O_READ) | SdBaseFile | protected |
openmode typedef | ios_base | |
openNext(SdBaseFile *dirFile, uint8_t oflag) | SdBaseFile | protected |
openRoot(SdVolume *vol) | SdBaseFile | protected |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
out | ios_base | static |
peek() | SdBaseFile | protected |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
printCreateDateTime(Print *pr) | SdBaseFile | protected |
printFatDate(uint16_t fatDate) | SdBaseFile | protectedstatic |
printFatDate(Print *pr, uint16_t fatDate) | SdBaseFile | protectedstatic |
printFatTime(uint16_t fatTime) | SdBaseFile | protectedstatic |
printFatTime(Print *pr, uint16_t fatTime) | SdBaseFile | protectedstatic |
printField(float value, char term, uint8_t prec=2) | SdBaseFile | protected |
printField(int16_t value, char term) | SdBaseFile | protected |
printField(uint16_t value, char term) | SdBaseFile | protected |
printField(int32_t value, char term) | SdBaseFile | protected |
printField(uint32_t value, char term) | SdBaseFile | protected |
printFileSize(Print *pr) | SdBaseFile | protected |
printModifyDateTime(Print *pr) | SdBaseFile | protected |
printName() | SdBaseFile | protected |
printName(Print *pr) | SdBaseFile | protected |
rdstate() const | ios | inline |
read() | SdBaseFile | protected |
read(void *buf, size_t nbyte) | SdBaseFile | protected |
readDir(dir_t *dir) | SdBaseFile | protected |
remove(SdBaseFile *dirFile, const char *path) | SdBaseFile | protectedstatic |
remove() | SdBaseFile | protected |
rename(SdBaseFile *dirFile, const char *newPath) | SdBaseFile | protected |
rewind() | SdBaseFile | inlineprotected |
right | ios_base | static |
rmdir() | SdBaseFile | protected |
rmRfStar() | SdBaseFile | protected |
SdBaseFile() | SdBaseFile | inlineprotected |
SdBaseFile(const char *path, uint8_t oflag) | SdBaseFile | protected |
seekCur(int32_t offset) | SdBaseFile | inlineprotected |
seekdir enum name | ios_base | |
seekEnd(int32_t offset=0) | SdBaseFile | inlineprotected |
seekSet(uint32_t pos) | SdBaseFile | protected |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setpos(FatPos_t *pos) | SdBaseFile | protected |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipws | ios_base | static |
streamsize typedef | ios_base | |
sync() | SdBaseFile | protected |
timestamp(SdBaseFile *file) | SdBaseFile | protected |
timestamp(uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) | SdBaseFile | protected |
trunc | ios_base | static |
truncate(uint32_t size) | SdBaseFile | protected |
type() const | SdBaseFile | inlineprotected |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
volume() const | SdBaseFile | inlineprotected |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
write(const void *buf, size_t nbyte) | SdBaseFile | protected |
writeError | SdBaseFile | protected |
+ SdFat
+
+ |
+
Base class for SD streams. + More...
+ +#include <SdStream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
bool | good () const |
operator const void * () const | |
bool | operator! () const |
int | precision () const |
int | precision (unsigned int n) |
iostate | rdstate () const |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint32_t | available () |
void | clearWriteError () |
bool | close () |
bool | contiguousRange (uint32_t *bgnBlock, uint32_t *endBlock) |
bool | createContiguous (SdBaseFile *dirFile, const char *path, uint32_t size) |
uint32_t | curCluster () const |
uint32_t | curPosition () const |
bool | dirEntry (dir_t *dir) |
bool | exists (const char *name) |
int16_t | fgets (char *str, int16_t num, char *delim=0) |
uint32_t | fileSize () const |
uint32_t | firstCluster () const |
uint8_t | flagsToBase () |
bool | getFilename (char *name) |
void | getpos (FatPos_t *pos) |
bool | getWriteError () |
bool | isDir () const |
bool | isFile () const |
bool | isOpen () const |
bool | isRoot () const |
bool | isSubDir () const |
void | ls (Print *pr, uint8_t flags=0, uint8_t indent=0) |
void | ls (uint8_t flags=0) |
bool | mkdir (SdBaseFile *dir, const char *path, bool pFlag=true) |
bool | open (SdBaseFile *dirFile, uint16_t index, uint8_t oflag) |
bool | open (SdBaseFile *dirFile, const char *path, uint8_t oflag) |
bool | open (const char *path, uint8_t oflag=O_READ) |
bool | openNext (SdBaseFile *dirFile, uint8_t oflag) |
bool | openRoot (SdVolume *vol) |
int | peek () |
bool | printCreateDateTime (Print *pr) |
int | printField (float value, char term, uint8_t prec=2) |
int | printField (int16_t value, char term) |
int | printField (uint16_t value, char term) |
int | printField (int32_t value, char term) |
int | printField (uint32_t value, char term) |
size_t | printFileSize (Print *pr) |
bool | printModifyDateTime (Print *pr) |
size_t | printName () |
size_t | printName (Print *pr) |
int16_t | read () |
int | read (void *buf, size_t nbyte) |
int8_t | readDir (dir_t *dir) |
bool | remove () |
bool | rename (SdBaseFile *dirFile, const char *newPath) |
void | rewind () |
bool | rmdir () |
bool | rmRfStar () |
bool | seekCur (int32_t offset) |
bool | seekEnd (int32_t offset=0) |
bool | seekSet (uint32_t pos) |
void | setpos (FatPos_t *pos) |
bool | sync () |
bool | timestamp (SdBaseFile *file) |
bool | timestamp (uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) |
bool | truncate (uint32_t size) |
uint8_t | type () const |
SdVolume * | volume () const |
int | write (const void *buf, size_t nbyte) |
+Static Protected Member Functions | |
static SdBaseFile * | cwd () |
static void | dateTimeCallback (void(*dateTime)(uint16_t *date, uint16_t *time)) |
static void | dateTimeCallbackCancel () |
static void | dirName (const dir_t &dir, char *name) |
static void | printFatDate (uint16_t fatDate) |
static void | printFatDate (Print *pr, uint16_t fatDate) |
static void | printFatTime (uint16_t fatTime) |
static void | printFatTime (Print *pr, uint16_t fatTime) |
static bool | remove (SdBaseFile *dirFile, const char *path) |
+Protected Attributes | |
bool | writeError |
Base class for SD streams.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inlineinherited | +
Set writeError to zero
+ +
+
|
+ +inherited | +
Close a file and force cached data and directory information to be written to the storage device.
+
+
|
+ +inherited | +
Check for contiguous file and return its raw block range.
+[out] | bgnBlock | the first block address for the file. |
[out] | endBlock | the last block address for the file. |
+
|
+ +inherited | +
Create and open a new contiguous file of a specified size.
+[in] | dirFile | The directory where the file will be created. |
[in] | path | A path with a valid DOS 8.3 file name. |
[in] | size | The desired file size. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlinestaticinherited | +
+
|
+ +inlinestaticinherited | +
Set the date/time callback function
+[in] | dateTime | The user's call back function. The callback function is of the form: |
Sets the function that is called when a file is created or when a file's directory entry is modified by sync(). All timestamps, access, creation, and modify, are set when a file is created. sync() maintains the last access date and last modify date/time.
+See the timestamp() function.
+ +
+
|
+ +inlinestaticinherited | +
Cancel the date/time callback function.
+ +
+
|
+ +inherited | +
Return a file's directory entry.
+[out] | dir | Location for return of the file's directory entry. |
+
|
+ +staticinherited | +
Format the name field of dir into the 13 byte array name in standard 8.3 short name format.
+[in] | dir | The directory structure containing the name. |
[out] | name | A 13 byte char array for the formatted name. |
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Test for the existence of a file in a directory
+[in] | name | Name of the file to be tested for. |
The calling instance must be an open directory file.
+dirFile.exists("TOFIND.TXT") searches for "TOFIND.TXT" in the directory dirFile.
+
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Get a string from a file.
+fgets() reads bytes from a file into the array pointed to by str, until num - 1 bytes are read, or a delimiter is read and transferred to str, or end-of-file is encountered. The string is then terminated with a null byte.
+fgets() deletes CR, '\r', from the string. This insures only a '\n' terminates the string for Windows text files which use CRLF for newline.
+[out] | str | Pointer to the array where the string is stored. |
[in] | num | Maximum number of characters to be read (including the final null byte). Usually the length of the array str is used. |
[in] | delim | Optional set of delimiters. The default is "\n". |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inherited | +
Get a file's name
+[out] | name | An array of 13 characters for the file's name. |
+
|
+ +inherited | +
get position for streams
[out] | pos | struct to receive position |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
List directory contents.
+[in] | pr | Print stream for list. |
[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+[in] | indent | Amount of space before file name. Used for recursive list to indicate subdirectory level. |
+
|
+ +inherited | +
List directory contents to stdOut.
+[in] | flags | The inclusive OR of |
LS_DATE - Print file modification date
+LS_SIZE - Print file size.
+LS_R - Recursive list of subdirectories.
+ +
+
|
+ +inherited | +
Make a new directory.
+[in] | parent | An open SdFat instance for the directory that will contain the new directory. |
[in] | path | A path with a valid 8.3 DOS name for the new directory. |
[in] | pFlag | Create missing parent directories if true. |
+
|
+ +inherited | +
Open a file by index.
+[in] | dirFile | An open SdFat instance for the directory. |
[in] | index | The index of the directory entry for the file to be opened. The value for index is (directory file position)/32. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags O_READ, O_WRITE, O_TRUNC, and O_SYNC. |
See open() by path for definition of flags.
+
|
+ +inherited | +
Open a file or directory by name.
+[in] | dirFile | An open SdFat instance for the directory containing the file to be opened. |
[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags from the following list |
O_READ - Open for reading.
+O_RDONLY - Same as O_READ.
+O_WRITE - Open for writing.
+O_WRONLY - Same as O_WRITE.
+O_RDWR - Open for reading and writing.
+O_APPEND - If set, the file offset shall be set to the end of the file prior to each write.
+O_AT_END - Set the initial position at the end of the file.
+O_CREAT - If the file exists, this flag has no effect except as noted under O_EXCL below. Otherwise, the file shall be created
+O_EXCL - If O_CREAT and O_EXCL are set, open() shall fail if the file exists.
+O_SYNC - Call sync() after each write. This flag should not be used with write(uint8_t), write_P(PGM_P), writeln_P(PGM_P), or the Arduino Print class. These functions do character at a time writes so sync() will be called after each byte.
+O_TRUNC - If the file exists and is a regular file, and the file is successfully opened and is not read only, its length shall be truncated to 0.
+WARNING: A given file must not be opened by more than one SdBaseFile object or file corruption may occur.
+
+
|
+ +inherited | +
Open a file in the current working directory.
+[in] | path | A path with a valid 8.3 DOS name for a file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of open flags. see SdBaseFile::open(SdBaseFile*, const char*, uint8_t). |
+
|
+ +inherited | +
Open the next file or subdirectory in a directory.
+[in] | dirFile | An open SdFat instance for the directory containing the file to be opened. |
[in] | oflag | Values for oflag are constructed by a bitwise-inclusive OR of flags O_READ, O_WRITE, O_TRUNC, and O_SYNC. |
See open() by path for definition of flags.
+
|
+ +inherited | +
Open a volume's root directory.
+[in] | vol | The FAT volume containing the root directory to be opened. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Return the next available byte without consuming it.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inherited | +
Print a file's creation date and time
+[in] | pr | Print stream for output. |
+
|
+ +staticinherited | +
Print a directory date field to stdOut.
+Format is yyyy-mm-dd.
+[in] | fatDate | The date field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory date field.
+Format is yyyy-mm-dd.
+[in] | pr | Print stream for output. |
[in] | fatDate | The date field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory time field to stdOut.
+Format is hh:mm:ss.
+[in] | fatTime | The time field from a directory entry. |
+
|
+ +staticinherited | +
Print a directory time field.
+Format is hh:mm:ss.
+[in] | pr | Print stream for output. |
[in] | fatTime | The time field from a directory entry. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
[in] | prec | Number of digits after decimal point. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. Use '\n' for CR LF. |
+
|
+ +inherited | +
Print a file's size.
+[in] | pr | Print stream for output. |
+
|
+ +inherited | +
Print a file's modify date and time
+[in] | pr | Print stream for output. |
+
|
+ +inherited | +
Print a file's name to stdOut
+
+
|
+ +inherited | +
Print a file's name
+[in] | pr | Print stream for output. |
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Read the next byte from a file.
+
+
|
+ +inherited | +
Read data from a file starting at the current position.
+[out] | buf | Pointer to the location that will receive the data. |
[in] | nbyte | Maximum number of bytes to read. |
+
|
+ +inherited | +
Read the next directory entry from a directory file.
+[out] | dir | The dir_t struct that will receive the data. |
+
|
+ +staticinherited | +
Remove a file.
+The directory entry and all data for the file are deleted.
+[in] | dirFile | The directory that contains the file. |
[in] | path | Path for the file to be removed. |
+
|
+ +inherited | +
Remove a file.
+The directory entry and all data for the file are deleted.
+
+
|
+ +inherited | +
Rename a file or subdirectory.
+[in] | dirFile | Directory for the new path. |
[in] | newPath | New path name for the file/directory. |
+
|
+ +inlineinherited | +
Set the file's current position to zero.
+ +
+
|
+ +inherited | +
Remove a directory file.
+The directory file will be removed only if it is empty and is not the root directory. rmdir() follows DOS and Windows and ignores the read-only attribute for the directory.
+
+
|
+ +inherited | +
Recursively delete a directory and all contained files.
+This is like the Unix/Linux 'rm -rf *' if called with the root directory hence the name.
+Warning - This will remove all contents of the directory including subdirectories. The directory will then be removed if it is not root. The read-only attribute for files will be ignored.
+
+
|
+ +inlineinherited | +
Set the files position to current position + pos. See seekSet().
[in] | offset | The new position in bytes from the current position. |
+
|
+ +inlineinherited | +
Set the files position to end-of-file + offset. See seekSet().
[in] | offset | The new position in bytes from end-of-file. |
+
|
+ +inherited | +
Sets a file's position.
+[in] | pos | The new position in bytes from the beginning of the file. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inherited | +
set position for streams
[out] | pos | struct with value for new position |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inherited | +
The sync() call causes all modified data and directory fields to be written to the storage device.
+
+
|
+ +inherited | +
Copy a file's timestamps
+[in] | file | File to copy timestamps from. |
+
|
+ +inherited | +
Set a file's timestamps in its directory entry.
+[in] | flags | Values for flags are constructed by a bitwise-inclusive OR of flags from the following list |
T_ACCESS - Set the file's last access date.
+T_CREATE - Set the file's creation date and time.
+T_WRITE - Set the file's last write/modification date and time.
+[in] | year | Valid range 1980 - 2107 inclusive. |
[in] | month | Valid range 1 - 12 inclusive. |
[in] | day | Valid range 1 - 31 inclusive. |
[in] | hour | Valid range 0 - 23 inclusive. |
[in] | minute | Valid range 0 - 59 inclusive. |
[in] | second | Valid range 0 - 59 inclusive |
+
|
+ +inherited | +
Truncate a file to a specified length. The current file position will be maintained if it is less than or equal to length otherwise it will be set to end of file.
+[in] | length | The desired length for the file. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +inherited | +
Write data to an open file.
+[in] | buf | Pointer to the location of the data to be written. |
[in] | nbyte | Number of bytes to write. |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+
|
+ +inherited | +
+ SdFat
+
+ |
+
This is the complete list of members for SdVolume, including all inherited members.
+blocksPerCluster() const | SdVolume | inline |
blocksPerFat() const | SdVolume | inline |
cacheClear() | SdVolume | inline |
clusterCount() const | SdVolume | inline |
clusterSizeShift() const | SdVolume | inline |
dataStartBlock() const | SdVolume | inline |
dbgFat(uint32_t n, uint32_t *v) | SdVolume | inline |
fatCount() const | SdVolume | inline |
fatStartBlock() const | SdVolume | inline |
fatType() const | SdVolume | inline |
freeClusterCount() | SdVolume | |
init(Sd2Card *dev) | SdVolume | inline |
init(Sd2Card *dev, uint8_t part) | SdVolume | |
rootDirEntryCount() const | SdVolume | inline |
rootDirStart() const | SdVolume | inline |
SdBaseFile (defined in SdVolume) | SdVolume | friend |
sdCard() | SdVolume | inline |
SdVolume() | SdVolume | inline |
+ SdFat
+
+ |
+
Access FAT16 and FAT32 volumes on SD and SDHC cards. + More...
+ +#include <SdVolume.h>
+Public Member Functions | |
uint8_t | blocksPerCluster () const |
uint32_t | blocksPerFat () const |
cache_t * | cacheClear () |
uint32_t | clusterCount () const |
uint8_t | clusterSizeShift () const |
uint32_t | dataStartBlock () const |
bool | dbgFat (uint32_t n, uint32_t *v) |
uint8_t | fatCount () const |
uint32_t | fatStartBlock () const |
uint8_t | fatType () const |
int32_t | freeClusterCount () |
bool | init (Sd2Card *dev) |
bool | init (Sd2Card *dev, uint8_t part) |
uint32_t | rootDirEntryCount () const |
uint32_t | rootDirStart () const |
Sd2Card * | sdCard () |
SdVolume () | |
+Friends | |
+class | SdBaseFile |
Access FAT16 and FAT32 volumes on SD and SDHC cards.
+
+
|
+ +inline | +
Create an instance of SdVolume
+ +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
Clear the cache and returns a pointer to the cache. Used by the WaveRP recorder to do raw write to the SD card. Not for normal apps.
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
Debug access to FAT table
+[in] | n | cluster number. |
[out] | v | value of entry |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
int32_t SdVolume::freeClusterCount | +( | +) | ++ |
Volume free space in clusters.
+
+
|
+ +inline | +
Initialize a FAT volume. Try partition one first then try super floppy format.
+[in] | dev | The Sd2Card where the volume is located. |
bool SdVolume::init | +( | +Sd2Card * | +dev, | +
+ | + | uint8_t | +part | +
+ | ) | ++ |
Initialize a FAT volume.
+[in] | dev | The SD card where the volume is located. |
[in] | part | The partition to be used. Legal values for part are 1-4 to use the corresponding partition on a device formatted with a MBR, Master Boot Record, or zero if the device is formatted as a super floppy with the FAT boot sector in block zero. |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+ SdFat
+
+ |
+
This is the complete list of members for StdioStream, including all inherited members.
+available() | SdBaseFile | inlineprivate |
clearerr() | StdioStream | inline |
clearWriteError() | SdBaseFile | inlineprivate |
close() | SdBaseFile | private |
contiguousRange(uint32_t *bgnBlock, uint32_t *endBlock) | SdBaseFile | private |
createContiguous(SdBaseFile *dirFile, const char *path, uint32_t size) | SdBaseFile | private |
curCluster() const | SdBaseFile | inlineprivate |
curPosition() const | SdBaseFile | inlineprivate |
cwd() | SdBaseFile | inlineprivatestatic |
dateTimeCallback(void(*dateTime)(uint16_t *date, uint16_t *time)) | SdBaseFile | inlineprivatestatic |
dateTimeCallbackCancel() | SdBaseFile | inlineprivatestatic |
dirEntry(dir_t *dir) | SdBaseFile | private |
dirName(const dir_t &dir, char *name) | SdBaseFile | privatestatic |
exists(const char *name) | SdBaseFile | private |
fclose() | StdioStream | |
feof() | StdioStream | inline |
ferror() | StdioStream | inline |
fflush() | StdioStream | |
fgetc() | StdioStream | inline |
fgets(char *str, int num, size_t *len=0) | StdioStream | |
SdBaseFile::fgets(char *str, int16_t num, char *delim=0) | SdBaseFile | private |
fileSize() const | SdBaseFile | inlineprivate |
firstCluster() const | SdBaseFile | inlineprivate |
fopen(const char *filename, const char *mode) | StdioStream | |
fputc(int c) | StdioStream | inline |
fputs(const char *str) | StdioStream | |
fputs_P(PGM_P str) | StdioStream | |
fread(void *ptr, size_t size, size_t count) | StdioStream | |
fseek(int32_t offset, int origin) | StdioStream | |
ftell() | StdioStream | |
fwrite(const void *ptr, size_t size, size_t count) | StdioStream | |
getc() | StdioStream | inline |
getFilename(char *name) | SdBaseFile | private |
getpos(FatPos_t *pos) | SdBaseFile | private |
getWriteError() | SdBaseFile | inlineprivate |
isDir() const | SdBaseFile | inlineprivate |
isFile() const | SdBaseFile | inlineprivate |
isOpen() const | SdBaseFile | inlineprivate |
isRoot() const | SdBaseFile | inlineprivate |
isSubDir() const | SdBaseFile | inlineprivate |
ls(Print *pr, uint8_t flags=0, uint8_t indent=0) | SdBaseFile | private |
ls(uint8_t flags=0) | SdBaseFile | private |
mkdir(SdBaseFile *dir, const char *path, bool pFlag=true) | SdBaseFile | private |
open(SdBaseFile *dirFile, uint16_t index, uint8_t oflag) | SdBaseFile | private |
open(SdBaseFile *dirFile, const char *path, uint8_t oflag) | SdBaseFile | private |
open(const char *path, uint8_t oflag=O_READ) | SdBaseFile | private |
openNext(SdBaseFile *dirFile, uint8_t oflag) | SdBaseFile | private |
openRoot(SdVolume *vol) | SdBaseFile | private |
peek() | SdBaseFile | private |
print(char c) | StdioStream | inline |
print(const char *str) | StdioStream | inline |
print(const __FlashStringHelper *str) | StdioStream | |
print(double val, uint8_t prec=2) | StdioStream | inline |
print(float val, uint8_t prec=2) | StdioStream | inline |
print(T val) | StdioStream | inline |
printCreateDateTime(Print *pr) | SdBaseFile | private |
printDec(char n) | StdioStream | inline |
printDec(signed char n) | StdioStream | |
printDec(unsigned char n) | StdioStream | inline |
printDec(int16_t n) | StdioStream | |
printDec(uint16_t n) | StdioStream | |
printDec(int32_t n) | StdioStream | |
printDec(uint32_t n) | StdioStream | |
printDec(double value, uint8_t prec) | StdioStream | inline |
printDec(float value, uint8_t prec) | StdioStream | |
printFatDate(uint16_t fatDate) | SdBaseFile | privatestatic |
printFatDate(Print *pr, uint16_t fatDate) | SdBaseFile | privatestatic |
printFatTime(uint16_t fatTime) | SdBaseFile | privatestatic |
printFatTime(Print *pr, uint16_t fatTime) | SdBaseFile | privatestatic |
printField(double value, char term, uint8_t prec=2) | StdioStream | inline |
printField(float value, char term, uint8_t prec=2) | StdioStream | inline |
printField(T value, char term) | StdioStream | inline |
SdBaseFile::printField(int16_t value, char term) | SdBaseFile | private |
SdBaseFile::printField(uint16_t value, char term) | SdBaseFile | private |
SdBaseFile::printField(int32_t value, char term) | SdBaseFile | private |
SdBaseFile::printField(uint32_t value, char term) | SdBaseFile | private |
printFileSize(Print *pr) | SdBaseFile | private |
printHex(uint32_t n) | StdioStream | |
printHexln(uint32_t n) | StdioStream | inline |
println() | StdioStream | inline |
println(double val, uint8_t prec=2) | StdioStream | inline |
println(float val, uint8_t prec=2) | StdioStream | inline |
println(T val) | StdioStream | inline |
printModifyDateTime(Print *pr) | SdBaseFile | private |
printName() | SdBaseFile | private |
printName(Print *pr) | SdBaseFile | private |
putc(int c) | StdioStream | inline |
putCRLF() | StdioStream | inline |
read() | SdBaseFile | private |
read(void *buf, size_t nbyte) | SdBaseFile | private |
readDir(dir_t *dir) | SdBaseFile | private |
remove(SdBaseFile *dirFile, const char *path) | SdBaseFile | privatestatic |
remove() | SdBaseFile | private |
rename(SdBaseFile *dirFile, const char *newPath) | SdBaseFile | private |
rewind() | StdioStream | |
rmdir() | SdBaseFile | private |
rmRfStar() | SdBaseFile | private |
SdBaseFile() | SdBaseFile | inlineprivate |
SdBaseFile(const char *path, uint8_t oflag) | SdBaseFile | private |
seekCur(int32_t offset) | SdBaseFile | inlineprivate |
seekEnd(int32_t offset=0) | SdBaseFile | inlineprivate |
seekSet(uint32_t pos) | SdBaseFile | private |
setpos(FatPos_t *pos) | SdBaseFile | private |
StdioStream() | StdioStream | inline |
sync() | SdBaseFile | private |
timestamp(SdBaseFile *file) | SdBaseFile | private |
timestamp(uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) | SdBaseFile | private |
truncate(uint32_t size) | SdBaseFile | private |
type() const | SdBaseFile | inlineprivate |
ungetc(int c) | StdioStream | |
volume() const | SdBaseFile | inlineprivate |
writeError | SdBaseFile | private |
+ SdFat
+
+ |
+
StdioStream implements a minimal stdio stream. + More...
+ +#include <StdioStream.h>
+Public Member Functions | |
void | clearerr () |
int | fclose () |
int | feof () |
int | ferror () |
int | fflush () |
int | fgetc () |
char * | fgets (char *str, int num, size_t *len=0) |
bool | fopen (const char *filename, const char *mode) |
int | fputc (int c) |
int | fputs (const char *str) |
int | fputs_P (PGM_P str) |
size_t | fread (void *ptr, size_t size, size_t count) |
int | fseek (int32_t offset, int origin) |
int32_t | ftell () |
size_t | fwrite (const void *ptr, size_t size, size_t count) |
int | getc () |
size_t | print (char c) |
size_t | print (const char *str) |
size_t | print (const __FlashStringHelper *str) |
size_t | print (double val, uint8_t prec=2) |
size_t | print (float val, uint8_t prec=2) |
template<typename T > | |
size_t | print (T val) |
int | printDec (char n) |
int | printDec (signed char n) |
int | printDec (unsigned char n) |
int | printDec (int16_t n) |
int | printDec (uint16_t n) |
int | printDec (int32_t n) |
int | printDec (uint32_t n) |
int | printDec (double value, uint8_t prec) |
int | printDec (float value, uint8_t prec) |
int | printField (double value, char term, uint8_t prec=2) |
int | printField (float value, char term, uint8_t prec=2) |
template<typename T > | |
int | printField (T value, char term) |
int | printHex (uint32_t n) |
int | printHexln (uint32_t n) |
size_t | println () |
size_t | println (double val, uint8_t prec=2) |
size_t | println (float val, uint8_t prec=2) |
template<typename T > | |
size_t | println (T val) |
int | putc (int c) |
int | putCRLF () |
bool | rewind () |
StdioStream () | |
int | ungetc (int c) |
+Private Member Functions | |
uint32_t | available () |
void | clearWriteError () |
bool | close () |
bool | contiguousRange (uint32_t *bgnBlock, uint32_t *endBlock) |
bool | createContiguous (SdBaseFile *dirFile, const char *path, uint32_t size) |
uint32_t | curCluster () const |
uint32_t | curPosition () const |
bool | dirEntry (dir_t *dir) |
bool | exists (const char *name) |
int16_t | fgets (char *str, int16_t num, char *delim=0) |
uint32_t | fileSize () const |
uint32_t | firstCluster () const |
bool | getFilename (char *name) |
void | getpos (FatPos_t *pos) |
bool | getWriteError () |
bool | isDir () const |
bool | isFile () const |
bool | isOpen () const |
bool | isRoot () const |
bool | isSubDir () const |
void | ls (Print *pr, uint8_t flags=0, uint8_t indent=0) |
void | ls (uint8_t flags=0) |
bool | mkdir (SdBaseFile *dir, const char *path, bool pFlag=true) |
bool | open (SdBaseFile *dirFile, uint16_t index, uint8_t oflag) |
bool | open (SdBaseFile *dirFile, const char *path, uint8_t oflag) |
bool | open (const char *path, uint8_t oflag=O_READ) |
bool | openNext (SdBaseFile *dirFile, uint8_t oflag) |
bool | openRoot (SdVolume *vol) |
int | peek () |
bool | printCreateDateTime (Print *pr) |
int | printField (int16_t value, char term) |
int | printField (uint16_t value, char term) |
int | printField (int32_t value, char term) |
int | printField (uint32_t value, char term) |
size_t | printFileSize (Print *pr) |
bool | printModifyDateTime (Print *pr) |
size_t | printName () |
size_t | printName (Print *pr) |
int16_t | read () |
int | read (void *buf, size_t nbyte) |
int8_t | readDir (dir_t *dir) |
bool | remove () |
bool | rename (SdBaseFile *dirFile, const char *newPath) |
bool | rmdir () |
bool | rmRfStar () |
bool | seekCur (int32_t offset) |
bool | seekEnd (int32_t offset=0) |
bool | seekSet (uint32_t pos) |
void | setpos (FatPos_t *pos) |
bool | sync () |
bool | timestamp (SdBaseFile *file) |
bool | timestamp (uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) |
bool | truncate (uint32_t size) |
uint8_t | type () const |
SdVolume * | volume () const |
+Static Private Member Functions | |
static SdBaseFile * | cwd () |
static void | dateTimeCallback (void(*dateTime)(uint16_t *date, uint16_t *time)) |
static void | dateTimeCallbackCancel () |
static void | dirName (const dir_t &dir, char *name) |
static void | printFatDate (uint16_t fatDate) |
static void | printFatDate (Print *pr, uint16_t fatDate) |
static void | printFatTime (uint16_t fatTime) |
static void | printFatTime (Print *pr, uint16_t fatTime) |
static bool | remove (SdBaseFile *dirFile, const char *path) |
+Private Attributes | |
bool | writeError |
StdioStream implements a minimal stdio stream.
+StdioStream does not support subdirectories or long file names.
+
+
|
+ +inline | +
Constructor
+ +
+
|
+ +inline | +
Clear the stream's end-of-file and error indicators.
+ +int StdioStream::fclose | +( | +) | ++ |
Close a stream.
+A successful call to the fclose function causes the stream to be flushed and the associated file to be closed. Any unwritten buffered data is written to the file; any unread buffered data is discarded. Whether or not the call succeeds, the stream is disassociated from the file.
+
+
|
+ +inline | +
Test the stream's end-of-file indicator.
+
|
+ +inline | +
Test the stream's error indicator.
int StdioStream::fflush | +( | +) | ++ |
Flush the stream.
+If stream is an output stream or an update stream in which the most recent operation was not input, any unwritten data is written to the file; otherwise the call is an error since any buffered input data would be lost.
+
+
|
+ +inline | +
Get a byte from the stream.
+char * StdioStream::fgets | +( | +char * | +str, | +
+ | + | int | +num, | +
+ | + | size_t * | +len = 0 |
+
+ | ) | ++ |
Get a string from a stream.
+The fgets function reads at most one less than the number of characters specified by num from the stream into the array pointed to by str. No additional characters are read after a new-line character (which is retained) or after end-of-file. A null character is written immediately after the last character read into the array.
+[out] | str | Pointer to an array of where the string is copied. |
[in] | num | Maximum number of characters including the null character. |
[out] | len | If len is not null and fgets is successful, the length of the string is returned. |
bool StdioStream::fopen | +( | +const char * | +filename, | +
+ | + | const char * | +mode | +
+ | ) | ++ |
Open a stream.
+Open a file and associates the stream with it.
+[in] | filename | name of the file to be opened. |
[in] | mode | a string that indicates the open mode. |
"r" or "rb" | Open a file for reading. The file must exist. |
"w" or "wb" | Truncate an existing to zero length or create an empty file for writing. |
"wx" or "wbx" | Create a file for writing. Fails if the file already exists. |
"a" or "ab" | Append; open or create file for writing at end-of-file. |
"r+" or "rb+" or "r+b" | Open a file for update (reading and writing). |
"w+" or "w+b" or "wb+" | Truncate an existing to zero length or create a file for update. |
"w+x" or "w+bx" or "wb+x" | Create a file for update. Fails if the file already exists. |
"a+" or "a+b" or "ab+" | Append; open or create a file for update, writing at end-of-file. |
The character 'b' shall have no effect, but is allowed for ISO C standard conformance.
+Opening a file with append mode causes all subsequent writes to the file to be forced to the then current end-of-file, regardless of intervening calls to the fseek function.
+When a file is opened with update mode, both input and output may be performed on the associated stream. However, output shall not be directly followed by input without an intervening call to the fflush function or to a file positioning function (fseek, or rewind), and input shall not be directly followed by output without an intervening call to a file positioning function, unless the input operation encounters endof-file.
+
+
|
+ +inline | +
Write a byte to a stream.
+[in] | c | the byte to be written (converted to an unsigned char). |
int StdioStream::fputs | +( | +const char * | +str | ) | ++ |
Write a string to a stream.
+[in] | str | a pointer to the string to be written. |
int StdioStream::fputs_P | +( | +PGM_P | +str | ) | ++ |
Write a string stored in flash.
+[in] | str | string to be written. |
size_t StdioStream::fread | +( | +void * | +ptr, | +
+ | + | size_t | +size, | +
+ | + | size_t | +count | +
+ | ) | ++ |
Binary input.
+Reads an array of up to count elements, each one with a size of size bytes.
[out] | ptr | pointer to area of at least (size*count) bytes where the data will be stored. |
[in] | size | the size, in bytes, of each element to be read. |
[in] | count | the number of elements to be read. |
int StdioStream::fseek | +( | +int32_t | +offset, | +
+ | + | int | +origin | +
+ | ) | ++ |
Set the file position for the stream.
+[in] | offset | number of offset from the origin. |
[in] | origin | position used as reference for the offset. It is specified by one of the following constants. |
SEEK_SET - Beginning of file.
+SEEK_CUR - Current position of the file pointer.
+SEEK_END - End of file.
+int32_t StdioStream::ftell | +( | +) | ++ |
Get the current position in a stream.
+size_t StdioStream::fwrite | +( | +const void * | +ptr, | +
+ | + | size_t | +size, | +
+ | + | size_t | +count | +
+ | ) | ++ |
Binary output.
+Writes an array of up to count elements, each one with a size of size bytes.
[in] | ptr | pointer to (size*count) bytes of data to be written. |
[in] | size | the size, in bytes, of each element to be written. |
[in] | count | the number of elements to be written. |
+
|
+ +inline | +
Get a byte from the stream.
+getc and fgetc are equivalent but getc is inline so it is faster but require more flash memory.
+
+
|
+ +inline | +
Write a character.
[in] | c | the character to write. |
+
|
+ +inline | +
Write a string.
+[in] | str | the string to be written. |
size_t StdioStream::print | +( | +const __FlashStringHelper * | +str | ) | ++ |
Print a string stored in flash memory.
+[in] | str | the string to print. |
+
|
+ +inline | +
Print a floating point number.
+[in] | prec | Number of digits after decimal point. |
[in] | val | the number to be printed. |
+
|
+ +inline | +
Print a floating point number.
+[in] | prec | Number of digits after decimal point. |
[in] | val | the number to be printed. |
+
|
+ +inline | +
Print a number.
+[in] | val | the number to be printed. |
+
|
+ +inline | +
Print a char as a number.
[in] | n | number to be printed. |
int StdioStream::printDec | +( | +signed char | +n | ) | ++ |
print a signed 8-bit integer
[in] | n | number to be printed. |
+
|
+ +inline | +
Print an unsigned 8-bit number.
[in] | n | number to be print. |
int StdioStream::printDec | +( | +int16_t | +n | ) | ++ |
Print a int16_t
[in] | n | number to be printed. |
int StdioStream::printDec | +( | +uint16_t | +n | ) | ++ |
print a uint16_t.
[in] | n | number to be printed. |
int StdioStream::printDec | +( | +int32_t | +n | ) | ++ |
Print a signed 32-bit integer.
[in] | n | number to be printed. |
int StdioStream::printDec | +( | +uint32_t | +n | ) | ++ |
Write an unsigned 32-bit number.
[in] | n | number to be printed. |
+
|
+ +inline | +
Print a double.
[in] | value | The number to be printed. |
[in] | prec | Number of digits after decimal point. |
int StdioStream::printDec | +( | +float | +value, | +
+ | + | uint8_t | +prec | +
+ | ) | ++ |
Print a float.
[in] | value | The number to be printed. |
[in] | prec | Number of digits after decimal point. |
+
|
+ +inline | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. |
[in] | prec | Number of digits after decimal point. |
+
|
+ +inline | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. |
[in] | prec | Number of digits after decimal point. |
+
|
+ +inline | +
Print a number followed by a field terminator.
[in] | value | The number to be printed. |
[in] | term | The field terminator. |
int StdioStream::printHex | +( | +uint32_t | +n | ) | ++ |
Print HEX
[in] | n | number to be printed as HEX. |
+
|
+ +inline | +
Print HEX with CRLF
[in] | n | number to be printed as HEX. |
+
|
+ +inline | +
Write a CR/LF.
+
+
|
+ +inline | +
Print a floating point number followed by CR/LF.
+[in] | val | the number to be printed. |
[in] | prec | Number of digits after decimal point. |
+
|
+ +inline | +
Print a floating point number followed by CR/LF.
+[in] | val | the number to be printed. |
[in] | prec | Number of digits after decimal point. |
+
|
+ +inline | +
Print an item followed by CR/LF
+[in] | val | the item to be printed. |
+
|
+ +inline | +
Write a byte to a stream.
+putc and fputc are equivalent but putc is inline so it is faster but require more flash memory.
+[in] | c | the byte to be written (converted to an unsigned char). |
+
|
+ +inline | +
Write a CR/LF.
+bool StdioStream::rewind | +( | +) | ++ |
Set position of a stream to the beginning.
+The rewind function sets the file position to the beginning of the file. It is equivalent to fseek(0L, SEEK_SET) except that the error indicator for the stream is also cleared.
+int StdioStream::ungetc | +( | +int | +c | ) | ++ |
Push a byte back into an input stream.
+[in] | c | the byte (converted to an unsigned char) to be pushed back. |
One character of pushback is guaranteed. If the ungetc function is called too many times without an intervening read or file positioning operation on that stream, the operation may fail.
+A successful intervening call to a file positioning function (fseek, fsetpos, or rewind) discards any pushed-back characters for the stream.
+
+ SdFat
+
+ |
+
|
| StdioStream | ifstream | ostream | |||
| ios |
| |||||
ArduinoInStream | Sd2Card | ios_base | |||||
ArduinoOutStream | SdBaseFile | cache_t | iostream | pgm | |||
| SdFat |
| istream |
| |||
SdFile |
| ||||||
FatPos_t | SdSpi | fstream | setfill | ||||
File | SdStreamBase |
| obufstream | setprecision | |||
| SdVolume | ofstream | setw | ||||
ibufstream | |||||||
MinimumSerial | |||||||
+ SdFat
+
+ |
+
This is the complete list of members for fstream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
available() | SdBaseFile | inlineprivate |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | fstream | inline |
clearWriteError() | SdBaseFile | inlineprivate |
close() | fstream | inline |
contiguousRange(uint32_t *bgnBlock, uint32_t *endBlock) | SdBaseFile | private |
createContiguous(SdBaseFile *dirFile, const char *path, uint32_t size) | SdBaseFile | private |
cur enum value | ios_base | |
curCluster() const | SdBaseFile | inlineprivate |
curPosition() const | SdBaseFile | inlineprivate |
cwd() | SdBaseFile | inlineprivatestatic |
dateTimeCallback(void(*dateTime)(uint16_t *date, uint16_t *time)) | SdBaseFile | inlineprivatestatic |
dateTimeCallbackCancel() | SdBaseFile | inlineprivatestatic |
dec | ios_base | static |
dirEntry(dir_t *dir) | SdBaseFile | private |
dirName(const dir_t &dir, char *name) | SdBaseFile | privatestatic |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
exists(const char *name) | SdBaseFile | private |
fail() const | ios | inline |
failbit | ios_base | static |
fgets(char *str, int16_t num, char *delim=0) | SdBaseFile | private |
fileSize() const | SdBaseFile | inlineprivate |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
firstCluster() const | SdBaseFile | inlineprivate |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
flush() | ostream | inline |
fmtflags typedef | ios_base | |
fstream() (defined in fstream) | fstream | inline |
fstream(const char *path, openmode mode=in|out) | fstream | inlineexplicit |
gcount() const | istream | inline |
get() | istream | |
get(char &ch) | istream | |
get(char *str, streamsize n, char delim= '\n') | istream | |
getFilename(char *name) | SdBaseFile | private |
getline(char *str, streamsize count, char delim= '\n') | istream | |
getpos(FatPos_t *pos) | SdBaseFile | private |
getWriteError() | SdBaseFile | inlineprivate |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
ignore(streamsize n=1, int delim=-1) | istream | |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
is_open() | fstream | inline |
isDir() const | SdBaseFile | inlineprivate |
isFile() const | SdBaseFile | inlineprivate |
isOpen() const | SdBaseFile | inlineprivate |
isRoot() const | SdBaseFile | inlineprivate |
isSubDir() const | SdBaseFile | inlineprivate |
istream() (defined in istream) | istream | inline |
left | ios_base | static |
ls(Print *pr, uint8_t flags=0, uint8_t indent=0) | SdBaseFile | private |
ls(uint8_t flags=0) | SdBaseFile | private |
mkdir(SdBaseFile *dir, const char *path, bool pFlag=true) | SdBaseFile | private |
oct | ios_base | static |
off_type typedef | ios_base | |
open(const char *path, openmode mode=in|out) | fstream | inline |
SdStreamBase::open(SdBaseFile *dirFile, uint16_t index, uint8_t oflag) | SdBaseFile | private |
SdStreamBase::open(SdBaseFile *dirFile, const char *path, uint8_t oflag) | SdBaseFile | private |
openmode typedef | ios_base | |
openNext(SdBaseFile *dirFile, uint8_t oflag) | SdBaseFile | private |
openRoot(SdVolume *vol) | SdBaseFile | private |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator<<(ostream &(*pf)(ostream &str)) | ostream | inline |
operator<<(ios_base &(*pf)(ios_base &str)) | ostream | inline |
operator<<(bool arg) | ostream | inline |
operator<<(const char *arg) | ostream | inline |
operator<<(const signed char *arg) | ostream | inline |
operator<<(const unsigned char *arg) | ostream | inline |
operator<<(char arg) | ostream | inline |
operator<<(signed char arg) | ostream | inline |
operator<<(unsigned char arg) | ostream | inline |
operator<<(double arg) | ostream | inline |
operator<<(float arg) | ostream | inline |
operator<<(short arg) | ostream | inline |
operator<<(unsigned short arg) | ostream | inline |
operator<<(int arg) | ostream | inline |
operator<<(unsigned int arg) | ostream | inline |
operator<<(long arg) | ostream | inline |
operator<<(unsigned long arg) | ostream | inline |
operator<<(const void *arg) | ostream | inline |
operator<<(pgm arg) | ostream | inline |
operator<<(const __FlashStringHelper *arg) | ostream | inline |
operator>>(istream &(*pf)(istream &str)) | istream | inline |
operator>>(ios_base &(*pf)(ios_base &str)) | istream | inline |
operator>>(ios &(*pf)(ios &str)) | istream | inline |
operator>>(char *str) | istream | inline |
operator>>(char &ch) | istream | inline |
operator>>(signed char *str) | istream | inline |
operator>>(signed char &ch) | istream | inline |
operator>>(unsigned char *str) | istream | inline |
operator>>(unsigned char &ch) | istream | inline |
operator>>(bool &arg) | istream | inline |
operator>>(short &arg) | istream | inline |
operator>>(unsigned short &arg) | istream | inline |
operator>>(int &arg) | istream | inline |
operator>>(unsigned int &arg) | istream | inline |
operator>>(long &arg) | istream | inline |
operator>>(unsigned long &arg) | istream | inline |
operator>>(double &arg) | istream | inline |
operator>>(float &arg) | istream | inline |
operator>>(void *&arg) | istream | inline |
ostream() (defined in ostream) | ostream | inline |
out | ios_base | static |
iostream::peek() | istream | |
SdStreamBase::peek() | SdBaseFile | private |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
printCreateDateTime(Print *pr) | SdBaseFile | private |
printFatDate(uint16_t fatDate) | SdBaseFile | privatestatic |
printFatDate(Print *pr, uint16_t fatDate) | SdBaseFile | privatestatic |
printFatTime(uint16_t fatTime) | SdBaseFile | privatestatic |
printFatTime(Print *pr, uint16_t fatTime) | SdBaseFile | privatestatic |
printField(float value, char term, uint8_t prec=2) | SdBaseFile | private |
printField(int16_t value, char term) | SdBaseFile | private |
printField(uint16_t value, char term) | SdBaseFile | private |
printField(int32_t value, char term) | SdBaseFile | private |
printField(uint32_t value, char term) | SdBaseFile | private |
printFileSize(Print *pr) | SdBaseFile | private |
printModifyDateTime(Print *pr) | SdBaseFile | private |
printName() | SdBaseFile | private |
printName(Print *pr) | SdBaseFile | private |
put(char ch) | ostream | inline |
rdstate() const | ios | inline |
read() | SdBaseFile | private |
read(void *buf, size_t nbyte) | SdBaseFile | private |
readDir(dir_t *dir) | SdBaseFile | private |
remove(SdBaseFile *dirFile, const char *path) | SdBaseFile | privatestatic |
remove() | SdBaseFile | private |
rename(SdBaseFile *dirFile, const char *newPath) | SdBaseFile | private |
rewind() | SdBaseFile | inlineprivate |
right | ios_base | static |
rmdir() | SdBaseFile | private |
rmRfStar() | SdBaseFile | private |
SdBaseFile() | SdBaseFile | inlineprivate |
SdBaseFile(const char *path, uint8_t oflag) | SdBaseFile | private |
seekCur(int32_t offset) | SdBaseFile | inlineprivate |
seekdir enum name | ios_base | |
seekEnd(int32_t offset=0) | SdBaseFile | inlineprivate |
seekg(pos_type pos) | istream | inline |
seekg(off_type off, seekdir way) | istream | inline |
seekp(pos_type pos) | ostream | inline |
seekp(off_type off, seekdir way) | ostream | inline |
seekSet(uint32_t pos) | SdBaseFile | private |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setpos(FatPos_t *pos) | SdBaseFile | private |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipWhite() | istream | |
skipws | ios_base | static |
streamsize typedef | ios_base | |
sync() | SdBaseFile | private |
tellg() | istream | inline |
tellp() | ostream | inline |
timestamp(SdBaseFile *file) | SdBaseFile | private |
timestamp(uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) | SdBaseFile | private |
trunc | ios_base | static |
truncate(uint32_t size) | SdBaseFile | private |
type() const | SdBaseFile | inlineprivate |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
volume() const | SdBaseFile | inlineprivate |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
write(const void *buf, size_t nbyte) | SdBaseFile | private |
writeError | SdBaseFile | private |
+ SdFat
+
+ |
+
SD file input/output stream. + More...
+ +#include <SdStream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
void | close () |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
ostream & | flush () |
fstream (const char *path, openmode mode=in|out) | |
streamsize | gcount () const |
int | get () |
istream & | get (char &ch) |
istream & | get (char *str, streamsize n, char delim= '\n') |
istream & | getline (char *str, streamsize count, char delim= '\n') |
bool | good () const |
istream & | ignore (streamsize n=1, int delim=-1) |
bool | is_open () |
void | open (const char *path, openmode mode=in|out) |
operator const void * () const | |
bool | operator! () const |
ostream & | operator<< (ostream &(*pf)(ostream &str)) |
ostream & | operator<< (ios_base &(*pf)(ios_base &str)) |
ostream & | operator<< (bool arg) |
ostream & | operator<< (const char *arg) |
ostream & | operator<< (const signed char *arg) |
ostream & | operator<< (const unsigned char *arg) |
ostream & | operator<< (char arg) |
ostream & | operator<< (signed char arg) |
ostream & | operator<< (unsigned char arg) |
ostream & | operator<< (double arg) |
ostream & | operator<< (float arg) |
ostream & | operator<< (short arg) |
ostream & | operator<< (unsigned short arg) |
ostream & | operator<< (int arg) |
ostream & | operator<< (unsigned int arg) |
ostream & | operator<< (long arg) |
ostream & | operator<< (unsigned long arg) |
ostream & | operator<< (const void *arg) |
ostream & | operator<< (pgm arg) |
ostream & | operator<< (const __FlashStringHelper *arg) |
istream & | operator>> (istream &(*pf)(istream &str)) |
istream & | operator>> (ios_base &(*pf)(ios_base &str)) |
istream & | operator>> (ios &(*pf)(ios &str)) |
istream & | operator>> (char *str) |
istream & | operator>> (char &ch) |
istream & | operator>> (signed char *str) |
istream & | operator>> (signed char &ch) |
istream & | operator>> (unsigned char *str) |
istream & | operator>> (unsigned char &ch) |
istream & | operator>> (bool &arg) |
istream & | operator>> (short &arg) |
istream & | operator>> (unsigned short &arg) |
istream & | operator>> (int &arg) |
istream & | operator>> (unsigned int &arg) |
istream & | operator>> (long &arg) |
istream & | operator>> (unsigned long &arg) |
istream & | operator>> (double &arg) |
istream & | operator>> (float &arg) |
istream & | operator>> (void *&arg) |
int | peek () |
int | precision () const |
int | precision (unsigned int n) |
ostream & | put (char ch) |
iostate | rdstate () const |
istream & | seekg (pos_type pos) |
istream & | seekg (off_type off, seekdir way) |
ostream & | seekp (pos_type pos) |
ostream & | seekp (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
void | skipWhite () |
pos_type | tellg () |
pos_type | tellp () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
+Private Member Functions | |
uint32_t | available () |
void | clearWriteError () |
bool | contiguousRange (uint32_t *bgnBlock, uint32_t *endBlock) |
bool | createContiguous (SdBaseFile *dirFile, const char *path, uint32_t size) |
uint32_t | curCluster () const |
uint32_t | curPosition () const |
bool | dirEntry (dir_t *dir) |
bool | exists (const char *name) |
int16_t | fgets (char *str, int16_t num, char *delim=0) |
uint32_t | fileSize () const |
uint32_t | firstCluster () const |
bool | getFilename (char *name) |
void | getpos (FatPos_t *pos) |
bool | getWriteError () |
bool | isDir () const |
bool | isFile () const |
bool | isOpen () const |
bool | isRoot () const |
bool | isSubDir () const |
void | ls (Print *pr, uint8_t flags=0, uint8_t indent=0) |
void | ls (uint8_t flags=0) |
bool | mkdir (SdBaseFile *dir, const char *path, bool pFlag=true) |
bool | open (SdBaseFile *dirFile, uint16_t index, uint8_t oflag) |
bool | open (SdBaseFile *dirFile, const char *path, uint8_t oflag) |
bool | openNext (SdBaseFile *dirFile, uint8_t oflag) |
bool | openRoot (SdVolume *vol) |
int | peek () |
bool | printCreateDateTime (Print *pr) |
int | printField (float value, char term, uint8_t prec=2) |
int | printField (int16_t value, char term) |
int | printField (uint16_t value, char term) |
int | printField (int32_t value, char term) |
int | printField (uint32_t value, char term) |
size_t | printFileSize (Print *pr) |
bool | printModifyDateTime (Print *pr) |
size_t | printName () |
size_t | printName (Print *pr) |
int16_t | read () |
int | read (void *buf, size_t nbyte) |
int8_t | readDir (dir_t *dir) |
bool | remove () |
bool | rename (SdBaseFile *dirFile, const char *newPath) |
void | rewind () |
bool | rmdir () |
bool | rmRfStar () |
bool | seekCur (int32_t offset) |
bool | seekEnd (int32_t offset=0) |
bool | seekSet (uint32_t pos) |
void | setpos (FatPos_t *pos) |
bool | sync () |
bool | timestamp (SdBaseFile *file) |
bool | timestamp (uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) |
bool | truncate (uint32_t size) |
uint8_t | type () const |
SdVolume * | volume () const |
int | write (const void *buf, size_t nbyte) |
+Static Private Member Functions | |
static SdBaseFile * | cwd () |
static void | dateTimeCallback (void(*dateTime)(uint16_t *date, uint16_t *time)) |
static void | dateTimeCallbackCancel () |
static void | dirName (const dir_t &dir, char *name) |
static void | printFatDate (uint16_t fatDate) |
static void | printFatDate (Print *pr, uint16_t fatDate) |
static void | printFatTime (uint16_t fatTime) |
static void | printFatTime (Print *pr, uint16_t fatTime) |
static bool | remove (SdBaseFile *dirFile, const char *path) |
+Private Attributes | |
bool | writeError |
SD file input/output stream.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inlineexplicit | +
Constructor with open
+[in] | path | path to open |
[in] | mode | open mode |
+
|
+ +inlineinherited | +
Clear state and writeError
[in] | state | new state for stream |
+
|
+ +inline | +
Close a file and force cached data and directory information to be written to the storage device.
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inlineinherited | +
Flushes the buffer associated with this stream. The flush function calls the sync function of the associated file.
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract a character if one is available.
+
+
|
+ +inherited | +
Extract a character if one is available.
+[out] | c | location to receive the extracted character. |
+
|
+ +inherited | +
Extract characters.
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, n is less than 1, n-1 characters are extracted, or the next character equals delim (delim is not extracted). If no characters are extracted failbit is set. If end-of-file occurs the eofbit is set.
+
+
|
+ +inherited | +
Extract characters
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, the next character equals delim (delim is extracted), or n-1 characters are extracted.
+The failbit is set if no characters are extracted or n-1 characters are extracted. If end-of-file occurs the eofbit is set.
+
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract characters and discard them.
+[in] | n | maximum number of characters to ignore. |
[in] | delim | Delimiter. |
Characters are extracted until extraction fails, n characters are extracted, or the next input character equals delim (the delimiter is extracted). If end-of-file occurs the eofbit is set.
+Failures are indicated by the state of the stream.
+
+
|
+ +inline | +
+
|
+ +inline | +
Open a fstream
[in] | path | file to open |
[in] | mode | open mode |
Valid open modes are (at end, ios::ate, and/or ios::binary may be added):
+ios::in - Open file for reading.
+ios::out or ios::out | ios::trunc - Truncate to 0 length, if existent, or create a file for writing only.
+ios::app or ios::out | ios::app - Append; open or create file for writing at end-of-file.
+ios::in | ios::out - Open file for update (reading and writing).
+ios::in | ios::out | ios::trunc - Truncate to zero length, if existent, or create file for update.
+ios::in | ios::app or ios::in | ios::out | ios::app - Append; open or create text file for update, writing at end of file.
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Output bool
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output double
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output float
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output pointer
[in] | arg | value to output |
Output a string from flash using the pstr() macro
[in] | arg | pgm struct pointing to string |
+
|
+ +inlineinherited | +
Output a string from flash using the Arduino F() macro.
[in] | arg | pointing to flash string |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a value of type bool.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type double.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type float.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type void*.
[out] | arg | location to store the value. |
+
|
+ +inherited | +
Return the next available character without consuming it.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
Puts a character in a stream.
+The unformatted output function inserts the element ch. It returns *this.
+[in] | ch | The character |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the read pointer. |
Set the stream position
[in] | pos | The absolute position in which to move the write pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inherited | +
used to implement ws()
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for ibufstream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
cur enum value | ios_base | |
dec | ios_base | static |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
fail() const | ios | inline |
failbit | ios_base | static |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
fmtflags typedef | ios_base | |
gcount() const | istream | inline |
get() | istream | |
get(char &ch) | istream | |
get(char *str, streamsize n, char delim= '\n') | istream | |
getline(char *str, streamsize count, char delim= '\n') | istream | |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
ibufstream() | ibufstream | inline |
ibufstream(const char *str) | ibufstream | inlineexplicit |
ignore(streamsize n=1, int delim=-1) | istream | |
in | ios_base | static |
init(const char *str) | ibufstream | inline |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
istream() (defined in istream) | istream | inline |
left | ios_base | static |
oct | ios_base | static |
off_type typedef | ios_base | |
openmode typedef | ios_base | |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator>>(istream &(*pf)(istream &str)) | istream | inline |
operator>>(ios_base &(*pf)(ios_base &str)) | istream | inline |
operator>>(ios &(*pf)(ios &str)) | istream | inline |
operator>>(char *str) | istream | inline |
operator>>(char &ch) | istream | inline |
operator>>(signed char *str) | istream | inline |
operator>>(signed char &ch) | istream | inline |
operator>>(unsigned char *str) | istream | inline |
operator>>(unsigned char &ch) | istream | inline |
operator>>(bool &arg) | istream | inline |
operator>>(short &arg) | istream | inline |
operator>>(unsigned short &arg) | istream | inline |
operator>>(int &arg) | istream | inline |
operator>>(unsigned int &arg) | istream | inline |
operator>>(long &arg) | istream | inline |
operator>>(unsigned long &arg) | istream | inline |
operator>>(double &arg) | istream | inline |
operator>>(float &arg) | istream | inline |
operator>>(void *&arg) | istream | inline |
out | ios_base | static |
peek() | istream | |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
rdstate() const | ios | inline |
right | ios_base | static |
seekdir enum name | ios_base | |
seekg(pos_type pos) | istream | inline |
seekg(off_type off, seekdir way) | istream | inline |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipWhite() | istream | |
skipws | ios_base | static |
streamsize typedef | ios_base | |
tellg() | istream | inline |
trunc | ios_base | static |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
+ SdFat
+
+ |
+
parse a char string + More...
+ +#include <bufstream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
streamsize | gcount () const |
int | get () |
istream & | get (char &ch) |
istream & | get (char *str, streamsize n, char delim= '\n') |
istream & | getline (char *str, streamsize count, char delim= '\n') |
bool | good () const |
ibufstream () | |
ibufstream (const char *str) | |
istream & | ignore (streamsize n=1, int delim=-1) |
void | init (const char *str) |
operator const void * () const | |
bool | operator! () const |
istream & | operator>> (istream &(*pf)(istream &str)) |
istream & | operator>> (ios_base &(*pf)(ios_base &str)) |
istream & | operator>> (ios &(*pf)(ios &str)) |
istream & | operator>> (char *str) |
istream & | operator>> (char &ch) |
istream & | operator>> (signed char *str) |
istream & | operator>> (signed char &ch) |
istream & | operator>> (unsigned char *str) |
istream & | operator>> (unsigned char &ch) |
istream & | operator>> (bool &arg) |
istream & | operator>> (short &arg) |
istream & | operator>> (unsigned short &arg) |
istream & | operator>> (int &arg) |
istream & | operator>> (unsigned int &arg) |
istream & | operator>> (long &arg) |
istream & | operator>> (unsigned long &arg) |
istream & | operator>> (double &arg) |
istream & | operator>> (float &arg) |
istream & | operator>> (void *&arg) |
int | peek () |
int | precision () const |
int | precision (unsigned int n) |
iostate | rdstate () const |
istream & | seekg (pos_type pos) |
istream & | seekg (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
void | skipWhite () |
pos_type | tellg () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
parse a char string
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inline | +
Constructor
+ +
+
|
+ +inlineexplicit | +
Constructor
[in] | str | pointer to string to be parsed Warning: The string will not be copied so must stay in scope. |
+
|
+ +inlineinherited | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract a character if one is available.
+
+
|
+ +inherited | +
Extract a character if one is available.
+[out] | c | location to receive the extracted character. |
+
|
+ +inherited | +
Extract characters.
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, n is less than 1, n-1 characters are extracted, or the next character equals delim (delim is not extracted). If no characters are extracted failbit is set. If end-of-file occurs the eofbit is set.
+
+
|
+ +inherited | +
Extract characters
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, the next character equals delim (delim is extracted), or n-1 characters are extracted.
+The failbit is set if no characters are extracted or n-1 characters are extracted. If end-of-file occurs the eofbit is set.
+
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract characters and discard them.
+[in] | n | maximum number of characters to ignore. |
[in] | delim | Delimiter. |
Characters are extracted until extraction fails, n characters are extracted, or the next input character equals delim (the delimiter is extracted). If end-of-file occurs the eofbit is set.
+Failures are indicated by the state of the stream.
+
+
|
+ +inline | +
Initialize an ibufstream
[in] | str | pointer to string to be parsed Warning: The string will not be copied so must stay in scope. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a value of type bool.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type double.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type float.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type void*.
[out] | arg | location to store the value. |
+
|
+ +inherited | +
Return the next available character without consuming it.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the read pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inherited | +
used to implement ws()
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for ifstream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
available() | SdBaseFile | inlineprivate |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
clearWriteError() | SdBaseFile | inlineprivate |
close() | ifstream | inline |
contiguousRange(uint32_t *bgnBlock, uint32_t *endBlock) | SdBaseFile | private |
createContiguous(SdBaseFile *dirFile, const char *path, uint32_t size) | SdBaseFile | private |
cur enum value | ios_base | |
curCluster() const | SdBaseFile | inlineprivate |
curPosition() const | SdBaseFile | inlineprivate |
cwd() | SdBaseFile | inlineprivatestatic |
dateTimeCallback(void(*dateTime)(uint16_t *date, uint16_t *time)) | SdBaseFile | inlineprivatestatic |
dateTimeCallbackCancel() | SdBaseFile | inlineprivatestatic |
dec | ios_base | static |
dirEntry(dir_t *dir) | SdBaseFile | private |
dirName(const dir_t &dir, char *name) | SdBaseFile | privatestatic |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
exists(const char *name) | SdBaseFile | private |
fail() const | ios | inline |
failbit | ios_base | static |
fgets(char *str, int16_t num, char *delim=0) | SdBaseFile | private |
fileSize() const | SdBaseFile | inlineprivate |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
firstCluster() const | SdBaseFile | inlineprivate |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
fmtflags typedef | ios_base | |
gcount() const | istream | inline |
get() | istream | |
get(char &ch) | istream | |
get(char *str, streamsize n, char delim= '\n') | istream | |
getFilename(char *name) | SdBaseFile | private |
getline(char *str, streamsize count, char delim= '\n') | istream | |
getpos(FatPos_t *pos) | SdBaseFile | private |
getWriteError() | SdBaseFile | inlineprivate |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
ifstream() (defined in ifstream) | ifstream | inline |
ifstream(const char *path, openmode mode=in) | ifstream | inlineexplicit |
ignore(streamsize n=1, int delim=-1) | istream | |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
is_open() | ifstream | inline |
isDir() const | SdBaseFile | inlineprivate |
isFile() const | SdBaseFile | inlineprivate |
isOpen() const | SdBaseFile | inlineprivate |
isRoot() const | SdBaseFile | inlineprivate |
isSubDir() const | SdBaseFile | inlineprivate |
istream() (defined in istream) | istream | inline |
left | ios_base | static |
ls(Print *pr, uint8_t flags=0, uint8_t indent=0) | SdBaseFile | private |
ls(uint8_t flags=0) | SdBaseFile | private |
mkdir(SdBaseFile *dir, const char *path, bool pFlag=true) | SdBaseFile | private |
oct | ios_base | static |
off_type typedef | ios_base | |
open(const char *path, openmode mode=in) | ifstream | inline |
SdStreamBase::open(SdBaseFile *dirFile, uint16_t index, uint8_t oflag) | SdBaseFile | private |
SdStreamBase::open(SdBaseFile *dirFile, const char *path, uint8_t oflag) | SdBaseFile | private |
openmode typedef | ios_base | |
openNext(SdBaseFile *dirFile, uint8_t oflag) | SdBaseFile | private |
openRoot(SdVolume *vol) | SdBaseFile | private |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator>>(istream &(*pf)(istream &str)) | istream | inline |
operator>>(ios_base &(*pf)(ios_base &str)) | istream | inline |
operator>>(ios &(*pf)(ios &str)) | istream | inline |
operator>>(char *str) | istream | inline |
operator>>(char &ch) | istream | inline |
operator>>(signed char *str) | istream | inline |
operator>>(signed char &ch) | istream | inline |
operator>>(unsigned char *str) | istream | inline |
operator>>(unsigned char &ch) | istream | inline |
operator>>(bool &arg) | istream | inline |
operator>>(short &arg) | istream | inline |
operator>>(unsigned short &arg) | istream | inline |
operator>>(int &arg) | istream | inline |
operator>>(unsigned int &arg) | istream | inline |
operator>>(long &arg) | istream | inline |
operator>>(unsigned long &arg) | istream | inline |
operator>>(double &arg) | istream | inline |
operator>>(float &arg) | istream | inline |
operator>>(void *&arg) | istream | inline |
out | ios_base | static |
istream::peek() | istream | |
SdStreamBase::peek() | SdBaseFile | private |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
printCreateDateTime(Print *pr) | SdBaseFile | private |
printFatDate(uint16_t fatDate) | SdBaseFile | privatestatic |
printFatDate(Print *pr, uint16_t fatDate) | SdBaseFile | privatestatic |
printFatTime(uint16_t fatTime) | SdBaseFile | privatestatic |
printFatTime(Print *pr, uint16_t fatTime) | SdBaseFile | privatestatic |
printField(float value, char term, uint8_t prec=2) | SdBaseFile | private |
printField(int16_t value, char term) | SdBaseFile | private |
printField(uint16_t value, char term) | SdBaseFile | private |
printField(int32_t value, char term) | SdBaseFile | private |
printField(uint32_t value, char term) | SdBaseFile | private |
printFileSize(Print *pr) | SdBaseFile | private |
printModifyDateTime(Print *pr) | SdBaseFile | private |
printName() | SdBaseFile | private |
printName(Print *pr) | SdBaseFile | private |
rdstate() const | ios | inline |
read() | SdBaseFile | private |
read(void *buf, size_t nbyte) | SdBaseFile | private |
readDir(dir_t *dir) | SdBaseFile | private |
remove(SdBaseFile *dirFile, const char *path) | SdBaseFile | privatestatic |
remove() | SdBaseFile | private |
rename(SdBaseFile *dirFile, const char *newPath) | SdBaseFile | private |
rewind() | SdBaseFile | inlineprivate |
right | ios_base | static |
rmdir() | SdBaseFile | private |
rmRfStar() | SdBaseFile | private |
SdBaseFile() | SdBaseFile | inlineprivate |
SdBaseFile(const char *path, uint8_t oflag) | SdBaseFile | private |
seekCur(int32_t offset) | SdBaseFile | inlineprivate |
seekdir enum name | ios_base | |
seekEnd(int32_t offset=0) | SdBaseFile | inlineprivate |
seekg(pos_type pos) | istream | inline |
seekg(off_type off, seekdir way) | istream | inline |
seekSet(uint32_t pos) | SdBaseFile | private |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setpos(FatPos_t *pos) | SdBaseFile | private |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipWhite() | istream | |
skipws | ios_base | static |
streamsize typedef | ios_base | |
sync() | SdBaseFile | private |
tellg() | istream | inline |
timestamp(SdBaseFile *file) | SdBaseFile | private |
timestamp(uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) | SdBaseFile | private |
trunc | ios_base | static |
truncate(uint32_t size) | SdBaseFile | private |
type() const | SdBaseFile | inlineprivate |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
volume() const | SdBaseFile | inlineprivate |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
write(const void *buf, size_t nbyte) | SdBaseFile | private |
writeError | SdBaseFile | private |
+ SdFat
+
+ |
+
SD file input stream. + More...
+ +#include <SdStream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
void | close () |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
streamsize | gcount () const |
int | get () |
istream & | get (char &ch) |
istream & | get (char *str, streamsize n, char delim= '\n') |
istream & | getline (char *str, streamsize count, char delim= '\n') |
bool | good () const |
ifstream (const char *path, openmode mode=in) | |
istream & | ignore (streamsize n=1, int delim=-1) |
bool | is_open () |
void | open (const char *path, openmode mode=in) |
operator const void * () const | |
bool | operator! () const |
istream & | operator>> (istream &(*pf)(istream &str)) |
istream & | operator>> (ios_base &(*pf)(ios_base &str)) |
istream & | operator>> (ios &(*pf)(ios &str)) |
istream & | operator>> (char *str) |
istream & | operator>> (char &ch) |
istream & | operator>> (signed char *str) |
istream & | operator>> (signed char &ch) |
istream & | operator>> (unsigned char *str) |
istream & | operator>> (unsigned char &ch) |
istream & | operator>> (bool &arg) |
istream & | operator>> (short &arg) |
istream & | operator>> (unsigned short &arg) |
istream & | operator>> (int &arg) |
istream & | operator>> (unsigned int &arg) |
istream & | operator>> (long &arg) |
istream & | operator>> (unsigned long &arg) |
istream & | operator>> (double &arg) |
istream & | operator>> (float &arg) |
istream & | operator>> (void *&arg) |
int | peek () |
int | precision () const |
int | precision (unsigned int n) |
iostate | rdstate () const |
istream & | seekg (pos_type pos) |
istream & | seekg (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
void | skipWhite () |
pos_type | tellg () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
+Private Member Functions | |
uint32_t | available () |
void | clearWriteError () |
bool | contiguousRange (uint32_t *bgnBlock, uint32_t *endBlock) |
bool | createContiguous (SdBaseFile *dirFile, const char *path, uint32_t size) |
uint32_t | curCluster () const |
uint32_t | curPosition () const |
bool | dirEntry (dir_t *dir) |
bool | exists (const char *name) |
int16_t | fgets (char *str, int16_t num, char *delim=0) |
uint32_t | fileSize () const |
uint32_t | firstCluster () const |
bool | getFilename (char *name) |
void | getpos (FatPos_t *pos) |
bool | getWriteError () |
bool | isDir () const |
bool | isFile () const |
bool | isOpen () const |
bool | isRoot () const |
bool | isSubDir () const |
void | ls (Print *pr, uint8_t flags=0, uint8_t indent=0) |
void | ls (uint8_t flags=0) |
bool | mkdir (SdBaseFile *dir, const char *path, bool pFlag=true) |
bool | open (SdBaseFile *dirFile, uint16_t index, uint8_t oflag) |
bool | open (SdBaseFile *dirFile, const char *path, uint8_t oflag) |
bool | openNext (SdBaseFile *dirFile, uint8_t oflag) |
bool | openRoot (SdVolume *vol) |
int | peek () |
bool | printCreateDateTime (Print *pr) |
int | printField (float value, char term, uint8_t prec=2) |
int | printField (int16_t value, char term) |
int | printField (uint16_t value, char term) |
int | printField (int32_t value, char term) |
int | printField (uint32_t value, char term) |
size_t | printFileSize (Print *pr) |
bool | printModifyDateTime (Print *pr) |
size_t | printName () |
size_t | printName (Print *pr) |
int16_t | read () |
int | read (void *buf, size_t nbyte) |
int8_t | readDir (dir_t *dir) |
bool | remove () |
bool | rename (SdBaseFile *dirFile, const char *newPath) |
void | rewind () |
bool | rmdir () |
bool | rmRfStar () |
bool | seekCur (int32_t offset) |
bool | seekEnd (int32_t offset=0) |
bool | seekSet (uint32_t pos) |
void | setpos (FatPos_t *pos) |
bool | sync () |
bool | timestamp (SdBaseFile *file) |
bool | timestamp (uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) |
bool | truncate (uint32_t size) |
uint8_t | type () const |
SdVolume * | volume () const |
int | write (const void *buf, size_t nbyte) |
+Static Private Member Functions | |
static SdBaseFile * | cwd () |
static void | dateTimeCallback (void(*dateTime)(uint16_t *date, uint16_t *time)) |
static void | dateTimeCallbackCancel () |
static void | dirName (const dir_t &dir, char *name) |
static void | printFatDate (uint16_t fatDate) |
static void | printFatDate (Print *pr, uint16_t fatDate) |
static void | printFatTime (uint16_t fatTime) |
static void | printFatTime (Print *pr, uint16_t fatTime) |
static bool | remove (SdBaseFile *dirFile, const char *path) |
+Private Attributes | |
bool | writeError |
SD file input stream.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inlineexplicit | +
Constructor with open
[in] | path | file to open |
[in] | mode | open mode |
+
|
+ +inlineinherited | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inline | +
Close a file and force cached data and directory information to be written to the storage device.
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract a character if one is available.
+
+
|
+ +inherited | +
Extract a character if one is available.
+[out] | c | location to receive the extracted character. |
+
|
+ +inherited | +
Extract characters.
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, n is less than 1, n-1 characters are extracted, or the next character equals delim (delim is not extracted). If no characters are extracted failbit is set. If end-of-file occurs the eofbit is set.
+
+
|
+ +inherited | +
Extract characters
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, the next character equals delim (delim is extracted), or n-1 characters are extracted.
+The failbit is set if no characters are extracted or n-1 characters are extracted. If end-of-file occurs the eofbit is set.
+
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract characters and discard them.
+[in] | n | maximum number of characters to ignore. |
[in] | delim | Delimiter. |
Characters are extracted until extraction fails, n characters are extracted, or the next input character equals delim (the delimiter is extracted). If end-of-file occurs the eofbit is set.
+Failures are indicated by the state of the stream.
+
+
|
+ +inline | +
+
|
+ +inline | +
Open an ifstream
[in] | path | file to open |
[in] | mode | open mode |
mode See fstream::open() for valid modes.
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a value of type bool.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type double.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type float.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type void*.
[out] | arg | location to store the value. |
+
|
+ +inherited | +
Return the next available character without consuming it.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the read pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inherited | +
used to implement ws()
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for ios, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
cur enum value | ios_base | |
dec | ios_base | static |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
fail() const | ios | inline |
failbit | ios_base | static |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
fmtflags typedef | ios_base | |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
left | ios_base | static |
oct | ios_base | static |
off_type typedef | ios_base | |
openmode typedef | ios_base | |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
out | ios_base | static |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
rdstate() const | ios | inline |
right | ios_base | static |
seekdir enum name | ios_base | |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipws | ios_base | static |
streamsize typedef | ios_base | |
trunc | ios_base | static |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
+ SdFat
+
+ |
+
Error and state information for all streams. + More...
+ +#include <ios.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
bool | good () const |
ios () | |
operator const void * () const | |
bool | operator! () const |
int | precision () const |
int | precision (unsigned int n) |
iostate | rdstate () const |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
Error and state information for all streams.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inline | +
Create ios with no error flags set
+ +
+
|
+ +inline | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inline | +
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inline | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for ios_base, including all inherited members.
+
+ SdFat
+
+ |
+
Base class for all streams. + More...
+ +#include <ios.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
int | precision () const |
int | precision (unsigned int n) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
Base class for all streams.
+typedef unsigned int ios_base::fmtflags | +
type for format flags
+ +typedef unsigned char ios_base::iostate | +
typedef for iostate bitmask
+ +typedef int32_t ios_base::off_type | +
type for relative seek offset
+ +typedef uint8_t ios_base::openmode | +
typedef for iostream open mode
+ +typedef uint32_t ios_base::pos_type | +
type for absolute seek position
+ +typedef uint32_t ios_base::streamsize | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +enum ios_base::seekdir | +
+
|
+ +inline | +
+
|
+ +inline | +
Set fill character
[in] | c | new fill character |
+
|
+ +inline | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotected | +
+
|
+ +inline | +
+
|
+ +inline | +
set precision
[in] | n | new precision |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inline | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inline | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inline | +
+
|
+ +inline | +
set width
[in] | n | new width |
mask for adjustfield
+ +
+
|
+ +static | +
seek to end before each write
+ +
+
|
+ +static | +
open and seek to end immediately after opening
+ +
+
|
+ +static | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +static | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +static | +
use strings true/false for bool
+ +
+
|
+ +static | +
base 10 flag
+ +
+
|
+ +static | +
iostate bit for end of file reached
+ +
+
|
+ +static | +
iostate fail bit for nonfatal error
+ +
+
|
+ +static | +
iostate for no flags
+ +
+
|
+ +static | +
base 16 flag
+ +
+
|
+ +static | +
open for input
+ +
+
|
+ +static | +
fill between sign/base prefix and number
+ +
+
|
+ +static | +
left adjust fields
+ +
+
|
+ +static | +
base 8 flag
+ +
+
|
+ +static | +
open for output
+ +
+
|
+ +static | +
right adjust fields
+ +
+
|
+ +static | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +static | +
always show '.' for floating numbers
+ +
+
|
+ +static | +
show + sign for nonnegative numbers
+ +
+
|
+ +static | +
skip initial white space
+ +
+
|
+ +static | +
truncate an existing stream when opening
+ +
+
|
+ +static | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for iostream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
cur enum value | ios_base | |
dec | ios_base | static |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
fail() const | ios | inline |
failbit | ios_base | static |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
flush() | ostream | inline |
fmtflags typedef | ios_base | |
gcount() const | istream | inline |
get() | istream | |
get(char &ch) | istream | |
get(char *str, streamsize n, char delim= '\n') | istream | |
getline(char *str, streamsize count, char delim= '\n') | istream | |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
ignore(streamsize n=1, int delim=-1) | istream | |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
istream() (defined in istream) | istream | inline |
left | ios_base | static |
oct | ios_base | static |
off_type typedef | ios_base | |
openmode typedef | ios_base | |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator<<(ostream &(*pf)(ostream &str)) | ostream | inline |
operator<<(ios_base &(*pf)(ios_base &str)) | ostream | inline |
operator<<(bool arg) | ostream | inline |
operator<<(const char *arg) | ostream | inline |
operator<<(const signed char *arg) | ostream | inline |
operator<<(const unsigned char *arg) | ostream | inline |
operator<<(char arg) | ostream | inline |
operator<<(signed char arg) | ostream | inline |
operator<<(unsigned char arg) | ostream | inline |
operator<<(double arg) | ostream | inline |
operator<<(float arg) | ostream | inline |
operator<<(short arg) | ostream | inline |
operator<<(unsigned short arg) | ostream | inline |
operator<<(int arg) | ostream | inline |
operator<<(unsigned int arg) | ostream | inline |
operator<<(long arg) | ostream | inline |
operator<<(unsigned long arg) | ostream | inline |
operator<<(const void *arg) | ostream | inline |
operator<<(pgm arg) | ostream | inline |
operator<<(const __FlashStringHelper *arg) | ostream | inline |
operator>>(istream &(*pf)(istream &str)) | istream | inline |
operator>>(ios_base &(*pf)(ios_base &str)) | istream | inline |
operator>>(ios &(*pf)(ios &str)) | istream | inline |
operator>>(char *str) | istream | inline |
operator>>(char &ch) | istream | inline |
operator>>(signed char *str) | istream | inline |
operator>>(signed char &ch) | istream | inline |
operator>>(unsigned char *str) | istream | inline |
operator>>(unsigned char &ch) | istream | inline |
operator>>(bool &arg) | istream | inline |
operator>>(short &arg) | istream | inline |
operator>>(unsigned short &arg) | istream | inline |
operator>>(int &arg) | istream | inline |
operator>>(unsigned int &arg) | istream | inline |
operator>>(long &arg) | istream | inline |
operator>>(unsigned long &arg) | istream | inline |
operator>>(double &arg) | istream | inline |
operator>>(float &arg) | istream | inline |
operator>>(void *&arg) | istream | inline |
ostream() (defined in ostream) | ostream | inline |
out | ios_base | static |
peek() | istream | |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
put(char ch) | ostream | inline |
rdstate() const | ios | inline |
right | ios_base | static |
seekdir enum name | ios_base | |
seekg(pos_type pos) | istream | inline |
seekg(off_type off, seekdir way) | istream | inline |
seekp(pos_type pos) | ostream | inline |
seekp(off_type off, seekdir way) | ostream | inline |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipWhite() | istream | |
skipws | ios_base | static |
streamsize typedef | ios_base | |
tellg() | istream | inline |
tellp() | ostream | inline |
trunc | ios_base | static |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
+ SdFat
+
+ |
+
Input/Output stream. + More...
+ +#include <iostream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
ostream & | flush () |
streamsize | gcount () const |
int | get () |
istream & | get (char &ch) |
istream & | get (char *str, streamsize n, char delim= '\n') |
istream & | getline (char *str, streamsize count, char delim= '\n') |
bool | good () const |
istream & | ignore (streamsize n=1, int delim=-1) |
operator const void * () const | |
bool | operator! () const |
ostream & | operator<< (ostream &(*pf)(ostream &str)) |
ostream & | operator<< (ios_base &(*pf)(ios_base &str)) |
ostream & | operator<< (bool arg) |
ostream & | operator<< (const char *arg) |
ostream & | operator<< (const signed char *arg) |
ostream & | operator<< (const unsigned char *arg) |
ostream & | operator<< (char arg) |
ostream & | operator<< (signed char arg) |
ostream & | operator<< (unsigned char arg) |
ostream & | operator<< (double arg) |
ostream & | operator<< (float arg) |
ostream & | operator<< (short arg) |
ostream & | operator<< (unsigned short arg) |
ostream & | operator<< (int arg) |
ostream & | operator<< (unsigned int arg) |
ostream & | operator<< (long arg) |
ostream & | operator<< (unsigned long arg) |
ostream & | operator<< (const void *arg) |
ostream & | operator<< (pgm arg) |
ostream & | operator<< (const __FlashStringHelper *arg) |
istream & | operator>> (istream &(*pf)(istream &str)) |
istream & | operator>> (ios_base &(*pf)(ios_base &str)) |
istream & | operator>> (ios &(*pf)(ios &str)) |
istream & | operator>> (char *str) |
istream & | operator>> (char &ch) |
istream & | operator>> (signed char *str) |
istream & | operator>> (signed char &ch) |
istream & | operator>> (unsigned char *str) |
istream & | operator>> (unsigned char &ch) |
istream & | operator>> (bool &arg) |
istream & | operator>> (short &arg) |
istream & | operator>> (unsigned short &arg) |
istream & | operator>> (int &arg) |
istream & | operator>> (unsigned int &arg) |
istream & | operator>> (long &arg) |
istream & | operator>> (unsigned long &arg) |
istream & | operator>> (double &arg) |
istream & | operator>> (float &arg) |
istream & | operator>> (void *&arg) |
int | peek () |
int | precision () const |
int | precision (unsigned int n) |
ostream & | put (char ch) |
iostate | rdstate () const |
istream & | seekg (pos_type pos) |
istream & | seekg (off_type off, seekdir way) |
ostream & | seekp (pos_type pos) |
ostream & | seekp (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
void | skipWhite () |
pos_type | tellg () |
pos_type | tellp () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
Input/Output stream.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inlineinherited | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inlineinherited | +
Flushes the buffer associated with this stream. The flush function calls the sync function of the associated file.
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract a character if one is available.
+
+
|
+ +inherited | +
Extract a character if one is available.
+[out] | c | location to receive the extracted character. |
+
|
+ +inherited | +
Extract characters.
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, n is less than 1, n-1 characters are extracted, or the next character equals delim (delim is not extracted). If no characters are extracted failbit is set. If end-of-file occurs the eofbit is set.
+
+
|
+ +inherited | +
Extract characters
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, the next character equals delim (delim is extracted), or n-1 characters are extracted.
+The failbit is set if no characters are extracted or n-1 characters are extracted. If end-of-file occurs the eofbit is set.
+
+
|
+ +inlineinherited | +
+
|
+ +inherited | +
Extract characters and discard them.
+[in] | n | maximum number of characters to ignore. |
[in] | delim | Delimiter. |
Characters are extracted until extraction fails, n characters are extracted, or the next input character equals delim (the delimiter is extracted). If end-of-file occurs the eofbit is set.
+Failures are indicated by the state of the stream.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Output bool
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output double
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output float
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output pointer
[in] | arg | value to output |
Output a string from flash using the pstr() macro
[in] | arg | pgm struct pointing to string |
+
|
+ +inlineinherited | +
Output a string from flash using the Arduino F() macro.
[in] | arg | pointing to flash string |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inlineinherited | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inlineinherited | +
Extract a value of type bool.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned short.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned int.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type unsigned long.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type double.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type float.
[out] | arg | location to store the value. |
+
|
+ +inlineinherited | +
Extract a value of type void*.
[out] | arg | location to store the value. |
+
|
+ +inherited | +
Return the next available character without consuming it.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
Puts a character in a stream.
+The unformatted output function inserts the element ch. It returns *this.
+[in] | ch | The character |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the read pointer. |
Set the stream position
[in] | pos | The absolute position in which to move the write pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inherited | +
used to implement ws()
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for istream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
cur enum value | ios_base | |
dec | ios_base | static |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
fail() const | ios | inline |
failbit | ios_base | static |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
fmtflags typedef | ios_base | |
gcount() const | istream | inline |
get() | istream | |
get(char &ch) | istream | |
get(char *str, streamsize n, char delim= '\n') | istream | |
getline(char *str, streamsize count, char delim= '\n') | istream | |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
ignore(streamsize n=1, int delim=-1) | istream | |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
istream() (defined in istream) | istream | inline |
left | ios_base | static |
oct | ios_base | static |
off_type typedef | ios_base | |
openmode typedef | ios_base | |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator>>(istream &(*pf)(istream &str)) | istream | inline |
operator>>(ios_base &(*pf)(ios_base &str)) | istream | inline |
operator>>(ios &(*pf)(ios &str)) | istream | inline |
operator>>(char *str) | istream | inline |
operator>>(char &ch) | istream | inline |
operator>>(signed char *str) | istream | inline |
operator>>(signed char &ch) | istream | inline |
operator>>(unsigned char *str) | istream | inline |
operator>>(unsigned char &ch) | istream | inline |
operator>>(bool &arg) | istream | inline |
operator>>(short &arg) | istream | inline |
operator>>(unsigned short &arg) | istream | inline |
operator>>(int &arg) | istream | inline |
operator>>(unsigned int &arg) | istream | inline |
operator>>(long &arg) | istream | inline |
operator>>(unsigned long &arg) | istream | inline |
operator>>(double &arg) | istream | inline |
operator>>(float &arg) | istream | inline |
operator>>(void *&arg) | istream | inline |
out | ios_base | static |
peek() | istream | |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
rdstate() const | ios | inline |
right | ios_base | static |
seekdir enum name | ios_base | |
seekg(pos_type pos) | istream | inline |
seekg(off_type off, seekdir way) | istream | inline |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipWhite() | istream | |
skipws | ios_base | static |
streamsize typedef | ios_base | |
tellg() | istream | inline |
trunc | ios_base | static |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
+ SdFat
+
+ |
+
Input Stream. + More...
+ +#include <istream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
streamsize | gcount () const |
int | get () |
istream & | get (char &ch) |
istream & | get (char *str, streamsize n, char delim= '\n') |
istream & | getline (char *str, streamsize count, char delim= '\n') |
bool | good () const |
istream & | ignore (streamsize n=1, int delim=-1) |
operator const void * () const | |
bool | operator! () const |
istream & | operator>> (istream &(*pf)(istream &str)) |
istream & | operator>> (ios_base &(*pf)(ios_base &str)) |
istream & | operator>> (ios &(*pf)(ios &str)) |
istream & | operator>> (char *str) |
istream & | operator>> (char &ch) |
istream & | operator>> (signed char *str) |
istream & | operator>> (signed char &ch) |
istream & | operator>> (unsigned char *str) |
istream & | operator>> (unsigned char &ch) |
istream & | operator>> (bool &arg) |
istream & | operator>> (short &arg) |
istream & | operator>> (unsigned short &arg) |
istream & | operator>> (int &arg) |
istream & | operator>> (unsigned int &arg) |
istream & | operator>> (long &arg) |
istream & | operator>> (unsigned long &arg) |
istream & | operator>> (double &arg) |
istream & | operator>> (float &arg) |
istream & | operator>> (void *&arg) |
int | peek () |
int | precision () const |
int | precision (unsigned int n) |
iostate | rdstate () const |
istream & | seekg (pos_type pos) |
istream & | seekg (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
void | skipWhite () |
pos_type | tellg () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
Input Stream.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inlineinherited | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inline | +
int istream::get | +( | +) | ++ |
Extract a character if one is available.
+istream & istream::get | +( | +char & | +c | ) | ++ |
Extract a character if one is available.
+[out] | c | location to receive the extracted character. |
istream & istream::get | +( | +char * | +str, | +
+ | + | streamsize | +n, | +
+ | + | char | +delim = '\n' |
+
+ | ) | ++ |
Extract characters.
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, n is less than 1, n-1 characters are extracted, or the next character equals delim (delim is not extracted). If no characters are extracted failbit is set. If end-of-file occurs the eofbit is set.
+istream & istream::getline | +( | +char * | +str, | +
+ | + | streamsize | +n, | +
+ | + | char | +delim = '\n' |
+
+ | ) | ++ |
Extract characters
+[out] | str | Location to receive extracted characters. |
[in] | n | Size of str. |
[in] | delim | Delimiter |
Characters are extracted until extraction fails, the next character equals delim (delim is extracted), or n-1 characters are extracted.
+The failbit is set if no characters are extracted or n-1 characters are extracted. If end-of-file occurs the eofbit is set.
+
+
|
+ +inlineinherited | +
istream & istream::ignore | +( | +streamsize | +n = 1 , |
+
+ | + | int | +delim = -1 |
+
+ | ) | ++ |
Extract characters and discard them.
+[in] | n | maximum number of characters to ignore. |
[in] | delim | Delimiter. |
Characters are extracted until extraction fails, n characters are extracted, or the next input character equals delim (the delimiter is extracted). If end-of-file occurs the eofbit is set.
+Failures are indicated by the state of the stream.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inline | +
call manipulator
[in] | pf | function to call |
+
|
+ +inline | +
call manipulator
[in] | pf | function to call |
call manipulator
[in] | pf | function to call |
+
|
+ +inline | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inline | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inline | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inline | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inline | +
Extract a character string
[out] | str | location to store the string. |
+
|
+ +inline | +
Extract a character
[out] | ch | location to store the character. |
+
|
+ +inline | +
Extract a value of type bool.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type short.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type unsigned short.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type int.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type unsigned int.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type long.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type unsigned long.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type double.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type float.
[out] | arg | location to store the value. |
+
|
+ +inline | +
Extract a value of type void*.
[out] | arg | location to store the value. |
int istream::peek | +( | +) | ++ |
Return the next available character without consuming it.
+
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the read pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
void istream::skipWhite | +( | +) | ++ |
used to implement ws()
+ +
+
|
+ +inline | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for obufstream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
buf() | obufstream | inline |
clear(iostate state=goodbit) | ios | inline |
cur enum value | ios_base | |
dec | ios_base | static |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
fail() const | ios | inline |
failbit | ios_base | static |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
flush() | ostream | inline |
fmtflags typedef | ios_base | |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
in | ios_base | static |
init(char *buf, size_t size) | obufstream | inline |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
left | ios_base | static |
length() | obufstream | inline |
obufstream() | obufstream | inline |
obufstream(char *buf, size_t size) | obufstream | inline |
oct | ios_base | static |
off_type typedef | ios_base | |
openmode typedef | ios_base | |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator<<(ostream &(*pf)(ostream &str)) | ostream | inline |
operator<<(ios_base &(*pf)(ios_base &str)) | ostream | inline |
operator<<(bool arg) | ostream | inline |
operator<<(const char *arg) | ostream | inline |
operator<<(const signed char *arg) | ostream | inline |
operator<<(const unsigned char *arg) | ostream | inline |
operator<<(char arg) | ostream | inline |
operator<<(signed char arg) | ostream | inline |
operator<<(unsigned char arg) | ostream | inline |
operator<<(double arg) | ostream | inline |
operator<<(float arg) | ostream | inline |
operator<<(short arg) | ostream | inline |
operator<<(unsigned short arg) | ostream | inline |
operator<<(int arg) | ostream | inline |
operator<<(unsigned int arg) | ostream | inline |
operator<<(long arg) | ostream | inline |
operator<<(unsigned long arg) | ostream | inline |
operator<<(const void *arg) | ostream | inline |
operator<<(pgm arg) | ostream | inline |
operator<<(const __FlashStringHelper *arg) | ostream | inline |
ostream() (defined in ostream) | ostream | inline |
out | ios_base | static |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
put(char ch) | ostream | inline |
rdstate() const | ios | inline |
right | ios_base | static |
seekdir enum name | ios_base | |
seekp(pos_type pos) | ostream | inline |
seekp(off_type off, seekdir way) | ostream | inline |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipws | ios_base | static |
streamsize typedef | ios_base | |
tellp() | ostream | inline |
trunc | ios_base | static |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
+ SdFat
+
+ |
+
format a char string + More...
+ +#include <bufstream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
char * | buf () |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
ostream & | flush () |
bool | good () const |
void | init (char *buf, size_t size) |
size_t | length () |
obufstream () | |
obufstream (char *buf, size_t size) | |
operator const void * () const | |
bool | operator! () const |
ostream & | operator<< (ostream &(*pf)(ostream &str)) |
ostream & | operator<< (ios_base &(*pf)(ios_base &str)) |
ostream & | operator<< (bool arg) |
ostream & | operator<< (const char *arg) |
ostream & | operator<< (const signed char *arg) |
ostream & | operator<< (const unsigned char *arg) |
ostream & | operator<< (char arg) |
ostream & | operator<< (signed char arg) |
ostream & | operator<< (unsigned char arg) |
ostream & | operator<< (double arg) |
ostream & | operator<< (float arg) |
ostream & | operator<< (short arg) |
ostream & | operator<< (unsigned short arg) |
ostream & | operator<< (int arg) |
ostream & | operator<< (unsigned int arg) |
ostream & | operator<< (long arg) |
ostream & | operator<< (unsigned long arg) |
ostream & | operator<< (const void *arg) |
ostream & | operator<< (pgm arg) |
ostream & | operator<< (const __FlashStringHelper *arg) |
int | precision () const |
int | precision (unsigned int n) |
ostream & | put (char ch) |
iostate | rdstate () const |
ostream & | seekp (pos_type pos) |
ostream & | seekp (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
pos_type | tellp () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
format a char string
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inline | +
constructor
+ +
+
|
+ +inline | +
Constructor
[in] | buf | buffer for formatted string |
[in] | size | buffer size |
+
|
+ +inlineinherited | +
+
|
+ +inline | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inlineinherited | +
Flushes the buffer associated with this stream. The flush function calls the sync function of the associated file.
+
|
+ +inlineinherited | +
+
|
+ +inline | +
Initialize an obufstream
[in] | buf | buffer for formatted string |
[in] | size | buffer size |
+
|
+ +inline | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Output bool
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output double
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output float
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output pointer
[in] | arg | value to output |
Output a string from flash using the pstr() macro
[in] | arg | pgm struct pointing to string |
+
|
+ +inlineinherited | +
Output a string from flash using the Arduino F() macro.
[in] | arg | pointing to flash string |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
Puts a character in a stream.
+The unformatted output function inserts the element ch. It returns *this.
+[in] | ch | The character |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the write pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for ofstream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
available() | SdBaseFile | inlineprivate |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ofstream | inline |
clearWriteError() | SdBaseFile | inlineprivate |
close() | ofstream | inline |
contiguousRange(uint32_t *bgnBlock, uint32_t *endBlock) | SdBaseFile | private |
createContiguous(SdBaseFile *dirFile, const char *path, uint32_t size) | SdBaseFile | private |
cur enum value | ios_base | |
curCluster() const | SdBaseFile | inlineprivate |
curPosition() const | SdBaseFile | inlineprivate |
cwd() | SdBaseFile | inlineprivatestatic |
dateTimeCallback(void(*dateTime)(uint16_t *date, uint16_t *time)) | SdBaseFile | inlineprivatestatic |
dateTimeCallbackCancel() | SdBaseFile | inlineprivatestatic |
dec | ios_base | static |
dirEntry(dir_t *dir) | SdBaseFile | private |
dirName(const dir_t &dir, char *name) | SdBaseFile | privatestatic |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
exists(const char *name) | SdBaseFile | private |
fail() const | ios | inline |
failbit | ios_base | static |
fgets(char *str, int16_t num, char *delim=0) | SdBaseFile | private |
fileSize() const | SdBaseFile | inlineprivate |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
firstCluster() const | SdBaseFile | inlineprivate |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
flush() | ostream | inline |
fmtflags typedef | ios_base | |
getFilename(char *name) | SdBaseFile | private |
getpos(FatPos_t *pos) | SdBaseFile | private |
getWriteError() | SdBaseFile | inlineprivate |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
is_open() | ofstream | inline |
isDir() const | SdBaseFile | inlineprivate |
isFile() const | SdBaseFile | inlineprivate |
isOpen() const | SdBaseFile | inlineprivate |
isRoot() const | SdBaseFile | inlineprivate |
isSubDir() const | SdBaseFile | inlineprivate |
left | ios_base | static |
ls(Print *pr, uint8_t flags=0, uint8_t indent=0) | SdBaseFile | private |
ls(uint8_t flags=0) | SdBaseFile | private |
mkdir(SdBaseFile *dir, const char *path, bool pFlag=true) | SdBaseFile | private |
oct | ios_base | static |
off_type typedef | ios_base | |
ofstream() (defined in ofstream) | ofstream | inline |
ofstream(const char *path, ios::openmode mode=out) | ofstream | inlineexplicit |
open(const char *path, openmode mode=out) | ofstream | inline |
SdStreamBase::open(SdBaseFile *dirFile, uint16_t index, uint8_t oflag) | SdBaseFile | private |
SdStreamBase::open(SdBaseFile *dirFile, const char *path, uint8_t oflag) | SdBaseFile | private |
openmode typedef | ios_base | |
openNext(SdBaseFile *dirFile, uint8_t oflag) | SdBaseFile | private |
openRoot(SdVolume *vol) | SdBaseFile | private |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator<<(ostream &(*pf)(ostream &str)) | ostream | inline |
operator<<(ios_base &(*pf)(ios_base &str)) | ostream | inline |
operator<<(bool arg) | ostream | inline |
operator<<(const char *arg) | ostream | inline |
operator<<(const signed char *arg) | ostream | inline |
operator<<(const unsigned char *arg) | ostream | inline |
operator<<(char arg) | ostream | inline |
operator<<(signed char arg) | ostream | inline |
operator<<(unsigned char arg) | ostream | inline |
operator<<(double arg) | ostream | inline |
operator<<(float arg) | ostream | inline |
operator<<(short arg) | ostream | inline |
operator<<(unsigned short arg) | ostream | inline |
operator<<(int arg) | ostream | inline |
operator<<(unsigned int arg) | ostream | inline |
operator<<(long arg) | ostream | inline |
operator<<(unsigned long arg) | ostream | inline |
operator<<(const void *arg) | ostream | inline |
operator<<(pgm arg) | ostream | inline |
operator<<(const __FlashStringHelper *arg) | ostream | inline |
ostream() (defined in ostream) | ostream | inline |
out | ios_base | static |
peek() | SdBaseFile | private |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
printCreateDateTime(Print *pr) | SdBaseFile | private |
printFatDate(uint16_t fatDate) | SdBaseFile | privatestatic |
printFatDate(Print *pr, uint16_t fatDate) | SdBaseFile | privatestatic |
printFatTime(uint16_t fatTime) | SdBaseFile | privatestatic |
printFatTime(Print *pr, uint16_t fatTime) | SdBaseFile | privatestatic |
printField(float value, char term, uint8_t prec=2) | SdBaseFile | private |
printField(int16_t value, char term) | SdBaseFile | private |
printField(uint16_t value, char term) | SdBaseFile | private |
printField(int32_t value, char term) | SdBaseFile | private |
printField(uint32_t value, char term) | SdBaseFile | private |
printFileSize(Print *pr) | SdBaseFile | private |
printModifyDateTime(Print *pr) | SdBaseFile | private |
printName() | SdBaseFile | private |
printName(Print *pr) | SdBaseFile | private |
put(char ch) | ostream | inline |
rdstate() const | ios | inline |
read() | SdBaseFile | private |
read(void *buf, size_t nbyte) | SdBaseFile | private |
readDir(dir_t *dir) | SdBaseFile | private |
remove(SdBaseFile *dirFile, const char *path) | SdBaseFile | privatestatic |
remove() | SdBaseFile | private |
rename(SdBaseFile *dirFile, const char *newPath) | SdBaseFile | private |
rewind() | SdBaseFile | inlineprivate |
right | ios_base | static |
rmdir() | SdBaseFile | private |
rmRfStar() | SdBaseFile | private |
SdBaseFile() | SdBaseFile | inlineprivate |
SdBaseFile(const char *path, uint8_t oflag) | SdBaseFile | private |
seekCur(int32_t offset) | SdBaseFile | inlineprivate |
seekdir enum name | ios_base | |
seekEnd(int32_t offset=0) | SdBaseFile | inlineprivate |
seekp(pos_type pos) | ostream | inline |
seekp(off_type off, seekdir way) | ostream | inline |
seekSet(uint32_t pos) | SdBaseFile | private |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setpos(FatPos_t *pos) | SdBaseFile | private |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipws | ios_base | static |
streamsize typedef | ios_base | |
sync() | SdBaseFile | private |
tellp() | ostream | inline |
timestamp(SdBaseFile *file) | SdBaseFile | private |
timestamp(uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) | SdBaseFile | private |
trunc | ios_base | static |
truncate(uint32_t size) | SdBaseFile | private |
type() const | SdBaseFile | inlineprivate |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
volume() const | SdBaseFile | inlineprivate |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
write(const void *buf, size_t nbyte) | SdBaseFile | private |
writeError | SdBaseFile | private |
+ SdFat
+
+ |
+
SD card output stream. + More...
+ +#include <SdStream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
void | close () |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
ostream & | flush () |
bool | good () const |
bool | is_open () |
ofstream (const char *path, ios::openmode mode=out) | |
void | open (const char *path, openmode mode=out) |
operator const void * () const | |
bool | operator! () const |
ostream & | operator<< (ostream &(*pf)(ostream &str)) |
ostream & | operator<< (ios_base &(*pf)(ios_base &str)) |
ostream & | operator<< (bool arg) |
ostream & | operator<< (const char *arg) |
ostream & | operator<< (const signed char *arg) |
ostream & | operator<< (const unsigned char *arg) |
ostream & | operator<< (char arg) |
ostream & | operator<< (signed char arg) |
ostream & | operator<< (unsigned char arg) |
ostream & | operator<< (double arg) |
ostream & | operator<< (float arg) |
ostream & | operator<< (short arg) |
ostream & | operator<< (unsigned short arg) |
ostream & | operator<< (int arg) |
ostream & | operator<< (unsigned int arg) |
ostream & | operator<< (long arg) |
ostream & | operator<< (unsigned long arg) |
ostream & | operator<< (const void *arg) |
ostream & | operator<< (pgm arg) |
ostream & | operator<< (const __FlashStringHelper *arg) |
int | precision () const |
int | precision (unsigned int n) |
ostream & | put (char ch) |
iostate | rdstate () const |
ostream & | seekp (pos_type pos) |
ostream & | seekp (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
pos_type | tellp () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
+Private Member Functions | |
uint32_t | available () |
void | clearWriteError () |
bool | contiguousRange (uint32_t *bgnBlock, uint32_t *endBlock) |
bool | createContiguous (SdBaseFile *dirFile, const char *path, uint32_t size) |
uint32_t | curCluster () const |
uint32_t | curPosition () const |
bool | dirEntry (dir_t *dir) |
bool | exists (const char *name) |
int16_t | fgets (char *str, int16_t num, char *delim=0) |
uint32_t | fileSize () const |
uint32_t | firstCluster () const |
bool | getFilename (char *name) |
void | getpos (FatPos_t *pos) |
bool | getWriteError () |
bool | isDir () const |
bool | isFile () const |
bool | isOpen () const |
bool | isRoot () const |
bool | isSubDir () const |
void | ls (Print *pr, uint8_t flags=0, uint8_t indent=0) |
void | ls (uint8_t flags=0) |
bool | mkdir (SdBaseFile *dir, const char *path, bool pFlag=true) |
bool | open (SdBaseFile *dirFile, uint16_t index, uint8_t oflag) |
bool | open (SdBaseFile *dirFile, const char *path, uint8_t oflag) |
bool | openNext (SdBaseFile *dirFile, uint8_t oflag) |
bool | openRoot (SdVolume *vol) |
int | peek () |
bool | printCreateDateTime (Print *pr) |
int | printField (float value, char term, uint8_t prec=2) |
int | printField (int16_t value, char term) |
int | printField (uint16_t value, char term) |
int | printField (int32_t value, char term) |
int | printField (uint32_t value, char term) |
size_t | printFileSize (Print *pr) |
bool | printModifyDateTime (Print *pr) |
size_t | printName () |
size_t | printName (Print *pr) |
int16_t | read () |
int | read (void *buf, size_t nbyte) |
int8_t | readDir (dir_t *dir) |
bool | remove () |
bool | rename (SdBaseFile *dirFile, const char *newPath) |
void | rewind () |
bool | rmdir () |
bool | rmRfStar () |
bool | seekCur (int32_t offset) |
bool | seekEnd (int32_t offset=0) |
bool | seekSet (uint32_t pos) |
void | setpos (FatPos_t *pos) |
bool | sync () |
bool | timestamp (SdBaseFile *file) |
bool | timestamp (uint8_t flag, uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second) |
bool | truncate (uint32_t size) |
uint8_t | type () const |
SdVolume * | volume () const |
int | write (const void *buf, size_t nbyte) |
+Static Private Member Functions | |
static SdBaseFile * | cwd () |
static void | dateTimeCallback (void(*dateTime)(uint16_t *date, uint16_t *time)) |
static void | dateTimeCallbackCancel () |
static void | dirName (const dir_t &dir, char *name) |
static void | printFatDate (uint16_t fatDate) |
static void | printFatDate (Print *pr, uint16_t fatDate) |
static void | printFatTime (uint16_t fatTime) |
static void | printFatTime (Print *pr, uint16_t fatTime) |
static bool | remove (SdBaseFile *dirFile, const char *path) |
+Private Attributes | |
bool | writeError |
SD card output stream.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inlineexplicit | +
Constructor with open
[in] | path | file to open |
[in] | mode | open mode |
+
|
+ +inlineinherited | +
Clear state and writeError
[in] | state | new state for stream |
+
|
+ +inline | +
Close a file and force cached data and directory information to be written to the storage device.
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inlineinherited | +
Flushes the buffer associated with this stream. The flush function calls the sync function of the associated file.
+
|
+ +inlineinherited | +
+
|
+ +inline | +
+
|
+ +inline | +
Open an ofstream
[in] | path | file to open |
[in] | mode | open mode |
mode See fstream::open() for valid modes.
+ +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
call manipulator
[in] | pf | function to call |
+
|
+ +inlineinherited | +
Output bool
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output string
[in] | arg | string to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output character
[in] | arg | character to output |
+
|
+ +inlineinherited | +
Output double
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output float
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned short
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned int
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output signed long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output unsigned long
[in] | arg | value to output |
+
|
+ +inlineinherited | +
Output pointer
[in] | arg | value to output |
Output a string from flash using the pstr() macro
[in] | arg | pgm struct pointing to string |
+
|
+ +inlineinherited | +
Output a string from flash using the Arduino F() macro.
[in] | arg | pointing to flash string |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inlineinherited | +
Puts a character in a stream.
+The unformatted output function inserts the element ch. It returns *this.
+[in] | ch | The character |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the write pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
This is the complete list of members for ostream, including all inherited members.
+adjustfield | ios_base | static |
app | ios_base | static |
ate | ios_base | static |
bad() const | ios | inline |
badbit | ios_base | static |
basefield | ios_base | static |
beg enum value | ios_base | |
binary | ios_base | static |
boolalpha | ios_base | static |
clear(iostate state=goodbit) | ios | inline |
cur enum value | ios_base | |
dec | ios_base | static |
end enum value | ios_base | |
eof() const | ios | inline |
eofbit | ios_base | static |
fail() const | ios | inline |
failbit | ios_base | static |
fill() | ios_base | inline |
fill(char c) | ios_base | inline |
flags() const | ios_base | inline |
flags(fmtflags fl) | ios_base | inline |
flagsToBase() | ios_base | inlineprotected |
flush() | ostream | inline |
fmtflags typedef | ios_base | |
good() const | ios | inline |
goodbit | ios_base | static |
hex | ios_base | static |
in | ios_base | static |
internal | ios_base | static |
ios() | ios | inline |
ios_base() (defined in ios_base) | ios_base | inline |
iostate typedef | ios_base | |
left | ios_base | static |
oct | ios_base | static |
off_type typedef | ios_base | |
openmode typedef | ios_base | |
operator const void *() const | ios | inline |
operator!() const | ios | inline |
operator<<(ostream &(*pf)(ostream &str)) | ostream | inline |
operator<<(ios_base &(*pf)(ios_base &str)) | ostream | inline |
operator<<(bool arg) | ostream | inline |
operator<<(const char *arg) | ostream | inline |
operator<<(const signed char *arg) | ostream | inline |
operator<<(const unsigned char *arg) | ostream | inline |
operator<<(char arg) | ostream | inline |
operator<<(signed char arg) | ostream | inline |
operator<<(unsigned char arg) | ostream | inline |
operator<<(double arg) | ostream | inline |
operator<<(float arg) | ostream | inline |
operator<<(short arg) | ostream | inline |
operator<<(unsigned short arg) | ostream | inline |
operator<<(int arg) | ostream | inline |
operator<<(unsigned int arg) | ostream | inline |
operator<<(long arg) | ostream | inline |
operator<<(unsigned long arg) | ostream | inline |
operator<<(const void *arg) | ostream | inline |
operator<<(pgm arg) | ostream | inline |
operator<<(const __FlashStringHelper *arg) | ostream | inline |
ostream() (defined in ostream) | ostream | inline |
out | ios_base | static |
pos_type typedef | ios_base | |
precision() const | ios_base | inline |
precision(unsigned int n) | ios_base | inline |
put(char ch) | ostream | inline |
rdstate() const | ios | inline |
right | ios_base | static |
seekdir enum name | ios_base | |
seekp(pos_type pos) | ostream | inline |
seekp(off_type off, seekdir way) | ostream | inline |
setf(fmtflags fl) | ios_base | inline |
setf(fmtflags fl, fmtflags mask) | ios_base | inline |
setstate(iostate state) | ios | inline |
showbase | ios_base | static |
showpoint | ios_base | static |
showpos | ios_base | static |
skipws | ios_base | static |
streamsize typedef | ios_base | |
tellp() | ostream | inline |
trunc | ios_base | static |
unsetf(fmtflags fl) | ios_base | inline |
uppercase | ios_base | static |
width() | ios_base | inline |
width(unsigned n) | ios_base | inline |
+ SdFat
+
+ |
+
Output Stream. + More...
+ +#include <ostream.h>
+Public Types | |
typedef unsigned int | fmtflags |
typedef unsigned char | iostate |
typedef int32_t | off_type |
typedef uint8_t | openmode |
typedef uint32_t | pos_type |
enum | seekdir { beg, +cur, +end + } |
typedef uint32_t | streamsize |
+Public Member Functions | |
bool | bad () const |
void | clear (iostate state=goodbit) |
bool | eof () const |
bool | fail () const |
char | fill () |
char | fill (char c) |
fmtflags | flags () const |
fmtflags | flags (fmtflags fl) |
ostream & | flush () |
bool | good () const |
operator const void * () const | |
bool | operator! () const |
ostream & | operator<< (ostream &(*pf)(ostream &str)) |
ostream & | operator<< (ios_base &(*pf)(ios_base &str)) |
ostream & | operator<< (bool arg) |
ostream & | operator<< (const char *arg) |
ostream & | operator<< (const signed char *arg) |
ostream & | operator<< (const unsigned char *arg) |
ostream & | operator<< (char arg) |
ostream & | operator<< (signed char arg) |
ostream & | operator<< (unsigned char arg) |
ostream & | operator<< (double arg) |
ostream & | operator<< (float arg) |
ostream & | operator<< (short arg) |
ostream & | operator<< (unsigned short arg) |
ostream & | operator<< (int arg) |
ostream & | operator<< (unsigned int arg) |
ostream & | operator<< (long arg) |
ostream & | operator<< (unsigned long arg) |
ostream & | operator<< (const void *arg) |
ostream & | operator<< (pgm arg) |
ostream & | operator<< (const __FlashStringHelper *arg) |
int | precision () const |
int | precision (unsigned int n) |
ostream & | put (char ch) |
iostate | rdstate () const |
ostream & | seekp (pos_type pos) |
ostream & | seekp (off_type off, seekdir way) |
fmtflags | setf (fmtflags fl) |
fmtflags | setf (fmtflags fl, fmtflags mask) |
void | setstate (iostate state) |
pos_type | tellp () |
void | unsetf (fmtflags fl) |
unsigned | width () |
unsigned | width (unsigned n) |
+Static Public Attributes | |
static const fmtflags | adjustfield = left | right | internal |
static const openmode | app = 0X4 |
static const openmode | ate = 0X8 |
static const iostate | badbit = 0X01 |
static const fmtflags | basefield = dec | hex | oct |
static const openmode | binary = 0X10 |
static const fmtflags | boolalpha = 0x0100 |
static const fmtflags | dec = 0x0008 |
static const iostate | eofbit = 0x02 |
static const iostate | failbit = 0X04 |
static const iostate | goodbit = 0x00 |
static const fmtflags | hex = 0x0010 |
static const openmode | in = 0X20 |
static const fmtflags | internal = 0x0004 |
static const fmtflags | left = 0x0001 |
static const fmtflags | oct = 0x0020 |
static const openmode | out = 0X40 |
static const fmtflags | right = 0x0002 |
static const fmtflags | showbase = 0x0200 |
static const fmtflags | showpoint = 0x0400 |
static const fmtflags | showpos = 0x0800 |
static const fmtflags | skipws = 0x1000 |
static const openmode | trunc = 0X80 |
static const fmtflags | uppercase = 0x4000 |
+Protected Member Functions | |
uint8_t | flagsToBase () |
Output Stream.
+
+
|
+ +inherited | +
type for format flags
+ +
+
|
+ +inherited | +
typedef for iostate bitmask
+ +
+
|
+ +inherited | +
type for relative seek offset
+ +
+
|
+ +inherited | +
typedef for iostream open mode
+ +
+
|
+ +inherited | +
type for absolute seek position
+ +
+
|
+ +inherited | +
unsigned size that can represent maximum file size. (violates spec - should be signed)
+ +
+
|
+ +inherited | +
+
|
+ +inlineinherited | +
Clear iostate bits.
+[in] | state | The flags you want to set after clearing all flags. |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
Set fill character
[in] | c | new fill character |
+
|
+ +inlineinherited | +
set format flags
[in] | fl | new flag |
+
|
+ +inlineprotectedinherited | +
+
|
+ +inline | +
Flushes the buffer associated with this stream. The flush function calls the sync function of the associated file.
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
+
|
+ +inline | +
call manipulator
[in] | pf | function to call |
+
|
+ +inline | +
call manipulator
[in] | pf | function to call |
+
|
+ +inline | +
Output bool
[in] | arg | value to output |
+
|
+ +inline | +
Output string
[in] | arg | string to output |
+
|
+ +inline | +
Output string
[in] | arg | string to output |
+
|
+ +inline | +
Output string
[in] | arg | string to output |
+
|
+ +inline | +
Output character
[in] | arg | character to output |
+
|
+ +inline | +
Output character
[in] | arg | character to output |
+
|
+ +inline | +
Output character
[in] | arg | character to output |
+
|
+ +inline | +
Output double
[in] | arg | value to output |
+
|
+ +inline | +
Output float
[in] | arg | value to output |
+
|
+ +inline | +
Output signed short
[in] | arg | value to output |
+
|
+ +inline | +
Output unsigned short
[in] | arg | value to output |
+
|
+ +inline | +
Output signed int
[in] | arg | value to output |
+
|
+ +inline | +
Output unsigned int
[in] | arg | value to output |
+
|
+ +inline | +
Output signed long
[in] | arg | value to output |
+
|
+ +inline | +
Output unsigned long
[in] | arg | value to output |
+
|
+ +inline | +
Output pointer
[in] | arg | value to output |
Output a string from flash using the pstr() macro
[in] | arg | pgm struct pointing to string |
+
|
+ +inline | +
Output a string from flash using the Arduino F() macro.
[in] | arg | pointing to flash string |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set precision
[in] | n | new precision |
+
|
+ +inline | +
Puts a character in a stream.
+The unformatted output function inserts the element ch. It returns *this.
+[in] | ch | The character |
+
|
+ +inlineinherited | +
Set the stream position
[in] | pos | The absolute position in which to move the write pointer. |
set format flags
[in] | fl | new flags to be or'ed in |
+
|
+ +inlineinherited | +
modify format flags
[in] | mask | flags to be removed |
[in] | fl | flags to be set after mask bits have been cleared |
+
|
+ +inlineinherited | +
Set iostate bits.
+[in] | state | Bitts to set. |
+
|
+ +inline | +
+
|
+ +inlineinherited | +
clear format flags
[in] | fl | flags to be cleared |
+
|
+ +inlineinherited | +
+
|
+ +inlineinherited | +
set width
[in] | n | new width |
+
|
+ +staticinherited | +
mask for adjustfield
+ +
+
|
+ +staticinherited | +
seek to end before each write
+ +
+
|
+ +staticinherited | +
open and seek to end immediately after opening
+ +
+
|
+ +staticinherited | +
iostate bad bit for a nonrecoverable error.
+ +mask for basefield
+ +
+
|
+ +staticinherited | +
perform input and output in binary mode (as opposed to text mode)
+ +
+
|
+ +staticinherited | +
use strings true/false for bool
+ +
+
|
+ +staticinherited | +
base 10 flag
+ +
+
|
+ +staticinherited | +
iostate bit for end of file reached
+ +
+
|
+ +staticinherited | +
iostate fail bit for nonfatal error
+ +
+
|
+ +staticinherited | +
iostate for no flags
+ +
+
|
+ +staticinherited | +
base 16 flag
+ +
+
|
+ +staticinherited | +
open for input
+ +
+
|
+ +staticinherited | +
fill between sign/base prefix and number
+ +
+
|
+ +staticinherited | +
left adjust fields
+ +
+
|
+ +staticinherited | +
base 8 flag
+ +
+
|
+ +staticinherited | +
open for output
+ +
+
|
+ +staticinherited | +
right adjust fields
+ +
+
|
+ +staticinherited | +
use prefix 0X for hex and 0 for oct
+ +
+
|
+ +staticinherited | +
always show '.' for floating numbers
+ +
+
|
+ +staticinherited | +
show + sign for nonnegative numbers
+ +
+
|
+ +staticinherited | +
skip initial white space
+ +
+
|
+ +staticinherited | +
truncate an existing stream when opening
+ +
+
|
+ +staticinherited | +
use uppercase letters in number representations
+ +
+ SdFat
+
+ |
+
+Files | |
file | ArduinoStream.h |
ArduinoInStream and ArduinoOutStream classes. | |
file | bufstream.h |
ibufstream and obufstream classes | |
file | ios.h |
ios_base and ios classes | |
file | iostream.h |
iostream class | |
file | istream.cpp |
file | istream.h |
istream class | |
file | MinimumSerial.cpp |
file | MinimumSerial.h |
file | ostream.cpp |
file | ostream.h |
ostream class | |
file | Sd2Card.cpp |
file | Sd2Card.h |
Sd2Card class for V2 SD/SDHC cards. | |
file | SdBaseFile.cpp |
file | SdBaseFile.h |
SdBaseFile class. | |
file | SdBaseFilePrint.cpp |
file | SdFat.cpp |
file | SdFat.h |
SdFat class. | |
file | SdFatConfig.h |
configuration definitions | |
file | SdFatErrorPrint.cpp |
file | SdFatmainpage.h |
file | SdFatUtil.cpp |
file | SdFatUtil.h |
Useful utility functions. | |
file | SdFile.cpp |
file | SdFile.h |
SdFile class. | |
file | SdSpi.h |
SdSpi class for V2 SD/SDHC cards. | |
file | SdSpiArduino.cpp |
file | SdSpiAVR.cpp |
file | SdSpiSAM3X.cpp |
file | SdSpiSoft.cpp |
file | SdSpiTeensy3.cpp |
file | SdStream.cpp |
file | SdStream.h |
fstream, ifstream, and ofstream classes | |
file | SdVolume.cpp |
file | SdVolume.h |
SdVolume class. | |
file | StdioStream.cpp |
file | StdioStream.h |
StdioStream class. | |
+ SdFat
+
+ |
+
+ SdFat
+
+ |
+
+ SdFat
+
+ |
+
▼ Arduino | |
▼ libraries | |
▼ SdFat | |
ArduinoStream.h | ArduinoInStream and ArduinoOutStream classes |
bufstream.h | ibufstream and obufstream classes |
ios.h | ios_base and ios classes |
iostream.h | iostream class |
istream.h | istream class |
ostream.h | ostream class |
Sd2Card.h | Sd2Card class for V2 SD/SDHC cards |
SdBaseFile.h | SdBaseFile class |
SdFat.h | SdFat class |
SdFatConfig.h | Configuration definitions |
SdFatUtil.h | Useful utility functions |
SdFile.h | SdFile class |
SdSpi.h | SdSpi class for V2 SD/SDHC cards |
SdStream.h | fstream, ifstream, and ofstream classes |
SdVolume.h | SdVolume class |
StdioStream.h | StdioStream class |
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
- SdFat
+ SdFat
+
|
+ SdFat
+
+ |
+
+ SdFat
+
+ |
+
This page explains how to interpret the graphs that are generated by doxygen.
+Consider the following example:
This will result in the following graph:
+The boxes in the above graph have the following meaning:
+The arrows have the following meaning:
+
+ SdFat
+
+ |
+
Ccache_t | Cache for an SD data block |
CFatPos_t | Internal type for istream do not use in user apps |
▼Cios_base | Base class for all streams |
▼Cios | Error and state information for all streams |
▼Cistream | Input Stream |
▼Cibufstream | Parse a char string |
CArduinoInStream | Input stream for Arduino Stream objects |
Cifstream | SD file input stream |
▼Ciostream | Input/Output stream |
Cfstream | SD file input/output stream |
▼Costream | Output Stream |
CArduinoOutStream | Output stream for Arduino Print objects |
Ciostream | Input/Output stream |
Cobufstream | Format a char string |
Cofstream | SD card output stream |
▼CSdStreamBase | Base class for SD streams |
Cfstream | SD file input/output stream |
Cifstream | SD file input stream |
Cofstream | SD card output stream |
Cpgm | Type for string in flash |
▼CPrint | |
CMinimumSerial | Mini serial class for the SdFat library |
CSdFile | SdBaseFile with Arduino Stream |
CSd2Card | Raw access to SD and SDHC flash memory cards |
▼CSdBaseFile | Base class for SdFile with Print and C++ streams |
CFile | Arduino SD.h style File API |
CSdFile | SdBaseFile with Arduino Stream |
CSdStreamBase | Base class for SD streams |
CStdioStream | StdioStream implements a minimal stdio stream |
CSdFat | Integration class for the SdFat library |
CSdSpi | SPI class for access to SD and SDHC flash memory cards |
CSdVolume | Access FAT16 and FAT32 volumes on SD and SDHC cards |
Csetfill | Type for setfill manipulator |
Csetprecision | Type for setprecision manipulator |
Csetw | Type for setw manipulator |
▼CStream | |
CFile | Arduino SD.h style File API |
+ SdFat
+
+ |
+
The Arduino SdFat Library is a minimal implementation of FAT16 and FAT32 file systems on SD flash memory cards. Standard SD and high capacity SDHC cards are supported.
+Experimental support for FAT12 can be enabled by setting FAT12_SUPPORT nonzero in SdFatConfig.h.
+The SdFat library only supports short 8.3 names.
+The main classes in SdFat are SdFat, SdBaseFile, SdFile, File, StdioStream, fstream, ifstream, and ofstream.
+The SdFat class maintains a FAT volume, a current working directory, and simplifies initialization of other classes.
+The SdBaseFile class provides basic file access functions such as open(), binary read(), binary write(), close(), remove(), and sync(). SdBaseFile is the smallest file class.
+The SdFile class has all the SdBaseFile class functions plus the Arduino Print class functions.
+The File class has all the SdBaseFile functions plus the functions in the Arduino SD.h File class. This provides compatibility with the Arduino SD.h library.
+The StdioStream class implements functions similar to Linux/Unix standard buffered input/output.
+The fstream class implements C++ iostreams for both reading and writing text files.
+The ifstream class implements C++ iostreams for reading text files.
+The ofstream class implements C++ iostreams for writing text files.
+The classes ibufstream and obufstream format and parse character strings in memory buffers.
+the classes ArduinoInStream and ArduinoOutStream provide iostream functions for Serial, LiquidCrystal, and other devices.
+A number of example are provided in the SdFat/examples folder. These were developed to test SdFat and illustrate its use.
+You must manually install SdFat by copying the SdFat folder from the download package to the Arduino libraries folder in you sketch book.
+See the Manual installation section of this guide.
+http://arduino.cc/en/Guide/Libraries
+Several configuration options may be changed by editing the SdFatConfig.h file in the SdFat folder.
+Set SD_FILE_USES_STREAM nonzero to use Stream instead of Print for SdFile. Using Stream will use more flash.
+To enable SD card CRC checking set USE_SD_CRC nonzero.
+To use multiple SD cards set USE_MULTIPLE_CARDS nonzero.
+Set FAT12_SUPPORT nonzero to enable use of FAT12 volumes. FAT12 has not been well tested and requires additional flash.
+Set USE_ARDUINO_SPI_LIBRARY nonzero to force use of Arduino Standard SPI library. This will override native and software SPI for all boards.
+Use of software SPI can be enabled for selected boards by setting the symbols AVR_SOFT_SPI, DUE_SOFT_SPI, LEONARDO_SOFT_SPI, MEGA_SOFT_SPI, and TEENSY3_SOFT_SPI.
+Set ENABLE_SPI_TRANSACTION nonzero to enable the SPI transaction feature of the standard Arduino SPI library. You must include SPI.h in your sketches when ENABLE_SPI_TRANSACTION is nonzero.
+Set ENABLE_SPI_YIELD nonzero to enable release of the SPI bus during SD card busy waits.
+Arduinos access SD cards using the cards SPI protocol. PCs, Macs, and most consumer devices use the 4-bit parallel SD protocol. A card that functions well on A PC or Mac may not work well on the Arduino.
+Most cards have good SPI read performance but cards vary widely in SPI write performance. Write performance is limited by how efficiently the card manages internal erase/remapping operations. The Arduino cannot optimize writes to reduce erase operations because of its limit RAM.
+SanDisk cards generally have good write performance. They seem to have more internal RAM buffering than other cards and therefore can limit the number of flash erase operations that the Arduino forces due to its limited RAM.
+SdFat was developed using an Adafruit Industries Data Logging Shield.
+The hardware interface to the SD card should not use a resistor based level shifter. SdFat sets the SPI bus frequency to 8 MHz which results in signal rise times that are too slow for the edge detectors in many newer SD card controllers when resistor voltage dividers are used.
+The 5 to 3.3 V level shifter for 5 V Arduinos should be IC based like the 74HC4050N based circuit shown in the file SdLevel.png. The Adafruit Wave Shield uses a 74AHC125N. Gravitech sells SD and MicroSD Card Adapters based on the 74LCX245.
+If you are using a resistor based level shifter and are having problems try setting the SPI bus frequency to 4 MHz. This can be done by using card.init(SPI_HALF_SPEED) to initialize the SD card.
+If you wish to report bugs or have comments, send email to fat16. lib@ sbcgl obal .net
+SdFat uses a slightly restricted form of short names. Short names are limited to 8 characters followed by an optional period (.) and extension of up to 3 characters. The characters may be any combination of letters and digits. The following special characters are also allowed:
+$ % ' - _ @ ~ ` ! ( ) { } ^ # &
+Short names are always converted to upper case and their original case value is lost.
+An application which writes to a file using print(), println() or write() must call sync() at the appropriate time to force data and directory information to be written to the SD Card. Data and directory information are also written to the SD card when close() is called.
+Applications must use care calling sync() since 2048 bytes of I/O is required to update file and directory information. This includes writing the current data block, reading the block that contains the directory entry for update, writing the directory block back and reading back the current data block.
+It is possible to open a file with two or more instances of a file object. A file may be corrupted if data is written to the file by more than one instance of a file object.
+The best way to restore an SD card's format on a PC or Mac is to use SDFormatter which can be downloaded from:
+http://www.sdcard.org/downloads
+A formatter sketch, SdFormatter.ino, is included in the SdFat/examples/SdFormatter directory. This sketch attempts to emulate SD Association's SDFormatter.
+SDFormatter aligns flash erase boundaries with file system structures which reduces write latency and file system overhead.
+The PC/Mac SDFormatter does not have an option for FAT type so it may format very small cards as FAT12. Use the SdFat formatter to force FAT16 formatting of small cards.
+Do not format the SD card with an OS utility, OS utilities do not format SD cards in conformance with the SD standard.
+You should use a freshly formatted SD card for best performance. FAT file systems become slower if many files have been created and deleted. This is because the directory entry for a deleted file is marked as deleted, but is not deleted. When a new file is created, these entries must be scanned before creating the file. Also files can become fragmented which causes reads and writes to be slower.
+A number of examples are provided in the SdFat/examples folder. See the html documentation for a list.
+To access these examples from the Arduino development environment go to: File -> Examples -> SdFat -> <Sketch Name>
+Compile, upload to your Arduino and click on Serial Monitor to run the example.
+Here is a list:
+AnalogBinLogger - Fast AVR ADC logger - see the AnalogBinLoggerExtras folder.
+bench - A read/write benchmark.
+cin_cout - Demo of ArduinoInStream and ArduinoOutStream.
+dataLogger - A simple modifiable data logger.
+directoryFunctions - Demo of chdir(), ls(), mkdir(), and rmdir().
+fgets - Demo of the fgets read line/string function.
+formating - Print a table with various formatting options.
+getline - Example of getline from section 27.7.1.3 of the C++ standard.
+LowLatencyLogger - A modifiable data logger for higher data rates.
+OpenNext - Open all files in the root dir and print their filename.
+PrintBenchmark - A simple benchmark for printing to a text file.
+QuickStart - A sketch to quickly test your SD card and SD shield/module.
+RawWrite - A test of raw write functions for contiguous files.
+readCSV - Read a comma-separated value file using iostream extractors.
+ReadWriteSdFat - SdFat version of Arduino SD ReadWrite example.
+rename - A demo of SdFat::rename(old, new) and SdFile::rename(dirFile, newPath).
+SdFormatter - This sketch will format an SD or SDHC card.
+SdInfo - Initialize an SD card and analyze its structure for trouble shooting.
+StdioBench - Demo and test of stdio style stream.
+StreamParseInt - Simple demo of parseInt() Stream member function.
+StressTest - Create and write files until the SD is full.
+Timestamp - Sets file create, modify, and access timestamps.
+TwoCards - Example using two SD cards.
+
+ SdFat
+
+ |
+
+ + |
+ + |
+ + |
+ + |
+ + |
+ + |
+ + |
+ + |
+ + |
+ + |
+ + |
+ SdFat
+
+ |
+
ios_base and ios classes +More...
+#include <SdBaseFile.h>
+Classes | |
class | ios |
Error and state information for all streams. More... | |
class | ios_base |
Base class for all streams. More... | |
+Functions | |
ios_base & | boolalpha (ios_base &str) |
ios_base & | dec (ios_base &str) |
ios_base & | hex (ios_base &str) |
ios_base & | internal (ios_base &str) |
ios_base & | left (ios_base &str) |
ios_base & | noboolalpha (ios_base &str) |
ios_base & | noshowbase (ios_base &str) |
ios_base & | noshowpoint (ios_base &str) |
ios_base & | noshowpos (ios_base &str) |
ios_base & | noskipws (ios_base &str) |
ios_base & | nouppercase (ios_base &str) |
ios_base & | oct (ios_base &str) |
ios_base & | right (ios_base &str) |
ios_base & | showbase (ios_base &str) |
ios_base & | showpoint (ios_base &str) |
ios_base & | showpos (ios_base &str) |
ios_base & | skipws (ios_base &str) |
ios_base & | uppercase (ios_base &str) |
function for boolalpha manipulator
[in] | str | The stream |
function for dec manipulator
[in] | str | The stream |
function for hex manipulator
[in] | str | The stream |
function for internal manipulator
[in] | str | The stream |
function for left manipulator
[in] | str | The stream |
function for noboolalpha manipulator
[in] | str | The stream |
function for noshowbase manipulator
[in] | str | The stream |
function for noshowpoint manipulator
[in] | str | The stream |
function for noshowpos manipulator
[in] | str | The stream |
function for noskipws manipulator
[in] | str | The stream |
function for nouppercase manipulator
[in] | str | The stream |
function for oct manipulator
[in] | str | The stream |
function for right manipulator
[in] | str | The stream |
function for showbase manipulator
[in] | str | The stream |
function for showpoint manipulator
[in] | str | The stream |
function for showpos manipulator
[in] | str | The stream |
function for skipws manipulator
[in] | str | The stream |
+ SdFat
+
+ |
+
+Classes | |
class | iostream |
Input/Output stream. More... | |
struct | setfill |
type for setfill manipulator More... | |
struct | setprecision |
type for setprecision manipulator More... | |
struct | setw |
type for setw manipulator More... | |
+Functions | |
ostream & | endl (ostream &os) |
ostream & | flush (ostream &os) |
ostream & | operator<< (ostream &os, const setfill &arg) |
ostream & | operator<< (ostream &os, const setprecision &arg) |
ostream & | operator<< (ostream &os, const setw &arg) |
istream & | operator>> (istream &obj, const setfill &arg) |
istream & | operator>> (istream &is, const setprecision &arg) |
istream & | operator>> (istream &is, const setw &arg) |
istream & | ws (istream &is) |
iostream class
+insert endline
[in] | os | The Stream |
flush manipulator
[in] | os | The stream |
+
|
+ +inline | +
setfill manipulator
[in] | os | the stream |
[in] | arg | set setfill object |
+
|
+ +inline | +
setprecision manipulator
[in] | os | the stream |
[in] | arg | set setprecision object |
+
|
+ +inline | +
setw manipulator
[in] | os | the stream |
[in] | arg | set setw object |
+
|
+ +inline | +
setfill manipulator
[in] | obj | the stream |
[in] | arg | set setfill object |
+
|
+ +inline | +
setprecision manipulator
[in] | is | the stream |
[in] | arg | set setprecision object |
+
|
+ +inline | +
setw manipulator
[in] | is | the stream |
[in] | arg | set setw object |
+ SdFat
+
+ |
+
#include <ios.h>
+Classes | |
class | istream |
Input Stream. More... | |
istream class
+t |
+ SdFat
+
+ |
+
#include <ios.h>
+Classes | |
class | ostream |
Output Stream. More... | |
struct | pgm |
type for string in flash More... | |
+Macros | |
#define | pstr(str) pgm(PSTR(str)) |
ostream class
+
+ SdFat
+
+ |
+
This is the complete list of members for FatPos_t, including all inherited members.
+cluster | FatPos_t | |
FatPos_t() (defined in FatPos_t) | FatPos_t | inline |
position | FatPos_t |
+ SdFat
+
+ |
+
internal type for istream do not use in user apps + More...
+ +#include <SdBaseFile.h>
+Public Attributes | |
uint32_t | cluster |
uint32_t | position |
internal type for istream do not use in user apps
+uint32_t FatPos_t::cluster | +
cluster for position
+ +uint32_t FatPos_t::position | +
stream position
+ +
+ SdFat
+
+ |
+
This is the complete list of members for pgm, including all inherited members.
+pgm(char *str) | pgm | inlineexplicit |
pgm(const char *str) | pgm | inlineexplicit |
ptr | pgm |
+ SdFat
+
+ |
+
type for string in flash + More...
+ +#include <ostream.h>
+Public Member Functions | |
pgm (char *str) | |
pgm (const char *str) | |
+Public Attributes | |
char * | ptr |
type for string in flash
+
+
|
+ +inlineexplicit | +
constructor
[in] | str | initializer for pointer. |
+
|
+ +inlineexplicit | +
constructor
[in] | str | initializer for pointer. |
char* pgm::ptr | +
Pointer to flash string
+ +
+ SdFat
+
+ |
+
This is the complete list of members for setfill, including all inherited members.
+c | setfill | |
setfill(char arg) | setfill | inlineexplicit |
+ SdFat
+
+ |
+
type for setfill manipulator + More...
+ +#include <iostream.h>
+Public Member Functions | |
setfill (char arg) | |
+Public Attributes | |
char | c |
type for setfill manipulator
+
+
|
+ +inlineexplicit | +
constructor
+[in] | arg | new fill character |
char setfill::c | +
fill character
+ +
+ SdFat
+
+ |
+
This is the complete list of members for setprecision, including all inherited members.
+p | setprecision | |
setprecision(unsigned int arg) | setprecision | inlineexplicit |
+ SdFat
+
+ |
+
type for setprecision manipulator + More...
+ +#include <iostream.h>
+Public Member Functions | |
setprecision (unsigned int arg) | |
+Public Attributes | |
unsigned int | p |
type for setprecision manipulator
+
+
|
+ +inlineexplicit | +
constructor
[in] | arg | new precision |
unsigned int setprecision::p | +
precision
+ +
+ SdFat
+
+ |
+
This is the complete list of members for setw, including all inherited members.
+setw(unsigned arg) | setw | inlineexplicit |
w | setw |
+ SdFat
+
+ |
+
type for setw manipulator + More...
+ +#include <iostream.h>
+Public Member Functions | |
setw (unsigned arg) | |
+Public Attributes | |
unsigned | w |
type for setw manipulator
+
+
|
+ +inlineexplicit | +
constructor
[in] | arg | new width |
unsigned setw::w | +
width
+ +
+ SdFat
+
+ |
+
This is the complete list of members for cache_t, including all inherited members.
+data | cache_t | |
dir | cache_t | |
fat16 | cache_t | |
fat32 | cache_t | |
fbs | cache_t | |
fbs32 | cache_t | |
fsinfo | cache_t | |
mbr | cache_t |
+ SdFat
+
+ |
+
Cache for an SD data block. + More...
+ +#include <SdVolume.h>
+Public Attributes | |
uint8_t | data [512] |
dir_t | dir [16] |
uint16_t | fat16 [256] |
uint32_t | fat32 [128] |
fat_boot_t | fbs |
fat32_boot_t | fbs32 |
fat32_fsinfo_t | fsinfo |
mbr_t | mbr |
Cache for an SD data block.
+uint8_t cache_t::data[512] | +
Used to access cached file data blocks.
+ +dir_t cache_t::dir[16] | +
Used to access cached directory entries.
+ +uint16_t cache_t::fat16[256] | +
Used to access cached FAT16 entries.
+ +uint32_t cache_t::fat32[128] | +
Used to access cached FAT32 entries.
+ +fat_boot_t cache_t::fbs | +
Used to access to a cached FAT boot sector.
+ +fat32_boot_t cache_t::fbs32 | +
Used to access to a cached FAT32 boot sector.
+ +fat32_fsinfo_t cache_t::fsinfo | +
Used to access to a cached FAT32 FSINFO sector.
+ +mbr_t cache_t::mbr | +
Used to access a cached Master Boot Record.
+ +