From 2a7a20b498250759b7f33a324dda750dad309d10 Mon Sep 17 00:00:00 2001 From: Ross Andrews Date: Thu, 17 Apr 2025 19:32:41 -0500 Subject: [PATCH] Added blank color --- novaforth/build.rs | 3 ++- vgfx/src/display.rs | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/novaforth/build.rs b/novaforth/build.rs index 4de844b..d0888b6 100644 --- a/novaforth/build.rs +++ b/novaforth/build.rs @@ -32,7 +32,8 @@ fn main() { symfile.write(json.as_bytes()).expect("Unable to write to symbol file"); } Err(e) => { - eprintln!("{}", e) + eprintln!("{}", e); + panic!() } } } \ No newline at end of file diff --git a/vgfx/src/display.rs b/vgfx/src/display.rs index 794f406..5efff22 100644 --- a/vgfx/src/display.rs +++ b/vgfx/src/display.rs @@ -12,6 +12,7 @@ struct DisplayRegisters { width: Word, row_offset: Word, col_offset: Word, + blank_color: Word, } impl Default for DisplayRegisters { @@ -25,6 +26,7 @@ impl Default for DisplayRegisters { width: Word::from(40), row_offset: Word::from(0), col_offset: Word::from(0), + blank_color: Word::from(0), } } } @@ -39,6 +41,7 @@ fn read_display_registers(machine: &P, start: Word) -> DisplayRegis width: machine.peek24(start + 13), row_offset: machine.peek24(start + 16), col_offset: machine.peek24(start + 19), + blank_color: machine.peek24(start + 22), } } @@ -52,6 +55,7 @@ fn init_display_registers(machine: &mut P, start: Word) { machine.poke24(start + 13, dr.width); machine.poke24(start + 16, dr.row_offset); machine.poke24(start + 19, dr.col_offset); + machine.poke24(start + 22, dr.blank_color); } fn init_font(machine: &mut P) {