]>
wirehaze git hosting - lifeboot.git/blob - lifeboot.asm
60b5ea4e7e1b58115dfccf2d587b7c6079740823
10 %
define GRID
ORG + 512
11 %
define NEXT_GRID GRID_CUR
+ COLS
* ROWS
16 %
define PRINT_COLOR
0x07 ; grey on black
18 ; entry point -----------------------------------------------------------------
20 ; initialize segment registers
30 ; clear screen ----------------------------------------------------------------
42 mov ax, (PRINT_COLOR
<< 8) | DEAD
44 rep stosw ; fill cx words at es:di with ax
46 ; errors ----------------------------------------------------------------------
51 ; print the error message string in si and halt
52 ; note: we assume es = VGA_SEG and ds = 0
57 ; es:di = video memory
58 ; ds:si = error message
60 ; ah = color attribute
63 lodsb ; al = [ds:si], si += 1
64 or al, al ; on null terminator,
66 stosw ; [es:di] = ax, di += 2
70 cli ; disable interrupts
74 ; data ------------------------------------------------------------------------
80 times 510 - ($ - $$) db 0 ; fill remaining bytes with zeroes
81 dw 0xaa55 ; mbr magic byte