Direct mode
Encyclopedia
Direct mode, also known as immediate mode is a computing term referring to the input of textual commands
Command (computing)
In computing, a command is a directive to a computer program acting as an interpreter of some kind, in order to perform a specific task. Most commonly a command is a directive to some kind of command line interface, such as a shell....

 outside the context of a program. The command would be executed immediately and the results printed on screen, in contrast to programming mode where nothing would be executed until a specific command was given (BASIC
BASIC
BASIC is a family of general-purpose, high-level programming languages whose design philosophy emphasizes ease of use - the name is an acronym from Beginner's All-purpose Symbolic Instruction Code....

s RUN
Run command
On the Microsoft Windows operating system, the Run command is used to directly open an application or document whose path is known. It functions more or less like a single-line command line interface....

 is an example of a direct mode command.) Some commands could be used in either mode, others were exclusive to one or the other. Direct mode was most often used on 8-bit
8-bit
The first widely adopted 8-bit microprocessor was the Intel 8080, being used in many hobbyist computers of the late 1970s and early 1980s, often running the CP/M operating system. The Zilog Z80 and the Motorola 6800 were also used in similar computers...

 systems such as the Commodore 64
Commodore 64
The Commodore 64 is an 8-bit home computer introduced by Commodore International in January 1982.Volume production started in the spring of 1982, with machines being released on to the market in August at a price of US$595...

 and Atari 800 series, though commands entered at a unix shell
Unix shell
A Unix shell is a command-line interpreter or shell that provides a traditional user interface for the Unix operating system and for Unix-like systems...

 can be thought of as direct mode equivalents to shell script
Shell script
A shell script is a script written for the shell, or command line interpreter, of an operating system. It is often considered a simple domain-specific programming language...

s, and modern interpreted languages like Python
Python (programming language)
Python is a general-purpose, high-level programming language whose design philosophy emphasizes code readability. Python claims to "[combine] remarkable power with very clear syntax", and its standard library is large and comprehensive...

 and Perl
Perl
Perl is a high-level, general-purpose, interpreted, dynamic programming language. Perl was originally developed by Larry Wall in 1987 as a general-purpose Unix scripting language to make report processing easier. Since then, it has undergone many changes and revisions and become widely popular...

include shells where commands may be entered for immediate evaluation and execution.

Example

Non-direct mode:


10 PRINT "HELLO WIKIPEDIA"

READY.

RUN

HELLO WIKIPEDIA

READY.
Direct mode:


PRINT "HELLO WIKIPEDIA"

HELLO WIKIPEDIA

READY.
The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK