Skip to content

LittleFS platform

«interface»SolidSyslogFileLittleFsFileLittleFs

File SolidSyslogLittleFsFile.h

FileList > Interface > SolidSyslogLittleFsFile.h

  • #include <stdint.h>
  • #include "SolidSyslogExternC.h"

Detailed Description

LittleFS file I/O behind the_ SolidSyslogFile _vtable, for a file-backed BlockDevice or Store.

lfs_file_sync runs after every complete write so a power loss never loses a record the BlockStore already claimed it stored. The integrator mounts the filesystem and keeps ownership of it.

Public Functions Documentation

SolidSyslogLittleFsFile_Create

Create a file on an already-mounted LittleFS.

struct SolidSyslogFile * SolidSyslogLittleFsFile_Create (
    struct lfs * filesystem,
    void * fileBuffer,
    uint32_t fileBufferBytes
) 

Parameters:

  • filesystem a mounted lfs_t, which must outlive this file.
  • fileBuffer storage LittleFS uses to cache this file, which must outlive it. It is the file's cache, not a copy of one.
  • fileBufferBytes its size, which must be at least the mounted filesystem's cache_size.

SolidSyslogLittleFsFile_Destroy

Release the pool slot, closing the file first.

void SolidSyslogLittleFsFile_Destroy (
    struct SolidSyslogFile * base
) 

The buffer is yours again once this returns.



The documentation for this class was generated from the following file Platform/LittleFs/Interface/SolidSyslogLittleFsFile.h