소스 검색

Implement memory module

sindre-ex1
Sindre Stephansen 6 년 전
부모
커밋
c451f113b8
1개의 변경된 파일10개의 추가작업 그리고 3개의 파일을 삭제
  1. +10
    -3
      src/main/scala/MEM.scala

+ 10
- 3
src/main/scala/MEM.scala 파일 보기

@@ -18,6 +18,11 @@ class MemoryFetch() extends MultiIOModule {

val io = IO(
new Bundle {
val dataIn = Input(UInt(32.W))
val dataAddress = Input(UInt(32.W))
val writeEnable = Input(Bool())

val dataOut = Output(UInt(32.W))
})


@@ -35,7 +40,9 @@ class MemoryFetch() extends MultiIOModule {
/**
* Your code here.
*/
DMEM.io.dataIn := 0.U
DMEM.io.dataAddress := 0.U
DMEM.io.writeEnable := false.B
DMEM.io.dataIn := io.dataIn
DMEM.io.dataAddress := io.dataAddress
DMEM.io.writeEnable := io.writeEnable

io.dataOut := DMEM.io.dataOut
}

불러오는 중...
취소
저장