51#include "spiffs_config.h" 
   57#define SPIFFS_DIR_SIZE (12) 
   59#if (VFS_DIR_BUFFER_SIZE < SPIFFS_DIR_SIZE) 
   60#error "VFS_DIR_BUFFER_SIZE too small" 
   67#ifndef SPIFFS_FS_CACHE_SIZE 
   68#if SPIFFS_CACHE || defined(DOXYGEN) 
   76#define SPIFFS_FS_CACHE_SIZE (512) 
   78#define SPIFFS_FS_CACHE_SIZE (0) 
   81#ifndef SPIFFS_FS_WORK_SIZE 
   89#define SPIFFS_FS_WORK_SIZE  (512) 
   91#ifndef SPIFFS_FS_FD_SPACE_SIZE 
   98#define SPIFFS_FS_FD_SPACE_SIZE (4 * 32) 
  109#if (SPIFFS_CACHE == 1) || defined(DOXYGEN) 
  115#if (SPIFFS_HAL_CALLBACK_EXTRA == 1) || defined(DOXYGEN) 
  118#if (SPIFFS_SINGLETON == 0) || defined(DOXYGEN) 
 
#define SPIFFS_FS_WORK_SIZE
The size of the work buffer.
void spiffs_lock(struct spiffs_t *fs)
SPIFFS lock function.
struct spiffs_desc spiffs_desc_t
This contains everything needed to run an instance of SPIFFS.
void spiffs_unlock(struct spiffs_t *fs)
SPIFFS unlock function.
#define SPIFFS_FS_FD_SPACE_SIZE
the size of the file descriptor buffer
const vfs_file_system_t spiffs_file_system
The SPIFFS vfs driver, a pointer to a spiffs_desc_t must be provided as vfs_mountp::private_data.
#define SPIFFS_FS_CACHE_SIZE
the size of the cache buffer
Mutex for thread synchronization.
This contains everything needed to run an instance of SPIFFS.
mutex_t lock
A lock for SPIFFS internal use.
spiffs_config config
SPIFFS config, filled at mount time depending on the underlying mtdi_dev_t dev.
uint8_t work[SPIFFS_FS_WORK_SIZE]
SPIFFS work buffer.
uint32_t block_count
Number of blocks in current partition, if 0, the mtd number of sector is used.
uint8_t cache[SPIFFS_FS_CACHE_SIZE]
SPIFFS cache.
mtd_dev_t * dev
The underlying mtd device, must be set by user.
spiffs fs
The SPIFFS struct.
uint32_t base_addr
Base address of partition.
uint8_t fd_space[SPIFFS_FS_FD_SPACE_SIZE]
SPIFFS file descriptor cache.