diff --git a/kernel/src/arch/x86_64/graphics.rs b/kernel/src/arch/x86_64/graphics.rs index adb7c4da..2f36627f 100644 --- a/kernel/src/arch/x86_64/graphics.rs +++ b/kernel/src/arch/x86_64/graphics.rs @@ -18,6 +18,7 @@ pub static DISPLAY: Lazy> = Lazy::new(|| { disp.set_attribute("width", fb1.width); disp.set_attribute("height", fb1.height); disp.set_attribute("bits per pixel", fb1.bpp); + disp.set_attribute("pitch", fb1.pitch); // disp.set_attribute("fb ptr", fb1.address.as_ptr().unwrap()); dt.devices.insert("Displays".to_string(), alloc::vec![disp]); } diff --git a/repbuild/holeybytes/limine_framebuffer_driver.rhai b/repbuild/holeybytes/limine_framebuffer_driver.rhai index a9015330..040aab22 100644 --- a/repbuild/holeybytes/limine_framebuffer_driver.rhai +++ b/repbuild/holeybytes/limine_framebuffer_driver.rhai @@ -7,17 +7,20 @@ import "repbuild/hblib/std" as std; // Define main fn main(){ std::Info("Starting the limine framebuffer driver."); - - li8(r1, 0x7); - li8(r2, 0); - li64(r3, 1000); - - label("start"); - // store from a register to a local address + // Color + li64(r1, 0xffffffff); + // iterator + li32(r2, 0); + // count + li64(r3, 12); + // Label here + let start = label(); + // Write to the memory st(r1, r2, 0xFFFF8000C0000000, 1); - // addi64(r2, r2, 1); - - jltu(r2, r3, "start"); + // Increment + addi64(r2, r2, 1); + // std::Info("abc"); + jltu(r2, r3, start); // Terminate execution. tx(); diff --git a/repbuild/holeybytes/vfs_test.rhai b/repbuild/holeybytes/vfs_test.rhai index 2883f384..22663bff 100644 --- a/repbuild/holeybytes/vfs_test.rhai +++ b/repbuild/holeybytes/vfs_test.rhai @@ -11,14 +11,6 @@ fn main(){ std::ipc_send(2, str, str.len); std::ipc_recv(2); - li8(r1, 0x7); - li8(r2, 0); - li64(r3, 128821000); - - let start = label(); - st(r1, r2, 0xFFFF8000C0000000, 1); - addi64(r2, r2, 1); - jltu(r2, r3, start); std::Info("VFS Test done!"); // un();