https://github.com/samankhamesian/special-purpose-processor
This project is an implementation of a special-purpose processor that can calculate greatest common multiple (GCM) and least common factor (LCM) for two inputs based on input operation code (Opcode)
https://github.com/samankhamesian/special-purpose-processor
controller de2-115 fpga gcm lcm processor quartus-prime state-machine vhdl
Last synced: 3 months ago
JSON representation
This project is an implementation of a special-purpose processor that can calculate greatest common multiple (GCM) and least common factor (LCM) for two inputs based on input operation code (Opcode)
- Host: GitHub
- URL: https://github.com/samankhamesian/special-purpose-processor
- Owner: SamanKhamesian
- License: apache-2.0
- Created: 2019-03-23T19:56:04.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2019-07-18T14:31:05.000Z (almost 6 years ago)
- Last Synced: 2024-01-29T23:13:48.176Z (over 1 year ago)
- Topics: controller, de2-115, fpga, gcm, lcm, processor, quartus-prime, state-machine, vhdl
- Language: Verilog
- Homepage:
- Size: 96.7 KB
- Stars: 3
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Special-Purpose-Processor
### Abstract
The main objective of this project was to build a special-purpose processor that can calculate greatest common multiple (GCM) and least common factor (LCM) based on input operation code (opcode). At first I design a datapath and controller for this processor and synchronized them with system clock that implemented using Verilog HDL language.
At the end I implement this code on FPGA. (Use Altera DE2-115 board and Cyclone IV EP4CE115 micro-controller)
##### System Design
For this processor, two main modules must have designed.
* Datapath : Contanis registers, multiplexers, ALU and comparator. Their values are updated according to the next state.
* Controller : Specify the next state based on datapath outputs.
##### State Machine
In the controller, the next state is specified based on comparator outputs. Three states are avialable for our state machine.
![]()
#### Testbench
The result of the system for calculating GCM and LCM for 6 and 4 inputs is shown below.