-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTile.scala
71 lines (48 loc) · 2.04 KB
/
Tile.scala
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
package Core
import Chisel._
class Tile(data_width: Int, cols: Int, rows: Int) extends Module{
val io = new Bundle {
val data_in = UInt(INPUT, data_width)
val reset = Bool(INPUT)
// val data_out = Vec.fill(rows){UInt(OUTPUT, data_width)}
}
val memory = Module(new PixelGrid(data_width, cols, rows)).io
// Wire data inputs and outputs
// io.data_out := memory.data_out
// memory.data_in := io.data_in
}
class CoreTest(c: Tile) extends Tester(c) {
step(1)
step(1)
for(i <- 0 until 60){
step(1)
}
}
object CoreMain {
def main(args: Array[String]): Unit = {
// chiselMainTest(args, () => Module(new Tile(24, 9, 3))) { c => new CoreTest(c) }
// Behaves
// chiselMainTest(args, () => Module(new PixelArray(24, 9))) { c => new PixelArrayTest(c, 24, 9) }
// Behaves
// chiselMainTest(args, () => Module(new Mux3(24, 3))) { c => new Mux3Test(c, 24, 3) }
// Behaves
// chiselMainTest(args, () => Module(new ShiftMux3(24, 3, 0))) { c => new ShiftMux3Test(c, 24, 3) }
// Behaves
// chiselMainTest(args, () => Module(new Orchestrator(9, 3))) { c => new OrchestratorTest(c, 24, 9) }
// Behaves
// chiselMainTest(args, () => Module(new PixelReg(24))) { c => new PixelRegTest(c, 24) }
// somewhat behaves
// chiselMainTest(args, () => Module(new PixelGrid(24, 9, 3))) { c => new PixelGridTest(c, 24, 9, 3) }
// Behaves
// chiselMainTest(args, () => Module(new ALUrow(24, 9))) { c => new ALUtest(c, 24, 9) }
// Behaves(?)
// chiselMainTest(args, () => Module(new PixelGrid(24, 9, 3))) { c => new Img_test(c, 24, 9, 3) }
// ???
chiselMainTest(args, () => Module(new PixelGrid(24, 9, 3))) { c => new image(c, 24, 9, 3) }
// Bretty gud :--DDD
// chiselMainTest(args, () => Module(new PixelGrid(24, 9, 3))) { c => new Snapshot(c) }
}
}
object Util {
def somefun(someval: Int) : Unit = {}
}