flat assembler
Message board for the users of flat assembler.
Index
> DOS > TEXTMODE code snipplets for newbies Goto page Previous 1, 2 |
Author |
|
bubach 13 Nov 2004, 13:36
Here's my complete set of textfunctions, for my os, BOS..
Scrolls the window, can change cursor attributes, getcursor, setcursor, print with new line feature etc..
Last edited by bubach on 13 Feb 2012, 15:01; edited 1 time in total |
|||||||||||
13 Nov 2004, 13:36 |
|
Matrix 13 Nov 2004, 19:40
yeah, sorry for the long thread, i was thinking about people don't like to download if they only wanna take a look, but i guess i will make all as an attachment, my structure is currently: direct.inc bios.inc dos.inc
my only problem with libraries is i can't include a large library in all my files, maeby i'm lazy to copy my procs to my code? well ... so you think they whould be better if i make it a zip in an attachment? |
|||
13 Nov 2004, 19:40 |
|
rea 02 May 2005, 21:17
, I have one,
Code: hexBuffer db 0,0,0,0, 0 Start_Ax2Eax: Ax2Eax: ; push cx push bx mov bx, ax and ax, 0xf0f0 and bx, 0x0f0f shr ax, 4 bswap eax mov ax, bx ;mov cl, 8 mov bx, 4 .again: ;cmp al, "9" ;jna .nadd ; add al, "A"-"9" ;.nadd ;add al, "0" cmp al,10 sbb al,69h das rol eax, 8 ; cl dec bx jnz .again rol eax, 8 ; cl xchg ah, al bswap eax ; comment this out if you prefer read it in Big-Endian way ¿?¿?¿? .. LOL mov [hexBuffer], eax pop bx ; pop cx ret End_Ax2Eax %assign Ax2Eax_size End_Ax2Eax-Start_Ax2Eax %error The size of Ax2Eax is Ax2Eax_size In that way are 48 bytes of function plus 5 bytes for the buffer, the previous one that I have was with the comments that are now comments.. (uh?), if you delete the preservation of bx and the store to memory the function will be 42 bytes, or the last bswap deleted and you get 39, tought bswap is for convert litle to big and viceversa.. then if you dont mind about.. ¿?. Hope this help . |
|||
02 May 2005, 21:17 |
|
Matrix 29 Oct 2005, 01:44
sorry for long thread, im going to make library and delete them
|
|||
29 Oct 2005, 01:44 |
|
relsoft 04 Apr 2006, 00:33
Matrix wrote: sorry for long thread, im going to make library and delete them Why would you? I find these snippets especially useful. _________________ Hello |
|||
04 Apr 2006, 00:33 |
|
Goto page Previous 1, 2 < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.