7518
This commit is contained in:
parent
30e4df8172
commit
32bb01ba4a
|
@ -1,5 +1,7 @@
|
|||
# Primitives for screen control.
|
||||
|
||||
== code
|
||||
|
||||
pixel: # screen: (addr screen), x: int, y: int, color: int
|
||||
# . prologue
|
||||
55/push-ebp
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
# check keyboard for a key
|
||||
# return 0 on no keypress or unrecognized key
|
||||
|
||||
== code
|
||||
|
||||
read-key: # kbd: (addr keyboard) -> result/eax: byte
|
||||
# . prologue
|
||||
55/push-ebp
|
||||
|
|
|
@ -1,3 +1,7 @@
|
|||
# Use the built-in font to draw a grapheme to screen.
|
||||
|
||||
== code
|
||||
|
||||
draw-grapheme: # screen: (addr screen), g: grapheme, x: int, y: int, color: int
|
||||
# . prologue
|
||||
55/push-ebp
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
== code
|
||||
# instruction effective address register displacement immediate
|
||||
# . op subop mod rm32 base index scale r32
|
||||
# . 1-3 bytes 3 bits 2 bits 3 bits 3 bits 3 bits 2 bits 2 bits 0/1/2/4 bytes 0/1/2/4 bytes
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
== code
|
||||
# instruction effective address register displacement immediate
|
||||
# . op subop mod rm32 base index scale r32
|
||||
# . 1-3 bytes 3 bits 2 bits 3 bits 3 bits 3 bits 2 bits 2 bits 0/1/2/4 bytes 0/1/2/4 bytes
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
== code
|
||||
# instruction effective address register displacement immediate
|
||||
# . op subop mod rm32 base index scale r32
|
||||
# . 1-3 bytes 3 bits 2 bits 3 bits 3 bits 3 bits 2 bits 2 bits 0/1/2/4 bytes 0/1/2/4 bytes
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
== code
|
||||
# instruction effective address register displacement immediate
|
||||
# . op subop mod rm32 base index scale r32
|
||||
# . 1-3 bytes 3 bits 2 bits 3 bits 3 bits 3 bits 2 bits 2 bits 0/1/2/4 bytes 0/1/2/4 bytes
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
# TODO: bring this back
|
||||
|
||||
== code
|
||||
|
||||
__check-mu-array-bounds: # index: int, elem-size: int, arr-size: int, function-name: (addr array byte), array-name: (addr array byte)
|
||||
# . prologue
|
||||
55/push-ebp
|
||||
|
|
|
@ -10,6 +10,8 @@
|
|||
# Or:
|
||||
# bochs -f baremetal/boot.bochsrc # boot.bochsrc loads disk.img
|
||||
|
||||
== code
|
||||
|
||||
main:
|
||||
e9/jump main/disp32
|
||||
|
||||
|
|
|
@ -10,6 +10,8 @@
|
|||
# Expected output:
|
||||
# html/baremetal.png
|
||||
|
||||
== code
|
||||
|
||||
main:
|
||||
# ecx <- start of video memory
|
||||
8b/-> *0x7f28 1/r32/ecx
|
||||
|
|
Loading…
Reference in New Issue