Founding of the BugFestival

This commit is contained in:
2024-06-07 07:36:24 +02:00
parent a9e928efa0
commit 7b5e5df952
10 changed files with 108 additions and 89 deletions

View File

@@ -151,19 +151,20 @@ namespace JabyEngine {
Interrupt::Type complete_irq;
};
// TODO: Seems they all need to be ACK? Can we remove this?
static constexpr Desc GetStat{0x01, Interrupt::Type::Acknowledge};
static constexpr Desc SetLoc{0x02, Interrupt::Type::Acknowledge};
static constexpr Desc Play{0x03, Interrupt::Type::Acknowledge};
static constexpr Desc ReadN{0x06, Interrupt::Type::DataReady};
static constexpr Desc ReadN{0x06, Interrupt::Type::Acknowledge};
static constexpr Desc Pause{0x09, Interrupt::Type::Complete};
static constexpr Desc Init{0x0A, Interrupt::Type::Complete};
//static constexpr Desc Init{0x0A, Interrupt::Type::Complete};
static constexpr Desc Demute{0x0C, Interrupt::Type::Acknowledge};
static constexpr Desc Filter{0x0D, Interrupt::Type::Acknowledge};
static constexpr Desc SetMode{0x0E, Interrupt::Type::Acknowledge};
static constexpr Desc GetLocP{0x11, Interrupt::Type::Acknowledge};
static constexpr Desc GetTN{0x13, Interrupt::Type::Acknowledge};
static constexpr Desc GetTD{0x14, Interrupt::Type::Acknowledge};
static constexpr Desc ReadS{0x1B, Interrupt::Type::DataReady};
static constexpr Desc ReadS{0x1B, Interrupt::Type::Acknowledge};
};
static constexpr auto IORegister1Adr = 0x1F801801;

View File

@@ -117,7 +117,7 @@ namespace JabyEngine {
};
typedef InterruptVerifierResult (*InterruptVerifier)();
typedef uint32_t (*InterruptHandler)(uint32_t);
typedef void (*InterruptHandler)(uint32_t);
using ThreadHandle = uint32_t;
#pragma pack(push, 1)
@@ -127,8 +127,8 @@ namespace JabyEngine {
InterruptVerifier verifier_function;
uint32_t notUsed;
static constexpr InterruptCallback from_single_function(InterruptVerifier verifier) {
return InterruptCallback{nullptr, nullptr, verifier, 0};
static constexpr InterruptCallback from(InterruptVerifier verifier, InterruptHandler handler) {
return InterruptCallback{nullptr, handler, verifier, 0};
}
};
#pragma pack(pop)