Annotation of nono/vm/romemu_luna88k.h, revision 1.1.1.7

1.1       root        1: //
                      2: // nono
1.1.1.2   root        3: // Copyright (C) 2020 nono project
                      4: // Licensed under nono-license.txt
1.1       root        5: //
                      6: 
                      7: #pragma once
                      8: 
1.1.1.5   root        9: #include "romemu_luna.h"
1.1       root       10: 
1.1.1.5   root       11: class Luna88kPROMEmuDevice : public LunaPROMEmuDevice
1.1       root       12: {
1.1.1.5   root       13:        using inherited = LunaPROMEmuDevice;
1.1       root       14: 
1.1.1.7 ! root       15:        // プロンプト種別
        !            16:        enum {
        !            17:                PROMPT_DEFAULT = 0,
        !            18:                PROMPT_NVRAM_UPDATE,
        !            19:                PROMPT_NVRAM_NEW,
        !            20:                PROMPT_NVRAM_INIT,
        !            21:        };
        !            22: 
1.1       root       23:  public:
                     24:        Luna88kPROMEmuDevice();
1.1.1.4   root       25:        virtual ~Luna88kPROMEmuDevice() override;
1.1       root       26: 
1.1.1.2   root       27:        bool Init() override;
1.1.1.6   root       28:        void ResetHard() override;
1.1       root       29: 
                     30:  private:
1.1.1.5   root       31:        uint32 ROM_Init() override;
                     32:        uint32 ROM_Entry() override;
1.1.1.7 ! root       33:        void GetChar(char asciicode) override;
1.1.1.5   root       34:        void Command() override;
1.1.1.7 ! root       35: 
        !            36:        void CommandH(const std::vector<std::string>& arg);
1.1.1.5   root       37:        void CommandB(const std::vector<std::string>& arg);
                     38:        void CommandBH();
                     39:        void CommandNvram(const std::vector<std::string>& arg);
1.1.1.7 ! root       40:        void CommandNvramShowAll();
        !            41:        void CommandNvramShow(const std::vector<std::string>& arg);
        !            42:        void CommandNvramUpdate(const std::vector<std::string>& arg);
        !            43:        void CommandNvramUpdate2(char);
        !            44:        void CommandNvramNew2(char);
        !            45:        void CommandNvramDelete(const std::vector<std::string>& arg);
        !            46:        void CommandNvramInit();
        !            47:        void CommandNvramInit2(char);
1.1.1.5   root       48: 
                     49:        // NVRAM
1.1.1.7 ! root       50:        uint32 FindNVRAM(const std::string& key) const;
1.1.1.5   root       51:        bool InitNVRAM();
                     52:        void GetNVRAM(bootinfo_t&);
1.1.1.2   root       53: 
1.1.1.5   root       54:        uint32 b_entrypoint {};
1.1.1.7 ! root       55: 
        !            56:        // nvram コマンドの遷移で覚えておくもの
        !            57:        int nvram_offset {};
        !            58:        std::string nvram_key {};
        !            59:        std::string nvram_val {};
        !            60: 
        !            61:        // プロンプトの状態。
        !            62:        // 0 (PROMPT_DEFAULT) が通常の行入力プロンプト。
        !            63:        // PROMPT_NVRAM_* は nvram コマンドでの確認プロンプト。
        !            64:        int prompt_idx {};
        !            65: 
        !            66:        // デフォルトプロンプト。
        !            67:        // 本物は "O>" というプロンプトで、何の O か分からんけど(OMRON?)、
        !            68:        // こっちは nono の頭文字ということにしておく。
        !            69:        const std::string default_prompt = "N>";
1.1       root       70: };

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.