Annotation of nono/doc/index.html, revision 1.1.1.8

1.1.1.2   root        1: <!--
                      2:  nono
                      3:  Copyright (C) 2020 nono project
                      4:  Licensed under nono-license.txt
                      5: -->
1.1       root        6: <html><head>
                      7: <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
                      8: <title>nono document</title>
                      9: <style type="text/css">
                     10: /* https://jfly.uni-koeln.de/colorset/ */
                     11: 
                     12: :root {
                     13:        --blue:                 rgb(  0,  90, 255);
                     14:        --brown:                rgb(128,  64,   0);
                     15:        --green:                rgb(  3, 175, 122);
                     16:        --grey:                 rgb(132, 145, 158);
                     17:        --light-grey:   rgb(200, 200, 203);
1.1.1.4   root       18: 
                     19:        --bg-grey:              rgb(220, 220, 223);
1.1       root       20: }
                     21: body {
1.1.1.4   root       22:        background-color: var(--bg-grey);
1.1       root       23: }
                     24: q {
                     25:        color: var(--brown);
                     26: }
                     27: q:before {
                     28:        content: "[";
                     29: }
                     30: q:after {
                     31:        content: "]";
                     32: }
                     33: dt.dt-indent {
                     34:        padding-left: 1ex;
                     35: }
                     36: .main {
                     37:        margin-left: 1em;
                     38: }
                     39: .cons {
                     40:        background-color: black;
                     41:        color: white;
                     42: }
                     43: .file {
                     44:        background-color: white;
                     45:        color: black;
                     46: }
                     47: .strike {
                     48:        color: var(--grey);
                     49: }
1.1.1.5   root       50: .strike > q {
                     51:        color: var(--grey);
                     52: }
1.1       root       53: </style>
                     54: </head>
                     55: <body>
1.1.1.8 ! root       56: <h3>nono 0.1.6 (2021/04/18)</h3>
1.1       root       57: 
                     58: nono は NetBSD とかで動作する OMRON LUNA-I とかのエミュレータです。
1.1.1.4   root       59: <q>nono is OMRON LUNA-I emulator runs on NetBSD and etc.</q>
1.1.1.8 ! root       60: <p>
        !            61: <div class="main">
        !            62: <span style="margin-left: -1em; ">Index:</span><Br>
        !            63: <a href="#build">ビルド方法 <q>How to build</q></a><br>
        !            64: <a href="#commandline">コマンドラインオプション <q>Command Line Option</q></a><br>
        !            65: <a href="#configuration">設定 <q>Configuration</q></a><br>
        !            66: <a href="#aboutvm">VM について <q>About VM</q></a><br>
        !            67: <a href="#tryit">実行してみる <q>Try it</q></a><br>
        !            68: <a href="#network">ネットワーク設定 <q>Setup network</q></a><br>
        !            69: <a href="#changes">変更履歴 <q>Changes</q></a><br>
        !            70: <a href="#license">連絡先、ライセンス等 <q>Contact, License, etc</q></a><br>
        !            71: </div>
1.1       root       72: <hr>
1.1.1.4   root       73: 
                     74: <h4>はじめに <q>Introduction</q></h4>
                     75: <div class="main">
                     76: nono は NetBSD とかで動作する OMRON LUNA-I とかのエミュレータです。
1.1.1.7   root       77: LUNA88K は実験的サポートです。
1.1.1.4   root       78: <q>
                     79: nono is OMRON LUNA-I emulator runs on NetBSD and etc.
1.1.1.7   root       80: LUNA88K is still experimental support.
1.1.1.4   root       81: </q>
                     82: </div>
                     83: 
1.1.1.8 ! root       84: 
        !            85: <a name="build"></a>
1.1       root       86: <h4>ビルド方法 <q>How to build</q></h4>
                     87: <div class="main">
1.1.1.5   root       88: ビルドには以下が必要です。
1.1.1.7   root       89: NetBSD(pkgsrc) なら wxWidgets は pkgsrc/x11/wxGTK30 です
1.1.1.8 ! root       90: (OPTIONS:gtk3 で動作確認しています)。
1.1.1.5   root       91: <q>The followings are required for build.
                     92: If you use NetBSD(pkgsrc),
1.1.1.8 ! root       93: wxWidgets is pkgsrc/x11/wxGTK30 (OPTIONS:gtk3 is tested).</q>
1.1.1.5   root       94: 
1.1       root       95: <ul>
1.1.1.2   root       96: <li>make (BSD make, not GNU make)
1.1.1.4   root       97: <li>C/C++ compiler which supports -std=c++14.
                     98: <br>
                     99: (For gcc, 7.4 works but 5.5 doesn't work, at least.
                    100: For clang, 7.0 and 8.0 works at least.)
1.1.1.2   root      101: <li>wxWidgets &gt;= 3.0
                    102: <li>gettext
