subject

Write an ARM Assembly program that will calculate the area of the following four plane shapes: a) Triangle b) Rectangle c) Trapezoid d) Square All number inputs are integers and all calculation results are provided in integer format. Any fractional calculations are to be truncated. The program must all meet the following requirements: 1. Each area calculation must be accessed as a subroutine/function (ARM instruction BL). 2. The operands are passed to the function via the stack. Use the ARM pseudo instructions PUSH and POP. To ensure you are properly implementing the stack the registers used in your main routine to hold the operands must be different than those used in the subroutines. For example, your calling routine will push r4 and r5 on the stack but the called routine will pop into registers r10 and ril. 3. The function returns the results on the top of the stack. 4. Your program is to print a welcome/instruction messages to the user. 5. The user is prompted to enter the calculation type and the appropriate number of positive integers. 6. The program shall verify the user input is valid and report any entry errors. Ensure your program checks for non-integer inputs (string, floating-point, characters). Invalid entries are reported and user prompted again to enter a valid input. 7. The program shall perform the calculation, display the results and report any overflow errors. Overflow is when the results do not fit into 32-bit unsigned format. 8. Ask the user if they want to continue with another calculation or quit the program.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 02:00
Which of the following is a way the operating system prevents unknown or unauthorized users from accessing the system?
Answers: 2
question
Computers and Technology, 24.06.2019 00:30
Setting up a home network using wireless connections is creating a a. vpn b. lan c. wan d. mini-internet
Answers: 2
question
Computers and Technology, 24.06.2019 14:40
Create a function (prob3_6) that will do the following: input a positive scalar integer x. if x is odd, multiply it by 3 and add 1. if the given x is even, divide it by 2. repeat this rule on the new value until you get 1, if ever. your program will output how many operations it had to perform to get to 1 and the largest number along the way. for example, start with the number 3: because 3 is odd, we multiply by 3 and add 1 giving us 10. 10 is even so we divide it by 2, giving us 5. 5 is odd so we multiply by 3 and add one, giving us 16. we divide 16 (even) by two giving 8. we divide 8 (even) by two giving 4. we divide 4 (even) by two giving 2. we divide 2 (even) by 2 to give us 1. once we have one, we stop. this example took seven operations to get to one. the largest number we had along the way was 16. every value of n that anyone has ever checked eventually leads to 1, but it is an open mathematical problem (known as the collatz conjectureopens in new tab) whether every value of n eventually leads to 1. your program should include a while loop and an if-statement.
Answers: 3
question
Computers and Technology, 24.06.2019 20:00
Individuals suffering from technology overload feel distressed when deprived of computers and mobile devices.true/fasle
Answers: 2
You know the right answer?
Write an ARM Assembly program that will calculate the area of the following four plane shapes: a) Tr...
Questions
question
English, 05.04.2021 17:30
question
English, 05.04.2021 17:30
question
Chemistry, 05.04.2021 17:30
Questions on the website: 13722361