Created CPU9bits file
This commit is contained in:
43
lab2CA.srcs/sources_1/new/CPU9bits.v
Normal file
43
lab2CA.srcs/sources_1/new/CPU9bits.v
Normal file
@@ -0,0 +1,43 @@
|
||||
`timescale 1ns / 1ps
|
||||
|
||||
module CPU9bits(input wire [8:0] instr,
|
||||
input wire reset, clk,
|
||||
output reg done
|
||||
);
|
||||
|
||||
wire [8:0] op1, op2;
|
||||
|
||||
RegFile RF(
|
||||
.clk(clk),
|
||||
.reset(reset),
|
||||
.enable(),
|
||||
.write_index(),
|
||||
.op0_idx(),
|
||||
.op1_idx(),
|
||||
.write_data(),
|
||||
.op0(op0),
|
||||
.op1(op1)
|
||||
);
|
||||
|
||||
FetchUnit FU(
|
||||
.clk(clk),
|
||||
.reset(reset),
|
||||
.op_idx(),
|
||||
.AddrIn(),
|
||||
.AddrOut()
|
||||
);
|
||||
|
||||
ALU alu(
|
||||
.opcode(),
|
||||
.operand0(op0),
|
||||
.operand1(op1),
|
||||
.result()
|
||||
);
|
||||
|
||||
//Make control unit here
|
||||
|
||||
|
||||
|
||||
//------------------------------
|
||||
|
||||
endmodule
|
||||
@@ -16,6 +16,7 @@ module RegFile(input wire clk, reset, enable,
|
||||
.regOut(decOut)
|
||||
);
|
||||
|
||||
|
||||
register r0(
|
||||
.clk(clk),
|
||||
.reset(reset),
|
||||
|
||||
10
lab2CA.xpr
10
lab2CA.xpr
@@ -3,7 +3,7 @@
|
||||
<!-- -->
|
||||
<!-- Copyright 1986-2018 Xilinx, Inc. All Rights Reserved. -->
|
||||
|
||||
<Project Version="7" Minor="39" Path="C:/Users/ecelab/ECE3570-Lab/lab2CA.xpr">
|
||||
<Project Version="7" Minor="39" Path="C:/Users/JoseIgnacio/CA Lab/lab2CA.xpr">
|
||||
<DefaultLaunch Dir="$PRUNDIR"/>
|
||||
<Configuration>
|
||||
<Option Name="Id" Val="0a5803efda44405bb28bbf43ba22e808"/>
|
||||
@@ -89,6 +89,14 @@
|
||||
<Attr Name="UsedIn" Val="simulation"/>
|
||||
</FileInfo>
|
||||
</File>
|
||||
<File Path="$PSRCDIR/sources_1/new/CPU9bits.v">
|
||||
<FileInfo>
|
||||
<Attr Name="AutoDisabled" Val="1"/>
|
||||
<Attr Name="UsedIn" Val="synthesis"/>
|
||||
<Attr Name="UsedIn" Val="implementation"/>
|
||||
<Attr Name="UsedIn" Val="simulation"/>
|
||||
</FileInfo>
|
||||
</File>
|
||||
<Config>
|
||||
<Option Name="DesignMode" Val="RTL"/>
|
||||
<Option Name="TopModule" Val="FetchUnit"/>
|
||||
|
||||
Reference in New Issue
Block a user