$25
Question 1: Verilog Part
You will implement a modified version Bird in Verilog and write the specified software that will run on it.
In the website;
http://www.marmaralectures.com/reference-for-second-project/
There is code for the Bird CPU, the keypad, 7-segment display, the main module, and the assembler with some missing sections (marked with the remark "to be added").
• Increase the address bus of the BIRD CPU given in the class to 16 bits. All the other properties of the BIRD CPU, ie. data bus width, number of registers etc., must remain same. Do all the necessary changes to the instruction set, FSM and assembler. Do not add or remove instructions. In other words, the address space of the CPU must be upgraded to 64k.
• Modify and complete all the codes given in the link,
• Load it into the FPGA kit,
• Connect the keypad and the 7-segment monitor to FPGA and run.
Write an assembly program in Modified Bird which will turn your hardware into a pocket calculator which is capable of adding and multiplying numbers.
• # key will act as sum (ie, +)
• * key will act as multiplication (ie, *)
• ‘A’ key will act as reset
There will be no "previlege" in calculations, ie, if you enter 3#2*10 the result will be 50, not 23. Or, in other words, + and * will have the same privilege.
In your code, you must have at least two function calls, "call addit" and "call mult", to perform addition and multiplication after you finish entering a number and press * or #.
Your calculator must read the numbers from the keypad and display them in decimal on seven segment display. To display your result in decimal, you must write an additional piece of code (Assembly code not in Verilog) to convert your hexadecimal result into decimal (or binary coded decimal, BCD). You must do this in software and NOT in hardware. Some hints on how this can be done is described in the following link:
https://my.eng.utah.edu/~nmcdonal/Tutorials/BCDTutorial/BCDConversion.html Disregard "BCD conversion in hardware" part.
There is an accompanying video which shows how the system you will build should work. (Note that in this video numbers are hexadecimal but you will implement it as decimal)
Question 2: Logisim Part
You will implement Modified Bird defined in question 1 in Logisim and write the specified software that will run on it.
You have;
--Modified Bird CPU (Defined in question 1)
--Two 16-bit switchboards, switchboards 1 and 2
--Two Push Button, PB1 and PB2
--One 4*7-segment display
Your assembly program will have a variable sum, which is initialized to sum=0 at the beginning. Then your code will continuously poll the 16- bit switchboards (16-bit pins).
-- If PB1 is pressed, you will read the number from switchboard 1, calculate sum=2*sum+(entered number), display new sum on 4*7-segment register. -- If PB2 is pressed, you will read the number from switchboard 2, calculate sum=sum*(entered number), display new sum on 4*7-segment register.
The numbers must be converted to decimal before displaying. The conversion process must be done in software in a function written for this purpose. Hardware solutions won’t be accepted.