ibis-os/main.asm

58 lines
730 B
NASM
Raw Normal View History

2024-07-24 17:02:54 +00:00
; Bootloader
%include "boot.asm"
2024-07-24 15:41:52 +00:00
2024-07-24 17:16:51 +00:00
section KERNEL follows=BOOTSECTOR vstart=1000h
2024-07-25 15:53:07 +00:00
%macro mod 2
push ax
push cx
mov cx, %2
xor dx, dx
mov ax, %1
div cx
pop cx
pop ax
%endmacro
2024-07-24 15:41:52 +00:00
main:
; Video mode
mov ax, 0x13
int 0x10
; Important for mouse stuff maybe????
jmp 0x000:.setcs
.setcs:
call mouse_initialize
call mouse_enable
lp:
cli
mov bx, [mouseX]
sti
call print_hex
call print_nl
2024-07-25 15:37:04 +00:00
jmp lp
2024-07-25 15:37:04 +00:00
2024-07-24 15:41:52 +00:00
jmp $ ; Halt
2024-07-24 17:02:54 +00:00
; Libs
2024-07-24 15:41:52 +00:00
%include "print_util.asm"
%include "mouse_util.asm"
;%include "time_util.asm"
;%include "gfx_util.asm"
2024-07-24 17:02:54 +00:00
; Data
HELLO_WORLD:
2024-07-25 18:20:57 +00:00
db 'Hello, world! :D', 0
No:
db 'No.', 0
2024-07-25 18:20:57 +00:00
;%include "gfx/gfxd_cursor.asm"