SdBaseFile class.
More...
#include <Arduino.h>
#include <SdFatConfig.h>
#include <SdVolume.h>
Detailed Description
Define Documentation
#define PGM_P const char* |
#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
store literal string in flash for ARM
Function Documentation
static uint16_t FAT_DATE |
( |
uint16_t |
year, |
|
|
uint8_t |
month, |
|
|
uint8_t |
day |
|
) |
| [inline, static] |
date field for FAT directory entry
- Parameters:
-
[in] | year | [1980,2107] |
[in] | month | [1,12] |
[in] | day | [1,31] |
- Returns:
- Packed date for dir_t entry.
static uint8_t FAT_DAY |
( |
uint16_t |
fatDate | ) |
[inline, static] |
day part of FAT directory date field
- Parameters:
-
[in] | fatDate | Date in packed dir format. |
- Returns:
- Extracted day [1,31]
static uint8_t FAT_HOUR |
( |
uint16_t |
fatTime | ) |
[inline, static] |
hour part of FAT directory time field
- Parameters:
-
[in] | fatTime | Time in packed dir format. |
- Returns:
- Extracted hour [0,23]
static uint8_t FAT_MINUTE |
( |
uint16_t |
fatTime | ) |
[inline, static] |
minute part of FAT directory time field
- Parameters:
-
[in] | fatTime | Time in packed dir format. |
- Returns:
- Extracted minute [0,59]
static uint8_t FAT_MONTH |
( |
uint16_t |
fatDate | ) |
[inline, static] |
month part of FAT directory date field
- Parameters:
-
[in] | fatDate | Date in packed dir format. |
- Returns:
- Extracted month [1,12]
static uint8_t FAT_SECOND |
( |
uint16_t |
fatTime | ) |
[inline, static] |
second part of FAT directory time field Note second/2 is stored in packed time.
- Parameters:
-
[in] | fatTime | Time in packed dir format. |
- Returns:
- Extracted second [0,58]
static uint16_t FAT_TIME |
( |
uint8_t |
hour, |
|
|
uint8_t |
minute, |
|
|
uint8_t |
second |
|
) |
| [inline, static] |
time field for FAT directory entry
- Parameters:
-
[in] | hour | [0,23] |
[in] | minute | [0,59] |
[in] | second | [0,59] |
- Returns:
- Packed time for dir_t entry.
static uint16_t FAT_YEAR |
( |
uint16_t |
fatDate | ) |
[inline, static] |
year part of FAT directory date field
- Parameters:
-
[in] | fatDate | Date in packed dir format. |
- Returns:
- Extracted year [1980,2107]
Variable Documentation
Default date for file timestamps is 1 Jan 2000
Default time for file timestamp is 1 am
This file has not been opened.
Test value for directory type
A FAT12 or FAT16 root directory
ls() flag to print modify date
ls() flag for recursive list of subdirectories
ls() flag to print file size
open() oflag mask for access modes
The file offset shall be set to the end of the file prior to each write.
set the initial position at the end of the file
create the file if nonexistent
If O_CREAT and O_EXCL are set, open() shall fail if the file exists
open() oflag - same as O_IN
open() oflag for reading and writing
synchronous writes - call sync() after each write
truncate the file to zero length
open() oflag - same as O_WRITE
set the file's last access date
set the file's creation date and time
Set the file's write date and time