Fix CD cancelling commands; Cleanup CD code a bit

This commit is contained in:
2023-04-03 22:00:39 +02:00
parent 1edae637c7
commit 7a373a38ff
4 changed files with 44 additions and 40 deletions

View File

@@ -31,6 +31,18 @@ namespace JabyEngine {
static constexpr uint8_t Max = 0xFF;
};
__declare_io_type(Mode, uint8_t,
static constexpr auto DoubleSpeed = Bit(7);
static constexpr auto SingleSpeed = !DoubleSpeed;
static constexpr auto XADPCM = Bit(6);
static constexpr auto WholeSector = Bit(5);
static constexpr auto DataSector = !WholeSector;
static constexpr auto UseXAFilter = Bit(3);
static constexpr auto AudioPlayIRQ = Bit(2);
static constexpr auto AutoPauseTrack = Bit(1);
static constexpr auto CDDA = Bit(0);
);
__declare_io_type(IndexStatus, uint8_t,
static constexpr auto PortIndex = BitRange::from_to(0, 1);
static constexpr auto HasXAFifoData = Bit(2);