+1 678 648 4277 

PEP/9 Assembly Code for Printing Message using Direct Addressing

Programming exercises in PEP9 computer assembly assignment help

LDBA 0x19,d STBA charOut,d LDBA 0x1A,d STBA charOut,d LDBA 0x1B,d STBA charOut,d LDBA 0x1C,d STBA charOut,d STOP .ASCII "CISC" .END BR start num1: .BLOCK 2 num2: .BLOCK 2 start: DECI num1,d ; scanf("%d %d", &num1, DECI num2,d ; &num2); DECO num1,d ; printf("%d\n%d\n", num1, LDBA '\n',i STBA charOut,d DECO num2,d ; num2); LDBA '\n',i STBA charOut,d STOP .END BR start amount: .WORD 20000 num: .BLOCK 2 sum: .BLOCK 2 msg: .ASCII "sum = \x00" start: DECI num,d ; scanf("%d", &num) LDWA num,d ; A = num ADDA amount,d ; A = num + amount STWA sum,d ; sum = num + amount STRO msg,d ; printf("sum = %d\n", sum); DECO sum,d LDBA '\n',i STBA charOut,d .END