Files
fluxengine/lib/layout.proto
David Given 0c40a3e79c File system mapping now sort of works in the filesystem, but there are
problems. These are potentially due to an incorrect Prodos mapping but I'm not
sure.
2022-09-11 19:01:25 +02:00

53 lines
1.5 KiB
Protocol Buffer

syntax = "proto2";
import "lib/common.proto";
message SectorListProto
{
/* either */
repeated int32 sector = 1 [ (help) = "sector ID" ];
/* or */
optional int32 start_sector = 2
[ (help) = "first sector of a continuous run" ];
optional int32 count = 3
[ (help) = "number of sectors in a continuous run" ];
}
message LayoutProto
{
enum Order
{
UNDEFINED = 0;
CHS = 1;
HCS = 2;
}
message LayoutdataProto
{
optional int32 track = 1
[ (help) = "if present, this format only applies to this track" ];
optional int32 up_to_track = 5
[ (help) = "if present, forms a range with track" ];
optional int32 side = 2
[ (help) = "if present, this format only applies to this side" ];
optional int32 sector_size = 3
[ default = 512, (help) = "number of bytes per sector" ];
optional SectorListProto physical = 4
[ (help) = "physical order of sectors on disk" ];
optional SectorListProto filesystem = 6
[ (help) = "logical order of sectors in filesystem" ];
}
repeated LayoutdataProto layoutdata = 1
[ (help) = "per-track layout information (repeatable)" ];
optional int32 tracks = 2
[ default = 0, (help) = "number of tracks in image" ];
optional int32 sides = 3
[ default = 0, (help) = "number of sides in image" ];
optional Order order = 4
[ default = CHS, (help) = "the order of sectors in the filesystem" ];
}