Computer Organization
Computer Organization
Computer Organization
Computer Organization
Please I want a 100% working program so if you're not sure about it do not solve it, Thanks
I want screenshots of the program and the results as well, and
would you please be kind and post the codes as a text so I can test
it, Thank you so much for your help
MIPS program to find the volume of the given sphere.
Hope this helps...
Thankyou..... :)
DATA SEGMENT
R DB ?
RES DB 10 DUP ('$')
MSG1 DB "ENTER RADIUS : $"
MSG2 DB 10,13,"VOLUME : $"
DATA ENDS
CODE SEGMENT
ASSUME DS:DATA,CS:CODE
START:
MOV AX,DATA
MOV DS,AX
LEA DX,MSG1
MOV AH,9
INT 21H
MOV AH,1
INT 21H
SUB AL,30H
MOV R,AL
MOV AH,0
MUL R
MUL R
MOV DL,88
MUL DL
MOV DX,0
MOV BX,21
DIV BX
LEA SI,RES
CALL HEX2DEC
LEA DX,MSG2
MOV AH,9
INT 21H
LEA DX,RES
MOV AH,9
INT 21H
MOV AH,4CH
INT 21H
CODE ENDS
HEX2DEC PROC NEAR
MOV CX,0
MOV BX,10
LOOP1: MOV DX,0
DIV BX
ADD DL,30H
PUSH DX
INC CX
CMP AX,9
JG LOOP1
ADD AL,30H
MOV [SI],AL
LOOP2: POP AX
INC SI
MOV [SI],AL
LOOP LOOP2
RET
HEX2DEC ENDP
END START
Here is the solution to above problem in assembly language. Please read the code comments for more information and give a thumbs up if you like the solution
ASSEMBLY CODE
DATA SEGMENT R DB ? RES DB 10 DUP('$') MSGO DB 10,13, "THE VOLUME OF THE SPHERE IS: $" #OUTPUT MSG MSGI DB "ENTER THE VALUE FOR RADIUS : $" # INPUT MSG DATA ENDS CODE SEGMENT ASSUME DS:DATA, CS:CODE START: MOV AX,DATA MOV DS,AX LEA DX,MSGI MOV AH,9 INT 21H MOV AH,1 INT 21H SUB AL,30H MOV R,AL MOV AH,0 MUL R MUL R MOV DL,88 MUL DL MOV DX,0 MOV BX,21 DIV BX LEA SI,RES CALL HEX2DEC LEA DX,MSG0 MOV AH,9 INT 21H LEA DX,RES MOV AH,9 INT 21H MOV AH,4CH INT 21H CODE ENDS
SCREENSHOT OF OUTPUT
Computer Organization Computer Organization Computer Organization Computer Organization Please I want a 100% working program so...
Write the codes as a text so I can copy them pls.
ALso, post a picture for testing by using
MARS
Dont forget to coment each step pls
Write a complete MIPS-32 assembly language program including data declarations that uses a function "Eval-Z', which evaluates the following expression Z = X-3(Y/ 8 + 125). Assume that caller program passes the values of X and Y to the function using registers Sa0 and Sal respectively while the result of executing the...
MIPS - assembly language Task I (1 mark): Write a program to calculate the nth Fibonacci number based on an iterative approach where value n is read from the keyboard and stored in your main program that is calling fib. The main program reads number ‘n’ -- restrict range of ‘n’ to 2-50, and display an error message if this condition is not satisfied. The main program calls fib with parameter passing. Procedure fib should return the calculated...
Please put the outputs with it also I want to make sure it
runs thanks
Project-Computer-Assisted Instruction (50 points) use of computers in education is referred to as computer-assisted instruction (CAl) should then Writ e a program that will help an elementary school student learn multiplication. Use the rand function to produce two positive one-digit integers. The program prompt the user with a question, such as How much is 6 times 7? The student then inputs the answer. Next, the...
I'm trying to write a program that can ask a user about what type of solid they have and to be able to enter values like radius and length of the shape so the program can calculate the volume of a shape and print the result. I also want to give them a repeating option to input another shape if they want to. I'm trying to use at least 7 functions that can display an output, the volumes of a...
IN MIPS PLEASE. Need help writing a MIPS program that reads from a text file named "input.txt" and places it in a buffer. A buffer of 80 bytes is more than enough. Before you call your function, set $a0 equal to the address of the filename and $a1 to the address of the buffer where data is stored. The function should return the number of bytes read in $v0. In the main program, print an error message and terminate the...
5 Exercises Now that everything is working you can try the following exercises. To complete them you will need to refer to the documentation in Appendix A- The MiteASM Assembler and Appendix B - The MiteFPGA Processor. Write an assembly language program for an over counter for a cricket umpire. This should display a count on the 7-segment display. The count should increase by 1 when button 0 is 1. pressed. It should reset to 0 when button 1 is...
There is an example below
Now that everything is working you can try the following exercises. To complete them you will need to refer to the documentation in Appendix A The MiteASM Assembler and Appendix B The MiteFPGA Processor. Write an assembly language program for an over counter for a cricket umpire. This should 1. display a count on the 7-segment display. The count should increase by 1 when button 0 is pressed. It should reset to 0 when button...
Please answer these questions
and please show your code this assignment is all correlated so feel
free to use whatever program you'd like. Thank you very much.
This is a programming assignment. You can use any programming language you like You have to submit your computer codes along with the homework. 1. We will now have a look at computer simulations of continuous random variables. (a) Let X be a continuous random variable that is uniformly distributed on 0, 1]....
****************************************************************************************************************8
I want it same as the output and with details please and
comments
"For two thousand years, codemakers have fought to preserve
secrets while codebreakers have tried their best to reveal them." -
taken from Code Book, The Evolution of Secrecy from Mary, Queen of
Scots to Quantum Cryptography by Simon Singh.
The idea for this machine problem came from this book.You will
encrypt and decrypt some messages using a simplified version of a
code in the book. The...
Please provide the full and correct solution to this
problem.
Make sure to provide comments so I can understand what is going
on.
Correct solution will receive thumbs up.
Thanks.
Write a program that generates an array filled up with random positive integer number ranging from 15 to 20, and display it on the screen. After the creation and displaying of the array, the program displays the following: [Plosition [RJeverse, [Ajverage, [SJearch, [Qjuit Please select an option: Then, if the...