Output to display with Rust bare metal

830 Views Asked by At

I'm following along with the Phil-Opp tutorials on creating an OS, and I'm trying to figure out how to control my display/screen, after having successfully gotten VGA output to work. How does one control the display? I'm assuming you have to write a driver... or do you write to specific memory locations like VGA? Would a crate like SDL2, Glium, or something else work on 'bare-metal'?

1

There are 1 best solutions below

1
On

Assuming you are in a 8bpp VGA graphics mode (such as Mode 0x13), you can write pixels directly to the screen by writing to memory addresses 0xA0000 to 0xB8000.