-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
234 lines (225 loc) · 7.11 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
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
<!DOCTYPE html>
<html>
<head>
<title>8085</title>
<link rel="stylesheet" href="codemirror-5.65.14/lib/codemirror.css" />
<link rel="stylesheet" href="codemirror-5.65.14/theme/dracula.css" />
<!-- <script src="codemirror-5.65.14/mode/xml/xml.js"></script> -->
<script src="codemirror-5.65.14/addon/edit/"></script>
<link rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200" />
<style>
@import url("https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@10..48,300&family=Inconsolata:wght@300&family=Montserrat:ital@0;1&family=Poppins:wght@300&family=Rubik&display=swap");
</style>
<link rel="stylesheet" href="style.css" />
<!-- Replace with your preferred theme -->
</head>
<body>
<div class="navbar">
<button onclick="resetAll()">Reset All</button>
<button onclick="loadHelp()">Help</button>
<button onclick="loadHelp()">Info</button>
<button onclick="Github()">Github</button>
</div>
<div class="main">
<div class="internal_memory">
<div class="inner">
<fieldset class="reg">
<legend style="text-align: left; font-weight: bold">
Register
</legend>
<div>
A
<span>
<p id="A">00</p>
</span>
</div>
<div>
BC
<span>
<p id="B">00</p>
<p id="C">00</p>
</span>
</div>
<div>
DE
<span>
<p id="D">00</p>
<p id="E">00</p>
</span>
</div>
<div>
HL
<span>
<p id="H">00</p>
<p id="L">00</p>
</span>
</div>
<div>
PSW
<span>
<p id="PW">00</p>
<p id="S">00</p>
</span>
</div>
<div>
PC
<span>
<p id="Pgr">00</p>
<p id="Ctr">00</p>
</span>
</div>
<div>
SP
<span>
<p id="Stk">00</p>
<p id="Ptr">00</p>
</span>
</div>
<div>
Int-Reg
<span>
<p id="Int">00</p>
</span>
</div>
</fieldset>
<fieldset class="flag">
<legend style="text-align: left; font-weight: bold">Flag</legend>
<div>
S
<p id="S_flag">0</p>
</div>
<div>
Z
<p id="Z_flag">0</p>
</div>
<div>
AC
<p id="AC_flag">0</p>
</div>
<div>
P
<p id="P_flag">0</p>
</div>
<div>
C
<p id="C_flag">0</p>
</div>
</fieldset>
</div>
<div class="outer">
<fieldset class="conv" id="conv1">
<legend style="text-align: left; font-weight: bold;">Decimal - Hex Convertion</legend>
<p>Decimal</p>
<p>Hex</p>
<input type="text" value="0" id="decimal" />
<input type="text" value="0" id="hex" />
<input type="button" value="To HEX" onclick="decimalToHex()" />
<input type="button" value="To DEC" onclick="hexToDecimal()" />
</fieldset>
<fieldset class="conv" id="conv2">
<legend style="text-align: left; font-weight: bold;" id="name">Memory Update</legend>
<p>Address</p>
<p>Data</p>
<input type="text" value="0" id="address" />
<input type="text" value="0" id="value" />
<input type="button" value="Update Value" onclick="updateData()" />
<select id="dropdown" name="dropdown" onchange="updateName()">
<option value="Mem">Memory</option>
<option value="io">I/O</option>
</select>
</fieldset>
</div>
</div>
<div class="mid" style=" width: 100%">
<div class="editor-setting">
<span class="material-symbols-outlined hide" id="run">arrow_forward</span>
<span class="material-symbols-outlined" id="compile">check_circle</span>
<span class="material-symbols-outlined" onclick="zoomin()">zoom_in</span>
<span class="material-symbols-outlined" onclick="zoomout()">zoom_out</span>
</div>
<textarea id="editor"></textarea>
<div class="Output"></div>
</div>
<div class="external_memory">
<div class="memory_controler">
<button onclick="showMemory()" class="memory_button focus">
Memory
</button>
<button onclick="showIo()" class="io_button">I/O Ports</button>
</div>
<div class="memory">
<div class="memoryin">
<div class="addr" style="margin-bottom: 10px; font-weight: bold">
<p>Address(Hex)</p>
<p>Address</p>
<p>Data</p>
</div>
<div class="cont" id="scroll_mem"></div>
</div>
</div>
<div class="io hide">
<div class="ioin">
<div class="addr" style="margin-bottom: 10px; font-weight: bold">
<p>Address(Hex)</p>
<p>Address</p>
<p>Data</p>
</div>
<div class="cont" id="scroll_io"></div>
</div>
</div>
</div>
</div>
<div class="footer">
<p>
Developed And Maintained by
<a href="https://www.linkedin.com/in/rajes-manna-489110212/" target="_blank">Rajes Manna</a>
|
<a href="https://www.linkedin.com/in/armsri/" target="_blank">Arman Ansari</a>
|
<a href="https://www.linkedin.com/in/suhaib-ahmad-2437b8240/" target="_blank">
Suhaib Ahmad</a>
</p>
</div>
<div class="model hide" id="model">
<div>
<span class="material-symbols-outlined close_model">cancel</span>
<h1>Documentation</h1>
<iframe src="./documentation/doc.html" frameborder="0"></iframe>
</div>
</div>
</body>
<script src="/controllers/conversion.js"></script>
<script src="codemirror-5.65.14/lib/codemirror.js"></script>
<script src="/codemirror-5.65.14/mode/assembly/assembly.js"></script>
<script src="/core/alu.js"></script>
<script src="core/compile.js"></script>
<script src="script.js"></script>
<script>
const code_editor = document.querySelector(".CodeMirror");
const me = document.querySelector(".memory");
const io = document.querySelector(".io");
const m_button = document.querySelector(".memory_button");
const i_button = document.querySelector(".io_button");
function zoomin() {
code_editor.style.fontSize =
parseInt(getComputedStyle(code_editor).fontSize) + 1 + "px";
}
function zoomout() {
code_editor.style.fontSize =
parseInt(getComputedStyle(code_editor).fontSize) - 1 + "px";
}
function showMemory() {
m_button.classList.add("focus");
i_button.classList.remove("focus");
io.classList.add("hide");
me.classList.remove("hide");
}
function showIo() {
me.classList.add("hide");
io.classList.remove("hide");
i_button.classList.add("focus");
m_button.classList.remove("focus");
}
</script>
</html>