Changeset 199 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Device/Serial


Ignore:
Timestamp:
Nov 21, 2011, 11:01:08 AM (13 years ago)
Author:
gregli@…
google:author:
gregli@hotmail.com
Message:

Adding proper serial port support to the Configurator, which required some minor changes elsewhere. Also added an option, off by default, to automatically scan for serial drives at the end of normal drive detection (no ALT key required, although that is still available if the option is off).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Src/Device/Serial/SerialCommand.asm

    r196 r199  
    119119        mov     cl, dl
    120120
    121         and     cl, SerialCommand_PackedPortAndBaud_BaudMask
     121        and     cl, DEVICE_SERIAL_PACKEDPORTANDBAUD_BAUDMASK
    122122        shl     cl, 1
    123123        mov     ch, SerialCommand_UART_divisorLow_startingBaud
     
    125125        adc     ch, 0
    126126
    127         and     dl, SerialCommand_PackedPortAndBaud_PortMask
     127        and     dl, DEVICE_SERIAL_PACKEDPORTANDBAUD_PORTMASK
    128128        mov     dh, 0
    129129        shl     dx, 1           ; port offset already x4, needs one more shift to be x8
    130         add     dx, SerialCommand_PackedPortAndBaud_StartingPort
     130        add     dx, DEVICE_SERIAL_PACKEDPORTANDBAUD_STARTINGPORT
    131131
    132132;
     
    501501SerialCommand_IdentifyDeviceToBufferInESSIwithDriveSelectByteInBH:
    502502
    503         mov     dl,[cs:bp+IDEVARS.bSerialPackedPortAndBaud]
     503        mov     dx,[cs:bp+IDEVARS.bSerialCOMDigit]
    504504        test    dl,dl
    505505        jz      SerialCommand_AutoSerial
    506506
     507        xchg    dh,dl           ; dh (the COM character to print) will be transmitted to the server,
     508                                ; so we know this is not an auto detect
     509       
    507510; fall-through
    508511SerialCommand_IdentifyDeviceInDL_DriveInBH:
     
    543546;
    544547
    545 SerialCommand_ScanPortAddresses:     db  0b8h, 0f8h, 0bch, 0bah, 0fah, 0beh, 0feh, 0
    546 ; Corresponds to I/O port:                3f8,  2f8,  3e8,  2e8,  2f0,  3e0,  2e0,  260,  368,  268,  360,  270
    547 ; COM Assignments:                          1,    2,    3,    4,    5,    6,    7,    8,    9,   10,   11,   12
    548 ; Corresponds to Packed I/O port (hex):    37,   17,   35,   15,   16,   34,   14,    4,   25,    5,   24,    6     
     548SerialCommand_ScanPortAddresses:    db  DEVICE_SERIAL_COM7 >> 2
     549                                    db  DEVICE_SERIAL_COM6 >> 2
     550                                    db  DEVICE_SERIAL_COM5 >> 2
     551                                    db  DEVICE_SERIAL_COM4 >> 2
     552                                    db  DEVICE_SERIAL_COM3 >> 2
     553                                    db  DEVICE_SERIAL_COM2 >> 2
     554                                    db  DEVICE_SERIAL_COM1 >> 2
     555                                    db  0
    549556
    550557ALIGN JUMP_ALIGN
     
    581588; Pack into dl, baud rate starts at 0
    582589;
    583         add     dx,-(SerialCommand_PackedPortAndBaud_StartingPort)
    584         shr     dx,1
     590        add     dx,-(DEVICE_SERIAL_PACKEDPORTANDBAUD_STARTINGPORT)
     591        shr     dx,1            ; dh is zero at this point, and will be sent to the server,
     592                                ; so we know this is an auto detect
    585593
    586594        jmp     .testFirstBaud
Note: See TracChangeset for help on using the changeset viewer.