Module binfmt

Source
Expand description

Parser for the .rcx binary format

Referenced from: https://github.com/BrickBot/nqc/blob/master/rcxlib/RCX_Image.cpp

* signature - 4 bytes
* version - 2 bytes
* chunks_count - 2 bytes
* symbol_count - 2 bytes
* target_type - 1 byte
* reserved - 1 byte
* for each chunk:
  - type - 1 byte (type <= 2)
  - number - 1 byte
  - length - 2 bytes
  - data - <length> bytes, padded to u32 alignment
 * for each symbol:
  - type - 1 byte
  - index - 1 byte
  - length - 1 byte
  - name - <length> bytes cstr

Structs§

RcxBin
Section
Symbol

Enums§

SectionType
SymbolType
TargetType