-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathindex.html
175 lines (154 loc) · 5.86 KB
/
index.html
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="https://fonts.googleapis.com/css?family=Ubuntu+Mono|Abel|Catamaran|Lato|Libre+Franklin|Rubik" rel="stylesheet">
<title>CMPT276 Group 4</title>
<link rel="stylesheet" href="normalize.css">
<link rel="stylesheet" href="main.css">
</head>
<body>
<div class="wrapper">
<h1> chip8 4tw </h1>
<div class="splitWrapper">
<canvas class ="shadow" id="canvas" width="560" height="280"></canvas>
<section class="visualizerWrapper whiteBox">
<section class="visualizer shadow" id="stack">
<h3>stack:</h3>
<div class="mriWrapper">
<div><p>0: </p> <p id="V0-Stack">0x0</p></div>
<div><p>1: </p> <p id="V1-Stack">0x0</p></div>
<div><p>2: </p> <p id="V2-Stack">0x0</p></div>
<div><p>3: </p> <p id="V3-Stack">0x0</p></div>
<div><p>4: </p> <p id="V4-Stack">0x0</p></div>
<div><p>5: </p> <p id="V5-Stack">0x0</p></div>
<div><p>6: </p> <p id="V6-Stack">0x0</p></div>
<div><p>7: </p> <p id="V7-Stack">0x0</p></div>
</div>
<div class="mriWrapper">
<div><p>8: </p> <p id="V8-Stack">0x0</p></div>
<div><p>9: </p> <p id="V9-Stack">0x0</p></div>
<div><p>a: </p> <p id="V10-Stack">0x0</p></div>
<div><p>b: </p> <p id="V11-Stack">0x0</p></div>
<div><p>c: </p> <p id="V12-Stack">0x0</p></div>
<div><p>d: </p> <p id="V13-Stack">0x0</p></div>
<div><p>e: </p> <p id="V14-Stack">0x0</p></div>
<div><p>f: </p> <p id="V15-Stack">0x0</p></div>
</div>
</section>
<section class="visualizer shadow" id="memory">
<h3>memory:</h3>
<div class="mriWrapper">
<div><p>PC: </p><p id="PC">0x0 </p></div>
<div><p>I: </p><p id="I">0x0 </p></div>
<div><p>SP: </p><p id="SP">0x0 </p></div>
<div><p>DT: </p><p id="DT">0x0 </p></div>
<div><p>ST: </p><p id="ST">0x0 </p></div>
<br>
</div>
<br>
<div class="mriWrapper">
<div><p>V0: </p> <p id="V0-Reg">0x0</p></div>
<div><p>V1: </p> <p id="V1-Reg">0x0</p></div>
<div><p>V2: </p> <p id="V2-Reg">0x0</p></div>
<div><p>V3: </p> <p id="V3-Reg">0x0</p></div>
<div><p>V4: </p> <p id="V4-Reg">0x0</p></div>
<div><p>V5: </p> <p id="V5-Reg">0x0</p></div>
<div><p>V6: </p> <p id="V6-Reg">0x0</p></div>
<div><p>V7: </p> <p id="V7-Reg">0x0</p></div>
</div>
<div class="mriWrapper">
<div><p>V8: </p> <p id="V8-Reg">0x0</p></div>
<div><p>V9: </p> <p id="V9-Reg">0x0</p></div>
<div><p>VA: </p> <p id="V10-Reg">0x0</p></div>
<div><p>VB: </p> <p id="V11-Reg">0x0</p></div>
<div><p>VC: </p> <p id="V12-Reg">0x0</p></div>
<div><p>VD: </p> <p id="V13-Reg">0x0</p></div>
<div><p>VE: </p> <p id="V14-Reg">0x0</p></div>
<div><p>VF: </p> <p id="V15-Reg">0x0</p></div>
</div>
</section>
</section>
<section class="visualizerWrapper whiteBox" id="visLogWrapper" >
<section class="visualizer shadow" id="visLog">
<h3>log</h3>
<div class="mriWrapper">
<div id="log">
<p id="welcome"> Welcome to group 4's chip8 emulator! <br>
Pick a rom and click <b>Run Emulation</b> to start! <br>
<b>Toggle Log On</b> Turns on the logs and instructions <br><p>
</div>
</div>
</section>
</section>
</div>
<div class="splitWrapper">
<section class="whiteBox" id="controls">
<form id="gameWrapper">
<h2 class="primaryH2">game: </h2>
<select name="games" id="games" onChange="updateGameFromSelect()">
<option value="default">choose a game</option>
<option value="snake">SNAKE</option>
<option value="flappy_bird">FLAPPY BIRD</option>
</select>
</form>
<h2 class="secondaryH2">rom input</h2>
<input type="file" id="file" />
<label for="file" id="fileUploadBox">upload a file</label>
<section id="stepControl">
<p class="stepControlActive" id="startEmulator">start emulation</p>
<p class="stepControlActive" id="runTest">run opcode test</p>
<h2 class="secondaryH2">step controls: </h2>
<div class="icon_wrapper">
<img src="Icons/-1.svg" class="icon stepControlInactive" id="stepBack" title="Step backwards one frame"></img>
<img src="Icons/pause.svg" class="icon stepControlActive" id="pause" title="Pause on current frame"></img>
<img src="Icons/play.svg" class="icon stepControlInactive" id="resume" title="Resume from current frame"></img>
<img src="Icons/+1.svg" class="icon stepControlInactive" id="stepForward" title="Step forwards one frame"></img>
</div>
<p class="stepControlActive" id="logToggle">toggle log on</p>
</section>
<section id="keyboardInput">
<ul>
<h2 class="secondaryH2">controls:</h2>
</ul>
<ul>
<li>1</li>
<li>2</li>
<li>3</li>
<li>4</li>
</ul>
<ul>
<li>q</li>
<li>w</li>
<li>e</li>
<li>r</li>
</ul>
<ul>
<li>a</li>
<li>s</li>
<li>d</li>
<li>f</li>
</ul>
<ul>
<li>z</li>
<li>x</li>
<li>c</li>
<li>v</li>
</ul>
</section>
<section id="assemblerLinkContainer">
<h2 class="secondaryH2">assembler: </h2>
<a href="Assembler/GUIAssemblerWIP/Assembler/assemblerIndex.html" target="_blank" class="stepControlActive" id="assemblerLink">open in new tab</a>
</section>
</section>
</div>
</div>
<script src = "Emulator/cpu.js"></script>
<script src = "Testing/opcodeTest.js"></script> <!-- uncomment this to add test file to html page
-->
<script src = "main.js"></script> <!-- comment this line out to run test -->
</body>
<footer>
</footer>
</html>