Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

3.5KB


type: workflow-guide source: E07-S01 disk builder and E07-S02 launchers

Editor and Compiler Workflow

Nova128 does not link the editor and compiler in memory. A development disk is edited in one emulator session and compiled in another, strictly in sequence. scripts/prepare-disk.ps1 (E07-S01) copies ../vim/work.d81 to a disposable image without ever writing the source; the launchers below add the two sessions.

Sequential rule

Never attach the same disk image writable to two emulators at once, and never edit an image while a compiler session still has it open. VICE buffers DOS writes, so a second session can read a half-written directory or overwrite the first session's changes. The launchers enforce this with a session lock in the image's folder (.newlang-session.lock); the lock holds the owning process and its kind, and a lock left behind by a dead process is replaced automatically.

Editor session

powershell -NoProfile -ExecutionPolicy Bypass -File scripts\launch-editor.ps1
  • Copies ../vim/vim-improved.d81 to build/newlang-edit.d81 first, so the editor never opens the source image, then writes ../vim/vim128.prg into the copy as vim128.
  • Starts x128 in 80-column mode and autostarts vim128 from the session disk, then attaches that disk as drive 8. Loading the editor from the disk is what gives it a write device: a host-loaded copy reports written and leaves the image unchanged, because it has no device number from the load. The 80-column session draws on the VDC, so an automated -Screenshot uses VICE's plain -exitscreenshot; the VIC-II option would capture a blank 40-column screen.
  • Waits for x128 to exit, then waits until the image can be opened exclusively (the image has flushed) before returning.
  • Verifies the source image's SHA-256 is unchanged.

Use -EditorPrg and -SourceImage to select another editor build or disk. -Emulator x64sc selects the C64 build instead, but that program is on vim-improved.d81 rather than a standalone PRG, so pass -EditorPrg with the extracted vim file. -LimitCycles and -Screenshot are for automated checks only; they end the session early.

Compiler session

powershell -NoProfile -ExecutionPolicy Bypass -File scripts\launch-compiler.ps1
  • Rebuilds build/newlang-dev.d81 from the clean source copy with prepare-disk.ps1 (unless -SkipPrepare is given), injecting build/n128c.prg.
  • Autostarts that compiler PRG in x128 with the development image attached.
  • Waits for x128 to exit and for the image to flush before returning.

-CompilerPrg selects another compiler PRG. The launcher reports a missing compiler program, source image, or VICE tool before starting anything.

Recovery

  • Lock reported as still owned: close the named session's emulator window first; if the process is gone, the launcher replaces the stale lock.
  • Image still locked after the emulator exits: wait for the DOS write to finish; the launcher retries for 30 seconds before failing.
  • Source image changed: stop and inspect ../vim with git status; the launchers only ever copy from it.
  • Wrong editor or compiler build: pass -EditorPrg/-CompilerPrg explicitly rather than editing the defaults.

Limits

Autostart loads the program from the host file system, not from the disk; the disk stays attached for the session's own file access. Physical C128 testing and the full edit/compile/run walkthrough belong to E07-S04 and E08-S06.

Powered by TurnKey Linux.