--- nono/cli/cli_app.cpp 2026/04/29 17:04:51 1.1.1.6 +++ nono/cli/cli_app.cpp 2026/04/29 17:04:53 1.1.1.7 @@ -8,6 +8,7 @@ #include "mainapp.h" #include "mpu680x0.h" #include "pluto.h" +#include "scheduler.h" #include "vm.h" void cli_halt_callback(void *); @@ -18,7 +19,7 @@ class CLIApp public: int OnInit(); bool Parse(); - [[noreturn]] void OnCreate(); + int OnCreate(); int ac; char **av; @@ -62,16 +63,17 @@ CLIApp::OnInit() } // メインウィンドウ作成後のイベントに相当するところ -void +int CLIApp::OnCreate() { // 電源投入 gVM->PowerButton(); - // ? - for (;;) { - sleep(1); - } + // スケジューラの終了を待つ + + gScheduler->Wait(); + + return 0; } // m680x0 ダブルバスフォールト時に呼ばれるコールバック。