--- nono/vm/printer.cpp 2026/04/29 17:05:10 1.1.1.6 +++ nono/vm/printer.cpp 2026/04/29 17:05:18 1.1.1.8 @@ -11,28 +11,22 @@ #include "printer.h" #include "mpu.h" -// グローバル参照用 -PrinterDevice *gPrinter; - // コンストラクタ PrinterDevice::PrinterDevice() - : inherited("Printer") + : inherited(OBJ_PRINTER) { - devaddr = baseaddr; - devlen = 0x2000; } // デストラクタ PrinterDevice::~PrinterDevice() { - gPrinter = NULL; } uint64 PrinterDevice::Read8(uint32 addr) { // 書き込み専用 - gMPU->AddCycle(7); // InsideOut p.135 + mpu->AddCycle(7); // InsideOut p.135 return (uint64)-1; } @@ -40,22 +34,24 @@ uint64 PrinterDevice::Read16(uint32 addr) { // 書き込み専用 - gMPU->AddCycle(7); // InsideOut p.135 + mpu->AddCycle(7); // InsideOut p.135 return (uint64)-1; } uint64 PrinterDevice::Write8(uint32 addr, uint32 data) { - gMPU->AddCycle(7); // InsideOut p.135 + mpu->AddCycle(7); // InsideOut p.135 uint32 offset = addr - baseaddr; switch (offset) { case 0: - putlog(0, "未実装データ書き込み"); + // データ書き込み + putlog(0, "Write Data (NOT IMPLEMENTED)"); break; case 3: - putlog(0, "未実装ストローブ書き込み"); + // ストローブ書き込み + putlog(0, "Write Strobe (NOT IMPLEMENTED)"); return 0; default: break;