====================================================================================================
SlotFS Specification
====================================================================================================

-----------------------------------------------------
Primary descriptor : always located at card sector #0
-----------------------------------------------------

UInt8 [ 16] magicNumber   - always { 0xA1, 0x3B, 0x3D, 0xFC, 0x64, 0x71, 0x5E, 0x8B,
                                     0xAE, 0x28, 0x9E, 0x9F, 0x75, 0xF2, 0x96, 0x50
                                   }
                          - generated using https://www.webtools.services/uuid-generator with these
                            settings:
                                UUID version : V5 (name-based, SHA1)
                                Namespace    : OID
                                Name         : "eCxx SlotFS"
Char  [ 34] magicString   - always "eCxx SlotFS File System Descriptor" (without a null terminator)
UInt16      fsVersion     - currently always 0x0001
UInt8 [ 12] reserved1     - currently always { 0x00, ... }

UInt16      sectorSize    - currently always 512
UInt32      sectorCount   - the number of sectors available in the memory card
                          - hence, the maximum supported memory card size is 2 TiB
UInt16      slotSize      - slot size in a multiple of 4 MiB
                          - valid values are 1, 2, 4, 8, 16, 32, 64, 128, 256, 512
                          - hence, the maximum supported slot size is 2048 MiB
UInt16      slotCount     - the number of slots available for use in the memory card
                                - a 128 MiB memory card will have at least    1 slots at size  32
                                - a 128 MiB memory card will have at most    32 slots at size   1
                                - a   8 GiB memory card will have at least    4 slots at size 512
                                - a   8 GiB memory card will have at most  2048 slots at size   1
                                - a   2 TiB memory card will have at least 1024 slots at size 512
                                - a   2 TiB memory card will have at most  4096 slots at size 128
                            in reality, because memory card is measured by MB, GB, and TB, the
                            actual number of slots will be less than above
UInt16      slotDescStart - starting sector number for slot descriptors
                          - currently always 0x0001
UInt16      slotDataStart - starting sector number for slot data
                          - currently always 0x2000 (8192)
UInt8 [ 50] reserved2     - currently always { 0x00, ... }

Char  [128] userDesc      - 128-byte user string (without a null terminator)
UInt8 [256] reserved3     - currently always { 0x00, ... }

-------------------------------------------------------------------------------------------------
Slot descriptor : located at card sector #slotDescStart to CEIL(#slotDescStart + #slotCount - 1)
-------------------------------------------------------------------------------------------------
UInt8     slotType  - 0 = empty ; 1 = occupied
UInt8[ 3] reserved1 - currently always { 0x00, ... }
UInt32    dataSize  - actual size of stored user data in bytes
Char [ 8] userID    -  8-byte user string (without a null terminator)
Char [48] userDesc  - 48-byte user string (without a null terminator)
UInt8[64] reserved2 - currently always { 0x00, ... }

Maximum number of available sectors for slot descriptors = slotDataStart - slotDescStart =  8191

---------------------------------------------------------------
Slot data : located at card sector starting from #slotDataStart
---------------------------------------------------------------
<<< user data ; each slot is (slotSize * 4) MiB >>>

====================================================================================================

SlotFS use little-endian byte ordering for multi-byte integers.

Maximum actual data size for linked slots is 3968 MiB.

====================================================================================================
