15 lines
269 B
C++
15 lines
269 B
C++
#include <iostream>
|
|
#include "memory/bus.h"
|
|
#include "memory/ram.h"
|
|
|
|
int main(int argc, char** argv)
|
|
{
|
|
RAM r(0x1000);
|
|
Bus b;
|
|
|
|
b.map_device(0x0000, 0x0FFF, &r);
|
|
b.map_device(0x2000, 0x2FFF, &r);
|
|
|
|
b.write8(0x60, 42);
|
|
return (b.read8(0x2060) == 42) ? 0 : 1;
|
|
}
|