updates to dsa libs
This commit is contained in:
@@ -1,33 +0,0 @@
|
||||
include print "./lib/io/print.dsa"
|
||||
|
||||
dw idt: 0xFFFF0000
|
||||
dw stack: 0x10000
|
||||
db interrupt: "INT: Hello world"
|
||||
|
||||
init:
|
||||
// set up a stack.
|
||||
ldw stack, bpr
|
||||
mov bpr, spr
|
||||
|
||||
start:
|
||||
ldw idt, idr
|
||||
|
||||
lwi handle_hard_fault, rg0
|
||||
stw rg0, idr, 4
|
||||
|
||||
|
||||
lwi 0x1234abcd, rg0
|
||||
push rg0
|
||||
call print::print_hex_word
|
||||
pop zero
|
||||
hlt
|
||||
|
||||
|
||||
dw hard_fault_err: "FATAL: Illegal Instruction or Memory Access!"
|
||||
handle_hard_fault:
|
||||
call print::reset
|
||||
lwi hard_fault_err, rg0
|
||||
push rg0
|
||||
call print::print
|
||||
pop zero
|
||||
hlt
|
||||
Reference in New Issue
Block a user