Changeset 181 in xtideuniversalbios for trunk/Configurator
- Timestamp:
- Nov 13, 2011, 3:38:40 PM (13 years ago)
- google:author:
- krille_n_@hotmail.com
- Location:
- trunk/Configurator/Src
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Configurator/Src/BiosFile.asm
r145 r181 29 29 30 30 ; Ask if user wants to save 31 mov ax, cs 32 mov ds, ax 33 mov es, ax 31 push cs 32 pop ds 33 push cs 34 pop es 34 35 call BiosFile_DoesUserWantToSaveChanges 35 36 jnc SHORT .Return -
trunk/Configurator/Src/Libraries/math.asm
r78 r181 1 ; File name : math.asm2 1 ; Project name : Math library 3 ; Created date : 7.10.2009 4 ; Last update : 4.1.2011 5 ; Author : Tomi Tilli, 6 ; : Krister Nordvall (optimizations) 7 ; Description : ASM library to for math related functions. 2 ; Description : ASM library for math related functions. 8 3 9 4 ;--------------- Equates ----------------------------- … … 27 22 ;-------------------------------------------------------------------- 28 23 ; Macro to select lesser of two unsigned operands. 29 ; 24 ; 30 25 ; MIN_U 31 26 ; Parameters: … … 48 43 ;-------------------------------------------------------------------- 49 44 ; Macro to select greater of two unsigned operands. 50 ; 45 ; 51 46 ; MAX_U 52 47 ; Parameters: … … 69 64 ;-------------------------------------------------------------------- 70 65 ; Macro to select lesser and greater of two unsigned operands. 71 ; 66 ; 72 67 ; MINMAX_U 73 68 ; Parameters: … … 82 77 %macro MINMAX_U 2 83 78 cmp %1, %2 ; Is %1 smaller? 84 jb e%%Return ; If so, return79 jb %%Return ; If so, return 85 80 xchg %1, %2 ; Exchange operands 86 81 ALIGN JUMP_ALIGN … … 93 88 ; Multiplies unsigned 32-bit integer by unsigned 16-bit integer. 94 89 ; Result is unsigned 32-bit integer, so overflow is possible. 95 ; 90 ; 96 91 ; Math_MulDWbyW 97 92 ; Parameters: … … 130 125 ;-------------------------------------------------------------------- 131 126 ; Divide a 32-bit unsigned integer so that quotient can be 32-bit. 132 ; 127 ; 133 128 ; Math_DivDWbyW 134 129 ; Parameters: … … 157 152 ;-------------------------------------------------------------------- 158 153 ; Converts remainder to tenths. 159 ; 154 ; 160 155 ; Math_RemToTenths 161 156 ; Parameters: -
trunk/Configurator/Src/Libraries/menu/menudraw.asm
r170 r181 287 287 test BYTE [bp+MENUVARS.bFlags], FLG_MNU_HIDENFO ; Information hidden? 288 288 jnz SHORT .JumpToBottomBorder 289 test cx, cx ; Any info strings? 290 jz SHORT MenuDraw_BottomBorder 289 jcxz MenuDraw_BottomBorder ; Any info strings? 291 290 push cx 292 291 call MenuDraw_MiddleBorder ; Draw middle border -
trunk/Configurator/Src/Libraries/menu/menumsg.asm
r2 r181 1 ; File name : menumsg.asm2 1 ; Project name : Menu library 3 ; Created date : 13.11.2009 4 ; Last update : 10.1.2010 5 ; Author : Tomi Tilli 6 ; Description : ASM library to menu system. 2 ; Description : ASM library for menu system. 7 3 ; Contains functions for displaying messages. 8 4 … … 156 152 ALIGN JUMP_ALIGN 157 153 MenuMsg_GetTokenForLine: 158 test cx, cx ; Line 0 wanted? 159 jz .GetFirst ; If so, just get token length 154 jcxz .GetFirst ; Line 0 wanted? If so, just get token length 160 155 push bp 161 156 push si … … 218 213 jnc .EndOfString ; Return if no tokens 219 214 eMOVZX dx, BYTE [bp+MENUVARS.bWidth] ; Menu width 220 sub dl, SIZE_MSG_HBRDR ; To line length 215 sub dl, SIZE_MSG_HBRDR ; To line length 221 216 mov bl, ' ' ; Space character 222 217 ALIGN JUMP_ALIGN -
trunk/Configurator/Src/Libraries/print.asm
r78 r181 1 ; File name : print.asm2 1 ; Project name : Print library 3 ; Created date : 6.10.20094 ; Last update : 4.1.20115 ; Author : Tomi Tilli,6 ; : Krister Nordvall (optimizations)7 2 ; Description : ASM library for character and string 8 3 ; printing related functions. … … 95 90 ;-------------------------------------------------------------------- 96 91 ; Debugging macro that prints wanted character and newline. 97 ; 92 ; 98 93 ; PRINT_DBG_CH 99 94 ; Parameters: … … 141 136 ; 142 137 ; NOTE! Caller must clean the stack variables! 143 ; 138 ; 144 139 ; Print_Format 145 140 ; Parameters: … … 341 336 ;-------------------------------------------------------------------- 342 337 ; Prints newline character to change line. 343 ; 338 ; 344 339 ; Print_Newline 345 340 ; Parameters: … … 363 358 ret 364 359 %endif 365 360 366 361 367 362 ;-------------------------------------------------------------------- 368 363 ; Prints wanted number of characters. 369 ; 364 ; 370 365 ; Print_CharBuffer 371 366 ; Parameters: … … 404 399 ;-------------------------------------------------------------------- 405 400 ; Repeats wanted character. 406 ; 401 ; 407 402 ; Print_Repeat 408 403 ; Parameters: … … 429 424 ;-------------------------------------------------------------------- 430 425 ; Prints boolean value. 431 ; 426 ; 432 427 ; Print_Bool 433 428 ; Parameters: … … 455 450 ;-------------------------------------------------------------------- 456 451 ; Prints signed or unsigned 16-bit integer. 457 ; 452 ; 458 453 ; Print_IntSW Prints signed 16-bit word 459 454 ; Print_IntUW Prints unsigned 16-bit word … … 506 501 PRINT_CHAR ; Print character 507 502 inc di ; Increment chars printed 508 test cx, cx; Characters left509 jnz.PrintLoop ; If so, loop503 inc cx ; Characters left 504 loop .PrintLoop ; If so, loop 510 505 mov dx, di ; Copy chars printed to DX 511 506 pop cx … … 518 513 ;-------------------------------------------------------------------- 519 514 ; Prints unsigned 32-bit integer. 520 ; 515 ; 521 516 ; Print_IntUDW 522 517 ; Parameters: … … 552 547 PRINT_CHAR ; Print character 553 548 inc di ; Increment chars printed 554 test cx, cx; Characters left555 jnz.PrintLoop ; If so, loop549 inc cx ; Characters left 550 loop .PrintLoop ; If so, loop 556 551 mov dx, di ; Copy characters printed to DX 557 552 pop cx … … 565 560 ;-------------------------------------------------------------------- 566 561 ; Prints 8-bit byte as hexadecimal string. 567 ; 562 ; 568 563 ; Print_IntHexB 569 564 ; Parameters: … … 593 588 ;-------------------------------------------------------------------- 594 589 ; Prints 16-bit word as hexadecimal string. 595 ; 590 ; 596 591 ; Print_IntHexW 597 592 ; Parameters: … … 621 616 ;-------------------------------------------------------------------- 622 617 ; Prints 32-bit dword as hexadecimal string. 623 ; 618 ; 624 619 ; Print_IntHexDW 625 620 ; Parameters: … … 658 653 ;-------------------------------------------------------------------- 659 654 ; Prints hexadecimal character for every nybble for WORD. 660 ; 655 ; 661 656 ; Print_HexString 662 657 ; Parameters: -
trunk/Configurator/Src/MenuPageItem.asm
r145 r181 65 65 ALIGN JUMP_ALIGN 66 66 MenuPageItem_DisplayHelpDialog: 67 push cs 68 pop es 67 69 mov di, [di+MENUPAGEITEM.szHelp] ; ES:DI now points to help string 68 push cs69 pop es70 70 mov bl, WIDTH_DLG ; Dialog width 71 71 jmp Menu_ShowMsgDlg -
trunk/Configurator/Src/Menupages/FlashMenu.asm
r145 r181 371 371 FlashMenu_CalculateCompletionPercentage: 372 372 cmp WORD [si+FLASHVARS.wPagesLeft], 0 373 mov ax, 100 373 374 je SHORT .FlashComplete 374 mov ax, 100375 375 mul WORD [si+FLASHVARS.wPagesLeft] 376 376 div WORD [si+FLASHVARS.wTotalPages] ; AX = Percentage left to write … … 382 382 ALIGN JUMP_ALIGN 383 383 .FlashComplete: 384 mov ax, 100385 384 stc 386 385 ret
Note:
See TracChangeset
for help on using the changeset viewer.