|
|
1.1 ! root 1: // ! 2: // nono ! 3: // Copyright (C) 2020 nono project ! 4: // Licensed under nono-license.txt ! 5: // ! 6: ! 7: #pragma once ! 8: ! 9: #include "romemu_luna.h" ! 10: ! 11: class Luna1PROMEmuDevice : public LunaPROMEmuDevice ! 12: { ! 13: using inherited = LunaPROMEmuDevice; ! 14: ! 15: public: ! 16: Luna1PROMEmuDevice(); ! 17: virtual ~Luna1PROMEmuDevice() override; ! 18: ! 19: bool Init() override; ! 20: void ResetHard() override; ! 21: ! 22: private: ! 23: uint32 ROM_Init() override; ! 24: uint32 ROM_Entry() override; ! 25: void ROM_Close() override; ! 26: void Command() override; ! 27: ! 28: void CommandG(const std::vector<std::string>& arg); ! 29: void CommandGH(); ! 30: void CommandK(const std::vector<std::string>& arg); ! 31: bool CommandKInput(const std::string& val); ! 32: void CommandX(); ! 33: ! 34: // NVRAM ! 35: uint8 CalcNVRAMCsum(); ! 36: void WriteNVRAMCsum(); ! 37: bool VerifyNVRAM(); ! 38: bool InitNVRAM(); ! 39: void GetNVRAM(bootinfo_t&); ! 40: ! 41: // 'x' コマンドなら true。 ! 42: bool x_executed {}; ! 43: ! 44: // 'g' コマンドで読み込んだプログラムのエントリポイント。 ! 45: // なければ 0。'x' コマンドで使う。 ! 46: uint32 x_entrypoint {}; ! 47: ! 48: // プロンプトの状態。 ! 49: // 0 が通常プロンプト。 ! 50: // 1 以降は k コマンドのプロンプトを示す ! 51: int prompt_idx {}; ! 52: // デフォルトプロンプト ! 53: const std::string default_prompt = ">"; ! 54: };
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.