Changeset 293 in xtideuniversalbios for trunk/Configurator


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/Configurator
Files:
18 edited

Legend:

Unmodified
Added
Removed
  • 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
Note: See TracChangeset for help on using the changeset viewer.