The NCS/e Shell
The NCS/e shell is the command-line interface used to start programs.
After startup completes, or whenever execution returns to the shell, the following prompt appears:
>
A blinking cursor indicates that the shell is ready for a command.
Running a program
Use RUN followed by the name of a program to start it.
For example:
> RUN CHESS
Press Enter to run the command.
The shell finds CHESS and starts the program immediately.
While the program is running, the shell is no longer accepting commands. When the program finishes, control returns to the shell and a new prompt appears:
>
You can then enter another command.
Programs may use the display and keyboard while they are running, so what you see between starting a program and returning to the shell depends on the program.
Stopping a program
Press ABORT on a standard NCS/e keyboard to immediately stop the currently running program.
Pressing Ctrl+C performs the same action.
After the program stops, control normally returns to the shell:
>
ABORT is useful if a program is taking too long, waiting for input you do not want to provide, or otherwise doing something you want to stop.
To restart the entire computer instead, use RESET.
RESET is different from ABORT: rather than stopping only the running program, RESET restarts the NCS/e.
See Booting the NCS/e for more information about ABORT, RESET, and the power controls.
Fatal errors
Sometimes a program cannot continue.
When a program encounters a fatal error, execution stops and the NCS/e returns to the shell.
The shell displays a prominent red error banner containing the error reported by the program and the line number at which the error occurred.
The line number can help identify where the problem happened if you are writing or troubleshooting the program.
After displaying the error, the shell presents a new prompt and is ready for another command.
You do not need to understand or fix every fatal error yourself. If the error occurs while running software written by someone else, the error message and line number may be useful information to give its author.
Running several programs
Normally, you can run a program, wait for it to finish, and then start another from the shell.
The NCS/e can also keep programs waiting and run them one after another automatically.
This is called the execution queue.
Continue to The Execution Queue to learn how to arrange several programs for execution.