namespace SabreTools.Data.Models.Atari7800 { /// /// Atari 7800 emulator header /// /// public class Header { /// /// Header version /// /// /// Current header version is 4. /// If no V4 features are used, this should be set to 3. /// public byte HeaderVersion { get; set; } /// /// "ATARI7800" with 7 null bytes following /// public byte[] MagicText { get; set; } = new byte[16]; /// /// Cart title, encoding not specified /// public byte[] CartTitle { get; set; } = new byte[32]; /// /// ROM size without header data /// /// /// Endianness possibly varies by version? /// Version 1 - Big-endian /// Version 2 - ????? /// Version 3 - Documented as little-endian (unconfirmed) /// Version 4 - Documented as little-endian (unconfirmed) /// public uint RomSizeWithoutHeader { get; set; } /// /// Cart type flags /// public CartType CartType { get; set; } /// /// Controller 1 type /// public ControllerType Controller1Type { get; set; } /// /// Controller 2 type /// public ControllerType Controller2Type { get; set; } /// /// TV type /// public TVType TVType { get; set; } /// /// Save device /// public SaveDevice SaveDevice { get; set; } /// /// Reserved /// public byte[] Reserved { get; set; } = new byte[4]; /// /// Slot passthrough device /// public SlotPassthroughDevice SlotPassthroughDevice { get; set; } #region Version 4+ /// /// Mapper /// /// v4+ only public Mapper Mapper { get; set; } /// /// Mapper options /// /// v4+ only public MapperOptions MapperOptions { get; set; } /// /// Audio device(s) /// public AudioDevice AudioDevice { get; set; } /// /// Interrupt /// public Interrupt Interrupt { get; set; } #endregion /// /// Padding from end of header data to end magic text /// /// /// 36 bytes in versions lower than 4. /// 30 bytes in versions 4 and above. /// public byte[] Padding { get; set; } = []; /// /// "ACTUAL CART DATA STARTS HERE" /// public byte[] EndMagicText { get; set; } = new byte[28]; } }