Question: The LC-3 code below displays the Ascii character '2' indefinitely, and when a key is pressed, a trap exception occurs. Modify the program to make
The LC-3 code below displays the Ascii character '2' indefinitely, and when a key is pressed, a trap exception occurs. Modify the program to make it handle the keyboard interrupt by displaying the character on screen without using the polling method. Include externally linked code.
.ORIG x3000 LD R3, A STI R3, KBSR AGAIN LD R0, B TRAP x21 BRnzp AGAIN A .FILL x4000 B .FILL x0032 KBSR .FILL xFE00 .END
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