1.1       root      103: </ul>
1.1.1.2   root      104: 
1.1.1.5   root      105: <p>
                    106: (NetBSD 以外でのビルドはサポートしていませんが)
                    107: Ubuntu 18.04 ではたぶん以下のパッケージが必要です。
                    108: <q>You may need the following packages on Ubuntu 18.04
                    109: (though we won't support non-NetBSD platform).</q>
                    110: </p>
1.1.1.8 ! root      111: <ul>
        !           112: <li>
1.1.1.5   root      113: bmake
                    114: build-essential
                    115: gettext
                    116: libbsd-dev
                    117: libedit-dev
                    118: libkqueue-dev
                    119: libwxgtk3.0-dev
                    120: zlib1g-dev
1.1.1.8 ! root      121: </ul>
1.1.1.5   root      122: 
1.1.1.2   root      123: <p>
                    124: アーカイブを展開したら以下のようにビルドします。
                    125: configure には環境変数 CC、CXX でコンパイラを指定することが出来ます。
                    126: また wx-config が標準的な名前で提供されていないために見付けられない場合には
                    127: 環境変数 WX_CONFIG にパスを指定することが出来ます。
                    128: <q>Extract the archive and build as following.
                    129: You can specify C/C++ compiler using environment variable CC and CXX
                    130: if configure cannot find standard name suitable compiler.
                    131: Also, you can specify wx-config path using environment variable WX_CONFIG
                    132: if configure cannot find wx-config.</q>
1.1       root      133: <blockquote class="cons"><pre>
                    134: % ./configure
                    135: % make depend
                    136: % make
1.1.1.2   root      137: % su
                    138: # make install
1.1       root      139: </pre></blockquote>
1.1.1.2   root      140: 
                    141: <p>
                    142: 2つの実行ファイルがインストールされます。
                    143: <tt>nono</tt> が GUI 版実行ファイル、
                    144: <tt>nono-cli</tt> がコマンドライン版です。
                    145: <q>Two executables will be installed.
1.1.1.8 ! root      146: <tt>nono</tt> is the GUI executable and <tt>nono-cli</tt> is
        !           147: the command line executable.</q>
1.1       root      148: 
                    149: </div>
                    150: 
                    151: 
1.1.1.8 ! root      152: <a name="commandline"></a>
1.1       root      153: <h4>コマンドラインオプション <q>Command Line Option</q></h4>
                    154: <div class="main">
                    155: <dl>
                    156: <dt class=dt-indent><tt>-A <i>file</i></tt></dt>
                    157: <dd>ホストの <tt><i>file</i></tt> をロードして実行します。
1.1.1.4   root      158: <tt><i>file</i></tt> が相対パスの場合カレントディレクトリからのパスになります。
1.1       root      159: ファイルが gzip 圧縮されていれば自動的に展開します。
                    160: (展開後の) ファイル形式は a.out (OMAGIC) か ELF で、
                    161: 実際にはブートローダとカーネル程度しか想定していません。
1.1.1.2   root      162: 設定ファイルの <tt>prom-image</tt> とともに指定されると
                    163: <tt>-A</tt> のほうが優先します。
                    164: <q>Loads and executes host's <tt><i>file</i></tt>.
1.1.1.4   root      165: If <tt><i>file</i></tt> is relative path,
                    166: it is path from the current directory.
1.1.1.2   root      167: If the file is gzip'd, it is automatically extracted.
                    168: The supported file format (after extracting) is a.out (OMAGIC) or ELF.
                    169: Actually, it only assumes bootloaders or kernels.
                    170: If this option is specified at the same time as
                    171: <tt>prom-image</tt> in configuration file,
                    172: this option preceeds.
                    173: </q></p></dd>
1.1.1.7   root      174: <dt class=dt-indent><tt>-c <i>vmpath</i></tt></dt>
                    175: <dd>VM ディレクトリ/設定ファイルを指定します。
                    176: <i>vmpath</i> がディレクトリならそのディレクトリの中の nono.cfg
                    177: を設定ファイルとします。
                    178: <i>vmpath</i> がファイルならそれを設定ファイルとします。
                    179: そしていずれの場合も
                    180: 設定ファイルがあるディレクトリを VM ディレクトリとします。
                    181: -c オプションを省略すると <i>vmpath</i> をカレントディレクトリとします。
                    182: <q>Specifies the VM directory/configuration file.
                    183: If <i>vmpath</i> is a directory,
                    184: make nono.cfg in that directory a configuration file.
                    185: Or if <i>vmpath</i> is a file,
                    186: make the specified file a configuration file.
                    187: And in both cases,
                    188: make the directory where that file is located a VM directory.
                    189: If <tt>-c</tt> option is omitted,
                    190: <i>vmpath</i> is considered as the current directory.
                    191: </q></p></dd>
1.1       root      192: <dt class=dt-indent><tt>-f</tt></dt>
                    193: <dd>高速モードで起動します。
1.1.1.2   root      194: GUI なら起動後にもメニューから変更できますが、その初期値を変えるだけです。
                    195: <q>Boot as the fast mode.
                    196: You can change this mode on GUI menu after boot,
                    197: and the option only changes its initial state.
                    198: </q></p></dd>
1.1       root      199: <dt class=dt-indent><tt>--fontsize <i>height</i></tt></dt>
                    200: <dd>GUI 版のみ。
                    201: 全サブウインドウの起動時のフォントサイズを指定します。
1.1.1.2   root      202: <tt><i>height</i></tt> には 12, 16
                    203: のいずれかを指定します。デフォルトは <tt>12</tt> です。
1.1.1.3   root      204: 起動後にメニューから変更できます。
1.1.1.2   root      205: <q>
                    206: GUI Only.
                    207: Specifies the initial fontsize on all sub windows.
                    208: <tt><i>height</i></tt> is one of 12 or 16.
1.1.1.3   root      209: The default value is <tt>12</tt>.
                    210: You can change this value on GUI menu after boot.
1.1.1.2   root      211: </q></p></dd>
1.1       root      212: <dt class=dt-indent><tt>-s <i>scale</i></tt></dt>
                    213: <dt class=dt-indent><tt>--scale <i>scale</i></tt></dt>
                    214: <dd>GUI 版のみ。
                    215: メインウィンドウの起動時のスケールを実数で指定します。
                    216: 起動後にもメニューからプリセットされた倍率には変更可能ですが、
                    217: 任意倍率は起動時のみ指定可能です
                    218: <span class=strike>(そのうちなんとかしたい)</span>。
1.1.1.2   root      219: デフォルトは 1.0 です。
                    220: <q>
                    221: GUI Only.
                    222: Specifies the initial main window scale in real number.
                    223: You can change this scale on GUI menu after boot,
                    224: but unlike this option, there are only a few preset choices
                    225: <span class=strike>(Should be improved in someday)</span>.
                    226: The default value is 1.0</q></p></dd>
1.1       root      227: <dt class=dt-indent><tt>--show-config</tt></dt>
1.1.1.2   root      228: <dd>設定ファイルと <tt>-V</tt> オプションを読み込んだ結果を表示します。
                    229: <q>Shows the result of reading configuration file and
                    230: parsing <tt>-V</tt> options.</q></p></dd>
1.1       root      231: <dt class=dt-indent><tt>-v</tt></dt>
1.1.1.2   root      232: <dd>バージョンを表示します。
                    233: <q>Shows the version.</q></p></dd>
1.1       root      234: <dt class=dt-indent><tt>-V <i>name</i>=<i>value</i></tt></dt>
1.1.1.3   root      235: <dd>設定ファイルで指定した <tt><i>name</i>=<i>configvalue</i></tt> の代わりに
1.1.1.2   root      236: このオプションの <tt><i>name</i>=<i>value</i></tt> を適用します。
1.1.1.3   root      237: <q>Use this <i>name</i>=<i>value</i>
                    238: instead of <i>name</i>=<i>configvalue</i> specified in configuration file.
1.1.1.2   root      239: </q></p></dd>
1.1       root      240: </dl>
                    241: 
1.1.1.2   root      242: 以下開発用。<q>For developers:</q>
1.1       root      243: <dl>
1.1.1.3   root      244: <dt class=dt-indent><tt>-b <i>hexaddr</i>[,<i>skipcount</i>]</tt></dt>
1.1       root      245: <dd>デバッガのブレークポイントを 16進数で指定します。</dd>
                    246: <dt class=dt-indent><tt>-C</tt></dt>
                    247: <dd>ログをコンソールにも出力します。
                    248: 通常はログウィンドウにだけ出力されます。</dd>
                    249: <dt class=dt-indent><tt>-d</tt></dt>
                    250: <dd>起動時にデバッガプロンプトで停止します。</dd>
                    251: <dt class=dt-indent><tt>-D</tt></dt>
                    252: <dd>コンソールをデバッガとして使用します。
                    253: -d を指定しなくても起動時にプロンプトで停止します
                    254: <span class=strike>(そのうちなんとかしたい)</span>。</dd>
                    255: <dt class=dt-indent><tt>-L <i>name1</i>=<i>level1</i>[,<i>name2</i>=<i>level2</i>,...]</tt></dt>
                    256: <dd>ログレベルを指定します。
                    257: カンマで区切って複数指定することも出来ます。
                    258: <tt>-Lhelp</tt> で name の一覧を表示します。</dd>
                    259: <dt class=dt-indent><tt>-M <i>name</i>[,<i>name2</i>,...]</tt></dt>
                    260: <dd>起動時に表示するモニタウィンドウを指定します。
1.1.1.3   root      261: カンマで区切って複数指定することも出来ます。
                    262: <tt>-Mhelp</tt> で name の一覧を表示します。</dd>
1.1       root      263: </dl>
                    264: </div>
                    265: 
1.1.1.8 ! root      266: 
        !           267: <a name="configuration"></a>
1.1       root      268: <h4>設定 <q>Configuration</q></h4>
                    269: <div class="main">
1.1.1.7   root      270: VM の設定ファイルはその VM ディレクトリ内の nono.cfg
                    271: (または -c で指定したファイル) です。
1.1       root      272: 書式は <tt>key = value</tt> 形式で1行1項目ずつです。
                    273: <tt>key</tt> と <tt>value</tt> の前後の空白は取り除かれます。
                    274: また空行と "<tt>#</tt>" で始まる行は無視します。
                    275: 知らないキーの行も無視します。
1.1.1.7   root      276: <q>VM configuration file is nono.cfg
                    277: (or the file specified by -c option) in the VM directory.
1.1.1.2   root      278: Its syntax is <tt>key = value</tt> format, one per line.
                    279: White spaces before and after <tt>key</tt> and <tt>value</tt> are ignored.
                    280: And, blank lines, lines beginning with "<tt>#</tt>", and
                    281: lines with unrecognized key are also ignored.
                    282: </q>
1.1       root      283: <p>
                    284: 設定項目は次の通りです。
1.1.1.2   root      285: <q>The configuration items are:</q>
1.1       root      286: <dl>
                    287: <dt class=dt-indent><tt>vmtype = <i>string</i></tt></dt>
1.1.1.4   root      288: <dd>VM 種別を以下のいずれかから指定します。
                    289: 省略不可です。
                    290: <q>Specifies the VM type from the following.
                    291: This field is mandatory.
                    292: </q>
                    293: <table cellspacing=0 cellpadding=0>
                    294: <tr><td>&nbsp;<td><tt>luna</tt>        <td>… LUNA-I
                    295: <tr><td><td><tt>luna88k</tt>   <td>… LUNA88K (experimental)
                    296: </table></p></dd>
1.1       root      297: <dt class=dt-indent><tt>debugger-port = <i>integer</i></tt></dt>
                    298: <dd>デバッガの TCP 待ち受けポート番号を指定します。
                    299: 0 なら待ち受けを行いません。
1.1.1.4   root      300: デフォルトは 0 です。
                    301: <q>Specifies the TCP port number that debugger listens.
                    302: If 0, it will not listen.
                    303: The default is 0.</q></p></dd>
1.1       root      304: <dt class=dt-indent><tt>ethernet-hostdriver = <i>string</i></tt></dt>
                    305: <dd>イーサネットデバイスのホスト側ドライバを指定します。
                    306: <tt>none</tt>、<tt>tap</tt>、<tt>bpf</tt> が指定できます。
                    307: <tt>none</tt> ならホスト側とは一切通信を行いません。
                    308: <tt>tap</tt> か <tt>bpf</tt> かはホスト OS によってビルド時に決定します。
1.1.1.7   root      309: NetBSD、OpenBSD、FreeBSD、Linux なら <tt>tap</tt> です。
                    310: <q>Specifies the host driver of ethernet device.
                    311: <tt>none</tt>, <tt>tap</tt> and <tt>bpf</tt> can be specified.
                    312: If <tt>none</tt>, it doesn't make any communication with the host.
                    313: <tt>tap</tt> or <tt>bpf</tt> is determined at build time for the host OS.
                    314: If the host is NetBSD, OpenBSD, FreeBSD, or Linux, it's <tt>tap</tt>.</q></p></dd>
                    315: <dt class=dt-indent><tt>ethernet-hostdevice = <i>string</i></tt></dt>
                    316: <dd>イーサネットデバイスのホスト側のデバイス名を指定します。
                    317: <tt>ethernet-hostdriver</tt> が <tt>tap</tt> の場合ここには
                    318: tap デバイスを(フルパスで)指定します。
                    319: <q>Specifies the host device name of ethernet device.
                    320: If <tt>ethernet-hostdriver</tt> is <tt>tap</tt>,
                    321: this field specifies the full path to the tap device.</q>
                    322: <p>
                    323: デフォルトは <tt>auto</tt> で、この場合の動作はホスト OS ごとに異なります。
                    324: Linux なら "<tt>/dev/net/tun</tt>" を指定したのと同じです。
                    325: OpenBSD なら <tt>/dev/tap0</tt> から <tt>/dev/tap9</tt> まで
                    326: 順番にオープンできるまで試します。
                    327: NetBSD (と FreeBSD) ならまず <tt>/dev/tap</tt> でクローニングを試み、
                    328: それが失敗すれば <tt>/dev/tap0</tt> から <tt>/dev/tap9</tt> までを
                    329: 順番にオープンできるまで試します。
                    330: <q>The default is <tt>auto</tt>.
                    331: The behavior in this case depends on the host OS.
                    332: On Linux, it's the same as <tt>/dev/net/tun</tt>.
                    333: On OpenBSD, it will try from <tt>/dev/tap0</tt> to <tt>/dev/tap9</tt>
                    334: until successful.
                    335: On NetBSD (and FreeBSD), it will try cloning by <tt>/dev/tap</tt> first.
                    336: If that fails, then try from <tt>/dev/tap0</tt> to <tt>/dev/tap9</tt>
                    337: until successful.
                    338: </q></p></dd>
1.1       root      339: <dt class=dt-indent><tt>ethernet-macaddr = <i>string</i></tt></dt>
                    340: <dd>イーサネットデバイスの仮想マシン側の MAC アドレスを指定します。
                    341: <tt><i>XX</i>:<i>XX</i>:<i>XX</i>:<i>XX</i>:<i>XX</i>:<i>XX</i></tt>
                    342: 形式で指定します。
                    343: <tt>auto</tt> なら自動的に決定します。
                    344: デフォルトは <tt>auto</tt> です。</p></dd>
                    345: <dt class=dt-indent><tt>luna-dipsw1 = <i>string</i></tt></dt>
                    346: <dd>本体前面 DIPSW#1-1..#1-8 の内容を指定します。
                    347: "<tt>0</tt>" を DOWN、"<tt>1</tt>" を UP として、
                    348: これを8つ並べた形式で、前から順に #1..#8 に対応します。
1.1.1.4   root      349: <q>Specifies status of the front panel DIPSW#1-1..#1-8 using 8 digit.
1.1.1.2   root      350: "<tt>0</tt>" means DOWN and "<tt>1</tt>" means UP.
                    351: The first character corresponds to #1 and
1.1.1.3   root      352: the eighth character corresponds to #8.</q>
                    353: <p>
                    354: LUNA-I でのデフォルトは <tt>11110111</tt> です。
                    355: 各スイッチの内容は以下のリンクを参照してください。
                    356: <q>On LUNA-I, the default value is <tt>11110111</tt>.
1.1.1.4   root      357: See the following link about DIPSW.</q><br>
1.1.1.3   root      358: → <a href="https://wiki.netbsd.org/ports/luna68k/luna68k_info/"
                    359: >NetBSD/luna68k: Information</a>
1.1       root      360: <br>
1.1.1.4   root      361: LUNA88K でのデフォルトは <tt>11111111</tt> です。
                    362: 各スイッチの内容は以下のリンクを参照してください。
                    363: <q>On LUNA88K, the default value is <tt>11111111</tt>.
                    364: See the following link about DIPSW.</q><br>
                    365: → <a href="http://man.openbsd.org/boot_luna88k.8"
                    366: >OpenBSD manual pages: boot_luna88k(8)</a></p></dd>
1.1       root      367: <dt class=dt-indent><tt>luna-dipsw2 = <i>string</i></tt></dt>
                    368: <dd>本体前面 DIPSW#2-1..#2-8 の内容を指定します。
                    369: 書式は <tt>luna-dipsw1</tt> と同じです。
                    370: デフォルトは <tt>11111111</tt> です。
1.1.1.2   root      371: <q>Specifies status of the front panel DIPSW#2-1..#2-8.
                    372: The same syntax as <tt>luna-dipsw1</tt> is used.
                    373: The default value is <tt>11111111</tt>.</q>
1.1.1.3   root      374: <p>
1.1.1.4   root      375: NetBSD/luna68k のブートローダは、
                    376: DIPSW#2 が "<tt>11111111</tt>" なら自動的にカーネルをロードして実行し、
                    377: どれかでも "<tt>0</tt>" にするとプロンプトで停止するようです。
1.1.1.2   root      378: <span class=strike>(本当は #8 だけで制御するつもりだったんじゃないかという気がします)</span>
1.1.1.4   root      379: <q>NetBSD/luna68k bootloader will automatically load and execute the kernel,
                    380: if the DIPSW#2 is "<tt>11111111</tt>".
1.1.1.2   root      381: Otherwise, the bootloader will enter interactive mode.
                    382: <span class=strike>(I doubt that they actually wanted to switch with only #8)
                    383: </span>
                    384: </q></p></dd>
1.1.1.3   root      385: <dt class=dt-indent><tt>monitor-rate = <i>integer</i></tt></dt>
                    386: <dd>テキスト系モニタウィンドウの更新頻度を Hz 単位で指定します。
                    387: 1 から 60 までの間で指定でき、デフォルトは 20Hz です。
                    388: 起動後にメニューからプリセットされた頻度には変更可能です。
                    389: <q>Specifies refresh rate of all text monitor windows in Hz.
                    390: It ranges from 1 to 60.  The default is 20Hz.
                    391: You can change this value on GUI menu after boot,
                    392: but unlike this configuration value, there are only a few preset choices.
                    393: </q></p></dd>
1.1       root      394: <dt class=dt-indent><tt>mpu-clock = <i>value</i></tt></dt>
                    395: <dd>MPU のクロック数を MHz 単位で指定します。
1.1.1.5   root      396: デフォルトは LUNA-I なら 20MHz、LUNA88K なら 25MHz です。
                    397: <q>Specifies the MPU clock in MHz.
                    398: The default value is 20MHz on LUNA-I, or 25MHz on LUNA88K.</q></p></dd>
1.1.1.2   root      399: <dt class=dt-indent><tt>prom-image = <i>path</i></tt></dt>
1.1.1.4   root      400: <dd>LUNA-I/LUNA88K の外部 ROM イメージファイルのパスを指定します。
1.1.1.2   root      401: <i>path</i> がファイル名のみなら VM ディレクトリとその親ディレクトリからこのファイル名を検索します。
                    402: <i>path</i> が相対パスなら VM ディレクトリからの相対パスになります (現在のディレクトリからではありません)。
                    403: 空にすると内蔵 ROM を使用します。
                    404: デフォルトは空です。
1.1.1.4   root      405: <q>Specifies the LUNA-I/LUNA88K's external ROM image file path.
1.1.1.2   root      406: If the <i>path</i> does not have any path delimiters,
                    407: the VM directory and then its parent directory will be searched.
                    408: If the <i>path</i> is a relative path,
                    409: it will be path from the VM directory, not from the current
                    410: directory.
                    411: If the <i>path</i> is empty, internal emulated ROM will be used.
                    412: The default value is empty.</q>
1.1       root      413: <p>
1.1.1.2   root      414: 実機を持っていない場合はこの値を空に (= デフォルトのままに) しておくと、
1.1.1.4   root      415: nono 内蔵のなんちゃって下位互換 ROM で起動します(現状 LUNA-I のみ)。
1.1.1.2   root      416: <q>If you does not have the real LUNA machines,
                    417: you can boot with nono's internal downward compatible emulated ROM
1.1.1.4   root      418: if you set this field empty (or leave it as the default).
                    419: For now, it's only for LUNA-I.
                    420: </q>
1.1       root      421: <p>
1.1.1.4   root      422: LUNA-I 実機を持っている場合は
                    423: ROM ファイルを指定することで実機 ROM で起動できます。
1.1.1.2   root      424: ROM ファイルは実機の 0x41000000-0x4101ffff (128KB) を保存したものです。
1.1.1.3   root      425: 今のところ ROM は V4.22 (Thu Jul 27 11:45:42 1989) のみサポートしています。
                    426: それ以外については何も分かりません。
1.1.1.4   root      427: <q>If you have the real LUNA-I machine,
1.1.1.2   root      428: you can boot with the real ROM spcifying the ROM file path.
1.1.1.4   root      429: The ROM file is extracted from 0x41000000-0x4101ffff (128KB) of
                    430: the real LUNA-I machine.
1.1.1.3   root      431: For now, only V4.22 (Thu Jul 27 11:45:42 1989) is supported.
                    432: I have no idea about other ROMs.
1.1.1.4   root      433: </q>
                    434: <p>
                    435: LUNA88K 実機の場合は 0x41000000-0x4103ffff (256KB) を保存したものです。
                    436: ただし現状サポートしていません。
                    437: <q>
                    438: For LUNA88K,
                    439: the ROM file is extracted from 0x41000000-0x4103ffff (256KB).
                    440: However, it's not supported yet.
1.1.1.3   root      441: </q></p></dd>
                    442: <dt class=dt-indent><tt>ram-size = <i>integer</i></tt></dt>
1.1.1.2   root      443: <dd>搭載する RAM サイズを MB 単位で指定します。
1.1.1.7   root      444: LUNA-I のデフォルトは 16MB です。
                    445: 16MB 未満は 4MB 単位で、
                    446: 16MB 以上は 255MB まで 1MB 単位で指定できます
                    447: (ちなみに NetBSD/luna68k の起動には最低でも 8MB 必要です)。
                    448: LUNA88K のデフォルトは 64MB です。
                    449: 64MB 未満は 16MB 単位で、
                    450: 64MB 以上は暫定で 255MB まで 1MB 単位で指定できます。
1.1.1.5   root      451: <q>Specifies the RAM size in MB.
1.1.1.7   root      452: On LUNA-I, the default is 16MB.
                    453: If the size is less than 16MB, you can specify in 4MB unit.
                    454: If larger, you can specify up to 255MB in 1MB unit.
                    455: By the way, NetBSD/luna68k needs at least 8MB to boot.
                    456: On LUNA88K, the default is 64MB.
                    457: If the size is less than 64MB, you can specify in 16MB unit.
                    458: If larger, you can specify up to tentative 255MB in 1MB unit.
                    459: </q></p></dd>
1.1.1.8 ! root      460: <dt class=dt-indent><tt>show-statuspanel = <i>integer</i></tt></dt>
        !           461: <dd>ステータスパネルを表示するかどうかを指定します。
        !           462: 0 なら非表示、1 なら表示です。
        !           463: 起動後はメニューから変更可能です。
        !           464: <q>Specifies whether to display the status panel or not.
        !           465: If 0, it is hidden; if 1, it is shown.
        !           466: You can change it on GUI menu after boot.
        !           467: </q></p></dd>
1.1       root      468: <dt class=dt-indent><tt>spc0-id<i>N</i>-image = <i>devtype</i>,<i>path</i></tt></dt>
                    469: <dd>SCSI デバイスを指定します。<i>N</i> には 0 から 7 が入ります。
                    470: ID 7 は本体が使用しますので指定しないでください。
                    471: 値はデバイス種別 <i>devtype</i> とイメージパス <i>path</i>
                    472: を "<tt>,</tt>"(カンマ) で区切って並べた形式で、
                    473: 今の所デバイス種別 <i>devtype</i> には "<tt>hd</tt>"(ハードディスク) のみ指定可能です。
                    474: ディスクイメージパスが相対パスなら VM ディレクトリからの相対パスになります。
1.1.1.2   root      475: <q>
                    476: Specifies SCSI device.  <i>N</i> is 0 to 7.
                    477: But don't specify ID 7 because the host uses it.
                    478: The value is in a form of device type <i>devtype</i> and
                    479: the image path <i>path</i> separated by "<tt>,</tt>"(comma).
                    480: For now, only "<tt>hd</tt>" (hard disk) can be specified for <i>devtype</i>.
                    481: If the <i>path</i> is relative path, it is from the VM directory.
                    482: </q>
                    483: 
1.1       root      484: <p>
                    485: 例えば、nono.cfg と同じディレクトリに置いたディスクイメージ luna.img
                    486: を使う場合、
1.1.1.7   root      487: LUNA では通常 ID 6 をプライマリ HDD に割り当てるのでこんな感じになります。
1.1.1.2   root      488: <q>For example, if you use disk image luna.img placed in the same
                    489: directory as nono.cfg,
1.1.1.7   root      490: since LUNA usually assigns ID 6 to the primary HDD,
1.1.1.2   root      491: write as following:</q>
1.1       root      492: <blockquote><pre>
                    493: spc0-id6-image = hd,luna.img
                    494: </pre></blockquote></p></dd>
1.1.1.4   root      495: <dt class=dt-indent><tt>spc0-id<i>N</i>-seektime = <i>integer</i></tt></dt>
                    496: <dd>指定の SCSI HDD の平均シークタイムを msec 単位で指定します。
                    497: 現在のデフォルトは <tt>0</tt> です (S・S・D!! S・S・D!!)。
                    498: 16 程度を指定すると幾分往時に思いを馳せることが出来るかもしれませんが、
                    499: 今の所あまり安定していません。
                    500: <q>Specifies the average seek time of specified SCSI HDD in msec.
                    501: Currently, the default value is <tt>0</tt>
                    502: (This may be something like SSD :-).
                    503: If you specify about 16 or so, you can feel nostalgic,
                    504: but this feature is still unstable.
                    505: </q></p></dd>
1.1       root      506: <dt class=dt-indent><tt>spc0-id<i>N</i>-writeprotect = <i>integer</i></tt></dt>
                    507: <dd>指定の SCSI デバイスへの書き込みを無視するかどうか指定します。
                    508: <tt>0</tt> なら通常動作(書き込みを行う)です。
                    509: <tt>1</tt> なら書き込みコマンドは成功したように振る舞いますが実際には
                    510: ディスクイメージに一切書き戻しません。
                    511: fsck を気にせずカーネルのデバッグとかを行いたい場合にはどうぞ。
                    512: 何が起きるか意味が分からない人は指定しないでください。
1.1.1.2   root      513: デフォルトは <tt>0</tt> です。
                    514: <q>Specifies whether nono ignores writing to SCSI devices.
                    515: <tt>0</tt> means normal operation (writes to the devices).
1.1.1.7   root      516: If <tt>1</tt> is specified,
1.1.1.2   root      517: nono will not actually write back to the disk image
                    518: even though the write command is succeeded.
                    519: nono's SCSI devices acts as
                    520: write command is successfully done but it never writes back
                    521: to the actual disk image.
                    522: This is useful for kernel debugging because it does not require fsck
                    523: after the kernel hangs.
                    524: But don't use this flag if you don't understand this paragraph.
                    525: The default value is <tt>0</tt>.
                    526: </q></p></dd>
1.1       root      527: </dl>
                    528: </div>
                    529: 
                    530: 
1.1.1.8 ! root      531: <a name="aboutvm"></a>
        !           532: <h4>VM について <q>About VM</q></h4>
        !           533: <h5>ステータスパネル <q>Status Panel</q></h5>
        !           534: <div class="main">
        !           535: ステータスパネル中央にあるパフォーマンスメータのアイコンは
        !           536: 高速モードの状態を表示しています。
        !           537: ダブルクリックすると高速/等速モードの指定を切り替えることができます。
        !           538: <q>The performance meter's icon at the center of the status panel
        !           539: shows the VM speed status.
        !           540: You can switch full speed / syncronized mode by double-clicking on this icon.
        !           541: </q>
        !           542: <table>
        !           543: <tr><td valign=top>
        !           544: <image src="image/sp-ffmark0.png" style="padding:0.5ex; background-color:white">
        !           545: <td valign=top>…
        !           546: <td valign=top>
        !           547: マークなしの場合、ユーザが等速モードを指定していて、等速モードで実行中です。
        !           548: <q>When no icons are displayed,
        !           549: the user has specified syncronized mode and
        !           550: the VM is running in synchronized mode.</q>
        !           551: <tr><td valign=top>
        !           552: <image src="image/sp-ffmark1.png" style="padding:0.5ex; background-color:white">
        !           553: <td valign=top>…
        !           554: <td valign=top>
        !           555: 三角2つの場合、ユーザが高速モードを指定していて、等速モードで実行中です。
        !           556: キー入力中(後述)または VM がアイドル状態(m68k の STOP 命令)などで起きます。
        !           557: <q>When an icon (two triangles) is displayed,
        !           558: the user has specified full speed mode and
        !           559: the VM is running in synchronized mode.
        !           560: This will happen during keystrokes or when the VM is idle
        !           561: (STOP instruction on m68k).
        !           562: </q>
        !           563: <tr><td valign=top>
        !           564: <image src="image/sp-ffmark2.png" style="padding:0.5ex; background-color:white">
        !           565: <td valign=top>…
        !           566: <td valign=top>
        !           567: 三角3つの場合、ユーザが高速モードを指定していて、高速モードで実行中です。
        !           568: <q>When an icon (three triangles) is displayed,
        !           569: the user has specified full speed mode and
        !           570: the VM is running in full speed mode.
        !           571: </table>
        !           572: </div>
        !           573: 
        !           574: <h5>キー入力 <q>Key input</q></h5>
        !           575: <div class="main">
        !           576: LUNA では、キーボードがハードウェア側でキーリピートを行わず、
        !           577: ソフトウェア(OS など)がキーリピートの処理を行います。
        !           578: そのため、キーリピートを実装していない LUNA の PROM や
        !           579: NetBSD/luna68k のブートローダではキーリピートは起きず、
        !           580: キーリピートを実装している NetBSD/luna68k カーネルではキーリピートが起こせます。
        !           581: ソフトウェアでキーリピートを起こす間隔を測定しているということは、
        !           582: VM が高速動作するとキーリピートもそれに合わせて発生することになり、
        !           583: これをホスト側から防ぐ手段はありません。
        !           584: そこで nono ではキー入力が発生している間
        !           585: (キーが一つでも押されてからキーが全て離されるまでの間)、
        !           586: 高速モードが指示されていても VM を一時的に等速モードに落として実行します。
        !           587: 上記のアイコンがそれを区別しているのはこのためです。
        !           588: そのため、何らかの理由でキーが入りっぱなしになった場合
        !           589: (ALT + TAB やアクセラレータキーでメニューを開くと起きがちです)
        !           590: 高速モードが抑制されたままということが起きえます。
        !           591: その場合はソフトウェアキーボードからキー入力を解除するなどしてください。
        !           592: <q>
        !           593: On LUNA,
        !           594: key repeat is done by software(OS), not by the keyboard hardware.
        !           595: For this reason,
        !           596: key repeat doesn't occur on LUNA's PROM or NetBSD/luna68k's bootloader
        !           597: that don't implement it, and
        !           598: key repeat occurs on NetBSD/luna68k kernel that implements it.
        !           599: Since the timing of key repeat is measured by software,
        !           600: if the VM is running faster than the real,
        !           601: the key repeat will occur faster, too.
        !           602: The host application doesn't have the way to avoid it.
        !           603: Therefore, nono will temporarily suppress the full speed mode
        !           604: while any keys are pressed.
        !           605: That is why the above-mentioned icon distinguishes them.
        !           606: For this reason,
        !           607: if keys continue to be pressed for some reason,
        !           608: the VM also continues to run syncronized mode.
        !           609: In this case, you can resolve it by using the software keyboard window.
        !           610: </q>
        !           611: </div>
        !           612: 
        !           613: 
        !           614: <a name="tryit"></a>
1.1       root      615: <h4>実行してみる <q>Try it</q></h4>
                    616: <div class="main">
1.1.1.2   root      617: つついさんが NetBSD/luna68k 9.0 の liveimage を用意してくださっています
                    618: (いつもありがとうございます)。
                    619: <q>Tsutsui-san has provided NetBSD/luna68k 9.0 liveimage for this
                    620: (Thanks as always).</q>
                    621: <br>
                    622: <ol>
                    623: <li>どこかに nono 用のディレクトリを用意し(例えば ~/nono/)、
1.1       root      624: その中に VM ディレクトリを用意します (例えば ~/nono/luna/)。
1.1.1.3   root      625: <q>Create a directory somewhere for nono (for example ~/nono/),
1.1.1.8 ! root      626: and create subdirectories for individual VMs in it (for example ~/nono/luna/).</q>
1.1       root      627: 
1.1.1.3   root      628: <li>以下のリンクからイメージファイルをダウンロードして展開し、
1.1.1.2   root      629: VM ディレクトリ ~/nono/luna/ に置きます。
1.1.1.3   root      630: <q>Download imagefile from the following link,
1.1.1.8 ! root      631: extract it and place it in the VM directory, ~/nono/luna/.</q>
1.1.1.3   root      632: <blockquote>
                    633: <a href="http://teokurebsd.org/netbsd/liveimage/20200518-luna68k/"
                    634: >http://teokurebsd.org/netbsd/liveimage/20200518-luna68k/</a>
                    635: </blockquote>
1.1.1.2   root      636: 
                    637: <li>同じく VM ディレクトリに設定ファイル nono.cfg を以下の内容で用意します。
1.1.1.8 ! root      638: <q>Create a configuration file nono.cfg in the VM directory, ~/nono/luna/,
1.1.1.2   root      639: with following contents:</q>
                    640: <blockquote class="file"><pre>
                    641: vmtype = luna
                    642: spc0-id6-image = hd,liveimage-luna68k-raw-20200518.img
                    643: </pre></blockquote>
                    644: <li><tt>nono -c ~/nono/luna</tt> で起動します
                    645: (VM ディレクトリに自動的に NVRAM.DAT が作られます)。
                    646: <q>Run as <tt>nono -c ~/nono/luna</tt>.
1.1.1.4   root      647: (NVRAM.DAT will be created automatically in the VM directory)</q>
1.1.1.2   root      648: <li>Emulated ROM Monitor が起動するので、
                    649: 初回は以下のように入力すると NetBSD が起動します。
                    650: <q>The emulated ROM Monitor will be executed.
                    651: Then, only for the first time,
                    652: entering the following can boot NetBSD.</q>
                    653: <blockquote class="file"><pre>
                    654: k
                    655: [Enter]
                    656: [Enter]
                    657: d
                    658: boot
                    659: g
                    660: x
                    661: </pre></blockquote>
                    662: この内容は NVRAM.DAT に記録されているので次回以降は直接 NetBSD が起動します。
1.1.1.8 ! root      663: <q>The information you have just entered is recorded in the NVRAM,
1.1.1.2   root      664: so next time it boots NetBSD automatically.</q>
                    665: </ol>
                    666: <p>
                    667: <a href="https://twitter.com/tsutsuii/status/1262429647364427783"
                    668: >元ツイートはこちら<q>Original tweet</q></a>。
1.1       root      669: </div>
                    670: 
                    671: 
1.1.1.8 ! root      672: <a name="network"></a>
1.1       root      673: <h4>ネットワーク設定 <q>Setup network</q></h4>
                    674: <div class=main>
1.1.1.2   root      675: 設定ファイル nono.cfg に以下の行を追加します。
                    676: <q>Add the following line to configuration file, nono.cfg.</q>
1.1       root      677: <blockquote class="file"><pre>
                    678: ethernet-hostdriver = tap
                    679: </pre></blockquote>
1.1.1.2   root      680: 次に VM ディレクトリかその親ディレクトリに nono-ifup、nono-ifdown
                    681: というスクリプトを用意します。
1.1       root      682: nono は tap(4) をオープンし、
                    683: そのデバイス名を引数にこれらのスクリプトを呼びます。
1.1.1.2   root      684: <q>Then, prepare two scripts named nono-ifup and nono-ifdown
                    685: in the VM directory or its parent directory.
                    686: nono will open tap(4) and
                    687: invoke these scripts with the name of the device as an argument.</q>
1.1       root      688: <p>
1.1.1.5   root      689: 例えば、NetBSD ホストで、ホストの wm0 セグメントに nono のゲスト OS を接続する場合、
                    690: <q>For example, if you want to connect guest OS to host's wm0 segment
                    691: on NetBSD,</q>
                    692: <ol>
                    693: <li>デフォルトでは /dev/tap は一般ユーザからアクセスできないので、
                    694: chmod で適当にパーミッションを与えます。
                    695: 番号の付いていないほうの /dev/tap だけでいいです。
                    696: <q>By default, /dev/tap is only accessible to privileged user.
                    697: You need to chmod /dev/tap (without unit number) appropriately.</q>
                    698: sysinst 等で OS をアップグレードするとパーミッションが 600
                    699: に戻るのがハマりポイントです。
                    700: 
                    701: <li>bridge(4) インタフェースを作成し、
                    702: ホストの外側のインタフェースをブリッジに追加しておきます。
                    703: <q>Create a bridge(4) interface, and
                    704: add your physical interface to the bridge.</q>
1.1       root      705: <blockquote class="cons"><pre>
1.1.1.5   root      706: # ifconfig bridge0 create
1.1       root      707: # brconfig bridge0 add wm0
                    708: </pre></blockquote>
1.1.1.5   root      709: 常用するなら設定ファイルに書いておきましょう。
                    710: <q>If you want to use this all the time,
                    711: you can put configuration file into /etc.</q>
                    712: <blockquote>
                    713: /etc/ifconfig.bridge0
                    714: <pre class=file>
                    715: create
                    716: up
                    717: !/sbin/brconfig $int add wm0
                    718: </pre>
                    719: <pre class=cons>
                    720: # /etc/rc.d/network restart
                    721: </pre>
                    722: </blockquote>
                    723: 
                    724: <li>
                    725: 一般ユーザに戻って、
                    726: VM ディレクトリかその親ディレクトリに
                    727: 次のような 2つのスクリプトを用意します。
                    728: sudo の設定は別途行ってください。
                    729: <q>Return to non-privileged user, and
                    730: create following two scripts in the VM directory or its parent directory.
                    731: In addition, you need to set up sudo separately.</q>
1.1       root      732: <blockquote>
                    733: nono-ifup
                    734: <pre class=file>
                    735: #!/bin/sh
1.1.1.5   root      736: sudo /sbin/ifconfig $1 up
                    737: sudo /sbin/brconfig bridge0 add $1
1.1       root      738: </pre></blockquote>
                    739: 
                    740: <blockquote>
1.1.1.5   root      741: nono-ifdown
1.1       root      742: <pre class=file>
                    743: #!/bin/sh
1.1.1.5   root      744: sudo /sbin/brconfig bridge0 delete $1
                    745: sudo /sbin/ifconfig $1 down
                    746: </pre></blockquote>
                    747: 
                    748: <blockquote class="cons"><pre>
                    749: % chmod +x nono-ifup nono-ifdown
1.1       root      750: </pre></blockquote>
                    751: 
1.1.1.5   root      752: <li>nono を起動し、
                    753: メニューの「モニタ &gt; ホスト &gt; ホストネットワーク」を開いて
                    754: NetDriver が None 以外 (この場合 BSD tap) になっていれば動いてるはずです。
                    755: <q>Run nono,
                    756: and open "Monitor &gt; Host &gt; Host Network" window from menu.
                    757: It's OK if you can see "NetDriver: BSD tap" (in this case).</q>
                    758: 
                    759: </ol>
                    760: 
1.1       root      761: </div>
                    762: 
                    763: 
1.1.1.8 ! root      764: <a name="changes"></a>
1.1.1.2   root      765: <h4>変更履歴 <q>Changes</q></h4>
                    766: <div class="main">
                    767: See <a href="changes.html">changes.html</a>.
                    768: </div>
                    769: 
                    770: 
1.1.1.8 ! root      771: <a name="license"></a>
1.1.1.2   root      772: <h4>ライセンス <q>License</q></h4>
                    773: <div class="main">
                    774: See <a href="nono-license.txt">nono-license.txt</a>.
                    775: </div>
                    776: 
                    777: 
1.1.1.4   root      778: <h4>連絡先 <q>Contact us</q></h4>
                    779: <div class="main">
                    780: バグ報告などは以下にお願いします。日本語でおk。
                    781: <q>If you find any problems, please let me know.
                    782: You may write in English.</q><br>
                    783: <a href="https://github.com/isaki68k/nono-issue/issues"
                    784: >https://github.com/isaki68k/nono-issue/issues</a>
                    785: </div>
                    786: 
                    787: 
1.1.1.2   root      788: <h4>パッチの提供について <q>About contributes</q></h4>
                    789: <div class="main">
                    790: パッチを提供してくださる場合は以下に同意したものとします。
                    791: <q>If you provide a patch to nono, you must agree to the following conditions:
                    792: </q>
                    793: <ul>
                    794: <li>成果物が nono のライセンスに従って運用あるいは配布されること。
                    795: <q>All your work are operated or distributed under the nono license.</q>
                    796: <li>ライセンスが将来変わる可能性があること。
                    797: <q>The license may be changed in the future.</q>
                    798: <li>著作部分に関して著作者人格権を行使しないこと。
                    799: <q>Do not exercise your author's rights.</q>
                    800: </ul>
                    801: <ul>
                    802: </div>
                    803: 
                    804: 
                    805: <h4>Acknowledgements</h4>
                    806: <div class="main">
                    807: nono は以下の広告条項を含むソースコードを利用しています。
                    808: <q>nono uses source code with the following advertising clause.</q>
                    809: <blockquote>
                    810: This product includes software developed by Gordon Ross<br>
                    811: This product includes software developed by the University of California, Lawrence Berkeley Laboratory.<br>
                    812: </blockquote>
                    813: </div>
                    814: 
1.1       root      815: 
                    816: <hr>
1.1.1.2   root      817: nono project
1.1       root      818: </body>
                    819: </html>

unix.superglobalmegacorp.com

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