Ported some PCjs drawing code to PC8080, still needs work though
This commit is contained in:
parent
98597a21da
commit
59b6dd3be6
23 changed files with 781 additions and 499 deletions
|
|
@ -9,7 +9,9 @@ PCjs CPU Component
|
|||
|
||||
Format
|
||||
---
|
||||
<cpu>...</cpu>
|
||||
```xml
|
||||
<cpu>...</cpu>
|
||||
```
|
||||
|
||||
Purpose
|
||||
---
|
||||
|
|
@ -19,7 +21,7 @@ Attributes
|
|||
---
|
||||
* *model* (optional; default is 8088; supported values include: 8086, 8088, 80186, 80286, and 80386)
|
||||
* Defines the CPU model, adjusting the CPU's capabilities accordingly.
|
||||
* *stepping* (optional; if specified, it must be a 2-character string, such as "A0" or "B1")
|
||||
* *stepping* (optional; if specified, it should be a 2-character string, such as "A0" or "B1")
|
||||
* Defines the CPU stepping, adjusting the CPU's capabilities accordingly.
|
||||
* Currently supported only on the 80386 model.
|
||||
* *cycles* (optional; default is 4772727)
|
||||
|
|
@ -44,26 +46,30 @@ Bindings
|
|||
*[Computer](/docs/pcjs/computer/)* component, because every component is reset, but the CPU offers the binding
|
||||
for convenience.
|
||||
* *speed*
|
||||
* For use with any control with an *innerHTML* property, to display the current CPU speed.
|
||||
* For use with any control with an *textContent* property, to display the current CPU speed.
|
||||
* *setSpeed*
|
||||
* For use with a control of type *button*, to increase the CPU speed.
|
||||
* *AX*, *BX*, *CX*, *DX*, *SP*, *BP*, *SI*, *DI*, *CS*, *DS*, *SS*, *ES*, *PC*, *PS*, *C*, *P*, *A*, *Z*, *S*, *T*, *I*, *D*, *O*
|
||||
* For use with any control with an *innerHTML* property, to display the corresponding register's contents.
|
||||
* For use with any control with an *textContent* property, to display the corresponding register's contents.
|
||||
|
||||
Example
|
||||
---
|
||||
<cpu id="cpu8088" model="8088" autoStart="true">
|
||||
<control type="button" class="input" binding="run">Run</control>
|
||||
</cpu>
|
||||
```xml
|
||||
<cpu id="cpu8088" model="8088" autoStart="true">
|
||||
<control type="button" class="input" binding="run">Run</control>
|
||||
</cpu>
|
||||
```
|
||||
|
||||
Output
|
||||
---
|
||||
<div id="..." class="pc-cpu pc-component" style="">
|
||||
<div class="pc-container" style="">
|
||||
<div class="pcjs-cpu" data-value="id:'...',name:'...',model:'...',cycles:'...',multiplier:'...',autoStart:'...'">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
```html
|
||||
<div id="..." class="pc-cpu pc-component" style="">
|
||||
<div class="pc-container" style="">
|
||||
<div class="pcjs-cpu" data-value="id:'...',name:'...',model:'...',cycles:'...',multiplier:'...',autoStart:'...'">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
```
|
||||
|
||||
Also, if any controls are defined, another <div> of class="pc-controls" is created in the container <div>,
|
||||
with each control inside a <div> of class="pc-control".
|
||||
|
|
|
|||
Loading…
Reference in a new issue