This demonstrates some of the aspects of machine and assembly language programming.
This applet was originally written by Barry G. Adams of Laurentian University. Several features were added by Curt Hill.
The following table shows the instructions that are available for this computer:
|Mnemonic||Code (1st word)||Code (2nd word)||Description|
|STORE||160||n||Store the contents of AX in memory location n|
|LOAD||161||n||Load AX with the contents of location n|
|ADDI||44||n||Add n to AX (add immediate)|
|SUBI||45||n||Subtract n from AX (subtract immediate)|
|ADD||50||n||Add the contents of location n to AX|
|SUB||51||n||Subtract the contents of location n from AX|
|MUL||52||n||Multiply the contents AX by the contents of location n|
|DIV||53||n||Divide the contents of AX by the contents of location n|
|INPUT||71||n||Enable input button and accept input into location n|
|OUTPUT||72||n||Output the contents of location n|
|JPOS||127||n||Jump to the instruction in location n if AX > 0|
|JZERO||128||n||Jump to the instruction in location n if AX = 0|
|HALT||0||Halt the execution|
The Java source in a zip file.
Return to the simulators page.
Curt's Home Page.
Last time I updated this page: February 17, 2012