Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The tree roots are stored in the first page of first bank, except internal slot : bank $21 (R21_BNK). They define the devices : :RAM.0, :RAM.- and :EPR. 0-3. Tree root of :RAM.1 is in bank $40, :RAM.2 in $80 and :RAM.3 in $C0.

...

The file pointer points to the first sector. A sector is 62+2 bytes length. Two bytes for the link to the next followed by 62 bytes of data. When the sector is the last one, the first byte is zero followed by the sector length. Each page allocated to the file system holds up to 4 sectors (or 1 DOR and 3 sectors...).

RAM device

Each RAM device is tagged at address CR_TAG ($0000) with CT_RAM ($A55A) followed by the size in banks (1 byte).

The RAM device DOR is by by default at $0040.

For information, the first page of :RAM.0 contains other root DORs (RAM.- at $210020 and APPL at $210060).

In the root DOR, the father LSB represent the mounting status : 0 unmounted and -1 if mounted. RAM device are always mounted and cannot be unmounted.

The brother is always zero and the son points to the File DOR described below.

Notice that this rule applies for :EPR.x and :SDC.0 root devices located in low RAM.

File DOR

The file DOR length is up to 64 bytes. Its layout is fixed and should respect the specified order. It contains father, brother and son followed by file informations consisting of a key, data length, data.

Offset
Length
Name
Value
Description
$00
3


pointer to father
$03
3


pointer to brother
$06
3


pointer to son
$09
1
DN_

DOR minor type (DN_Fil, DN_Dir, DN_Epr)
$0A
1

$3F
file DOR length
$0B
1
DT_NAM
'N'
name section descriptor
$0C
1

$11
filename length, fixed value
$0D
17


filename null terminated, cell filled with trailing zero. Includes dot and extension.

filename of 1 to 12 characters, a dot, 3 characters extension, a null terminator.
$1E
1
DT_UPD
'U'
update timestamp section descriptor
$1F
1

$06
update time length, fixed value
$20
6


date and time of update in machine format
$26
1
DT_CRE
'C'
creation timestamp section descriptor
$27
1

$06
creation time length, fixed value
$28
6


date and time of creation in machine format
$2E
1
DT_EXT
'X'
extent (size)
$2F
1

$04
extent length, fixed value
$30
4


32 bit value of filesize
$34
1
DT_EFS
'E'
section descriptor
$35
1

$04
section length, fixed value
$36
4


32 bit pointer to eprom file entry
$3A
1
DT_ATR
'A'
section descriptor
$3B
1

$03
section length, fixed value
$3C
3


24 bit for file attribute flags

system flag (protecting shell commands) is bit 23, others are reserved

...