Answered step by step
Verified Expert Solution
Question
1 Approved Answer
ACTIVITY 1 Read the problem and write codes to make the correct operation. 1-1. We want to read the value from the PIND and make
ACTIVITY 1 Read the problem and write codes to make the correct operation. 1-1. We want to read the value from the PIND and make the five outputs through the PORTB in sequence. We assume the reading value from the PIND is in binary 00101100 ($20 in hex). The output through PORTB will be different based on the value changes of the register R16 that we load the value of PIND reading to this register R16 as followings, PORTB 00000001 when R16 is equal to $2C PORTB 00000010 when R16 is equal to $2A PORTB 000000100 when R16 s equal to $28 PORTB 3 00001000 when R16 s equal to $26 PORTB 00010000 when R16 s equal to $24 (1) Write a code to make this operation using lo registers and IN/OUTinstruction. (2) You cannot run the part (1) code due to the input reading operation. Therefore, you can use another instruction to do the same operation such as LDS. Write a code using alternative instruction to run the operation and to observe the output value at the PORTB (3) Check the operation using ATMEL STUDIO 7 simulation and demonstrate your result. 1-2. We want to send the counting value of the corresponding ASCII characters (letters and numbers) through the PORTA and PORTD. The outputs of the PORTA will be the counted value of the ASCII character between A and Z (Capital Alphabet). And the outputs of the PORTD will be the counted value of the ASCII characters between 1 and 9 (numbers). (See the table 1.1) The operational detail is shown below, When 20 ASCII character value between A and Z Let say R20 PORTA When 20 ASCII character value between 1 and 9 Let say R20 19' 11' T1' "5', 13' "1' PORTB ACTIVITY 1 Read the problem and write codes to make the correct operation. 1-1. We want to read the value from the PIND and make the five outputs through the PORTB in sequence. We assume the reading value from the PIND is in binary 00101100 ($20 in hex). The output through PORTB will be different based on the value changes of the register R16 that we load the value of PIND reading to this register R16 as followings, PORTB 00000001 when R16 is equal to $2C PORTB 00000010 when R16 is equal to $2A PORTB 000000100 when R16 s equal to $28 PORTB 3 00001000 when R16 s equal to $26 PORTB 00010000 when R16 s equal to $24 (1) Write a code to make this operation using lo registers and IN/OUTinstruction. (2) You cannot run the part (1) code due to the input reading operation. Therefore, you can use another instruction to do the same operation such as LDS. Write a code using alternative instruction to run the operation and to observe the output value at the PORTB (3) Check the operation using ATMEL STUDIO 7 simulation and demonstrate your result. 1-2. We want to send the counting value of the corresponding ASCII characters (letters and numbers) through the PORTA and PORTD. The outputs of the PORTA will be the counted value of the ASCII character between A and Z (Capital Alphabet). And the outputs of the PORTD will be the counted value of the ASCII characters between 1 and 9 (numbers). (See the table 1.1) The operational detail is shown below, When 20 ASCII character value between A and Z Let say R20 PORTA When 20 ASCII character value between 1 and 9 Let say R20 19' 11' T1' "5', 13' "1' PORTB
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started