pull/11/head
able 2023-11-03 08:25:31 -05:00
parent 8a5f12bcff
commit 2959e65ef9
3 changed files with 14 additions and 18 deletions

View File

@ -18,6 +18,7 @@ pub static DISPLAY: Lazy<Mutex<Display>> = Lazy::new(|| {
disp.set_attribute("width", fb1.width); disp.set_attribute("width", fb1.width);
disp.set_attribute("height", fb1.height); disp.set_attribute("height", fb1.height);
disp.set_attribute("bits per pixel", fb1.bpp); disp.set_attribute("bits per pixel", fb1.bpp);
disp.set_attribute("pitch", fb1.pitch);
// disp.set_attribute("fb ptr", fb1.address.as_ptr().unwrap()); // disp.set_attribute("fb ptr", fb1.address.as_ptr().unwrap());
dt.devices.insert("Displays".to_string(), alloc::vec![disp]); dt.devices.insert("Displays".to_string(), alloc::vec![disp]);
} }

View File

@ -7,17 +7,20 @@ import "repbuild/hblib/std" as std;
// Define main // Define main
fn main(){ fn main(){
std::Info("Starting the limine framebuffer driver."); std::Info("Starting the limine framebuffer driver.");
// Color
li8(r1, 0x7); li64(r1, 0xffffffff);
li8(r2, 0); // iterator
li64(r3, 1000); li32(r2, 0);
// count
label("start"); li64(r3, 12);
// store from a register to a local address // Label here
let start = label();
// Write to the memory
st(r1, r2, 0xFFFF8000C0000000, 1); st(r1, r2, 0xFFFF8000C0000000, 1);
// addi64(r2, r2, 1); // Increment
addi64(r2, r2, 1);
jltu(r2, r3, "start"); // std::Info("abc");
jltu(r2, r3, start);
// Terminate execution. // Terminate execution.
tx(); tx();

View File

@ -11,14 +11,6 @@ fn main(){
std::ipc_send(2, str, str.len); std::ipc_send(2, str, str.len);
std::ipc_recv(2); 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!"); std::Info("VFS Test done!");
// un(); // un();