Changeset 200 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Initialization
- Timestamp:
- Nov 22, 2011, 8:38:36 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
r199 r200 20 20 call RamVars_GetIdeControllerCountToCX 21 21 mov bp, ROMVARS.ideVars0 ; CS:BP now points to first IDEVARS 22 .DriveDetectLoop: 23 mov si, g_szDetect 22 23 .DriveDetectLoop: ; Loop through IDEVARS 24 mov si, g_szDetect ; Setup standard print string 24 25 %ifdef MODULE_SERIAL 25 26 cmp byte [cs:bp+IDEVARS.bDevice], DEVICE_SERIAL_PORT 26 jnz .DriveNotSerial 27 jnz .DriveNotSerial ; Special print string for serial drives 27 28 mov si, g_szDetectCOM 28 29 .DriveNotSerial: … … 31 32 add bp, BYTE IDEVARS_size ; Point to next IDEVARS 32 33 loop .DriveDetectLoop 34 33 35 %ifdef MODULE_SERIAL 34 mov al,[cs:ROMVARS.wFlags] 35 or al,[es:BDA.bKBFlgs1] 36 and al,8 ; 8 = alt key depressed, same as FLG_ROMVARS_SERIAL_ALWAYSDETECT 37 jz .done 38 mov bp, ROMVARS.ideVarsSerialAuto 39 mov si, g_szDetectCOMAuto 36 call FindDPT_ToDSDIforSerialDevice ; Did we already find any serial drives? 37 jc .done ; Yes, do not scan 38 mov al,[cs:ROMVARS.wFlags] ; Configurator set to always scan? 39 or al,[es:BDA.bKBFlgs1] ; Or, did the user hold down the ALT key? 40 and al,8 ; 8 = alt key depressed, same as FLG_ROMVARS_SERIAL_ALWAYSDETECT 41 jz .done 42 mov bp, ROMVARS.ideVarsSerialAuto ; Point to our special IDEVARS sructure, just for serial scans 43 mov si, g_szDetectCOMAuto ; Special, special print string for serial drives during a scan 40 44 ;;; fall-through 41 45 %else … … 44 48 45 49 %if FLG_ROMVARS_SERIAL_SCANDETECT != 8 46 %error "DetectDrives is currently coded to assume that FLG_ROMVARS_SERIAL_ ALWAYSDETECT is the same bit as the ALT key code in the BDA. Changes in the code will be needed if these values are no longer the same."50 %error "DetectDrives is currently coded to assume that FLG_ROMVARS_SERIAL_SCANDETECT is the same bit as the ALT key code in the BDA. Changes in the code will be needed if these values are no longer the same." 47 51 %endif 48 52 … … 70 74 pop si 71 75 76 %ifdef MODULE_SERIAL 77 ; 78 ; This block of code checks to see if we found a master during a serial drives scan. If no master 79 ; was found, there is no point in scanning for a slave as the server will not return a slave without a master, 80 ; as there is very little point given the drives are emulated. Performing the slave scan will take 81 ; time to rescan all the COM port and baud rate combinations. 82 ; 83 jnc .masterFound 84 pop cx 85 jcxz .done ; note that CX will only be zero after the .DriveDetectLoop, indicating a serial scan 86 push cx 87 .masterFound: 88 %endif 89 72 90 mov ax, g_szSlave 73 91 mov bh, MASK_DRVNHEAD_SET | FLG_DRVNHEAD_DRV 74 92 call StartDetectionWithDriveSelectByteInBHandStringInAX 75 93 pop cx 94 76 95 .done: 77 96 ret … … 87 106 ; ES: Zero (BDA segment) 88 107 ; Returns: 89 ; Nothing 108 ; CF: Set on failure, Clear on success 109 ; Note that this is set in the last thing both cases 110 ; do: printing the drive name, or printing "Not Found" 90 111 ; Corrupts registers: 91 112 ; AX, BX, CX, DX, SI, DI … … 150 171 ; Nothing 151 172 ; Returns: 152 ; Nothing173 ; CF: Set (from BootMenuPrint_NullTerminatedStringFromCSSIandSetCF) 153 174 ; Corrupts registers: 154 175 ; AX, SI -
trunk/XTIDE_Universal_BIOS/Src/Initialization/DetectPrint.asm
r199 r200 88 88 pop bx 89 89 pop di 90 clc ; return success up through DetectDrives 90 91 ret 91 92
Note:
See TracChangeset
for help on using the changeset viewer.