1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-12-24 12:30:17 +00:00

Fixed types of the 8k cartridges, ensured the 6502 starts without an IRQ request history.

This commit is contained in:
Thomas Harte 2017-03-18 17:04:01 -04:00
parent e8d34f2eb4
commit 55ce851bb2
2 changed files with 4 additions and 3 deletions

View File

@ -13,7 +13,7 @@
namespace Atari2600 {
class CartridgeAtari8k: public Cartridge<CartridgeUnpaged> {
class CartridgeAtari8k: public Cartridge<CartridgeAtari8k> {
public:
CartridgeAtari8k(const std::vector<uint8_t> &rom) :
Cartridge(rom) {
@ -36,7 +36,7 @@ class CartridgeAtari8k: public Cartridge<CartridgeUnpaged> {
uint8_t *rom_ptr_;
};
class CartridgeAtari8kSuperChip: public Cartridge<CartridgeUnpaged> {
class CartridgeAtari8kSuperChip: public Cartridge<CartridgeAtari8kSuperChip> {
public:
CartridgeAtari8kSuperChip(const std::vector<uint8_t> &rom) :
Cartridge(rom) {

View File

@ -548,6 +548,7 @@ template <class T> class Processor {
ready_is_active_(false),
scheduled_programs_{nullptr, nullptr, nullptr, nullptr},
inverse_interrupt_flag_(0),
irq_request_history_(0),
s_(0),
next_bus_operation_(BusOperation::None),
interrupt_requests_(InterruptRequestFlags::PowerOn),
@ -657,7 +658,7 @@ template <class T> class Processor {
case CycleFetchOperation: {
last_operation_pc_ = pc_;
// printf("%04x x:%02x\n", pc_.full, x_);
// printf("%04x\n", pc_.full);
pc_.full++;
read_op(operation_, last_operation_pc_.full);