BCSL022 - Assembly Language Programming Lab

Download Solution Order New Solution

Assignment Task

Questions

1. Design a two-bit down counter circuit that does reverse counting. It should have states 11, 10, 01, and 00. The initial state of the counter may be assumed to be 11. The counter will be in following successive states: 11, 10,01, 00,11, 10, 01, 00, 11,... Use J-K flip flop to design the circuit. You must design the circuit using state transition diagram and Karnaugh's maps.

2. Write and run following programs using 8086 assembly language.

(a) Write and run an 8086-assembly language program that accepts two input digits from the keyboard and converts it into a two-digit packed BCD number. This resultant number should be stored in a byte location in the memory. For example, if you input digit '3' and '5' then it will be converted to packed BCD number 35, which is 001101012. This result should be stored in a byte memory location.

(b) Write and run (using appropriate calling program) a near procedure in 8086-assembly language, which is passed a single parameter by the calling program. The procedure checks if the input parameter is divisible by 5 or not. If the input parameter is divisible by 5, then a value of 1 is returned to the calling program, else a value 0 is returned. The calling program based on the returned value prints "Divisible" or "NOT Divisible". You may assume that the parameter value would always be greater than or equal to 1. Make and state suitable assumptions, if any.

(c) Write and run an 8086-assembly language program that computes the multiplication of 5 natural numbers, starting from number 2. You should use the looping construct to write this program. The result is stored in a word memory location. Make and state suitable assumptions, if any.

This BCSL022Engineering has been solved by our PHD Experts at My Uni Paper.

Get It Done! Today

Country
Applicable Time Zone is AEST [Sydney, NSW] (GMT+11)
+

Every Assignment. Every Solution. Instantly. Deadline Ahead? Grab Your Sample Now.