2017-05-17 01:19:17 +00:00
|
|
|
//
|
|
|
|
// Z80AllRAM.hpp
|
|
|
|
// Clock Signal
|
|
|
|
//
|
|
|
|
// Created by Thomas Harte on 16/05/2017.
|
|
|
|
// Copyright © 2017 Thomas Harte. All rights reserved.
|
|
|
|
//
|
|
|
|
|
|
|
|
#ifndef Z80AllRAM_hpp
|
|
|
|
#define Z80AllRAM_hpp
|
|
|
|
|
|
|
|
#include "Z80.hpp"
|
2017-05-17 01:28:17 +00:00
|
|
|
#include "../AllRAMProcessor.hpp"
|
2017-05-17 01:19:17 +00:00
|
|
|
|
|
|
|
namespace CPU {
|
|
|
|
namespace Z80 {
|
|
|
|
|
2017-05-17 01:28:17 +00:00
|
|
|
class AllRAMProcessor:
|
|
|
|
public ::CPU::AllRAMProcessor,
|
|
|
|
public Processor<AllRAMProcessor> {
|
|
|
|
|
2017-05-17 01:19:17 +00:00
|
|
|
public:
|
|
|
|
AllRAMProcessor();
|
|
|
|
|
|
|
|
int perform_machine_cycle(const MachineCycle *cycle);
|
2017-05-22 23:24:11 +00:00
|
|
|
|
|
|
|
struct MemoryAccessDelegate {
|
2017-05-22 23:49:38 +00:00
|
|
|
virtual void z80_all_ram_processor_did_perform_bus_operation(AllRAMProcessor &processor, BusOperation operation, uint16_t address, uint8_t value, int time_stamp) = 0;
|
2017-05-22 23:24:11 +00:00
|
|
|
};
|
|
|
|
void set_memory_access_delegate(MemoryAccessDelegate *delegate) {
|
|
|
|
delegate_ = delegate;
|
|
|
|
}
|
|
|
|
|
|
|
|
private:
|
|
|
|
MemoryAccessDelegate *delegate_;
|
2017-05-17 01:19:17 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif /* Z80AllRAM_hpp */
|