examine and examineNext logic
This commit is contained in:
20
index.html
20
index.html
@@ -211,6 +211,17 @@ db ff d3 ff c3 00 00 // Switch echo between A2 and A1.
|
||||
dumpMemElem.innerHTML = dumpHtml;
|
||||
}
|
||||
|
||||
function getInputWord() {
|
||||
var word = 0;
|
||||
for (let i = 0; i < 16; i++) {
|
||||
var switchElem = document.getElementById('s' + i);
|
||||
if (switchElem.checked) {
|
||||
word |= 1 << i;
|
||||
}
|
||||
}
|
||||
return word;
|
||||
}
|
||||
|
||||
var sim = new Sim8800(256, 1000000,
|
||||
setAddressLedsCallback, setDataLedsCallback,
|
||||
setWaitLedCallback, setStatusLedsCallback,
|
||||
@@ -244,6 +255,15 @@ db ff d3 ff c3 00 00 // Switch echo between A2 and A1.
|
||||
function stop() {
|
||||
sim.stop();
|
||||
}
|
||||
|
||||
function examine() {
|
||||
var address = getInputWord();
|
||||
sim.examine(address);
|
||||
}
|
||||
|
||||
function examineNext() {
|
||||
sim.examineNext();
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user