Ignore:
Timestamp:
Dec 9, 2010, 6:36:00 PM (13 years ago)
Author:
aitotat
google:author:
aitotat
Message:

Changes to Configurator v2:

  • Finally ready for testing.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/FlashMenu.asm

    r65 r68  
    185185ALIGN JUMP_ALIGN
    186186StartFlashing:
     187    call    .MakeSureThatImageFitsInEeprom
     188    jc      SHORT .InvalidFlashingParameters
    187189    push    es
    188190    push    ds
     
    200202    pop     ds
    201203    pop     es
     204.InvalidFlashingParameters:
     205    ret
     206
     207;--------------------------------------------------------------------
     208; .MakeSureThatImageFitsInEeprom
     209;   Parameters:
     210;       SS:BP:  Ptr to MENU
     211;   Returns:
     212;       Nothing
     213;   Corrupts registers:
     214;       AX, BX, DX
     215;--------------------------------------------------------------------
     216ALIGN JUMP_ALIGN
     217.MakeSureThatImageFitsInEeprom:
     218    call    .GetSelectedEepromSizeInWordsToAX
     219    cmp     ax, [cs:g_cfgVars+CFGVARS.wImageSizeInWords]
     220    jae     SHORT .ImageFitsInSelectedEeprom
     221    mov     dx, g_szErrEepromTooSmall
     222    call    Dialogs_DisplayErrorFromCSDX
     223    stc
     224    ret
     225ALIGN JUMP_ALIGN
     226.ImageFitsInSelectedEeprom:
     227    clc
    202228    ret
    203229
     
    270296ALIGN JUMP_ALIGN
    271297.GetNumberOfPagesToFlashToAX:
    272     eMOVZX  bx, BYTE [si+FLASHVARS.bEepromType]
    273     mov     ax, [cs:bx+g_rgwEepromTypeToSizeInWords]
     298    call    .GetSelectedEepromSizeInWordsToAX
    274299    xor     dx, dx
    275300    shl     ax, 1       ; Size in bytes to...
     
    282307    ret
    283308
     309;--------------------------------------------------------------------
     310; .GetSelectedEepromSizeInWordsToAX
     311;   Parameters:
     312;       Nothing
     313;   Returns:
     314;       AX:     Selected EEPROM size in WORDs
     315;   Corrupts registers:
     316;       BX
     317;--------------------------------------------------------------------
     318ALIGN JUMP_ALIGN
     319.GetSelectedEepromSizeInWordsToAX:
     320    eMOVZX  bx, BYTE [cs:g_cfgVars+CFGVARS.bEepromType]
     321    mov     ax, [cs:bx+g_rgwEepromTypeToSizeInWords]
     322    ret
    284323
    285324;--------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.