Little Man Computer (LMC)
with Exercises
(htt)
Dasun Randesh.
University of Moratuwa, Sri Lanka.
1
, Introduction
LMC was created by Dr. Stuart Madnick in 1965, and a new version was proposed
in 1979. LMC uses the von Neumann architecture.
LMC online simulator: https://www.peterhigginson.co.uk/LMC/
Instructions
Operation code (OP code)
5 | 28
Instruction | memory address
LDA 5xx Load
STO 3xx Store
ADD 1xx Add
SUB 2xx Subtract
IN 901 Input
OUT 902 Output
COB or HLT 000 Coffee break (or Halt)
BRZ 7xx Branch if zero
BRP 8xx Branch if positive or zero
BR 6xx Branch unconditional
DAT Data storage location
➢ LOAD (LDA)
• Opcode: 5xx
• The little man reads the xx-memory address and loads it into the
calculator.
• The existing calculator value is updated with a new load value.
2
with Exercises
(htt)
Dasun Randesh.
University of Moratuwa, Sri Lanka.
1
, Introduction
LMC was created by Dr. Stuart Madnick in 1965, and a new version was proposed
in 1979. LMC uses the von Neumann architecture.
LMC online simulator: https://www.peterhigginson.co.uk/LMC/
Instructions
Operation code (OP code)
5 | 28
Instruction | memory address
LDA 5xx Load
STO 3xx Store
ADD 1xx Add
SUB 2xx Subtract
IN 901 Input
OUT 902 Output
COB or HLT 000 Coffee break (or Halt)
BRZ 7xx Branch if zero
BRP 8xx Branch if positive or zero
BR 6xx Branch unconditional
DAT Data storage location
➢ LOAD (LDA)
• Opcode: 5xx
• The little man reads the xx-memory address and loads it into the
calculator.
• The existing calculator value is updated with a new load value.
2