Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ANSI.SYS - why driver?

92 views
Skip to first unread message

muta...@gmail.com

unread,
Oct 9, 2020, 12:46:03 PM10/9/20
to
Why does MSDOS have a DEVICE=ANSI.SYS
to activate the ANSI escape sequences? Why
was it made a driver, instead of just extra
functionality, perhaps signaled by:

ANSI=YES

in the config.sys.

I'm trying to understand when we need to
create drivers and when we need to just
add functionality to the OS.

Thanks. Paul.

Grant Taylor

unread,
Oct 9, 2020, 1:38:10 PM10/9/20
to
On 10/9/20 10:46 AM, muta...@gmail.com wrote:
> Why does MSDOS have a DEVICE=ANSI.SYS to activate the ANSI
> escape sequences?

Because the base OS doesn't support ANSI escape sequences.

> Why was it made a driver, instead of just extra functionality,
> perhaps signaled by:

Because the base functionality didn't exist when DOS was created. It
was later /added/ as an /optional/ module (via ANSI.SYS driver) so that
it could be enabled by those that wanted it's support.

Remember, additional functionality requires additional resources. Also
remember that DOS is a resource constrained OS.

> I'm trying to understand when we need to create drivers and when we
> need to just add functionality to the OS.

Can you add functionality to the (base) OS? Do you have legal access to
the DOS source code? (Most people do not.) Further, can you compile
new versions and distribute it? (I'm betting not.)

Anybody that wants to can create drivers to add functionality to an
operating system that they can't realistically change.

> Thanks. Paul.

:-)



--
Grant. . . .
unix || die

muta...@gmail.com

unread,
Oct 10, 2020, 9:22:45 AM10/10/20
to
On Saturday, October 10, 2020 at 4:38:10 AM UTC+11, Grant Taylor wrote:

> Because the base functionality didn't exist when DOS was created. It
> was later /added/ as an /optional/ module (via ANSI.SYS driver) so that
> it could be enabled by those that wanted it's support.

Is MSDOS written with special hooks in the screen
output functions that enable a device driver to hook
into?

It just seems a bit odd that a device driver (designed
to drive alien hardware) is also able to intercept
MSDOS before it does BIOS calls to write to the
screen.

Thanks. Paul.

muta...@gmail.com

unread,
Oct 10, 2020, 10:05:18 AM10/10/20
to
On Sunday, October 11, 2020 at 12:22:45 AM UTC+11, muta...@gmail.com wrote:

> Is MSDOS written with special hooks in the screen
> output functions that enable a device driver to hook
> into?

Or does the device driver hook into INT 21H and
redirect the DOS screen writes to be handled itself?

Thanks. Paul.

Grant Taylor

unread,
Oct 10, 2020, 3:20:49 PM10/10/20
to
On 10/10/20 7:22 AM, muta...@gmail.com wrote:
> Is MSDOS written with special hooks in the screen output functions
> that enable a device driver to hook into?

I have no idea.

You might look for one of the purported leaks of the MS-DOS source code
and look through it to find the answer.

> It just seems a bit odd that a device driver (designed to drive alien
> hardware) is also able to intercept MSDOS before it does BIOS calls
> to write to the screen.
>
> Or does the device driver hook into INT 21H and redirect the DOS
> screen writes to be handled itself?

I don't know.

My speculation is that there are provisions to allow such things to happen.

NimbUs

unread,
Oct 12, 2020, 2:26:21 PM10/12/20
to
muta...@gmail.com asked :

>> Is MSDOS written with special hooks in the screen
>> output functions that enable a device driver to hook
>> into?

> Or does the device driver hook into INT 21H and
> redirect the DOS screen writes to be handled itself?

No. ANSI.SYS is just a DOS console driver (aka CON) replacement.
It adds itself to the DOS driver chain upon installation, and
thereafter replaces the standard CON (built-in, part of IO.SYS aka
IBMBIO.COM) completely. It is a standard mechanism of DOS (2+), not
any "special hook".

--
Nim'

Bill Cunningham

unread,
Oct 13, 2020, 7:53:28 AM10/13/20
to
I miss those old drivers. ansi.sys and cdrom.sys. I have a msdos 3.x copy of dos. Are there any older ones out there? Versions of msdos and drivers?

Grant Taylor

unread,
Oct 13, 2020, 4:59:20 PM10/13/20
to
On 10/13/20 5:53 AM, Bill Cunningham wrote:
> Are there any older ones out there? Versions of msdos and drivers?

Yes, there are absolutely older versions of MS-DOS / PC-DOS / DR-DOS to
be found in archives scattered all over the Internet.

I do wonder how functional something older than 3.0 will be. I say that
thinking that many things that we take for granted, even in DOS, have a
requirement on 3.<something>.

My understanding is that CD-ROM drivers even use something meant for
networking that was introduced in 3.<something>. (I have long assumed
this to be functionality used for drive letters that don't correspond to
local physical devices.)
0 new messages