flat assembler
Message board for the users of flat assembler.

Index > OS Construction > A few Realmode functions for your OS

Author
Thread Post new topic Reply to topic
me239



Joined: 06 Jan 2011
Posts: 200
me239 19 Feb 2011, 07:03
Hello everyone, today I wanted to post a few simple, but useful, Realmode BIOS functions. The functions go as the following: printf- SI = text(NULL terminated), cmpstr(not case sensitive)- DI = buffer SI = text to compare to(caps), getinput-DI = buffer CL = number of characters to take.


Description: Functions
Download
Filename: input.asm
Filesize: 1.9 KB
Downloaded: 228 Time(s)

Post 19 Feb 2011, 07:03
View user's profile Send private message Reply with quote
b1528932



Joined: 21 May 2010
Posts: 287
b1528932 19 Feb 2011, 10:03
pusha/popa = 80286+
Quote:
mov byte[counter], cl

I belive that byte operations are slower than native word ones. Even if i need only byte, i store word.

Quote:
mov ax, 0e0dh
int 10h
mov al, 0ah
int 10h

why you assume ah is not destroyed? Correct me if im wrong.


Quote:
mov si, msg3

you should also load segment registers, in real mode pointer is segment:offset, keep in mind.


8086 also has movs (strncpy/memcpy)/cmps (strncmp)/scas (strnlen). I dont read all you code but, so i dont know if those instructions are appropiate for it.
Post 19 Feb 2011, 10:03
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.