1.2 Systems software & development
Types of programming language
Assembly language
Short, precise commands that provide greater control over the computer’s components.
Little Man Computer
Opcodes for low level instructions:
Code | Description |
HLT | Stops program execution |
ADD | Adds the contents of the memory address from the accumulator |
SUB | Subtracts the contents of the memory address from the accumulator |
STA | Stores the contents of the accumulator in the memory address given |
LDA | Loads the accumulator with the contents of the memory address given |
BRA | Branches to the address given, always. |
BRZ | Branches to the address given, if the accumulator is zero. |
BRP | Branches to the address given, if the accumulator is zero or positive. |
INP | Asks the user for a number and puts it into the accumulator. |
OUT | Outputs the contents of the accumulator. |
DAT | Stores data in a variable, declared. |
OTC | Outputs a character in ASCII. |
Addressing modes
There are different types of addressing modes.
Direct | Takes the data from the contents of the memory location addressed. |
Indirect | Takes the data from the address of the contents of the memory location addressed. |
Immediate | Takes the data from the value addressed. E.g LDA 8 would be 8. |
Indexed | Takes the data held in the the memory location of the address + the index (held in index register) |
Symbolic | Takes the data held in a tag. E.g STA total |