Little Man Computer: How to Use

Description| How to Use| LMC Programs| How it works

The little man computer is programmed using the programme editor on the left, controlled by the CPU controls and given inputs through the input registers on the right.

The LMC editor consists of a title line and 5 columns. The use of these columns is shown in the picture below. A drop down box is available for the selection of instructions. If the instruction does not require a further memory location (eg INPUT), the next cells is filled with a dotted pattern. Comments can be entered in the last column, these are for documentation of the code.

LMC Editor

Program files can be saved or loaded using the editor controls shown below. The "Create New" button can be used to clear the existing data from the editor. The "Load Program" is used for loading program files and the "Save Program" allows the programs to be saved from the editor to the user's computer. The files are saved in ".lmc" format, which is a comma separated variable format.

Editor controls

Once a program is ready, it can be loaded into the Little Man Computer's memory and executed using the program controls. "Load program" compiles and loads the program if there are no errors (like missing labels). "Execute" runs the programme and "Abort" terminates a running programme. Speed controls are provided to control the speed of execution. When the programme executes, the editor shows the line that is being executed, which helps debug the code.

CPU Controls

The Input and Output registers allow users to enter inputs and inspect program outputs. A sample for the "Add" program is shown below.

LMC Output