Changeset 196 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Initialization
- Timestamp:
- Nov 19, 2011, 11:18:39 AM (13 years ago)
- google:author:
- gregli@hotmail.com
- Location:
- trunk/XTIDE_Universal_BIOS/Src/Initialization
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/Initialization/DetectDrives.asm
r189 r196 21 21 mov bp, ROMVARS.ideVars0 ; CS:BP now points to first IDEVARS 22 22 .DriveDetectLoop: 23 mov si,g_szDetect 23 mov si, g_szDetect 24 %ifdef MODULE_SERIAL 25 cmp byte [cs:bp+IDEVARS.bDevice], DEVICE_SERIAL_PORT 26 jnz .DriveNotSerial 27 mov si, g_szDetectCOM 28 .DriveNotSerial: 29 %endif 24 30 call .DetectDrives_WithIDEVARS ; Detect Master and Slave 25 31 add bp, BYTE IDEVARS_size ; Point to next IDEVARS … … 30 36 jz .done 31 37 mov bp, ROMVARS.ideVarsSerialAuto 32 mov si, g_szSerial38 mov si, g_szDetectCOMAuto 33 39 ;;; fall-through 34 40 %else … … 52 58 .DetectDrives_WithIDEVARS: 53 59 push cx 54 55 push si 60 61 push si 56 62 mov ax, g_szMaster 57 63 mov bh, MASK_DRVNHEAD_SET ; Select Master drive 58 64 call StartDetectionWithDriveSelectByteInBHandStringInAX ; Detect and create DPT + BOOTNFO 59 65 pop si 60 66 61 67 mov ax, g_szSlave 62 68 mov bh, MASK_DRVNHEAD_SET | FLG_DRVNHEAD_DRV … … 112 118 ;call ReadAtapiInfoFromDrive ; Assume CD-ROM 113 119 ;jnc SHORT _CreateBiosTablesForCDROM 114 jmp DetectPrint_DriveNotFound120 jmp short DetectDrives_DriveNotFound 115 121 116 122 … … 130 136 CreateBiosTablesForHardDisk: 131 137 call CreateDPT_FromAtaInformation 132 jc SHORT .InvalidAtaInfo138 jc SHORT DetectDrives_DriveNotFound 133 139 call BootInfo_CreateForHardDisk 134 jmp DetectPrint_DriveNameFromBootnfoInESBX 135 .InvalidAtaInfo: 136 jmp DetectPrint_DriveNotFound 140 jmp short DetectPrint_DriveNameFromBootnfoInESBX 141 142 ;-------------------------------------------------------------------- 143 ; DetectDrives_DriveNotFound 144 ; Parameters: 145 ; Nothing 146 ; Returns: 147 ; Nothing 148 ; Corrupts registers: 149 ; AX, SI 150 ;-------------------------------------------------------------------- 151 DetectDrives_DriveNotFound: 152 mov si, g_szNotFound 153 jmp BootMenuPrint_NullTerminatedStringFromCSSIandSetCF 154 -
trunk/XTIDE_Universal_BIOS/Src/Initialization/DetectPrint.asm
r192 r196 36 36 ; Nothing 37 37 ; Corrupts registers: 38 ; AX, SI, DI 38 ; AX, SI, DI, CX 39 39 ;-------------------------------------------------------------------- 40 40 DetectPrint_StartDetectWithMasterOrSlaveStringInAXandIdeVarsInCSBP: 41 41 push bp 42 42 mov di, [cs:bp+IDEVARS.wPort] 43 %ifdef MODULE_SERIAL 44 mov cx, [cs:bp+IDEVARS.wSerialPackedPrintBaud] 45 %endif 46 43 47 mov bp, sp 44 push ax ; Push "Master" or "Slave" 45 push di ; Push port number 46 jmp DetectPrint_BootMenuPrint_FormatCSSIfromParamsInSSBP_Relay 48 49 push ax ; Push "Master" or "Slave" 50 51 push di ; Push Port address or COM port number 52 53 %ifdef MODULE_SERIAL 54 ; 55 ; Baud rate is packed into one word: 56 ; High order 6 bits: number to add to '0' to get postfix character ('0' or 'K') 57 ; Low order 10 bits: binary number to display (960, 240, 38, or 115) 58 ; To get 9600: '0'<<10 + 960 59 ; To get 2400: '0'<<10 + 240 60 ; To get 38K: ('K'-'0')<<10 + 38 61 ; To get 115K: ('K'-'0')<<10 + 115 62 ; 63 mov ax,cx ; Unpack baud rate number 64 and ax,03ffh 65 push ax 66 67 mov al,ch ; Unpack baud rate postfix ('0' or 'K') 68 eSHR_IM al,2 69 add al,'0' 70 push ax 71 %endif 72 73 jmp short DetectPrint_BootMenuPrint_FormatCSSIfromParamsInSSBP_Relay 47 74 48 75 … … 70 97 71 98 72 ;-------------------------------------------------------------------- 73 ; DetectPrint_DriveNotFound 74 ; Parameters: 75 ; Nothing 76 ; Returns: 77 ; Nothing 78 ; Corrupts registers: 79 ; AX, SI 80 ;-------------------------------------------------------------------- 81 DetectPrint_DriveNotFound: 82 mov si, g_szNotFound 83 jmp BootMenuPrint_NullTerminatedStringFromCSSIandSetCF 99
Note:
See TracChangeset
for help on using the changeset viewer.