Chapter 28 Low-level Programming Flashcards
Which are the Data movement instructions used in the Processor?
LDM #n //Immediate addressing. Load the number n to ACC
LDD <address> //Direct addressing. Load the contents of the location at the given address to ACC
LDI <address> //Indirect addressing. The address to be used is at the given address. Load the contents of this second address to ACC
LDX <address> //Indexed addressing. Form the address from <address>+ the contents of the index register. Copy the contents of this calculated address to ACC
LDR #n //Immediate addressing. Load the number to IX
STO <address> //Immediate addressing. Load the number n to IX
STX <address> //Indexed addressing. Form the address from <address>+ the contents of the index • register. Copy the contents from ACC to this calculated address
STI <address> //Indirect addressing. The address to be used is at the given address. Store the contents of ACC at this second address
</address></address></address></address></address></address></address></address>
Which are the Arithmetic operations used in the Processor?
ADD <address> //Add the contents of the given address to the ACC
INC //Add 1 to the contents of the register (Ace or IX)
DEC //Subtract 1 from the contents of the register (ACC or IX) </address>
Which are the Comparison and jump instructions used in the Processor?
JMP <address> //Jump to the given address
CMP <address> //Compare the contents of ACC with the contents of <address>
CMP #n //Compare the contents of ACC with n
JPE <address> //Following a compare instruction,jump to <address> if the compare was True
JPN <address> //Following a compare instruction, jump to <address> if the compare was False </address></address></address></address></address></address></address>
Which are the Input and output instructions used in the Processor?
IN //Key in a character and store its ASCII value in ACC
OUT //Output to the screen the character whose ASCII value is stored in ACC
Which are the Bit manipulation instrcutions used in the Processor?
AND #n //Bitwise AND operation of the contents of Ace with the operand
AND <address> //Bitwise AND operation of the contents of ACC with the contents of <address>
XOR #n //Bitwise OR operation of the contents of Ace with the operand
XOR <address> //Bitwise XOR operation of the contents of Ace with the operand
OR #n //Bitwise OR operation of the contents of ACC with the operand
OR <address> //Bitwise OR operation of the contents of ACC with the contents of <address>
LSL #n //Bits in Ace are shifted n places to the left. Zeros are introduced on the right hand end
LSR #n //Bits in Ace are shifted n places to the right. Zeros are introduced on the left hand end
</address></address></address></address></address>
Which is the instruction used to return control to the operating system?
END //Retrun control to the operating by ending the process
What is the structure of an instruction?
:
What is the structure of assigning data to a label?
:
What does in the assembly code in this chapter ACC mean?
Accumulator
What does in the assembly code in this chapter IX mean?
Indexed Register
What does in the assembly code in this chapter # mean?
Immediate addressing
What does in the assembly code in this chapter B mean?
A binary number
When & occurs what does it mean?
When & occurs it means that a hexadecimal code is written for example &4A
What does in the assembly code in this chapter <address> mean?</address>
<address> can be an absolute address or a symbolic address</address>
How to assign 34 to A in assembly code?
LDM #34
STO A