diff options
Diffstat (limited to 'ex4.mu')
-rw-r--r-- | ex4.mu | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/ex4.mu b/ex4.mu new file mode 100644 index 00000000..5b883131 --- /dev/null +++ b/ex4.mu @@ -0,0 +1,14 @@ +# Draw a character using the built-in font (GNU unifont) +# +# To build a disk image: +# ./translate_mu_baremetal baremetal/ex4.mu # emits disk.img +# To run: +# qemu-system-i386 disk.img +# Or: +# bochs -f baremetal/boot.bochsrc # boot.bochsrc loads disk.img +# +# Expected output: letter 'A' in green near the top-left corner of screen + +fn main { + draw-codepoint 0/screen, 0x41/A, 2/row, 1/col, 0xa/fg, 0/bg +} |