source: xtideuniversalbios/trunk/XTIDE_Universal_BIOS/Src/Boot/BootPrint.asm@ 89

Last change on this file since 89 was 88, checked in by Tomi Tilli, 14 years ago

Changes to XTIDE Universal BIOS:

  • Now uses new libraries (untested)
  • Non-working since code size is too large
File size: 2.3 KB
RevLine 
[88]1; Project name : XTIDE Universal BIOS
[3]2; Description : Functions for printing boot related strings.
3
4; Section containing code
5SECTION .text
6
7;--------------------------------------------------------------------
8; BootPrint_TryToBootFromDL
9; Parameters:
10; DL: Drive to boot from (translated, 00h or 80h)
11; DS: RAMVARS segment
12; Returns:
13; Nothing
14; Corrupts registers:
[88]15; AX, SI
[3]16;--------------------------------------------------------------------
17ALIGN JUMP_ALIGN
18BootPrint_TryToBootFromDL:
[88]19 push bp
20 mov bp, sp
[3]21
[88]22 mov ax, g_szHardDrv
23 test dl, 80h
24 eCMOVZ ax, g_szFloppyDrv
25 push ax ; "Hard Drive" or "Floppy Drive"
26
[3]27 call DriveXlate_ToOrBack
28 push dx ; Push untranslated drive number
[88]29 call DriveXlate_ToOrBack
30 push dx ; Push translated drive number
[3]31
32 mov si, g_szTryToBoot
[88]33 jmp BootMenuPrint_FormatCSSIfromParamsInSSBP
[3]34
35
36;--------------------------------------------------------------------
37; BootPrint_BootSectorLoaded
38; Parameters:
39; Nothing
40; Returns:
41; Nothing
42; Corrupts registers:
[88]43; AX, SI
[3]44;--------------------------------------------------------------------
45ALIGN JUMP_ALIGN
46BootPrint_BootSectorLoaded:
[88]47 push bp
48 mov bp, sp
49 ePUSH_T ax, g_szBootSector
[3]50 ePUSH_T ax, g_szFound
[88]51 jmp SHORT PrintBootSectorResult
[3]52
53;--------------------------------------------------------------------
54; BootPrint_FirstSectorNotBootable
55; Parameters:
56; Nothing
57; Returns:
58; Nothing
59; Corrupts registers:
[88]60; AX, SI
[3]61;--------------------------------------------------------------------
62ALIGN JUMP_ALIGN
63BootPrint_FirstSectorNotBootable:
[88]64 push bp
65 mov bp, sp
66 ePUSH_T ax, g_szBootSector
[3]67 ePUSH_T ax, g_szNotFound
[88]68PrintBootSectorResult:
[3]69 mov si, g_szSectRead
[88]70 jmp BootMenuPrint_FormatCSSIfromParamsInSSBP
[3]71
72
73;--------------------------------------------------------------------
74; BootPrint_FailedToLoadFirstSector
75; Parameters:
76; AH: INT 13h error code
77; Returns:
78; Nothing
79; Corrupts registers:
[88]80; AX, CX, SI
[3]81;--------------------------------------------------------------------
82ALIGN JUMP_ALIGN
83BootPrint_FailedToLoadFirstSector:
[88]84 push bp
85 mov bp, sp
[3]86 eMOVZX cx, ah ; Error code to CX
87 push cx ; Push INT 13h error code
88 mov si, g_szReadError
[88]89 jmp BootMenuPrint_FormatCSSIfromParamsInSSBP
Note: See TracBrowser for help on using the repository browser.