mirror of
https://github.com/curioustorvald/tsvm.git
synced 2026-03-07 11:51:49 +09:00
Terran BASIC stuffs
This commit is contained in:
@@ -29,8 +29,6 @@ public class TerranBASIC {
|
||||
appConfig.setWindowedMode(WIDTH, HEIGHT);
|
||||
|
||||
HashMap<String, VMWatchdog> watchdogs = new HashMap<>();
|
||||
watchdogs.put("TEVD_COMMIT", TevdPartialDomCommitWatchdog.INSTANCE);
|
||||
watchdogs.put("TEVD_SYNC", TevdPartialDomSyncWatchdog.INSTANCE);
|
||||
|
||||
VM tbasvm = new VM("./assets", 64 << 10, new TheRealWorld(), new VMProgramRom[]{TBASRelBios.INSTANCE}, 2, watchdogs);
|
||||
EmulInstance tbasrunner = new EmulInstance(tbasvm, "net.torvald.tsvm.peripheral.ReferenceGraphicsAdapter", "assets/disk0", 560, 448);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
println("TSVM - Copyright 2020 CuriousTorvald");
|
||||
println("TSVM - Copyright 2020-2023 CuriousTorvald");
|
||||
|
||||
var _BIOS = {};
|
||||
|
||||
@@ -26,6 +26,12 @@ if (r == 0){
|
||||
println("Reading basic.js...");
|
||||
let g=com.pullMessage(0);
|
||||
let execAppPrg = eval("var _appStub=function(exec_args){"+g+"};_appStub;"); // making 'exec_args' a app-level global
|
||||
|
||||
// show TerranBASIC on the character LCD (aka the window title)
|
||||
[..."TerranBASIC"].map(s=>s.charCodeAt(0)).forEach((c,i)=>{
|
||||
sys.poke(-1025 - i, c)
|
||||
})
|
||||
|
||||
execAppPrg();
|
||||
}
|
||||
catch (e) {
|
||||
|
||||
Reference in New Issue
Block a user