please help 4. Consider the following assembly-language program. Starting values: [A] - $60, [B]- $80, [SC300]...
this is assembly language for HCS12 / 9S12 4. Consider the following assembly-language program. Starting values: [A] = $60, [B] = $80, [$C300] = $20, [$C301] = $40 (Hint: [$C300) means "contents of memory location $C300".) $C300 $C301 ADDA LDAB SBA BEO STAA STAB WAI X1 $1301 $C300 X1: ; "WAI" basically means "stop" What values are in A, B, memory location $C300, and memory location $C301 when the program finishes? [A] = — [B]= _ [$C300] = - [$C301)...
DO 2 AND 3. Question #1 Convert the following assembly program into machine code. LDAA WSA1 STAA $1000 INCA LDAB $1000 DECB ABA Here: Bra Here Question # 2 (a) in Question # 1, determine the values of PC, A, B, N, Z, V, C after each instruction (b) Verify your answers by using CodeWarrior Question # 3 Assume that the program in Question 1 is saved in memory starting at location $COOA. Drawa memory diagram showing the contents (in...
Complete the following Intel assembly language program which determines whether the byte sized operand stored in memory location 'number' is prime or not. The program will write the value of 0 into the memory location 'answer' if the number is not prime, otherwise the initial value of '1' will be left unmodified (indicating that the number is prime). The program makes use of the DIV instruction to determine the value of quotient and remainder when dividing the number by 2,3,4,......