flat assembler
Message board for the users of flat assembler.

Index > DOS > DOS inturrupt

Author
Thread Post new topic Reply to topic
GhostXoPCorp



Joined: 13 Dec 2008
Posts: 199
Location: 01F0:0100
GhostXoPCorp 01 Jun 2009, 21:45
i was wondering on how dos works, i came upon int 21 and how it prints to the screen, does dos use int 10h inside of 21h or do they have a built in driver or one of the io or ms_dos sys file to print to the screen (drivers)

_________________
Oh that divide overflow. Just jumps out of the bushes every time to scare the day lights out of me.
Post 01 Jun 2009, 21:45
View user's profile Send private message Reply with quote
comrade



Joined: 16 Jun 2003
Posts: 1150
Location: Russian Federation
comrade 02 Jun 2009, 00:54
They probably call int 10h inside their int 21h handler. Kinda like routines call other subroutines. Remember software interrupts are similar to a function call mechanism. Except in modern software they also bring an environment change (user-mode to kernel-mode). On DOS they are pretty much like a subroutine call Smile
Post 02 Jun 2009, 00:54
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number Reply with quote
LocoDelAssembly
Your code has a bug


Joined: 06 May 2005
Posts: 4624
Location: Argentina
LocoDelAssembly 02 Jun 2009, 02:41
If Int21 calls Int29 for on-screen printing then:
DOS 2+ - FAST CONSOLE OUTPUT wrote:
AL = character to display

Return:
Nothing BX may be destroyed by some versions of DOS 3.3

Notes: Automatically called when writing to a device with bit 4 of its device driver header set (see also INT 21/AH=52h). COMMAND.COM v3.2 and v3.3 compare the INT 29 vector against the INT 20 vector and assume that ANSI.SYS is installed if the segment is larger. The default handler under DOS 2.x and 3.x simply calls INT 10/AH=0Eh. The default handler under DESQview 2.2 understands the [2J screen-clearing sequence, calls INT 10/AH=0Eh for all others


Ref: http://www.ctyme.com/intr/rb-4124.htm
Post 02 Jun 2009, 02:41
View user's profile Send private message Reply with quote
GhostXoPCorp



Joined: 13 Dec 2008
Posts: 199
Location: 01F0:0100
GhostXoPCorp 02 Jun 2009, 04:05
thanks for the reply, what i thought is that t used its own screen drivers, if so that would of anwered another question, the other question was why is command.com so big? in asm shouldnt it be smaller? or are there things that are background and cant be noticed, maybe its the buffers? one more question (getting annoying, sorry) what is a stacks over flow and i know it has a connection with the keyboard, when key mash i get the little error screen, i promise these are all the questions i have left for dos
Post 02 Jun 2009, 04:05
View user's profile Send private message Reply with quote
rCX



Joined: 29 Jul 2007
Posts: 172
Location: Maryland, USA
rCX 02 Jun 2009, 16:38
Which DOS are you using? In FreeDOS, command.com is 66945bytes.
Post 02 Jun 2009, 16:38
View user's profile Send private message Reply with quote
GhostXoPCorp



Joined: 13 Dec 2008
Posts: 199
Location: 01F0:0100
GhostXoPCorp 02 Jun 2009, 16:45
no, the original ms-dos, but i know why free dos is so big, it doesnt use assembly as a main for programming, but i have seen somewhere some one built an os with more functionallity than dos and much smaller, does dos use assembly, or is there many background things that arents noticed, like for security of anything else?

_________________
Oh that divide overflow. Just jumps out of the bushes every time to scare the day lights out of me.
Post 02 Jun 2009, 16:45
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.