rk86 2.0.24 → 2.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/rk86.js +22 -4
package/package.json
CHANGED
package/rk86.js
CHANGED
|
@@ -4083,7 +4083,7 @@ import { basename } from "path";
|
|
|
4083
4083
|
// packages/rk86/package.json
|
|
4084
4084
|
var package_default = {
|
|
4085
4085
|
name: "rk86",
|
|
4086
|
-
version: "2.0.
|
|
4086
|
+
version: "2.0.24",
|
|
4087
4087
|
description: "\u042D\u043C\u0443\u043B\u044F\u0442\u043E\u0440 \u0420\u0430\u0434\u0438\u043E-86\u0420\u041A (Intel 8080) \u0434\u043B\u044F \u0442\u0435\u0440\u043C\u0438\u043D\u0430\u043B\u0430",
|
|
4088
4088
|
bin: {
|
|
4089
4089
|
rk86: "rk86.js"
|
|
@@ -6060,16 +6060,30 @@ class TerminalRenderer {
|
|
|
6060
6060
|
output += `${dim}\u250C${"\u2500".repeat(w)}\u2510${reset}
|
|
6061
6061
|
`;
|
|
6062
6062
|
let addr = screen.video_memory_base;
|
|
6063
|
+
let frameStopped = false;
|
|
6063
6064
|
for (let y = 0;y < screen.height; y++) {
|
|
6064
6065
|
let line = `${dim}\u2502${reset}`;
|
|
6066
|
+
let rowStopped = frameStopped;
|
|
6065
6067
|
for (let x = 0;x < w; x++) {
|
|
6066
|
-
const
|
|
6068
|
+
const raw = memory.read(addr++);
|
|
6069
|
+
let ch;
|
|
6070
|
+
if (rowStopped) {
|
|
6071
|
+
ch = " ";
|
|
6072
|
+
} else if (raw >= 240) {
|
|
6073
|
+
ch = " ";
|
|
6074
|
+
rowStopped = true;
|
|
6075
|
+
if (raw >= 248)
|
|
6076
|
+
frameStopped = true;
|
|
6077
|
+
} else if (raw >= 128) {
|
|
6078
|
+
ch = " ";
|
|
6079
|
+
} else {
|
|
6080
|
+
ch = rk86char(raw);
|
|
6081
|
+
}
|
|
6067
6082
|
if (x === screen.cursor_x && y === screen.cursor_y) {
|
|
6068
6083
|
line += `\x1B[4m${ch}${reset}`;
|
|
6069
6084
|
} else {
|
|
6070
6085
|
line += ch;
|
|
6071
6086
|
}
|
|
6072
|
-
addr++;
|
|
6073
6087
|
}
|
|
6074
6088
|
line += `${dim}\u2502${reset}`;
|
|
6075
6089
|
output += line + `
|
|
@@ -6512,7 +6526,7 @@ function dumpScreen(machine) {
|
|
|
6512
6526
|
let rowStopped = frameStopped;
|
|
6513
6527
|
for (let x = 0;x < screen.width; x++) {
|
|
6514
6528
|
const raw = memory.read_raw(addr++);
|
|
6515
|
-
if (rowStopped || raw >=
|
|
6529
|
+
if (rowStopped || raw >= 192) {
|
|
6516
6530
|
line += ".";
|
|
6517
6531
|
if (raw >= 240)
|
|
6518
6532
|
rowStopped = true;
|
|
@@ -6520,6 +6534,10 @@ function dumpScreen(machine) {
|
|
|
6520
6534
|
frameStopped = true;
|
|
6521
6535
|
continue;
|
|
6522
6536
|
}
|
|
6537
|
+
if (raw >= 128) {
|
|
6538
|
+
line += ".";
|
|
6539
|
+
continue;
|
|
6540
|
+
}
|
|
6523
6541
|
const byte = raw & 127;
|
|
6524
6542
|
if (byte === 0 || byte === 9 || byte === 10 || byte === 13) {
|
|
6525
6543
|
line += ".";
|