ableos/sysdata/test-programs/limine_framebuffer_driver.rhai

29 lines
685 B
Plaintext
Raw Normal View History

2023-10-29 14:25:13 +00:00
// Change and add to this as you see fit.
// The STD and even syscalls are still in flux.
// Do your best to avoid adding bad design.
// Use std abstractions if they exist like logging functionality
2023-11-11 14:45:45 +00:00
import "sysdata/test-programs/hblib/std" as std;
2023-10-29 14:25:13 +00:00
// Define main
fn main(){
2023-11-02 19:08:48 +00:00
std::Info("Starting the limine framebuffer driver.");
2023-11-03 13:25:31 +00:00
// Color
li64(r1, 0xffffffff);
// iterator
li32(r2, 0);
// count
li64(r3, 12);
// Label here
let start = label();
// Write to the memory
2023-11-02 19:08:48 +00:00
st(r1, r2, 0xFFFF8000C0000000, 1);
2023-11-03 13:25:31 +00:00
// Increment
addi64(r2, r2, 1);
// std::Info("abc");
jltu(r2, r3, start);
2023-10-29 14:25:13 +00:00
2023-11-02 19:08:48 +00:00
// Terminate execution.
tx();
}
2023-10-29 14:25:13 +00:00
2023-11-02 19:08:48 +00:00
main();