Changeset 426 in xtideuniversalbios


Ignore:
Timestamp:
May 16, 2012, 5:29:06 PM (13 years ago)
Author:
aitotat@…
google:author:
aitotat@gmail.com
Message:

Changes to BIOS Drive Information Tool:

  • Small fixes and improvements to display output.
Location:
trunk/BIOS_Drive_Information_Tool/Src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/BIOS_Drive_Information_Tool/Src/AtaInfo.asm

    r424 r426  
    6464.SkipLBA48:
    6565
     66    ; Print block mode information
     67    call    DisplayBlockModeInformationUsingAtaInfoFromDSBX
     68
     69    ; Print PIO mode information
     70    call    DisplayPioModeInformationUsingAtaInfoFromDSBX
     71
    6672    ; Print L-CHS generated by XTIDE Universal BIOS
    6773    call    DisplayXTUBcompatibilityInfoUsingAtaInfoFromDSBX
    68 
    69     ; Print block mode information
    70     call    DisplayBlockModeInformationUsingAtaInfoFromDSBX
    71 
    72     ; Print PIO mode information
    73     call    DisplayPioModeInformationUsingAtaInfoFromDSBX
    7474
    7575.SkipAtaInfoSinceError:
     
    166166
    167167;--------------------------------------------------------------------
    168 ; DisplayXTUBcompatibilityInfoUsingAtaInfoFromDSBX
    169 ;   Parameters:
    170 ;       BX:     Offset to ATA Information
    171 ;   Returns:
    172 ;       Nothing
    173 ;   Corrupts registers:
    174 ;       AX, CX, DX, BP, SI, DI
    175 ;--------------------------------------------------------------------
    176 DisplayXTUBcompatibilityInfoUsingAtaInfoFromDSBX:
    177     push    bx
    178 
    179     ; Display header
    180     mov     ax, g_szXTUBversion
    181     mov     si, g_szXTUB
    182     call    Print_FormatStringFromSIwithParameterInAX
    183 
    184     ; Display translation mode and L-CHS
    185     mov     si, bx              ; DS == ES
    186     mov     dx, TRANSLATEMODE_AUTO
    187     call    AtaGeometry_GetLCHStoAXBLBHfromAtaInfoInESSIandTranslateModeInDX
    188     dec     ax                  ; Reserve diagnostics cylinder
    189     MIN_U   ax, MAX_LCHS_CYLINDERS
    190     call    Print_ModeFromDLandCHSfromAXLBH
    191 
    192     pop     bx
    193     ret
    194 
    195 
    196 ;--------------------------------------------------------------------
    197168; DisplayBlockModeInformationUsingAtaInfoFromDSBX
    198169;   Parameters:
     
    205176DisplayBlockModeInformationUsingAtaInfoFromDSBX:
    206177    eMOVZX  ax, BYTE [bx+ATA1.bBlockSel]    ; ATA2+ has flag on high word
    207     mov     dx, [bx+ATA1.bBlckSize]
     178    eMOVZX  dx, BYTE [bx+ATA1.bBlckSize]
    208179    mov     si, g_szBlockMode
    209180    jmp     Print_FormatStringFromSIwithParametersInAXDX
     
    247218    dw      PIO_1_MIN_CYCLE_TIME_NS
    248219    dw      PIO_2_MIN_CYCLE_TIME_NS
     220
     221
     222;--------------------------------------------------------------------
     223; DisplayXTUBcompatibilityInfoUsingAtaInfoFromDSBX
     224;   Parameters:
     225;       BX:     Offset to ATA Information
     226;   Returns:
     227;       Nothing
     228;   Corrupts registers:
     229;       AX, BX, CX, DX, BP, SI, DI
     230;--------------------------------------------------------------------
     231DisplayXTUBcompatibilityInfoUsingAtaInfoFromDSBX:
     232    ; Display header
     233    mov     ax, g_szXTUBversion
     234    mov     si, g_szXTUB
     235    call    Print_FormatStringFromSIwithParameterInAX
     236
     237    ; Display translation mode and L-CHS
     238    mov     si, bx              ; DS == ES
     239    mov     dx, TRANSLATEMODE_AUTO
     240    call    AtaGeometry_GetLCHStoAXBLBHfromAtaInfoInESSIandTranslateModeInDX
     241    dec     ax                  ; Reserve diagnostics cylinder
     242    MIN_U   ax, MAX_LCHS_CYLINDERS
     243    jmp     Print_ModeFromDLandCHSfromAXLBH
  • trunk/BIOS_Drive_Information_Tool/Src/Print.asm

    r424 r426  
    140140    mov     bp, sp
    141141
    142     xor     dh, dh
    143     mov     si, dx
    144     shl     si, 1       ; Shift for WORD lookup
    145     push    WORD [si+.rgszXlateModeToString]
    146 
     142    ; Push CHS parameters
    147143    ePUSH_T si, g_szFormatCHS
    148144    push    ax          ; Cylinders
     
    152148    push    ax          ; Sectors per track
    153149
    154     mov     si, g_szXlateAndCHS
     150    ; Push translation mode
     151    xor     dh, dh
     152    mov     si, dx
     153    shl     si, 1       ; Shift for WORD lookup
     154    push    WORD [si+.rgszXlateModeToString]
     155
     156    mov     si, g_szChsAndMode
    155157    jmp     SHORT JumpToFormatNullTerminatedStringFromSI
    156158
     
    181183    mov     si, g_szFormatCHS
    182184    CALL_DISPLAY_LIBRARY    FormatNullTerminatedStringFromCSSI
     185    CALL_DISPLAY_LIBRARY    PrintNewlineCharacters
    183186
    184187    pop     si
  • trunk/BIOS_Drive_Information_Tool/Src/Strings.asm

    r424 r426  
    3131
    3232g_szAtaInfoHeader:  db  "ATA-information from AH=25h...",CR,LF,NULL
    33 g_szFormatDrvName:  db  " Name: %s",CR,LF,NULL
    34 g_szXlateAndCHS:    db  " Mode: %s, %s",NULL
     33g_szFormatDrvName:  db  " Name         : %s",CR,LF,NULL
     34g_szChsAndMode:     db  "%s, Mode: %s",CR,LF,NULL
    3535g_szNormal:         db  "NORMAL",NULL
    3636g_szLarge:          db  "LARGE ",NULL
    3737g_szLBA:            db  "LBA   ",NULL
    38 g_szFormatCHS:      db  " Cylinders    : %5-u, Heads: %3-u, Sectors: %2-u",CR,LF,NULL
     38g_szFormatCHS:      db  " Cylinders    : %5u, Heads: %3u, Sectors: %2u",NULL
    3939g_szChsSectors:     db  " CHS   sectors: ",NULL
    4040g_szLBA28:          db  " LBA28 sectors: ",NULL
    4141g_szLBA48:          db  " LBA48 sectors: ",NULL
    42 g_szBlockMode:      db  " Block set    : %u, Max block: %u sectors",CR,LF,NULL
    43 g_szPIO:            db  " Max PIO mode : %u, Min cycle time without IORDY %u, with IORDY %d ns",CR,LF,NULL
     42g_szBlockMode:      db  " Block mode   : Set to %u from max %u sectors",CR,LF,NULL
     43g_szPIO:            db  " PIO mode     : Max %u, Min cycle times: %u ns, with IORDY %d ns",CR,LF,NULL
    4444g_szXTUB:           db  "XTIDE Universal BIOS %s generates following L-CHS...",CR,LF,NULL
    4545g_szXTUBversion:    db  ROM_VERSION_STRING  ; This one is NULL terminated
Note: See TracChangeset for help on using the changeset viewer.