Changeset 293 in xtideuniversalbios


Ignore:
Timestamp:
Mar 4, 2012, 1:33:52 AM (12 years ago)
Author:
krille_n_@…
google:author:
krille_n_@hotmail.com
Message:

Commit 1/2 (Library, Configurators and Serial Server):

  • Changed Emulate.inc so that making 286 and 386 versions now works. Additionally, only one processor type define is needed in the makefile.
  • Minor optimizations.
  • Fixed spelling and did some cleaning.
Location:
trunk
Files:
39 edited

Legend:

Unmodified
Added
Removed
  • trunk/Assembly_Library/Inc/Emulate.inc

    r223 r293  
    11; Project name  :   Emulation library
    2 ; Description   :   Macros for emulating later x86 instruction with older
     2; Description   :   Macros for emulating later x86 instructions with older
    33;                   processors.
    4 ;                   Macros are used so optimized builds could be done
     4;                   Macros are used so optimized builds can be done
    55;                   easily for different processors.
    66;
     
    1010%define EMULATE_INC
    1111
    12 ; Defines for processor support. Unsupported instructions will be
    13 ; emulated using macros.
    14 ; If using 286, define USE_186 and USE_286
    15 ; If using 386, define USE_186, USE_286 and USE_386
     12; Defines for processor support (should be set in makefile).
     13; Unsupported instructions will be emulated using macros.
    1614; If AT class PC is used (instead of XT), define USE_AT
     15
    1716;%define USE_186                ; Define to use 18x/V20/V30 instructions
    1817;%define USE_286                ; Define to use 286 instructions
    1918;%define USE_386                ; Define to use 386 instructions
    2019;%define USE_AT                 ; Define for AT class machine
    21 ; Above defines should be set on makefile!
    22 
    23 CPU 8086                        ; Allow 8088/8086 instructions only
    24 %ifdef USE_186
    25 CPU 186                         ; Allow instructions up to 188/186/V20/V30
     20
     21%ifdef USE_386
     22    %define USE_286             ; Define to use 286 instructions
     23%endif
     24%ifdef USE_286
     25    %define USE_186             ; Define to use 18x/V20/V30 instructions
     26%endif
     27
     28%ifdef USE_386
     29    CPU 386                     ; Allow instructions up to 386
    2630%elifdef USE_286
    27 CPU 286                         ; Allow instructions up to 286
    28 %elifdef USE_386
    29 CPU 386                         ; Allow instructions up to 386
    30 %endif
     31    CPU 286                     ; Allow instructions up to 286
     32%elifdef USE_186
     33    CPU 186                     ; Allow instructions up to 188/186/V20/V30
     34%else
     35    CPU 8086                    ; Allow 8088/8086 instructions only
     36%endif
     37
    3138BITS 16                         ; Set 16 bit code generation
    3239
  • trunk/Assembly_Library/Src/File/FileIO.asm

    r133 r293  
    3636;   Returns:
    3737;       AX:     DOS error code if CF set
    38 ;       CF:     Clear if successfull
     38;       CF:     Clear if successful
    3939;               Set if error
    4040;   Corrupts registers:
     
    5959;       DS:SI:  Ptr to destination buffer
    6060;   Returns:
    61 ;       AX:     Number of bytes actually read if successfull (0 if at EOF before call)
     61;       AX:     Number of bytes actually read if successful (0 if at EOF before call)
    6262;               DOS error code if CF set
    63 ;       CF:     Clear if successfull
     63;       CF:     Clear if successful
    6464;               Set if error
    6565;   Corrupts registers:
     
    8383;   Returns:
    8484;       AX:     DOS error code if CF set
    85 ;       CF:     Clear if successfull
     85;       CF:     Clear if successful
    8686;               Set if error
    8787;   Corrupts registers:
     
    106106;       DS:SI:  Ptr to source buffer
    107107;   Returns:
    108 ;       AX:     Number of bytes actually written if successfull (EOF check)
     108;       AX:     Number of bytes actually written if successful (EOF check)
    109109;               DOS error code if CF set
    110 ;       CF:     Clear if successfull
     110;       CF:     Clear if successful
    111111;               Set if error
    112112;   Corrupts registers:
     
    131131;   Returns:
    132132;       AX:     DOS error code if CF set
    133 ;       CF:     Clear if successfull
     133;       CF:     Clear if successful
    134134;               Set if error
    135135;   Corrupts registers:
     
    200200;       DX:AX:  Signed file size (if CF cleared)
    201201;       AX:     DOS error code (if CF set)
    202 ;       CF:     Clear if successfull
     202;       CF:     Clear if successful
    203203;               Set if error
    204204;   Corrupts registers:
     
    257257;       DX:AX:  New file position in bytes from start of file (if CF cleared)
    258258;       AX:     DOS error code (if CF set)
    259 ;       CF:     Clear if successfull
     259;       CF:     Clear if successful
    260260;               Set if error
    261261;   Corrupts registers:
  • trunk/Assembly_Library/Src/Menu/Dialog/DialogFile.asm

    r181 r293  
    173173
    174174    lds     si, [bp+DIALOG.fpDialogIO]
    175     eMOVZX  cx, BYTE [si+FILE_DIALOG_IO.bFileAttributes]
     175    eMOVZX  cx, [si+FILE_DIALOG_IO.bFileAttributes]
    176176    lds     si, [si+FILE_DIALOG_IO.fpFileFilterString]
    177177    call    Directory_UpdateDTAForFirstMatchForDSSIwithAttributesInCX
     
    518518    xor     ax, ax
    519519    stosb                       ; Terminate with NULL
    520     jmp     SHORT CloseFileDialogAfterSuccessfullSelection
     520    jmp     SHORT CloseFileDialogAfterSuccessfulSelection
    521521
    522522;--------------------------------------------------------------------
     
    617617    test    al, al      ; User cancellation?
    618618    jnz     SHORT ReturnWithoutHandlingKeystroke
    619     jmp     CloseFileDialogAfterSuccessfullSelection
     619    jmp     CloseFileDialogAfterSuccessfulSelection
    620620
    621621ALIGN JUMP_ALIGN
     
    646646    test    al, FLG_FILEDIALOG_DIRECTORY
    647647    jz      SHORT ReturnWithoutHandlingKeystroke
    648     ; Fall to CloseFileDialogAfterSuccessfullSelection
    649 
    650 ;--------------------------------------------------------------------
    651 ; CloseFileDialogAfterSuccessfullSelection
     648    ; Fall to CloseFileDialogAfterSuccessfulSelection
     649
     650;--------------------------------------------------------------------
     651; CloseFileDialogAfterSuccessfulSelection
    652652;   Parameters:
    653653;       SS:BP:  Ptr to DIALOG
     
    658658;--------------------------------------------------------------------
    659659ALIGN JUMP_ALIGN
    660 CloseFileDialogAfterSuccessfullSelection:
     660CloseFileDialogAfterSuccessfulSelection:
    661661    lds     di, [bp+DIALOG.fpDialogIO]
    662662    mov     BYTE [di+FILE_DIALOG_IO.bUserCancellation], FALSE
  • trunk/Assembly_Library/Src/Menu/Dialog/DialogWord.asm

    r58 r293  
    8585GetWordFromUser:
    8686    lds     si, [bp+DIALOG.fpDialogIO]
    87     eMOVZX  bx, BYTE [si+WORD_DIALOG_IO.bNumericBase]
     87    eMOVZX  bx, [si+WORD_DIALOG_IO.bNumericBase]
    8888ALIGN JUMP_ALIGN
    8989.GetUserInputIntilValidOrCancelled:
  • trunk/Assembly_Library/Src/Menu/MenuBorders.asm

    r223 r293  
    118118ALIGN JUMP_ALIGN
    119119MenuBorders_GetNumberOfMiddleCharactersToDX:
    120     eMOVZX  dx, BYTE [bp+MENUINIT.bWidth]
     120    eMOVZX  dx, [bp+MENUINIT.bWidth]
    121121    sub     dx, BYTE MENU_HORIZONTAL_BORDER_LINES
    122122    ret
     
    136136RefreshTitleBorders:
    137137    call    DrawTopBorderLine
    138     eMOVZX  cx, BYTE [bp+MENUINIT.bTitleLines]
     138    eMOVZX  cx, [bp+MENUINIT.bTitleLines]
    139139    jmp     SHORT DrawTextBorderLinesByCXtimes
    140140
     
    152152RefreshInformationBorders:
    153153    call    DrawSeparationBorderLine
    154     eMOVZX  cx, BYTE [bp+MENUINIT.bInfoLines]
     154    eMOVZX  cx, [bp+MENUINIT.bInfoLines]
    155155    jmp     SHORT DrawTextBorderLinesByCXtimes
    156156
  • trunk/Assembly_Library/Src/Menu/MenuCharOut.asm

    r104 r293  
    6161    mov     al, CR
    6262    call    DisplayCharOut_BiosTeletypeOutput
    63     eMOVZX  ax, BYTE [VIDEO_BDA.displayContext+DISPLAY_CONTEXT.wCharOutParam]
     63    eMOVZX  ax, [VIDEO_BDA.displayContext+DISPLAY_CONTEXT.wCharOutParam]
    6464    add     di, ax
    6565ReturnSinceNoNeedToStartLineWithControlCharacter:
  • trunk/Assembly_Library/Src/Menu/MenuLocation.asm

    r181 r293  
    114114ALIGN JUMP_ALIGN
    115115MenuLocation_GetMaxTextLineLengthToAX:
    116     eMOVZX  ax, BYTE [bp+MENUINIT.bWidth]
     116    eMOVZX  ax, [bp+MENUINIT.bWidth]
    117117    sub     ax, BYTE MENU_HORIZONTAL_BORDER_LINES + MENU_TEXT_COLUMN_OFFSET
    118118    ret
  • trunk/Assembly_Library/Src/Menu/MenuScrollbars.asm

    r181 r293  
    245245ALIGN JUMP_ALIGN
    246246MenuScrollbars_GetMaxVisibleItemsOnPageToCX:
    247     eMOVZX  cx, BYTE [bp+MENUINIT.bHeight]
     247    eMOVZX  cx, [bp+MENUINIT.bHeight]
    248248    sub     cl, [bp+MENUINIT.bTitleLines]
    249249    sub     cl, [bp+MENUINIT.bInfoLines]
  • trunk/Assembly_Library/Src/Serial/SerialServer.asm

    r292 r293  
    33
    44%include "SerialServer.inc"
    5        
     5
    66; Section containing code
    77SECTION .text
    88
    99;--------------------------------------------------------------------
    10 ; SerialServer_SendReceive:     
     10; SerialServer_SendReceive:
    1111;   Parameters:
    1212;       DX:     Packed I/O port and baud rate
     
    2020;       AL, BX, CX, DX
    2121;--------------------------------------------------------------------
    22 SerialServer_SendReceive:       
    23        
     22SerialServer_SendReceive:
     23
    2424        push    si
    2525        push    di
     
    3737        mov     al,[bp+SerialServer_Command.bSectorCount]
    3838        mov     ah,[bp+SerialServer_Command.bCommand]
    39        
     39
    4040;
    4141; Command byte and sector count live at the top of the stack, pop/push are used to access
     
    4444        push    ax              ; working copy on the top of the stack
    4545
     46%ifndef EXCLUDE_FROM_XTIDE_UNIVERSAL_BIOS   ; DF already cleared in Int13h.asm
    4647        cld
     48%endif
    4749
    4850;----------------------------------------------------------------------
     
    121123        jz      .zeroSectors
    122124%endif
    123        
     125
    124126;
    125127; Top of the read/write loop, one iteration per sector
     
    278280%endif
    279281        mov     ah, al          ;  for success, AL will already be zero
    280        
     282
    281283        pop     bx              ;  recover "ax" (command and count) from stack
    282284        pop     cx              ;  recover saved sector count
    283         mov     ch, 0
     285        xor     ch, ch
    284286        sub     cl, bl          ; subtract off the number of sectors that remained
    285287
     
    366368
    367369.writeTimeout1:
    368 %ifndef USE_186
    369         mov     ax,.writeByte1Ready
    370         push    ax              ; return address for ret at end of SC_writeTimeout2
    371 %else
    372         push    .writeByte1Ready
    373 %endif
     370        ePUSH_T ax, .writeByte1Ready    ; return address for ret at end of SC_writeTimeout2
    374371;;; fall-through
    375372
     
    381378;               One entry point fills in AH with 20h for write
    382379;       DX:     Port address (OK if already incremented to UART_lineStatus)
    383 ;       BX:     
     380;       BX:
    384381;       Stack:  2 words on the stack below the command/count word
    385382;   Returns:
     
    430427        pop     ax
    431428%endif
    432        
     429
    433430.WaitAndPoll:
    434431%ifndef SERIALSERVER_TIMER_LOCATION
     
    441438        pop     bx
    442439        pop     ax
    443 %endif     
     440%endif
    444441        jc      SerialServer_OutputWithParameters_ErrorAndPop4Words
    445442        in      al,dx
  • trunk/Assembly_Library/Src/String/String.asm

    r131 r293  
    3737;       CX:     Number of characters processed
    3838;       SI:     Updated
    39 ;       CF:     Cleared if successfull
     39;       CF:     Cleared if successful
    4040;               Set if error during conversion
    4141;   Corrupts registers:
  • trunk/Configurator/Inc/emulate.inc

    r223 r293  
    1 ; File name     :   emulate.inc
    21; Project name  :   Emulation library
    3 ; Created date  :   21.10.2009
    4 ; Last update   :   4.4.2010
    5 ; Author        :   Tomi Tilli
    6 ; Description   :   Macros for emulating later x86 instruction with older
     2; Description   :   Macros for emulating later x86 instructions with older
    73;                   processors.
    8 ;                   Macros are used so optimized builds could be done
     4;                   Macros are used so optimized builds can be done
    95;                   easily for different processors.
    106;
     
    1410%define EMULATE_INC
    1511
    16 ; Defines for processor support. Unsupported instructions will be
    17 ; emulated using macros.
    18 ; If using 286, define USE_186 and USE_286
    19 ; If using 386, define USE_186, USE_286 and USE_386
     12; Defines for processor support (should be set in makefile).
     13; Unsupported instructions will be emulated using macros.
    2014; If AT class PC is used (instead of XT), define USE_AT
     15
    2116;%define USE_186                ; Define to use 18x/V20/V30 instructions
    2217;%define USE_286                ; Define to use 286 instructions
    2318;%define USE_386                ; Define to use 386 instructions
    2419;%define USE_AT                 ; Define for AT class machine
    25 ; Above defines should be set on makefile!
    26 
    27 CPU 8086                        ; Allow 8088/8086 instructions only
    28 %ifdef USE_186
    29 CPU 186                         ; Allow instructions up to 188/186/V20/V30
     20
     21%ifdef USE_386
     22    %define USE_286             ; Define to use 286 instructions
     23%endif
     24%ifdef USE_286
     25    %define USE_186             ; Define to use 18x/V20/V30 instructions
     26%endif
     27
     28%ifdef USE_386
     29    CPU 386                     ; Allow instructions up to 386
    3030%elifdef USE_286
    31 CPU 286                         ; Allow instructions up to 286
    32 %elifdef USE_386
    33 CPU 386                         ; Allow instructions up to 386
    34 %endif
     31    CPU 286                     ; Allow instructions up to 286
     32%elifdef USE_186
     33    CPU 186                     ; Allow instructions up to 188/186/V20/V30
     34%else
     35    CPU 8086                    ; Allow 8088/8086 instructions only
     36%endif
     37
    3538BITS 16                         ; Set 16 bit code generation
    3639
  • trunk/Configurator/Src/EEPROM.asm

    r2 r293  
    1 ; File name     :   EEPROM.asm
    21; Project name  :   XTIDE Univeral BIOS Configurator
    3 ; Created date  :   19.4.2010
    4 ; Last update   :   2.5.2010
    5 ; Author        :   Tomi Tilli
    62; Description   :   Functions for managing EEPROM contents.
    73
     
    2521    call    EEPROM_FindXtideUniversalBiosROM
    2622    xor     si, si                                  ; Load from beginning of ROM
    27     eMOVZX  cx, BYTE [es:ROMVARS.bRomSize]
     23    eMOVZX  cx, [es:ROMVARS.bRomSize]
    2824    eSHL_IM cx, 9                                   ; *= 512 for byte count
    2925    call    EEPROM_LoadBytesFromROM
  • trunk/Configurator/Src/Flash.asm

    r2 r293  
    1 ; File name     :   Flash.asm
    21; Project name  :   XTIDE Univeral BIOS Configurator
    3 ; Created date  :   30.4.2010
    4 ; Last update   :   2.5.2010
    5 ; Author        :   Tomi Tilli
    62; Description   :   Function for flashing the EEPROM.
    73
     
    4642; Verifies that all data has been written successfully.
    4743;
    48 ; Flash_WasDataWriteSuccessfull
     44; Flash_WasDataWriteSuccessful
    4945;   Parameters:
    5046;       Nothing
     
    5652;--------------------------------------------------------------------
    5753ALIGN JUMP_ALIGN
    58 Flash_WasDataWriteSuccessfull:
     54Flash_WasDataWriteSuccessful:
    5955    push    ds
    6056    push    di
     
    218214;       ES:BP:  Ptr to EEPROM last write location
    219215;   Returns:
    220 ;       CF:     Cleared if polling successfull
     216;       CF:     Cleared if polling successful
    221217;               Set if polling timeout
    222218;   Corrupts registers:
  • trunk/Configurator/Src/Libraries/file.asm

    r162 r293  
    162162;       ES:DI:  Ptr to destination buffer
    163163;   Returns:
    164 ;       AX:     Number of bytes actually read if successfull (EOF check)
     164;       AX:     Number of bytes actually read if successful (EOF check)
    165165;               DOS error code if CF set
    166 ;       CF:     Clear if successfull
     166;       CF:     Clear if successful
    167167;               Set if error
    168168;   Corrupts registers:
     
    194194;       ES:DI:  Ptr to source buffer
    195195;   Returns:
    196 ;       AX:     Number of bytes actually written if successfull (EOF check)
     196;       AX:     Number of bytes actually written if successful (EOF check)
    197197;               DOS error code if CF set
    198 ;       CF:     Clear if successfull
     198;       CF:     Clear if successful
    199199;               Set if error
    200200;   Corrupts registers:
     
    224224;   Returns:
    225225;       AX:     DOS error code if CF set
    226 ;       CF:     Clear if successfull
     226;       CF:     Clear if successful
    227227;               Set if error
    228228;   Corrupts registers:
     
    373373;   Returns:
    374374;       AX:     DOS Error code
    375 ;       CF:     Clear if successfull
     375;       CF:     Clear if successful
    376376;               Set if error
    377377;   Corrupts registers:
  • trunk/Configurator/Src/Libraries/menu/menudraw.asm

    r181 r293  
    6161    push    cx
    6262    call    MenuCrsr_GetCursor              ; Get current cursor to DX
    63     eMOVZX  cx, BYTE [bp+MENUVARS.bWidth]   ; Load menu width
     63    eMOVZX  cx, [bp+MENUVARS.bWidth]        ; Load menu width
    6464    add     cl, [bp+MENUVARS.bInitX]        ; Add menu start X coord
    6565    sub     cl, W_OFF_CRSR_STR & 0FFh       ; Subtract right borders
     
    164164    call    MenuCrsr_Point1stItem           ; Set cursor position
    165165    mov     cx, [bp+MENUVARS.wItemTop]      ; Load idx of first menuitem to draw
    166     eMOVZX  dx, BYTE [bp+MENUVARS.bVisCnt]  ; Load number of visible menuitems
     166    eMOVZX  dx, [bp+MENUVARS.bVisCnt]       ; Load number of visible menuitems
    167167    MIN_U   dx, [bp+MENUVARS.wItemCnt]      ; Limit to item count
    168168    add     dx, cx                          ; One past last menuitem to draw
     
    266266    call    MenuDraw_TopBorder              ; Draw top border
    267267    call    MenuDraw_NewlineBrdr            ; Change line
    268     eMOVZX  cx, BYTE [bp+MENUVARS.bTitleH]  ; Load number of title strings
     268    eMOVZX  cx, [bp+MENUVARS.bTitleH]       ; Load number of title strings
    269269    jcxz    .Return                         ; Return if no title strings
    270270ALIGN JUMP_ALIGN
     
    284284    xor     dx, dx                          ; Zero DX
    285285    call    MenuCrsr_PointNfoBrdr           ; Set cursor
    286     eMOVZX  cx, BYTE [bp+MENUVARS.bInfoH]   ; Load number of info strings
     286    eMOVZX  cx, [bp+MENUVARS.bInfoH]        ; Load number of info strings
    287287    test    BYTE [bp+MENUVARS.bFlags], FLG_MNU_HIDENFO  ; Information hidden?
    288288    jnz     SHORT .JumpToBottomBorder
     
    320320    xor     dx, dx                          ; Zero DX
    321321    call    MenuCrsr_PointItemBrdr          ; Set cursor
    322     eMOVZX  cx, BYTE [bp+MENUVARS.bVisCnt]  ; Load max number of item strings
     322    eMOVZX  cx, [bp+MENUVARS.bVisCnt]       ; Load max number of item strings
    323323ALIGN JUMP_ALIGN
    324324.LineLoop:
     
    374374    mov     dl, bh                          ; Leftmost
    375375    PRINT_CHAR
    376     eMOVZX  cx, BYTE [bp+MENUVARS.bWidth]
     376    eMOVZX  cx, [bp+MENUVARS.bWidth]
    377377    times 2 dec cx                          ; Subtract borders
    378378    mov     dl, bl                          ; Middle
     
    438438    mov     dh, B_V                     ; Assume no scroll bars needed
    439439    mov     ax, [bp+MENUVARS.wItemCnt]  ; Load menuitem count to AX
    440     eMOVZX  bx, BYTE [bp+MENUVARS.bVisCnt]  ; Load visible menuitems to BX
     440    eMOVZX  bx, [bp+MENUVARS.bVisCnt]   ; Load visible menuitems to BX
    441441    cmp     ax, bx                      ; Need scroll bars?
    442442    jbe     .Return                     ;  If not, return
  • trunk/Configurator/Src/Libraries/menu/menufile.asm

    r83 r293  
    1 ; File name     :   menufile.asm
    21; Project name  :   Menu library
    3 ; Created date  :   20.11.2009
    4 ; Last update   :   6.1.2011
    5 ; Author        :   Tomi Tilli,
    6 ;               :   Krister Nordvall (Optimizations)
    7 ; Description   :   ASM library to menu system.
     2; Description   :   ASM library for menu system.
    83;                   Contains functions for displaying file dialog.
    94
     
    276271ALIGN JUMP_ALIGN
    277272.ChangeDone:
    278     mov     dx, [bp+FDLGVARS.fpFileSrch]    ; Load ptr to file search str
    279     mov     ds, [bp+FDLGVARS.fpFileSrch+2]
     273    lds     dx, [bp+FDLGVARS.fpFileSrch]    ; Load ptr to file search str
    280274    call    MenuFile_GetItemCnt             ; Get file count from new dir
    281275    pop     ds
     
    314308    mov     di, [bp+MSGVARS.wStrOff]        ; Load string offset
    315309    mov     es, [bp+MSGVARS.wStrSeg]        ; Load string segment
    316     eMOVZX  cx, BYTE [bp+MENUVARS.bInfoH]   ; Load info line count to CX
     310    eMOVZX  cx, [bp+MENUVARS.bInfoH]        ; Load info line count to CX
    317311    call    MenuDraw_MultilineStr           ; Draw multiline str
    318312    pop     di
  • trunk/Configurator/Src/Libraries/menu/menuloop.asm

    r9 r293  
    1 ; File name     :   menuloop.asm
    21; Project name  :   Menu library
    3 ; Created date  :   11.11.2009
    4 ; Last update   :   25.5.2010
    5 ; Author        :   Tomi Tilli
    6 ; Description   :   ASM library to menu system.
     2; Description   :   ASM library for menu system.
    73;                   Contains event dispatching loop.
    84
     
    143139
    144140    ; Jump to process menu key
    145     mov     di, CNT_MENU_KEYS-1 ; Convert CX... 
     141    mov     di, CNT_MENU_KEYS-1 ; Convert CX...
    146142    sub     di, cx              ; ...to lookup index
    147143    shl     di, 1               ; Prepare for word lookup
     
    186182    jnz     .TextScrollUp                   ;  If so, go to text scrolling
    187183%endif
    188     mov     ax, [bp+MENUVARS.wItemSel]      ; Load selected index 
     184    mov     ax, [bp+MENUVARS.wItemSel]      ; Load selected index
    189185    test    ax, ax                          ; Already at top?
    190186    jz      .KeyEnd                         ;  If so, go to end
     
    222218    je      .KeyHome                        ;  If so, go to beginning
    223219    mov     [bp+MENUVARS.wItemSel], ax      ; Store new menuitem index
    224     eMOVZX  bx, BYTE [bp+MENUVARS.bVisCnt]  ; Load number of visible items
     220    eMOVZX  bx, [bp+MENUVARS.bVisCnt]       ; Load number of visible items
    225221    add     bx, [bp+MENUVARS.wItemTop]      ; BX to one past last visible index
    226222    cmp     ax, bx                          ; Need to scroll?
     
    235231ALIGN JUMP_ALIGN
    236232.TextScrollDown:
    237     eMOVZX  ax, BYTE [bp+MENUVARS.bVisCnt]  ; Load visible items
     233    eMOVZX  ax, [bp+MENUVARS.bVisCnt]       ; Load visible items
    238234    add     ax, [bp+MENUVARS.wItemTop]      ; Add topmost menuitem index
    239235    cmp     ax, [bp+MENUVARS.wItemCnt]      ; Already at the bottom?
     
    261257    sbb     bh, 0
    262258    mov     [bp+MENUVARS.wItemTop], bx      ; Store first menuitem to draw
    263     jnc     .ScrollMenu 
     259    jnc     .ScrollMenu
    264260    mov     WORD [bp+MENUVARS.wItemTop], 0  ; Overflow, start with 0
    265261    jmp     .ScrollMenu
     
    284280    inc     ax                              ; Increment page
    285281    mul     BYTE [bp+MENUVARS.bVisCnt]      ; AX=First menuitem on page
    286     eMOVZX  bx, BYTE [bp+MENUVARS.bVisCnt]  ; Load number of visible items
     282    eMOVZX  bx, [bp+MENUVARS.bVisCnt]       ; Load number of visible items
    287283    add     bx, ax                          ; BX now one past last visible
    288284    cmp     bx, [bp+MENUVARS.wItemCnt]      ; Went over last?
     
    331327    dw      .KeyEnd     ; KEY_END
    332328; Scan code to jump index translation table
    333 .rgbKeyToIdx:   
     329.rgbKeyToIdx:
    334330    db  KEY_ENTER,  KEY_ESC,    KEY_UP,     KEY_DOWN,
    335331    db  KEY_PGUP,   KEY_PGDN,   KEY_HOME,   KEY_END
  • trunk/Configurator/Src/Libraries/menu/menumsg.asm

    r181 r293  
    212212    call    MenuMsg_GetTokenForLine         ; Get ptr to first token, length to AX
    213213    jnc     .EndOfString                    ; Return if no tokens
    214     eMOVZX  dx, BYTE [bp+MENUVARS.bWidth]   ; Menu width
     214    eMOVZX  dx, [bp+MENUVARS.bWidth]        ; Menu width
    215215    sub     dl, SIZE_MSG_HBRDR              ; To line length
    216216    mov     bl, ' '                         ; Space character
  • trunk/Configurator/Src/Libraries/menu/menuprog.asm

    r2 r293  
    1 ; File name     :   menuprog.asm
    21; Project name  :   Menu library
    3 ; Created date  :   23.11.2009
    4 ; Last update   :   23.11.2009
    5 ; Author        :   Tomi Tilli
    6 ; Description   :   ASM library to menu system.
     2; Description   :   ASM library for menu system.
    73;                   Contains functions for displaying progress bar dialog.
    84
     
    110106MenuProg_DrawBar:
    111107    ; Calculate number of chars to draw
    112     eMOVZX  cx, BYTE [bp+MENUVARS.bWidth]   ; Dialog width to CX
     108    eMOVZX  cx, [bp+MENUVARS.bWidth]        ; Dialog width to CX
    113109    sub     cl, 4                           ; Sub borders, CX=bar width
    114110    mul     cl                              ; AX=bar with * percentage
     
    117113    sub     cl, al                          ; CX=Empty char cnt
    118114    mov     bl, al                          ; BX=full char cnt
    119    
     115
    120116    ; Draw full chars
    121117    mov     dl, FULL_BLCK                   ; Load full block char
     
    180176    push    ds
    181177    push    si
    182     mov     si, [bp+PDLGVARS.fpUser]    ; Load offset to user ptr
    183     mov     ds, [bp+PDLGVARS.fpUser+2]  ; Load segment to user ptr
     178    lds     si, [bp+PDLGVARS.fpUser]    ; Load user defined ptr
    184179    xor     ax, ax                      ; Zero percent
    185180ALIGN JUMP_ALIGN
  • trunk/Configurator/Src/Libraries/menu/prntvram.asm

    r2 r293  
    1 ; File name     :   prntvram.asm
    21; Project name  :   Print library
    3 ; Created date  :   7.12.2009
    4 ; Last update   :   7.12.2009
    5 ; Author        :   Tomi Tilli
    6 ; Description   :   ASM library to for character and string
     2; Description   :   ASM library for character and string
    73;                   printing using direct access to VRAM.
    84;
     
    2723;--------------------------------------------------------------------
    2824; Return pointer to VRAM for current cursor position.
    29 ; 
     25;
    3026; PrntVram_GetPtr
    3127;   Parameters:
     
    4339
    4440    ; Calculate offset to VRAM
    45     eMOVZX  di, BYTE [es:BDA.bVidPageIdx]   ; Load page index
     41    eMOVZX  di, [es:BDA.bVidPageIdx]        ; Load page index
    4642    shl     di, 1                           ; Shift for word lookup
    4743    mov     ax, [es:di+BDA.rgwVidCurPos]    ; Load cursor position
     
    7066; use this macro to print characters (so printing implementation
    7167; can be easily modified when needed).
    72 ; 
     68;
    7369; PRINT_CHAR
    7470;   Parameters:
     
    117113    pop     es
    118114    je      .IncRow
    119    
     115
    120116    ; Inc column only
    121117    push    dx
     
    147143; use this macro to print strings (so printing implementation
    148144; can be easily modified when needed).
    149 ; 
     145;
    150146; PRINT_STR
    151147;   Parameters:
     
    167163; All string printing functions must use this macro to print strings
    168164; (so printing implementation can be easily modified when needed).
    169 ; 
     165;
    170166; PRINT_STR_LEN
    171167;   Parameters:
     
    194190    cmp     al, 20h                 ; Printable character?
    195191    jb      .Bios                   ;  If not, use BIOS functions
    196    
     192
    197193    push    dx
    198194    mov     al, dl
    199195    PRINT_CHAR
    200196    pop     dx
    201    
     197
    202198    ;stosb                          ; Store char to [ES:DI]
    203199    inc     dx                      ; Increment chars printed
  • trunk/Configurator/Src/MenuPage.asm

    r2 r293  
    1 ; File name     :   MenuPage.asm
    2 ; Project name  :   XTIDE Univeral BIOS Configurator
    3 ; Created date  :   15.4.2010
    4 ; Last update   :   27.4.2010
    5 ; Author        :   Tomi Tilli
     1; Project name  :   XTIDE Universal BIOS Configurator
    62; Description   :   Functions to access MENUPAGE structs.
    73
     
    113109    push    cx
    114110    push    bx
    115     eMOVZX  cx, BYTE [si+MENUPAGE.bItemCnt]
     111    eMOVZX  cx, [si+MENUPAGE.bItemCnt]
    116112    lea     bx, [si+MENUPAGE.rgMenuPageItem]
    117113ALIGN JUMP_ALIGN
  • trunk/Configurator/Src/MenuPageItem.asm

    r181 r293  
    1 ; Project name  :   XTIDE Univeral BIOS Configurator
     1; Project name  :   XTIDE Universal BIOS Configurator
    22; Description   :   Functions to access MENUPAGEITEM structs.
    33
     
    2121    push    cs
    2222    pop     es
    23     eMOVZX  cx, BYTE [bp+MENUVARS.bInfoH]   ; Info line count to CX
     23    eMOVZX  cx, [bp+MENUVARS.bInfoH]        ; Info line count to CX
    2424    call    MenuPageItem_PrintCommonInfoLines
    2525    mov     di, [di+MENUPAGEITEM.szInfo]    ; ES:DI now points to info string
     
    111111;       SS:BP:  Ptr to MENUVARS
    112112;   Returns:
    113 ;       CF:     Set if user data inputted succesfully
     113;       CF:     Set if user data inputted successfully
    114114;               Cleared if cancel
    115115;   Corrupts registers:
     
    147147;       SS:BP:  Ptr to MENUVARS
    148148;   Returns:
    149 ;       CF:     Set if user data inputted succesfully
     149;       CF:     Set if user data inputted successfully
    150150;               Cleared if cancel
    151151;   Corrupts registers:
     
    183183;       SS:BP:  Ptr to MENUVARS
    184184;   Returns:
    185 ;       CF:     Set if user data inputted succesfully
     185;       CF:     Set if user data inputted successfully
    186186;               Cleared if cancel
    187187;   Corrupts registers:
     
    216216;       SS:BP:  Ptr to MENUVARS
    217217;   Returns:
    218 ;       CF:     Set if user data inputted succesfully
     218;       CF:     Set if user data inputted successfully
    219219;               Cleared if cancel
    220220;   Corrupts registers:
     
    247247;       SS:BP:  Ptr to MENUVARS
    248248;   Returns:
    249 ;       CF:     Set since user data inputted succesfully
     249;       CF:     Set since user data inputted successfully
    250250;   Corrupts registers:
    251251;       AX, BX, CX, DX
     
    269269;   Returns:
    270270;       AX:     16-bit unsigned word inputted by user
    271 ;       CF:     Set if user data inputted succesfully
     271;       CF:     Set if user data inputted successfully
    272272;               Cleared if cancel
    273273;   Corrupts registers:
     
    297297;       SS:BP:  Ptr to MENUVARS
    298298;   Returns:
    299 ;       CF:     Set if user data inputted succesfully
     299;       CF:     Set if user data inputted successfully
    300300;               Cleared if cancel
    301301;   Corrupts registers:
  • trunk/Configurator/Src/MenuPageItemFormat.asm

    r2 r293  
    1 ; File name     :   MenuPageItemFormat.asm
    2 ; Project name  :   XTIDE Univeral BIOS Configurator
    3 ; Created date  :   15.4.2010
    4 ; Last update   :   30.4.2010
    5 ; Author        :   Tomi Tilli
    6 ; Description   :   Functions for formatting
     1; Project name  :   XTIDE Universal BIOS Configurator
     2; Description   :   Functions for formatting
    73;                   menuitem names from MENUPAGEITEM.
    84
     
    2521    mov     si, [di+MENUPAGEITEM.rgszLookup]    ; Load offset to string lookup table
    2622    mov     bx, [di+MENUPAGEITEM.pValue]        ; Ptr to value containing lookup index
    27     eMOVZX  bx, BYTE [bx]                       ; BX=lookup index (values are already shifted for WORD lookup)
     23    eMOVZX  bx, [bx]                            ; BX=lookup index (values are already shifted for WORD lookup)
    2824    push    WORD [bx+si]                        ; Push offset to string to print
    2925    mov     dh, 4                               ; Total of 4 bytes for formatting params
     
    4642ALIGN JUMP_ALIGN
    4743MenuPageItemFormat_NameForAnyType:
    48     eMOVZX  bx, BYTE [di+MENUPAGEITEM.bType]    ; Load menuitem type
     44    eMOVZX  bx, [di+MENUPAGEITEM.bType]         ; Load menuitem type
    4945    jmp     [cs:bx+.rgfnPrintBasedOnType]
    5046ALIGN WORD_ALIGN
     
    132128MenuPageItemFormat_NameWithUnsignedByteValue:
    133129    mov     si, [di+MENUPAGEITEM.pValue]        ; DS:SI points to value
    134     eMOVZX  ax, BYTE [si]                       ; Load byte to AX
     130    eMOVZX  ax, [si]                            ; Load byte to AX
    135131    push    ax                                  ; Push byte
    136132    jmp     SHORT MenuPageItemFormat_NameWithUnsignedValuePushed
     
    161157MenuPageItemFormat_NameWithByteHexadecimalValue:
    162158    mov     si, [di+MENUPAGEITEM.pValue]        ; DS:SI points to value
    163     eMOVZX  ax, BYTE [si]                       ; Load byte to AX
     159    eMOVZX  ax, [si]                            ; Load byte to AX
    164160    push    ax                                  ; Push byte
    165161    jmp     SHORT MenuPageItemFormat_NameWithHexadecimalValuePushed
  • trunk/Configurator/Src/Menupages/ConfigurationMenu.asm

    r2 r293  
    1 ; File name     :   ConfigurationMenu.asm
    2 ; Project name  :   XTIDE Univeral BIOS Configurator
    3 ; Created date  :   21.4.2010
    4 ; Last update   :   2.5.2010
    5 ; Author        :   Tomi Tilli
     1; Project name  :   XTIDE Universal BIOS Configurator
    62; Description   :   XTIDE Universal BIOS configuration menu.
    73
     
    226222;       SS:BP:  Ptr to MENUVARS
    227223;   Returns:
    228 ;       CF:     Set if user data inputted succesfully
     224;       CF:     Set if user data inputted successfully
    229225;               Cleared if cancel
    230226;   Corrupts registers:
     
    245241;       SS:BP:  Ptr to MENUVARS
    246242;   Returns:
    247 ;       CF:     Set if user data inputted succesfully
     243;       CF:     Set if user data inputted successfully
    248244;               Cleared if cancel
    249245;   Corrupts registers:
     
    358354    call    ConfigurationMenu_GetNumberOfIdeControllers
    359355    dec     cx                  ; First always visible
    360     jcxz    .Return
     356    j    .Return
    361357    mov     bx, g_MenuPageItemCfgIde2+MENUPAGEITEM.bFlags
    362358ALIGN JUMP_ALIGN
     
    381377ALIGN JUMP_ALIGN
    382378ConfigurationMenu_GetNumberOfIdeControllers:
     379    mov     cx, 1               ; Assume one controller for Lite mode
    383380    test    WORD [g_cfgVars+CFGVARS.rgbEepromBuffers+ROMVARS.wFlags], FLG_ROMVARS_FULLMODE
    384     jz      SHORT .ReturnOneControllerForLiteMode
    385     eMOVZX  cx, BYTE [g_cfgVars+CFGVARS.rgbEepromBuffers+ROMVARS.bIdeCnt]
    386     ret
    387 ALIGN JUMP_ALIGN
    388 .ReturnOneControllerForLiteMode:
    389     mov     cx, 1
    390     ret
     381    jz      SHORT .Return
     382    mov     cl, [g_cfgVars+CFGVARS.rgbEepromBuffers+ROMVARS.bIdeCnt]
     383ALIGN JUMP_ALIGN, ret
     384.Return:
     385    ret
  • trunk/Configurator/Src/Menupages/DrvParamsMenu.asm

    r2 r293  
    1 ; File name     :   DrvParamsMenu.asm
    2 ; Project name  :   XTIDE Univeral BIOS Configurator
    3 ; Created date  :   26.4.2010
    4 ; Last update   :   27.4.2010
    5 ; Author        :   Tomi Tilli
     1; Project name  :   XTIDE Universal BIOS Configurator
    62; Description   :   Menu for configuring DRVPARAMS.
    73
     
    109105ALIGN JUMP_ALIGN
    110106DrvParamsMenu_SetDrvParamsOffset:
    111     eMOVZX  cx, BYTE [g_MenuPageDrvParams+MENUPAGE.bItemCnt]
     107    eMOVZX  cx, [g_MenuPageDrvParams+MENUPAGE.bItemCnt]
    112108    dec     cx
    113109    mov     bx, g_MenuPageItemDrvBlockMode+MENUPAGEITEM.pValue
  • trunk/Configurator/Src/Menupages/FlashMenu.asm

    r181 r293  
    1 ; Project name  :   XTIDE Univeral BIOS Configurator
     1; Project name  :   XTIDE Universal BIOS Configurator
    22; Description   :   Flash menu.
    33
    44
    55; Flash error codes returned from progress bar task function
    6 ERR_FLASH_SUCCESSFULL   EQU     0
     6ERR_FLASH_SUCCESSFUL    EQU     0
    77ERR_FLASH_POLL_TIMEOUT  EQU     1
    88
     
    132132    call    MenuPageItem_GetByteFromUserWithoutMarkingUnsaved
    133133    jnc     SHORT .Cancel
    134     eMOVZX  bx, BYTE [g_cfgVars+CFGVARS.bPageSize]
     134    eMOVZX  bx, [g_cfgVars+CFGVARS.bPageSize]
    135135    eBSR    ax, bx                  ; AX = Index of highest order bit
    136136    mov     cx, 1
     
    185185    xor     dx, dx
    186186    mov     ax, [g_cfgVars+CFGVARS.wEepromSize]     ; DX:AX = Bytes to write
    187     eMOVZX  cx, BYTE [g_cfgVars+CFGVARS.bPageSize]
     187    eMOVZX  cx, [g_cfgVars+CFGVARS.bPageSize]
    188188    div     cx                                      ; AX = Total number of pages
    189189    mov     [g_cfgVars+CFGVARS.flashVars+FLASHVARS.wTotalPages], ax
     
    255255ALIGN JUMP_ALIGN
    256256.FlashComplete:
    257     mov     ax, ERR_FLASH_SUCCESSFULL
     257    mov     ax, ERR_FLASH_SUCCESSFUL
    258258    retf
    259259.Timeout:
     
    278278    mov     ax, [si+FLASHVARS.wTotalPages]
    279279    sub     ax, [si+FLASHVARS.wPagesLeft]           ; AX=Pages written
    280     eMOVZX  dx, BYTE [g_cfgVars+CFGVARS.bPageSize]
     280    eMOVZX  dx, [g_cfgVars+CFGVARS.bPageSize]
    281281    mul     dx                                      ; AX=Bytes written
    282282
     
    311311    mov     dx, [si+FLASHVARS.wPagesBeforeDraw]
    312312    call    FlashMenu_GetPointersToPageToFlash
    313     eMOVZX  ax, BYTE [g_cfgVars+CFGVARS.bSdpCommand]
    314     eMOVZX  cx, BYTE [g_cfgVars+CFGVARS.bPageSize]
     313    eMOVZX  ax, [g_cfgVars+CFGVARS.bSdpCommand]
     314    eMOVZX  cx, [g_cfgVars+CFGVARS.bPageSize]
    315315ALIGN JUMP_ALIGN
    316316.PageLoop:
     
    405405    cmp     ax, ERR_FLASH_POLL_TIMEOUT
    406406    je      SHORT FlashMenu_PollingTimeoutErrorDuringFlashing
    407     call    Flash_WasDataWriteSuccessfull
     407    call    Flash_WasDataWriteSuccessful
    408408    jne     SHORT FlashMenu_DataVerifyErrorAfterFlashing
    409409    ; Fall to FlashMenu_EepromFlashedSuccessfully
  • trunk/Configurator/Src/Menupages/IdeControllerMenu.asm

    r2 r293  
    1 ; File name     :   IdeControllerMenu.asm
    2 ; Project name  :   XTIDE Univeral BIOS Configurator
    3 ; Created date  :   23.4.2010
    4 ; Last update   :   27.4.2010
    5 ; Author        :   Tomi Tilli
     1; Project name  :   XTIDE Universal BIOS Configurator
    62; Description   :   Menu for configuring IDEVARS.
    73
     
    119115
    120116;--------------------------------------------------------------------
    121 ; Stores IDEVARS specific pointers to IDE Controller Menu 
     117; Stores IDEVARS specific pointers to IDE Controller Menu
    122118; MENUPAGEITEM structs.
    123119;
     
    133129ALIGN JUMP_ALIGN
    134130IdeControllerMenu_SetIdevarsOffset:
    135     eMOVZX  cx, BYTE [g_MenuPageIdeVars+MENUPAGE.bItemCnt]
     131    eMOVZX  cx, [g_MenuPageIdeVars+MENUPAGE.bItemCnt]
    136132    dec     cx
    137133    mov     bx, g_MenuPageItemIdeMaster+MENUPAGEITEM.pValue
  • trunk/Configurator/Src/Strings.asm

    r2 r293  
    1 ; File name     :   Strings.asm
    2 ; Project name  :   XTIDE Univeral BIOS Configurator
    3 ; Created date  :   16.4.2010
    4 ; Last update   :   2.5.2010
    5 ; Author        :   Tomi Tilli
     1; Project name  :   XTIDE Universal BIOS Configurator
    62; Description   :   Strings used in this program.
    73
     
    2218g_szFlashTimeout:       db  "Timeout error when polling EEPROM!",STOP
    2319g_szFlashVerifyErr:     db  "Data verification failed!",STOP
    24 g_szFlashDoneReboot:    db  "EEPROM written succesfully. Press any key to reboot.",STOP
    25 g_szFlashDoneContinue:  db  "EEPROM written succesfully.",STOP
     20g_szFlashDoneReboot:    db  "EEPROM written successfully. Press any key to reboot.",STOP
     21g_szFlashDoneContinue:  db  "EEPROM written successfully.",STOP
    2622
    2723
     
    4440g_szDlgMainLoadStngs:   db  "Successfully loaded settings from EEPROM.",STOP
    4541
    46 g_szNfoMainExitToDOS:   db  "Quits XTIDE Univeral BIOS Configurator.",STOP
     42g_szNfoMainExitToDOS:   db  "Quits XTIDE Universal BIOS Configurator.",STOP
    4743g_szNfoMainLoadFile:    db  "Load BIOS file to be configured or flashed.",STOP
    4844g_szNfoMainLoadROM:     db  "Load BIOS from EEPROM to be reconfigured.",STOP
  • trunk/Serial_Server/win32/Win32Serial.h

    r284 r293  
    1212#define PIPENAME "\\\\.\\pipe\\xtide"
    1313
    14 class SerialAccess 
     14class SerialAccess
    1515{
    1616public:
     
    2222
    2323        pipe = NULL;
    24    
     24
    2525        if( !name )
    2626        {
     
    3838        {
    3939            log( 0, "Opening named pipe %s (simulating %s baud)", name, baudRate->display );
    40        
     40
    4141            pipe = CreateNamedPipeA( name, PIPE_ACCESS_DUPLEX, PIPE_TYPE_BYTE|PIPE_REJECT_REMOTE_CLIENTS, 2, 1024, 1024, 0, NULL );
    4242            if( pipe == INVALID_HANDLE_VALUE )
    4343                log( -1, "Could not CreateNamedPipe " PIPENAME );
    44        
     44
    4545            if( !ConnectNamedPipe( pipe, NULL ) )
    4646                log( -1, "Could not ConnectNamedPipe" );
     
    6060
    6161                log( 0, "Opening %s (%s baud)", name, baudRate->display );
    62            
     62
    6363                pipe = CreateFileA( name, GENERIC_READ|GENERIC_WRITE, 0, 0, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0 );
    6464                if( pipe == INVALID_HANDLE_VALUE )
    6565                    log( -1, "Could not Open \"%s\"", name );
    66            
     66
    6767                FillMemory(&dcb, sizeof(dcb), 0);
    6868                FillMemory(&timeouts, sizeof(timeouts), 0);
     
    8383                            msg = "\n    On this COM port, baud rate is limited to 115.2K";
    8484                    }
    85                     log( -1, "Could not SetCommState: baud rate selected may not be availabele%s", msg );
     85                    log( -1, "Could not SetCommState: baud rate selected may not be available%s", msg );
    8686                }
    8787
     
    9494
    9595                EnumerateCOMPorts( logbuff, 1024 );
    96                
     96
    9797                log( -1, "Serial port '%s' not found, detected COM ports: %s", name, logbuff );
    9898            }
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/BiosFile.asm

    r181 r293  
    2727    call    Buffers_NewBiosWithSizeInDXCXandSourceInAXhasBeenLoadedForConfiguration
    2828    call    FileIO_CloseUsingHandleFromBX
    29     call    DisplayFileLoadedSuccesfully
     29    call    DisplayFileLoadedSuccessfully
    3030    jmp     SHORT .Return
    3131
     
    4343;       DS:SI:  Name of file to open
    4444;   Returns:
    45 ;       BX:     File handle (if succesfull)
    46 ;       DX:CX:  File size (if succesfull)
    47 ;       CF:     Clear if successfull
     45;       BX:     File handle (if successful)
     46;       DX:CX:  File size (if successful)
     47;       CF:     Clear if successful
    4848;               Set if error
    4949;   Corrupts registers:
     
    8080;       DS:SI:  File name
    8181;   Returns:
    82 ;       CF:     Clear if successfull
     82;       CF:     Clear if successful
    8383;               Set if error
    8484;   Corrupts registers:
     
    167167    call    FileIO_CloseUsingHandleFromBX
    168168    call    Buffers_ClearUnsavedChanges
    169     call    DisplayFileSavedSuccesfully
     169    call    DisplayFileSavedSuccessfully
    170170    jmp     SHORT .Return
    171171
     
    181181
    182182;--------------------------------------------------------------------
    183 ; DisplayFileLoadedSuccesfully
    184 ; DisplayFileSavedSuccesfully
     183; DisplayFileLoadedSuccessfully
     184; DisplayFileSavedSuccessfully
    185185; DisplayFailedToLoadFile
    186186; DisplayFailedToSaveFile
     
    194194;--------------------------------------------------------------------
    195195ALIGN JUMP_ALIGN
    196 DisplayFileLoadedSuccesfully:
     196DisplayFileLoadedSuccessfully:
    197197    mov     dx, g_szDlgMainLoadFile
    198198    jmp     Dialogs_DisplayNotificationFromCSDX
    199199
    200200ALIGN JUMP_ALIGN
    201 DisplayFileSavedSuccesfully:
     201DisplayFileSavedSuccessfully:
    202202    mov     dx, g_szDlgMainSaveFile
    203203    jmp     Dialogs_DisplayNotificationFromCSDX
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Buffers.asm

    r204 r293  
    145145    push    es
    146146
    147     eMOVZX  di, BYTE [cs:g_cfgVars+CFGVARS.bEepromType]
     147    eMOVZX  di, [cs:g_cfgVars+CFGVARS.bEepromType]
    148148    mov     cx, [cs:di+g_rgwEepromTypeToSizeInWords]
    149149    sub     cx, [cs:g_cfgVars+CFGVARS.wImageSizeInWords]    ; CX = WORDs to append
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/EEPROM.asm

    r181 r293  
    9191.GetXtideUniversalBiosSizeFromEStoDXCX:
    9292    xor     dx, dx
    93     eMOVZX  cx, BYTE [es:ROMVARS.bRomSize]
     93    eMOVZX  cx, [es:ROMVARS.bRomSize]
    9494    eSHL_IM cx, 9               ; *= 512 for byte count
    9595    ret
     
    199199    xor     si, si
    200200    call    Buffers_GetFlashComparisonBufferToESDI
    201     eMOVZX  bx, BYTE [cs:g_cfgVars+CFGVARS.bEepromType]
     201    eMOVZX  bx, [cs:g_cfgVars+CFGVARS.bEepromType]
    202202    mov     cx, [cs:bx+g_rgwEepromTypeToSizeInWords]
    203203    cld
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Flash.asm

    r181 r293  
    8686ALIGN JUMP_ALIGN
    8787.GetSdpCommandFunctionToDXwithFlashvarsInSSBP:
    88     eMOVZX  bx, BYTE [bp+FLASHVARS.bEepromSdpCommand]
     88    eMOVZX  bx, [bp+FLASHVARS.bEepromSdpCommand]
    8989    mov     si, [cs:bx+.rgpSdpCommandToEepromTypeLookupTable]
    9090    mov     bl, [bp+FLASHVARS.bEepromType]
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menuitem.asm

    r286 r293  
    146146ALIGN JUMP_ALIGN
    147147Menuitem_StoreValueFromAXtoMenuitemInDSSI:
    148     eMOVZX  bx, BYTE [si+MENUITEM.bType]
     148    eMOVZX  bx, [si+MENUITEM.bType]
    149149    cmp     bl, TYPE_MENUITEM_HEX
    150150    ja      SHORT .InvalidItemType
     
    207207;
    208208; if the lookup pointer is NULL, no translation is needed
    209 ; 
     209;
    210210    mov     bx, [si+MENUITEM.itemValue+ITEM_VALUE.rgwChoiceToValueLookup]
    211211    test    bx, bx
    212212    jz      .StoreByteOrWordValueFromAXtoESDIwithItemInDSSI
    213        
     213
    214214    shl     ax, 1           ; Shift for WORD lookup
    215215    add     bx, ax
     
    234234    mov     bx,[si+MENUITEM.itemValue+ITEM_VALUE.fnValueWriter]
    235235    test    bx,bx
    236     jz      SHORT .NoWriter 
    237 
    238     call    bx     
     236    jz      SHORT .NoWriter
     237
     238    call    bx
    239239
    240240.NoWriter:
     
    313313    xor     ah, ah              ; conversion needs to happen before call to the reader,
    314314                                ; in case the reader unpacks the byte to a word
    315        
     315
    316316.NoConvertWordToByteValue:
    317317    mov     bx, [si+MENUITEM.itemValue+ITEM_VALUE.fnValueReader]
     
    321321    call    bx
    322322
    323 .NoReader:     
     323.NoReader:
    324324    pop     bx
    325325    pop     di
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/MenuitemPrint.asm

    r286 r293  
    3636ALIGN JUMP_ALIGN
    3737MenuitemPrint_NameWithPossibleValueFromDSSI:
    38     eMOVZX  bx, BYTE [si+MENUITEM.bType]
     38    eMOVZX  bx, [si+MENUITEM.bType]
    3939    cmp     bl, TYPE_MENUITEM_ACTION
    4040    ja      SHORT .PrintNameAndValueFromDSSI
     
    147147;   Corrupts registers:
    148148;       AX, BX, CX
    149 ;--------------------------------------------------------------------   
     149;--------------------------------------------------------------------
    150150ALIGN JUMP_ALIGN
    151151MenuitemPrint_WriteLookupValueStringToBufferInESDIfromUnshiftedItemInDSSI:
     
    170170;   Corrupts registers:
    171171;       AX, BX, CX
    172 ;--------------------------------------------------------------------   
     172;--------------------------------------------------------------------
    173173ALIGN JUMP_ALIGN
    174174PrintLookupValueFromAXtoBufferInESDI:
    175175    push    si
    176176    test    byte [si+MENUITEM.bFlags], FLG_MENUITEM_CHOICESTRINGS
    177     jnz     .lookupChoice   
    178        
     177    jnz     .lookupChoice
     178
    179179    add     ax, [si+MENUITEM.itemValue+ITEM_VALUE.rgszValueToStringLookup]
    180180    xchg    bx, ax
    181 .found: 
     181.found:
    182182    mov     si, [bx]
    183183.errorReturn:
     
    187187
    188188;
    189 ; With FLG_MENUITEM_CHOICESTRINGS, the array at .rgszChoiceToStringLookup is based on the 
     189; With FLG_MENUITEM_CHOICESTRINGS, the array at .rgszChoiceToStringLookup is based on the
    190190; Choice number (offset within .rgwChoiceToValueLookup) instead of the value stored.
    191191; Here, we scan the .rgwChoiceToValueLookup array until we find the value there, and then
    192 ; use the same offset in .rgszChoiceToStringLookup.  If we don't find the value, we 
    193 ; return an "Error!" string instead. 
     192; use the same offset in .rgszChoiceToStringLookup.  If we don't find the value, we
     193; return an "Error!" string instead.
    194194;
    195195; Note that the pointer array at .rgszChoiceToStringLookup must be NULL terminated.  Since the
     
    197197;
    198198.lookupChoice:
    199     mov     bx,[si+MENUITEM.itemValue+ITEM_VALUE.rgszChoiceToStringLookup]     
     199    mov     bx,[si+MENUITEM.itemValue+ITEM_VALUE.rgszChoiceToStringLookup]
    200200    mov     si,[si+MENUITEM.itemValue+ITEM_VALUE.rgwChoiceToValueLookup]
    201        
     201
    202202.wordLoop:
    203203    cmp     ax,[si]
     
    222222;   Corrupts registers:
    223223;       AX, BX, CX
    224 ;--------------------------------------------------------------------   
     224;--------------------------------------------------------------------
    225225ALIGN JUMP_ALIGN
    226226MenuitemPrint_WriteUnsignedValueStringToBufferInESDIfromItemInDSSI:
     
    244244;   Corrupts registers:
    245245;       AX, BX, CX
    246 ;--------------------------------------------------------------------   
     246;--------------------------------------------------------------------
    247247ALIGN JUMP_ALIGN
    248248MenuitemPrint_WriteHexValueStringToBufferInESDIfromItemInDSSI:
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/FlashMenu.asm

    r246 r293  
    273273    mov     [si+FLASHVARS.bEepromSdpCommand], al
    274274
    275     eMOVZX  bx, BYTE [cs:g_cfgVars+CFGVARS.bEepromPage]
     275    eMOVZX  bx, [cs:g_cfgVars+CFGVARS.bEepromPage]
    276276    mov     ax, [cs:bx+g_rgwEepromPageToSizeInBytes]
    277277    mov     [si+FLASHVARS.wEepromPageSize], ax
     
    314314ALIGN JUMP_ALIGN
    315315.GetSelectedEepromSizeInWordsToAX:
    316     eMOVZX  bx, BYTE [cs:g_cfgVars+CFGVARS.bEepromType]
     316    eMOVZX  bx, [cs:g_cfgVars+CFGVARS.bEepromType]
    317317    mov     ax, [cs:bx+g_rgwEepromTypeToSizeInWords]
    318318    ret
     
    330330ALIGN JUMP_ALIGN
    331331.DisplayFlashingResultsFromFlashvarsInDSBX:
    332     eMOVZX  bx, BYTE [bx+FLASHVARS.flashResult]
     332    eMOVZX  bx, [bx+FLASHVARS.flashResult]
    333333    jmp     [cs:bx+.rgfnFlashResultMessage]
    334334
     
    370370ALIGN JUMP_ALIGN
    371371.DisplayRebootMessageAndReboot:
    372     mov     dx, g_szPCFlashSuccessfull
     372    mov     dx, g_szPCFlashSuccessful
    373373    call    Dialogs_DisplayNotificationFromCSDX
    374374    xor     ax, ax          ; Cold boot flag
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/MasterSlaveMenu.asm

    r286 r293  
    238238    call    .EnableMenuitemFromCSBX
    239239    mov     bx, g_MenuitemMasterSlaveUserLBA
    240     jmp     .EnableMenuitemFromCSBX 
     240    jmp     .EnableMenuitemFromCSBX
    241241
    242242ALIGN JUMP_ALIGN
     
    245245    call    .EnableMenuitemFromCSBX
    246246    mov     bx, g_MenuitemMasterSlaveUserLBA
    247     jmp     .DisableMenuitemFromCSBX   
     247    jmp     .DisableMenuitemFromCSBX
    248248
    249249ALIGN JUMP_ALIGN
     
    252252    call    .EnableMenuitemFromCSBX
    253253    mov     bx, g_MenuitemMasterSlaveUserCHS
    254     jmp     .DisableMenuitemFromCSBX   
     254    jmp     .DisableMenuitemFromCSBX
    255255
    256256
     
    308308    test    ax, FLG_DRVPARAMS_USERLBA
    309309    jz      SHORT .DisableMenuitemFromCSBX
    310     jmp     SHORT .EnableMenuitemFromCSBX
     310    ; Fall to .EnableMenuitemFromCSBX
    311311
    312312
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Strings.asm

    r290 r293  
    2222
    2323g_szNo:                             db  "No",NULL
    24 g_szYes:                            db  "Yes",NULL
    2524g_szMultichoiceBooleanFlag:
    2625                                    db  "No",LF
    27                                     db  "Yes",NULL
     26g_szYes:                            db  "Yes",NULL
    2827
    2928; Exit messages
     
    4443g_szErrEepromVerify:    db  "EEPROM did not return the same byte that was written.",LF
    4544                        db  "EEPROM was not flashed properly!",NULL
    46 g_szPCFlashSuccessfull: db  "EEPROM was written successfully.",LF
     45g_szPCFlashSuccessful:  db  "EEPROM was written successfully.",LF
    4746                        db  "Press any key to reboot.",NULL
    4847g_szForeignFlash:       db  "EEPROM was written successfully.",NULL
     
    374373                        db  "None",LF
    375374                        db  "Enable",LF
    376                         db  "Disable",NULL
     375g_szValueFlashDisable:  db  "Disable",NULL
    377376g_szValueFlashNone:     db  "None",NULL
    378377g_szValueFlashEnable:   db  "Enable",NULL
    379 g_szValueFlashDisable:  db  "Disable",NULL
    380378
    381379g_szMultichoicePageSize:
     
    386384                        db  "16 bytes",LF
    387385                        db  "32 bytes",LF
    388                         db  "64 bytes",NULL
     386g_szValueFlash64bytes:  db  "64 bytes",NULL
    389387g_szValueFlash1byte:    db  "1 byte",NULL
    390388g_szValueFlash2bytes:   db  "2 bytes",NULL
     
    393391g_szValueFlash16bytes:  db  "16 bytes",NULL
    394392g_szValueFlash32bytes:  db  "32 bytes",NULL
    395 g_szValueFlash64bytes:  db  "64 bytes",NULL
    396393
    397394g_szSelectionTimeout:   db      DOUBLE_BOTTOM_LEFT_CORNER,DOUBLE_LEFT_HORIZONTAL_TO_SINGLE_VERTICAL,"%ASelection in %2u s",NULL
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/makefile

    r187 r293  
    11###############################################################################
    2 # Generic makefile for building binary files.                                 #
    3 # v. 1.1.0 (28.7.2007 ... 5.10.2010)                                          #
    4 # (C) Tomi Tilli                                                              #
    5 # aitotat@gmail.com                                                           #
     2# Makefile to build XTIDE Universal BIOS Configurator v2.                     #
    63#                                                                             #
    74# Valid makefile targets are:                                                 #
    85# all       Removes existing files and builds binary file in \Build           #
    9 # build     Builds binary file in \Build                                      #
    106# clean     Removes all files from \Build                                     #
    117#                                                                             #
     
    5450
    5551
    56 
    5752#################################################################
    5853# Assembler preprocessor defines.                               #
     
    6156DEFINES_XT = ELIMINATE_CGA_SNOW
    6257DEFINES_XTPLUS = USE_186 ELIMINATE_CGA_SNOW
    63 DEFINES_AT = USE_186 USE_286 USE_AT
     58DEFINES_AT = USE_286 USE_AT
    6459
    6560
     
    113108.PHONY: all at xtplus xt clean release
    114109
    115 # Make clean debug and release versions
    116110all: clean xt
    117111    @echo All done!
     
    123117xtplus:
    124118    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XTPLUS) -l"$(TARGET)_xtp.lst" -o"$(TARGET)_xtp.$(EXTENSION)"
    125     @echo XT plus version "$(TARGET)_xtp.$(EXTENSION)" built.
     119    @echo XT Plus version "$(TARGET)_xtp.$(EXTENSION)" built.
    126120
    127121xt:
Note: See TracChangeset for help on using the changeset viewer.