Programming (LMC) Flashcards
1
Q
LDA
A
Load contents of address into ACC
2
Q
STA
A
Store contents of ACC to given address
3
Q
ADD
A
Add contents of location to value in ACC
4
Q
SUB
A
Subtract contents of location from ACC
5
Q
INP
A
Copy value from the “inbox” to the ACC
6
Q
OUT
A
Copy value from ACC to “out” box
7
Q
HLT
A
stop executing the program
8
Q
BRZ
A
Branch if zero - if ACC contents are 000, PC will be set to the given address
9
Q
BRP
A
If negative flag is not set (i.e. ACC >= 000) the PC will be set to the given address
10
Q
BRA
A
Sets the contents of the PC to the given address
11
Q
DAT
A
When the code is compiled, the address given will be reserved for storage rather than holding compiled code