Ignore:
Timestamp:
Nov 19, 2011, 11:18:39 AM (12 years ago)
Author:
gregli@…
google:author:
gregli@hotmail.com
Message:

Added printing of COM port and baud rate, when set explicitly by idecfg. Although it eats some bytes, I think it is worth it, since the BIOS will be looking for a server on a particular com port and baud rate, and it could be hard to troubleshoot a mismatch without this information. However, if we become space crunched, this change can be backed out.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Src/Initialization/DetectPrint.asm

    r192 r196  
    3636;       Nothing
    3737;   Corrupts registers:
    38 ;       AX, SI, DI
     38;       AX, SI, DI, CX
    3939;--------------------------------------------------------------------
    4040DetectPrint_StartDetectWithMasterOrSlaveStringInAXandIdeVarsInCSBP:
    4141    push    bp
    4242    mov     di, [cs:bp+IDEVARS.wPort]
     43%ifdef MODULE_SERIAL
     44    mov     cx, [cs:bp+IDEVARS.wSerialPackedPrintBaud]
     45%endif
     46       
    4347    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   
    4774
    4875
     
    7097
    7198
    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.