ANSI.SYS

From Wikipedia, the free encyclopedia

ANSI.SYS is a device driver in the DOS operating system that provides extra console functions through ANSI escape codes. It is partially based upon a subset of the text terminal control standard proposed by the ANSI X3L2 Technical Committee on Codes and Character Sets (the "X3 Committee").

Contents

[edit] Usage

To use ANSI.SYS under MS-DOS, you added a line to the CONFIG.SYS file that read:

device=(drive:)(path)ANSI.SYS

where (drive:) and (path) are the drive letter and path to the directory in which the file ANSI.SYS is found.

[note: since Windows XP is an NT native platform (does not use MS-DOS as kernel) certain things have changed when using the prompt. Notable to this discussion is that you must modify CONFIG.NT (often in a folder C:\I386\ or C:\Windows\System32) in place of CONFIG.SYS]

[edit] Functionality

Once loaded, ANSI.SYS enabled codes that changed the colors of the cursor and characters on the screen, or enabled software programs to move the cursor up or down lines, enabled blinking text, and similar text graphics features. Using this driver, text could be displayed in 16 different colors ("foreground" colors), with 8 optional background colors. It also allowed for the changing of the video mode from standard 80x25 text mode to a number of different graphics modes (i.e. 320x200, 640x200, 40-column text mode) depending on the which video graphics card was installed.

An interesting feature about ANSI.SYS was that it allowed for the remapping of any key on the keyboard in order to perform shortcuts or macros for complex instructions. This feature was also used by evildoers to create simple trojans out of text files called "ANSI Bombs" laced with nefarious keyboard remaps. A number of antivirus utilities were written to ensure that, for example, the F3 function key wasn't remapped to DEL *.* or FORMAT C: and the N-key (for no) wasn't remapped to Y.

[edit] Occurrence

The file ANSI.SYS is a part of several Microsoft operating systems, including:

ANSI.SYS was required to run some software that used its cursor and color control functions. It could also be used to enable elaborate color codes in the command.com prompt. These uses were overshadowed by the use of ANSI.SYS in BBSes; ANSI escape codes were used to enable BBSes to send elaborate text graphics more elaborate than ASCII art, and to control the cursor in ways that were used in a number of online games and similar features.

[edit] See also

[edit] External links

In other languages