Expand description
LTC (Linear Timecode) bit-level parser.
Parses the raw 80-bit LTC word into a LtcFrame containing a decoded
Timecode. The parser operates on a slice of LtcBit values
(i.e. clock-qualified biphase-mark decoded bits) and locates the sync
word, then reconstructs the timecode fields.
§SMPTE 12M LTC word layout (80 bits, LSB first per group)
- Bits 0-3: frame units
- Bit 4: user bit 1
- Bit 5: user bit 2 (actually these are user bit nibbles interleaved)
- Bits 4,6,10,12,18,20,26,28: user-bit nibble pairs
- Bits 8-9: frame tens + drop-frame flag (bit 10) + color-frame (bit 11)
- Bits 16-19: seconds units
- Bits 24-26: seconds tens
- Bits 32-35: minutes units
- Bits 40-42: minutes tens
- Bits 48-51: hours units
- Bits 56-57: hours tens
- Bits 64-79: sync word 0xBFFC (0011111111111101 in LS→MS order)
Structs§
Enums§
- LtcBit
- A single logical bit in an LTC data stream after biphase-mark decoding.
Functions§
- build_
ltc_ word - Helper: build an 80-bit LTC word from raw field values (for test construction).