diff --git a/devices/pc/machine/5160/ega/256kb/debugger/machine.xml b/devices/pc/machine/5160/ega/256kb/debugger/machine.xml index f087ea3901..46a7a4b5a7 100644 --- a/devices/pc/machine/5160/ega/256kb/debugger/machine.xml +++ b/devices/pc/machine/5160/ega/256kb/debugger/machine.xml @@ -1,7 +1,7 @@ - IBM PC XT (Model 5160), 64K EGA, 256K RAM, 10Mb Hard Drive + IBM PC XT (Model 5160), 64K EGA, 256K RAM, 10Mb Hard Disk diff --git a/devices/pc/machine/5160/ega/256kb/machine.xml b/devices/pc/machine/5160/ega/256kb/machine.xml index 76e629276c..b923fdfac0 100644 --- a/devices/pc/machine/5160/ega/256kb/machine.xml +++ b/devices/pc/machine/5160/ega/256kb/machine.xml @@ -1,7 +1,7 @@ - IBM PC XT (Model 5160), 64K EGA, 256K RAM, 10Mb Hard Drive + IBM PC XT (Model 5160), 64K EGA, 256K RAM, 10Mb Hard Disk diff --git a/devices/pc/machine/5160/ega/640kb/array/machine.xml b/devices/pc/machine/5160/ega/640kb/array/machine.xml index da3688aa90..23c3da8379 100644 --- a/devices/pc/machine/5160/ega/640kb/array/machine.xml +++ b/devices/pc/machine/5160/ega/640kb/array/machine.xml @@ -1,7 +1,7 @@ - IBM PC XT, 128K EGA, 640K RAM, 10Mb Hard Drive + IBM PC XT, 128K EGA, 640K RAM, 10Mb Hard Disk diff --git a/devices/pc/machine/5160/ega/640kb/debugger/machine.xml b/devices/pc/machine/5160/ega/640kb/debugger/machine.xml index ec84da2d23..26206cb924 100644 --- a/devices/pc/machine/5160/ega/640kb/debugger/machine.xml +++ b/devices/pc/machine/5160/ega/640kb/debugger/machine.xml @@ -1,7 +1,7 @@ - IBM PC XT, 128K EGA, 640K RAM, 10Mb Hard Drive + IBM PC XT, 128K EGA, 640K RAM, 10Mb Hard Disk diff --git a/devices/pc/machine/5160/ega/640kb/machine.xml b/devices/pc/machine/5160/ega/640kb/machine.xml index 9a5af44c05..1b6377c650 100644 --- a/devices/pc/machine/5160/ega/640kb/machine.xml +++ b/devices/pc/machine/5160/ega/640kb/machine.xml @@ -1,7 +1,7 @@ - IBM PC XT, 128K EGA, 640K RAM, 10Mb Hard Drive + IBM PC XT, 128K EGA, 640K RAM, 10Mb Hard Disk diff --git a/devices/pc/machine/5170/README.md b/devices/pc/machine/5170/README.md index 2483a7bebf..6ece8fe3da 100644 --- a/devices/pc/machine/5170/README.md +++ b/devices/pc/machine/5170/README.md @@ -9,5 +9,7 @@ IBM PC AT Machines (Model 5170) All our Model 5170, aka IBM PC AT, configurations are located here, including: +* [IBM PC AT with MDA Display](/devices/pc/machine/5170/mda/) +* [IBM PC AT with CGA Display](/devices/pc/machine/5170/cga/) * [IBM PC AT with EGA Display](/devices/pc/machine/5170/ega/) * [IBM PC AT with VGA Display](/devices/pc/machine/5170/vga/) diff --git a/devices/pc/machine/5170/cga/640kb/rev3/debugger/machine.md b/devices/pc/machine/5170/cga/640kb/rev3/debugger/machine.md new file mode 100644 index 0000000000..65e7872ed4 --- /dev/null +++ b/devices/pc/machine/5170/cga/640kb/rev3/debugger/machine.md @@ -0,0 +1,11 @@ +--- +layout: page +title: "IBM PC AT (Model 5170, 640Kb) with CGA Display" +permalink: /devices/pc/machine/5170/cga/640kb/rev3/debugger/ +machines: + - type: pc + id: ibm5170 + debugger: true +--- + +{% include machine.html id="ibm5170" %} diff --git a/devices/pc/machine/5170/cga/640kb/rev3/debugger/machine.xml b/devices/pc/machine/5170/cga/640kb/rev3/debugger/machine.xml new file mode 100644 index 0000000000..c59d688b30 --- /dev/null +++ b/devices/pc/machine/5170/cga/640kb/rev3/debugger/machine.xml @@ -0,0 +1,36 @@ + + + + IBM PC AT (8Mhz, 640Kb, Dual Floppy) with Color Display + + + + + diff --git a/devices/pc/machine/5170/cga/640kb/rev3/machine.md b/devices/pc/machine/5170/cga/640kb/rev3/machine.md new file mode 100644 index 0000000000..41b6e9d9aa --- /dev/null +++ b/devices/pc/machine/5170/cga/640kb/rev3/machine.md @@ -0,0 +1,10 @@ +--- +layout: page +title: "IBM PC AT (Model 5170, 640Kb) with CGA Display" +permalink: /devices/pc/machine/5170/cga/640kb/rev3/ +machines: + - type: pc + id: ibm5170 +--- + +{% include machine.html id="ibm5170" %} diff --git a/devices/pc/machine/5170/cga/640kb/rev3/machine.xml b/devices/pc/machine/5170/cga/640kb/rev3/machine.xml new file mode 100644 index 0000000000..a642c3eb3d --- /dev/null +++ b/devices/pc/machine/5170/cga/640kb/rev3/machine.xml @@ -0,0 +1,15 @@ + + + + IBM PC AT (8Mhz, 640Kb, Dual Floppy) with Color Display + + + + + diff --git a/devices/pc/machine/5170/cga/README.md b/devices/pc/machine/5170/cga/README.md new file mode 100644 index 0000000000..cfaa164865 --- /dev/null +++ b/devices/pc/machine/5170/cga/README.md @@ -0,0 +1,12 @@ +--- +layout: page +title: "IBM PC AT (Model 5170) with Color Display" +permalink: /devices/pc/machine/5170/cga/ +--- + +IBM PC AT with Color (CGA) Display +--- + +All our Color Display configurations of the IBM PC AT (Model 5170) are located here, including: + +* [IBM PC AT (8Mhz, 640Kb, Dual Floppy) with CGA Display](/devices/pc/machine/5170/cga/640kb/rev3/) ([Debugger](/devices/pc/machine/5170/cga/640kb/rev3/debugger/)) diff --git a/devices/pc/machine/5170/ega/1152kb/rev1/machine.md b/devices/pc/machine/5170/ega/1152kb/rev1/machine.md new file mode 100644 index 0000000000..315a42eb9e --- /dev/null +++ b/devices/pc/machine/5170/ega/1152kb/rev1/machine.md @@ -0,0 +1,10 @@ +--- +layout: page +title: "IBM PC AT (Model 5170, 1152Kb) with EGA Display and 20Mb Hard Disk" +permalink: /devices/pc/machine/5170/ega/1152kb/rev1/ +machines: + - type: pc + id: ibm5170 +--- + +{% include machine.html id="ibm5170" %} diff --git a/devices/pc/machine/5170/ega/1152kb/rev1/machine.xml b/devices/pc/machine/5170/ega/1152kb/rev1/machine.xml new file mode 100644 index 0000000000..f6b5ac1ac6 --- /dev/null +++ b/devices/pc/machine/5170/ega/1152kb/rev1/machine.xml @@ -0,0 +1,17 @@ + + + + IBM PC AT (6Mhz), 128Kb EGA, 1152Kb RAM, 20Mb Hard Disk + + + + + + diff --git a/devices/pc/machine/5170/ega/1152kb/rev3/machine.xml b/devices/pc/machine/5170/ega/1152kb/rev3/machine.xml index 37c68fe342..4fc0e3d179 100644 --- a/devices/pc/machine/5170/ega/1152kb/rev3/machine.xml +++ b/devices/pc/machine/5170/ega/1152kb/rev3/machine.xml @@ -17,6 +17,5 @@ - diff --git a/devices/pc/machine/5170/ega/2048kb/rev3/machine.xml b/devices/pc/machine/5170/ega/2048kb/rev3/machine.xml index afa6375c06..c0e9ddcbe6 100644 --- a/devices/pc/machine/5170/ega/2048kb/rev3/machine.xml +++ b/devices/pc/machine/5170/ega/2048kb/rev3/machine.xml @@ -13,6 +13,5 @@ - diff --git a/devices/pc/machine/5170/ega/640kb/rev1/debugger/machine.xml b/devices/pc/machine/5170/ega/640kb/rev1/debugger/machine.xml index ab97f39919..4a225572a9 100644 --- a/devices/pc/machine/5170/ega/640kb/rev1/debugger/machine.xml +++ b/devices/pc/machine/5170/ega/640kb/rev1/debugger/machine.xml @@ -1,7 +1,7 @@ - IBM PC AT, 128K EGA, 640K RAM + IBM PC AT, 128K EGA, 640Kb RAM diff --git a/devices/pc/machine/5170/ega/640kb/rev1/debugger/manifest.xml b/devices/pc/machine/5170/ega/640kb/rev1/debugger/manifest.xml deleted file mode 100644 index 0387d42e17..0000000000 --- a/devices/pc/machine/5170/ega/640kb/rev1/debugger/manifest.xml +++ /dev/null @@ -1,23 +0,0 @@ - - - - IBM PC AT References - - IBM 5170 Technical Reference (March 1984) - - I/O Address Map - CMOS Addresses - BIOS Map - BIOS Listing - TEST.01: X286 Processor Test - TEST.02: Verify CMOS Shutdown - POST7 VERW/VERR - DISKETTE_IO_1 - - - 80286 and 80287 Programmers Reference Manual (1987) - - Memory Organization and Segmentation - VERR/VERW - - diff --git a/devices/pc/machine/5170/ega/640kb/rev1/machine.xml b/devices/pc/machine/5170/ega/640kb/rev1/machine.xml index f39f59bd73..56145a27a4 100644 --- a/devices/pc/machine/5170/ega/640kb/rev1/machine.xml +++ b/devices/pc/machine/5170/ega/640kb/rev1/machine.xml @@ -1,7 +1,7 @@ - IBM PC AT, 128K EGA, 640K RAM + IBM PC AT, 128K EGA, 640Kb RAM @@ -11,6 +11,5 @@ - diff --git a/devices/pc/machine/5170/ega/README.md b/devices/pc/machine/5170/ega/README.md index bf33395cb3..c00d94cde8 100644 --- a/devices/pc/machine/5170/ega/README.md +++ b/devices/pc/machine/5170/ega/README.md @@ -9,7 +9,9 @@ IBM PC AT with Enhanced Color Graphics (EGA) Display All our Enhanced Color Graphics (EGA) configurations of the IBM PC AT (Model 5170) are located here, including: -* [IBM PC AT (6Mhz, 640Kb) with EGA Display (Debugger)](/devices/pc/machine/5170/ega/640kb/rev1/debugger/) -* [IBM PC AT (6Mhz, 1Mb, 20Mb Drive) with EGA Display (Debugger)](/devices/pc/machine/5170/ega/1152kb/rev1/debugger/) -* [IBM PC AT (8Mhz, 1Mb, 20Mb Drive) with EGA Display](/devices/pc/machine/5170/ega/1152kb/rev3/) ([Debugger](/devices/pc/machine/5170/ega/1152kb/rev3/debugger/),[Backtrack](/devices/pc/machine/5170/ega/1152kb/rev3/debugger/backtrack/)) -* [IBM PC AT (8Mhz, 2Mb, 20Mb Drive) with EGA Display](/devices/pc/machine/5170/ega/2048kb/rev3/) ([Debugger](/devices/pc/machine/5170/ega/2048kb/rev3/debugger/),[Backtrack](/devices/pc/machine/5170/ega/2048kb/rev3/debugger/backtrack/)) +* [IBM PC AT (8Mhz, 640Kb, Dual Floppy) with MDA Display](/devices/pc/machine/5170/mda/640kb/rev3/) ([Debugger](/devices/pc/machine/5170/mda/640kb/rev3/debugger/)) +* [IBM PC AT (8Mhz, 640Kb, Dual Floppy) with CGA Display](/devices/pc/machine/5170/cga/640kb/rev3/) ([Debugger](/devices/pc/machine/5170/cga/640kb/rev3/debugger/)) +* [IBM PC AT (6Mhz, 640Kb, Dual Floppy) with EGA Display](/devices/pc/machine/5170/ega/640kb/rev1/) ([Debugger](/devices/pc/machine/5170/ega/640kb/rev1/debugger/)) +* [IBM PC AT (6Mhz, 1Mb, 20Mb Hard Disk) with EGA Display](/devices/pc/machine/5170/ega/1152kb/rev1/) ([Debugger](/devices/pc/machine/5170/ega/1152kb/rev1/debugger/)) +* [IBM PC AT (8Mhz, 1Mb, 20Mb Hard Disk) with EGA Display](/devices/pc/machine/5170/ega/1152kb/rev3/) ([Debugger](/devices/pc/machine/5170/ega/1152kb/rev3/debugger/),[Backtrack](/devices/pc/machine/5170/ega/1152kb/rev3/debugger/backtrack/)) +* [IBM PC AT (8Mhz, 2Mb, 20Mb Hard Disk) with EGA Display](/devices/pc/machine/5170/ega/2048kb/rev3/) ([Debugger](/devices/pc/machine/5170/ega/2048kb/rev3/debugger/),[Backtrack](/devices/pc/machine/5170/ega/2048kb/rev3/debugger/backtrack/)) diff --git a/devices/pc/machine/5170/mda/640kb/rev3/debugger/machine.md b/devices/pc/machine/5170/mda/640kb/rev3/debugger/machine.md new file mode 100644 index 0000000000..e28542640c --- /dev/null +++ b/devices/pc/machine/5170/mda/640kb/rev3/debugger/machine.md @@ -0,0 +1,11 @@ +--- +layout: page +title: "IBM PC AT (Model 5170, 640Kb) with MDA Display" +permalink: /devices/pc/machine/5170/mda/640kb/rev3/debugger/ +machines: + - type: pc + id: ibm5170 + debugger: true +--- + +{% include machine.html id="ibm5170" %} diff --git a/devices/pc/machine/5170/mda/640kb/rev3/debugger/machine.xml b/devices/pc/machine/5170/mda/640kb/rev3/debugger/machine.xml new file mode 100644 index 0000000000..f11de6b497 --- /dev/null +++ b/devices/pc/machine/5170/mda/640kb/rev3/debugger/machine.xml @@ -0,0 +1,36 @@ + + + + IBM PC AT (8Mhz, 640Kb, Dual Floppy) with Monochrome Display + + + + + diff --git a/devices/pc/machine/5170/mda/640kb/rev3/machine.md b/devices/pc/machine/5170/mda/640kb/rev3/machine.md new file mode 100644 index 0000000000..7fae8003d5 --- /dev/null +++ b/devices/pc/machine/5170/mda/640kb/rev3/machine.md @@ -0,0 +1,10 @@ +--- +layout: page +title: "IBM PC AT (Model 5170, 640Kb) with MDA Display" +permalink: /devices/pc/machine/5170/mda/640kb/rev3/ +machines: + - type: pc + id: ibm5170 +--- + +{% include machine.html id="ibm5170" %} diff --git a/devices/pc/machine/5170/mda/640kb/rev3/machine.xml b/devices/pc/machine/5170/mda/640kb/rev3/machine.xml new file mode 100644 index 0000000000..b533ee1289 --- /dev/null +++ b/devices/pc/machine/5170/mda/640kb/rev3/machine.xml @@ -0,0 +1,15 @@ + + + + IBM PC AT (8Mhz, 640Kb, Dual Floppy) with Monochrome Display + + + + + diff --git a/devices/pc/machine/5170/mda/README.md b/devices/pc/machine/5170/mda/README.md new file mode 100644 index 0000000000..f621636d9e --- /dev/null +++ b/devices/pc/machine/5170/mda/README.md @@ -0,0 +1,12 @@ +--- +layout: page +title: "IBM PC AT (Model 5170) with Monochrome Display" +permalink: /devices/pc/machine/5170/mda/ +--- + +IBM PC AT with Monochrome (MDA) Display +--- + +All our Monochrome Display configurations of the IBM PC AT (Model 5170) are located here, including: + +* [IBM PC AT (8Mhz, 640Kb, Dual Floppy) with MDA Display](/devices/pc/machine/5170/mda/640kb/rev3/) ([Debugger](/devices/pc/machine/5170/mda/640kb/rev3/debugger/)) diff --git a/devices/pc/machine/5170/vga/2048kb/debugger/machine.xml b/devices/pc/machine/5170/vga/2048kb/debugger/machine.xml index e57ed95206..9bac46eaff 100644 --- a/devices/pc/machine/5170/vga/2048kb/debugger/machine.xml +++ b/devices/pc/machine/5170/vga/2048kb/debugger/machine.xml @@ -1,7 +1,7 @@ - IBM PC AT (8Mhz), VGA, 2Mb RAM, 20Mb Hard Disk + IBM PC AT (8Mhz, 2Mb, 20Mb Hard Disk) with VGA Display diff --git a/devices/pc/machine/5170/vga/2048kb/machine.xml b/devices/pc/machine/5170/vga/2048kb/machine.xml index 3407996926..3cba23db47 100644 --- a/devices/pc/machine/5170/vga/2048kb/machine.xml +++ b/devices/pc/machine/5170/vga/2048kb/machine.xml @@ -1,7 +1,7 @@ - IBM PC AT (8Mhz), VGA, 2Mb RAM, 20Mb Hard Disk + IBM PC AT (8Mhz, 2Mb, 20Mb Hard Disk) with VGA Display @@ -17,6 +17,5 @@ - diff --git a/devices/pc/machine/5170/vga/4096kb/debugger/machine.xml b/devices/pc/machine/5170/vga/4096kb/debugger/machine.xml index 7b3d2a847c..14a4e0823f 100644 --- a/devices/pc/machine/5170/vga/4096kb/debugger/machine.xml +++ b/devices/pc/machine/5170/vga/4096kb/debugger/machine.xml @@ -1,7 +1,7 @@ - IBM PC AT (8Mhz), VGA, 4Mb RAM, 20Mb Hard Disk + IBM PC AT (8Mhz, 4Mb, 20Mb Hard Disk) with VGA Display diff --git a/devices/pc/machine/5170/vga/4096kb/machine.xml b/devices/pc/machine/5170/vga/4096kb/machine.xml index 22646e307e..fdf6c39245 100644 --- a/devices/pc/machine/5170/vga/4096kb/machine.xml +++ b/devices/pc/machine/5170/vga/4096kb/machine.xml @@ -17,6 +17,5 @@ - diff --git a/devices/pc/machine/5170/vga/README.md b/devices/pc/machine/5170/vga/README.md index 31348e58f5..0a3bffe71b 100644 --- a/devices/pc/machine/5170/vga/README.md +++ b/devices/pc/machine/5170/vga/README.md @@ -4,9 +4,10 @@ title: "IBM PC AT (Model 5170) with VGA Display" permalink: /devices/pc/machine/5170/vga/ --- -IBM PC AT with VGA Display +IBM PC AT with Video Graphics Array (VGA) Display --- -All our VGA configurations of the IBM PC AT (Model 5170) are located here, including: +All our Video Graphics Array (VGA) configurations of the IBM PC AT (Model 5170) are located here, including: -* [IBM PC AT (8Mhz, 2Mb, 20Mb Drive) with VGA Display](/devices/pc/machine/5170/vga/2048kb/) ([Debugger](/devices/pc/machine/5170/vga/2048kb/debugger/)) +* [IBM PC AT (8Mhz, 2Mb, 20Mb Hard Disk) with VGA Display](/devices/pc/machine/5170/vga/2048kb/) ([Debugger](/devices/pc/machine/5170/vga/2048kb/debugger/)) +* [IBM PC AT (8Mhz, 4Mb, 20Mb Hard Disk) with VGA Display](/devices/pc/machine/5170/vga/4096kb/) ([Debugger](/devices/pc/machine/5170/vga/4096kb/debugger/)) diff --git a/devices/pc/machine/README.md b/devices/pc/machine/README.md index 21cc57d1bd..3023d849fe 100644 --- a/devices/pc/machine/README.md +++ b/devices/pc/machine/README.md @@ -96,9 +96,11 @@ other software. [Model 5170 Machines](/devices/pc/machine/5170/) include: -* [IBM PC AT (6Mhz, 640Kb) with EGA Display (Debugger)](/devices/pc/machine/5170/ega/640kb/rev1/debugger/) -* [IBM PC AT (6Mhz, 1Mb, 20Mb Drive) with EGA Display (Debugger)](/devices/pc/machine/5170/ega/1152kb/rev1/debugger/) -* [IBM PC AT (8Mhz, 1Mb, 20Mb Drive) with EGA Display](/devices/pc/machine/5170/ega/1152kb/rev3/) ([Debugger](/devices/pc/machine/5170/ega/1152kb/rev3/debugger/),[Backtrack](/devices/pc/machine/5170/ega/1152kb/rev3/debugger/backtrack/)) -* [IBM PC AT (8Mhz, 2Mb, 20Mb Drive) with EGA Display](/devices/pc/machine/5170/ega/2048kb/rev3/) ([Debugger](/devices/pc/machine/5170/ega/2048kb/rev3/debugger/),[Backtrack](/devices/pc/machine/5170/ega/2048kb/rev3/debugger/backtrack/)) -* [IBM PC AT (8Mhz, 2Mb, 20Mb Drive) with VGA Display](/devices/pc/machine/5170/vga/2048kb/) ([Debugger](/devices/pc/machine/5170/vga/2048kb/debugger/)) -* [IBM PC AT (8Mhz, 4Mb, 20Mb Drive) with VGA Display](/devices/pc/machine/5170/vga/4096kb/) ([Debugger](/devices/pc/machine/5170/vga/4096kb/debugger/)) +* [IBM PC AT (8Mhz, 640Kb, Dual Floppy) with MDA Display](/devices/pc/machine/5170/mda/640kb/rev3/) ([Debugger](/devices/pc/machine/5170/mda/640kb/rev3/debugger/)) +* [IBM PC AT (8Mhz, 640Kb, Dual Floppy) with CGA Display](/devices/pc/machine/5170/cga/640kb/rev3/) ([Debugger](/devices/pc/machine/5170/cga/640kb/rev3/debugger/)) +* [IBM PC AT (6Mhz, 640Kb, Dual Floppy) with EGA Display](/devices/pc/machine/5170/ega/640kb/rev1/) ([Debugger](/devices/pc/machine/5170/ega/640kb/rev1/debugger/)) +* [IBM PC AT (6Mhz, 1Mb, 20Mb Hard Disk) with EGA Display](/devices/pc/machine/5170/ega/1152kb/rev1/) ([Debugger)](/devices/pc/machine/5170/ega/1152kb/rev1/debugger/)) +* [IBM PC AT (8Mhz, 1Mb, 20Mb Hard Disk) with EGA Display](/devices/pc/machine/5170/ega/1152kb/rev3/) ([Debugger](/devices/pc/machine/5170/ega/1152kb/rev3/debugger/),[Backtrack](/devices/pc/machine/5170/ega/1152kb/rev3/debugger/backtrack/)) +* [IBM PC AT (8Mhz, 2Mb, 20Mb Hard Disk) with EGA Display](/devices/pc/machine/5170/ega/2048kb/rev3/) ([Debugger](/devices/pc/machine/5170/ega/2048kb/rev3/debugger/),[Backtrack](/devices/pc/machine/5170/ega/2048kb/rev3/debugger/backtrack/)) +* [IBM PC AT (8Mhz, 2Mb, 20Mb Hard Disk) with VGA Display](/devices/pc/machine/5170/vga/2048kb/) ([Debugger](/devices/pc/machine/5170/vga/2048kb/debugger/)) +* [IBM PC AT (8Mhz, 4Mb, 20Mb Hard Disk) with VGA Display](/devices/pc/machine/5170/vga/4096kb/) ([Debugger](/devices/pc/machine/5170/vga/4096kb/debugger/)) diff --git a/docs/pcjs/examples/pc-dbg.js b/docs/pcjs/examples/pc-dbg.js index 89431226e4..5e82cd4d03 100644 --- a/docs/pcjs/examples/pc-dbg.js +++ b/docs/pcjs/examples/pc-dbg.js @@ -41,10 +41,10 @@ f>d&&(f=d);c=f;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.Ca)){b=c;if(a.context&&a.ja& c}}}m.qd=function(){};function Kb(a,b,c,d){a.A.Af[a.A.Ai++]={Qk:b,Ud:c,type:d};return sa(Hb,b,c,0,d)}function Ib(a,b,c,d){var e,f=null.style.color,g=a.Na=10;a.C=g;a.U=b;a.X=a.wa=18;e||(e=a.ua||a.wa+"px Monaco, Lucida Console, Courier New");a.ga=a.ua=e;c&&(a.Ea=c);d&&(a.N=d,a.Fa=f||"white")} function Jb(a,b,c,d,e){a.N.font=a.ga;a.N.fillStyle=a.Fa;a.N.fillText(b,a.C,a.U);a.C+=a.pa;null!=c&&(16!=a.Tb?b=c.toString():(b=8>a.Ka?"0x":"",b+=r(c,a.Ka)),a.N.fillText(b,a.C,a.U),a.C+=a.pa);d&&(a.C+=a.pa*d);e&&(a.C=a.Na,a.U+=(a.X+2)*(e||1))}function Fb(){for(var a=!1,b=nb(document,"pcjs","panel"),c=0;c=this.N?12:24>=this.N?14:15;this.Nb=1<>2;this.A=this.Nb-1;this.U=this.X/this.Nb|0;this.ea=this.U-1;this.B=[];this.C=[];this.L=this.W=!1;this.aa=[];this.fa=[];a=new B;Mb(a,this.ha);this.sa=Array(this.U);for(b=0;b>>a.La;0a.Nb?a.Nb:c;if(g&&g.size){if(g.type==d&&g.controller==e){if(b+c<=g.Da)return g.Ne+=g.Da-b,g.Da=b,!0;if(b>=g.Da+g.Ne){k=g.size-(b-h);k>c&&(k=c);g.Ne=b-g.Da+k;c-=k;b=h+a.Nb;continue}}return Tb(a,1,b,c)}g=a.sa[f];b=new B(b,k,a.Nb,d,e);Mb(b,a.ha,g);a.sa[f++]=b;b=h+a.Nb;c-=k}return 0>=c?(Vb(a.F),!0):Tb(a,2,b,c)} +a.jd=a.Gd-1;a=this.F;a.Gb=a.Db=this.Gb;rb(this)}db(Lb);var Hb,Nb={$j:20,count:8,oo:1,type:3},Ob=0,Pb;for(Pb in Nb){var Qb=Nb[Pb];Nb[Pb]={lh:(1<>>a.La;0a.Nb?a.Nb:c;if(g&&g.size){if(g.type==d&&g.controller==e){if(b+c<=g.Da)return g.Ne+=g.Da-b,g.Da=b,!0;if(b>=g.Da+g.Ne){k=g.size-(b-h);k>c&&(k=c);g.Ne=b-g.Da+k;c-=k;b=h+a.Nb;continue}}return Tb(a,1,b,c)}g=a.sa[f];b=new B(b,k,a.Nb,d,e);Mb(b,a.ha,g);a.sa[f++]=b;b=h+a.Nb;c-=k}return 0>=c?(Ub(a.F),!0):Tb(a,2,b,c)} function Rb(a,b){if(32==a.N)b?a.V&&(Wb(a,1048576,1048576,a.V),a.V=null):a.V||(a.V=Xb(a,1048576,1048576),Wb(a,1048576,1048576,Xb(a,0,1048576)));else if(20>>this.La;0>>a.La;0>>=a.La;0>>a.La;0>>=a.La;0>>a.La;0>>this.La].jc(a&this.A,a)}; m.na=function(a){var b=a&this.A,c=(a&this.Gb)>>>this.La;return b!=this.A?this.sa[c].rf(b,a):this.sa[c++].jc(b,a)|this.sa[c&this.ea].jc(0,a+1)<<8};function ec(a,b){var c=b&a.A,d=(b&a.Gb)>>>a.La;return c!=a.A?a.sa[d].cg(c,b):a.sa[d++].se(c,b)|a.sa[d&a.ea].se(0,b+1)<<8}m.oa=function(a){var b=a&this.A,c=(a&this.Gb)>>>this.La;if(b>>this.La].sc(a&this.A,b&255,a)};m.jb=function(a,b){var c=a&this.A,d=(a&this.Gb)>>>this.La;c!=this.A?this.sa[d].yf(c,b&65535,a):(this.sa[d++].sc(c,b&255,a),this.sa[d&this.ea].sc(0,b>>8&255,a+1))};function fc(a,b,c){var d=b&a.A,e=(b&a.Gb)>>>a.La;d!=a.A?a.sa[e].oi(d,c&65535,b):(a.sa[e++].wf(d,c&255,b),a.sa[e&a.ea].wf(0,c>>8&255,b+1))} @@ -73,15 +73,15 @@ m.ic=function(a,b){if(!b){if(a&&this.restore){Oc(this);if(!this.restore(a))retur function Vc(a,b){if(a.la.Ye){var c=!1;a.Y.If=a.Y.If+a.Qi()|0;a.Y.kf-=b;0>=a.Y.kf&&(a.Y.kf+=a.Y.jf,c=!0);0<=a.Y.lf&&a.Y.lf<=Wc(a)&&(a.Y.jf=a.Y.lf=-1,Pc(a),a.Wb(),c=!0);c&&a.O(Wc(a)+" cycles: checksum="+r(a.Y.If))}} m.Qb=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.qa[b]=c;a=!0;break;case "run":this.qa[b]=c;c.onclick=function(){var a;if(a=d.V)if(a=d.V,a.la.cc)a=!0;else{var b=null,c,h=gb(a.id);for(c=0;cc&&(c=60);2>c&&(c=2);var d=1;b&&1a.Y.tg&&(c=Math.round(c/a.Y.Yd));return c}function Oc(a){a.Y.pe=0;a.uc=a.Ub=a.fb=a.A=0;Pc(a);Xc(a,1)} +function $c(a,b){var c=30;60>c&&(c=60);2>c&&(c=2);var d=1;b&&1a.Y.tg&&(c=Math.round(c/a.Y.Yd));return c}function Oc(a){a.Y.pe=0;a.uc=a.Ub=a.fb=a.A=0;Pc(a);Xc(a,1)} function Xc(a,b,c){var d=!1;if(void 0!==b){.8>a.Y.pe/a.Y.Fe?b=1:d=!0;a.Y.Yd=b;b=a.Y.tg*a.Y.Yd;if(a.Y.Fe!=b){a.Y.Fe=b;b=a.Y.Fe.toFixed(2)+"Mhz";var e=a.qa.setSpeed;e&&(e.textContent=b);a.O("target speed: "+b)}c&&a.V&&a.V.yd()}Zc(a,a.Ub);a.Ub=0;a.Y.hf=pa();a.Y.Ge=0;$c(a);return d} -m.Ke=function(a){if(pb(this,!0)){if(!this.la.Ib){Xc(this);this.V&&this.V.start(this.Y.hf,Wc(this));this.la.Ib=!0;this.la.dh=!0;this.N&&ad(this.N);var b=this.qa.run;b&&(b.textContent="Halt");this.V&&(this.V.qd(),a&&this.V.yd(!0))}this.Y.rh>=this.Y.Jd&&$c(this,!0);this.Y.Mf=0;this.Y.ug=pa();this.Y.Ge&&(a=this.Y.ug-this.Y.Ge,a>this.Y.Xi&&(this.Y.hf+=a,this.Y.hf>this.Y.ug&&(this.Y.hf=this.Y.ug)));try{do{var c=this.la.Ye?1:this.Y.jm;if(this.N){bd(this.N);var d=this.N;a=c;var e=d.W[0];if(e.Be){var f=(Wc(d.F, +m.Ke=function(a){if(pb(this,!0)){if(!this.la.Ib){Xc(this);this.V&&this.V.start(this.Y.hf,Wc(this));this.la.Ib=!0;this.la.dh=!0;this.N&&ad(this.N);var b=this.qa.run;b&&(b.textContent="Halt");this.V&&(this.V.qd(),a&&this.V.yd(!0))}this.Y.rh>=this.Y.Jd&&$c(this,!0);this.Y.Mf=0;this.Y.ug=pa();this.Y.Ge&&(a=this.Y.ug-this.Y.Ge,a>this.Y.Xi&&(this.Y.hf+=a,this.Y.hf>this.Y.ug&&(this.Y.hf=this.Y.ug)));try{do{var c=this.la.Ye?1:this.Y.km;if(this.N){bd(this.N);var d=this.N;a=c;var e=d.W[0];if(e.Be){var f=(Wc(d.F, d.ka)-e.xd)/d.gb|0,g=cd(d,0)-f;6==e.mode&&(g-=f);var h=g*d.gb|0;6==e.mode&&(h>>=1);a>h&&(a=h)}var c=a,k=this.N;a=c;if(k.A&&k.A[11]&64){var l=k.ua-Wc(k.F,k.ka);0l&&(a=l)}c=a}try{this.vf(c)}catch(q){if("number"!=typeof q)throw q;}var n=this.fb-this.A;this.Ub+=n;this.Y.Mf+=n;Zc(this,0,!0);Vc(this,n);this.Y.Lf-=n;0>=this.Y.Lf&&(this.Y.Lf+=this.Y.Zi,this.V&&dd(this.V));this.Y.Kf-=n;0>=this.Y.Kf&&(this.Y.Kf+=this.Y.Yi,this.V&&this.V.qd());this.Y.mf-=n;if(0>=this.Y.mf){this.Y.mf+=this.Y.qh;break}}while(this.la.Ib)}catch(q){this.Wb(); Qc(this);this.V&&this.V.stop(pa(),Wc(this));pb(this,!1);ub(this,q.stack||q.message);return}c=setTimeout;d=this.pi;this.Y.Ge=pa();e=this.Y.Xi;this.Y.Mf&&(e=Math.round(e*this.Y.Mf/this.Y.qh));e-=this.Y.Ge-this.Y.ug;if(f=this.Y.Ge-this.Y.hf)this.Y.pe=Math.round(this.Ub/(10*f))/100,864E5<=f&&(this.uc=0,this.N&&bd(this.N,!0),Xc(this));if(0>e||this.Y.pethis.id&&C.call(e,b&&3==this.id?10:13,a&65532)}return-1};m.fm=function(a){var b=this.F;a=b.Mc+(a<<2);var c=b.na(a);b.ca&=-769;return this.load(b.na(a+2))+c|0}; -m.em=function(a){var b=this.F;a<<=3;var c=b.Mc+a|0;if(7<=(b.Td-c|0))return this.C=!0,a=hd(this,c,a),-1!==a&&(a+=this.Xf),a;C.call(b,13,a|2);return-1};m.Di=function(a){return this.Aa+a|0};m.Fi=function(a){return this.Aa+a|0};m.Ci=function(a,b){return(a>>>0)+b<=this.Zb?this.Aa+a|0:this.ng()};m.Ik=function(a,b){return(a>>>0)+b>this.Zb?this.Aa+a|0:this.ng()};m.ng=function(){C.call(this.F,13,0);return-1};m.Ei=function(a,b){return(a>>>0)+b<=this.Zb?this.Aa+a|0:this.og()}; +m.kh=function(a){this.Z=a&65535;return this.Aa=this.Z<<4};m.sg=function(a,b){var c,d,e=this.F;a&=65535;a&4?(c=e.Bc.Aa,d=c+e.Bc.Ta|0):(c=e.Ec,d=e.Ad);if(c){c=c+(a&65528)|0;if(d-c|0)return e.A-=15,hd(this,c,a,b);6>this.id&&C.call(e,b&&3==this.id?10:13,a&65532)}return-1};m.gm=function(a){var b=this.F;a=b.Mc+(a<<2);var c=b.na(a);b.ca&=-769;return this.load(b.na(a+2))+c|0}; +m.fm=function(a){var b=this.F;a<<=3;var c=b.Mc+a|0;if(7<=(b.Td-c|0))return this.C=!0,a=hd(this,c,a),-1!==a&&(a+=this.Xf),a;C.call(b,13,a|2);return-1};m.Di=function(a){return this.Aa+a|0};m.Fi=function(a){return this.Aa+a|0};m.Ci=function(a,b){return(a>>>0)+b<=this.Zb?this.Aa+a|0:this.ng()};m.Ik=function(a,b){return(a>>>0)+b>this.Zb?this.Aa+a|0:this.ng()};m.ng=function(){C.call(this.F,13,0);return-1};m.Ei=function(a,b){return(a>>>0)+b<=this.Zb?this.Aa+a|0:this.og()}; m.Jk=function(a,b){return(a>>>0)+b>this.Zb?this.Aa+a|0:this.og()};m.og=function(){C.call(this.F,13,0);return-1};function id(a,b,c,d,e){a.Z=b;a.Aa=d;a.Ta=e;a.Zb=(e>>>0)+1;a.wb=c;a.type=c&7936;a.ext=c>>16&192;a.Xb=(b&4?a.F.Bc.Aa:a.F.Ec)+(b&65528)|0;4>a.id&&fd(a,!0)}function jd(a,b,c){var d=a.F,e=d.na(b+2),f=d.na(b)|(e&255)<<16,d=d.na(b+4);a.Z=c;a.Aa=f;a.Ta=d;a.Zb=(d>>>0)+1;a.wb=e;a.type=e&7936;a.ext=0;a.Xb=b;4>a.id&&fd(a,!0)} function hd(a,b,c,d){var e=a.F;if(!d&&c===a.A.Z)return a.Z=c,a.Aa=a.A.Aa,a.Ta=a.A.Ta,a.Zb=(a.A.Ta>>>0)+1,a.wb=a.A.wb,a.type=a.A.type,a.ext=a.A.ext,a.Xb=a.A.Xb,a.A.Z=-1,fd(a,!0,!0,!1),a.Aa;a.A.Z=-1;var f=e.na(b+0),g=e.na(b+4),h=g&7936,k=e.na(b+2)|(g&255)<<16,l=e.na(b+6),n=c&65528;if(80386<=e.ia){var q=f,k=k|(l&65280)<<16,f=f|(l&15)<<16;l&128&&(f=f<<12|4095)}switch(a.id){case 1:var p=a.C;a.cf=!1;if(p&&1==c&&a.B.length){var z=a.B[a.Xf-1];if(z&&!z())return-1}var F=c&3,v=(g&24576)>>13,z=-1,E,H;n||b>=e.Ec&& b=a.Lb&&(F>a.Lb&&(z=D(e),kd(e,D(e),!0),G(e,z),a.cf=!0),z=0);else{if(256==h||2304==h)return ld(a,c,p)?a.Aa:-1;if(1024==h)z=2,H=0,F>>0)+1)}; -function fd(a,b,c,d){void 0===c&&(c=!!(a.F.Za&1));a.cd=!1;if(c)if(a.load=a.sg,a.Wi=a.em,a.nc=a.Ci,a.oc=a.Ei,void 0===d&&(d=!!(a.F.ca&131072)),d)a.load=a.V,a.nc=a.ea,a.oc=a.qa,a.Lb=a.Gc=3,a.ba=a.Oc=2,a.R=a.Ba=65535,a.Ta=65535,a.Zb=a.Ta+1,a.Oc=a.ba,a.Xb=-1,a.cf=!1;else{if(!(a.Z&-4))a.nc=a.ng,a.oc=a.og;else if(a.type&4096){6144==(a.type&6656)&&(a.nc=a.ng);if(a.type&2048||!(a.type&512))a.oc=a.og;1024==(a.type&3072)&&(a.nc==a.Ci&&(a.nc=a.Ik),a.oc==a.Ei&&(a.oc=a.Jk),a.cd=!0);b&&6>a.id&&a.Z&-4&&-1!==a.Xb&& -(c=a.Xb+5,d=a.F.Qa(c),d&1||a.F.qc(c,d|1))}b&&(a.Lb=a.Z&3,a.Gc=(a.wb&24576)>>13,80386>a.F.ia||!(a.ext&64)?(a.ba=2,a.R=65535):(a.ba=4,a.R=-1),a.Oc=a.ba,a.Ba=a.R)}else a.load=a.kh,a.Wi=a.fm,a.nc=a.Di,a.oc=a.Fi,a.Lb=a.Gc=0,a.Xb=-1,a.cf=!1} +function fd(a,b,c,d){void 0===c&&(c=!!(a.F.Za&1));a.cd=!1;if(c)if(a.load=a.sg,a.Wi=a.fm,a.nc=a.Ci,a.oc=a.Ei,void 0===d&&(d=!!(a.F.ca&131072)),d)a.load=a.V,a.nc=a.ea,a.oc=a.qa,a.Lb=a.Gc=3,a.ba=a.Oc=2,a.R=a.Ba=65535,a.Ta=65535,a.Zb=a.Ta+1,a.Oc=a.ba,a.Xb=-1,a.cf=!1;else{if(!(a.Z&-4))a.nc=a.ng,a.oc=a.og;else if(a.type&4096){6144==(a.type&6656)&&(a.nc=a.ng);if(a.type&2048||!(a.type&512))a.oc=a.og;1024==(a.type&3072)&&(a.nc==a.Ci&&(a.nc=a.Ik),a.oc==a.Ei&&(a.oc=a.Jk),a.cd=!0);b&&6>a.id&&a.Z&-4&&-1!==a.Xb&& +(c=a.Xb+5,d=a.F.Qa(c),d&1||a.F.qc(c,d|1))}b&&(a.Lb=a.Z&3,a.Gc=(a.wb&24576)>>13,80386>a.F.ia||!(a.ext&64)?(a.ba=2,a.R=65535):(a.ba=4,a.R=-1),a.Oc=a.ba,a.Ba=a.R)}else a.load=a.kh,a.Wi=a.gm,a.nc=a.Di,a.oc=a.Fi,a.Lb=a.Gc=0,a.Xb=-1,a.cf=!1} function Bd(a){this.ia=a.model||8088;var b=a.stepping;this.Uc=this.ia+(b?ca(b,16):0);b=0;switch(this.ia){default:b=4772727;break;case 80286:b=6E6;break;case 80386:b=16E6}Lc.call(this,a,b);this.Yf=61442;this.Cc=1792;this.Wf=28672;this.Dd=4;this.ra=255;this.B=80286<=this.ia?xb:wb;this.X=Cd;this.bg=Dd;this.gg=Ed;this.hg=Fd;if(80186<=this.ia&&(this.X=Cd.slice(),this.bg=Dd.slice(),this.gg=Ed.slice(),this.ra=31,this.X[15]=Gd,this.X[96]=Hd,this.X[97]=Id,this.X[98]=Jd,this.X[99]=Gd,this.X[100]=Gd,this.X[101]= Gd,this.X[102]=Gd,this.X[103]=Gd,this.X[104]=Kd,this.X[105]=Ld,this.X[106]=Md,this.X[107]=Nd,this.X[108]=Od,this.X[109]=Pd,this.X[110]=Qd,this.X[111]=Rd,this.X[192]=Sd,this.X[193]=Td,this.X[200]=Ud,this.X[201]=Yd,this.X[241]=Zd,this.bg[7]=$d,this.gg[7]=$d,80286<=this.ia)){this.Yf=2;this.Cc|=28672;this.Dd=0;this.X[15]=ae;this.tc=ge.slice();for(a=0;a=this.Uc&&(this.tc[166]=oe,this.tc[167]=pe)}}this.Id=[];this.le=[];this.ne=0;Oc(this);this.la.Wd=this.la.Mi=!1;this.Og=0;this.ld=this.sa=[];this.La=this.Nb=this.Fa=this.Gd=this.jd=this.Gb=this.Db=0;qe(this)}db(Bd,Lc);function re(a,b,c,d){Gc((d?a.ld:a.sa)[b>>>a.La],c);d&&Vb(a)} -function se(a){var b;if(a.sa===a.ld){a.sa=Array(a.Gd);a.me=new B(null,0,0,5,null,a);Mb(a.me,a.ha);for(b=0;ba.oe&&(a.ag[a.oe++]=d);a.sa[b]=a.me}a.Hd=[]}function Vb(a){a.Za&-2147483648&&se(a)} +le;this.X[102]=me;this.X[103]=ne;for(c in M)this.tc[+c]=M[c];80546<=this.Uc&&80562>=this.Uc&&(this.tc[166]=oe,this.tc[167]=pe)}}this.Id=[];this.le=[];this.ne=0;Oc(this);this.la.Wd=this.la.Mi=!1;this.Og=0;this.ld=this.sa=[];this.La=this.Nb=this.Fa=this.Gd=this.jd=this.Gb=this.Db=0;qe(this)}db(Bd,Lc);function re(a,b,c,d){Gc((d?a.ld:a.sa)[b>>>a.La],c);d&&Ub(a)} +function se(a){var b;if(a.sa===a.ld){a.sa=Array(a.Gd);a.me=new B(null,0,0,5,null,a);Mb(a.me,a.ha);for(b=0;ba.oe&&(a.ag[a.oe++]=d);a.sa[b]=a.me}a.Hd=[]}function Ub(a){a.Za&-2147483648&&se(a)} function Fc(a,b,c,d){var e=(b&-4194304)>>>20,f=a.ld[(a.Pd+e&a.Gb)>>>a.La],g=f.Nd(e);if(!(g&1))return d||te.call(a,b,!1,c),a.kd;if(!(g&4)&&3==a.pa)return d||te.call(a,b,!0,c),a.kd;var h=(b&4190208)>>>10,g=a.ld[((g&-4096)+h&a.Gb)>>>a.La],k=g.Nd(h);if(!(k&1))return d||te.call(a,b,!1,c),a.kd;if(!(k&4)&&3==a.pa)return d||te.call(a,b,!0,c),a.kd;c=a.ld[((k&-4096)+(b&4095)&a.Gb)>>>a.La];if(d)return c;d=b>>>a.La;k=a.sa[d];b=b&-4096;var l;0>2;b.zb=g;b.B=h>>2;vb&&ac&&c.da&&!c.controller&&!c.Te&&!c.Ue?(b.Ya=c.Ya,b.fe=c.fe,b.da=c.da,Yb(b,Kc)):(b.ea=c?yc(32):0,b.W=c?yc(96):0,Yb(b,Ic));Mb(b,a.ha,k);a.sa[d]=b;a.Hd.push(d);return b}function ue(a){a.sa!==a.ld&&(a.sa=a.ld,a.me=null,a.Hd=null,a.kd=null)}m=Bd.prototype;m.reset=function(){this.la.Ib&&this.Wb();qe(this);Oc(this);this.la.ud=!1}; function ve(a,b){var c;switch(b){case 0:c=a.G;break;case 1:c=a.I;break;case 2:c=a.M;break;case 3:c=a.H;break;case 4:c=I(a);break;case 5:c=a.P;break;case 6:c=a.K;break;case 7:c=a.J}return c}function we(a,b,c){switch(b){case 0:a.G=c;break;case 1:a.I=c;break;case 2:a.M=c;break;case 3:a.H=c;break;case 4:G(a,c);break;case 5:a.P=c;break;case 6:a.K=c;break;case 7:a.J=c}} @@ -183,7 +183,7 @@ function gj(a,b){return b>>(this.G&this.R)&(1<<(this.I&31))-1&this.R}function hj function ij(a,b){if(-1===this.D){switch(this.L&7){case 0:this.G=this.G&~this.R|a;break;case 1:this.I=this.I&~this.R|a;break;case 2:this.M=this.M&~this.R|a;break;case 3:this.H=this.H&~this.R|a;break;case 4:G(this,I(this)&~this.R|a);break;case 5:this.P=this.H&~this.R|a;break;case 6:this.K=this.K&~this.R|a;break;case 7:this.J=this.J&~this.R|a}this.A-=this.B.bi}else this.C=this.D,this.S&2||this.rc(this.$b.oc(this.Ca,this.ba),a),this.A-=this.B.ai;return b} function jj(a,b){var c=a^b;vf(this,c,128);this.A-=-1===this.C?-1===this.D?this.B.yc:this.B.Vb:this.B.Nc;return c}function kj(a,b){this.A-=-1===this.C?-1===this.D?this.B.yc:this.B.Vb:this.B.Nc;return vf(this,a^b,this.Ia)&this.R}function lj(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function mj(a){var b=a-1|0;of(this,a,1,b,this.Ia|62,!0);this.A-=2;return a&~this.R|b&this.R} function nj(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1;c=[c>>>0,0];for(a=[a>>>0,b>>>0];0>>=0,b[1]++);e+=e}do 0<=lj(a,c)&&(b=a,f=c,b[0]-=f[0],b[1]-=f[1],0>b[0]&&(b[0]>>>=0,b[1]--),d+=e),b=c,b[0]>>>=1,b[1]&1&&(b[0]=(b[0]|2147483648)>>>0),b[1]>>>=1,e/=2;while(1<=e);this.ja=d;this.wa=a[0];return!0}function oj(a){var b=a+1|0;of(this,a,1,b,this.Ia|62);this.A-=2;return a&~this.R|b&this.R} -function pj(a){this.Za=a;md(this);this.Za&-2147483648?se(this):ue(this)}function Ad(a){this.Pd=a;Vb(this)}function qj(a){this.S|=1;this.$a.call(this,a);this.A-=-1===this.D?4:5}function Ri(a,b,c){if(c){16>>16-c)&65535;vf(this,a,32768,d&32768)}return a}function Ti(a,b,c){if(c){var d=a<>>32-c;vf(this,a,-2147483648,d&-2147483648)}return a} +function pj(a){this.Za=a;md(this);this.Za&-2147483648?se(this):ue(this)}function Ad(a){this.Pd=a;Ub(this)}function qj(a){this.S|=1;this.$a.call(this,a);this.A-=-1===this.D?4:5}function Ri(a,b,c){if(c){16>>16-c)&65535;vf(this,a,32768,d&32768)}return a}function Ti(a,b,c){if(c){var d=a<>>32-c;vf(this,a,-2147483648,d&-2147483648)}return a} function Xi(a,b,c){if(c){16>>c-1;a=(d>>>1|b<<16-c)&65535;vf(this,a,32768,d&1)}return a}function Zi(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;vf(this,a,-2147483648,d&1)}return a}function rj(){this.A-=-1===this.D?2:this.B.Yj;return 1}function sj(){var a=this.I&255;this.A-=(-1===this.D?this.B.Th:this.B.Sh)+(a<=cg&&(this.cb=this.Ea=2);this.ka=a.scaleTimers||!1;this.Ub=a.rtcDate;this.Db=!1;a.sound&&(this.sb=this.Fa=null,window&&(this.sb=window.AudioContext|| -window.webkitAudioContext),this.sb&&(this.Fa=new this.sb));this.reset(!0);rb(this)}db(pk);var rk=5150.9,cg=5170,qk={5150:5150,5160:5160,5170:cg,att6300:5160.101,mpc1600:5150.101,z150:5160.15,compaq:5150.102,other:rk,deskpro386:5180},tk="sw1",xk="sw2",yk={Bk:1,ONE:0,bo:64,$n:128,En:192,Lc:192,Pg:6},zk={ao:16,xn:32,Mn:48,Lc:48,Pg:4},vk=1,wk=4,Ak={5150:[{},{}]};Ak[5150][0][vk]={Lc:192,hd:{1:0,2:64,3:128,4:192},Qd:"Number of Floppy Drives"};Ak[5150][0][3]={Lc:2,hd:{0:0,1:2},Qd:"Coprocessor"}; -Ak[5150][0][wk]={Lc:48,hd:{0:0,1:16,2:32,3:48,none:0,tv:16,color:32,mono:48,ega:0,vga:0},Qd:"Monitor Type"};Ak[5150][0][5]={Lc:12,hd:{16:0,32:4,48:8,64:12},Qd:"Base Memory (16Kb Increments)"};Ak[5150][1][6]={Lc:31,hd:{0:0,32:1,64:2,96:3,128:4,160:5,192:6,224:7,256:8,288:9,320:10,352:11,384:12,416:13,448:14,480:15,512:16,544:17,576:18},Qd:"Expansion Memory (32Kb Increments)"};Ak[5160]=[{},{}];Ak[5160][0][vk]=Ak[5150][0][vk];Ak[5160][0][3]=Ak[5150][0][3];Ak[5160][0][wk]=Ak[5150][0][wk]; +window.webkitAudioContext),this.sb&&(this.Fa=new this.sb));this.reset(!0);rb(this)}db(pk);var rk=5150.9,cg=5170,qk={5150:5150,5160:5160,5170:cg,att6300:5160.101,mpc1600:5150.101,z150:5160.15,compaq:5150.102,other:rk,deskpro386:5180},tk="sw1",xk="sw2",yk={Bk:1,ONE:0,co:64,ao:128,Fn:192,Lc:192,Pg:6},zk={bo:16,yn:32,Nn:48,Lc:48,Pg:4},vk=1,wk=4,Ak={5150:[{},{}]};Ak[5150][0][vk]={Lc:192,hd:{1:0,2:64,3:128,4:192},Qd:"Number of Floppy Drives"};Ak[5150][0][3]={Lc:2,hd:{0:0,1:2},Qd:"Coprocessor"}; +Ak[5150][0][wk]={Lc:48,hd:{0:0,1:16,2:32,3:48,none:0,tv:16,color:32,cga:32,mda:48,mono:48,ega:0,vga:0},Qd:"Monitor Type"};Ak[5150][0][5]={Lc:12,hd:{16:0,32:4,48:8,64:12},Qd:"Base Memory (16Kb Increments)"};Ak[5150][1][6]={Lc:31,hd:{0:0,32:1,64:2,96:3,128:4,160:5,192:6,224:7,256:8,288:9,320:10,352:11,384:12,416:13,448:14,480:15,512:16,544:17,576:18},Qd:"Expansion Memory (32Kb Increments)"};Ak[5160]=[{},{}];Ak[5160][0][vk]=Ak[5150][0][vk];Ak[5160][0][3]=Ak[5150][0][3];Ak[5160][0][wk]=Ak[5150][0][wk]; Ak[5160][0][5]={Lc:12,hd:{64:0,128:4,192:8,256:12},Qd:"Base Memory (64Kb Increments)"};Ak[5160][1][6]=Ak[5150][1][6];Ak[5160.101]=[{},{}];Ak[5160.101][0][5]={Lc:143,hd:{128:1,256:130,512:8,640:141},Qd:"Base Memory (128Kb Increments)"};Ak[5160.101][0][3]={Lc:16,hd:{0:0,1:16},Qd:"Coprocessor"};Ak[5160.101][1][2]={Lc:1,hd:{0:0,1:1},Qd:"Floppy Type"};Ak[5160.101][1][vk]=Ak[5150][0][vk];Ak[5160.101][1][wk]=Ak[5150][0][wk];m=pk.prototype; m.Qb=function(a,b,c){switch(b){case tk:return this.qa[b]=c,Bk(this,0,b),!0;case xk:if(5150==(this.ia|0)||5160.101==this.ia)return this.qa[b]=c,Bk(this,1,b),!0;break;case "swdesc":return this.qa[b]=c,!0}return!1}; m.Ic=function(a,b,c,d){this.ea=b;this.F=c;this.ha=d;this.V=a;this.Tb=Eb(a,"FPU");uk(this,3,this.Tb?1:0,!0);this.B=Eb(a,"Keyboard");this.gb=c.Y.Jd/1193181;hc(b,this,Ck);lc(b,this,Dk);this.iab;b++){var c=13>=b?Ok(e,b):e.A[b];a&&(a+="\n");a+="CMOS["+t(b)+"]: "+t(c)}e.ha.O(a)})}cf(c,26,this.$l.bind(this))}; +c+=" IMR="+t(b.Bd)+" IRR="+t(b.mc)+" ISR="+t(b.Pc)+" DELAY="+b.nf;e.ha.O(c)}});Mk(d,2048,function(a){a=(a=a[0])?+a:null;for(var b=0;bb;b++){var c=13>=b?Ok(e,b):e.A[b];a&&(a+="\n");a+="CMOS["+t(b)+"]: "+t(c)}e.ha.O(a)})}cf(c,26,this.am.bind(this))}; m.ic=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};m.hc=function(a){return a?this.save():!0}; m.reset=function(a){var b;Pk(this);this.L=Array(this.cb);for(b=0;b=cg){this.N=16;this.fa=0;this.aa=16;this.Ja=0;this.ga=160;512<=Tk(this)&&(this.ga|=16);3==+Uk(this,wk,void 0)&&(this.ga|=64);5180==(this.ia|0)&&(this.ga|=12);this.Ka= 3;this.ra=Array(8);this.pa=0;a&&(this.A=Array(64));Vk(this,this.Ub);for(a=21;24>=a;a++)this.A[a]=0;for(a=14;46>a;a++)void 0===this.A[a]&&(this.A[a]=0);a=0|+Uk(this,wk,void 0)<b){var d=!1;4!=b&&5!=b||a.A[11]&2||(12>c?c=c?c:12:c=(c-=12)?c+128:140,d=!0);a.A[11]&4||(d&&128c;c++)b+=a.A[c];a.A[47]=b&255;a.A[46]=b>>8} -m.save=function(){var a=new hf(this);N(a,0,[this.C]);for(var b=[],c=0;c=cg&&(N(a,5,[this.N,this.fa,this.aa,this.Ja,this.ga,this.Ka]),N(a,6,[this.ra[7],this.ra,this.pa,this.A,this.Ia,this.ua]));return a.data()}; m.restore=function(a){var b,c;b=a[0];Array.isArray(b[0])?this.C=b[0]:(this.C[0][0]=b[0],this.C[1][0]=b[1]&15,this.C[0][1]=b[2],this.C[1][1]=b[3]&15);Pk(this);b=a[1];for(c=0;c=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
'+f+"
\n"}e.innerHTML=d;el(a,b,c,!0)}function fl(a,b,c){if(b=(a=Ak[a.ia|0])&&a[b])for(var d in b)if(a=b[d],a.Lc&1<g.Ab[0]&&(g.Ab[0]=255,g.Ab[1]--,0>g.Ab[1]&&(g.Ab[1]=255)));return h}function ll(a,b,c,d,e,f){var g=a.L[b];A(a,768)&&x(a,d,e,f,"DMA"+b+".CHANNEL"+c+".COUNT["+g.Kb+"]",null,!0);a=g.Dc[c];a.Ab[g.Kb]=a.Fc[g.Kb]=e;g.Kb^=1}function ml(a,b,c,d){var e=a.L[b],f=e.Yb|1;e.Yb&=-16;A(a,768)&&x(a,c,null,d,"DMA"+b+".STATUS",f,!0);return f} -function nl(a,b,c,d,e){var f=a.L[b];A(a,768)&&x(a,c,d,e,"DMA"+b+".REQ",null,!0);a=d&3;f.Yb=f.Yb&~(16<>2].Dc[b&3],c,d,e)}function pl(a,b,c){b=a.L[b>>2].Dc[b&3];b.pg&&b.eh&&b.Eg?(c&&(b.done=c),b.Ee||yl(a,b,!0)):c&&c(!0)} function yl(a,b,c){c&&(b.count=b.Ab[1]<<8|b.Ab[0],b.type=b.mode&12,b.Pi=b.ud=!1);for(var d=!1;0<=b.count&&(c=b.kg<<16|b.Eb[1]<<8|b.Eb[0],4==b.type?(d=!0,function(c){b.eh.call(b.pg,b.Eg,-1,function(f,g){0>f&&(b.Pi||(b.Pi=!0),f=255);b.Ee||a.ea.qc(c,f);(d=g)&&setTimeout(function(){zl(b)||yl(a,b)},0)})}(c)):8==b.type?(c=a.ea.Qa(c),0>b.eh.call(b.pg,b.Eg,c)&&(b.ud=!0)):0!=b.type&&(b.ud=!0)),!d&&!zl(b););} @@ -402,29 +402,29 @@ function Kl(a,b,c,d,e){x(a,c,d,e,"PIT"+b+".CTRL",null,2048);e=0;c=d&192;b?(e=3,a 77==a.X&&(b=a.W[0],b.$c[0]=b.Fc[0],b.$c[1]=b.Fc[1],b.xd=Wc(a.F,a.ka))}}}function Il(a,b){var c=a.W[b],d=c.Fc[1]<<8|c.Fc[0];d||(d=1==c.nd?256:65536);return d}function cd(a,b){var c=a.W[b],d=c.$c[1]<<8|c.$c[0];d||(d=1==c.nd?256:65536);return d}function Ll(a,b){Nk(a,b);var c=a.W[b];c.ze[0]=c.Ab[0];c.ze[1]=c.Ab[1];c.Ze=!0;Gl(a,b)}function Gl(a,b){var c=a.W[b];c.Fd=32==c.eg?1:0;c.nd=48==c.eg?2:1} function Nk(a,b,c){var d=a.W[b];if(d.Be&&(2!=b||a.X&1)){var e=Wc(a.F,a.ka),f=(e-d.xd)/a.gb|0;0>f&&(d.xd=e,f=0);var g=Il(a,b),h=cd(a,b)-f;0==d.mode?(0>=h&&(h=0),h||(d.vd=!0,d.Be=!1,b||eg(a,0))):4==d.mode?(d.vd=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.$c[0]=h&255,d.$c[1]=h>>8&255,d.xd=e,!b&&d.vd&&eg(a,0))):6==d.mode&&(h-=f,0>=h&&(d.vd=!d.vd,h=g+h,0>=h&&(h=g),d.$c[0]=h&255,d.$c[1]=h>>8&255,d.xd=e,!b&&d.vd&&eg(a,0)));d.Ab[0]=h&255;d.Ab[1]=h>>8&255;c&&(a.xd=0)}return d} function bd(a,b){for(var c=0;c=cg){var c=a.F.Y.Jd,d=Wc(a.F,a.ka);null==a.fb&&(a.Ia=Wc(a.F,a.ka),a.Jb=1024,a.fb=Math.floor(a.F.Y.Jd/a.Jb),Yk(a));d>=a.ua&&(a.A[12]|=64,a.A[11]&64&&(a.A[12]|=128,eg(a,8)),a.ua=d+a.fb);a.A[0]==a.A[1]&&a.A[2]==a.A[3]&&a.A[4]==a.A[5]&&(a.A[12]|=32,a.A[11]&32&&(a.A[12]|=128,eg(a,8)));var e=d-a.Ia,f=Math.floor(e/c);if(f&&!(a.A[11]&128)){for(;f--;)if(60<=++a.A[0]&&(a.A[0]=0,60<=++a.A[2]&&(a.A[2]=0,24<=++a.A[4]))){a.A[4]=0;a.A[6]=a.A[6]%7+1; -var g;g=a.A[9];var h=ra[a.A[8]-1];28==h&&0===g%4&&(g%100||0===g%400)&&h++;g=h;++a.A[7]>g&&(a.A[7]=1,12<++a.A[8]&&(a.A[8]=1,a.A[9]=(a.A[9]+1)%100))}a.A[12]|=16;a.A[11]&16&&(a.A[12]|=128,eg(a,8))}a.Ia=d-e%c}}m=pk.prototype;m.Jl=function(a,b){var c=this.$a;this.Ca&16&&(this.X&128?c=this.C[0][1]:this.B&&(c=Ml(this.B)));x(this,a,null,b,"PPI_A",c);return c};m.cn=function(a,b,c){x(this,a,b,c,"PPI_A");this.$a=b};m.Kl=function(a,b){var c=this.X;x(this,a,null,b,"PPI_B",c);return c}; -m.dn=function(a,b,c){x(this,a,b,c,"PPI_B");Nl(this,b)};function Nl(a,b){var c=!!(b&2),d=!!(a.X&2);a.X=b;a.B&&Ol(a.B,!(b&128),!!(b&64));c!=d&&ad(a,c)}m.Ll=function(a,b){var c=0,c=5150==(this.ia|0)?this.X&4?c|this.C[1][1]&15:c|this.C[1][1]>>4&1:this.X&8?c|this.C[0][1]>>4:c|this.C[0][1]&15;this.X&1&&Nk(this,2).vd&&(c=this.X&2?c|32:c|16);x(this,a,null,b,"PPI_C",c,32896);return c};m.en=function(a,b,c){x(this,a,b,c,"PPI_C");this.rb=b};m.Ml=function(a,b){var c=this.Ca;x(this,a,null,b,"PPI_CTRL",c);return c}; -m.fn=function(a,b,c){x(this,a,b,c,"PPI_CTRL");this.Ca=b};m.Wk=function(a,b){var c=this.B?Ml(this.B):0;x(this,a,null,b,"8041_KBD",c);this.wa&=-2;return c};m.om=function(a,b,c){x(this,a,b,c,"8041_KBD")};m.Vk=function(a,b){var c=this.X;x(this,a,null,b,"8041_CTRL",c);return c};m.nm=function(a,b,c){x(this,a,b,c,"8041_CTRL");Nl(this,b)};m.Xk=function(a,b){var c=this.wa;x(this,a,null,b,"8041_STATUS",c);return c}; +var g;g=a.A[9];var h=ra[a.A[8]-1];28==h&&0===g%4&&(g%100||0===g%400)&&h++;g=h;++a.A[7]>g&&(a.A[7]=1,12<++a.A[8]&&(a.A[8]=1,a.A[9]=(a.A[9]+1)%100))}a.A[12]|=16;a.A[11]&16&&(a.A[12]|=128,eg(a,8))}a.Ia=d-e%c}}m=pk.prototype;m.Kl=function(a,b){var c=this.$a;this.Ca&16&&(this.X&128?c=this.C[0][1]:this.B&&(c=Ml(this.B)));x(this,a,null,b,"PPI_A",c);return c};m.dn=function(a,b,c){x(this,a,b,c,"PPI_A");this.$a=b};m.Ll=function(a,b){var c=this.X;x(this,a,null,b,"PPI_B",c);return c}; +m.en=function(a,b,c){x(this,a,b,c,"PPI_B");Nl(this,b)};function Nl(a,b){var c=!!(b&2),d=!!(a.X&2);a.X=b;a.B&&Ol(a.B,!(b&128),!!(b&64));c!=d&&ad(a,c)}m.Ml=function(a,b){var c=0,c=5150==(this.ia|0)?this.X&4?c|this.C[1][1]&15:c|this.C[1][1]>>4&1:this.X&8?c|this.C[0][1]>>4:c|this.C[0][1]&15;this.X&1&&Nk(this,2).vd&&(c=this.X&2?c|32:c|16);x(this,a,null,b,"PPI_C",c,32896);return c};m.fn=function(a,b,c){x(this,a,b,c,"PPI_C");this.rb=b};m.Nl=function(a,b){var c=this.Ca;x(this,a,null,b,"PPI_CTRL",c);return c}; +m.gn=function(a,b,c){x(this,a,b,c,"PPI_CTRL");this.Ca=b};m.Wk=function(a,b){var c=this.B?Ml(this.B):0;x(this,a,null,b,"8041_KBD",c);this.wa&=-2;return c};m.pm=function(a,b,c){x(this,a,b,c,"8041_KBD")};m.Vk=function(a,b){var c=this.X;x(this,a,null,b,"8041_CTRL",c);return c};m.om=function(a,b,c){x(this,a,b,c,"8041_CTRL");Nl(this,b)};m.Xk=function(a,b){var c=this.wa;x(this,a,null,b,"8041_STATUS",c);return c}; m.Yk=function(a,b){var c=this.Ja;x(this,a,null,b,"8042_OUTBUFF",c,16384);this.N&=-258;this.B&&Pl(this.B);return c}; -m.qm=function(a,b,c){x(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.N&8)switch(this.fa){case 96:Ql(this,b);break;case 209:Rl(this,b);break;default:if(Ql(this,this.aa&-17),this.B){a=this.B;c=b;var d=-1;A(a)&&y(a,"sendCmd("+t(c)+")");switch(a.W||c){case 255:d=250;Sl(a);break;case 243:a.W&&(c=0);Tl(a,250);a.W=c;break;case 237:a.W&&(c=0);Tl(a,250);a.W=c;break;default:y(a,"sendCmd(): unrecognized command")}Ul(this,d)}}this.fa=b;this.N&=-9}; -m.Zk=function(a,b){var c=this.X&-209|(Wc(this.F)&64?16:0);x(this,a,null,b,"8042_RWREG",c,16384);return c};m.rm=function(a,b,c){x(this,a,b,c,"8042_RWREG",null,16384);Nl(this,b)};m.$k=function(a,b){x(this,a,null,b,"8042_STATUS",this.N,16384);var c=this.N&255;this.N&256&&(this.N|=1,this.N&=-257);return c}; -m.pm=function(a,b,c){x(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.fa=b;this.N|=8;a=0;240<=this.fa&&(a=this.fa^15,this.fa=240);switch(this.fa){case 32:Ul(this,this.aa);break;case 173:Ql(this,this.aa|16);break;case 174:Ql(this,this.aa&-17);this.B&&Pl(this.B);break;case 170:this.B&&(a=this.B,a.A=[],A(a)&&y(a,"scan codes flushed"));Ql(this,this.aa|16);Ul(this,85);Rl(this,3);break;case 171:Ul(this,0);break;case 192:Ul(this,this.ga);break;case 208:Ul(this,this.Ka);break;case 224:Ul(this,this.aa&16?0: +m.rm=function(a,b,c){x(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.N&8)switch(this.fa){case 96:Ql(this,b);break;case 209:Rl(this,b);break;default:if(Ql(this,this.aa&-17),this.B){a=this.B;c=b;var d=-1;A(a)&&y(a,"sendCmd("+t(c)+")");switch(a.W||c){case 255:d=250;Sl(a);break;case 243:a.W&&(c=0);Tl(a,250);a.W=c;break;case 237:a.W&&(c=0);Tl(a,250);a.W=c;break;default:y(a,"sendCmd(): unrecognized command")}Ul(this,d)}}this.fa=b;this.N&=-9}; +m.Zk=function(a,b){var c=this.X&-209|(Wc(this.F)&64?16:0);x(this,a,null,b,"8042_RWREG",c,16384);return c};m.sm=function(a,b,c){x(this,a,b,c,"8042_RWREG",null,16384);Nl(this,b)};m.$k=function(a,b){x(this,a,null,b,"8042_STATUS",this.N,16384);var c=this.N&255;this.N&256&&(this.N|=1,this.N&=-257);return c}; +m.qm=function(a,b,c){x(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.fa=b;this.N|=8;a=0;240<=this.fa&&(a=this.fa^15,this.fa=240);switch(this.fa){case 32:Ul(this,this.aa);break;case 173:Ql(this,this.aa|16);break;case 174:Ql(this,this.aa&-17);this.B&&Pl(this.B);break;case 170:this.B&&(a=this.B,a.A=[],A(a)&&y(a,"scan codes flushed"));Ql(this,this.aa|16);Ul(this,85);Rl(this,3);break;case 171:Ul(this,0);break;case 192:Ul(this,this.ga);break;case 208:Ul(this,this.Ka);break;case 224:Ul(this,this.aa&16?0: 1);break;case 240:a&1&&qe(this.F)}};function Ql(a,b){a.aa=b;a.N=a.N&-5|b&4;a.B&&Ol(a.B,!!(b&8),!(b&16))}function Ul(a,b,c){0<=b&&(a.Ja=b,c?a.N|=1:(a.N&=-2,a.N|=256))}function Rl(a,b){a.Ka=b;Rb(a.ea,!!(b&2));b&1||qe(a.F)}function Vl(a,b){a.ia=c?Ok(this,c):this.A[c];A(this,4352)&&x(this,a,null,b,"CMOS.DATA["+t(c)+"]",d,!0);null!=b&&12==c&&(this.A[c]&=15,d&128&&dg(this,8),d&64&&this.A[11]&64&&Yk(this));return d}; -m.Gm=function(a,b,c){var d=this.pa&63;A(this,4352)&&x(this,a,b,c,"CMOS.DATA["+t(d)+"]",null,!0);a=b^this.A[d];if(13>=d){if(c=b,10>d){var e=!1;this.A[11]&4||(c=10*(c>>4)+(c&15),e=!0);if(4==d||5==d)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;11==d&&a&64&&b&64&&Yk(this)};m.fk=function(a,b,c){x(this,a,b,c,"NMI");this.ya=b};m.Qm=function(a,b,c){x(this,a,b,c,"FPU.CLEAR")};m.Rm=function(a,b,c){x(this,a,b,c,"FPU.RESET");this.Tb&&Yf(this.Tb)}; -m.$l=function(a){if(A(this,16)&&kk(this.ha,26,a)){var b=this.F.G>>8;df(this.F,a,function(a,d){return function(e){d=Wc(a.F)-d;var f,g=a.F.M&255,h=a.F.M>>8,k=a.F.M&255,l=a.F.M>>8;if(2==b||3==b)f=" CH(hour)="+u(h)+" CL(min)="+t(g)+" DH(sec)="+t(l);else if(4==b||5==b)f=" CX(year)="+u(a.F.I)+" DH(month)="+t(l)+" DL(day)="+t(k);g=a.ha;h=d;g.message("INT "+t(26)+": C="+(pf(g.F)?1:0)+(f||"")+" (cycles="+h+(e?",level="+(e+1):"")+")")}}(this,Wc(this.F)))}return!0}; +m.Gm=function(a,b,c){x(this,a,b,c,"CMOS.ADDR",null,4096);this.pa=b;this.ya=b&128?0:128};m.ol=function(a,b){var c=this.pa&63,d=13>=c?Ok(this,c):this.A[c];A(this,4352)&&x(this,a,null,b,"CMOS.DATA["+t(c)+"]",d,!0);null!=b&&12==c&&(this.A[c]&=15,d&128&&dg(this,8),d&64&&this.A[11]&64&&Yk(this));return d}; +m.Hm=function(a,b,c){var d=this.pa&63;A(this,4352)&&x(this,a,b,c,"CMOS.DATA["+t(d)+"]",null,!0);a=b^this.A[d];if(13>=d){if(c=b,10>d){var e=!1;this.A[11]&4||(c=10*(c>>4)+(c&15),e=!0);if(4==d||5==d)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;11==d&&a&64&&b&64&&Yk(this)};m.fk=function(a,b,c){x(this,a,b,c,"NMI");this.ya=b};m.Rm=function(a,b,c){x(this,a,b,c,"FPU.CLEAR")};m.Sm=function(a,b,c){x(this,a,b,c,"FPU.RESET");this.Tb&&Yf(this.Tb)}; +m.am=function(a){if(A(this,16)&&kk(this.ha,26,a)){var b=this.F.G>>8;df(this.F,a,function(a,d){return function(e){d=Wc(a.F)-d;var f,g=a.F.M&255,h=a.F.M>>8,k=a.F.M&255,l=a.F.M>>8;if(2==b||3==b)f=" CH(hour)="+u(h)+" CL(min)="+t(g)+" DH(sec)="+t(l);else if(4==b||5==b)f=" CX(year)="+u(a.F.I)+" DH(month)="+t(l)+" DL(day)="+t(k);g=a.ha;h=d;g.message("INT "+t(26)+": C="+(pf(g.F)?1:0)+(f||"")+" (cycles="+h+(e?",level="+(e+1):"")+")")}}(this,Wc(this.F)))}return!0}; function ad(a,b){if(a.Fa)try{void 0!==b?a.Db=b:b=a.Db&&a.F&&a.F.la.Ib;var c=Math.round(1193181/Il(a,2));if(20>c||2E4>>4,0,this.L,this.C,this.Rd),delete this.Rd);return!0};Yl.prototype.hc=function(){return!0}; @@ -437,8 +437,8 @@ m.reset=function(){if(!this.B&&!this.V&&this.N){var a=1024*Tk(this.N);this.A&&a! 1]=c>>8;Xk(a)}}else w("No RAM allocated")};m.save=function(){var a=new hf(this);this.controller&&N(a,0,this.controller.save());return a.data()};m.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function em(a){this.N=a;this.C=gm;this.ha=hm;this.B=im;this.A=null}var fm=-2134900736,gm=65535,hm=2575,im=2,jm=[null,0],km=[function(a){return this.controller.Qa(a)},null,null,function(a,b){this.controller.qc(a,b)},null,null];m=em.prototype;m.save=function(){return[this.C,this.B]}; m.restore=function(a){this.qc(0,a[0]&255);this.qc(2,a[1]&255);return!0};m.Qa=function(a){var b=255;2>a?b=a&1?this.ha>>8:this.ha&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b};m.qc=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){var c=this.N.ea;if(b&1)this.A&&(Wb(c,917504,131072,this.A),this.A=null);else{this.A||(this.A=Xb(c,917504,131072));var d=Xb(c,16646144,131072);Wb(c,917504,131072,d,b&2?1:$b)}this.C=this.C&-256|b}};m.Ri=function(){return jm};m.fh=function(){return km}; Qa(function(){for(var a=nb(document,"pcjs","ram"),b=0;b":62,"?":63,"@":64,un:65,vn:66,wn:67,Bn:68,E:69,Cn:70,Fn:71,Gn:72,Hn:73,In:74,Jn:75,Kn:76,Ln:77,Nn:78,On:79,Pn:80,Q:81,Qn:82,Un:83,Zn:84,co:85,eo:86,fo:87,io:88,jo:89,ko:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,lo:97,mo:98,oo:99,d:100,e:101,po:102,qo:103,ro:104, -so:105,to:106,k:107,uo:108,vo:109,n:110,xo:111,p:112,q:113,r:114,yo:115,t:116,Ao:117,Bo:118,Co:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126},om={};om[186]=X[";"];om[187]=X["="];om[188]=X[","];om[189]=X["-"];om[190]=X["."];om[191]=X["/"];om[192]=X["`"];om[219]=X["["];om[220]=X["\\"];om[221]=X["]"];om[222]=X["'"];om[173]=X["-"];var pm={};pm[X["1"]]=X["!"];pm[X["2"]]=X["@"];pm[X["3"]]=X["#"];pm[X["4"]]=X.$;pm[X["5"]]=X["%"];pm[X["6"]]=X["^"];pm[X["7"]]=X["&"];pm[X["8"]]=X["*"];pm[X["9"]]=X["("]; +var nm=["US83","US84","US101"],X={zn:1,An:3,Bn:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,vn:65,wn:66,xn:67,Cn:68,E:69,Dn:70,Gn:71,Hn:72,In:73,Jn:74,Kn:75,Ln:76,Mn:77,On:78,Pn:79,Qn:80,Q:81,Rn:82,Vn:83,$n:84,eo:85,fo:86,ho:87,jo:88,ko:89,lo:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,mo:97,no:98,po:99,d:100,e:101,qo:102,ro:103,so:104, +to:105,uo:106,k:107,vo:108,wo:109,n:110,yo:111,p:112,q:113,r:114,zo:115,t:116,Bo:117,Co:118,Do:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126},om={};om[186]=X[";"];om[187]=X["="];om[188]=X[","];om[189]=X["-"];om[190]=X["."];om[191]=X["/"];om[192]=X["`"];om[219]=X["["];om[220]=X["\\"];om[221]=X["]"];om[222]=X["'"];om[173]=X["-"];var pm={};pm[X["1"]]=X["!"];pm[X["2"]]=X["@"];pm[X["3"]]=X["#"];pm[X["4"]]=X.$;pm[X["5"]]=X["%"];pm[X["6"]]=X["^"];pm[X["7"]]=X["&"];pm[X["8"]]=X["*"];pm[X["9"]]=X["("]; pm[X["0"]]=X[")"];pm[186]=X[":"];pm[187]=X["+"];pm[188]=X["<"];pm[189]=X._;pm[190]=X[">"];pm[191]=X["?"];pm[192]=X["~"];pm[219]=X["{"];pm[220]=X["|"];pm[221]=X["}"];pm[222]=X['"'];pm[173]=X._;pm[61]=X["+"];pm[59]=X[":"]; var qm={3016:1,1016:2,1017:8,1018:32,1091:128,1093:64,1224:128,1020:512,1144:1024,1145:2048},rm={TAB:1009,ESC:1027,F1:1112,F2:1113,F3:1114,F4:1115,F5:1116,F6:1117,F7:1118,F8:1119,F9:1120,F10:1121,LEFT:1037,UP:1038,RIGHT:1039,DOWN:1040,SYSREQ:4027,CTRL_C:4003,CTRL_BREAK:4008,CTRL_ALT_DEL:4046,CTRL_ALT_INS:4045,CTRL_ALT_ENTER:4013},sm={esc:1027,1:X["1"],2:X["2"],3:X["3"],4:X["4"],5:X["5"],6:X["6"],7:X["7"],8:X["8"],9:X["9"],0:X["0"],"-":X["-"],"=":X["="],bs:1008,tab:1009,q:81,w:87,e:69,r:82,t:84,y:89, u:85,i:73,o:79,p:80,"[":X["["],"]":X["]"],enter:13,ctrl:1017,a:65,s:83,d:68,f:70,g:71,h:72,j:74,k:75,l:76,";":X[";"],quote:X["'"],"`":X["`"],shift:1016,"\\":X["\\"],z:90,x:88,c:67,v:86,b:66,n:78,m:77,",":X[","],".":X["."],"/":X["/"],"right-shift":3016,prtsc:1044,alt:1018,space:1032,"caps-lock":1020,f1:1112,f2:1113,f3:1114,f4:1115,f5:1116,f6:1117,f7:1118,f8:1119,f9:1120,f10:1121,"num-lock":1144,"scroll-lock":1145,"num-home":1036,"num-up":1038,"num-pgup":1033,"num-sub":1109,"num-left":1037,"num-center":1101, @@ -460,7 +460,7 @@ function Dm(a,b,c){var d=b;if(65<=b&&90>=b)!(a.xc&515)==c&&(d=b+32);else if(97<= function um(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode,h=Dm(a,g,!0);a.ah&&h==X["`"]&&(g=h=27);if(Y[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),wm(a,h,!1,c)){if(20==g||144==g||145==g)a.pa||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;k=b||97<=b&&122>=b;e>>>=8;){var g=0,h=e&255;224==f||225==f?d.push(f|(c?0:128)):(42==h?a.C&3||a.C&512&&b||(g=h):29==h?a.C&12||(g=h):56==h?a.C&48||(g=h):d.push(f|(c?0:128)),g&&(c?d.unshift(g):d.push(g|128)))}for(c=0;ce.A.length?(A(e)&&y(e,"scan code "+t(f)+" buffered"),e.A.push(f),1== e.A.length&&e.N&&Vl(e.N,f)):(20==e.A.length&&e.A.push(255),y(e,"scan code buffer overflow")));d=!0}return d}Qa(function(){for(var a=nb(document,"pcjs","keyboard"),b=0;bc.length)c=[!1,0,null,null,0,Array(5>b?Vm:Wm)];this.ha=a.ha;this.type=e[0];this.port=e[1];this.Ua=b;this.ob=e[2];this.ac=e[3];this.Ed=d||e[4];65536<=this.Ed&&720896<=this.ob&&(this.ac=Math.min(this.Ed>>2,32768));this.Hc=c[0];this.gd=c[1];this.sf=c[2];this.ma=c[3];this.Ac=c[4]&255;this.Ig=c[4]>>8&255;this.mb=c[5];this.mh=Vm;this.jg=Xm;if(5<=b){this.mh=Wm;this.jg=Ym;b=c[6];void 0===b&&(b=[!1,0,Array(20), 0,3==f?0:1,0,0,Array(5),0,0,0,Array(9),0,[this.ob,this.ac,this.Ed],Array(this.Ed>>2),-2147478512,0,-1,0,-1,0,-1,0,0,0,0,1,255,0,0,0,Array(256)]);this.Xe=b[0];this.Od=b[1];this.Tc=b[2];this.Sg=Zm;this.Lg=b[3];this.uf=b[4];this.dg=b[5];this.ce=b[6];this.Je=b[7];this.Ug=$m;this.gk=b[8];this.hk=b[9];this.be=b[10];this.ae=b[11];this.Tg=an;this.Fb=b[12];d=b[13];"number"==typeof d&&(d=[this.ob,this.ac,d]);this.ob=d[0];this.ac=d[1];d=this.Ed>>2;if((this.sd=b[14])&&this.sd.length>this.controller.ci&255};cn[17408]=function(a){return(this.controller.Fb=this.da[(a&-4)+this.C])>>((a&3)<<3)&255};cn[5120]=function(a){a+=this.C;var b=this.controller.Fb=this.da[a&-2];return(a&1?b>>8:b)&255};cn[1280]=function(a){a+=this.C;a=this.controller.Fb=this.da[a];for(var b=this.controller.oh,c=this.controller.nh&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d}; @@ -496,9 +496,9 @@ b.Od),b.ha.O(" ATCDATA: "+b.Xe),en(b," FEAT",b.dg),en(b," MISC",b.uf),en(b m.Qb=function(a,b,c){var d=this;if(!this.qa[b])switch(this.qa[b]=c,b){case "fullScreen":return this.ga&&this.ga.We?c.onclick=function(){d.We()}:c.parentNode.removeChild(c),!0;case "lockPointer":return this.uk=c.textContent,this.V&&this.V.De?c.onclick=function(){d.De(!0)}:c.parentNode.removeChild(c),!0;case "refresh":return c.onclick=function(){qn(d,!0)},!0}return!1}; m.We=function(){var a=!1;if(this.ga){if(this.ga.We){a="100%";if(screen&&screen.width&&screen.height){var b=screen.width/screen.height,c=this.ra/this.Ea;b>c&&(a=Math.round(c/b*100)+"%")}this.qf?(this.ka.style.width=a,this.ka.style.width=a,this.ka.style.display="block",this.ka.style.margin="auto"):(this.ga.style.width=a,this.ga.style.height="auto");this.ga.style.backgroundColor="black";this.ga.We();a=!0}this.V&&this.V.focus()}return a}; function Hm(a,b){!b&&a.ga&&(a.qf?a.ka.style.width=a.ka.style.height="":a.ga.style.width=a.ga.style.height="");y(a,"notifyFullScreen("+b+")",!0);a.B&&(a.B.ah=b)}m.De=function(a){var b=!1;this.V&&(a?this.V.De&&(this.V.De(),this.W&&this.W.Vf(!0),b=!0):this.V.rk&&(this.V.rk(),this.W&&this.W.Vf(!1),b=!0),this.V&&this.V.focus());return b};m.Vf=function(a){this.W&&(this.W.Vf(a),this.B&&(this.B.ah=a));var b=this.qa.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.uk)}; -function pn(a,b){var c=a.V;c&&!a.me&&(c.addEventListener("touchstart",function(b){rn(a,b,!0)},!1),c.addEventListener("touchmove",function(b){rn(a,b)},!0),c.addEventListener("touchend",function(b){rn(a,b,!1)},!1),a.me=b,a.uc=a.Cc=a.gg=-1,a.Id=!1,a.Xc=null,a.Hd=!1,a.tn=function(){a.Hd=!0;a.W.je(sn,!0)})}m.Fg=function(a){this.B&&this.B.Fg(a)}; +function pn(a,b){var c=a.V;c&&!a.me&&(c.addEventListener("touchstart",function(b){rn(a,b,!0)},!1),c.addEventListener("touchmove",function(b){rn(a,b)},!0),c.addEventListener("touchend",function(b){rn(a,b,!1)},!1),a.me=b,a.uc=a.Cc=a.gg=-1,a.Id=!1,a.Xc=null,a.Hd=!1,a.un=function(){a.Hd=!0;a.W.je(sn,!0)})}m.Fg=function(a){this.B&&this.B.Fg(a)}; function rn(a,b,c){var d,e,f=0,g=0;e=a.ka;do isNaN(e.offsetLeft)||(f+=e.offsetLeft,g+=e.offsetTop);while(e=e.offsetParent);var h=a.ra/a.ka.offsetWidth,k=a.Ea/a.ka.offsetHeight;b.targetTouches&&b.targetTouches.length?(d=b.targetTouches[0].pageX,e=b.targetTouches[0].pageY):(d=b.pageX,e=b.pageY);d=(d-f)*h;e=(e-g)*k;if(1==a.me)d=d/(a.ra/3)|0,e=e/(a.Ea/3)|0,1!=e?e?vm(a.B,1040,!0):vm(a.B,1038,!0):1!=d&&(d?vm(a.B,1039,!0):vm(a.B,1037,!0));else if(a.W){g=a.Id;f=b.timeStamp-a.gg;!0===c?(a.Id=500f){a.W.je(sn,!0);a.W.je(sn,!1);return}}if(c||0>a.uc||0>a.Cc)a.uc=d,a.Cc=e;c=Math.round(d-a.uc);b=Math.round(e-a.Cc);a.uc=d;a.Cc=e;a.W.Hf(c,b,a.uc,a.Cc)}}m.ic=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};m.hc=function(a){return a?this.save():!0}; +a.Xc=setTimeout(a.un,500)):null!=a.Xc&&(clearTimeout(a.Xc),a.Xc=null);void 0===c&&(a.Id=!1);g||b.preventDefault();if(!1===c){a.Hd?(a.W.je(sn,!1),a.Hd=!1,b=!0):b=!1;if(b)return;if(200>f){a.W.je(sn,!0);a.W.je(sn,!1);return}}if(c||0>a.uc||0>a.Cc)a.uc=d,a.Cc=e;c=Math.round(d-a.uc);b=Math.round(e-a.Cc);a.uc=d;a.Cc=e;a.W.Hf(c,b,a.uc,a.Cc)}}m.ic=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};m.hc=function(a){return a?this.save():!0}; m.reset=function(){var a=!0,b=0;this.N&&(b=+Uk(this.N,wk,void 0));this.ia||(this.Ua=3==b?1:3);this.wa=3;switch(this.Ua){case cm:b=7;break;case 5:var c=Km[this.Vc];c&&(b=c[0]);b||(b=4);break;case 1:b=3;this.wa=7;break;default:b=2}this.ya!==b&&(this.ya=b,a=!0);this.C=null;this.pa=this.rd=new Tm(this,1);this.aa=this.Wc=new Tm(this,3);5>this.Ua?this.A=new Tm:(this.A=new Tm(this,this.Ua,null,this.Ed),tn(this));un(this);this.Ia=null;this.cb=this.ua=-1;this.Pa=0;vn(this,this.wa);if(this.C.ob&&a){a=this.C.ob+ this.Ub;for(b=this.C.ob;b>1&255,d=d>>8&-129,d>>4==(d&15)&&(d^=15)):(c=d&255,d=(d&256?7:112)|8&d>>8);fc(this.ea,b,c|d<<8)}qn(this,!0)}};function tn(a){a.A.uf&1?(a.pa=a.rd,a.aa=a.A):(a.pa=a.A,a.aa=a.Wc)}m.save=function(){var a=new hf(this);N(a,0,dn(this.rd));N(a,1,dn(this.Wc));N(a,2,[this.ya,this.wa,this.Ia]);N(a,3,dn(this.A));return a.data()}; m.restore=function(a){var b=a[2];this.ya=b[0];this.wa=b[1];this.Ia=b[2];this.C=null;this.pa=this.rd=new Tm(this,1,a[0]);this.aa=this.Wc=new Tm(this,3,a[1]);this.A=new Tm(this,this.Ua,a[3],this.Ed);this.A.Hc&&tn(this);un(this);if(!wn(this))return!1;xn(this);return!0}; @@ -506,8 +506,8 @@ function Im(a,b,c,d){if(d)a.Oa("Unable to load font ROM (error "+d+": "+b+")");e function yn(a,b){if(1==b)return a.Ca[0]=Nm[0],a.Ca[1]=Nm[7],a.Ca;if(2==b){var c=a.C.sf;if(a.C===a.A){var d=a.A.Tc[0],c=d&7;d&16&&(c|=8);18!=a.A.Tc[1]&&(c|=32)}a.Ca[0]=Nm[c&15];c=c&32?Pm:Om;for(d=0;df;f++)g=d[f]||0,h=g<<2&252,k=g>>4&252,g=g>>10&252,a.Ca[f]=[h,k,g,255];else{var l=d&&d[255];e=null!=c.Tc[15]?c.Tc:Qm;for(f=0;16>f;f++)g=e[f]&63,l?(g|= (c.Tc[20]&12)<<4,c.Tc[16]&128&&(g&=-49,g|=(c.Tc[20]&3)<<4),g=d[g],h=g<<2&252,k=g>>4&252,g=g>>10&252):(h=(g&4?170:0)|(g&32?85:0),k=(g&2?170:0)|(g&16?85:0),g=(g&1?170:0)|(g&8?85:0)),a.Ca[f]=[h,k,g,255]}a.rb=!0}return a.Ca}function bm(a,b,c,d){a.Uc=b;a.Jb=c;a.Tb=d} function un(a,b){var c=!1;if(window&&a.Uc&&(!b||a.U)){var d=0,e=a.Tb?a.Tb:8,f=yn(a);null!=a.Jb[0]&&zn(a,3,a.Jb[0],d,e,8,a.Uc,f)&&(c=!0);d=a.Tb?0:2048;e=a.Tb?a.Tb:9;null!=a.Jb[1]&&(zn(a,1,a.Jb[1],d,e,14,a.Uc,Lm,Mm)&&(c=!0),a.Tb&&zn(a,a.Ua,a.Jb[1],0,a.Tb,14,a.Uc,f)&&(c=!0))}return c}function zn(a,b,c,d,e,f,g,h,k){var l=!1;null!=c&&(An(a,b,c,d,e,f,g,h,k)&&(l=!0),a.pi&&An(a,b<<1,c,d,e,f,g,h,k)&&(l=!0));return l} -function An(a,b,c,d,e,f,g,h,k){var l=!1,n=b&1?0:1,q=a.Na[b],p=16>h.length?h.length:16;q||(q={Qc:e<V||!H?V:8,wa=ja.createImageData(l.Qc,l.Rc),Ha=0;256>Ha;Ha++){for(Ba= -0;Ba=V-2,Rc=P[Ba>(8<=Xa&&192<=Ha&&223>=Ha?7:Xa)?z:bb;Bn(wa,Ie,Xd,Je);v&&Bn(wa,Ie+1,Xd,Je)}ja.putImageData(wa,(Ha&15)*l.Qc,(Ha>>4)*l.Rc)}l.Oe[F]="#"+r(z[0],2)+r(z[1],2)+r(z[2],2);l.si[F]=z;l.Rg[F]=ia;l=!0}}a.Na[b]=q;return l}function Cn(a){0a.cb&&(a.cb=0):a.cb=-1} +function An(a,b,c,d,e,f,g,h,k){var l=!1,n=b&1?0:1,q=a.Na[b],p=16>h.length?h.length:16;q||(q={Qc:e<V||!H?V:8,wa=ja.createImageData(l.Qc,l.Rc),Ha=0;256>Ha;Ha++){for(Ba= +0;Ba=V-2,Rc=P[Ba>(8<=Xa&&192<=Ha&&223>=Ha?7:Xa)?z:bb;Bn(wa,Ie,Xd,Je);v&&Bn(wa,Ie+1,Xd,Je)}ja.putImageData(wa,(Ha&15)*l.Qc,(Ha>>4)*l.Rc)}l.Oe[F]="#"+r(z[0],2)+r(z[1],2)+r(z[2],2);l.si[F]=z;l.Rg[F]=ia;l=!0}}a.Na[b]=q;return l}function Cn(a){0a.cb&&(a.cb=0):a.cb=-1} function xn(a){if(a.U){for(var b=10;15>=b;b++)if(null==a.C.mb[b])return;var c=a.C.mb[10],b=c&31,d=a.C.mb[11]&31,e=a.C.mb[9]&31,f=!1;a.C===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)ao(a);else{c=a.C.mb[15]+((a.C.mb[14]&63)<<8);a.ua!=c&&(ao(a),a.ua=c);d=d-b+1;if(a.hg!=b||a.Ce!=d)a.hg=b,a.Ce=d;a.$a=e+1;Cn(a)}}} function ao(a){if(0<=a.ua){if(void 0!==a.fa){var b=a.fa[a.ua];if(b&131072){var b=b&-131073,c=a.ua%a.L,d=a.ua/a.L|0;a.U&&a.Na[a.U]&&(a.gb&&bo(a,c,d,b,a.gb),bo(a,c,d,b));a.fa[a.ua]=b}}a.ua=-1}} function co(a){var b,c=a.C;a.gf=!1;var d=c.ae[5];if(null!=d){b=1024;var e=0,f=c.ae[3]&31;switch(d&3){case 0:if(f){e=32;switch(f&24){case 8:e=96;break;case 16:e=160;break;case 24:e=224}c.dd=f&7}break;case 1:e=1;break;case 2:switch(f&24){default:e=2;break;case 8:e=98;break;case 16:e=162;break;case 24:e=226}break;case 3:a.Ua==cm&&(e=3,c.dd=f&7)}d&8&&(b=1280);c=c.Je[4];null!=c&&(c&4||(b|=4096,e|=16),d&64&&(c&8&&(b|=16384,e|=4),a.gf=!0));b|=e}return b} @@ -515,7 +515,7 @@ function eo(a,b){var c=a.C;return c&&null!=b&&b!=c.vg?(c.Mg(b),a.ea.Mg(c.ob,c.ac function wn(a,b){var c,d=a.Ia,e=a.C;if(e)if(1==e.Ua)d=7;else if(5<=e.Ua){var d=null,f=e.Ed>>2,g=32768=e.mb[18]?19:20:21:g&128||350>f?d= l?13:14:480<=f&&(d=3==a.ya?17:18):d=l?7-d:6:d-=l?2:0);c=co(a)}}else e.gd&8&&(e.gd&2?(d=e.gd&16?6:5,e.gd&4||--d):(d=e.gd&1?3:1,e.gd&4&&--d));else a.Ia=null,null==d&&(d=a.wa);if(!vn(a,d,b))return!1;eo(a,c);return!0} function vn(a,b,c){if(null!=b&&(b!=a.Ia||c)){a.Ng=0;a.Ia=b;a.rb=!1;b=a.C||(7==b?a.pa:a.aa);if(b!=a.C||b.ob!=a.ob||b.ac!=a.ac){ao(a);if(a.ob){if(!Zb(a.ea,a.ob,a.ac))return!1;a.C&&(a.C.Hc=!1)}a.C=b;b.Hc=!0;a.ob=b.ob;a.ac=b.ac;if(!Sb(a.ea,b.ob,b.ac,3,b===a.A?b:null))return!1}a:{a.U=0;a.L=a.kd;a.X=a.le;a.Db=a.L;a.jd=Fm[7][2];b=0;if(c=Fm[a.Ia])a.L=c[0],a.X=c[1],a.jd=c[2],b=c[3],a.U=c[4],4!=a.ya&&7!=a.ya||a.C!==a.A||3!=a.U||(7==(a.A.mb[9]&31)?a.X=350>fn(a.A,18)?43:50:a.U=a.Ua);a.Yf=a.L*a.X|0;a.Wf=a.Yf/ -a.jd|0;a.Ub=a.Wf;a.td=0;void 0!==b&&(a.Ub=(a.Ub<<1)+b|0,a.td=a.Ub+b>>1);if(a.Na.length){a.Ja=a.ra/a.L|0;a.Ka=a.Ea/a.X|0;if(a.U){b=a.Na[a.U];if(!b)break a;c=a.Na[a.U<<1];a.sn&&80==a.L?c&&a.Ja>=3*c.Qc>>2&&(a.U<<=1,b=c):(c&&a.Ja>=c.Qc&&(a.U<<=1,b=c),b&&(a.Ja=b.Qc,a.Ka=b.Rc));a.bc=a.tc=0;b&&(a.bc=a.L*b.Qc,a.tc=a.X*b.Rc)}else a.Ja=a.Ka=1,a.bc=a.L,a.tc=a.X;a.sb=a.ja.createImageData(a.bc,a.tc);a.fb=document.createElement("canvas");a.fb.width=a.bc;a.fb.height=a.tc;a.gb=a.fb.getContext("2d");a.ne=a.oe=0;a.Dd= +a.jd|0;a.Ub=a.Wf;a.td=0;void 0!==b&&(a.Ub=(a.Ub<<1)+b|0,a.td=a.Ub+b>>1);if(a.Na.length){a.Ja=a.ra/a.L|0;a.Ka=a.Ea/a.X|0;if(a.U){b=a.Na[a.U];if(!b)break a;c=a.Na[a.U<<1];a.tn&&80==a.L?c&&a.Ja>=3*c.Qc>>2&&(a.U<<=1,b=c):(c&&a.Ja>=c.Qc&&(a.U<<=1,b=c),b&&(a.Ja=b.Qc,a.Ka=b.Rc));a.bc=a.tc=0;b&&(a.bc=a.L*b.Qc,a.tc=a.X*b.Rc)}else a.Ja=a.Ka=1,a.bc=a.L,a.tc=a.X;a.sb=a.ja.createImageData(a.bc,a.tc);a.fb=document.createElement("canvas");a.fb.width=a.bc;a.fb.height=a.tc;a.gb=a.fb.getContext("2d");a.ne=a.oe=0;a.Dd= a.ra;a.Gd=a.Ea;b=a.ra-a.L*a.Ja;c=a.Ea-a.X*a.Ka;0>1,a.Dd-=b);0>1,a.Gd-=c);if(b||c)a.ja.fillStyle=a.ka.style.backgroundColor,a.ja.fillRect(0,0,a.ra,a.Ea)}}fo(a,!0);qn(a)}return!0}function Bn(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function go(a){a.Pa=-1;a.Fa=!1;var b=a.Wf;if(void 0===a.fa||a.fa.length!=b)a.fa=Array(b)}function fo(a,b){b||(a.rb=!1);go(a)} function bo(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.Na[a.U];h.zf&&(d=h.zf[d]);var k=g>>4&15;h.zf&&(k=h.zf[k]);e?(b*=h.Qc,c*=h.Rc,e.fillStyle=h.Oe[k],e.fillRect(b,c,h.Qc,h.Rc)):(b=b*a.Ja+a.ne,c=c*a.Ka+a.oe,a.ja.fillStyle=h.Oe[k],a.ja.fillRect(b,c,a.Ja,a.Ka));g&256&&(k=(f&15)*h.Qc,f=(f>>4)*h.Rc,e?e.drawImage(h.Rg[d],k,f,h.Qc,h.Rc,b,c,h.Qc,h.Rc):a.ja.drawImage(h.Rg[d],k,f,h.Qc,h.Rc,b,c,a.Ja,a.Ka));g&512&&(f=a.hg,g=a.Ce,e?(a.$a&&a.$a!==h.Rc&&(f=f*h.Rc/a.$a|0,g=g*h.Rc/a.$a|0),e.fillStyle=h.Oe[d], e.fillRect(b,c+f,h.Qc,g)):(a.$a&&a.$a!==a.Ka&&(f=f*a.Ka/a.$a|0,g=g*a.Ka/a.$a|0),a.ja.fillStyle=h.Oe[d],a.ja.fillRect(b,c+f,a.Ja,g)))} @@ -524,38 +524,38 @@ function qn(a,b){if(a.la.cc){var c=!1,d=a.C;d&&(d!==a.A?d.gd&8&&(c=!0):d.Od&32&& a.fa[d]=n,f++),c+=2,d++;a.Fa=!0;f&&a.gb&&a.ja.drawImage(a.fb,0,0,a.bc,a.tc,a.ne,a.oe,a.Dd,a.Gd);Cn(a)}}else if(a.td){for(var g=k,z,k=c,d=a.Pa=0,f=a.jd,e=16==f?65536:196608,h=16==f?1:2,l=yn(a,h),q=n=0,p=a.L,F=0,v=a.X,E=0;k>8|(z&255)<<8;var H=e,L=16;n>=h))>>(L-=h);Bn(a.sb,n++,q,l[P])}n>F&&(F=n);q=E&&(E=q+1)}k+=2;d++;if(n>=a.L){n=0;q+=2;if(q>a.X)break;q==a.X&&(q=1,k=c+a.td)}}a.Fa=!0; pa.L?a.Db-a.L-z>>3:0;c>=8;l>p&&(p=l);n=v&&(v=n+1)}c+=E;if(l>=a.L){l=0;if(++n>a.X)break;c+=H}}z||(a.Fa=!0);qa.L?a.Db-a.L-v>>3:0;cH&&(L=H)):(z<<=v,L-=v,a.Fa=!1):(a.Fa&&z===a.fa[d]?(h+=L,L=0):a.fa[d]=z,d++);if(L){hq&&(q=h);l=F&&(F=l+1)}if(h>=a.L){h=0;if(++l>a.X)break;c+=E}}v||(a.Fa=!0);nd&&(b.uh=d,d=-d|0);d%b.ph>b.im&&(c|=1);d%b.sh>b.km&&(c|=9);b.di=d/b.sh|0;return c}m.Fl=function(a,b){return io(this,this.pa,a,b)};m.$m=function(a,b,c){var d=this.pa;d.Ig=d.Ac;d.Ac=b&31;x(this,a,b,c,"CRTC.INDX")};m.El=function(a,b){return jo(this,this.pa,a,b)};m.Zm=function(a,b,c){ko(this,this.pa,a,b,c)};m.Gl=function(a,b){return lo(this,this.pa,b)};m.an=function(a,b,c){a=this.pa;x(this,a.port+4,b,c,"MODE");a.gd=b;wn(this,!1)}; -m.Hl=function(a,b){return mo(this,this.pa,b)};m.ek=function(a,b,c){this.A.dg=this.A.dg&-4|b&3;x(this,a,b,c,"FEAT")};m.el=function(a,b){var c=this.A.Od;b&&!A(this)||x(this,960,null,b,"ATC.INDX",c);return c};m.Ck=function(a,b){var c=this.A.Tc[this.A.Od&31];b&&!A(this)||x(this,960,null,b,"ATC."+this.A.Sg[this.A.Od&31],c);return c}; +0,0,a.L,a.X,0,0,a.ra,a.Ea))}}}}function ho(a,b){var c=0,d=Wc(a.F)-b.uh;0>d&&(b.uh=d,d=-d|0);d%b.ph>b.jm&&(c|=1);d%b.sh>b.lm&&(c|=9);b.di=d/b.sh|0;return c}m.Gl=function(a,b){return io(this,this.pa,a,b)};m.an=function(a,b,c){var d=this.pa;d.Ig=d.Ac;d.Ac=b&31;x(this,a,b,c,"CRTC.INDX")};m.Fl=function(a,b){return jo(this,this.pa,a,b)};m.$m=function(a,b,c){ko(this,this.pa,a,b,c)};m.Hl=function(a,b){return lo(this,this.pa,b)};m.bn=function(a,b,c){a=this.pa;x(this,a.port+4,b,c,"MODE");a.gd=b;wn(this,!1)}; +m.Il=function(a,b){return mo(this,this.pa,b)};m.ek=function(a,b,c){this.A.dg=this.A.dg&-4|b&3;x(this,a,b,c,"FEAT")};m.el=function(a,b){var c=this.A.Od;b&&!A(this)||x(this,960,null,b,"ATC.INDX",c);return c};m.Ck=function(a,b){var c=this.A.Tc[this.A.Od&31];b&&!A(this)||x(this,960,null,b,"ATC."+this.A.Sg[this.A.Od&31],c);return c}; m.dk=function(a,b,c){var d=this.A,e=d.Od&32;if(d.Xe){d.Xe=!1;var f=d.Od&31;if(16<=f||!e)c&&!A(this)||x(this,a,b,c,"ATC."+d.Sg[f]),d.Tc[f]=b,fo(this,!1)}else d.Od=b,x(this,a,b,c,"ATC.INDX"),d.Xe=!0,b&32&&!e&&un(this,!0)&&qn(this,!0),a=(d.mb[12]<<8)+d.mb[13]|0,d.Md!=a&&(d.Md=a,fo(this)),d.pf=0}; -m.Rl=function(a,b){var c=0;if(5==this.Ua)c=3-((this.A.uf&12)>>2),c=(this.Vc&1<>this.A.Kc&63;b&&!A(this)||x(this,969,null,b,"DAC.DATA["+t(this.A.pd)+"]["+t(this.A.Kc)+"]",c);this.A.Kc+=6;12>2),c=(this.Vc&1<>this.A.Kc&63;b&&!A(this)||x(this,969,null,b,"DAC.DATA["+t(this.A.pd)+"]["+t(this.A.Kc)+"]",c);this.A.Kc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=ya().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= (a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());c.appendChild(e);var f=document.createElement("textarea");Ga("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"));c.appendChild(f);var g=e.getContext("2d"),d=new Z(d,e,g,f,c);mb(d,c)}}); function no(a){this.W=a.adapter;switch(this.W){case 1:this.V=956;this.C=7;break;case 2:this.V=888;this.C=7;break;case 3:this.V=632;this.C=5;break;default:w("Unrecognized parallel adapter #"+this.W);return}this.A=this.B=null;Ua.call(this,"ParallelPort",a,no,4194304);a=a.binding;"console"==a?this.B="":kb(this,a,oo)}db(no);var oo="buffer";m=no.prototype;m.Qb=function(a,b,c){switch(b){case oo:return this.qa[b]=this.A=c,!0}return!1}; m.Ic=function(a,b,c,d){this.ea=b;this.F=c;this.ha=d;this.N=Eb(a,"ChipSet");hc(b,this,po,this.V);lc(b,this,qo,this.V);rb(this)};m.ic=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};m.hc=function(a){return a?this.save():!0};m.reset=function(){ro(this)};m.save=function(){var a=new hf(this),b=0,c=[];c[b++]=this.L;c[b++]=this.Yb;c[b]=this.Bf;N(a,0,c);return a.data()};m.restore=function(a){return ro(this,a[0])}; -function ro(a,b){var c=0;void 0===b&&(b=[0,0,0]);a.L=b[c++];a.Yb=b[c++];a.Bf=b[c];return!0}m.tl=function(a,b){var c=this.L;x(this,a,null,b,"DATA",c);return c};m.Ql=function(a,b){var c=this.Yb;x(this,a,null,b,"STAT",c);return c};m.pl=function(a,b){var c=this.Bf;x(this,a,null,b,"CTRL",c);return c}; -m.Mm=function(a,b,c){x(this,a,b,c,"DATA");this.L=b;this.Yb|=64;if(this.A)8==b?this.A.value=this.A.value.slice(0,-1):(this.A.value+=String.fromCharCode(b),this.A.scrollTop=this.A.scrollHeight),a=!0;else if(null!=this.B){if(10==b||1024<=this.B.length)this.O(this.B),this.B="";10!=b&&(this.B+=String.fromCharCode(b));a=!0}else a=!1;a&&(this.Yb&=-65);so(this)};m.Hm=function(a,b,c){x(this,a,b,c,"CTRL");this.Bf=b;so(this)};function so(a){a.N&&a.C&&(a.Bf&16&&!(a.Yb&64)?eg(a.N,a.C):dg(a.N,a.C))} -var po={0:no.prototype.tl,1:no.prototype.Ql,2:no.prototype.pl},qo={0:no.prototype.Mm,2:no.prototype.Hm};Qa(function(){for(var a=nb(document,"pcjs","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64>8:this.ja;x(this,a,null,b,this.B&128?"DLM":"IER",c);return c};m.Al=function(a,b){var c=this.L;x(this,a,null,b,"IIR",c);return c}; -m.Bl=function(a,b){var c=this.B;x(this,a,null,b,"LCR",c);return c};m.Dl=function(a,b){var c=this.C;x(this,a,null,b,"MCR",c);return c};m.Cl=function(a,b){var c=this.A;x(this,a,null,b,"LSR",c);return c};m.Il=function(a,b){var c=this.ua;x(this,a,null,b,"MSR",c);return c}; -m.jn=function(a,b,c){x(this,a,b,c,this.B&128?"DLL":"THR");if(this.B&128)this.aa=this.aa&-256|b;else{this.wa=b;this.A&=-97;if(this.V)13==b?this.X=0:8==b?(this.V.value=this.V.value.slice(0,-1),0>8:this.ja;x(this,a,null,b,this.B&128?"DLM":"IER",c);return c};m.Bl=function(a,b){var c=this.L;x(this,a,null,b,"IIR",c);return c}; +m.Cl=function(a,b){var c=this.B;x(this,a,null,b,"LCR",c);return c};m.El=function(a,b){var c=this.C;x(this,a,null,b,"MCR",c);return c};m.Dl=function(a,b){var c=this.A;x(this,a,null,b,"LSR",c);return c};m.Jl=function(a,b){var c=this.ua;x(this,a,null,b,"MSR",c);return c}; +m.kn=function(a,b,c){x(this,a,b,c,this.B&128?"DLL":"THR");if(this.B&128)this.aa=this.aa&-256|b;else{this.wa=b;this.A&=-97;if(this.V)13==b?this.X=0:8==b?(this.V.value=this.V.value.slice(0,-1),0d&&a.V&&!a.V.la.cc;if(a.qg)d?a.controller.Oa('Unable to connect to disk "'+a.W+'" (error '+d+": "+c+")",f):(a.N=!0,fp(a),e=a);else if(d)a.controller.Oa('Unable to load disk "'+a.ea+'" (error '+d+": "+b+")",f);else{fb(a.controller.ve,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+c+")");if(h.length)if(1==h.length)w(h[0]);else{a.Bb=h.length;a.ub=h[0].length;a.lb=h[0][0].length;var k=h[0][0][0];a.Va=k&&k.length||512;for(d=c=0;d>2,n=k.pattern;void 0===n&&(n=k.pattern=0);var q=k.data;if(void 0===q){var p=k.bytes;if(void 0!==p&&p.length){for(var z= l<<2,F=p.length;Fb;b++){if(128==Zo(a,e,c+0,1)){d.Zf=Zo(a,e,c+8,4);(e=Yo(a,d.Zf))&&(f=!0);break}c+=16}if(!f)return}d.Gf||(d.Gf=Zo(a,e,19,2)||Zo(a,e,32,4),d.Ff=Zo(a,e,14,2),d.jh=d.Ff+Zo(a,e,22,2)*Zo(a,e,16,1),d.th=Zo(a,e,17,2),d.xg=Zo(a,e,13,1));d.hh=d.jh+((32*d.th+(d.Va-1))/d.Va|0);d.hm=(d.Gf-d.hh)/d.xg|0;d.zg=4084>=d.hm?12:16;d.Sk=12==d.zg?4086:65526;b=[];for(e=d.jh;eb;b++){if(128==Zo(a,e,c+0,1)){d.Zf=Zo(a,e,c+8,4);(e=Yo(a,d.Zf))&&(f=!0);break}c+=16}if(!f)return}d.Gf||(d.Gf=Zo(a,e,19,2)||Zo(a,e,32,4),d.Ff=Zo(a,e,14,2),d.jh=d.Ff+Zo(a,e,22,2)*Zo(a,e,16,1),d.th=Zo(a,e,17,2),d.xg=Zo(a,e,13,1));d.hh=d.jh+((32*d.th+(d.Va-1))/d.Va|0);d.im=(d.Gf-d.hh)/d.xg|0;d.zg=4084>=d.im?12:16;d.Sk=12==d.zg?4086:65526;b=[];for(e=d.jh;e>8;f+=2;if(k)for(;l--;)Xo(d,f,1),254>=k?(n=k,q=Xo(d,f+1),f+=3):(n=Xo(d,f+3,1),q=Xo(d,f+4),f+=6),d.zd[n]&&(d.zd[n].we[h]=[q]),d.A[h]=[n,q],h++;else h+=l}(g=$o(e,Uo,c))&&ap(e,g+c);g=$o(e,Vo,c);h=$o(e,So,c);g&&h&&ap(e,g,g+h)}}}} -function ip(a,b,c,d,e){var f,g=a.C.length,h=b.Va/32|0;b.zo=d+"\\";for(var k=0;kF)break;for(var v=p.hh+(F-2)*p.xg,E=0;EF)break;for(var v=p.hh+(F-2)*p.xg,E=0;E>3,1),d?e=16==b.zg?e<<8:c&7?e<<4:(e&15)<<8:c&7&&(e>>=4));return e} function Yo(a,b){var c=a.ub*a.lb,d=b/c|0;return dg)break;e|=g<=f)break;e+=String.fromCharCode(f)}return e}function cp(a,b,c,d,e,f){a||(a={sector:d,length:e,data:[],pattern:f});a.Tk=b;a.Uk=c;a.wd=a.Zc=0;a.Wa=!1;return a} function dp(a,b){var c;c="action=open&volume="+b+("&mode="+a.mode);c+="&chs="+a.Bb+":"+a.ub+":"+a.lb+":"+a.Va;c+="&machine="+a.controller.ff();c+="&user="+a.controller.ke();return xa()+"/api/v1/disk?"+c} @@ -593,7 +593,7 @@ m.restore=function(a){var b=0,c="unsupported restore format";if(a&&0b?-2!=b&&this.controller.Oa("Unable to restore disk '"+this.ea+": "+c):fp(this);return b}; m.toJSON=function(){var a;a=0;for(var b;b=Yo(this,a++);)pp(b);a=JSON.stringify(this.A,function(a,b){return"file"==a?void 0:b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; function pp(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}function qp(a){Ua.call(this,"FDC",a,qp,524288);this.dmaRead=this.wk;this.dmaWrite=this.xk;this.dmaFormat=this.Lk;this.U=a.autoMount||null;this.B=[];this.ga=!Ga("Mobi")&&window&&"FileReader"in window}db(qp);aa={}; -var rp={3:{Vd:3,ie:0,name:aa.Yn},4:{Vd:2,ie:1,name:aa.Wn},5:{Vd:9,ie:7,name:aa.ho},6:{Vd:9,ie:7,name:aa.Rn},7:{Vd:2,ie:0,name:aa.Tn},8:{Vd:1,ie:2,name:aa.Xn},10:{Vd:2,ie:7,name:aa.Sn},13:{Vd:6,ie:7,name:aa.Dn},15:{Vd:3,ie:0,name:aa.Vn}};m=qp.prototype; +var rp={3:{Vd:3,ie:0,name:aa.Zn},4:{Vd:2,ie:1,name:aa.Xn},5:{Vd:9,ie:7,name:aa.io},6:{Vd:9,ie:7,name:aa.Sn},7:{Vd:2,ie:0,name:aa.Un},8:{Vd:1,ie:2,name:aa.Yn},10:{Vd:2,ie:7,name:aa.Tn},13:{Vd:6,ie:7,name:aa.En},15:{Vd:3,ie:0,name:aa.Wn}};m=qp.prototype; m.Qb=function(a,b,c){var d=this;switch(b){case "listDisks":return this.qa[b]=c,c.onchange=function(){var a=d.qa.descDisk,b=c.options[c.selectedIndex];if(a&&b){var g={};if(b=b.getAttribute("data-value"))try{g=eval("("+b+")")}catch(h){w("FDC option error: "+h.message)}b=g.desc;void 0===b&&(b="");g=g.href;void 0!==g&&(b=''+b+"");a.innerHTML=b}},!0;case "descDisk":case "listDrives":return this.qa[b]=c,c.onchange=function(){var a=ca(c.value,10);null!=a&&sp(d,a)},!0; case "loadDrive":return this.qa[b]=c,c.onclick=function(){var a=d.qa.listDisks;a&&tp(d,a.options[a.selectedIndex].text,a.value)},!0;case "saveDrive":if(!this.ga){c.parentNode.removeChild(c);break}this.qa[b]=c;c.onclick=function(){var a=d.qa.listDrives;if(a&&a.options&&d.A)if(a=ca(a.value,10),a=d.A[a])if(a.za){for(var b=a.za,c="",h=0,k;k=Yo(b,h++);)for(var l=0,n=k.length;la.Bb||f[1]>a.ub)&&(this.Oa('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.hb)),b=null);b?(a.za=b,a.jk=c,a.Le=d,Cp(this,c,d,b),f=b.info(),this.X|=128,this.Oa('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.hb),a.Ae||e),a.yg=f[0],a.Nf=f[1],a.Of=f[2],this.V&&this.V.yd()):a.$e=!1;a.Ae&&(a.Ae=!1,--this.fa||rb(this));sp(this,a.hb)}; function xp(a,b,c){if((a=a.qa.listDisks)&&a.options){for(var d=0;d=this.C&&(this.ma&=-81,this.L=this.C=0);return c}; -m.Om=function(a,b,c){A(this)&&x(this,a,b,c,"DATA["+this.C+"]");this.C=rp[a].Vd){b=!1;this.L=0;a=Dp(this);var d,e,f,g,h=a&31;switch(h){case 3:Dp(this);Dp(this);Ep(this);break;case 4:c=Dp(this);this.hb=c&3;d=this.A[this.hb];Ep(this);Fp(this,(d.Cb&-16777216)>>>24);break;case 5:case 6:c=Dp(this);b=c>>2&1;this.hb=c&3;d=this.A[this.hb];d.kb=b;c=d.Rb=Dp(this);e=Dp(this);f=d.xb=Dp(this);g=Dp(this);d.Hb=128<=rp[a].Vd){b=!1;this.L=0;a=Dp(this);var d,e,f,g,h=a&31;switch(h){case 3:Dp(this);Dp(this);Ep(this);break;case 4:c=Dp(this);this.hb=c&3;d=this.A[this.hb];Ep(this);Fp(this,(d.Cb&-16777216)>>>24);break;case 5:case 6:c=Dp(this);b=c>>2&1;this.hb=c&3;d=this.A[this.hb];d.kb=b;c=d.Rb=Dp(this);e=Dp(this);f=d.xb=Dp(this);g=Dp(this);d.Hb=128<>2&1;this.hb=c&3;d= this.A[this.hb];c=d.Rb;e=d.kb=b;f=d.xb=1;g=0;d.Cb=0;d.za&&(d.pb=d.za.seek(d.Rb,d.kb,d.xb))?g=d.pb.length>>8:d.Cb=72;Gp(this,d,a,b,c,e,f,g);b=!0;break;case 13:c=Dp(this);b=c>>2&1;this.hb=c&3;d=this.A[this.hb];c=d.Rb;e=d.kb=b;f=1;g=Dp(this);d.Hb=128<>2&1,c=Dp(this),d.Rb+=c-d.ge,0>d.Rb&&(d.Rb=0),d.Rb>=d.Bb&&(d.Rb=d.Bb-1),d.ge=c,d.Cb=32,d.Rb||(d.Cb|=268435456),Ep(this),b=!0}0>2&1,c=Dp(this),d.Rb+=c-d.ge,0>d.Rb&&(d.Rb=0),d.Rb>=d.Bb&&(d.Rb=d.Bb-1),d.ge=c,d.Cb=32,d.Rb||(d.Cb|=268435456),Ep(this),b=!0}0>>8);Fp(a,(b.Cb&16711680)>>>16);var k=0;if(e!=b.Rb||f!=b.kb)k=g=1;c&128&&(f^=k,d||(k=0));Fp(a,e+k);Fp(a,f);Fp(a,g);Fp(a,h)}function Dp(a){var b=a.W[a.L];a.L++;return b}function Ep(a){a.L=a.C=0}function Fp(a,b){a.W[a.C++]=b} m.wk=function(a,b,c){if(void 0===b||0>b){b=-1;var d=null,e=0;if(!a.Cb&&a.za){do{if(a.pb&&(e=a.eb,0<=(b=a.za.read(a.pb,a.eb++)))){d=a.pb;break}a.pb=a.za.seek(a.Rb,a.kb,a.xb);if(!a.pb){a.Cb=1088;break}a.eb=0;Hp(a)}while(1)}c(b,!1,d,e)}else c(-1,!1)};m.xk=function(a,b){return void 0!==b&&0<=b?Ip(a,b):-1}; m.Lk=function(a,b){var c;if(void 0!==b&&0<=b)a:if(c=b,a.Cb)c=-1;else{a.md[a.Ve++]=c;if(a.Ve==a.md.length){a.Rb=a.md[0];a.kb=a.md[1];a.xb=a.md[2];a.Hb=128<Ip(a,a.xi)){c=-1;break a}a.mg++}a.mg>=a.he&&(c=-1)}else c=-1;return c};function Ip(a,b){if(a.Cb||!a.za)return-1;do{if(a.pb&&a.za.write(a.pb,a.eb++,b))break;a.pb=a.za.seek(a.Rb,a.kb,a.xb);if(!a.pb){a.Cb=8256;b=-1;break}a.eb=0;Hp(a)}while(1);return b} -function Hp(a){a.xb++;a.xb>=a.Of+1&&(a.xb=1,a.kb++,a.kb>=a.Nf&&(a.kb=0,a.Rb++))}var vp={1012:qp.prototype.wl,1013:qp.prototype.ul,1015:qp.prototype.vl},wp={1010:qp.prototype.Pm,1013:qp.prototype.Om,1015:qp.prototype.Nm};Qa(function(){for(var a=nb(document,"pcjs","fdc"),b=0;b=a.Of+1&&(a.xb=1,a.kb++,a.kb>=a.Nf&&(a.kb=0,a.Rb++))}var vp={1009:qp.prototype.vl,1012:qp.prototype.xl,1013:qp.prototype.ul,1015:qp.prototype.wl},wp={1010:qp.prototype.Qm,1013:qp.prototype.Pm,1015:qp.prototype.Om};Qa(function(){for(var a=nb(document,"pcjs","fdc"),b=0;b=this.C&&(this.L=this.C=0,this.ma&=-15);return c};m.mn=function(a,b,c){x(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.ma|=2,this.ma&=-2,Tp(this))};m.Xl=function(a,b){var c=this.ma;x(this,a,null,b,"STATUS",c);this.L=this.C&&(this.L=this.C=0,this.ma&=-15);return c};m.nn=function(a,b,c){x(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.ma|=2,this.ma&=-2,Tp(this))};m.Yl=function(a,b){var c=this.ma;x(this,a,null,b,"STATUS",c);this.L=a.B.Va?(a.ma=128,Vp(a.B,function(b){0<=b?(Wp(a),a.N&&5180==a.N.ia&&(a.ma=0),a.ma|=88):(a.ma=1,a.X=16)},!1)):a.ma=80));return d}m.Ak=function(a,b){return Up(this,a,b)|Up(this,a,b)<<8}; -function Xp(a,b,c,d){if(a.B&&a.B.Hb>=a.B.Va)if(0>Yp(a.B,c))a.ma=1,a.X=16;else if(1==a.B.eb||a.B.eb==a.B.Va)A(a,1048832)&&x(a,b,c,d,"DATA["+a.B.eb+"]"),1=a.B.Va&&(a.ma|=8))}m.vm=function(a,b,c){Xp(this,a,b&255,c);Xp(this,a,b>>8&255,c)};m.dl=function(a,b){var c=this.X;x(this,a,null,b,"ERROR",c);return c};m.Am=function(a,b,c){x(this,a,b,c,"WPREC");this.Pa=b};m.fl=function(a,b){var c=this.aa;x(this,a,null,b,"SECCNT",c);return c}; -m.ym=function(a,b,c){x(this,a,b,c,"SECCNT");this.aa=b};m.gl=function(a,b){var c=this.Ca;x(this,a,null,b,"SECNUM",c);return c};m.zm=function(a,b,c){x(this,a,b,c,"SECNUM");this.Ca=b};m.bl=function(a,b){var c=this.ya;x(this,a,null,b,"CYLLO",c);return c};m.um=function(a,b,c){x(this,a,b,c,"CYLLO");this.ya=b};m.al=function(a,b){var c=this.wa;x(this,a,null,b,"CYLHI",c);return c};m.tm=function(a,b,c){x(this,a,b,c,"CYLHI");this.wa=b};m.cl=function(a,b){var c=this.ra;x(this,a,null,b,"DRVHD",c);return c}; -m.wm=function(a,b,c){x(this,a,b,c,"DRVHD");this.ra=b;this.ma=this.A[this.ra&16?1:0]?this.ma|80:this.ma&-65};m.hl=function(a,b){var c=this.ma;x(this,a,null,b,"STATUS",c);this.ma&64&&(this.ma&=-129);return c};m.sm=function(a,b,c){x(this,a,b,c,"COMMAND");this.Ea=b;this.N&&dg(this.N,14);Zp(this)};m.xm=function(a,b,c){x(this,a,b,c,"FDR");this.ga&4&&!(b&4)&&(this.X=1);this.ga=b}; +function Xp(a,b,c,d){if(a.B&&a.B.Hb>=a.B.Va)if(0>Yp(a.B,c))a.ma=1,a.X=16;else if(1==a.B.eb||a.B.eb==a.B.Va)A(a,1048832)&&x(a,b,c,d,"DATA["+a.B.eb+"]"),1=a.B.Va&&(a.ma|=8))}m.wm=function(a,b,c){Xp(this,a,b&255,c);Xp(this,a,b>>8&255,c)};m.dl=function(a,b){var c=this.X;x(this,a,null,b,"ERROR",c);return c};m.Bm=function(a,b,c){x(this,a,b,c,"WPREC");this.Pa=b};m.fl=function(a,b){var c=this.aa;x(this,a,null,b,"SECCNT",c);return c}; +m.zm=function(a,b,c){x(this,a,b,c,"SECCNT");this.aa=b};m.gl=function(a,b){var c=this.Ca;x(this,a,null,b,"SECNUM",c);return c};m.Am=function(a,b,c){x(this,a,b,c,"SECNUM");this.Ca=b};m.bl=function(a,b){var c=this.ya;x(this,a,null,b,"CYLLO",c);return c};m.vm=function(a,b,c){x(this,a,b,c,"CYLLO");this.ya=b};m.al=function(a,b){var c=this.wa;x(this,a,null,b,"CYLHI",c);return c};m.um=function(a,b,c){x(this,a,b,c,"CYLHI");this.wa=b};m.cl=function(a,b){var c=this.ra;x(this,a,null,b,"DRVHD",c);return c}; +m.xm=function(a,b,c){x(this,a,b,c,"DRVHD");this.ra=b;this.ma=this.A[this.ra&16?1:0]?this.ma|80:this.ma&-65};m.hl=function(a,b){var c=this.ma;x(this,a,null,b,"STATUS",c);this.ma&64&&(this.ma&=-129);return c};m.tm=function(a,b,c){x(this,a,b,c,"COMMAND");this.Ea=b;this.N&&dg(this.N,14);Zp(this)};m.ym=function(a,b,c){x(this,a,b,c,"FDR");this.ga&4&&!(b&4)&&(this.X=1);this.ga=b}; function Zp(a){var b=!1,c=a.Ea,d=a.ra&16?1:0,e=a.ra&15,f=a.ya|(a.wa&3)<<8,g=a.Ca,h=a.aa||256;a.hb=-1;a.B=null;a.X=0;a.ma=80;var k=a.A[d];k?(k.de=f,k.kb=e,k.xb=g,k.Hb=h*k.Va,c=144<=c?c:c&240,k.pb=null,k.eb=0,k.errorCode=0,a.hb=d,a.B=k):c=-1;switch(c&240){case 16:b=!0;break;case 32:a.ma=128;Vp(k,function(b){0<=b&&a.N?(Wp(a),a.ma=88):(a.ma=1,a.X=16)},!1);break;case 48:a.ma=8;break;case 64:b=!0;break;case 112:b=!0;break;case 144:a.X=1;b=!0;break;case 145:k.ub=e+1,k.lb=h,b=!0}b&&Wp(a)} function Wp(a){!a.N||a.ga&2||eg(a.N,14,120)} function Tp(a){a.L=0;var b=$p(a),c=$p(a),d=c&32,e=d>>5,f=c&31,g=$p(a),h=$p(a),k=g<<2&768|h,l=g&63,n=$p(a),q=$p(a),p=a.A[e];p&&(p.de=k,p.kb=f,p.xb=l,p.Hb=n*p.Va);switch(b){case 3:aq(a,p?p.errorCode:4);bq(a,c);bq(a,g);bq(a,h);bq(a,0|d);b=-1;break;case 12:for(c=0;0<=(b=$p(a));)p&&c=a.lb+b&&(a.xb=b,a.kb++,a.kb>=a.ub&&(a.kb=0,a.de++))}m.Yl=function(){var a=this.F.M&255;!(this.F.G>>8)&&128>8||!this.N)||(a=!(this.N.vc[0].Bd&64));return a?!0:!1}; -var Np={800:Jp.prototype.Wl,801:Jp.prototype.Xl,802:Jp.prototype.Vl},Mp={496:Jp.prototype.Ak,497:Jp.prototype.dl,498:Jp.prototype.fl,499:Jp.prototype.gl,500:Jp.prototype.bl,501:Jp.prototype.al,502:Jp.prototype.cl,503:Jp.prototype.hl},Pp={800:Jp.prototype.mn,801:Jp.prototype.pn,802:Jp.prototype.on,803:Jp.prototype.nn,807:Jp.prototype.fi,811:Jp.prototype.fi,815:Jp.prototype.fi},Op={496:Jp.prototype.vm,497:Jp.prototype.Am,498:Jp.prototype.ym,499:Jp.prototype.zm,500:Jp.prototype.um,501:Jp.prototype.tm, -502:Jp.prototype.wm,503:Jp.prototype.sm,1014:Jp.prototype.xm};Qa(function(){for(var a=nb(document,"pcjs","hdc"),b=0;b=a.lb+b&&(a.xb=b,a.kb++,a.kb>=a.ub&&(a.kb=0,a.de++))}m.Zl=function(){var a=this.F.M&255;!(this.F.G>>8)&&128>8||!this.N)||(a=!(this.N.vc[0].Bd&64));return a?!0:!1}; +var Np={800:Jp.prototype.Xl,801:Jp.prototype.Yl,802:Jp.prototype.Wl},Mp={496:Jp.prototype.Ak,497:Jp.prototype.dl,498:Jp.prototype.fl,499:Jp.prototype.gl,500:Jp.prototype.bl,501:Jp.prototype.al,502:Jp.prototype.cl,503:Jp.prototype.hl},Pp={800:Jp.prototype.nn,801:Jp.prototype.qn,802:Jp.prototype.pn,803:Jp.prototype.on,807:Jp.prototype.fi,811:Jp.prototype.fi,815:Jp.prototype.fi},Op={496:Jp.prototype.wm,497:Jp.prototype.Bm,498:Jp.prototype.zm,499:Jp.prototype.Am,500:Jp.prototype.vm,501:Jp.prototype.um, +502:Jp.prototype.xm,503:Jp.prototype.tm,1014:Jp.prototype.ym};Qa(function(){for(var a=nb(document,"pcjs","hdc"),b=0;b>2;this.Ba=b.wg;this.bc=new ed(this.F,7,"DBG");this.Ia=yq;80186<=this.F.ia&&(this.Ia=yq.slice(),this.Ia[15]=wq,80286<=this.F.ia&&(this.Ia[15]=xq,80386<=this.F.ia&&(this.Ja=8)));Mk(this,64,function(a){Cq(d,d.F.ld,a[0])});Mk(this,4,function(a){if(a=a[0]){var b=Dq(d,a);if(void 0===b)d.O("invalid selector: "+a);else if(a=Eq(d, b,2),d.O("dumpSel("+u(a?a.Z:b)+"): %"+r(a?a.Xb:null,d.Ca)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var h=Fq[a.type];h&&(c=h[0],b=h[1])}!c||a.wb&32768||(c+=",not present");d.O((b?"seg="+u(a.Aa&65535)+" off="+u(a.Ta):"base="+r(a.Aa,d.Ca)+" limit="+Gq(a.Ta))+" type="+t(a.type>>8)+" ("+c+") ext="+u(a.ext&-65296)+ " dpl="+t(a.Gc))}}else d.O("no selector")});Mk(this,134217728,function(a){var b;(a=a[0])&&(b=Dq(d,a));if(void 0===b)d.O("invalid MCB");else for(d.O("dumpMCB("+u(b)+")");b;){a=hq(d,0,b);var c=d.Qa(a,1),h=d.na(a,2),k=d.na(a,5);if(77!=c&&90!=c)break;d.O(Hq(0,b)+": '"+String.fromCharCode(c)+"' PID="+u(h)+" LEN="+u(k)+' "'+Iq(d,a,8)+'"');b+=1+k}});Mk(this,128,function(a){Cq(d,d.F.sa,a[0],d.F.sa!==d.F.ld)});Mk(this,8,function(a){a:{if(a=a[0]){var b=Dq(d,a);if(void 0===b){d.O("invalid task selector: "+a); -break a}a=Eq(d,b,2)}else a=d.F.Sa;d.O("dumpTSS("+u(a?a.Z:b)+"): %"+r(a?a.Aa:null,d.Ca));if(a){var b="",c=a.type&-513,h=256==c?4:8,k=256==c?Jq:Kq,l,n,q,p;for(p in k)l=k[p],n=a.Aa+l,q=If(d.F,n,2),2304==c&&(q|=If(d.F,n+2,2)<<16),b&&(b+="\n"),b+=u(l)+" "+ma(p+":",11)+r(q,h);if(2304==c)for(p=0,l=q>>>16;lp;)n=a.Aa+l,q=If(d.F,n,2),b+="\n"+u(l)+" ports "+u(p)+"-"+u(p+15)+": "+ea(q,2),p+=16,l+=2;d.O(b)}}});this.C=null;this.rb=0;this.cb=!1;cf(this.F,48,this.am.bind(this));cf(this.F,65,this.bm.bind(this)); -this.ka=null;cf(this.F,104,this.cm.bind(this));rb(this)};function Lq(a,b,c,d,e,f){b=Iq(a,b);var g=Eq(a,d),g=g?g.Ta+1:0,h=(e?"_CODE":"_DATA")+r(c,2);f&&A(a,128)&&a.message(b+" "+(e?"code":"data")+"("+r(c,4)+")=#"+r(d,4)+" len "+r(g));e=Mq(a,b,c);e[b+h]=0;am(a,b,c,d,0,null,g,e)} +break a}a=Eq(d,b,2)}else a=d.F.Sa;d.O("dumpTSS("+u(a?a.Z:b)+"): %"+r(a?a.Aa:null,d.Ca));if(a){var b="",c=a.type&-513,h=256==c?4:8,k=256==c?Jq:Kq,l,n,q,p;for(p in k)l=k[p],n=a.Aa+l,q=If(d.F,n,2),2304==c&&(q|=If(d.F,n+2,2)<<16),b&&(b+="\n"),b+=u(l)+" "+ma(p+":",11)+r(q,h);if(2304==c)for(p=0,l=q>>>16;lp;)n=a.Aa+l,q=If(d.F,n,2),b+="\n"+u(l)+" ports "+u(p)+"-"+u(p+15)+": "+ea(q,2),p+=16,l+=2;d.O(b)}}});this.C=null;this.rb=0;this.cb=!1;cf(this.F,48,this.bm.bind(this));cf(this.F,65,this.cm.bind(this)); +this.ka=null;cf(this.F,104,this.dm.bind(this));rb(this)};function Lq(a,b,c,d,e,f){b=Iq(a,b);var g=Eq(a,d),g=g?g.Ta+1:0,h=(e?"_CODE":"_DATA")+r(c,2);f&&A(a,128)&&a.message(b+" "+(e?"code":"data")+"("+r(c,4)+")=#"+r(d,4)+" len "+r(g));e=Mq(a,b,c);e[b+h]=0;am(a,b,c,d,0,null,g,e)} function Nq(a,b,c,d){var e=a.na(b,2),f=a.na(b,2),g=a.oa(b,4),h=a.oa(b,4),k=hq(a,a.oa(b,4),a.na(b,2));b=hq(a,a.oa(b,4),a.na(b,2));b=Iq(a,b).toUpperCase();var k=Iq(a,k).toUpperCase(),l=(c?"_CODE":"_DATA")+r(e,2);d&&A(a,128)&&a.message((b==k?"":b+"!")+k+" "+(c?"code":"data")+"("+r(e,4)+")="+r(f,4)+":"+r(g)+" len "+r(h));c=Mq(a,k,e);c[k+l]=g;am(a,k,e,f,g,null,h,c)}function Oq(a,b,c){c=Iq(a,c).toUpperCase();Pq(a,c,b)} -m.am=function(){var a=this.F;if(null!=this.C&&2752554==a.G){var b=a.M&65535,c=a.K&65535,d=hq(this,I(a)+12,a.ta.Z);switch(this.oa(d)){case 336:Nq(this,hq(this,a.H,b),!c,!!this.C)}}return!0}; -m.bm=function(a){var b=this.F,c=b.G&65535,d=b.H&65535,e=b.I&65535,f=b.M&65535,g=b.K&65535,h=b.J&65535,k=b.Xa.Z;if(null==this.C)return 79==c&&df(b,a,function(a){return function(){62342!=(b.G&65535)?(b.G=b.G&-65536|62342,y(a,"INT 0x41 handling enabled",128),a.C=!0):(y(a,"INT 0x41 monitoring enabled",128),a.C=!1)}}(this)),!0;switch(c){case 79:this.C&&(b.G=b.G&-65536|62342,y(this,"INT 0x41 handling enabled",128));break;case 80:Lq(this,hq(this,h,k),d+1,e,!(g&1),!!this.C);break;case 82:Pq(this,null,d); +m.bm=function(){var a=this.F;if(null!=this.C&&2752554==a.G){var b=a.M&65535,c=a.K&65535,d=hq(this,I(a)+12,a.ta.Z);switch(this.oa(d)){case 336:Nq(this,hq(this,a.H,b),!c,!!this.C)}}return!0}; +m.cm=function(a){var b=this.F,c=b.G&65535,d=b.H&65535,e=b.I&65535,f=b.M&65535,g=b.K&65535,h=b.J&65535,k=b.Xa.Z;if(null==this.C)return 79==c&&df(b,a,function(a){return function(){62342!=(b.G&65535)?(b.G=b.G&-65536|62342,y(a,"INT 0x41 handling enabled",128),a.C=!0):(y(a,"INT 0x41 monitoring enabled",128),a.C=!1)}}(this)),!0;switch(c){case 79:this.C&&(b.G=b.G&-65536|62342,y(this,"INT 0x41 handling enabled",128));break;case 80:Lq(this,hq(this,h,k),d+1,e,!(g&1),!!this.C);break;case 82:Pq(this,null,d); break;case 127:this.C&&(b.G=b.G&-65536|(this.cb?0:1));break;case 131:this.C&&(a=hq(this,b.M,e),this.rb++?(this.O("TRAPFAULT failed"),Qq(this,this.A,a,!0,!0),this.rb=0,this.Wb()):(this.O("INT 0x41 TRAPFAULT: fault="+u(d)+" error="+("0x"+r(b.K))+" addr="+Rq(a)),this.Sd(this.A,a,!0),jq(this,!0)));break;case 141:this.C&&(b.G=b.G&-65536|1);break;case 336:Nq(this,hq(this,b.H,f),!g,!!this.C);break;case 338:Oq(this,d,hq(this,b.J,f))}this.cb=!1;return!this.C}; -m.cm=function(a){var b=this.F,c=b.G&255,d=b.G>>8&255,e=b.H&65535,f=b.I&65535,g=b.M&65535,h=b.J&65535,k=b.Xa.Z;if(null==this.ka){if(67==d){if(609437257==b.oa((b.va.Z<<4)+10)||1111835735==b.oa((b.va.Z<<4)+95))return!0;df(b,a,function(a){return function(){62342!=(b.G&65535)?(b.G=b.G&-65536|62342,y(a,"INT 0x68 handling enabled",128),a.C=a.ka=!0):(y(a,"INT 0x68 monitoring enabled",128),a.ka=!1)}}(this))}return!0}switch(d){case 67:this.ka&&(b.G=b.G&-65536|62342);break;case 68:this.ka&&(a=gd(b.va,this.Hk.bind(this)))&& +m.dm=function(a){var b=this.F,c=b.G&255,d=b.G>>8&255,e=b.H&65535,f=b.I&65535,g=b.M&65535,h=b.J&65535,k=b.Xa.Z;if(null==this.ka){if(67==d){if(609437257==b.oa((b.va.Z<<4)+10)||1111835735==b.oa((b.va.Z<<4)+95))return!0;df(b,a,function(a){return function(){62342!=(b.G&65535)?(b.G=b.G&-65536|62342,y(a,"INT 0x68 handling enabled",128),a.C=a.ka=!0):(y(a,"INT 0x68 monitoring enabled",128),a.ka=!1)}}(this))}return!0}switch(d){case 67:this.ka&&(b.G=b.G&-65536|62342);break;case 68:this.ka&&(a=gd(b.va,this.Hk.bind(this)))&& (b.J=a[0],wd(b,a[1]));break;case 72:Pq(this,null,e);break;case 80:32==c?Lq(this,hq(this,h,k),0,f,!0,!!this.ka):128>c?Lq(this,hq(this,h,k),e+1,c&64?g:f,!(c&1),!!this.ka):Nq(this,hq(this,h,k),!(c&1),!!this.ka),this.ka&&(b.G=b.G&-256|1)}return!this.ka};m.Hk=function(){var a=this.F;5==(a.G&255)&&(a.I=a.K=0,a.G=a.G&-256|1);return!1}; m.Qb=function(a,b,c){var d=this;switch(b){case "debugInput":return this.Ka=this.qa[b]=c,c.onkeydown=function(a){var b;if(13==a.keyCode)b=c.value,c.value="",lq(d,b,!0);else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?d.U>>f.La].Sd(e&f.Fa,a==this.ga);g&&Vb(f)}}d&&(a.push(b),c?(null!=b.Da&&(b.Z=null),b.Xd=!0):(mr(this,a,a.length-1,"set"),jq(this)));return d}; +m.Sd=function(a,b,c){var d=!0;c||Qq(this,a,b,!1,!0);if(a!=this.A){var e=this.dc(b);if(-1===e)this.O("invalid address: "+Rq(b)),d=!1;else{var f=this.F,g=5==b.type;(g?f.ld:f.sa)[e>>>f.La].Sd(e&f.Fa,a==this.ga);g&&Ub(f)}}d&&(a.push(b),c?(null!=b.Da&&(b.Z=null),b.Xd=!0):(mr(this,a,a.length-1,"set"),jq(this)));return d}; function Qq(a,b,c,d,e){for(var f=!1,g=nr(a,a.dc(c)),h=1;h>3&7,z=(3>(g>>6&3)?0:48)+p;(217==f||219==f)&&52<=z&&(z=p<<4|g&7);(p=Aq[f])&&(q=p[z]);q&&(n=qq,k=q,l=k[0])}l>=n.length&&(g=a.Qa(b,1),k=Bq[l-n.length][g>>3&7],l=k[0]);n=n[l];p=k.length-1;q="";b.Sb&&(18==l? n="CWDE":28==l?n="CDQ":104<=l&&107>=l&&(n+="D"));if(164<=f&&167>=f||170<=f&&175>=f)p=0,b.Sb&&"W"==n.slice(-1)&&(n=n.slice(0,-1)+"D");for(var f=null,z=!0,F=1;F<=p;F++){var v,E;v="";E=k[F];if(void 0!==E){null==f&&(f=E>>14);80==l&&(2==f?q="[%800]":3==f&&(q="ES:["+(b.pc?"E":"")+"DI]"));var H=E&15;if(0!=H)if(8==H)z=!1;else{var L=E&240;if(128<=L)if(0>g&&(g=a.Qa(b,1)),160>L){v=a;var V=p,H=b,P="",bb=g>>6,ia=g&7;if(3>bb){var ja=void 0,L=0==n.indexOf("FI");if(!bb&&(!H.pc&&6==ia||H.pc&&5==ia))bb=2;else{if(H.pc)if(4!= -ia)ia+=8;else{var P=v,ja=bb,Ha=H,Xa=P.Qa(Ha,1),Ba=Xa>>6,Ub=Xa>>3&7,Xa=Xa&7,wa="";if(ja||5!=Xa)wa=uq[Xa+8];4!=Ub&&(wa&&(wa+="+"),wa+=uq[Ub+8],Ba&&(wa+="*"+(1<>24,P+="-"+r(-ja,2)):P+="+"+r(ja,2)):2==bb&&(P&&(P+="+"),H.pc?(ja=v.oa(H,4),P+=r(ja)):(ja=v.na(H,2),P+=r(ja,4)));P="["+P+"]";if(1==V){v="";E&=15;4==E&&(E=H.Sb?5:3);switch(E){case 7:v="FAR";break;case 1:v="BYTE";break;case 3:if(L){v="INT16"; +ia)ia+=8;else{var P=v,ja=bb,Ha=H,Xa=P.Qa(Ha,1),Ba=Xa>>6,Vb=Xa>>3&7,Xa=Xa&7,wa="";if(ja||5!=Xa)wa=uq[Xa+8];4!=Vb&&(wa&&(wa+="+"),wa+=uq[Vb+8],Ba&&(wa+="*"+(1<>24,P+="-"+r(-ja,2)):P+="+"+r(ja,2)):2==bb&&(P&&(P+="+"),H.pc?(ja=v.oa(H,4),P+=r(ja)):(ja=v.na(H,2),P+=r(ja,4)));P="["+P+"]";if(1==V){v="";E&=15;4==E&&(E=H.Sb?5:3);switch(E){case 7:v="FAR";break;case 1:v="BYTE";break;case 3:if(L){v="INT16"; break}v="WORD";break;case 5:v="DWORD";break;case 11:if(L){v="INT32";break}case 11:v="REAL32";break;case 12:if(L){v="INT64";break}case 12:v="REAL64";break;case 13:v="REAL80";break;case 14:v="BCD80"}v&&(P=v+" "+P)}}else P=rr(v,ia,E,H);v=P}else v=160==L?rr(a,g&7,E,b):rr(a,g>>3&7,E,b);else if(16==L)v="1";else if(0==L){v=a;H=E;L=b;E=" ";switch(H&15){case 1:H&12288&&(E=r(v.Qa(L,1),2));break;case 2:E=r(v.Qa(L,1)<<24>>24,L.Sb?8:4);break;case 4:if(L.Sb){E=r(v.oa(L,4));break}case 3:E=r(v.na(L,2),4);break;case 7:L= hq(v,v.tb(L,!0),v.na(L,2),null,L.type,L.Sb,L.pc);E=Rq(L);v=sr(v,L);v[0]&&(E+=" ("+v[0]+")");break;default:E="imm("+u(H)+")"}v=E}else 32==L?(b.pc?(v=8,E=a.oa(b,4)):(v=4,E=a.na(b,2)),v="["+r(E,v)+"]"):48==L?(v=1==H?a.Qa(b,1)<<24>>24:a.tb(b,!0),E=b.Ra+v&(b.Sb?-1:65535),v=r(E,b.Sb?8:4),E=sr(a,hq(a,E,b.Z)),E[0]&&(v+=" ("+E[0]+")")):96==L?v=9==H?"ST":10==H?"ST("+(g&7)+")":rr(a,(E&3840)>>8,E,b):112==L?v=rr(a,(E&3840)>>8,192,b):64==L?v="DS:[SI]":80==L&&(v="ES:[DI]");if(!v||!v.length){q="INVALID";break}0< q.length&&(q+=",");q+=v||"???"}}}g="";k=Rq(e)+" ";if(-1!==e.Da&&-1!==b.Da){do if(g+=r(a.Qa(e,1),2),null==e.Da)break;while(e.Da!=b.Da)}k+=ma(g,e.pc?24:16);k+=ma(n,8);q&&(k+=" "+q);a.F.ia=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);eb[0]?1:a[0]>>0,n],v=oa(z,p,a.sb);0>v&&z.splice(-(v+1),0,p)}F&&(q.a=F.replace(/''/g,'"'))}a.B.push({fg:b,lm:c,Z:d,Ra:e,Da:f,dm:g,Rd:h,ri:l})} -function Pq(a,b,c){for(var d=0;d>>0,f=a.dc(b)>>>0,g=0;g>>0,n=h.Da;null!=n&&(n>>>=0);var q=h.dm;48==k&&(k=40);if(k==b.Z&&e>=l&&e=n&&f>>0,n],v=oa(z,p,a.sb);0>v&&z.splice(-(v+1),0,p)}F&&(q.a=F.replace(/''/g,'"'))}a.B.push({fg:b,mm:c,Z:d,Ra:e,Da:f,em:g,Rd:h,ri:l})} +function Pq(a,b,c){for(var d=0;d>>0,f=a.dc(b)>>>0,g=0;g>>0,n=h.Da;null!=n&&(n>>>=0);var q=h.em;48==k&&(k=40);if(k==b.Z&&e>=l&&e=n&&f>>20;Da.ui=a.F.Pd+Da.bk;Da.yb=ce.sa[(Da.ui&ce.Gb)>>>ce.La];Da.Ui=Da.yb.Nd(Da.bk);Da.ck=(Te&4190208)>>>10;Da.vi=(Da.Ui&-4096)+Da.ck;Da.zb=ce.sa[(Da.vi&ce.Gb)>>>ce.La];Da.Vi=Da.zb.Nd(Da.ck);Da.Fk=(Da.Vi&-4096)+(Te&4095)}if(be=Da){a.O("linear PDE addr PDE PTE addr PTE physical");a.O("--------- ---------- -------- ---------- -------- ----------");var qd="%"+r(Te),qd=qd+(" %%"+cr(be.ui,be.Ui)),qd=qd+(" %%"+cr(be.vi,be.Vi,!0)), qd=qd+(" %%"+r(be.Fk));a.O(qd)}else a.O("unsupported operation")}}else a.O("missing address")}else{if("d"==ia){if("disk"==ja){P[0]="l";P[1]="json";Ir(a,P);break a}for(bb in vq)if(P[1]==bb){var Dn=a.$a[bb];Dn?(P.shift(),P.shift(),Dn(P)):a.O("no dump registered for "+ja);break a}ja||(ia=a.Cc||"db")}else a.Cc=ia;if("dh"==ia){var En=ja,Fn=Ha,Gn="",Hn=0,tb=a.Fa,tc=a.ja;if(tc.length){var Db=+En||a.Ub,de=+Fn||10;isNaN(Db)?Db=de:Gn="more ";Db>tc.length&&(a.O("note: only "+tc.length+" available"),Db=tc.length); tb-=Db;0>tb&&(null==tc[tc.length-1].Z?(Db=tb+Db,tb=0):tb+=tc.length);var ii=[];"call"==Fn&&(de=1E5,ii=["CALL"]);for(void 0!==En&&a.O(Db+" instructions earlier:");0=tc.length&&(tb=0);a.Ub=Db;Hn++;de--}}Hn||(a.O("no "+Gn+"history available"),a.Ub=void 0)}else if("di"==ia){P.shift(); diff --git a/docs/pcjs/examples/pc.js b/docs/pcjs/examples/pc.js index a3d40a8b53..81f50f3005 100644 --- a/docs/pcjs/examples/pc.js +++ b/docs/pcjs/examples/pc.js @@ -29,7 +29,7 @@ function mb(a,b,c){var d=1280/null.offsetWidth,e=720/null.offsetHeight,f=null.ge l.Xd=function(){};function qb(a,b,c,d){a.B.He[a.B.Gh++]={Ij:b,hd:c,type:d};return na(nb,b,c,0,d)}function ob(a,b,c,d){var e,f=null.style.color,g=a.xa=10;a.D=g;a.K=b;a.L=a.ka=18;e||(e=a.ia||a.ka+"px Monaco, Lucida Console, Courier New");a.S=a.ia=e;c&&(a.pa=c);d&&(a.G=d,a.qa=f||"white")} function pb(a,b,c,d,e){a.G.font=a.S;a.G.fillStyle=a.qa;a.G.fillText(b,a.D,a.K);a.D+=a.ba;null!=c&&(16!=a.Ja?b=c.toString():(b=8>a.va?"0x":"",b+=ea(c,a.va)),a.G.fillText(b,a.D,a.K),a.D+=a.ba);d&&(a.D+=a.ba*d);e&&(a.D=a.xa,a.K+=(a.L+2)*(e||1))}function lb(){for(var a=!1,b=Za(document,"pcjs","panel"),c=0;c=this.D?12:24>=this.D?14:15;this.vb=1<>2;this.B=this.vb-1;this.H=this.L/this.vb|0;this.C=this.H-1;this.I=[];this.K=[];this.P=[];this.S=[];a=new q;sb(a,this.Ia);this.R=Array(this.H);for(b=0;b>>a.da;0a.vb?a.vb:c;if(g&&g.size){if(g.type==d&&g.controller==e){if(b+c<=g.fe)return g.De+=g.fe-b,g.fe=b,!0;if(b>=g.fe+g.De){k=g.size-(b-h);k>c&&(k=c);g.De=b-g.fe+k;c-=k;b=h+a.vb;continue}}return zb(a,1,b,c)}g=a.R[f];b=new q(b,k,a.vb,d,e);sb(b,a.Ia,g);a.R[f++]=b;b=h+a.vb;c-=k}return 0>=c?(a=a.A,a.Pa&-2147483648&&Bb(a),!0):zb(a,2,b,c)} function xb(a,b){if(32==a.D)b?a.G&&(Cb(a,1048576,1048576,a.G),a.G=null):a.G||(a.G=Db(a,1048576,1048576),Cb(a,1048576,1048576,Db(a,0,1048576)));else if(20>>this.da;0>>a.da;0>>=a.da;0>>=f)&k;if(void 0!==g&&g[0])g[0](b,k,e);f+=h<<3;b+=h;c-=h}}function zb(a,b,c,d,e){b="Memory block error ("+b+": "+ea(c)+","+ea(d)+")";e?a.Ia?a.Ia.message(b):a.log(b):n(b);return!1}var Rb;if(db){var Sb=new ArrayBuffer(2);(new DataView(Sb)).setUint16(0,256,!0);Rb=256===(new Uint16Array(Sb))[0]}else Rb=!1;var Hb=Rb; function q(a,b,c,d,e,f){this.id=Tb+=2;this.V=null;this.H=0;this.fe=a;this.De=b;this.size=c||0;this.type=d||Ub;this.I=d==Gb;this.controller=null;this.A=f;sb(this);this.Ha=this.Oh=!1;if(c)if(e)this.controller=e,a=e.Th(a),this.V=a[0],this.H=a[1],Eb(this,e.lg());else if(db)this.R=new ArrayBuffer(c),this.P=new DataView(this.R,0,c),this.Ka=new Uint8Array(this.R,0,c),this.ud=new Uint16Array(this.R,0,c>>1),this.V=new Int32Array(this.R,0,c>>2),Eb(this,Hb?Ib:Jb);else{this.V=Array(c>>2);for(e=0;e>8&65280|a>>>24);return a} -q.prototype={constructor:q,parent:null,Pk:function(a){this.fe=a},save:function(){var a,b;if(this.controller)a=null;else if(db)for(a=Array(this.size>>2),b=0;b>2),b=0;b>8,c)},la:function(a,b,c){this.Yb(a++,b&255,c++);this.Yb(a++,b>>8&255,c++);this.Yb(a++,b>>16&255,c++);this.Yb(a,b>>>24,c)},va:function(a){return this.V[a>>2]>>>((a&3)<<3)&255},fb:function(a){var b=a>>2;a=(a&3)<<3;var c=this.V[b]>>a;return 24>a?c&65535:c&255|(this.V[b+1]&255)<<8},Ga:function(a){var b=a>>2;a=(a&3)<<3;var c=this.V[b];a&&(c=c>>> a|this.V[b+1]<<32-a);return c},Bb:function(a,b){var c=a>>2,d=(a&3)<<3;this.V[c]=this.V[c]&~(255<>2,d=(a&3)<<3;24>d?this.V[c]=this.V[c]&~(65535<>8);this.Ha=!0},fc:function(a,b){var c=a>>2,d=(a&3)<<3;if(d){var e=-1<>>32-d}else this.V[c]=b;this.Ha=!0},ua:function(a,b){this.A&&Yb(this.A,b,1,!1);return this.Ed(a,b)},Xa:function(a, b){this.A&&Yb(this.A,b,2,!1);return this.ef(a,b)},Fa:function(a,b){this.A&&Yb(this.A,b,4,!1);return this.ih(a,b)},Ab:function(a,b,c){this.A&&Yb(this.A,c,1,!0);this.I||this.kf(a,b,c)},wc:function(a,b,c){this.A&&Yb(this.A,c,2,!0);this.I||this.oh(a,b,c)},Zb:function(a,b,c){this.A&&Yb(this.A,c,4,!0);this.I||this.oa(a,b,c)},za:function(a,b){this.B.V[this.D]|=this.K;this.C.V[this.G]|=this.K;return this.L.Wb(a,b)},qb:function(a,b){this.B.V[this.D]|=this.K;this.C.V[this.G]|=this.K;return this.L.ye(a,b)}, @@ -58,14 +58,14 @@ l.pc=function(a,b,c,d){this.aa=a;this.ha=b;this.Ia=d;for(b=0;bc&&(c=60);2>c&&(c=2);var d=1;b&&1a.T.Df&&(c=Math.round(c/a.T.Bd));return c}function kc(a){a.T.Ad=0;a.$c=a.zc=a.mc=a.A=0;lc(a);pc(a,1)} +function sc(a,b){var c=30;60>c&&(c=60);2>c&&(c=2);var d=1;b&&1a.T.Df&&(c=Math.round(c/a.T.Bd));return c}function kc(a){a.T.Ad=0;a.$c=a.zc=a.mc=a.A=0;lc(a);pc(a,1)} function pc(a,b,c){if(void 0!==b){.8>a.T.Ad/a.T.te&&(b=1);a.T.Bd=b;b=a.T.Df*a.T.Bd;if(a.T.te!=b){a.T.te=b;b=a.T.te.toFixed(2)+"Mhz";var d=a.la.setSpeed;d&&(d.textContent=b);a.rc("target speed: "+b)}c&&a.aa&&uc(a.aa)}rc(a,a.zc);a.zc=0;a.T.ue=ka();a.T.Rd=0;sc(a)} -l.mh=function(a){if($a(this,!0)){if(!this.ea.Sb){pc(this);this.aa&&this.aa.start(this.T.ue,tc(this));this.ea.Sb=!0;this.ea.Qh=!0;this.P&&vc(this.P);var b=this.la.run;b&&(b.textContent="Halt");this.aa&&(this.aa.Xd(),a&&uc(this.aa,!0))}this.T.ug>=this.T.ad&&sc(this,!0);this.T.Se=0;this.T.Ef=ka();this.T.Rd&&(a=this.T.Ef-this.T.Rd,a>this.T.Xh&&(this.T.ue+=a,this.T.ue>this.T.Ef&&(this.T.ue=this.T.Ef)));try{do{var c=this.ea.zf?1:this.T.Wk;if(this.P){wc(this.P);var d=this.P;a=c;var e=d.K[0];if(e.Od){var f= +l.mh=function(a){if($a(this,!0)){if(!this.ea.Sb){pc(this);this.aa&&this.aa.start(this.T.ue,tc(this));this.ea.Sb=!0;this.ea.Qh=!0;this.P&&vc(this.P);var b=this.la.run;b&&(b.textContent="Halt");this.aa&&(this.aa.Xd(),a&&uc(this.aa,!0))}this.T.ug>=this.T.ad&&sc(this,!0);this.T.Se=0;this.T.Ef=ka();this.T.Rd&&(a=this.T.Ef-this.T.Rd,a>this.T.Xh&&(this.T.ue+=a,this.T.ue>this.T.Ef&&(this.T.ue=this.T.Ef)));try{do{var c=this.ea.zf?1:this.T.Xk;if(this.P){wc(this.P);var d=this.P;a=c;var e=d.K[0];if(e.Od){var f= (tc(d.A,d.ba)-e.ld)/d.Ga|0,g=xc(d,0)-f;6==e.mode&&(g-=f);var h=g*d.Ga|0;6==e.mode&&(h>>=1);a>h&&(a=h)}var c=a,k=this.P;a=c;if(k.B&&k.B[11]&64){var m=k.ia-tc(k.A,k.ba);0m&&(a=m)}c=a}try{this.mj(c)}catch(x){if("number"!=typeof x)throw x;}var p=this.mc-this.A;this.zc+=p;this.T.Se+=p;rc(this,0,!0);a=p;this.ea.zf&&(b=!1,this.T.Ff=this.T.Ff+this.Sh()|0,this.T.ve-=a,0>=this.T.ve&&(this.T.ve+=this.T.Ne,b=!0),0<=this.T.Oe&&this.T.Oe<=tc(this)&&(this.T.Ne=this.T.Oe=-1,lc(this),oc(this),b=!0),b&&this.rc(tc(this)+ " cycles: checksum="+ea(this.T.Ff)));this.T.Qe-=p;0>=this.T.Qe&&(this.T.Qe+=this.T.Zh,this.aa&&yc(this.aa));this.T.Pe-=p;0>=this.T.Pe&&(this.T.Pe+=this.T.Yh,this.aa&&this.aa.Xd());this.T.Re-=p;if(0>=this.T.Re){this.T.Re+=this.T.tg;break}}while(this.ea.Sb)}catch(x){oc(this);mc(this);this.aa&&this.aa.stop(ka(),tc(this));$a(this,!1);cb(this,x.stack||x.message);return}c=setTimeout;d=this.wj;this.T.Rd=ka();e=this.T.Xh;this.T.Se&&(e=Math.round(e*this.T.Se/this.T.tg));e-=this.T.Rd-this.T.Ef;if(f=this.T.Rd- this.T.ue)this.T.Ad=Math.round(this.zc/(10*f))/100,864E5<=f&&(this.$c=0,this.P&&wc(this.P,!0),pc(this));if(0>e||this.T.Adthis.id&&t.call(e,b&&3==this.id?10:13,a&65532)}return-1};l.Tk=function(a){var b=this.A;a=b.Ab+(a<<2);var c=b.ga(a);b.W&=-769;return this.load(b.ga(a+2))+c|0};l.Sk=function(a){var b=this.A;a<<=3;var c=b.Ab+a|0;if(7<=(b.xc-c|0))return this.D=!0,a=Bc(this,c,a),-1!==a&&(a+=this.cf),a;t.call(b,13,a|2);return-1};l.Ih=function(a){return this.ya+a|0}; +l.Cf=function(a,b){var c,d,e=this.A;a&=65535;a&4?(c=e.Zb.ya,d=c+e.Zb.Za|0):(c=e.ub,d=e.wc);if(c){c=c+(a&65528)|0;if(d-c|0)return e.A-=15,Bc(this,c,a,b);6>this.id&&t.call(e,b&&3==this.id?10:13,a&65532)}return-1};l.Uk=function(a){var b=this.A;a=b.Ab+(a<<2);var c=b.ga(a);b.W&=-769;return this.load(b.ga(a+2))+c|0};l.Tk=function(a){var b=this.A;a<<=3;var c=b.Ab+a|0;if(7<=(b.xc-c|0))return this.D=!0,a=Bc(this,c,a),-1!==a&&(a+=this.cf),a;t.call(b,13,a|2);return-1};l.Ih=function(a){return this.ya+a|0}; l.Kh=function(a){return this.ya+a|0};l.Hh=function(a,b){return(a>>>0)+b<=this.C?this.ya+a|0:this.wf()};l.zj=function(a,b){return(a>>>0)+b>this.C?this.ya+a|0:this.wf()};l.wf=function(){t.call(this.A,13,0);return-1};l.Jh=function(a,b){return(a>>>0)+b<=this.C?this.ya+a|0:this.xf()};l.Aj=function(a,b){return(a>>>0)+b>this.C?this.ya+a|0:this.xf()};l.xf=function(){t.call(this.A,13,0);return-1}; function Cc(a,b,c,d,e){a.ja=b;a.ya=d;a.Za=e;a.C=(e>>>0)+1;a.lb=c;a.type=c&7936;a.ext=c>>16&192;a.hc=(b&4?a.A.Zb.ya:a.A.ub)+(b&65528)|0;4>a.id&&Ac(a,!0)}function Dc(a,b,c){var d=a.A,e=d.ga(b+2),f=d.ga(b)|(e&255)<<16,d=d.ga(b+4);a.ja=c;a.ya=f;a.Za=d;a.C=(d>>>0)+1;a.lb=e;a.type=e&7936;a.ext=0;a.hc=b;4>a.id&&Ac(a,!0)} function Bc(a,b,c,d){var e=a.A;if(!d&&c===a.B.ja)return a.ja=c,a.ya=a.B.ya,a.Za=a.B.Za,a.C=(a.B.Za>>>0)+1,a.lb=a.B.lb,a.type=a.B.type,a.ext=a.B.ext,a.hc=a.B.hc,a.B.ja=-1,Ac(a,!0,!0,!1),a.ya;a.B.ja=-1;var f=e.ga(b+0),g=e.ga(b+4),h=g&7936,k=e.ga(b+2)|(g&255)<<16,m=e.ga(b+6),p=c&65528;if(80386<=e.ca){var x=f,k=k|(m&65280)<<16,f=f|(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case 1:var r=a.D;a.pe=!1;if(r&&1==c&&a.G.length){var z=a.G[a.cf-1];if(z&&!z())return-1}var E=c&3,J=(g&24576)>>13,z=-1,W,da;p|| @@ -77,13 +77,13 @@ function Fc(a,b,c){var d=a.A,e=a.sb,f=d.ia.ja,g=d.ia.ya;if(!c){if(!(d.ia.type&51 34,d.pa.ja),d.bb(g+36,d.Ba.ja),d.bb(g+38,d.S.ja),d.bb(g+40,d.xa.ja),d.Zb.load(d.ga(h+42)),Nc(d,d.ga(h+16)|(c?16384:0)),d.J=d.ga(h+18),d.G=d.ga(h+20),d.M=d.ga(h+22),d.D=d.ga(h+24),d.K=d.ga(h+28),d.I=d.ga(h+30),d.H=d.ga(h+32),d.pa.load(d.ga(h+34)),d.xa.load(d.ga(h+40)),Pc(d,d.ga(h+14),d.ga(h+36)),b=38,g=26,a.sb>>0)+1)}; -function Ac(a,b,c,d){void 0===c&&(c=!!(a.A.Pa&1));a.yd=!1;if(c)if(a.load=a.Cf,a.Vh=a.Sk,a.Pb=a.Hh,a.Qb=a.Jh,void 0===d&&(d=!!(a.A.W&131072)),d)a.load=a.L,a.Pb=a.I,a.Qb=a.K,a.sb=a.nc=3,a.U=a.Nc=2,a.N=a.sa=65535,a.Za=65535,a.C=a.Za+1,a.Nc=a.U,a.hc=-1,a.pe=!1;else{if(!(a.ja&-4))a.Pb=a.wf,a.Qb=a.xf;else if(a.type&4096){6144==(a.type&6656)&&(a.Pb=a.wf);if(a.type&2048||!(a.type&512))a.Qb=a.xf;1024==(a.type&3072)&&(a.Pb==a.Hh&&(a.Pb=a.zj),a.Qb==a.Jh&&(a.Qb=a.Aj),a.yd=!0);b&&6>a.id&&a.ja&-4&&-1!==a.hc&&(c= -a.hc+5,d=a.A.Jb(c),d&1||a.A.Mc(c,d|1))}b&&(a.sb=a.ja&3,a.nc=(a.lb&24576)>>13,80386>a.A.ca||!(a.ext&64)?(a.U=2,a.N=65535):(a.U=4,a.N=-1),a.Nc=a.U,a.sa=a.N)}else a.load=a.Wh,a.Vh=a.Tk,a.Pb=a.Ih,a.Qb=a.Kh,a.sb=a.nc=0,a.hc=-1,a.pe=!1} +function Ac(a,b,c,d){void 0===c&&(c=!!(a.A.Pa&1));a.yd=!1;if(c)if(a.load=a.Cf,a.Vh=a.Tk,a.Pb=a.Hh,a.Qb=a.Jh,void 0===d&&(d=!!(a.A.W&131072)),d)a.load=a.L,a.Pb=a.I,a.Qb=a.K,a.sb=a.nc=3,a.U=a.Nc=2,a.N=a.sa=65535,a.Za=65535,a.C=a.Za+1,a.Nc=a.U,a.hc=-1,a.pe=!1;else{if(!(a.ja&-4))a.Pb=a.wf,a.Qb=a.xf;else if(a.type&4096){6144==(a.type&6656)&&(a.Pb=a.wf);if(a.type&2048||!(a.type&512))a.Qb=a.xf;1024==(a.type&3072)&&(a.Pb==a.Hh&&(a.Pb=a.zj),a.Qb==a.Jh&&(a.Qb=a.Aj),a.yd=!0);b&&6>a.id&&a.ja&-4&&-1!==a.hc&&(c= +a.hc+5,d=a.A.Jb(c),d&1||a.A.Mc(c,d|1))}b&&(a.sb=a.ja&3,a.nc=(a.lb&24576)>>13,80386>a.A.ca||!(a.ext&64)?(a.U=2,a.N=65535):(a.U=4,a.N=-1),a.Nc=a.U,a.sa=a.N)}else a.load=a.Wh,a.Vh=a.Uk,a.Pb=a.Ih,a.Qb=a.Kh,a.sb=a.nc=0,a.hc=-1,a.pe=!1} function Rc(a){this.ca=a.model||8088;var b=a.stepping;this.pd=this.ca+(b?ca(b,16):0);b=0;switch(this.ca){default:b=4772727;break;case 80286:b=6E6;break;case 80386:b=16E6}hc.call(this,a,b);this.qh=61442;this.od=1792;this.ph=28672;this.ae=4;this.Da=255;this.B=80286<=this.ca?fb:eb;this.ma=Sc;this.th=Tc;this.uh=Uc;this.vh=Vc;if(80186<=this.ca&&(this.ma=Sc.slice(),this.th=Tc.slice(),this.uh=Uc.slice(),this.Da=31,this.ma[15]=Wc,this.ma[96]=Xc,this.ma[97]=Yc,this.ma[98]=Zc,this.ma[99]=Wc,this.ma[100]=Wc, this.ma[101]=Wc,this.ma[102]=Wc,this.ma[103]=Wc,this.ma[104]=$c,this.ma[105]=ad,this.ma[106]=bd,this.ma[107]=cd,this.ma[108]=dd,this.ma[109]=ed,this.ma[110]=fd,this.ma[111]=gd,this.ma[192]=hd,this.ma[193]=id,this.ma[200]=jd,this.ma[201]=kd,this.ma[241]=ld,this.th[7]=md,this.uh[7]=md,80286<=this.ca)){this.qh=2;this.od|=28672;this.ae=0;this.ma[15]=nd;this.Zc=od.slice();for(a=0;a=this.pd&&(this.Zc[166]=xd,this.Zc[167]=yd)}}this.of=[];this.sh=[];this.Vf=0;kc(this);this.ea.Le=this.ea.Hj=!1;this.xh=0;this.vc=this.R=[];this.da=this.vb=this.pb=this.mf=this.Yd=this.Fa=this.oc=0;zd(this)}Qa(Rc,hc); function Bb(a){var b;if(a.R===a.vc){a.R=Array(a.mf);a.pf=new q(null,0,0,5,null,a);sb(a.pf,a.Ia);for(b=0;ba.qf&&(a.rh[a.qf++]=d);a.R[b]=a.pf}a.nf=[]} -function Zb(a,b,c,d){var e=(b&-4194304)>>>20,f=a.vc[(a.dd+e&a.Fa)>>>a.da],g=f.Fd(e);if(!(g&1))return d||Ad.call(a,b,!1,c),a.Zd;if(!(g&4)&&3==a.za)return d||Ad.call(a,b,!0,c),a.Zd;var h=(b&4190208)>>>10,g=a.vc[((g&-4096)+h&a.Fa)>>>a.da],k=g.Fd(h);if(!(k&1))return d||Ad.call(a,b,!1,c),a.Zd;if(!(k&4)&&3==a.za)return d||Ad.call(a,b,!0,c),a.Zd;c=a.vc[((k&-4096)+(b&4095)&a.Fa)>>>a.da];if(d)return c;d=b>>>a.da;k=a.R[d];b=b&-4096;var m;0>>20,f=a.vc[(a.dd+e&a.Fa)>>>a.da],g=f.Fd(e);if(!(g&1))return d||Ad.call(a,b,!1,c),a.Zd;if(!(g&4)&&3==a.za)return d||Ad.call(a,b,!0,c),a.Zd;var h=(b&4190208)>>>10,g=a.vc[((g&-4096)+h&a.Fa)>>>a.da],k=g.Fd(h);if(!(k&1))return d||Ad.call(a,b,!1,c),a.Zd;if(!(k&4)&&3==a.za)return d||Ad.call(a,b,!0,c),a.Zd;c=a.vc[((k&-4096)+(b&4095)&a.Fa)>>>a.da];if(d)return c;d=b>>>a.da;k=a.R[d];b=b&-4096;var m;0>2;b.C=g;b.G=h>>2;db&&Hb&&c.V&&!c.controller&&!c.ge&&!c.he?(b.Ka=c.Ka,b.ud=c.ud,b.V=c.V,Eb(b,gc)):(b.K=c?Xb(32):0,b.S=c?Xb(96):0,Eb(b,ec));sb(b,a.Ia,k);a.R[d]=b;a.nf.push(d);return b}function Bd(a){a.R!==a.vc&&(a.R=a.vc,a.pf=null,a.nf=null,a.Zd=null)}l=Rc.prototype;l.reset=function(){this.ea.Sb&&oc(this);zd(this);kc(this);this.ea.Yc=!1}; function Cd(a,b){var c;switch(b){case 0:c=a.J;break;case 1:c=a.G;break;case 2:c=a.M;break;case 3:c=a.D;break;case 4:c=w(a);break;case 5:c=a.K;break;case 6:c=a.I;break;case 7:c=a.H}return c}function Dd(a,b,c){switch(b){case 0:a.J=c;break;case 1:a.G=c;break;case 2:a.M=c;break;case 3:a.D=c;break;case 4:v(a,c);break;case 5:a.K=c;break;case 6:a.I=c;break;case 7:a.H=c}} function zd(a){a.J=0;a.D=0;a.G=0;a.M=0;a.Nb=0;a.K=0;a.I=0;a.H=0;a.Hb=!1;a.ua=a.Ga=0;a.oa=0;a.wh=0;a.X=0;a.Pa=65520;a.Ab=0;a.xc=1023;a.W=a.Cb=0;a.Hd=a.Kd=a.sd=a.Id=0;a.fc=-1;a.Gc=a.ic=-1;a.Dd=a.ka=-1;a.Ba=new zc(a,1,"CS");a.xa=new zc(a,2,"DS");a.pa=new zc(a,2,"ES");a.S=new zc(a,3,"SS");v(a,0);Ec(a,0);if(80386<=a.ca){switch(a.pd){case 80562:case 80563:a.M=771;break;case 80578:a.M=772;break;case 80594:a.M=773;break;case 80595:case 80596:a.M=776}a.Pa=16;a.Ah=0;a.rd=0;a.dd=0;a.qb=[0,0,0,0,null,null,0, @@ -348,8 +348,8 @@ var be=[function(){this.A-=2+(-1===this.F?0:1);return this.Zb.ja},function(){thi var b=this.Ab;80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.U&&(a|=b<<16);this.Va(this.F+2,b);this.A-=12}return a},function(a){-1===this.F||this.W&131072?t.call(this,6):(this.ub=this.fa(this.F+2)&(this.N|this.N<<8),a&=65535,this.wc=this.ub+a,this.L|=2,this.A-=11);return a},function(a){-1===this.F||this.W&131072?t.call(this,6):(this.Ab=this.fa(this.F+2)&(this.N|this.N<<8),a&=65535,this.xc=this.Ab+a,this.L|=2,this.A-=12);return a},function(){this.A-=2+(-1===this.F?0:1);return this.Pa},R,function(a){this.W& 131072?t.call(this,6):(Be(this,a),this.A-=-1===this.F?3:6,this.L|=2);return a},R],yi=[R,R,R,R,fg,ig,hg,gg]; function S(a){Ia.call(this,"ChipSet",a,S);var b=a.model;b&&!zi[b]&&n("Unrecognized ChipSet model: "+b);this.ca=b&&zi[b]||Ai;this.D=[];b=Bi(a[Ci]);this.D[0]=[b,b];null==b&&(this.Y=[360,360],(b=a.floppies)&&b.length&&(this.Y=b),Di(this,Ei,this.Y.length),Di(this,Fi,a.monitor||(this.ca=Re&&(this.Ea=this.pa=2);this.ba=a.scaleTimers||!1;this.Xa=a.rtcDate;this.Oa=!1;a.sound&&(this.La=this.qa=null,window&&(this.La=window.AudioContext|| -window.webkitAudioContext),this.La&&(this.qa=new this.La));this.reset(!0);ab(this)}Qa(S);var Ai=5150.9,Re=5170,zi={5150:5150,5160:5160,5170:Re,att6300:5160.101,mpc1600:5150.101,z150:5160.15,compaq:5150.102,other:Ai,deskpro386:5180},Ci="sw1",Gi="sw2",Hi={uj:1,ONE:0,Im:64,Gm:128,km:192,lc:192,Zf:6},Ii={Hm:16,dm:32,sm:48,lc:48,Zf:4},Ei=1,Fi=4,T={5150:[{},{}]};T[5150][0][Ei]={lc:192,Oc:{1:0,2:64,3:128,4:192},gd:"Number of Floppy Drives"};T[5150][0][3]={lc:2,Oc:{0:0,1:2},gd:"Coprocessor"}; -T[5150][0][Fi]={lc:48,Oc:{0:0,1:16,2:32,3:48,none:0,tv:16,color:32,mono:48,ega:0,vga:0},gd:"Monitor Type"};T[5150][0][5]={lc:12,Oc:{16:0,32:4,48:8,64:12},gd:"Base Memory (16Kb Increments)"};T[5150][1][6]={lc:31,Oc:{0:0,32:1,64:2,96:3,128:4,160:5,192:6,224:7,256:8,288:9,320:10,352:11,384:12,416:13,448:14,480:15,512:16,544:17,576:18},gd:"Expansion Memory (32Kb Increments)"};T[5160]=[{},{}];T[5160][0][Ei]=T[5150][0][Ei];T[5160][0][3]=T[5150][0][3];T[5160][0][Fi]=T[5150][0][Fi]; +window.webkitAudioContext),this.La&&(this.qa=new this.La));this.reset(!0);ab(this)}Qa(S);var Ai=5150.9,Re=5170,zi={5150:5150,5160:5160,5170:Re,att6300:5160.101,mpc1600:5150.101,z150:5160.15,compaq:5150.102,other:Ai,deskpro386:5180},Ci="sw1",Gi="sw2",Hi={uj:1,ONE:0,Jm:64,Hm:128,lm:192,lc:192,Zf:6},Ii={Im:16,em:32,tm:48,lc:48,Zf:4},Ei=1,Fi=4,T={5150:[{},{}]};T[5150][0][Ei]={lc:192,Oc:{1:0,2:64,3:128,4:192},gd:"Number of Floppy Drives"};T[5150][0][3]={lc:2,Oc:{0:0,1:2},gd:"Coprocessor"}; +T[5150][0][Fi]={lc:48,Oc:{0:0,1:16,2:32,3:48,none:0,tv:16,color:32,cga:32,mda:48,mono:48,ega:0,vga:0},gd:"Monitor Type"};T[5150][0][5]={lc:12,Oc:{16:0,32:4,48:8,64:12},gd:"Base Memory (16Kb Increments)"};T[5150][1][6]={lc:31,Oc:{0:0,32:1,64:2,96:3,128:4,160:5,192:6,224:7,256:8,288:9,320:10,352:11,384:12,416:13,448:14,480:15,512:16,544:17,576:18},gd:"Expansion Memory (32Kb Increments)"};T[5160]=[{},{}];T[5160][0][Ei]=T[5150][0][Ei];T[5160][0][3]=T[5150][0][3];T[5160][0][Fi]=T[5150][0][Fi]; T[5160][0][5]={lc:12,Oc:{64:0,128:4,192:8,256:12},gd:"Base Memory (64Kb Increments)"};T[5160][1][6]=T[5150][1][6];T[5160.101]=[{},{}];T[5160.101][0][5]={lc:143,Oc:{128:1,256:130,512:8,640:141},gd:"Base Memory (128Kb Increments)"};T[5160.101][0][3]={lc:16,Oc:{0:0,1:16},gd:"Coprocessor"};T[5160.101][1][2]={lc:1,Oc:{0:0,1:1},gd:"Floppy Type"};T[5160.101][1][Ei]=T[5150][0][Ei];T[5160.101][1][Fi]=T[5150][0][Fi];l=S.prototype; l.zb=function(a,b,c){switch(b){case Ci:return this.la[b]=c,Ji(this,0,b),!0;case Gi:if(5150==(this.ca|0)||5160.101==this.ca)return this.la[b]=c,Ji(this,1,b),!0;break;case "swdesc":return this.la[b]=c,!0}return!1}; l.pc=function(a,b,c,d){this.ha=b;this.A=c;this.Ia=d;this.aa=a;this.qd=kb(a,"FPU");Di(this,3,this.qd?1:0,!0);this.C=kb(a,"Keyboard");this.Ga=c.T.ad/1193181;Nb(b,this,Ki);Pb(b,this,Li);this.ca=a;a++)this.B[a]=0;for(a=14;46>a;a++)void 0===this.B[a]&&(this.B[a]=0);a=0|+Zi(this,Fi,void 0)<c;c++)b+=a.B[c];a.B[47]=b&255;a.B[46]=b>>8} -l.save=function(){var a=new ce(this);C(a,0,[this.D]);for(var b=[],c=0;c=Re&&(C(a,5,[this.H,this.S,this.R,this.ua,this.X,this.va]),C(a,6,[this.I[7],this.I,this.da,this.B,this.ra,this.ia]));return a.data()}; l.restore=function(a){var b,c;b=a[0];Array.isArray(b[0])?this.D=b[0]:(this.D[0][0]=b[0],this.D[1][0]=b[1]&15,this.D[0][1]=b[2],this.D[1][1]=b[3]&15);Ui(this);b=a[1];for(c=0;c=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
'+f+"
\n"}e.innerHTML=d;jj(a,b,c,!0)}function kj(a,b,c){if(b=(a=T[a.ca|0])&&a[b])for(var d in b)if(a=b[d],a.lc&1<d.hb[0]&&(d.hb[0]=255,d.hb[1]--,0>d.hb[1]&&(d.hb[1]=255)));return e}function qj(a,b,c,d){a=a.G[b];c=a.$b[c];c.hb[a.Ib]=c.jc[a.Ib]=d;a.Ib^=1} -function rj(a,b){var c=a.G[b],d=c.Db|1;c.Db&=-16;return d}function wj(a,b,c){a=a.G[b];b=c&3;a.Db=a.Db&~(16<>2].$b[b&3],c,d,e)} +function rj(a,b){var c=a.G[b],d=c.Db|1;c.Db&=-16;return d}function wj(a,b,c){a=a.G[b];b=c&3;a.Db=a.Db&~(16<>2].$b[b&3],c,d,e)} function yj(a,b,c){b=a.G[b>>2].$b[b&3];b.yf&&b.kg&&b.Mf?(c&&(b.done=c),b.Qd||Dj(a,b,!0)):c&&c(!0)}function Dj(a,b,c){c&&(b.count=b.hb[1]<<8|b.hb[0],b.type=b.mode&12,b.Rh=b.Yc=!1);for(var d=!1;0<=b.count&&(c=b.tf<<16|b.gb[1]<<8|b.gb[0],4==b.type?(d=!0,function(c){b.kg.call(b.yf,b.Mf,-1,function(f,g){0>f&&(b.Rh||(b.Rh=!0),f=255);b.Qd||a.ha.Mc(c,f);(d=g)&&setTimeout(function(){Ej(b)||Dj(a,b)},0)})}(c)):8==b.type?(c=a.ha.Jb(c),0>b.kg.call(b.yf,b.Mf,c)&&(b.Yc=!0)):0!=b.type&&(b.Yc=!0)),!d&&!Ej(b););} function Ej(a){if(!a.Yc&&0<=--a.count&&(a.mode&32?(a.gb[0]--,0>a.gb[0]&&(a.gb[0]=255,a.gb[1]--,0>a.gb[1]&&(a.gb[1]=255))):(a.gb[0]++,255f&&(d.ld=e,f=0);var g=Nj(a,b),h=xc(a,b)-f;0==d.mode?(0>=h&&(h=0),h||(d.Tc=!0,d.Od=!1,b||Te(a,0))):4==d.mode?(d.Tc=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.Ec[0]=h&255,d.Ec[1]=h>>8&255,d.ld=e,!b&&d.Tc&&Te(a,0))):6==d.mode&&(h-=f,0>=h&&(d.Tc=!d.Tc,h=g+h,0>=h&&(h=g),d.Ec[0]=h&255,d.Ec[1]=h>>8&255,d.ld=e,!b&&d.Tc&&Te(a,0)));d.hb[0]=h&255;d.hb[1]=h>>8&255;c&&(a.ld=0)}return d} function wc(a,b){for(var c=0;c=Re){var c=a.A.T.ad,d=tc(a.A,a.ba);null==a.Fa&&(a.ra=tc(a.A,a.ba),a.Ta=1024,a.Fa=Math.floor(a.A.T.ad/a.Ta),cj(a));d>=a.ia&&(a.B[12]|=64,a.B[11]&64&&(a.B[12]|=128,Te(a,8)),a.ia=d+a.Fa);a.B[0]==a.B[1]&&a.B[2]==a.B[3]&&a.B[4]==a.B[5]&&(a.B[12]|=32,a.B[11]&32&&(a.B[12]|=128,Te(a,8)));var e=d-a.ra,f=Math.floor(e/c);if(f&&!(a.B[11]&128)){for(;f--;)if(60<=++a.B[0]&&(a.B[0]=0,60<=++a.B[2]&&(a.B[2]=0,24<=++a.B[4]))){a.B[4]=0;a.B[6]=a.B[6]%7+1; -var g;g=a.B[9];var h=ma[a.B[8]-1];28==h&&0===g%4&&(g%100||0===g%400)&&h++;g=h;++a.B[7]>g&&(a.B[7]=1,12<++a.B[8]&&(a.B[8]=1,a.B[9]=(a.B[9]+1)%100))}a.B[12]|=16;a.B[11]&16&&(a.B[12]|=128,Te(a,8))}a.ra=d-e%c}}l=S.prototype;l.Ak=function(){var a=this.Da;this.oa&16&&(this.P&128?a=this.D[0][1]:this.C&&(a=Qj(this.C)));return a};l.Nl=function(a,b){this.Da=b};l.Bk=function(){return this.P};l.Ol=function(a,b){Rj(this,b)}; -function Rj(a,b){var c=!!(b&2),d=!!(a.P&2);a.P=b;a.C&&Sj(a.C,!(b&128),!!(b&64));c!=d&&vc(a,c)}l.Ck=function(){var a=0,a=5150==(this.ca|0)?this.P&4?a|this.D[1][1]&15:a|this.D[1][1]>>4&1:this.P&8?a|this.D[0][1]>>4:a|this.D[0][1]&15;this.P&1&&Lj(this,2).Tc&&(a=this.P&2?a|32:a|16);return a};l.Pl=function(a,b){this.Ja=b};l.Dk=function(){return this.oa};l.Ql=function(a,b){this.oa=b};l.Mj=function(){var a=this.C?Qj(this.C):0;this.ka&=-2;return a};l.Zk=function(){};l.Lj=function(){return this.P}; -l.Yk=function(a,b){Rj(this,b)};l.Nj=function(){return this.ka};l.Oj=function(){var a=this.ua;this.H&=-258;this.C&&Tj(this.C);return a};l.al=function(a,b){if(this.H&8)switch(this.S){case 96:Uj(this,b);break;case 209:Vj(this,b);break;default:if(Uj(this,this.R&-17),this.C){var c=this.C,d=b,e=-1;switch(c.G||d){case 255:e=250;c.Ob=[];Wj(c,170);break;case 243:c.G&&(d=0);Wj(c,250);c.G=d;break;case 237:c.G&&(d=0),Wj(c,250),c.G=d}Xj(this,e)}}this.S=b;this.H&=-9}; -l.Pj=function(){return this.P&-209|(tc(this.A)&64?16:0)};l.bl=function(a,b){Rj(this,b)};l.Qj=function(){var a=this.H&255;this.H&256&&(this.H|=1,this.H&=-257);return a}; -l.$k=function(a,b){this.S=b;this.H|=8;var c=0;240<=this.S&&(c=this.S^15,this.S=240);switch(this.S){case 32:Xj(this,this.R);break;case 173:Uj(this,this.R|16);break;case 174:Uj(this,this.R&-17);this.C&&Tj(this.C);break;case 170:this.C&&(this.C.Ob=[]);Uj(this,this.R|16);Xj(this,85);Vj(this,3);break;case 171:Xj(this,0);break;case 192:Xj(this,this.X);break;case 208:Xj(this,this.va);break;case 224:Xj(this,this.R&16?0:1);break;case 240:c&1&&zd(this.A)}}; -function Uj(a,b){a.R=b;a.H=a.H&-5|b&4;a.C&&Sj(a.C,!!(b&8),!(b&16))}function Xj(a,b,c){0<=b&&(a.ua=b,c?a.H|=1:(a.H&=-2,a.H|=256))}function Vj(a,b){a.va=b;xb(a.ha,!!(b&2));b&1||zd(a.A)}function Yj(a,b){a.cag&&(a.B[7]=1,12<++a.B[8]&&(a.B[8]=1,a.B[9]=(a.B[9]+1)%100))}a.B[12]|=16;a.B[11]&16&&(a.B[12]|=128,Te(a,8))}a.ra=d-e%c}}l=S.prototype;l.Bk=function(){var a=this.Da;this.oa&16&&(this.P&128?a=this.D[0][1]:this.C&&(a=Qj(this.C)));return a};l.Ol=function(a,b){this.Da=b};l.Ck=function(){return this.P};l.Pl=function(a,b){Rj(this,b)}; +function Rj(a,b){var c=!!(b&2),d=!!(a.P&2);a.P=b;a.C&&Sj(a.C,!(b&128),!!(b&64));c!=d&&vc(a,c)}l.Dk=function(){var a=0,a=5150==(this.ca|0)?this.P&4?a|this.D[1][1]&15:a|this.D[1][1]>>4&1:this.P&8?a|this.D[0][1]>>4:a|this.D[0][1]&15;this.P&1&&Lj(this,2).Tc&&(a=this.P&2?a|32:a|16);return a};l.Ql=function(a,b){this.Ja=b};l.Ek=function(){return this.oa};l.Rl=function(a,b){this.oa=b};l.Mj=function(){var a=this.C?Qj(this.C):0;this.ka&=-2;return a};l.$k=function(){};l.Lj=function(){return this.P}; +l.Zk=function(a,b){Rj(this,b)};l.Nj=function(){return this.ka};l.Oj=function(){var a=this.ua;this.H&=-258;this.C&&Tj(this.C);return a};l.bl=function(a,b){if(this.H&8)switch(this.S){case 96:Uj(this,b);break;case 209:Vj(this,b);break;default:if(Uj(this,this.R&-17),this.C){var c=this.C,d=b,e=-1;switch(c.G||d){case 255:e=250;c.Ob=[];Wj(c,170);break;case 243:c.G&&(d=0);Wj(c,250);c.G=d;break;case 237:c.G&&(d=0),Wj(c,250),c.G=d}Xj(this,e)}}this.S=b;this.H&=-9}; +l.Pj=function(){return this.P&-209|(tc(this.A)&64?16:0)};l.cl=function(a,b){Rj(this,b)};l.Qj=function(){var a=this.H&255;this.H&256&&(this.H|=1,this.H&=-257);return a}; +l.al=function(a,b){this.S=b;this.H|=8;var c=0;240<=this.S&&(c=this.S^15,this.S=240);switch(this.S){case 32:Xj(this,this.R);break;case 173:Uj(this,this.R|16);break;case 174:Uj(this,this.R&-17);this.C&&Tj(this.C);break;case 170:this.C&&(this.C.Ob=[]);Uj(this,this.R|16);Xj(this,85);Vj(this,3);break;case 171:Xj(this,0);break;case 192:Xj(this,this.X);break;case 208:Xj(this,this.va);break;case 224:Xj(this,this.R&16?0:1);break;case 240:c&1&&zd(this.A)}}; +function Uj(a,b){a.R=b;a.H=a.H&-5|b&4;a.C&&Sj(a.C,!!(b&8),!(b&16))}function Xj(a,b,c){0<=b&&(a.ua=b,c?a.H|=1:(a.H&=-2,a.H|=256))}function Vj(a,b){a.va=b;xb(a.ha,!!(b&2));b&1||zd(a.A)}function Yj(a,b){a.ca=c)if(d=this.B[c],10>c){var e=!1;4!=c&&5!=c||this.B[11]&2||(12>d?d=d?d:12:d=(d-=12)?d+128:140,e=!0);this.B[11]&4||(e&&128=c){if(e=b,10>c){var f=!1;this.B[11]&4||(e=10*(e>>4)+(e&15),f=!0);if(4==c||5==c)f&&23=e?e=12==e?0:e:(e-=116,e=24==e?12:e))}}else e=b;this.B[c]=e;11==c&&d&64&&b&64&&cj(this)};l.dj=function(a,b){this.ma=b};l.Al=function(){};l.Bl=function(){this.qd&&Ne(this.qd)}; +l.rl=function(a,b){var c=this.da&63,d=b^this.B[c],e;if(13>=c){if(e=b,10>c){var f=!1;this.B[11]&4||(e=10*(e>>4)+(e&15),f=!0);if(4==c||5==c)f&&23=e?e=12==e?0:e:(e-=116,e=24==e?12:e))}}else e=b;this.B[c]=e;11==c&&d&64&&b&64&&cj(this)};l.dj=function(a,b){this.ma=b};l.Bl=function(){};l.Cl=function(){this.qd&&Ne(this.qd)}; function vc(a,b){if(a.qa)try{void 0!==b?a.Oa=b:b=a.Oa&&a.A&&a.A.ea.Sb;var c=Math.round(1193181/Nj(a,2));if(20>c||2E4>>4,0,this.I,this.D,this.K),delete this.K);return!0};ak.prototype.Ub=function(){return!0}; @@ -410,8 +410,8 @@ l.reset=function(){if(!this.C&&!this.G&&this.P){var a=1024*Yi(this.P);this.B&&a! 1]=c>>8;bj(a)}}else n("No RAM allocated")};l.save=function(){var a=new ce(this);this.controller&&C(a,0,this.controller.save());return a.data()};l.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function gk(a){this.G=a;this.C=ik;this.D=jk;this.B=kk;this.A=null}var hk=-2134900736,ik=65535,jk=2575,kk=2,lk=[null,0],mk=[function(a){return this.controller.Jb(a)},null,null,function(a,b){this.controller.Mc(a,b)},null,null];l=gk.prototype;l.save=function(){return[this.C,this.B]}; l.restore=function(a){this.Mc(0,a[0]&255);this.Mc(2,a[1]&255);return!0};l.Jb=function(a){var b=255;2>a?b=a&1?this.D>>8:this.D&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b};l.Mc=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){var c=this.G.ha;if(b&1)this.A&&(Cb(c,917504,131072,this.A),this.A=null);else{this.A||(this.A=Db(c,917504,131072));var d=Db(c,16646144,131072);Cb(c,917504,131072,d,b&2?1:Gb)}this.C=this.C&-256|b}};l.Th=function(){return lk};l.lg=function(){return mk}; Ea(function(){for(var a=Za(document,"pcjs","ram"),b=0;b":62,"?":63,"@":64,am:65,bm:66,cm:67,hm:68,E:69,im:70,lm:71,mm:72,nm:73,om:74,pm:75,qm:76,rm:77,tm:78,um:79,vm:80,Q:81,wm:82,Am:83,Fm:84,Jm:85,Km:86,Lm:87,Nm:88,Om:89,Pm:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Qm:97,Rm:98,Tm:99,d:100,e:101,Um:102,Vm:103,Wm:104, -Xm:105,Ym:106,k:107,Zm:108,$m:109,n:110,bn:111,p:112,q:113,r:114,cn:115,t:116,dn:117,en:118,fn:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126},qk={};qk[186]=U[";"];qk[187]=U["="];qk[188]=U[","];qk[189]=U["-"];qk[190]=U["."];qk[191]=U["/"];qk[192]=U["`"];qk[219]=U["["];qk[220]=U["\\"];qk[221]=U["]"];qk[222]=U["'"];qk[173]=U["-"];var V={};V[U["1"]]=U["!"];V[U["2"]]=U["@"];V[U["3"]]=U["#"];V[U["4"]]=U.$;V[U["5"]]=U["%"];V[U["6"]]=U["^"];V[U["7"]]=U["&"];V[U["8"]]=U["*"];V[U["9"]]=U["("]; +var pk=["US83","US84","US101"],U={fm:1,gm:3,hm:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,bm:65,cm:66,dm:67,im:68,E:69,jm:70,mm:71,nm:72,om:73,pm:74,qm:75,rm:76,sm:77,um:78,vm:79,wm:80,Q:81,xm:82,Bm:83,Gm:84,Km:85,Lm:86,Mm:87,Om:88,Pm:89,Qm:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Rm:97,Sm:98,Um:99,d:100,e:101,Vm:102,Wm:103,Xm:104, +Ym:105,Zm:106,k:107,$m:108,an:109,n:110,cn:111,p:112,q:113,r:114,dn:115,t:116,en:117,fn:118,gn:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126},qk={};qk[186]=U[";"];qk[187]=U["="];qk[188]=U[","];qk[189]=U["-"];qk[190]=U["."];qk[191]=U["/"];qk[192]=U["`"];qk[219]=U["["];qk[220]=U["\\"];qk[221]=U["]"];qk[222]=U["'"];qk[173]=U["-"];var V={};V[U["1"]]=U["!"];V[U["2"]]=U["@"];V[U["3"]]=U["#"];V[U["4"]]=U.$;V[U["5"]]=U["%"];V[U["6"]]=U["^"];V[U["7"]]=U["&"];V[U["8"]]=U["*"];V[U["9"]]=U["("]; V[U["0"]]=U[")"];V[186]=U[":"];V[187]=U["+"];V[188]=U["<"];V[189]=U._;V[190]=U[">"];V[191]=U["?"];V[192]=U["~"];V[219]=U["{"];V[220]=U["|"];V[221]=U["}"];V[222]=U['"'];V[173]=U._;V[61]=U["+"];V[59]=U[":"]; var rk={3016:1,1016:2,1017:8,1018:32,1091:128,1093:64,1224:128,1020:512,1144:1024,1145:2048},sk={TAB:1009,ESC:1027,F1:1112,F2:1113,F3:1114,F4:1115,F5:1116,F6:1117,F7:1118,F8:1119,F9:1120,F10:1121,LEFT:1037,UP:1038,RIGHT:1039,DOWN:1040,SYSREQ:4027,CTRL_C:4003,CTRL_BREAK:4008,CTRL_ALT_DEL:4046,CTRL_ALT_INS:4045,CTRL_ALT_ENTER:4013},tk={esc:1027,1:U["1"],2:U["2"],3:U["3"],4:U["4"],5:U["5"],6:U["6"],7:U["7"],8:U["8"],9:U["9"],0:U["0"],"-":U["-"],"=":U["="],bs:1008,tab:1009,q:81,w:87,e:69,r:82,t:84,y:89, u:85,i:73,o:79,p:80,"[":U["["],"]":U["]"],enter:13,ctrl:1017,a:65,s:83,d:68,f:70,g:71,h:72,j:74,k:75,l:76,";":U[";"],quote:U["'"],"`":U["`"],shift:1016,"\\":U["\\"],z:90,x:88,c:67,v:86,b:66,n:78,m:77,",":U[","],".":U["."],"/":U["/"],"right-shift":3016,prtsc:1044,alt:1018,space:1032,"caps-lock":1020,f1:1112,f2:1113,f3:1114,f4:1115,f5:1116,f6:1117,f7:1118,f8:1119,f9:1120,f10:1121,"num-lock":1144,"scroll-lock":1145,"num-home":1036,"num-up":1038,"num-pgup":1033,"num-sub":1109,"num-left":1037,"num-center":1101, @@ -442,7 +442,7 @@ var Mk=[[0,0,0,255],[127,192,127,255],[127,192,127,255],[127,255,127,255],[127,2 16777215,-16777216,-16776961,-16711936,-16711681,-65536,-65281,-256,-1],Tk=[0];Tk[128]=1;Tk[32768]=2;Tk[32896]=3;Tk[8388608]=4;Tk[8388736]=5;Tk[8421376]=6;Tk[8421504]=7;Tk[-2147483648]=8;Tk[-2147483520]=9;Tk[-2147450880]=10;Tk[-2147450752]=11;Tk[-2139095040]=12;Tk[-2139094912]=13;Tk[-2139062272]=14;Tk[-2139062144]=15; function Uk(a,b,c,d){if(void 0!==b&&(!c||c.length)){this.video=a;var e=Vk[b],f=a.ma||e[5];if(!c||6>c.length)c=[!1,0,null,null,0,Array(5>b?Wk:Xk)];this.Ra=b;this.cb=e[2];this.Fb=e[3];this.Wc=d||e[4];65536<=this.Wc&&720896<=this.cb&&(this.Fb=Math.min(this.Wc>>2,32768));this.cc=c[0];this.Lc=c[1];this.ff=c[2];this.Z=c[3];this.sc=c[4]&255;this.Qf=c[4]>>8&255;this.ab=c[5];this.pg=Wk;if(5<=b){this.pg=Xk;b=c[6];void 0===b&&(b=[!1,0,Array(20),0,3==f?0:1,0,0,Array(5),0,0,0,Array(9),0,[this.cb,this.Fb,this.Wc], Array(this.Wc>>2),-2147478512,0,-1,0,-1,0,-1,0,0,0,0,1,255,0,0,0,Array(256)]);this.Ke=b[0];this.Ud=b[1];this.Kc=b[2];this.kh=b[3];this.gf=b[4];this.Sf=b[5];this.Ce=b[6];this.Be=b[7];this.ej=b[8];this.fj=b[9];this.Ae=b[10];this.Gd=b[11];this.ob=b[12];d=b[13];"number"==typeof d&&(d=[this.cb,this.Fb,d]);this.cb=d[0];this.Fb=d[1];d=this.Wc>>2;if((this.td=b[14])&&this.td.length>this.controller.fh&255};Zk[17408]=function(a){return(this.controller.ob=this.V[(a&-4)+this.H])>>((a&3)<<3)&255};Zk[5120]=function(a){a+=this.H;var b=this.controller.ob=this.V[a&-2];return(a&1?b>>8:b)&255}; Zk[1280]=function(a){a+=this.H;a=this.controller.ob=this.V[a];for(var b=this.controller.rg,c=this.controller.qg&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};Zk[0]=function(a,b){var c=a+this.H,d;d=(b|b<<8|b<<16|b<<24)&this.controller.nd|this.controller.Cd;d=d&this.controller.tb|this.controller.ob&~this.controller.tb;d=d&this.controller.$a|this.V[c]&~this.controller.$a;this.V[c]!=d&&(this.V[c]=d,this.Ha=!0)}; Zk[32]=function(a,b){var c=a+this.H;b=b>>this.controller.Hc|b<<8-this.controller.Hc&255;var d;d=(b|b<<8|b<<16|b<<24)&this.controller.nd|this.controller.Cd;d=d&this.controller.tb|this.controller.ob&~this.controller.tb;d=d&this.controller.$a|this.V[c]&~this.controller.$a;this.V[c]!=d&&(this.V[c]=d,this.Ha=!0)}; @@ -490,31 +490,31 @@ function kl(a,b){if(a.ea.Rb){var c=!1,d=a.D;d&&(d!==a.B?d.Lc&8&&(c=!0):d.Ud&32&& a.S[d]=p,f++),c+=2,d++;a.qa=!0;f&&a.Ga&&a.X.drawImage(a.Fa,0,0,a.pb,a.qb,a.yc,a.zc,a.ic,a.mc);wl(a)}}else if(a.fc){for(var g=k,z,k=c,d=a.za=0,f=a.Hb,e=16==f?65536:196608,h=16==f?1:2,m=sl(a,h),x=p=0,r=a.H,E=0,J=a.L,W=0;k>8|(z&255)<<8;var da=e,ua=16;p>=h))>>(ua-=h);vl(a.Oa,p++,x,m[qd])}p>E&&(E=p);x=W&&(W=x+1)}k+=2;d++;if(p>=a.H){p=0;x+=2;if(x>a.L)break;x==a.L&&(x=1,k=c+a.fc)}}a.qa= !0;ra.H?a.Ta-a.H-z>>3:0;c>=8;m>r&&(r=m);p=J&&(J=p+1)}c+=W;if(m>=a.H){m=0;if(++p>a.L)break;c+=da}}z||(a.qa=!0);xa.H?a.Ta-a.H-J>>3:0;cda&&(ua=da)):(z<<=J,ua-=J,a.qa=!1):(a.qa&&z===a.S[d]?(h+=ua,ua=0):a.S[d]=z,d++);if(ua){hx&&(x=h);m=E&&(E=m+1)}if(h>=a.H){h=0;if(++m>a.L)break;c+=W}}J||(a.qa=!0);pd&&(b.wg=d,d=-d|0);d%b.sg>b.Vk&&(c|=1);d%b.vg>b.Xk&&(c|=9);b.gh=d/b.vg|0;return c}l.wk=function(){var a=this.ba,b;a.cc&&(b=a.sc);return b};l.Kl=function(a,b){var c=this.ba;c.Qf=c.sc;c.sc=b&31};l.vk=function(){return El(this.ba)};l.Jl=function(a,b){Fl(this,this.ba,b)};l.xk=function(){return this.ba.Lc};l.Ll=function(a,b){this.ba.Lc=b;ql(this,!1)};l.yk=function(){return Gl(this,this.ba)}; +r,x-p,E-r),a.X.drawImage(a.Fa,0,0,a.H,a.L,0,0,a.da,a.pa))}}}}function Dl(a,b){var c=0,d=tc(a.A)-b.wg;0>d&&(b.wg=d,d=-d|0);d%b.sg>b.Wk&&(c|=1);d%b.vg>b.Yk&&(c|=9);b.gh=d/b.vg|0;return c}l.xk=function(){var a=this.ba,b;a.cc&&(b=a.sc);return b};l.Ll=function(a,b){var c=this.ba;c.Qf=c.sc;c.sc=b&31};l.wk=function(){return El(this.ba)};l.Kl=function(a,b){Fl(this,this.ba,b)};l.yk=function(){return this.ba.Lc};l.Ml=function(a,b){this.ba.Lc=b;ql(this,!1)};l.zk=function(){return Gl(this,this.ba)}; l.cj=function(a,b){this.B.Sf=this.B.Sf&-4|b&3};l.Vj=function(){return this.B.Ud};l.vj=function(){return this.B.Kc[this.B.Ud&31]};l.bj=function(a,b){var c=this.B,d=c.Ud&32;if(c.Ke){c.Ke=!1;var e=c.Ud&31;if(16<=e||!d)c.Kc[e]=b,Bl(this,!1)}else c.Ud=b,c.Ke=!0,b&32&&!d&&ol(this,!0)&&kl(this,!0),d=(c.ab[12]<<8)+c.ab[13]|0,c.ed!=d&&(c.ed=d,Bl(this)),c.xe=0}; -l.Ik=function(){var a=0;if(5==this.Ra)a=3-((this.B.gf&12)>>2),a=(this.Bb&1<>this.B.Bc&63;this.B.Bc+=6;12>2),a=(this.Bb&1<>this.B.Bc&63;this.B.Bc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=(window?window.navigator.userAgent:"").indexOf("MSIE")&&(c.onresize=function(a, b,c,d){return function(){b.style.height=(a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());c.appendChild(e);var f=document.createElement("textarea");ya("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"));c.appendChild(f);var g=e.getContext("2d"),d=new Y(d,e,g,f,c);Ya(d,c)}}); function Hl(a){this.I=a.adapter;switch(this.I){case 1:this.G=956;this.D=7;break;case 2:this.G=888;this.D=7;break;case 3:this.G=632;this.D=5;break;default:n("Unrecognized parallel adapter #"+this.I);return}this.B=this.C=null;Ia.call(this,"ParallelPort",a,Hl);a=a.binding;"console"==a?this.C="":Xa(this,a,Il)}Qa(Hl);var Il="buffer";l=Hl.prototype;l.zb=function(a,b,c){switch(b){case Il:return this.la[b]=this.B=c,!0}return!1}; l.pc=function(a,b,c,d){this.ha=b;this.A=c;this.Ia=d;this.P=kb(a,"ChipSet");Nb(b,this,Jl,this.G);Pb(b,this,Kl,this.G);ab(this)};l.Vb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Ub=function(a){return a?this.save():!0};l.reset=function(){Ll(this)};l.save=function(){var a=new ce(this),b=0,c=[];c[b++]=this.H;c[b++]=this.Db;c[b]=this.Ie;C(a,0,c);return a.data()};l.restore=function(a){return Ll(this,a[0])}; -function Ll(a,b){var c=0;void 0===b&&(b=[0,0,0]);a.H=b[c++];a.Db=b[c++];a.Ie=b[c];return!0}l.jk=function(){return this.H};l.Hk=function(){return this.Db};l.fk=function(){return this.Ie}; -l.wl=function(a,b){this.H=b;this.Db|=64;var c;if(this.B)8==b?this.B.value=this.B.value.slice(0,-1):(this.B.value+=String.fromCharCode(b),this.B.scrollTop=this.B.scrollHeight),c=!0;else if(null!=this.C){if(10==b||1024<=this.C.length)this.rc(this.C),this.C="";10!=b&&(this.C+=String.fromCharCode(b));c=!0}else c=!1;c&&(this.Db&=-65);Ml(this)};l.rl=function(a,b){this.Ie=b;Ml(this)};function Ml(a){a.P&&a.D&&(a.Ie&16&&!(a.Db&64)?Te(a.P,a.D):Se(a.P,a.D))} -var Jl={0:Hl.prototype.jk,1:Hl.prototype.Hk,2:Hl.prototype.fk},Kl={0:Hl.prototype.wl,2:Hl.prototype.rl};Ea(function(){for(var a=Za(document,"pcjs","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64>8:this.X};l.rk=function(){return this.G};l.sk=function(){return this.I};l.uk=function(){return this.C};l.tk=function(){return this.B};l.zk=function(){return this.ia}; -l.Tl=function(a,b){if(this.I&128)this.R=this.R&-256|b;else{this.ka=b;this.B&=-97;var c;if(this.D){if(13==b)this.L=0;else if(8==b)this.D.value=this.D.value.slice(0,-1),0>8:this.X};l.sk=function(){return this.G};l.tk=function(){return this.I};l.vk=function(){return this.C};l.uk=function(){return this.B};l.Ak=function(){return this.ia}; +l.Ul=function(a,b){if(this.I&128)this.R=this.R&-256|b;else{this.ka=b;this.B&=-97;var c;if(this.D){if(13==b)this.L=0;else if(8==b)this.D.value=this.D.value.slice(0,-1),0b&&-2!=b&&this.controller.Ca("Unable to restore disk '"+this.B+": "+c);return b}; l.toJSON=function(){var a;a=0;for(var b;b=im(this,a++);)pm(b);a=JSON.stringify(this.A,function(a,b){return"file"==a?void 0:b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; function pm(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}function qm(a){Ia.call(this,"FDC",a,qm);this.dmaRead=this.pj;this.dmaWrite=this.qj;this.dmaFormat=this.Cj;this.K=a.autoMount||null;this.C=[];this.X=!ya("Mobi")&&window&&"FileReader"in window}Qa(qm);aa={}; -var rm={3:{jd:3,xd:0,name:aa.Em},4:{jd:2,xd:1,name:aa.Cm},5:{jd:9,xd:7,name:aa.Mm},6:{jd:9,xd:7,name:aa.xm},7:{jd:2,xd:0,name:aa.zm},8:{jd:1,xd:2,name:aa.Dm},10:{jd:2,xd:7,name:aa.ym},13:{jd:6,xd:7,name:aa.jm},15:{jd:3,xd:0,name:aa.Bm}};l=qm.prototype; +var rm={3:{jd:3,xd:0,name:aa.Fm},4:{jd:2,xd:1,name:aa.Dm},5:{jd:9,xd:7,name:aa.Nm},6:{jd:9,xd:7,name:aa.ym},7:{jd:2,xd:0,name:aa.Am},8:{jd:1,xd:2,name:aa.Em},10:{jd:2,xd:7,name:aa.zm},13:{jd:6,xd:7,name:aa.km},15:{jd:3,xd:0,name:aa.Cm}};l=qm.prototype; l.zb=function(a,b,c){var d=this;switch(b){case "listDisks":return this.la[b]=c,c.onchange=function(){var a=d.la.descDisk,b=c.options[c.selectedIndex];if(a&&b){var g={};if(b=b.getAttribute("data-value"))try{g=eval("("+b+")")}catch(h){n("FDC option error: "+h.message)}b=g.desc;void 0===b&&(b="");g=g.href;void 0!==g&&(b=''+b+"");a.innerHTML=b}},!0;case "descDisk":case "listDrives":return this.la[b]=c,c.onchange=function(){var a=ca(c.value,10);null!=a&&sm(d,a)},!0; case "loadDrive":return this.la[b]=c,c.onclick=function(){var a=d.la.listDisks;a&&tm(d,a.options[a.selectedIndex].text,a.value)},!0;case "saveDrive":if(!this.X){c.parentNode.removeChild(c);break}this.la[b]=c;c.onclick=function(){var a=d.la.listDrives;if(a&&a.options&&d.B)if(a=ca(a.value,10),a=d.B[a])if(a.ta){for(var b=a.ta,c="",h=0,k;k=im(b,h++);)for(var m=0,p=k.length;ma.ib||f[1]>a.jb)&&(this.Ca('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Qa)),b=null);b?(a.ta=b,a.hj=c,a.Vd=d,Cm(this,c,d,b),f=b.info(),this.L|=128,this.Ca('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Qa),a.Nd||e),a.Hf=f[0],a.Ue=f[1],a.Ve=f[2],this.aa&&uc(this.aa)):a.me=!1;a.Nd&&(a.Nd=!1,--this.R||ab(this));sm(this,a.Qa)}; function xm(a,b,c){if((a=a.la.listDisks)&&a.options){for(var d=0;d=this.D&&(this.Z&=-81,this.G=this.D=0);return a}; -l.yl=function(a,b){this.D=rm[c].jd){var d=!1;this.G=0;var c=Dm(this),e,f,g,h,k,m=c&31;switch(m){case 3:Dm(this);Dm(this);Em(this);break;case 4:f=Dm(this);this.Qa=f&3;e=this.B[this.Qa];Em(this);Fm(this,(e.kb&-16777216)>>>24);break;case 5:case 6:f=Dm(this);d=f>>2&1;this.Qa=f&3;e=this.B[this.Qa];e.Ya=d;f=e.xb=Dm(this);g=Dm(this);h=e.mb=Dm(this);k=Dm(this);e.wb=128<=this.D&&(this.Z&=-81,this.G=this.D=0);return a}; +l.zl=function(a,b){this.D=rm[c].jd){var d=!1;this.G=0;var c=Dm(this),e,f,g,h,k,m=c&31;switch(m){case 3:Dm(this);Dm(this);Em(this);break;case 4:f=Dm(this);this.Qa=f&3;e=this.B[this.Qa];Em(this);Fm(this,(e.kb&-16777216)>>>24);break;case 5:case 6:f=Dm(this);d=f>>2&1;this.Qa=f&3;e=this.B[this.Qa];e.Ya=d;f=e.xb=Dm(this);g=Dm(this);h=e.mb=Dm(this);k=Dm(this);e.wb=128<>2&1;this.Qa=f&3;e=this.B[this.Qa];f=e.xb;g=e.Ya=d;h= e.mb=1;k=0;e.kb=0;e.ta&&(e.Wa=e.ta.seek(e.xb,e.Ya,e.mb))?k=e.Wa.length>>8:e.kb=72;Gm(this,e,c,d,f,g,h,k);d=!0;break;case 13:f=Dm(this);d=f>>2&1;this.Qa=f&3;e=this.B[this.Qa];f=e.xb;g=e.Ya=d;h=1;k=Dm(this);e.wb=128<>2&1,f=Dm(this),e.xb+= -f-e.vd,0>e.xb&&(e.xb=0),e.xb>=e.ib&&(e.xb=e.ib-1),e.vd=f,e.kb=32,e.xb||(e.kb|=268435456),Em(this),d=!0}0>>8);Fm(a,(b.kb&16711680)>>>16);var k=0;if(e!=b.xb||f!=b.Ya)k=g=1;c&128&&(f^=k,d||(k=0));Fm(a,e+k);Fm(a,f);Fm(a,g);Fm(a,h)} +f-e.vd,0>e.xb&&(e.xb=0),e.xb>=e.ib&&(e.xb=e.ib-1),e.vd=f,e.kb=32,e.xb||(e.kb|=268435456),Em(this),d=!0}0>>8);Fm(a,(b.kb&16711680)>>>16);var k=0;if(e!=b.xb||f!=b.Ya)k=g=1;c&128&&(f^=k,d||(k=0));Fm(a,e+k);Fm(a,f);Fm(a,g);Fm(a,h)} function Dm(a){var b=a.I[a.G];a.G++;return b}function Em(a){a.G=a.D=0}function Fm(a,b){a.I[a.D++]=b}l.pj=function(a,b,c){if(void 0===b||0>b){b=-1;var d=null,e=0;if(!a.kb&&a.ta){do{if(a.Wa&&(e=a.Ua,0<=(b=a.ta.read(a.Wa,a.Ua++)))){d=a.Wa;break}a.Wa=a.ta.seek(a.xb,a.Ya,a.mb);if(!a.Wa){a.kb=1088;break}a.Ua=0;Hm(a)}while(1)}c(b,!1,d,e)}else c(-1,!1)};l.qj=function(a,b){return void 0!==b&&0<=b?Im(a,b):-1}; l.Cj=function(a,b){var c;if(void 0!==b&&0<=b)a:if(c=b,a.kb)c=-1;else{a.Pc[a.ie++]=c;if(a.ie==a.Pc.length){a.xb=a.Pc[0];a.Ya=a.Pc[1];a.mb=a.Pc[2];a.wb=128<Im(a,a.Eh)){c=-1;break a}a.vf++}a.vf>=a.wd&&(c=-1)}else c=-1;return c};function Im(a,b){if(a.kb||!a.ta)return-1;do{if(a.Wa&&a.ta.write(a.Wa,a.Ua++,b))break;a.Wa=a.ta.seek(a.xb,a.Ya,a.mb);if(!a.Wa){a.kb=8256;b=-1;break}a.Ua=0;Hm(a)}while(1);return b} -function Hm(a){a.mb++;a.mb>=a.Ve+1&&(a.mb=1,a.Ya++,a.Ya>=a.Ue&&(a.Ya=0,a.xb++))}var vm={1012:qm.prototype.mk,1013:qm.prototype.kk,1015:qm.prototype.lk},wm={1010:qm.prototype.zl,1013:qm.prototype.yl,1015:qm.prototype.xl};Ea(function(){for(var a=Za(document,"pcjs","fdc"),b=0;b=a.Ve+1&&(a.mb=1,a.Ya++,a.Ya>=a.Ue&&(a.Ya=0,a.xb++))}var vm={1009:qm.prototype.lk,1012:qm.prototype.nk,1013:qm.prototype.kk,1015:qm.prototype.mk},wm={1010:qm.prototype.Al,1013:qm.prototype.zl,1015:qm.prototype.yl};Ea(function(){for(var a=Za(document,"pcjs","fdc"),b=0;bk.ta.restore(g)&&(z=!1),z&&void 0!==k.Ua&&(k.Wa=k.ta.seek(k.Jd,k.Ya,k.mb+k.uf)));z||(e= !1);null!=a.da&&1>=d&&(a.da|=(f.type&3)<<(1-d<<1))}0<=a.Qa&&(a.C=a.B[a.Qa]);return e}function Rm(a,b,c){if(b){var d=0,e=0;null==c&&((d=b.de[2])?e=b.de[0]<<8|b.de[1]:c=b.type);null==c||d||(d=Km[a.H][c][1],e=Km[a.H][c][0]);d&&((c=Km[a.H][b.type])&&e!=c[0]&&d!=c[1]&&a.Ca("Warning: drive parameters ("+e+","+d+") do not match drive type "+b.type+" ("+c[0]+","+c[1]+")"),b.ib=e,b.jb=d,null==b.ta&&(b.ta=new am(a,b,b.mode)))}} function Pm(a,b){b||(a.R=0);for(var c=0;c=this.D&&(this.G=this.D=0,this.Z&=-15);return a}; -l.Vl=function(a,b){this.D=c&&(this.Z|=2,this.Z&=-2,Sm(this))};l.Ok=function(){var a=this.Z;this.G=this.D&&(this.G=this.D=0,this.Z&=-15);return a}; +l.Wl=function(a,b){this.D=c&&(this.Z|=2,this.Z&=-2,Sm(this))};l.Pk=function(){var a=this.Z;this.G=a.C.nb?(a.Z=128,Um(a.C,function(b){0<=b?(Vm(a),a.P&&5180==a.P.ca&&(a.Z=0),a.Z|=88):(a.Z=1,a.K=16)},!1)):a.Z=80));return b}l.tj=function(){return Tm(this)|Tm(this)<<8};function Wm(a,b){a.C&&a.C.wb>=a.C.nb&&(0>Xm(a.C,b)?(a.Z=1,a.K=16):(1==a.C.Ua||a.C.Ua==a.C.nb)&&1=a.C.nb&&(a.Z|=8)))} -l.fl=function(a,b){Wm(this,b&255);Wm(this,b>>8&255)};l.Uj=function(){return this.K};l.kl=function(a,b){this.za=b};l.Wj=function(){return this.L};l.il=function(a,b){this.L=b};l.Xj=function(){return this.oa};l.jl=function(a,b){this.oa=b};l.Sj=function(){return this.ma};l.el=function(a,b){this.ma=b};l.Rj=function(){return this.ka};l.dl=function(a,b){this.ka=b};l.Tj=function(){return this.ba};l.gl=function(a,b){this.ba=b;this.Z=this.B[this.ba&16?1:0]?this.Z|80:this.Z&-65}; -l.Yj=function(){var a=this.Z;this.Z&64&&(this.Z&=-129);return a};l.cl=function(a,b){this.pa=b;this.P&&Se(this.P,14);Ym(this)};l.hl=function(a,b){this.S&4&&!(b&4)&&(this.K=1);this.S=b}; +l.gl=function(a,b){Wm(this,b&255);Wm(this,b>>8&255)};l.Uj=function(){return this.K};l.ll=function(a,b){this.za=b};l.Wj=function(){return this.L};l.jl=function(a,b){this.L=b};l.Xj=function(){return this.oa};l.kl=function(a,b){this.oa=b};l.Sj=function(){return this.ma};l.fl=function(a,b){this.ma=b};l.Rj=function(){return this.ka};l.el=function(a,b){this.ka=b};l.Tj=function(){return this.ba};l.hl=function(a,b){this.ba=b;this.Z=this.B[this.ba&16?1:0]?this.Z|80:this.Z&-65}; +l.Yj=function(){var a=this.Z;this.Z&64&&(this.Z&=-129);return a};l.dl=function(a,b){this.pa=b;this.P&&Se(this.P,14);Ym(this)};l.il=function(a,b){this.S&4&&!(b&4)&&(this.K=1);this.S=b}; function Ym(a){var b=!1,c=a.pa,d=a.ba&16?1:0,e=a.ba&15,f=a.ma|(a.ka&3)<<8,g=a.oa,h=a.L||256;a.Qa=-1;a.C=null;a.K=0;a.Z=80;var k=a.B[d];k?(k.Jd=f,k.Ya=e,k.mb=g,k.wb=h*k.nb,c=144<=c?c:c&240,k.Wa=null,k.Ua=0,k.errorCode=0,a.Qa=d,a.C=k):c=-1;switch(c&240){case 16:b=!0;break;case 32:a.Z=128;Um(k,function(b){0<=b&&a.P?(Vm(a),a.Z=88):(a.Z=1,a.K=16)},!1);break;case 48:a.Z=8;break;case 64:b=!0;break;case 112:b=!0;break;case 144:a.K=1;b=!0;break;case 145:k.jb=e+1,k.eb=h,b=!0}b&&Vm(a)} function Vm(a){!a.P||a.S&2||Te(a.P,14,120)} function Sm(a){a.G=0;var b=Zm(a),c=Zm(a),d=c&32,e=d>>5,f=c&31,g=Zm(a),h=Zm(a),k=g<<2&768|h,m=g&63,p=Zm(a),x=Zm(a),r=a.B[e];r&&(r.Jd=k,r.Ya=f,r.mb=m,r.wb=p*r.nb);switch(b){case 3:$m(a,r?r.errorCode:4);dn(a,c);dn(a,g);dn(a,h);dn(a,0|d);b=-1;break;case 12:for(c=0;0<=(b=Zm(a));)r&&c=a.eb+b&&(a.mb=b,a.Ya++,a.Ya>=a.jb&&(a.Ya=0,a.Jd++))}l.Qk=function(){var a=this.A.M&255;!(this.A.J>>8)&&128>8||!this.P)||(a=!(this.P.gc[0].Vc&64));return a?!0:!1}; -var Mm={800:Z.prototype.Nk,801:Z.prototype.Ok,802:Z.prototype.Mk},Lm={496:Z.prototype.tj,497:Z.prototype.Uj,498:Z.prototype.Wj,499:Z.prototype.Xj,500:Z.prototype.Sj,501:Z.prototype.Rj,502:Z.prototype.Tj,503:Z.prototype.Yj},Om={800:Z.prototype.Vl,801:Z.prototype.Yl,802:Z.prototype.Xl,803:Z.prototype.Wl,807:Z.prototype.hh,811:Z.prototype.hh,815:Z.prototype.hh},Nm={496:Z.prototype.fl,497:Z.prototype.kl,498:Z.prototype.il,499:Z.prototype.jl,500:Z.prototype.el,501:Z.prototype.dl,502:Z.prototype.gl,503:Z.prototype.cl, -1014:Z.prototype.hl};Ea(function(){for(var a=Za(document,"pcjs","hdc"),b=0;b=a.eb+b&&(a.mb=b,a.Ya++,a.Ya>=a.jb&&(a.Ya=0,a.Jd++))}l.Rk=function(){var a=this.A.M&255;!(this.A.J>>8)&&128>8||!this.P)||(a=!(this.P.gc[0].Vc&64));return a?!0:!1}; +var Mm={800:Z.prototype.Ok,801:Z.prototype.Pk,802:Z.prototype.Nk},Lm={496:Z.prototype.tj,497:Z.prototype.Uj,498:Z.prototype.Wj,499:Z.prototype.Xj,500:Z.prototype.Sj,501:Z.prototype.Rj,502:Z.prototype.Tj,503:Z.prototype.Yj},Om={800:Z.prototype.Wl,801:Z.prototype.Zl,802:Z.prototype.Yl,803:Z.prototype.Xl,807:Z.prototype.hh,811:Z.prototype.hh,815:Z.prototype.hh},Nm={496:Z.prototype.gl,497:Z.prototype.ll,498:Z.prototype.jl,499:Z.prototype.kl,500:Z.prototype.fl,501:Z.prototype.el,502:Z.prototype.hl,503:Z.prototype.dl, +1014:Z.prototype.il};Ea(function(){for(var a=Za(document,"pcjs","hdc"),b=0;b<><><><><><><><><><><><> + * ; <><> DISKETTE FAILED <><> + * MOV SI,OFFSET E601 ; GET ADDRESS OF MESSAGE + * CALL E_MSG ; GO PRINT ERROR MESSAGE + * JMP SHORT F15C ; SKIP SETUP IF ERROR + * + * J_OK3: + * OR @LASTRATE,DUAL ; TURN ON DSP/COMBO FLAG + * + * @this {FDC} + * @param {number} port (0x3F1, input only) + * @param {number} [addrFrom] (not defined whenever the Debugger tries to read the specified port) + * @return {number} simulated port value + */ +FDC.prototype.inFDCDiagnostic = function(port, addrFrom) +{ + var b = 0x50; // we simply return the expected pattern (01010000B); see code excerpt above + this.printMessageIO(port, null, addrFrom, "DIAG", b); + return b; +}; + /** * inFDCStatus(port, addrFrom) * @@ -2545,6 +2624,7 @@ FDC.prototype.writeFormat = function(drive, b) * way out and always emulating it. So, consider an FDC parameter to disable that feature for stricter compatibility. */ FDC.aPortInput = { + 0x3F1: FDC.prototype.inFDCDiagnostic, 0x3F4: FDC.prototype.inFDCStatus, 0x3F5: FDC.prototype.inFDCData, 0x3F7: FDC.prototype.inFDCInput diff --git a/modules/pcjs/lib/hdc.js b/modules/pcjs/lib/hdc.js index bc277c324f..cd3342ea40 100644 --- a/modules/pcjs/lib/hdc.js +++ b/modules/pcjs/lib/hdc.js @@ -2958,6 +2958,11 @@ HDC.aXTCPortInput = { 0x322: HDC.prototype.inXTCConfig }; +/* + * For future reference, the REV2 and REV3 PC AT ROM BIOS also refer to a "FIXED DISK DIAGNOSTIC REGISTER" at + * port 0x5F7, but I have no documentation on it, and failure to respond is non-fatal. See the discussion of the + * FDC diagnostic register in inFDCDiagnostic() for more details. + */ HDC.aATCPortInput = { 0x1F0: HDC.prototype.inATCData, 0x1F1: HDC.prototype.inATCError, diff --git a/pubs/pc/reference/ibm/5170/techref/manifest.xml b/pubs/pc/reference/ibm/5170/techref/manifest.xml index 2aa22186ea..a837ec62ca 100644 --- a/pubs/pc/reference/ibm/5170/techref/manifest.xml +++ b/pubs/pc/reference/ibm/5170/techref/manifest.xml @@ -12,5 +12,7 @@ BIOS Listing TEST.01: X286 Processor Test TEST.02: Verify CMOS Shutdown Byte + POST7 VERW/VERR + DISKETTE_IO_1 diff --git a/versions/pcjs/1.21.4/pc-dbg.js b/versions/pcjs/1.21.4/pc-dbg.js index 89431226e4..5e82cd4d03 100644 --- a/versions/pcjs/1.21.4/pc-dbg.js +++ b/versions/pcjs/1.21.4/pc-dbg.js @@ -41,10 +41,10 @@ f>d&&(f=d);c=f;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.Ca)){b=c;if(a.context&&a.ja& c}}}m.qd=function(){};function Kb(a,b,c,d){a.A.Af[a.A.Ai++]={Qk:b,Ud:c,type:d};return sa(Hb,b,c,0,d)}function Ib(a,b,c,d){var e,f=null.style.color,g=a.Na=10;a.C=g;a.U=b;a.X=a.wa=18;e||(e=a.ua||a.wa+"px Monaco, Lucida Console, Courier New");a.ga=a.ua=e;c&&(a.Ea=c);d&&(a.N=d,a.Fa=f||"white")} function Jb(a,b,c,d,e){a.N.font=a.ga;a.N.fillStyle=a.Fa;a.N.fillText(b,a.C,a.U);a.C+=a.pa;null!=c&&(16!=a.Tb?b=c.toString():(b=8>a.Ka?"0x":"",b+=r(c,a.Ka)),a.N.fillText(b,a.C,a.U),a.C+=a.pa);d&&(a.C+=a.pa*d);e&&(a.C=a.Na,a.U+=(a.X+2)*(e||1))}function Fb(){for(var a=!1,b=nb(document,"pcjs","panel"),c=0;c=this.N?12:24>=this.N?14:15;this.Nb=1<>2;this.A=this.Nb-1;this.U=this.X/this.Nb|0;this.ea=this.U-1;this.B=[];this.C=[];this.L=this.W=!1;this.aa=[];this.fa=[];a=new B;Mb(a,this.ha);this.sa=Array(this.U);for(b=0;b>>a.La;0a.Nb?a.Nb:c;if(g&&g.size){if(g.type==d&&g.controller==e){if(b+c<=g.Da)return g.Ne+=g.Da-b,g.Da=b,!0;if(b>=g.Da+g.Ne){k=g.size-(b-h);k>c&&(k=c);g.Ne=b-g.Da+k;c-=k;b=h+a.Nb;continue}}return Tb(a,1,b,c)}g=a.sa[f];b=new B(b,k,a.Nb,d,e);Mb(b,a.ha,g);a.sa[f++]=b;b=h+a.Nb;c-=k}return 0>=c?(Vb(a.F),!0):Tb(a,2,b,c)} +a.jd=a.Gd-1;a=this.F;a.Gb=a.Db=this.Gb;rb(this)}db(Lb);var Hb,Nb={$j:20,count:8,oo:1,type:3},Ob=0,Pb;for(Pb in Nb){var Qb=Nb[Pb];Nb[Pb]={lh:(1<>>a.La;0a.Nb?a.Nb:c;if(g&&g.size){if(g.type==d&&g.controller==e){if(b+c<=g.Da)return g.Ne+=g.Da-b,g.Da=b,!0;if(b>=g.Da+g.Ne){k=g.size-(b-h);k>c&&(k=c);g.Ne=b-g.Da+k;c-=k;b=h+a.Nb;continue}}return Tb(a,1,b,c)}g=a.sa[f];b=new B(b,k,a.Nb,d,e);Mb(b,a.ha,g);a.sa[f++]=b;b=h+a.Nb;c-=k}return 0>=c?(Ub(a.F),!0):Tb(a,2,b,c)} function Rb(a,b){if(32==a.N)b?a.V&&(Wb(a,1048576,1048576,a.V),a.V=null):a.V||(a.V=Xb(a,1048576,1048576),Wb(a,1048576,1048576,Xb(a,0,1048576)));else if(20>>this.La;0>>a.La;0>>=a.La;0>>a.La;0>>=a.La;0>>a.La;0>>this.La].jc(a&this.A,a)}; m.na=function(a){var b=a&this.A,c=(a&this.Gb)>>>this.La;return b!=this.A?this.sa[c].rf(b,a):this.sa[c++].jc(b,a)|this.sa[c&this.ea].jc(0,a+1)<<8};function ec(a,b){var c=b&a.A,d=(b&a.Gb)>>>a.La;return c!=a.A?a.sa[d].cg(c,b):a.sa[d++].se(c,b)|a.sa[d&a.ea].se(0,b+1)<<8}m.oa=function(a){var b=a&this.A,c=(a&this.Gb)>>>this.La;if(b>>this.La].sc(a&this.A,b&255,a)};m.jb=function(a,b){var c=a&this.A,d=(a&this.Gb)>>>this.La;c!=this.A?this.sa[d].yf(c,b&65535,a):(this.sa[d++].sc(c,b&255,a),this.sa[d&this.ea].sc(0,b>>8&255,a+1))};function fc(a,b,c){var d=b&a.A,e=(b&a.Gb)>>>a.La;d!=a.A?a.sa[e].oi(d,c&65535,b):(a.sa[e++].wf(d,c&255,b),a.sa[e&a.ea].wf(0,c>>8&255,b+1))} @@ -73,15 +73,15 @@ m.ic=function(a,b){if(!b){if(a&&this.restore){Oc(this);if(!this.restore(a))retur function Vc(a,b){if(a.la.Ye){var c=!1;a.Y.If=a.Y.If+a.Qi()|0;a.Y.kf-=b;0>=a.Y.kf&&(a.Y.kf+=a.Y.jf,c=!0);0<=a.Y.lf&&a.Y.lf<=Wc(a)&&(a.Y.jf=a.Y.lf=-1,Pc(a),a.Wb(),c=!0);c&&a.O(Wc(a)+" cycles: checksum="+r(a.Y.If))}} m.Qb=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.qa[b]=c;a=!0;break;case "run":this.qa[b]=c;c.onclick=function(){var a;if(a=d.V)if(a=d.V,a.la.cc)a=!0;else{var b=null,c,h=gb(a.id);for(c=0;cc&&(c=60);2>c&&(c=2);var d=1;b&&1a.Y.tg&&(c=Math.round(c/a.Y.Yd));return c}function Oc(a){a.Y.pe=0;a.uc=a.Ub=a.fb=a.A=0;Pc(a);Xc(a,1)} +function $c(a,b){var c=30;60>c&&(c=60);2>c&&(c=2);var d=1;b&&1a.Y.tg&&(c=Math.round(c/a.Y.Yd));return c}function Oc(a){a.Y.pe=0;a.uc=a.Ub=a.fb=a.A=0;Pc(a);Xc(a,1)} function Xc(a,b,c){var d=!1;if(void 0!==b){.8>a.Y.pe/a.Y.Fe?b=1:d=!0;a.Y.Yd=b;b=a.Y.tg*a.Y.Yd;if(a.Y.Fe!=b){a.Y.Fe=b;b=a.Y.Fe.toFixed(2)+"Mhz";var e=a.qa.setSpeed;e&&(e.textContent=b);a.O("target speed: "+b)}c&&a.V&&a.V.yd()}Zc(a,a.Ub);a.Ub=0;a.Y.hf=pa();a.Y.Ge=0;$c(a);return d} -m.Ke=function(a){if(pb(this,!0)){if(!this.la.Ib){Xc(this);this.V&&this.V.start(this.Y.hf,Wc(this));this.la.Ib=!0;this.la.dh=!0;this.N&&ad(this.N);var b=this.qa.run;b&&(b.textContent="Halt");this.V&&(this.V.qd(),a&&this.V.yd(!0))}this.Y.rh>=this.Y.Jd&&$c(this,!0);this.Y.Mf=0;this.Y.ug=pa();this.Y.Ge&&(a=this.Y.ug-this.Y.Ge,a>this.Y.Xi&&(this.Y.hf+=a,this.Y.hf>this.Y.ug&&(this.Y.hf=this.Y.ug)));try{do{var c=this.la.Ye?1:this.Y.jm;if(this.N){bd(this.N);var d=this.N;a=c;var e=d.W[0];if(e.Be){var f=(Wc(d.F, +m.Ke=function(a){if(pb(this,!0)){if(!this.la.Ib){Xc(this);this.V&&this.V.start(this.Y.hf,Wc(this));this.la.Ib=!0;this.la.dh=!0;this.N&&ad(this.N);var b=this.qa.run;b&&(b.textContent="Halt");this.V&&(this.V.qd(),a&&this.V.yd(!0))}this.Y.rh>=this.Y.Jd&&$c(this,!0);this.Y.Mf=0;this.Y.ug=pa();this.Y.Ge&&(a=this.Y.ug-this.Y.Ge,a>this.Y.Xi&&(this.Y.hf+=a,this.Y.hf>this.Y.ug&&(this.Y.hf=this.Y.ug)));try{do{var c=this.la.Ye?1:this.Y.km;if(this.N){bd(this.N);var d=this.N;a=c;var e=d.W[0];if(e.Be){var f=(Wc(d.F, d.ka)-e.xd)/d.gb|0,g=cd(d,0)-f;6==e.mode&&(g-=f);var h=g*d.gb|0;6==e.mode&&(h>>=1);a>h&&(a=h)}var c=a,k=this.N;a=c;if(k.A&&k.A[11]&64){var l=k.ua-Wc(k.F,k.ka);0l&&(a=l)}c=a}try{this.vf(c)}catch(q){if("number"!=typeof q)throw q;}var n=this.fb-this.A;this.Ub+=n;this.Y.Mf+=n;Zc(this,0,!0);Vc(this,n);this.Y.Lf-=n;0>=this.Y.Lf&&(this.Y.Lf+=this.Y.Zi,this.V&&dd(this.V));this.Y.Kf-=n;0>=this.Y.Kf&&(this.Y.Kf+=this.Y.Yi,this.V&&this.V.qd());this.Y.mf-=n;if(0>=this.Y.mf){this.Y.mf+=this.Y.qh;break}}while(this.la.Ib)}catch(q){this.Wb(); Qc(this);this.V&&this.V.stop(pa(),Wc(this));pb(this,!1);ub(this,q.stack||q.message);return}c=setTimeout;d=this.pi;this.Y.Ge=pa();e=this.Y.Xi;this.Y.Mf&&(e=Math.round(e*this.Y.Mf/this.Y.qh));e-=this.Y.Ge-this.Y.ug;if(f=this.Y.Ge-this.Y.hf)this.Y.pe=Math.round(this.Ub/(10*f))/100,864E5<=f&&(this.uc=0,this.N&&bd(this.N,!0),Xc(this));if(0>e||this.Y.pethis.id&&C.call(e,b&&3==this.id?10:13,a&65532)}return-1};m.fm=function(a){var b=this.F;a=b.Mc+(a<<2);var c=b.na(a);b.ca&=-769;return this.load(b.na(a+2))+c|0}; -m.em=function(a){var b=this.F;a<<=3;var c=b.Mc+a|0;if(7<=(b.Td-c|0))return this.C=!0,a=hd(this,c,a),-1!==a&&(a+=this.Xf),a;C.call(b,13,a|2);return-1};m.Di=function(a){return this.Aa+a|0};m.Fi=function(a){return this.Aa+a|0};m.Ci=function(a,b){return(a>>>0)+b<=this.Zb?this.Aa+a|0:this.ng()};m.Ik=function(a,b){return(a>>>0)+b>this.Zb?this.Aa+a|0:this.ng()};m.ng=function(){C.call(this.F,13,0);return-1};m.Ei=function(a,b){return(a>>>0)+b<=this.Zb?this.Aa+a|0:this.og()}; +m.kh=function(a){this.Z=a&65535;return this.Aa=this.Z<<4};m.sg=function(a,b){var c,d,e=this.F;a&=65535;a&4?(c=e.Bc.Aa,d=c+e.Bc.Ta|0):(c=e.Ec,d=e.Ad);if(c){c=c+(a&65528)|0;if(d-c|0)return e.A-=15,hd(this,c,a,b);6>this.id&&C.call(e,b&&3==this.id?10:13,a&65532)}return-1};m.gm=function(a){var b=this.F;a=b.Mc+(a<<2);var c=b.na(a);b.ca&=-769;return this.load(b.na(a+2))+c|0}; +m.fm=function(a){var b=this.F;a<<=3;var c=b.Mc+a|0;if(7<=(b.Td-c|0))return this.C=!0,a=hd(this,c,a),-1!==a&&(a+=this.Xf),a;C.call(b,13,a|2);return-1};m.Di=function(a){return this.Aa+a|0};m.Fi=function(a){return this.Aa+a|0};m.Ci=function(a,b){return(a>>>0)+b<=this.Zb?this.Aa+a|0:this.ng()};m.Ik=function(a,b){return(a>>>0)+b>this.Zb?this.Aa+a|0:this.ng()};m.ng=function(){C.call(this.F,13,0);return-1};m.Ei=function(a,b){return(a>>>0)+b<=this.Zb?this.Aa+a|0:this.og()}; m.Jk=function(a,b){return(a>>>0)+b>this.Zb?this.Aa+a|0:this.og()};m.og=function(){C.call(this.F,13,0);return-1};function id(a,b,c,d,e){a.Z=b;a.Aa=d;a.Ta=e;a.Zb=(e>>>0)+1;a.wb=c;a.type=c&7936;a.ext=c>>16&192;a.Xb=(b&4?a.F.Bc.Aa:a.F.Ec)+(b&65528)|0;4>a.id&&fd(a,!0)}function jd(a,b,c){var d=a.F,e=d.na(b+2),f=d.na(b)|(e&255)<<16,d=d.na(b+4);a.Z=c;a.Aa=f;a.Ta=d;a.Zb=(d>>>0)+1;a.wb=e;a.type=e&7936;a.ext=0;a.Xb=b;4>a.id&&fd(a,!0)} function hd(a,b,c,d){var e=a.F;if(!d&&c===a.A.Z)return a.Z=c,a.Aa=a.A.Aa,a.Ta=a.A.Ta,a.Zb=(a.A.Ta>>>0)+1,a.wb=a.A.wb,a.type=a.A.type,a.ext=a.A.ext,a.Xb=a.A.Xb,a.A.Z=-1,fd(a,!0,!0,!1),a.Aa;a.A.Z=-1;var f=e.na(b+0),g=e.na(b+4),h=g&7936,k=e.na(b+2)|(g&255)<<16,l=e.na(b+6),n=c&65528;if(80386<=e.ia){var q=f,k=k|(l&65280)<<16,f=f|(l&15)<<16;l&128&&(f=f<<12|4095)}switch(a.id){case 1:var p=a.C;a.cf=!1;if(p&&1==c&&a.B.length){var z=a.B[a.Xf-1];if(z&&!z())return-1}var F=c&3,v=(g&24576)>>13,z=-1,E,H;n||b>=e.Ec&& b=a.Lb&&(F>a.Lb&&(z=D(e),kd(e,D(e),!0),G(e,z),a.cf=!0),z=0);else{if(256==h||2304==h)return ld(a,c,p)?a.Aa:-1;if(1024==h)z=2,H=0,F>>0)+1)}; -function fd(a,b,c,d){void 0===c&&(c=!!(a.F.Za&1));a.cd=!1;if(c)if(a.load=a.sg,a.Wi=a.em,a.nc=a.Ci,a.oc=a.Ei,void 0===d&&(d=!!(a.F.ca&131072)),d)a.load=a.V,a.nc=a.ea,a.oc=a.qa,a.Lb=a.Gc=3,a.ba=a.Oc=2,a.R=a.Ba=65535,a.Ta=65535,a.Zb=a.Ta+1,a.Oc=a.ba,a.Xb=-1,a.cf=!1;else{if(!(a.Z&-4))a.nc=a.ng,a.oc=a.og;else if(a.type&4096){6144==(a.type&6656)&&(a.nc=a.ng);if(a.type&2048||!(a.type&512))a.oc=a.og;1024==(a.type&3072)&&(a.nc==a.Ci&&(a.nc=a.Ik),a.oc==a.Ei&&(a.oc=a.Jk),a.cd=!0);b&&6>a.id&&a.Z&-4&&-1!==a.Xb&& -(c=a.Xb+5,d=a.F.Qa(c),d&1||a.F.qc(c,d|1))}b&&(a.Lb=a.Z&3,a.Gc=(a.wb&24576)>>13,80386>a.F.ia||!(a.ext&64)?(a.ba=2,a.R=65535):(a.ba=4,a.R=-1),a.Oc=a.ba,a.Ba=a.R)}else a.load=a.kh,a.Wi=a.fm,a.nc=a.Di,a.oc=a.Fi,a.Lb=a.Gc=0,a.Xb=-1,a.cf=!1} +function fd(a,b,c,d){void 0===c&&(c=!!(a.F.Za&1));a.cd=!1;if(c)if(a.load=a.sg,a.Wi=a.fm,a.nc=a.Ci,a.oc=a.Ei,void 0===d&&(d=!!(a.F.ca&131072)),d)a.load=a.V,a.nc=a.ea,a.oc=a.qa,a.Lb=a.Gc=3,a.ba=a.Oc=2,a.R=a.Ba=65535,a.Ta=65535,a.Zb=a.Ta+1,a.Oc=a.ba,a.Xb=-1,a.cf=!1;else{if(!(a.Z&-4))a.nc=a.ng,a.oc=a.og;else if(a.type&4096){6144==(a.type&6656)&&(a.nc=a.ng);if(a.type&2048||!(a.type&512))a.oc=a.og;1024==(a.type&3072)&&(a.nc==a.Ci&&(a.nc=a.Ik),a.oc==a.Ei&&(a.oc=a.Jk),a.cd=!0);b&&6>a.id&&a.Z&-4&&-1!==a.Xb&& +(c=a.Xb+5,d=a.F.Qa(c),d&1||a.F.qc(c,d|1))}b&&(a.Lb=a.Z&3,a.Gc=(a.wb&24576)>>13,80386>a.F.ia||!(a.ext&64)?(a.ba=2,a.R=65535):(a.ba=4,a.R=-1),a.Oc=a.ba,a.Ba=a.R)}else a.load=a.kh,a.Wi=a.gm,a.nc=a.Di,a.oc=a.Fi,a.Lb=a.Gc=0,a.Xb=-1,a.cf=!1} function Bd(a){this.ia=a.model||8088;var b=a.stepping;this.Uc=this.ia+(b?ca(b,16):0);b=0;switch(this.ia){default:b=4772727;break;case 80286:b=6E6;break;case 80386:b=16E6}Lc.call(this,a,b);this.Yf=61442;this.Cc=1792;this.Wf=28672;this.Dd=4;this.ra=255;this.B=80286<=this.ia?xb:wb;this.X=Cd;this.bg=Dd;this.gg=Ed;this.hg=Fd;if(80186<=this.ia&&(this.X=Cd.slice(),this.bg=Dd.slice(),this.gg=Ed.slice(),this.ra=31,this.X[15]=Gd,this.X[96]=Hd,this.X[97]=Id,this.X[98]=Jd,this.X[99]=Gd,this.X[100]=Gd,this.X[101]= Gd,this.X[102]=Gd,this.X[103]=Gd,this.X[104]=Kd,this.X[105]=Ld,this.X[106]=Md,this.X[107]=Nd,this.X[108]=Od,this.X[109]=Pd,this.X[110]=Qd,this.X[111]=Rd,this.X[192]=Sd,this.X[193]=Td,this.X[200]=Ud,this.X[201]=Yd,this.X[241]=Zd,this.bg[7]=$d,this.gg[7]=$d,80286<=this.ia)){this.Yf=2;this.Cc|=28672;this.Dd=0;this.X[15]=ae;this.tc=ge.slice();for(a=0;a=this.Uc&&(this.tc[166]=oe,this.tc[167]=pe)}}this.Id=[];this.le=[];this.ne=0;Oc(this);this.la.Wd=this.la.Mi=!1;this.Og=0;this.ld=this.sa=[];this.La=this.Nb=this.Fa=this.Gd=this.jd=this.Gb=this.Db=0;qe(this)}db(Bd,Lc);function re(a,b,c,d){Gc((d?a.ld:a.sa)[b>>>a.La],c);d&&Vb(a)} -function se(a){var b;if(a.sa===a.ld){a.sa=Array(a.Gd);a.me=new B(null,0,0,5,null,a);Mb(a.me,a.ha);for(b=0;ba.oe&&(a.ag[a.oe++]=d);a.sa[b]=a.me}a.Hd=[]}function Vb(a){a.Za&-2147483648&&se(a)} +le;this.X[102]=me;this.X[103]=ne;for(c in M)this.tc[+c]=M[c];80546<=this.Uc&&80562>=this.Uc&&(this.tc[166]=oe,this.tc[167]=pe)}}this.Id=[];this.le=[];this.ne=0;Oc(this);this.la.Wd=this.la.Mi=!1;this.Og=0;this.ld=this.sa=[];this.La=this.Nb=this.Fa=this.Gd=this.jd=this.Gb=this.Db=0;qe(this)}db(Bd,Lc);function re(a,b,c,d){Gc((d?a.ld:a.sa)[b>>>a.La],c);d&&Ub(a)} +function se(a){var b;if(a.sa===a.ld){a.sa=Array(a.Gd);a.me=new B(null,0,0,5,null,a);Mb(a.me,a.ha);for(b=0;ba.oe&&(a.ag[a.oe++]=d);a.sa[b]=a.me}a.Hd=[]}function Ub(a){a.Za&-2147483648&&se(a)} function Fc(a,b,c,d){var e=(b&-4194304)>>>20,f=a.ld[(a.Pd+e&a.Gb)>>>a.La],g=f.Nd(e);if(!(g&1))return d||te.call(a,b,!1,c),a.kd;if(!(g&4)&&3==a.pa)return d||te.call(a,b,!0,c),a.kd;var h=(b&4190208)>>>10,g=a.ld[((g&-4096)+h&a.Gb)>>>a.La],k=g.Nd(h);if(!(k&1))return d||te.call(a,b,!1,c),a.kd;if(!(k&4)&&3==a.pa)return d||te.call(a,b,!0,c),a.kd;c=a.ld[((k&-4096)+(b&4095)&a.Gb)>>>a.La];if(d)return c;d=b>>>a.La;k=a.sa[d];b=b&-4096;var l;0>2;b.zb=g;b.B=h>>2;vb&&ac&&c.da&&!c.controller&&!c.Te&&!c.Ue?(b.Ya=c.Ya,b.fe=c.fe,b.da=c.da,Yb(b,Kc)):(b.ea=c?yc(32):0,b.W=c?yc(96):0,Yb(b,Ic));Mb(b,a.ha,k);a.sa[d]=b;a.Hd.push(d);return b}function ue(a){a.sa!==a.ld&&(a.sa=a.ld,a.me=null,a.Hd=null,a.kd=null)}m=Bd.prototype;m.reset=function(){this.la.Ib&&this.Wb();qe(this);Oc(this);this.la.ud=!1}; function ve(a,b){var c;switch(b){case 0:c=a.G;break;case 1:c=a.I;break;case 2:c=a.M;break;case 3:c=a.H;break;case 4:c=I(a);break;case 5:c=a.P;break;case 6:c=a.K;break;case 7:c=a.J}return c}function we(a,b,c){switch(b){case 0:a.G=c;break;case 1:a.I=c;break;case 2:a.M=c;break;case 3:a.H=c;break;case 4:G(a,c);break;case 5:a.P=c;break;case 6:a.K=c;break;case 7:a.J=c}} @@ -183,7 +183,7 @@ function gj(a,b){return b>>(this.G&this.R)&(1<<(this.I&31))-1&this.R}function hj function ij(a,b){if(-1===this.D){switch(this.L&7){case 0:this.G=this.G&~this.R|a;break;case 1:this.I=this.I&~this.R|a;break;case 2:this.M=this.M&~this.R|a;break;case 3:this.H=this.H&~this.R|a;break;case 4:G(this,I(this)&~this.R|a);break;case 5:this.P=this.H&~this.R|a;break;case 6:this.K=this.K&~this.R|a;break;case 7:this.J=this.J&~this.R|a}this.A-=this.B.bi}else this.C=this.D,this.S&2||this.rc(this.$b.oc(this.Ca,this.ba),a),this.A-=this.B.ai;return b} function jj(a,b){var c=a^b;vf(this,c,128);this.A-=-1===this.C?-1===this.D?this.B.yc:this.B.Vb:this.B.Nc;return c}function kj(a,b){this.A-=-1===this.C?-1===this.D?this.B.yc:this.B.Vb:this.B.Nc;return vf(this,a^b,this.Ia)&this.R}function lj(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function mj(a){var b=a-1|0;of(this,a,1,b,this.Ia|62,!0);this.A-=2;return a&~this.R|b&this.R} function nj(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1;c=[c>>>0,0];for(a=[a>>>0,b>>>0];0>>=0,b[1]++);e+=e}do 0<=lj(a,c)&&(b=a,f=c,b[0]-=f[0],b[1]-=f[1],0>b[0]&&(b[0]>>>=0,b[1]--),d+=e),b=c,b[0]>>>=1,b[1]&1&&(b[0]=(b[0]|2147483648)>>>0),b[1]>>>=1,e/=2;while(1<=e);this.ja=d;this.wa=a[0];return!0}function oj(a){var b=a+1|0;of(this,a,1,b,this.Ia|62);this.A-=2;return a&~this.R|b&this.R} -function pj(a){this.Za=a;md(this);this.Za&-2147483648?se(this):ue(this)}function Ad(a){this.Pd=a;Vb(this)}function qj(a){this.S|=1;this.$a.call(this,a);this.A-=-1===this.D?4:5}function Ri(a,b,c){if(c){16>>16-c)&65535;vf(this,a,32768,d&32768)}return a}function Ti(a,b,c){if(c){var d=a<>>32-c;vf(this,a,-2147483648,d&-2147483648)}return a} +function pj(a){this.Za=a;md(this);this.Za&-2147483648?se(this):ue(this)}function Ad(a){this.Pd=a;Ub(this)}function qj(a){this.S|=1;this.$a.call(this,a);this.A-=-1===this.D?4:5}function Ri(a,b,c){if(c){16>>16-c)&65535;vf(this,a,32768,d&32768)}return a}function Ti(a,b,c){if(c){var d=a<>>32-c;vf(this,a,-2147483648,d&-2147483648)}return a} function Xi(a,b,c){if(c){16>>c-1;a=(d>>>1|b<<16-c)&65535;vf(this,a,32768,d&1)}return a}function Zi(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;vf(this,a,-2147483648,d&1)}return a}function rj(){this.A-=-1===this.D?2:this.B.Yj;return 1}function sj(){var a=this.I&255;this.A-=(-1===this.D?this.B.Th:this.B.Sh)+(a<=cg&&(this.cb=this.Ea=2);this.ka=a.scaleTimers||!1;this.Ub=a.rtcDate;this.Db=!1;a.sound&&(this.sb=this.Fa=null,window&&(this.sb=window.AudioContext|| -window.webkitAudioContext),this.sb&&(this.Fa=new this.sb));this.reset(!0);rb(this)}db(pk);var rk=5150.9,cg=5170,qk={5150:5150,5160:5160,5170:cg,att6300:5160.101,mpc1600:5150.101,z150:5160.15,compaq:5150.102,other:rk,deskpro386:5180},tk="sw1",xk="sw2",yk={Bk:1,ONE:0,bo:64,$n:128,En:192,Lc:192,Pg:6},zk={ao:16,xn:32,Mn:48,Lc:48,Pg:4},vk=1,wk=4,Ak={5150:[{},{}]};Ak[5150][0][vk]={Lc:192,hd:{1:0,2:64,3:128,4:192},Qd:"Number of Floppy Drives"};Ak[5150][0][3]={Lc:2,hd:{0:0,1:2},Qd:"Coprocessor"}; -Ak[5150][0][wk]={Lc:48,hd:{0:0,1:16,2:32,3:48,none:0,tv:16,color:32,mono:48,ega:0,vga:0},Qd:"Monitor Type"};Ak[5150][0][5]={Lc:12,hd:{16:0,32:4,48:8,64:12},Qd:"Base Memory (16Kb Increments)"};Ak[5150][1][6]={Lc:31,hd:{0:0,32:1,64:2,96:3,128:4,160:5,192:6,224:7,256:8,288:9,320:10,352:11,384:12,416:13,448:14,480:15,512:16,544:17,576:18},Qd:"Expansion Memory (32Kb Increments)"};Ak[5160]=[{},{}];Ak[5160][0][vk]=Ak[5150][0][vk];Ak[5160][0][3]=Ak[5150][0][3];Ak[5160][0][wk]=Ak[5150][0][wk]; +window.webkitAudioContext),this.sb&&(this.Fa=new this.sb));this.reset(!0);rb(this)}db(pk);var rk=5150.9,cg=5170,qk={5150:5150,5160:5160,5170:cg,att6300:5160.101,mpc1600:5150.101,z150:5160.15,compaq:5150.102,other:rk,deskpro386:5180},tk="sw1",xk="sw2",yk={Bk:1,ONE:0,co:64,ao:128,Fn:192,Lc:192,Pg:6},zk={bo:16,yn:32,Nn:48,Lc:48,Pg:4},vk=1,wk=4,Ak={5150:[{},{}]};Ak[5150][0][vk]={Lc:192,hd:{1:0,2:64,3:128,4:192},Qd:"Number of Floppy Drives"};Ak[5150][0][3]={Lc:2,hd:{0:0,1:2},Qd:"Coprocessor"}; +Ak[5150][0][wk]={Lc:48,hd:{0:0,1:16,2:32,3:48,none:0,tv:16,color:32,cga:32,mda:48,mono:48,ega:0,vga:0},Qd:"Monitor Type"};Ak[5150][0][5]={Lc:12,hd:{16:0,32:4,48:8,64:12},Qd:"Base Memory (16Kb Increments)"};Ak[5150][1][6]={Lc:31,hd:{0:0,32:1,64:2,96:3,128:4,160:5,192:6,224:7,256:8,288:9,320:10,352:11,384:12,416:13,448:14,480:15,512:16,544:17,576:18},Qd:"Expansion Memory (32Kb Increments)"};Ak[5160]=[{},{}];Ak[5160][0][vk]=Ak[5150][0][vk];Ak[5160][0][3]=Ak[5150][0][3];Ak[5160][0][wk]=Ak[5150][0][wk]; Ak[5160][0][5]={Lc:12,hd:{64:0,128:4,192:8,256:12},Qd:"Base Memory (64Kb Increments)"};Ak[5160][1][6]=Ak[5150][1][6];Ak[5160.101]=[{},{}];Ak[5160.101][0][5]={Lc:143,hd:{128:1,256:130,512:8,640:141},Qd:"Base Memory (128Kb Increments)"};Ak[5160.101][0][3]={Lc:16,hd:{0:0,1:16},Qd:"Coprocessor"};Ak[5160.101][1][2]={Lc:1,hd:{0:0,1:1},Qd:"Floppy Type"};Ak[5160.101][1][vk]=Ak[5150][0][vk];Ak[5160.101][1][wk]=Ak[5150][0][wk];m=pk.prototype; m.Qb=function(a,b,c){switch(b){case tk:return this.qa[b]=c,Bk(this,0,b),!0;case xk:if(5150==(this.ia|0)||5160.101==this.ia)return this.qa[b]=c,Bk(this,1,b),!0;break;case "swdesc":return this.qa[b]=c,!0}return!1}; m.Ic=function(a,b,c,d){this.ea=b;this.F=c;this.ha=d;this.V=a;this.Tb=Eb(a,"FPU");uk(this,3,this.Tb?1:0,!0);this.B=Eb(a,"Keyboard");this.gb=c.Y.Jd/1193181;hc(b,this,Ck);lc(b,this,Dk);this.iab;b++){var c=13>=b?Ok(e,b):e.A[b];a&&(a+="\n");a+="CMOS["+t(b)+"]: "+t(c)}e.ha.O(a)})}cf(c,26,this.$l.bind(this))}; +c+=" IMR="+t(b.Bd)+" IRR="+t(b.mc)+" ISR="+t(b.Pc)+" DELAY="+b.nf;e.ha.O(c)}});Mk(d,2048,function(a){a=(a=a[0])?+a:null;for(var b=0;bb;b++){var c=13>=b?Ok(e,b):e.A[b];a&&(a+="\n");a+="CMOS["+t(b)+"]: "+t(c)}e.ha.O(a)})}cf(c,26,this.am.bind(this))}; m.ic=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};m.hc=function(a){return a?this.save():!0}; m.reset=function(a){var b;Pk(this);this.L=Array(this.cb);for(b=0;b=cg){this.N=16;this.fa=0;this.aa=16;this.Ja=0;this.ga=160;512<=Tk(this)&&(this.ga|=16);3==+Uk(this,wk,void 0)&&(this.ga|=64);5180==(this.ia|0)&&(this.ga|=12);this.Ka= 3;this.ra=Array(8);this.pa=0;a&&(this.A=Array(64));Vk(this,this.Ub);for(a=21;24>=a;a++)this.A[a]=0;for(a=14;46>a;a++)void 0===this.A[a]&&(this.A[a]=0);a=0|+Uk(this,wk,void 0)<b){var d=!1;4!=b&&5!=b||a.A[11]&2||(12>c?c=c?c:12:c=(c-=12)?c+128:140,d=!0);a.A[11]&4||(d&&128c;c++)b+=a.A[c];a.A[47]=b&255;a.A[46]=b>>8} -m.save=function(){var a=new hf(this);N(a,0,[this.C]);for(var b=[],c=0;c=cg&&(N(a,5,[this.N,this.fa,this.aa,this.Ja,this.ga,this.Ka]),N(a,6,[this.ra[7],this.ra,this.pa,this.A,this.Ia,this.ua]));return a.data()}; m.restore=function(a){var b,c;b=a[0];Array.isArray(b[0])?this.C=b[0]:(this.C[0][0]=b[0],this.C[1][0]=b[1]&15,this.C[0][1]=b[2],this.C[1][1]=b[3]&15);Pk(this);b=a[1];for(c=0;c=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
'+f+"
\n"}e.innerHTML=d;el(a,b,c,!0)}function fl(a,b,c){if(b=(a=Ak[a.ia|0])&&a[b])for(var d in b)if(a=b[d],a.Lc&1<g.Ab[0]&&(g.Ab[0]=255,g.Ab[1]--,0>g.Ab[1]&&(g.Ab[1]=255)));return h}function ll(a,b,c,d,e,f){var g=a.L[b];A(a,768)&&x(a,d,e,f,"DMA"+b+".CHANNEL"+c+".COUNT["+g.Kb+"]",null,!0);a=g.Dc[c];a.Ab[g.Kb]=a.Fc[g.Kb]=e;g.Kb^=1}function ml(a,b,c,d){var e=a.L[b],f=e.Yb|1;e.Yb&=-16;A(a,768)&&x(a,c,null,d,"DMA"+b+".STATUS",f,!0);return f} -function nl(a,b,c,d,e){var f=a.L[b];A(a,768)&&x(a,c,d,e,"DMA"+b+".REQ",null,!0);a=d&3;f.Yb=f.Yb&~(16<>2].Dc[b&3],c,d,e)}function pl(a,b,c){b=a.L[b>>2].Dc[b&3];b.pg&&b.eh&&b.Eg?(c&&(b.done=c),b.Ee||yl(a,b,!0)):c&&c(!0)} function yl(a,b,c){c&&(b.count=b.Ab[1]<<8|b.Ab[0],b.type=b.mode&12,b.Pi=b.ud=!1);for(var d=!1;0<=b.count&&(c=b.kg<<16|b.Eb[1]<<8|b.Eb[0],4==b.type?(d=!0,function(c){b.eh.call(b.pg,b.Eg,-1,function(f,g){0>f&&(b.Pi||(b.Pi=!0),f=255);b.Ee||a.ea.qc(c,f);(d=g)&&setTimeout(function(){zl(b)||yl(a,b)},0)})}(c)):8==b.type?(c=a.ea.Qa(c),0>b.eh.call(b.pg,b.Eg,c)&&(b.ud=!0)):0!=b.type&&(b.ud=!0)),!d&&!zl(b););} @@ -402,29 +402,29 @@ function Kl(a,b,c,d,e){x(a,c,d,e,"PIT"+b+".CTRL",null,2048);e=0;c=d&192;b?(e=3,a 77==a.X&&(b=a.W[0],b.$c[0]=b.Fc[0],b.$c[1]=b.Fc[1],b.xd=Wc(a.F,a.ka))}}}function Il(a,b){var c=a.W[b],d=c.Fc[1]<<8|c.Fc[0];d||(d=1==c.nd?256:65536);return d}function cd(a,b){var c=a.W[b],d=c.$c[1]<<8|c.$c[0];d||(d=1==c.nd?256:65536);return d}function Ll(a,b){Nk(a,b);var c=a.W[b];c.ze[0]=c.Ab[0];c.ze[1]=c.Ab[1];c.Ze=!0;Gl(a,b)}function Gl(a,b){var c=a.W[b];c.Fd=32==c.eg?1:0;c.nd=48==c.eg?2:1} function Nk(a,b,c){var d=a.W[b];if(d.Be&&(2!=b||a.X&1)){var e=Wc(a.F,a.ka),f=(e-d.xd)/a.gb|0;0>f&&(d.xd=e,f=0);var g=Il(a,b),h=cd(a,b)-f;0==d.mode?(0>=h&&(h=0),h||(d.vd=!0,d.Be=!1,b||eg(a,0))):4==d.mode?(d.vd=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.$c[0]=h&255,d.$c[1]=h>>8&255,d.xd=e,!b&&d.vd&&eg(a,0))):6==d.mode&&(h-=f,0>=h&&(d.vd=!d.vd,h=g+h,0>=h&&(h=g),d.$c[0]=h&255,d.$c[1]=h>>8&255,d.xd=e,!b&&d.vd&&eg(a,0)));d.Ab[0]=h&255;d.Ab[1]=h>>8&255;c&&(a.xd=0)}return d} function bd(a,b){for(var c=0;c=cg){var c=a.F.Y.Jd,d=Wc(a.F,a.ka);null==a.fb&&(a.Ia=Wc(a.F,a.ka),a.Jb=1024,a.fb=Math.floor(a.F.Y.Jd/a.Jb),Yk(a));d>=a.ua&&(a.A[12]|=64,a.A[11]&64&&(a.A[12]|=128,eg(a,8)),a.ua=d+a.fb);a.A[0]==a.A[1]&&a.A[2]==a.A[3]&&a.A[4]==a.A[5]&&(a.A[12]|=32,a.A[11]&32&&(a.A[12]|=128,eg(a,8)));var e=d-a.Ia,f=Math.floor(e/c);if(f&&!(a.A[11]&128)){for(;f--;)if(60<=++a.A[0]&&(a.A[0]=0,60<=++a.A[2]&&(a.A[2]=0,24<=++a.A[4]))){a.A[4]=0;a.A[6]=a.A[6]%7+1; -var g;g=a.A[9];var h=ra[a.A[8]-1];28==h&&0===g%4&&(g%100||0===g%400)&&h++;g=h;++a.A[7]>g&&(a.A[7]=1,12<++a.A[8]&&(a.A[8]=1,a.A[9]=(a.A[9]+1)%100))}a.A[12]|=16;a.A[11]&16&&(a.A[12]|=128,eg(a,8))}a.Ia=d-e%c}}m=pk.prototype;m.Jl=function(a,b){var c=this.$a;this.Ca&16&&(this.X&128?c=this.C[0][1]:this.B&&(c=Ml(this.B)));x(this,a,null,b,"PPI_A",c);return c};m.cn=function(a,b,c){x(this,a,b,c,"PPI_A");this.$a=b};m.Kl=function(a,b){var c=this.X;x(this,a,null,b,"PPI_B",c);return c}; -m.dn=function(a,b,c){x(this,a,b,c,"PPI_B");Nl(this,b)};function Nl(a,b){var c=!!(b&2),d=!!(a.X&2);a.X=b;a.B&&Ol(a.B,!(b&128),!!(b&64));c!=d&&ad(a,c)}m.Ll=function(a,b){var c=0,c=5150==(this.ia|0)?this.X&4?c|this.C[1][1]&15:c|this.C[1][1]>>4&1:this.X&8?c|this.C[0][1]>>4:c|this.C[0][1]&15;this.X&1&&Nk(this,2).vd&&(c=this.X&2?c|32:c|16);x(this,a,null,b,"PPI_C",c,32896);return c};m.en=function(a,b,c){x(this,a,b,c,"PPI_C");this.rb=b};m.Ml=function(a,b){var c=this.Ca;x(this,a,null,b,"PPI_CTRL",c);return c}; -m.fn=function(a,b,c){x(this,a,b,c,"PPI_CTRL");this.Ca=b};m.Wk=function(a,b){var c=this.B?Ml(this.B):0;x(this,a,null,b,"8041_KBD",c);this.wa&=-2;return c};m.om=function(a,b,c){x(this,a,b,c,"8041_KBD")};m.Vk=function(a,b){var c=this.X;x(this,a,null,b,"8041_CTRL",c);return c};m.nm=function(a,b,c){x(this,a,b,c,"8041_CTRL");Nl(this,b)};m.Xk=function(a,b){var c=this.wa;x(this,a,null,b,"8041_STATUS",c);return c}; +var g;g=a.A[9];var h=ra[a.A[8]-1];28==h&&0===g%4&&(g%100||0===g%400)&&h++;g=h;++a.A[7]>g&&(a.A[7]=1,12<++a.A[8]&&(a.A[8]=1,a.A[9]=(a.A[9]+1)%100))}a.A[12]|=16;a.A[11]&16&&(a.A[12]|=128,eg(a,8))}a.Ia=d-e%c}}m=pk.prototype;m.Kl=function(a,b){var c=this.$a;this.Ca&16&&(this.X&128?c=this.C[0][1]:this.B&&(c=Ml(this.B)));x(this,a,null,b,"PPI_A",c);return c};m.dn=function(a,b,c){x(this,a,b,c,"PPI_A");this.$a=b};m.Ll=function(a,b){var c=this.X;x(this,a,null,b,"PPI_B",c);return c}; +m.en=function(a,b,c){x(this,a,b,c,"PPI_B");Nl(this,b)};function Nl(a,b){var c=!!(b&2),d=!!(a.X&2);a.X=b;a.B&&Ol(a.B,!(b&128),!!(b&64));c!=d&&ad(a,c)}m.Ml=function(a,b){var c=0,c=5150==(this.ia|0)?this.X&4?c|this.C[1][1]&15:c|this.C[1][1]>>4&1:this.X&8?c|this.C[0][1]>>4:c|this.C[0][1]&15;this.X&1&&Nk(this,2).vd&&(c=this.X&2?c|32:c|16);x(this,a,null,b,"PPI_C",c,32896);return c};m.fn=function(a,b,c){x(this,a,b,c,"PPI_C");this.rb=b};m.Nl=function(a,b){var c=this.Ca;x(this,a,null,b,"PPI_CTRL",c);return c}; +m.gn=function(a,b,c){x(this,a,b,c,"PPI_CTRL");this.Ca=b};m.Wk=function(a,b){var c=this.B?Ml(this.B):0;x(this,a,null,b,"8041_KBD",c);this.wa&=-2;return c};m.pm=function(a,b,c){x(this,a,b,c,"8041_KBD")};m.Vk=function(a,b){var c=this.X;x(this,a,null,b,"8041_CTRL",c);return c};m.om=function(a,b,c){x(this,a,b,c,"8041_CTRL");Nl(this,b)};m.Xk=function(a,b){var c=this.wa;x(this,a,null,b,"8041_STATUS",c);return c}; m.Yk=function(a,b){var c=this.Ja;x(this,a,null,b,"8042_OUTBUFF",c,16384);this.N&=-258;this.B&&Pl(this.B);return c}; -m.qm=function(a,b,c){x(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.N&8)switch(this.fa){case 96:Ql(this,b);break;case 209:Rl(this,b);break;default:if(Ql(this,this.aa&-17),this.B){a=this.B;c=b;var d=-1;A(a)&&y(a,"sendCmd("+t(c)+")");switch(a.W||c){case 255:d=250;Sl(a);break;case 243:a.W&&(c=0);Tl(a,250);a.W=c;break;case 237:a.W&&(c=0);Tl(a,250);a.W=c;break;default:y(a,"sendCmd(): unrecognized command")}Ul(this,d)}}this.fa=b;this.N&=-9}; -m.Zk=function(a,b){var c=this.X&-209|(Wc(this.F)&64?16:0);x(this,a,null,b,"8042_RWREG",c,16384);return c};m.rm=function(a,b,c){x(this,a,b,c,"8042_RWREG",null,16384);Nl(this,b)};m.$k=function(a,b){x(this,a,null,b,"8042_STATUS",this.N,16384);var c=this.N&255;this.N&256&&(this.N|=1,this.N&=-257);return c}; -m.pm=function(a,b,c){x(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.fa=b;this.N|=8;a=0;240<=this.fa&&(a=this.fa^15,this.fa=240);switch(this.fa){case 32:Ul(this,this.aa);break;case 173:Ql(this,this.aa|16);break;case 174:Ql(this,this.aa&-17);this.B&&Pl(this.B);break;case 170:this.B&&(a=this.B,a.A=[],A(a)&&y(a,"scan codes flushed"));Ql(this,this.aa|16);Ul(this,85);Rl(this,3);break;case 171:Ul(this,0);break;case 192:Ul(this,this.ga);break;case 208:Ul(this,this.Ka);break;case 224:Ul(this,this.aa&16?0: +m.rm=function(a,b,c){x(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.N&8)switch(this.fa){case 96:Ql(this,b);break;case 209:Rl(this,b);break;default:if(Ql(this,this.aa&-17),this.B){a=this.B;c=b;var d=-1;A(a)&&y(a,"sendCmd("+t(c)+")");switch(a.W||c){case 255:d=250;Sl(a);break;case 243:a.W&&(c=0);Tl(a,250);a.W=c;break;case 237:a.W&&(c=0);Tl(a,250);a.W=c;break;default:y(a,"sendCmd(): unrecognized command")}Ul(this,d)}}this.fa=b;this.N&=-9}; +m.Zk=function(a,b){var c=this.X&-209|(Wc(this.F)&64?16:0);x(this,a,null,b,"8042_RWREG",c,16384);return c};m.sm=function(a,b,c){x(this,a,b,c,"8042_RWREG",null,16384);Nl(this,b)};m.$k=function(a,b){x(this,a,null,b,"8042_STATUS",this.N,16384);var c=this.N&255;this.N&256&&(this.N|=1,this.N&=-257);return c}; +m.qm=function(a,b,c){x(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.fa=b;this.N|=8;a=0;240<=this.fa&&(a=this.fa^15,this.fa=240);switch(this.fa){case 32:Ul(this,this.aa);break;case 173:Ql(this,this.aa|16);break;case 174:Ql(this,this.aa&-17);this.B&&Pl(this.B);break;case 170:this.B&&(a=this.B,a.A=[],A(a)&&y(a,"scan codes flushed"));Ql(this,this.aa|16);Ul(this,85);Rl(this,3);break;case 171:Ul(this,0);break;case 192:Ul(this,this.ga);break;case 208:Ul(this,this.Ka);break;case 224:Ul(this,this.aa&16?0: 1);break;case 240:a&1&&qe(this.F)}};function Ql(a,b){a.aa=b;a.N=a.N&-5|b&4;a.B&&Ol(a.B,!!(b&8),!(b&16))}function Ul(a,b,c){0<=b&&(a.Ja=b,c?a.N|=1:(a.N&=-2,a.N|=256))}function Rl(a,b){a.Ka=b;Rb(a.ea,!!(b&2));b&1||qe(a.F)}function Vl(a,b){a.ia=c?Ok(this,c):this.A[c];A(this,4352)&&x(this,a,null,b,"CMOS.DATA["+t(c)+"]",d,!0);null!=b&&12==c&&(this.A[c]&=15,d&128&&dg(this,8),d&64&&this.A[11]&64&&Yk(this));return d}; -m.Gm=function(a,b,c){var d=this.pa&63;A(this,4352)&&x(this,a,b,c,"CMOS.DATA["+t(d)+"]",null,!0);a=b^this.A[d];if(13>=d){if(c=b,10>d){var e=!1;this.A[11]&4||(c=10*(c>>4)+(c&15),e=!0);if(4==d||5==d)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;11==d&&a&64&&b&64&&Yk(this)};m.fk=function(a,b,c){x(this,a,b,c,"NMI");this.ya=b};m.Qm=function(a,b,c){x(this,a,b,c,"FPU.CLEAR")};m.Rm=function(a,b,c){x(this,a,b,c,"FPU.RESET");this.Tb&&Yf(this.Tb)}; -m.$l=function(a){if(A(this,16)&&kk(this.ha,26,a)){var b=this.F.G>>8;df(this.F,a,function(a,d){return function(e){d=Wc(a.F)-d;var f,g=a.F.M&255,h=a.F.M>>8,k=a.F.M&255,l=a.F.M>>8;if(2==b||3==b)f=" CH(hour)="+u(h)+" CL(min)="+t(g)+" DH(sec)="+t(l);else if(4==b||5==b)f=" CX(year)="+u(a.F.I)+" DH(month)="+t(l)+" DL(day)="+t(k);g=a.ha;h=d;g.message("INT "+t(26)+": C="+(pf(g.F)?1:0)+(f||"")+" (cycles="+h+(e?",level="+(e+1):"")+")")}}(this,Wc(this.F)))}return!0}; +m.Gm=function(a,b,c){x(this,a,b,c,"CMOS.ADDR",null,4096);this.pa=b;this.ya=b&128?0:128};m.ol=function(a,b){var c=this.pa&63,d=13>=c?Ok(this,c):this.A[c];A(this,4352)&&x(this,a,null,b,"CMOS.DATA["+t(c)+"]",d,!0);null!=b&&12==c&&(this.A[c]&=15,d&128&&dg(this,8),d&64&&this.A[11]&64&&Yk(this));return d}; +m.Hm=function(a,b,c){var d=this.pa&63;A(this,4352)&&x(this,a,b,c,"CMOS.DATA["+t(d)+"]",null,!0);a=b^this.A[d];if(13>=d){if(c=b,10>d){var e=!1;this.A[11]&4||(c=10*(c>>4)+(c&15),e=!0);if(4==d||5==d)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;11==d&&a&64&&b&64&&Yk(this)};m.fk=function(a,b,c){x(this,a,b,c,"NMI");this.ya=b};m.Rm=function(a,b,c){x(this,a,b,c,"FPU.CLEAR")};m.Sm=function(a,b,c){x(this,a,b,c,"FPU.RESET");this.Tb&&Yf(this.Tb)}; +m.am=function(a){if(A(this,16)&&kk(this.ha,26,a)){var b=this.F.G>>8;df(this.F,a,function(a,d){return function(e){d=Wc(a.F)-d;var f,g=a.F.M&255,h=a.F.M>>8,k=a.F.M&255,l=a.F.M>>8;if(2==b||3==b)f=" CH(hour)="+u(h)+" CL(min)="+t(g)+" DH(sec)="+t(l);else if(4==b||5==b)f=" CX(year)="+u(a.F.I)+" DH(month)="+t(l)+" DL(day)="+t(k);g=a.ha;h=d;g.message("INT "+t(26)+": C="+(pf(g.F)?1:0)+(f||"")+" (cycles="+h+(e?",level="+(e+1):"")+")")}}(this,Wc(this.F)))}return!0}; function ad(a,b){if(a.Fa)try{void 0!==b?a.Db=b:b=a.Db&&a.F&&a.F.la.Ib;var c=Math.round(1193181/Il(a,2));if(20>c||2E4>>4,0,this.L,this.C,this.Rd),delete this.Rd);return!0};Yl.prototype.hc=function(){return!0}; @@ -437,8 +437,8 @@ m.reset=function(){if(!this.B&&!this.V&&this.N){var a=1024*Tk(this.N);this.A&&a! 1]=c>>8;Xk(a)}}else w("No RAM allocated")};m.save=function(){var a=new hf(this);this.controller&&N(a,0,this.controller.save());return a.data()};m.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function em(a){this.N=a;this.C=gm;this.ha=hm;this.B=im;this.A=null}var fm=-2134900736,gm=65535,hm=2575,im=2,jm=[null,0],km=[function(a){return this.controller.Qa(a)},null,null,function(a,b){this.controller.qc(a,b)},null,null];m=em.prototype;m.save=function(){return[this.C,this.B]}; m.restore=function(a){this.qc(0,a[0]&255);this.qc(2,a[1]&255);return!0};m.Qa=function(a){var b=255;2>a?b=a&1?this.ha>>8:this.ha&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b};m.qc=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){var c=this.N.ea;if(b&1)this.A&&(Wb(c,917504,131072,this.A),this.A=null);else{this.A||(this.A=Xb(c,917504,131072));var d=Xb(c,16646144,131072);Wb(c,917504,131072,d,b&2?1:$b)}this.C=this.C&-256|b}};m.Ri=function(){return jm};m.fh=function(){return km}; Qa(function(){for(var a=nb(document,"pcjs","ram"),b=0;b":62,"?":63,"@":64,un:65,vn:66,wn:67,Bn:68,E:69,Cn:70,Fn:71,Gn:72,Hn:73,In:74,Jn:75,Kn:76,Ln:77,Nn:78,On:79,Pn:80,Q:81,Qn:82,Un:83,Zn:84,co:85,eo:86,fo:87,io:88,jo:89,ko:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,lo:97,mo:98,oo:99,d:100,e:101,po:102,qo:103,ro:104, -so:105,to:106,k:107,uo:108,vo:109,n:110,xo:111,p:112,q:113,r:114,yo:115,t:116,Ao:117,Bo:118,Co:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126},om={};om[186]=X[";"];om[187]=X["="];om[188]=X[","];om[189]=X["-"];om[190]=X["."];om[191]=X["/"];om[192]=X["`"];om[219]=X["["];om[220]=X["\\"];om[221]=X["]"];om[222]=X["'"];om[173]=X["-"];var pm={};pm[X["1"]]=X["!"];pm[X["2"]]=X["@"];pm[X["3"]]=X["#"];pm[X["4"]]=X.$;pm[X["5"]]=X["%"];pm[X["6"]]=X["^"];pm[X["7"]]=X["&"];pm[X["8"]]=X["*"];pm[X["9"]]=X["("]; +var nm=["US83","US84","US101"],X={zn:1,An:3,Bn:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,vn:65,wn:66,xn:67,Cn:68,E:69,Dn:70,Gn:71,Hn:72,In:73,Jn:74,Kn:75,Ln:76,Mn:77,On:78,Pn:79,Qn:80,Q:81,Rn:82,Vn:83,$n:84,eo:85,fo:86,ho:87,jo:88,ko:89,lo:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,mo:97,no:98,po:99,d:100,e:101,qo:102,ro:103,so:104, +to:105,uo:106,k:107,vo:108,wo:109,n:110,yo:111,p:112,q:113,r:114,zo:115,t:116,Bo:117,Co:118,Do:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126},om={};om[186]=X[";"];om[187]=X["="];om[188]=X[","];om[189]=X["-"];om[190]=X["."];om[191]=X["/"];om[192]=X["`"];om[219]=X["["];om[220]=X["\\"];om[221]=X["]"];om[222]=X["'"];om[173]=X["-"];var pm={};pm[X["1"]]=X["!"];pm[X["2"]]=X["@"];pm[X["3"]]=X["#"];pm[X["4"]]=X.$;pm[X["5"]]=X["%"];pm[X["6"]]=X["^"];pm[X["7"]]=X["&"];pm[X["8"]]=X["*"];pm[X["9"]]=X["("]; pm[X["0"]]=X[")"];pm[186]=X[":"];pm[187]=X["+"];pm[188]=X["<"];pm[189]=X._;pm[190]=X[">"];pm[191]=X["?"];pm[192]=X["~"];pm[219]=X["{"];pm[220]=X["|"];pm[221]=X["}"];pm[222]=X['"'];pm[173]=X._;pm[61]=X["+"];pm[59]=X[":"]; var qm={3016:1,1016:2,1017:8,1018:32,1091:128,1093:64,1224:128,1020:512,1144:1024,1145:2048},rm={TAB:1009,ESC:1027,F1:1112,F2:1113,F3:1114,F4:1115,F5:1116,F6:1117,F7:1118,F8:1119,F9:1120,F10:1121,LEFT:1037,UP:1038,RIGHT:1039,DOWN:1040,SYSREQ:4027,CTRL_C:4003,CTRL_BREAK:4008,CTRL_ALT_DEL:4046,CTRL_ALT_INS:4045,CTRL_ALT_ENTER:4013},sm={esc:1027,1:X["1"],2:X["2"],3:X["3"],4:X["4"],5:X["5"],6:X["6"],7:X["7"],8:X["8"],9:X["9"],0:X["0"],"-":X["-"],"=":X["="],bs:1008,tab:1009,q:81,w:87,e:69,r:82,t:84,y:89, u:85,i:73,o:79,p:80,"[":X["["],"]":X["]"],enter:13,ctrl:1017,a:65,s:83,d:68,f:70,g:71,h:72,j:74,k:75,l:76,";":X[";"],quote:X["'"],"`":X["`"],shift:1016,"\\":X["\\"],z:90,x:88,c:67,v:86,b:66,n:78,m:77,",":X[","],".":X["."],"/":X["/"],"right-shift":3016,prtsc:1044,alt:1018,space:1032,"caps-lock":1020,f1:1112,f2:1113,f3:1114,f4:1115,f5:1116,f6:1117,f7:1118,f8:1119,f9:1120,f10:1121,"num-lock":1144,"scroll-lock":1145,"num-home":1036,"num-up":1038,"num-pgup":1033,"num-sub":1109,"num-left":1037,"num-center":1101, @@ -460,7 +460,7 @@ function Dm(a,b,c){var d=b;if(65<=b&&90>=b)!(a.xc&515)==c&&(d=b+32);else if(97<= function um(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode,h=Dm(a,g,!0);a.ah&&h==X["`"]&&(g=h=27);if(Y[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),wm(a,h,!1,c)){if(20==g||144==g||145==g)a.pa||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;k=b||97<=b&&122>=b;e>>>=8;){var g=0,h=e&255;224==f||225==f?d.push(f|(c?0:128)):(42==h?a.C&3||a.C&512&&b||(g=h):29==h?a.C&12||(g=h):56==h?a.C&48||(g=h):d.push(f|(c?0:128)),g&&(c?d.unshift(g):d.push(g|128)))}for(c=0;ce.A.length?(A(e)&&y(e,"scan code "+t(f)+" buffered"),e.A.push(f),1== e.A.length&&e.N&&Vl(e.N,f)):(20==e.A.length&&e.A.push(255),y(e,"scan code buffer overflow")));d=!0}return d}Qa(function(){for(var a=nb(document,"pcjs","keyboard"),b=0;bc.length)c=[!1,0,null,null,0,Array(5>b?Vm:Wm)];this.ha=a.ha;this.type=e[0];this.port=e[1];this.Ua=b;this.ob=e[2];this.ac=e[3];this.Ed=d||e[4];65536<=this.Ed&&720896<=this.ob&&(this.ac=Math.min(this.Ed>>2,32768));this.Hc=c[0];this.gd=c[1];this.sf=c[2];this.ma=c[3];this.Ac=c[4]&255;this.Ig=c[4]>>8&255;this.mb=c[5];this.mh=Vm;this.jg=Xm;if(5<=b){this.mh=Wm;this.jg=Ym;b=c[6];void 0===b&&(b=[!1,0,Array(20), 0,3==f?0:1,0,0,Array(5),0,0,0,Array(9),0,[this.ob,this.ac,this.Ed],Array(this.Ed>>2),-2147478512,0,-1,0,-1,0,-1,0,0,0,0,1,255,0,0,0,Array(256)]);this.Xe=b[0];this.Od=b[1];this.Tc=b[2];this.Sg=Zm;this.Lg=b[3];this.uf=b[4];this.dg=b[5];this.ce=b[6];this.Je=b[7];this.Ug=$m;this.gk=b[8];this.hk=b[9];this.be=b[10];this.ae=b[11];this.Tg=an;this.Fb=b[12];d=b[13];"number"==typeof d&&(d=[this.ob,this.ac,d]);this.ob=d[0];this.ac=d[1];d=this.Ed>>2;if((this.sd=b[14])&&this.sd.length>this.controller.ci&255};cn[17408]=function(a){return(this.controller.Fb=this.da[(a&-4)+this.C])>>((a&3)<<3)&255};cn[5120]=function(a){a+=this.C;var b=this.controller.Fb=this.da[a&-2];return(a&1?b>>8:b)&255};cn[1280]=function(a){a+=this.C;a=this.controller.Fb=this.da[a];for(var b=this.controller.oh,c=this.controller.nh&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d}; @@ -496,9 +496,9 @@ b.Od),b.ha.O(" ATCDATA: "+b.Xe),en(b," FEAT",b.dg),en(b," MISC",b.uf),en(b m.Qb=function(a,b,c){var d=this;if(!this.qa[b])switch(this.qa[b]=c,b){case "fullScreen":return this.ga&&this.ga.We?c.onclick=function(){d.We()}:c.parentNode.removeChild(c),!0;case "lockPointer":return this.uk=c.textContent,this.V&&this.V.De?c.onclick=function(){d.De(!0)}:c.parentNode.removeChild(c),!0;case "refresh":return c.onclick=function(){qn(d,!0)},!0}return!1}; m.We=function(){var a=!1;if(this.ga){if(this.ga.We){a="100%";if(screen&&screen.width&&screen.height){var b=screen.width/screen.height,c=this.ra/this.Ea;b>c&&(a=Math.round(c/b*100)+"%")}this.qf?(this.ka.style.width=a,this.ka.style.width=a,this.ka.style.display="block",this.ka.style.margin="auto"):(this.ga.style.width=a,this.ga.style.height="auto");this.ga.style.backgroundColor="black";this.ga.We();a=!0}this.V&&this.V.focus()}return a}; function Hm(a,b){!b&&a.ga&&(a.qf?a.ka.style.width=a.ka.style.height="":a.ga.style.width=a.ga.style.height="");y(a,"notifyFullScreen("+b+")",!0);a.B&&(a.B.ah=b)}m.De=function(a){var b=!1;this.V&&(a?this.V.De&&(this.V.De(),this.W&&this.W.Vf(!0),b=!0):this.V.rk&&(this.V.rk(),this.W&&this.W.Vf(!1),b=!0),this.V&&this.V.focus());return b};m.Vf=function(a){this.W&&(this.W.Vf(a),this.B&&(this.B.ah=a));var b=this.qa.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.uk)}; -function pn(a,b){var c=a.V;c&&!a.me&&(c.addEventListener("touchstart",function(b){rn(a,b,!0)},!1),c.addEventListener("touchmove",function(b){rn(a,b)},!0),c.addEventListener("touchend",function(b){rn(a,b,!1)},!1),a.me=b,a.uc=a.Cc=a.gg=-1,a.Id=!1,a.Xc=null,a.Hd=!1,a.tn=function(){a.Hd=!0;a.W.je(sn,!0)})}m.Fg=function(a){this.B&&this.B.Fg(a)}; +function pn(a,b){var c=a.V;c&&!a.me&&(c.addEventListener("touchstart",function(b){rn(a,b,!0)},!1),c.addEventListener("touchmove",function(b){rn(a,b)},!0),c.addEventListener("touchend",function(b){rn(a,b,!1)},!1),a.me=b,a.uc=a.Cc=a.gg=-1,a.Id=!1,a.Xc=null,a.Hd=!1,a.un=function(){a.Hd=!0;a.W.je(sn,!0)})}m.Fg=function(a){this.B&&this.B.Fg(a)}; function rn(a,b,c){var d,e,f=0,g=0;e=a.ka;do isNaN(e.offsetLeft)||(f+=e.offsetLeft,g+=e.offsetTop);while(e=e.offsetParent);var h=a.ra/a.ka.offsetWidth,k=a.Ea/a.ka.offsetHeight;b.targetTouches&&b.targetTouches.length?(d=b.targetTouches[0].pageX,e=b.targetTouches[0].pageY):(d=b.pageX,e=b.pageY);d=(d-f)*h;e=(e-g)*k;if(1==a.me)d=d/(a.ra/3)|0,e=e/(a.Ea/3)|0,1!=e?e?vm(a.B,1040,!0):vm(a.B,1038,!0):1!=d&&(d?vm(a.B,1039,!0):vm(a.B,1037,!0));else if(a.W){g=a.Id;f=b.timeStamp-a.gg;!0===c?(a.Id=500f){a.W.je(sn,!0);a.W.je(sn,!1);return}}if(c||0>a.uc||0>a.Cc)a.uc=d,a.Cc=e;c=Math.round(d-a.uc);b=Math.round(e-a.Cc);a.uc=d;a.Cc=e;a.W.Hf(c,b,a.uc,a.Cc)}}m.ic=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};m.hc=function(a){return a?this.save():!0}; +a.Xc=setTimeout(a.un,500)):null!=a.Xc&&(clearTimeout(a.Xc),a.Xc=null);void 0===c&&(a.Id=!1);g||b.preventDefault();if(!1===c){a.Hd?(a.W.je(sn,!1),a.Hd=!1,b=!0):b=!1;if(b)return;if(200>f){a.W.je(sn,!0);a.W.je(sn,!1);return}}if(c||0>a.uc||0>a.Cc)a.uc=d,a.Cc=e;c=Math.round(d-a.uc);b=Math.round(e-a.Cc);a.uc=d;a.Cc=e;a.W.Hf(c,b,a.uc,a.Cc)}}m.ic=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};m.hc=function(a){return a?this.save():!0}; m.reset=function(){var a=!0,b=0;this.N&&(b=+Uk(this.N,wk,void 0));this.ia||(this.Ua=3==b?1:3);this.wa=3;switch(this.Ua){case cm:b=7;break;case 5:var c=Km[this.Vc];c&&(b=c[0]);b||(b=4);break;case 1:b=3;this.wa=7;break;default:b=2}this.ya!==b&&(this.ya=b,a=!0);this.C=null;this.pa=this.rd=new Tm(this,1);this.aa=this.Wc=new Tm(this,3);5>this.Ua?this.A=new Tm:(this.A=new Tm(this,this.Ua,null,this.Ed),tn(this));un(this);this.Ia=null;this.cb=this.ua=-1;this.Pa=0;vn(this,this.wa);if(this.C.ob&&a){a=this.C.ob+ this.Ub;for(b=this.C.ob;b>1&255,d=d>>8&-129,d>>4==(d&15)&&(d^=15)):(c=d&255,d=(d&256?7:112)|8&d>>8);fc(this.ea,b,c|d<<8)}qn(this,!0)}};function tn(a){a.A.uf&1?(a.pa=a.rd,a.aa=a.A):(a.pa=a.A,a.aa=a.Wc)}m.save=function(){var a=new hf(this);N(a,0,dn(this.rd));N(a,1,dn(this.Wc));N(a,2,[this.ya,this.wa,this.Ia]);N(a,3,dn(this.A));return a.data()}; m.restore=function(a){var b=a[2];this.ya=b[0];this.wa=b[1];this.Ia=b[2];this.C=null;this.pa=this.rd=new Tm(this,1,a[0]);this.aa=this.Wc=new Tm(this,3,a[1]);this.A=new Tm(this,this.Ua,a[3],this.Ed);this.A.Hc&&tn(this);un(this);if(!wn(this))return!1;xn(this);return!0}; @@ -506,8 +506,8 @@ function Im(a,b,c,d){if(d)a.Oa("Unable to load font ROM (error "+d+": "+b+")");e function yn(a,b){if(1==b)return a.Ca[0]=Nm[0],a.Ca[1]=Nm[7],a.Ca;if(2==b){var c=a.C.sf;if(a.C===a.A){var d=a.A.Tc[0],c=d&7;d&16&&(c|=8);18!=a.A.Tc[1]&&(c|=32)}a.Ca[0]=Nm[c&15];c=c&32?Pm:Om;for(d=0;df;f++)g=d[f]||0,h=g<<2&252,k=g>>4&252,g=g>>10&252,a.Ca[f]=[h,k,g,255];else{var l=d&&d[255];e=null!=c.Tc[15]?c.Tc:Qm;for(f=0;16>f;f++)g=e[f]&63,l?(g|= (c.Tc[20]&12)<<4,c.Tc[16]&128&&(g&=-49,g|=(c.Tc[20]&3)<<4),g=d[g],h=g<<2&252,k=g>>4&252,g=g>>10&252):(h=(g&4?170:0)|(g&32?85:0),k=(g&2?170:0)|(g&16?85:0),g=(g&1?170:0)|(g&8?85:0)),a.Ca[f]=[h,k,g,255]}a.rb=!0}return a.Ca}function bm(a,b,c,d){a.Uc=b;a.Jb=c;a.Tb=d} function un(a,b){var c=!1;if(window&&a.Uc&&(!b||a.U)){var d=0,e=a.Tb?a.Tb:8,f=yn(a);null!=a.Jb[0]&&zn(a,3,a.Jb[0],d,e,8,a.Uc,f)&&(c=!0);d=a.Tb?0:2048;e=a.Tb?a.Tb:9;null!=a.Jb[1]&&(zn(a,1,a.Jb[1],d,e,14,a.Uc,Lm,Mm)&&(c=!0),a.Tb&&zn(a,a.Ua,a.Jb[1],0,a.Tb,14,a.Uc,f)&&(c=!0))}return c}function zn(a,b,c,d,e,f,g,h,k){var l=!1;null!=c&&(An(a,b,c,d,e,f,g,h,k)&&(l=!0),a.pi&&An(a,b<<1,c,d,e,f,g,h,k)&&(l=!0));return l} -function An(a,b,c,d,e,f,g,h,k){var l=!1,n=b&1?0:1,q=a.Na[b],p=16>h.length?h.length:16;q||(q={Qc:e<V||!H?V:8,wa=ja.createImageData(l.Qc,l.Rc),Ha=0;256>Ha;Ha++){for(Ba= -0;Ba=V-2,Rc=P[Ba>(8<=Xa&&192<=Ha&&223>=Ha?7:Xa)?z:bb;Bn(wa,Ie,Xd,Je);v&&Bn(wa,Ie+1,Xd,Je)}ja.putImageData(wa,(Ha&15)*l.Qc,(Ha>>4)*l.Rc)}l.Oe[F]="#"+r(z[0],2)+r(z[1],2)+r(z[2],2);l.si[F]=z;l.Rg[F]=ia;l=!0}}a.Na[b]=q;return l}function Cn(a){0a.cb&&(a.cb=0):a.cb=-1} +function An(a,b,c,d,e,f,g,h,k){var l=!1,n=b&1?0:1,q=a.Na[b],p=16>h.length?h.length:16;q||(q={Qc:e<V||!H?V:8,wa=ja.createImageData(l.Qc,l.Rc),Ha=0;256>Ha;Ha++){for(Ba= +0;Ba=V-2,Rc=P[Ba>(8<=Xa&&192<=Ha&&223>=Ha?7:Xa)?z:bb;Bn(wa,Ie,Xd,Je);v&&Bn(wa,Ie+1,Xd,Je)}ja.putImageData(wa,(Ha&15)*l.Qc,(Ha>>4)*l.Rc)}l.Oe[F]="#"+r(z[0],2)+r(z[1],2)+r(z[2],2);l.si[F]=z;l.Rg[F]=ia;l=!0}}a.Na[b]=q;return l}function Cn(a){0a.cb&&(a.cb=0):a.cb=-1} function xn(a){if(a.U){for(var b=10;15>=b;b++)if(null==a.C.mb[b])return;var c=a.C.mb[10],b=c&31,d=a.C.mb[11]&31,e=a.C.mb[9]&31,f=!1;a.C===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)ao(a);else{c=a.C.mb[15]+((a.C.mb[14]&63)<<8);a.ua!=c&&(ao(a),a.ua=c);d=d-b+1;if(a.hg!=b||a.Ce!=d)a.hg=b,a.Ce=d;a.$a=e+1;Cn(a)}}} function ao(a){if(0<=a.ua){if(void 0!==a.fa){var b=a.fa[a.ua];if(b&131072){var b=b&-131073,c=a.ua%a.L,d=a.ua/a.L|0;a.U&&a.Na[a.U]&&(a.gb&&bo(a,c,d,b,a.gb),bo(a,c,d,b));a.fa[a.ua]=b}}a.ua=-1}} function co(a){var b,c=a.C;a.gf=!1;var d=c.ae[5];if(null!=d){b=1024;var e=0,f=c.ae[3]&31;switch(d&3){case 0:if(f){e=32;switch(f&24){case 8:e=96;break;case 16:e=160;break;case 24:e=224}c.dd=f&7}break;case 1:e=1;break;case 2:switch(f&24){default:e=2;break;case 8:e=98;break;case 16:e=162;break;case 24:e=226}break;case 3:a.Ua==cm&&(e=3,c.dd=f&7)}d&8&&(b=1280);c=c.Je[4];null!=c&&(c&4||(b|=4096,e|=16),d&64&&(c&8&&(b|=16384,e|=4),a.gf=!0));b|=e}return b} @@ -515,7 +515,7 @@ function eo(a,b){var c=a.C;return c&&null!=b&&b!=c.vg?(c.Mg(b),a.ea.Mg(c.ob,c.ac function wn(a,b){var c,d=a.Ia,e=a.C;if(e)if(1==e.Ua)d=7;else if(5<=e.Ua){var d=null,f=e.Ed>>2,g=32768=e.mb[18]?19:20:21:g&128||350>f?d= l?13:14:480<=f&&(d=3==a.ya?17:18):d=l?7-d:6:d-=l?2:0);c=co(a)}}else e.gd&8&&(e.gd&2?(d=e.gd&16?6:5,e.gd&4||--d):(d=e.gd&1?3:1,e.gd&4&&--d));else a.Ia=null,null==d&&(d=a.wa);if(!vn(a,d,b))return!1;eo(a,c);return!0} function vn(a,b,c){if(null!=b&&(b!=a.Ia||c)){a.Ng=0;a.Ia=b;a.rb=!1;b=a.C||(7==b?a.pa:a.aa);if(b!=a.C||b.ob!=a.ob||b.ac!=a.ac){ao(a);if(a.ob){if(!Zb(a.ea,a.ob,a.ac))return!1;a.C&&(a.C.Hc=!1)}a.C=b;b.Hc=!0;a.ob=b.ob;a.ac=b.ac;if(!Sb(a.ea,b.ob,b.ac,3,b===a.A?b:null))return!1}a:{a.U=0;a.L=a.kd;a.X=a.le;a.Db=a.L;a.jd=Fm[7][2];b=0;if(c=Fm[a.Ia])a.L=c[0],a.X=c[1],a.jd=c[2],b=c[3],a.U=c[4],4!=a.ya&&7!=a.ya||a.C!==a.A||3!=a.U||(7==(a.A.mb[9]&31)?a.X=350>fn(a.A,18)?43:50:a.U=a.Ua);a.Yf=a.L*a.X|0;a.Wf=a.Yf/ -a.jd|0;a.Ub=a.Wf;a.td=0;void 0!==b&&(a.Ub=(a.Ub<<1)+b|0,a.td=a.Ub+b>>1);if(a.Na.length){a.Ja=a.ra/a.L|0;a.Ka=a.Ea/a.X|0;if(a.U){b=a.Na[a.U];if(!b)break a;c=a.Na[a.U<<1];a.sn&&80==a.L?c&&a.Ja>=3*c.Qc>>2&&(a.U<<=1,b=c):(c&&a.Ja>=c.Qc&&(a.U<<=1,b=c),b&&(a.Ja=b.Qc,a.Ka=b.Rc));a.bc=a.tc=0;b&&(a.bc=a.L*b.Qc,a.tc=a.X*b.Rc)}else a.Ja=a.Ka=1,a.bc=a.L,a.tc=a.X;a.sb=a.ja.createImageData(a.bc,a.tc);a.fb=document.createElement("canvas");a.fb.width=a.bc;a.fb.height=a.tc;a.gb=a.fb.getContext("2d");a.ne=a.oe=0;a.Dd= +a.jd|0;a.Ub=a.Wf;a.td=0;void 0!==b&&(a.Ub=(a.Ub<<1)+b|0,a.td=a.Ub+b>>1);if(a.Na.length){a.Ja=a.ra/a.L|0;a.Ka=a.Ea/a.X|0;if(a.U){b=a.Na[a.U];if(!b)break a;c=a.Na[a.U<<1];a.tn&&80==a.L?c&&a.Ja>=3*c.Qc>>2&&(a.U<<=1,b=c):(c&&a.Ja>=c.Qc&&(a.U<<=1,b=c),b&&(a.Ja=b.Qc,a.Ka=b.Rc));a.bc=a.tc=0;b&&(a.bc=a.L*b.Qc,a.tc=a.X*b.Rc)}else a.Ja=a.Ka=1,a.bc=a.L,a.tc=a.X;a.sb=a.ja.createImageData(a.bc,a.tc);a.fb=document.createElement("canvas");a.fb.width=a.bc;a.fb.height=a.tc;a.gb=a.fb.getContext("2d");a.ne=a.oe=0;a.Dd= a.ra;a.Gd=a.Ea;b=a.ra-a.L*a.Ja;c=a.Ea-a.X*a.Ka;0>1,a.Dd-=b);0>1,a.Gd-=c);if(b||c)a.ja.fillStyle=a.ka.style.backgroundColor,a.ja.fillRect(0,0,a.ra,a.Ea)}}fo(a,!0);qn(a)}return!0}function Bn(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function go(a){a.Pa=-1;a.Fa=!1;var b=a.Wf;if(void 0===a.fa||a.fa.length!=b)a.fa=Array(b)}function fo(a,b){b||(a.rb=!1);go(a)} function bo(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.Na[a.U];h.zf&&(d=h.zf[d]);var k=g>>4&15;h.zf&&(k=h.zf[k]);e?(b*=h.Qc,c*=h.Rc,e.fillStyle=h.Oe[k],e.fillRect(b,c,h.Qc,h.Rc)):(b=b*a.Ja+a.ne,c=c*a.Ka+a.oe,a.ja.fillStyle=h.Oe[k],a.ja.fillRect(b,c,a.Ja,a.Ka));g&256&&(k=(f&15)*h.Qc,f=(f>>4)*h.Rc,e?e.drawImage(h.Rg[d],k,f,h.Qc,h.Rc,b,c,h.Qc,h.Rc):a.ja.drawImage(h.Rg[d],k,f,h.Qc,h.Rc,b,c,a.Ja,a.Ka));g&512&&(f=a.hg,g=a.Ce,e?(a.$a&&a.$a!==h.Rc&&(f=f*h.Rc/a.$a|0,g=g*h.Rc/a.$a|0),e.fillStyle=h.Oe[d], e.fillRect(b,c+f,h.Qc,g)):(a.$a&&a.$a!==a.Ka&&(f=f*a.Ka/a.$a|0,g=g*a.Ka/a.$a|0),a.ja.fillStyle=h.Oe[d],a.ja.fillRect(b,c+f,a.Ja,g)))} @@ -524,38 +524,38 @@ function qn(a,b){if(a.la.cc){var c=!1,d=a.C;d&&(d!==a.A?d.gd&8&&(c=!0):d.Od&32&& a.fa[d]=n,f++),c+=2,d++;a.Fa=!0;f&&a.gb&&a.ja.drawImage(a.fb,0,0,a.bc,a.tc,a.ne,a.oe,a.Dd,a.Gd);Cn(a)}}else if(a.td){for(var g=k,z,k=c,d=a.Pa=0,f=a.jd,e=16==f?65536:196608,h=16==f?1:2,l=yn(a,h),q=n=0,p=a.L,F=0,v=a.X,E=0;k>8|(z&255)<<8;var H=e,L=16;n>=h))>>(L-=h);Bn(a.sb,n++,q,l[P])}n>F&&(F=n);q=E&&(E=q+1)}k+=2;d++;if(n>=a.L){n=0;q+=2;if(q>a.X)break;q==a.X&&(q=1,k=c+a.td)}}a.Fa=!0; pa.L?a.Db-a.L-z>>3:0;c>=8;l>p&&(p=l);n=v&&(v=n+1)}c+=E;if(l>=a.L){l=0;if(++n>a.X)break;c+=H}}z||(a.Fa=!0);qa.L?a.Db-a.L-v>>3:0;cH&&(L=H)):(z<<=v,L-=v,a.Fa=!1):(a.Fa&&z===a.fa[d]?(h+=L,L=0):a.fa[d]=z,d++);if(L){hq&&(q=h);l=F&&(F=l+1)}if(h>=a.L){h=0;if(++l>a.X)break;c+=E}}v||(a.Fa=!0);nd&&(b.uh=d,d=-d|0);d%b.ph>b.im&&(c|=1);d%b.sh>b.km&&(c|=9);b.di=d/b.sh|0;return c}m.Fl=function(a,b){return io(this,this.pa,a,b)};m.$m=function(a,b,c){var d=this.pa;d.Ig=d.Ac;d.Ac=b&31;x(this,a,b,c,"CRTC.INDX")};m.El=function(a,b){return jo(this,this.pa,a,b)};m.Zm=function(a,b,c){ko(this,this.pa,a,b,c)};m.Gl=function(a,b){return lo(this,this.pa,b)};m.an=function(a,b,c){a=this.pa;x(this,a.port+4,b,c,"MODE");a.gd=b;wn(this,!1)}; -m.Hl=function(a,b){return mo(this,this.pa,b)};m.ek=function(a,b,c){this.A.dg=this.A.dg&-4|b&3;x(this,a,b,c,"FEAT")};m.el=function(a,b){var c=this.A.Od;b&&!A(this)||x(this,960,null,b,"ATC.INDX",c);return c};m.Ck=function(a,b){var c=this.A.Tc[this.A.Od&31];b&&!A(this)||x(this,960,null,b,"ATC."+this.A.Sg[this.A.Od&31],c);return c}; +0,0,a.L,a.X,0,0,a.ra,a.Ea))}}}}function ho(a,b){var c=0,d=Wc(a.F)-b.uh;0>d&&(b.uh=d,d=-d|0);d%b.ph>b.jm&&(c|=1);d%b.sh>b.lm&&(c|=9);b.di=d/b.sh|0;return c}m.Gl=function(a,b){return io(this,this.pa,a,b)};m.an=function(a,b,c){var d=this.pa;d.Ig=d.Ac;d.Ac=b&31;x(this,a,b,c,"CRTC.INDX")};m.Fl=function(a,b){return jo(this,this.pa,a,b)};m.$m=function(a,b,c){ko(this,this.pa,a,b,c)};m.Hl=function(a,b){return lo(this,this.pa,b)};m.bn=function(a,b,c){a=this.pa;x(this,a.port+4,b,c,"MODE");a.gd=b;wn(this,!1)}; +m.Il=function(a,b){return mo(this,this.pa,b)};m.ek=function(a,b,c){this.A.dg=this.A.dg&-4|b&3;x(this,a,b,c,"FEAT")};m.el=function(a,b){var c=this.A.Od;b&&!A(this)||x(this,960,null,b,"ATC.INDX",c);return c};m.Ck=function(a,b){var c=this.A.Tc[this.A.Od&31];b&&!A(this)||x(this,960,null,b,"ATC."+this.A.Sg[this.A.Od&31],c);return c}; m.dk=function(a,b,c){var d=this.A,e=d.Od&32;if(d.Xe){d.Xe=!1;var f=d.Od&31;if(16<=f||!e)c&&!A(this)||x(this,a,b,c,"ATC."+d.Sg[f]),d.Tc[f]=b,fo(this,!1)}else d.Od=b,x(this,a,b,c,"ATC.INDX"),d.Xe=!0,b&32&&!e&&un(this,!0)&&qn(this,!0),a=(d.mb[12]<<8)+d.mb[13]|0,d.Md!=a&&(d.Md=a,fo(this)),d.pf=0}; -m.Rl=function(a,b){var c=0;if(5==this.Ua)c=3-((this.A.uf&12)>>2),c=(this.Vc&1<>this.A.Kc&63;b&&!A(this)||x(this,969,null,b,"DAC.DATA["+t(this.A.pd)+"]["+t(this.A.Kc)+"]",c);this.A.Kc+=6;12>2),c=(this.Vc&1<>this.A.Kc&63;b&&!A(this)||x(this,969,null,b,"DAC.DATA["+t(this.A.pd)+"]["+t(this.A.Kc)+"]",c);this.A.Kc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=ya().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= (a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());c.appendChild(e);var f=document.createElement("textarea");Ga("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"));c.appendChild(f);var g=e.getContext("2d"),d=new Z(d,e,g,f,c);mb(d,c)}}); function no(a){this.W=a.adapter;switch(this.W){case 1:this.V=956;this.C=7;break;case 2:this.V=888;this.C=7;break;case 3:this.V=632;this.C=5;break;default:w("Unrecognized parallel adapter #"+this.W);return}this.A=this.B=null;Ua.call(this,"ParallelPort",a,no,4194304);a=a.binding;"console"==a?this.B="":kb(this,a,oo)}db(no);var oo="buffer";m=no.prototype;m.Qb=function(a,b,c){switch(b){case oo:return this.qa[b]=this.A=c,!0}return!1}; m.Ic=function(a,b,c,d){this.ea=b;this.F=c;this.ha=d;this.N=Eb(a,"ChipSet");hc(b,this,po,this.V);lc(b,this,qo,this.V);rb(this)};m.ic=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};m.hc=function(a){return a?this.save():!0};m.reset=function(){ro(this)};m.save=function(){var a=new hf(this),b=0,c=[];c[b++]=this.L;c[b++]=this.Yb;c[b]=this.Bf;N(a,0,c);return a.data()};m.restore=function(a){return ro(this,a[0])}; -function ro(a,b){var c=0;void 0===b&&(b=[0,0,0]);a.L=b[c++];a.Yb=b[c++];a.Bf=b[c];return!0}m.tl=function(a,b){var c=this.L;x(this,a,null,b,"DATA",c);return c};m.Ql=function(a,b){var c=this.Yb;x(this,a,null,b,"STAT",c);return c};m.pl=function(a,b){var c=this.Bf;x(this,a,null,b,"CTRL",c);return c}; -m.Mm=function(a,b,c){x(this,a,b,c,"DATA");this.L=b;this.Yb|=64;if(this.A)8==b?this.A.value=this.A.value.slice(0,-1):(this.A.value+=String.fromCharCode(b),this.A.scrollTop=this.A.scrollHeight),a=!0;else if(null!=this.B){if(10==b||1024<=this.B.length)this.O(this.B),this.B="";10!=b&&(this.B+=String.fromCharCode(b));a=!0}else a=!1;a&&(this.Yb&=-65);so(this)};m.Hm=function(a,b,c){x(this,a,b,c,"CTRL");this.Bf=b;so(this)};function so(a){a.N&&a.C&&(a.Bf&16&&!(a.Yb&64)?eg(a.N,a.C):dg(a.N,a.C))} -var po={0:no.prototype.tl,1:no.prototype.Ql,2:no.prototype.pl},qo={0:no.prototype.Mm,2:no.prototype.Hm};Qa(function(){for(var a=nb(document,"pcjs","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64>8:this.ja;x(this,a,null,b,this.B&128?"DLM":"IER",c);return c};m.Al=function(a,b){var c=this.L;x(this,a,null,b,"IIR",c);return c}; -m.Bl=function(a,b){var c=this.B;x(this,a,null,b,"LCR",c);return c};m.Dl=function(a,b){var c=this.C;x(this,a,null,b,"MCR",c);return c};m.Cl=function(a,b){var c=this.A;x(this,a,null,b,"LSR",c);return c};m.Il=function(a,b){var c=this.ua;x(this,a,null,b,"MSR",c);return c}; -m.jn=function(a,b,c){x(this,a,b,c,this.B&128?"DLL":"THR");if(this.B&128)this.aa=this.aa&-256|b;else{this.wa=b;this.A&=-97;if(this.V)13==b?this.X=0:8==b?(this.V.value=this.V.value.slice(0,-1),0>8:this.ja;x(this,a,null,b,this.B&128?"DLM":"IER",c);return c};m.Bl=function(a,b){var c=this.L;x(this,a,null,b,"IIR",c);return c}; +m.Cl=function(a,b){var c=this.B;x(this,a,null,b,"LCR",c);return c};m.El=function(a,b){var c=this.C;x(this,a,null,b,"MCR",c);return c};m.Dl=function(a,b){var c=this.A;x(this,a,null,b,"LSR",c);return c};m.Jl=function(a,b){var c=this.ua;x(this,a,null,b,"MSR",c);return c}; +m.kn=function(a,b,c){x(this,a,b,c,this.B&128?"DLL":"THR");if(this.B&128)this.aa=this.aa&-256|b;else{this.wa=b;this.A&=-97;if(this.V)13==b?this.X=0:8==b?(this.V.value=this.V.value.slice(0,-1),0d&&a.V&&!a.V.la.cc;if(a.qg)d?a.controller.Oa('Unable to connect to disk "'+a.W+'" (error '+d+": "+c+")",f):(a.N=!0,fp(a),e=a);else if(d)a.controller.Oa('Unable to load disk "'+a.ea+'" (error '+d+": "+b+")",f);else{fb(a.controller.ve,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+c+")");if(h.length)if(1==h.length)w(h[0]);else{a.Bb=h.length;a.ub=h[0].length;a.lb=h[0][0].length;var k=h[0][0][0];a.Va=k&&k.length||512;for(d=c=0;d>2,n=k.pattern;void 0===n&&(n=k.pattern=0);var q=k.data;if(void 0===q){var p=k.bytes;if(void 0!==p&&p.length){for(var z= l<<2,F=p.length;Fb;b++){if(128==Zo(a,e,c+0,1)){d.Zf=Zo(a,e,c+8,4);(e=Yo(a,d.Zf))&&(f=!0);break}c+=16}if(!f)return}d.Gf||(d.Gf=Zo(a,e,19,2)||Zo(a,e,32,4),d.Ff=Zo(a,e,14,2),d.jh=d.Ff+Zo(a,e,22,2)*Zo(a,e,16,1),d.th=Zo(a,e,17,2),d.xg=Zo(a,e,13,1));d.hh=d.jh+((32*d.th+(d.Va-1))/d.Va|0);d.hm=(d.Gf-d.hh)/d.xg|0;d.zg=4084>=d.hm?12:16;d.Sk=12==d.zg?4086:65526;b=[];for(e=d.jh;eb;b++){if(128==Zo(a,e,c+0,1)){d.Zf=Zo(a,e,c+8,4);(e=Yo(a,d.Zf))&&(f=!0);break}c+=16}if(!f)return}d.Gf||(d.Gf=Zo(a,e,19,2)||Zo(a,e,32,4),d.Ff=Zo(a,e,14,2),d.jh=d.Ff+Zo(a,e,22,2)*Zo(a,e,16,1),d.th=Zo(a,e,17,2),d.xg=Zo(a,e,13,1));d.hh=d.jh+((32*d.th+(d.Va-1))/d.Va|0);d.im=(d.Gf-d.hh)/d.xg|0;d.zg=4084>=d.im?12:16;d.Sk=12==d.zg?4086:65526;b=[];for(e=d.jh;e>8;f+=2;if(k)for(;l--;)Xo(d,f,1),254>=k?(n=k,q=Xo(d,f+1),f+=3):(n=Xo(d,f+3,1),q=Xo(d,f+4),f+=6),d.zd[n]&&(d.zd[n].we[h]=[q]),d.A[h]=[n,q],h++;else h+=l}(g=$o(e,Uo,c))&&ap(e,g+c);g=$o(e,Vo,c);h=$o(e,So,c);g&&h&&ap(e,g,g+h)}}}} -function ip(a,b,c,d,e){var f,g=a.C.length,h=b.Va/32|0;b.zo=d+"\\";for(var k=0;kF)break;for(var v=p.hh+(F-2)*p.xg,E=0;EF)break;for(var v=p.hh+(F-2)*p.xg,E=0;E>3,1),d?e=16==b.zg?e<<8:c&7?e<<4:(e&15)<<8:c&7&&(e>>=4));return e} function Yo(a,b){var c=a.ub*a.lb,d=b/c|0;return dg)break;e|=g<=f)break;e+=String.fromCharCode(f)}return e}function cp(a,b,c,d,e,f){a||(a={sector:d,length:e,data:[],pattern:f});a.Tk=b;a.Uk=c;a.wd=a.Zc=0;a.Wa=!1;return a} function dp(a,b){var c;c="action=open&volume="+b+("&mode="+a.mode);c+="&chs="+a.Bb+":"+a.ub+":"+a.lb+":"+a.Va;c+="&machine="+a.controller.ff();c+="&user="+a.controller.ke();return xa()+"/api/v1/disk?"+c} @@ -593,7 +593,7 @@ m.restore=function(a){var b=0,c="unsupported restore format";if(a&&0b?-2!=b&&this.controller.Oa("Unable to restore disk '"+this.ea+": "+c):fp(this);return b}; m.toJSON=function(){var a;a=0;for(var b;b=Yo(this,a++);)pp(b);a=JSON.stringify(this.A,function(a,b){return"file"==a?void 0:b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; function pp(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}function qp(a){Ua.call(this,"FDC",a,qp,524288);this.dmaRead=this.wk;this.dmaWrite=this.xk;this.dmaFormat=this.Lk;this.U=a.autoMount||null;this.B=[];this.ga=!Ga("Mobi")&&window&&"FileReader"in window}db(qp);aa={}; -var rp={3:{Vd:3,ie:0,name:aa.Yn},4:{Vd:2,ie:1,name:aa.Wn},5:{Vd:9,ie:7,name:aa.ho},6:{Vd:9,ie:7,name:aa.Rn},7:{Vd:2,ie:0,name:aa.Tn},8:{Vd:1,ie:2,name:aa.Xn},10:{Vd:2,ie:7,name:aa.Sn},13:{Vd:6,ie:7,name:aa.Dn},15:{Vd:3,ie:0,name:aa.Vn}};m=qp.prototype; +var rp={3:{Vd:3,ie:0,name:aa.Zn},4:{Vd:2,ie:1,name:aa.Xn},5:{Vd:9,ie:7,name:aa.io},6:{Vd:9,ie:7,name:aa.Sn},7:{Vd:2,ie:0,name:aa.Un},8:{Vd:1,ie:2,name:aa.Yn},10:{Vd:2,ie:7,name:aa.Tn},13:{Vd:6,ie:7,name:aa.En},15:{Vd:3,ie:0,name:aa.Wn}};m=qp.prototype; m.Qb=function(a,b,c){var d=this;switch(b){case "listDisks":return this.qa[b]=c,c.onchange=function(){var a=d.qa.descDisk,b=c.options[c.selectedIndex];if(a&&b){var g={};if(b=b.getAttribute("data-value"))try{g=eval("("+b+")")}catch(h){w("FDC option error: "+h.message)}b=g.desc;void 0===b&&(b="");g=g.href;void 0!==g&&(b=''+b+"");a.innerHTML=b}},!0;case "descDisk":case "listDrives":return this.qa[b]=c,c.onchange=function(){var a=ca(c.value,10);null!=a&&sp(d,a)},!0; case "loadDrive":return this.qa[b]=c,c.onclick=function(){var a=d.qa.listDisks;a&&tp(d,a.options[a.selectedIndex].text,a.value)},!0;case "saveDrive":if(!this.ga){c.parentNode.removeChild(c);break}this.qa[b]=c;c.onclick=function(){var a=d.qa.listDrives;if(a&&a.options&&d.A)if(a=ca(a.value,10),a=d.A[a])if(a.za){for(var b=a.za,c="",h=0,k;k=Yo(b,h++);)for(var l=0,n=k.length;la.Bb||f[1]>a.ub)&&(this.Oa('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.hb)),b=null);b?(a.za=b,a.jk=c,a.Le=d,Cp(this,c,d,b),f=b.info(),this.X|=128,this.Oa('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.hb),a.Ae||e),a.yg=f[0],a.Nf=f[1],a.Of=f[2],this.V&&this.V.yd()):a.$e=!1;a.Ae&&(a.Ae=!1,--this.fa||rb(this));sp(this,a.hb)}; function xp(a,b,c){if((a=a.qa.listDisks)&&a.options){for(var d=0;d=this.C&&(this.ma&=-81,this.L=this.C=0);return c}; -m.Om=function(a,b,c){A(this)&&x(this,a,b,c,"DATA["+this.C+"]");this.C=rp[a].Vd){b=!1;this.L=0;a=Dp(this);var d,e,f,g,h=a&31;switch(h){case 3:Dp(this);Dp(this);Ep(this);break;case 4:c=Dp(this);this.hb=c&3;d=this.A[this.hb];Ep(this);Fp(this,(d.Cb&-16777216)>>>24);break;case 5:case 6:c=Dp(this);b=c>>2&1;this.hb=c&3;d=this.A[this.hb];d.kb=b;c=d.Rb=Dp(this);e=Dp(this);f=d.xb=Dp(this);g=Dp(this);d.Hb=128<=rp[a].Vd){b=!1;this.L=0;a=Dp(this);var d,e,f,g,h=a&31;switch(h){case 3:Dp(this);Dp(this);Ep(this);break;case 4:c=Dp(this);this.hb=c&3;d=this.A[this.hb];Ep(this);Fp(this,(d.Cb&-16777216)>>>24);break;case 5:case 6:c=Dp(this);b=c>>2&1;this.hb=c&3;d=this.A[this.hb];d.kb=b;c=d.Rb=Dp(this);e=Dp(this);f=d.xb=Dp(this);g=Dp(this);d.Hb=128<>2&1;this.hb=c&3;d= this.A[this.hb];c=d.Rb;e=d.kb=b;f=d.xb=1;g=0;d.Cb=0;d.za&&(d.pb=d.za.seek(d.Rb,d.kb,d.xb))?g=d.pb.length>>8:d.Cb=72;Gp(this,d,a,b,c,e,f,g);b=!0;break;case 13:c=Dp(this);b=c>>2&1;this.hb=c&3;d=this.A[this.hb];c=d.Rb;e=d.kb=b;f=1;g=Dp(this);d.Hb=128<>2&1,c=Dp(this),d.Rb+=c-d.ge,0>d.Rb&&(d.Rb=0),d.Rb>=d.Bb&&(d.Rb=d.Bb-1),d.ge=c,d.Cb=32,d.Rb||(d.Cb|=268435456),Ep(this),b=!0}0>2&1,c=Dp(this),d.Rb+=c-d.ge,0>d.Rb&&(d.Rb=0),d.Rb>=d.Bb&&(d.Rb=d.Bb-1),d.ge=c,d.Cb=32,d.Rb||(d.Cb|=268435456),Ep(this),b=!0}0>>8);Fp(a,(b.Cb&16711680)>>>16);var k=0;if(e!=b.Rb||f!=b.kb)k=g=1;c&128&&(f^=k,d||(k=0));Fp(a,e+k);Fp(a,f);Fp(a,g);Fp(a,h)}function Dp(a){var b=a.W[a.L];a.L++;return b}function Ep(a){a.L=a.C=0}function Fp(a,b){a.W[a.C++]=b} m.wk=function(a,b,c){if(void 0===b||0>b){b=-1;var d=null,e=0;if(!a.Cb&&a.za){do{if(a.pb&&(e=a.eb,0<=(b=a.za.read(a.pb,a.eb++)))){d=a.pb;break}a.pb=a.za.seek(a.Rb,a.kb,a.xb);if(!a.pb){a.Cb=1088;break}a.eb=0;Hp(a)}while(1)}c(b,!1,d,e)}else c(-1,!1)};m.xk=function(a,b){return void 0!==b&&0<=b?Ip(a,b):-1}; m.Lk=function(a,b){var c;if(void 0!==b&&0<=b)a:if(c=b,a.Cb)c=-1;else{a.md[a.Ve++]=c;if(a.Ve==a.md.length){a.Rb=a.md[0];a.kb=a.md[1];a.xb=a.md[2];a.Hb=128<Ip(a,a.xi)){c=-1;break a}a.mg++}a.mg>=a.he&&(c=-1)}else c=-1;return c};function Ip(a,b){if(a.Cb||!a.za)return-1;do{if(a.pb&&a.za.write(a.pb,a.eb++,b))break;a.pb=a.za.seek(a.Rb,a.kb,a.xb);if(!a.pb){a.Cb=8256;b=-1;break}a.eb=0;Hp(a)}while(1);return b} -function Hp(a){a.xb++;a.xb>=a.Of+1&&(a.xb=1,a.kb++,a.kb>=a.Nf&&(a.kb=0,a.Rb++))}var vp={1012:qp.prototype.wl,1013:qp.prototype.ul,1015:qp.prototype.vl},wp={1010:qp.prototype.Pm,1013:qp.prototype.Om,1015:qp.prototype.Nm};Qa(function(){for(var a=nb(document,"pcjs","fdc"),b=0;b=a.Of+1&&(a.xb=1,a.kb++,a.kb>=a.Nf&&(a.kb=0,a.Rb++))}var vp={1009:qp.prototype.vl,1012:qp.prototype.xl,1013:qp.prototype.ul,1015:qp.prototype.wl},wp={1010:qp.prototype.Qm,1013:qp.prototype.Pm,1015:qp.prototype.Om};Qa(function(){for(var a=nb(document,"pcjs","fdc"),b=0;b=this.C&&(this.L=this.C=0,this.ma&=-15);return c};m.mn=function(a,b,c){x(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.ma|=2,this.ma&=-2,Tp(this))};m.Xl=function(a,b){var c=this.ma;x(this,a,null,b,"STATUS",c);this.L=this.C&&(this.L=this.C=0,this.ma&=-15);return c};m.nn=function(a,b,c){x(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.ma|=2,this.ma&=-2,Tp(this))};m.Yl=function(a,b){var c=this.ma;x(this,a,null,b,"STATUS",c);this.L=a.B.Va?(a.ma=128,Vp(a.B,function(b){0<=b?(Wp(a),a.N&&5180==a.N.ia&&(a.ma=0),a.ma|=88):(a.ma=1,a.X=16)},!1)):a.ma=80));return d}m.Ak=function(a,b){return Up(this,a,b)|Up(this,a,b)<<8}; -function Xp(a,b,c,d){if(a.B&&a.B.Hb>=a.B.Va)if(0>Yp(a.B,c))a.ma=1,a.X=16;else if(1==a.B.eb||a.B.eb==a.B.Va)A(a,1048832)&&x(a,b,c,d,"DATA["+a.B.eb+"]"),1=a.B.Va&&(a.ma|=8))}m.vm=function(a,b,c){Xp(this,a,b&255,c);Xp(this,a,b>>8&255,c)};m.dl=function(a,b){var c=this.X;x(this,a,null,b,"ERROR",c);return c};m.Am=function(a,b,c){x(this,a,b,c,"WPREC");this.Pa=b};m.fl=function(a,b){var c=this.aa;x(this,a,null,b,"SECCNT",c);return c}; -m.ym=function(a,b,c){x(this,a,b,c,"SECCNT");this.aa=b};m.gl=function(a,b){var c=this.Ca;x(this,a,null,b,"SECNUM",c);return c};m.zm=function(a,b,c){x(this,a,b,c,"SECNUM");this.Ca=b};m.bl=function(a,b){var c=this.ya;x(this,a,null,b,"CYLLO",c);return c};m.um=function(a,b,c){x(this,a,b,c,"CYLLO");this.ya=b};m.al=function(a,b){var c=this.wa;x(this,a,null,b,"CYLHI",c);return c};m.tm=function(a,b,c){x(this,a,b,c,"CYLHI");this.wa=b};m.cl=function(a,b){var c=this.ra;x(this,a,null,b,"DRVHD",c);return c}; -m.wm=function(a,b,c){x(this,a,b,c,"DRVHD");this.ra=b;this.ma=this.A[this.ra&16?1:0]?this.ma|80:this.ma&-65};m.hl=function(a,b){var c=this.ma;x(this,a,null,b,"STATUS",c);this.ma&64&&(this.ma&=-129);return c};m.sm=function(a,b,c){x(this,a,b,c,"COMMAND");this.Ea=b;this.N&&dg(this.N,14);Zp(this)};m.xm=function(a,b,c){x(this,a,b,c,"FDR");this.ga&4&&!(b&4)&&(this.X=1);this.ga=b}; +function Xp(a,b,c,d){if(a.B&&a.B.Hb>=a.B.Va)if(0>Yp(a.B,c))a.ma=1,a.X=16;else if(1==a.B.eb||a.B.eb==a.B.Va)A(a,1048832)&&x(a,b,c,d,"DATA["+a.B.eb+"]"),1=a.B.Va&&(a.ma|=8))}m.wm=function(a,b,c){Xp(this,a,b&255,c);Xp(this,a,b>>8&255,c)};m.dl=function(a,b){var c=this.X;x(this,a,null,b,"ERROR",c);return c};m.Bm=function(a,b,c){x(this,a,b,c,"WPREC");this.Pa=b};m.fl=function(a,b){var c=this.aa;x(this,a,null,b,"SECCNT",c);return c}; +m.zm=function(a,b,c){x(this,a,b,c,"SECCNT");this.aa=b};m.gl=function(a,b){var c=this.Ca;x(this,a,null,b,"SECNUM",c);return c};m.Am=function(a,b,c){x(this,a,b,c,"SECNUM");this.Ca=b};m.bl=function(a,b){var c=this.ya;x(this,a,null,b,"CYLLO",c);return c};m.vm=function(a,b,c){x(this,a,b,c,"CYLLO");this.ya=b};m.al=function(a,b){var c=this.wa;x(this,a,null,b,"CYLHI",c);return c};m.um=function(a,b,c){x(this,a,b,c,"CYLHI");this.wa=b};m.cl=function(a,b){var c=this.ra;x(this,a,null,b,"DRVHD",c);return c}; +m.xm=function(a,b,c){x(this,a,b,c,"DRVHD");this.ra=b;this.ma=this.A[this.ra&16?1:0]?this.ma|80:this.ma&-65};m.hl=function(a,b){var c=this.ma;x(this,a,null,b,"STATUS",c);this.ma&64&&(this.ma&=-129);return c};m.tm=function(a,b,c){x(this,a,b,c,"COMMAND");this.Ea=b;this.N&&dg(this.N,14);Zp(this)};m.ym=function(a,b,c){x(this,a,b,c,"FDR");this.ga&4&&!(b&4)&&(this.X=1);this.ga=b}; function Zp(a){var b=!1,c=a.Ea,d=a.ra&16?1:0,e=a.ra&15,f=a.ya|(a.wa&3)<<8,g=a.Ca,h=a.aa||256;a.hb=-1;a.B=null;a.X=0;a.ma=80;var k=a.A[d];k?(k.de=f,k.kb=e,k.xb=g,k.Hb=h*k.Va,c=144<=c?c:c&240,k.pb=null,k.eb=0,k.errorCode=0,a.hb=d,a.B=k):c=-1;switch(c&240){case 16:b=!0;break;case 32:a.ma=128;Vp(k,function(b){0<=b&&a.N?(Wp(a),a.ma=88):(a.ma=1,a.X=16)},!1);break;case 48:a.ma=8;break;case 64:b=!0;break;case 112:b=!0;break;case 144:a.X=1;b=!0;break;case 145:k.ub=e+1,k.lb=h,b=!0}b&&Wp(a)} function Wp(a){!a.N||a.ga&2||eg(a.N,14,120)} function Tp(a){a.L=0;var b=$p(a),c=$p(a),d=c&32,e=d>>5,f=c&31,g=$p(a),h=$p(a),k=g<<2&768|h,l=g&63,n=$p(a),q=$p(a),p=a.A[e];p&&(p.de=k,p.kb=f,p.xb=l,p.Hb=n*p.Va);switch(b){case 3:aq(a,p?p.errorCode:4);bq(a,c);bq(a,g);bq(a,h);bq(a,0|d);b=-1;break;case 12:for(c=0;0<=(b=$p(a));)p&&c=a.lb+b&&(a.xb=b,a.kb++,a.kb>=a.ub&&(a.kb=0,a.de++))}m.Yl=function(){var a=this.F.M&255;!(this.F.G>>8)&&128>8||!this.N)||(a=!(this.N.vc[0].Bd&64));return a?!0:!1}; -var Np={800:Jp.prototype.Wl,801:Jp.prototype.Xl,802:Jp.prototype.Vl},Mp={496:Jp.prototype.Ak,497:Jp.prototype.dl,498:Jp.prototype.fl,499:Jp.prototype.gl,500:Jp.prototype.bl,501:Jp.prototype.al,502:Jp.prototype.cl,503:Jp.prototype.hl},Pp={800:Jp.prototype.mn,801:Jp.prototype.pn,802:Jp.prototype.on,803:Jp.prototype.nn,807:Jp.prototype.fi,811:Jp.prototype.fi,815:Jp.prototype.fi},Op={496:Jp.prototype.vm,497:Jp.prototype.Am,498:Jp.prototype.ym,499:Jp.prototype.zm,500:Jp.prototype.um,501:Jp.prototype.tm, -502:Jp.prototype.wm,503:Jp.prototype.sm,1014:Jp.prototype.xm};Qa(function(){for(var a=nb(document,"pcjs","hdc"),b=0;b=a.lb+b&&(a.xb=b,a.kb++,a.kb>=a.ub&&(a.kb=0,a.de++))}m.Zl=function(){var a=this.F.M&255;!(this.F.G>>8)&&128>8||!this.N)||(a=!(this.N.vc[0].Bd&64));return a?!0:!1}; +var Np={800:Jp.prototype.Xl,801:Jp.prototype.Yl,802:Jp.prototype.Wl},Mp={496:Jp.prototype.Ak,497:Jp.prototype.dl,498:Jp.prototype.fl,499:Jp.prototype.gl,500:Jp.prototype.bl,501:Jp.prototype.al,502:Jp.prototype.cl,503:Jp.prototype.hl},Pp={800:Jp.prototype.nn,801:Jp.prototype.qn,802:Jp.prototype.pn,803:Jp.prototype.on,807:Jp.prototype.fi,811:Jp.prototype.fi,815:Jp.prototype.fi},Op={496:Jp.prototype.wm,497:Jp.prototype.Bm,498:Jp.prototype.zm,499:Jp.prototype.Am,500:Jp.prototype.vm,501:Jp.prototype.um, +502:Jp.prototype.xm,503:Jp.prototype.tm,1014:Jp.prototype.ym};Qa(function(){for(var a=nb(document,"pcjs","hdc"),b=0;b>2;this.Ba=b.wg;this.bc=new ed(this.F,7,"DBG");this.Ia=yq;80186<=this.F.ia&&(this.Ia=yq.slice(),this.Ia[15]=wq,80286<=this.F.ia&&(this.Ia[15]=xq,80386<=this.F.ia&&(this.Ja=8)));Mk(this,64,function(a){Cq(d,d.F.ld,a[0])});Mk(this,4,function(a){if(a=a[0]){var b=Dq(d,a);if(void 0===b)d.O("invalid selector: "+a);else if(a=Eq(d, b,2),d.O("dumpSel("+u(a?a.Z:b)+"): %"+r(a?a.Xb:null,d.Ca)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var h=Fq[a.type];h&&(c=h[0],b=h[1])}!c||a.wb&32768||(c+=",not present");d.O((b?"seg="+u(a.Aa&65535)+" off="+u(a.Ta):"base="+r(a.Aa,d.Ca)+" limit="+Gq(a.Ta))+" type="+t(a.type>>8)+" ("+c+") ext="+u(a.ext&-65296)+ " dpl="+t(a.Gc))}}else d.O("no selector")});Mk(this,134217728,function(a){var b;(a=a[0])&&(b=Dq(d,a));if(void 0===b)d.O("invalid MCB");else for(d.O("dumpMCB("+u(b)+")");b;){a=hq(d,0,b);var c=d.Qa(a,1),h=d.na(a,2),k=d.na(a,5);if(77!=c&&90!=c)break;d.O(Hq(0,b)+": '"+String.fromCharCode(c)+"' PID="+u(h)+" LEN="+u(k)+' "'+Iq(d,a,8)+'"');b+=1+k}});Mk(this,128,function(a){Cq(d,d.F.sa,a[0],d.F.sa!==d.F.ld)});Mk(this,8,function(a){a:{if(a=a[0]){var b=Dq(d,a);if(void 0===b){d.O("invalid task selector: "+a); -break a}a=Eq(d,b,2)}else a=d.F.Sa;d.O("dumpTSS("+u(a?a.Z:b)+"): %"+r(a?a.Aa:null,d.Ca));if(a){var b="",c=a.type&-513,h=256==c?4:8,k=256==c?Jq:Kq,l,n,q,p;for(p in k)l=k[p],n=a.Aa+l,q=If(d.F,n,2),2304==c&&(q|=If(d.F,n+2,2)<<16),b&&(b+="\n"),b+=u(l)+" "+ma(p+":",11)+r(q,h);if(2304==c)for(p=0,l=q>>>16;lp;)n=a.Aa+l,q=If(d.F,n,2),b+="\n"+u(l)+" ports "+u(p)+"-"+u(p+15)+": "+ea(q,2),p+=16,l+=2;d.O(b)}}});this.C=null;this.rb=0;this.cb=!1;cf(this.F,48,this.am.bind(this));cf(this.F,65,this.bm.bind(this)); -this.ka=null;cf(this.F,104,this.cm.bind(this));rb(this)};function Lq(a,b,c,d,e,f){b=Iq(a,b);var g=Eq(a,d),g=g?g.Ta+1:0,h=(e?"_CODE":"_DATA")+r(c,2);f&&A(a,128)&&a.message(b+" "+(e?"code":"data")+"("+r(c,4)+")=#"+r(d,4)+" len "+r(g));e=Mq(a,b,c);e[b+h]=0;am(a,b,c,d,0,null,g,e)} +break a}a=Eq(d,b,2)}else a=d.F.Sa;d.O("dumpTSS("+u(a?a.Z:b)+"): %"+r(a?a.Aa:null,d.Ca));if(a){var b="",c=a.type&-513,h=256==c?4:8,k=256==c?Jq:Kq,l,n,q,p;for(p in k)l=k[p],n=a.Aa+l,q=If(d.F,n,2),2304==c&&(q|=If(d.F,n+2,2)<<16),b&&(b+="\n"),b+=u(l)+" "+ma(p+":",11)+r(q,h);if(2304==c)for(p=0,l=q>>>16;lp;)n=a.Aa+l,q=If(d.F,n,2),b+="\n"+u(l)+" ports "+u(p)+"-"+u(p+15)+": "+ea(q,2),p+=16,l+=2;d.O(b)}}});this.C=null;this.rb=0;this.cb=!1;cf(this.F,48,this.bm.bind(this));cf(this.F,65,this.cm.bind(this)); +this.ka=null;cf(this.F,104,this.dm.bind(this));rb(this)};function Lq(a,b,c,d,e,f){b=Iq(a,b);var g=Eq(a,d),g=g?g.Ta+1:0,h=(e?"_CODE":"_DATA")+r(c,2);f&&A(a,128)&&a.message(b+" "+(e?"code":"data")+"("+r(c,4)+")=#"+r(d,4)+" len "+r(g));e=Mq(a,b,c);e[b+h]=0;am(a,b,c,d,0,null,g,e)} function Nq(a,b,c,d){var e=a.na(b,2),f=a.na(b,2),g=a.oa(b,4),h=a.oa(b,4),k=hq(a,a.oa(b,4),a.na(b,2));b=hq(a,a.oa(b,4),a.na(b,2));b=Iq(a,b).toUpperCase();var k=Iq(a,k).toUpperCase(),l=(c?"_CODE":"_DATA")+r(e,2);d&&A(a,128)&&a.message((b==k?"":b+"!")+k+" "+(c?"code":"data")+"("+r(e,4)+")="+r(f,4)+":"+r(g)+" len "+r(h));c=Mq(a,k,e);c[k+l]=g;am(a,k,e,f,g,null,h,c)}function Oq(a,b,c){c=Iq(a,c).toUpperCase();Pq(a,c,b)} -m.am=function(){var a=this.F;if(null!=this.C&&2752554==a.G){var b=a.M&65535,c=a.K&65535,d=hq(this,I(a)+12,a.ta.Z);switch(this.oa(d)){case 336:Nq(this,hq(this,a.H,b),!c,!!this.C)}}return!0}; -m.bm=function(a){var b=this.F,c=b.G&65535,d=b.H&65535,e=b.I&65535,f=b.M&65535,g=b.K&65535,h=b.J&65535,k=b.Xa.Z;if(null==this.C)return 79==c&&df(b,a,function(a){return function(){62342!=(b.G&65535)?(b.G=b.G&-65536|62342,y(a,"INT 0x41 handling enabled",128),a.C=!0):(y(a,"INT 0x41 monitoring enabled",128),a.C=!1)}}(this)),!0;switch(c){case 79:this.C&&(b.G=b.G&-65536|62342,y(this,"INT 0x41 handling enabled",128));break;case 80:Lq(this,hq(this,h,k),d+1,e,!(g&1),!!this.C);break;case 82:Pq(this,null,d); +m.bm=function(){var a=this.F;if(null!=this.C&&2752554==a.G){var b=a.M&65535,c=a.K&65535,d=hq(this,I(a)+12,a.ta.Z);switch(this.oa(d)){case 336:Nq(this,hq(this,a.H,b),!c,!!this.C)}}return!0}; +m.cm=function(a){var b=this.F,c=b.G&65535,d=b.H&65535,e=b.I&65535,f=b.M&65535,g=b.K&65535,h=b.J&65535,k=b.Xa.Z;if(null==this.C)return 79==c&&df(b,a,function(a){return function(){62342!=(b.G&65535)?(b.G=b.G&-65536|62342,y(a,"INT 0x41 handling enabled",128),a.C=!0):(y(a,"INT 0x41 monitoring enabled",128),a.C=!1)}}(this)),!0;switch(c){case 79:this.C&&(b.G=b.G&-65536|62342,y(this,"INT 0x41 handling enabled",128));break;case 80:Lq(this,hq(this,h,k),d+1,e,!(g&1),!!this.C);break;case 82:Pq(this,null,d); break;case 127:this.C&&(b.G=b.G&-65536|(this.cb?0:1));break;case 131:this.C&&(a=hq(this,b.M,e),this.rb++?(this.O("TRAPFAULT failed"),Qq(this,this.A,a,!0,!0),this.rb=0,this.Wb()):(this.O("INT 0x41 TRAPFAULT: fault="+u(d)+" error="+("0x"+r(b.K))+" addr="+Rq(a)),this.Sd(this.A,a,!0),jq(this,!0)));break;case 141:this.C&&(b.G=b.G&-65536|1);break;case 336:Nq(this,hq(this,b.H,f),!g,!!this.C);break;case 338:Oq(this,d,hq(this,b.J,f))}this.cb=!1;return!this.C}; -m.cm=function(a){var b=this.F,c=b.G&255,d=b.G>>8&255,e=b.H&65535,f=b.I&65535,g=b.M&65535,h=b.J&65535,k=b.Xa.Z;if(null==this.ka){if(67==d){if(609437257==b.oa((b.va.Z<<4)+10)||1111835735==b.oa((b.va.Z<<4)+95))return!0;df(b,a,function(a){return function(){62342!=(b.G&65535)?(b.G=b.G&-65536|62342,y(a,"INT 0x68 handling enabled",128),a.C=a.ka=!0):(y(a,"INT 0x68 monitoring enabled",128),a.ka=!1)}}(this))}return!0}switch(d){case 67:this.ka&&(b.G=b.G&-65536|62342);break;case 68:this.ka&&(a=gd(b.va,this.Hk.bind(this)))&& +m.dm=function(a){var b=this.F,c=b.G&255,d=b.G>>8&255,e=b.H&65535,f=b.I&65535,g=b.M&65535,h=b.J&65535,k=b.Xa.Z;if(null==this.ka){if(67==d){if(609437257==b.oa((b.va.Z<<4)+10)||1111835735==b.oa((b.va.Z<<4)+95))return!0;df(b,a,function(a){return function(){62342!=(b.G&65535)?(b.G=b.G&-65536|62342,y(a,"INT 0x68 handling enabled",128),a.C=a.ka=!0):(y(a,"INT 0x68 monitoring enabled",128),a.ka=!1)}}(this))}return!0}switch(d){case 67:this.ka&&(b.G=b.G&-65536|62342);break;case 68:this.ka&&(a=gd(b.va,this.Hk.bind(this)))&& (b.J=a[0],wd(b,a[1]));break;case 72:Pq(this,null,e);break;case 80:32==c?Lq(this,hq(this,h,k),0,f,!0,!!this.ka):128>c?Lq(this,hq(this,h,k),e+1,c&64?g:f,!(c&1),!!this.ka):Nq(this,hq(this,h,k),!(c&1),!!this.ka),this.ka&&(b.G=b.G&-256|1)}return!this.ka};m.Hk=function(){var a=this.F;5==(a.G&255)&&(a.I=a.K=0,a.G=a.G&-256|1);return!1}; m.Qb=function(a,b,c){var d=this;switch(b){case "debugInput":return this.Ka=this.qa[b]=c,c.onkeydown=function(a){var b;if(13==a.keyCode)b=c.value,c.value="",lq(d,b,!0);else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?d.U>>f.La].Sd(e&f.Fa,a==this.ga);g&&Vb(f)}}d&&(a.push(b),c?(null!=b.Da&&(b.Z=null),b.Xd=!0):(mr(this,a,a.length-1,"set"),jq(this)));return d}; +m.Sd=function(a,b,c){var d=!0;c||Qq(this,a,b,!1,!0);if(a!=this.A){var e=this.dc(b);if(-1===e)this.O("invalid address: "+Rq(b)),d=!1;else{var f=this.F,g=5==b.type;(g?f.ld:f.sa)[e>>>f.La].Sd(e&f.Fa,a==this.ga);g&&Ub(f)}}d&&(a.push(b),c?(null!=b.Da&&(b.Z=null),b.Xd=!0):(mr(this,a,a.length-1,"set"),jq(this)));return d}; function Qq(a,b,c,d,e){for(var f=!1,g=nr(a,a.dc(c)),h=1;h>3&7,z=(3>(g>>6&3)?0:48)+p;(217==f||219==f)&&52<=z&&(z=p<<4|g&7);(p=Aq[f])&&(q=p[z]);q&&(n=qq,k=q,l=k[0])}l>=n.length&&(g=a.Qa(b,1),k=Bq[l-n.length][g>>3&7],l=k[0]);n=n[l];p=k.length-1;q="";b.Sb&&(18==l? n="CWDE":28==l?n="CDQ":104<=l&&107>=l&&(n+="D"));if(164<=f&&167>=f||170<=f&&175>=f)p=0,b.Sb&&"W"==n.slice(-1)&&(n=n.slice(0,-1)+"D");for(var f=null,z=!0,F=1;F<=p;F++){var v,E;v="";E=k[F];if(void 0!==E){null==f&&(f=E>>14);80==l&&(2==f?q="[%800]":3==f&&(q="ES:["+(b.pc?"E":"")+"DI]"));var H=E&15;if(0!=H)if(8==H)z=!1;else{var L=E&240;if(128<=L)if(0>g&&(g=a.Qa(b,1)),160>L){v=a;var V=p,H=b,P="",bb=g>>6,ia=g&7;if(3>bb){var ja=void 0,L=0==n.indexOf("FI");if(!bb&&(!H.pc&&6==ia||H.pc&&5==ia))bb=2;else{if(H.pc)if(4!= -ia)ia+=8;else{var P=v,ja=bb,Ha=H,Xa=P.Qa(Ha,1),Ba=Xa>>6,Ub=Xa>>3&7,Xa=Xa&7,wa="";if(ja||5!=Xa)wa=uq[Xa+8];4!=Ub&&(wa&&(wa+="+"),wa+=uq[Ub+8],Ba&&(wa+="*"+(1<>24,P+="-"+r(-ja,2)):P+="+"+r(ja,2)):2==bb&&(P&&(P+="+"),H.pc?(ja=v.oa(H,4),P+=r(ja)):(ja=v.na(H,2),P+=r(ja,4)));P="["+P+"]";if(1==V){v="";E&=15;4==E&&(E=H.Sb?5:3);switch(E){case 7:v="FAR";break;case 1:v="BYTE";break;case 3:if(L){v="INT16"; +ia)ia+=8;else{var P=v,ja=bb,Ha=H,Xa=P.Qa(Ha,1),Ba=Xa>>6,Vb=Xa>>3&7,Xa=Xa&7,wa="";if(ja||5!=Xa)wa=uq[Xa+8];4!=Vb&&(wa&&(wa+="+"),wa+=uq[Vb+8],Ba&&(wa+="*"+(1<>24,P+="-"+r(-ja,2)):P+="+"+r(ja,2)):2==bb&&(P&&(P+="+"),H.pc?(ja=v.oa(H,4),P+=r(ja)):(ja=v.na(H,2),P+=r(ja,4)));P="["+P+"]";if(1==V){v="";E&=15;4==E&&(E=H.Sb?5:3);switch(E){case 7:v="FAR";break;case 1:v="BYTE";break;case 3:if(L){v="INT16"; break}v="WORD";break;case 5:v="DWORD";break;case 11:if(L){v="INT32";break}case 11:v="REAL32";break;case 12:if(L){v="INT64";break}case 12:v="REAL64";break;case 13:v="REAL80";break;case 14:v="BCD80"}v&&(P=v+" "+P)}}else P=rr(v,ia,E,H);v=P}else v=160==L?rr(a,g&7,E,b):rr(a,g>>3&7,E,b);else if(16==L)v="1";else if(0==L){v=a;H=E;L=b;E=" ";switch(H&15){case 1:H&12288&&(E=r(v.Qa(L,1),2));break;case 2:E=r(v.Qa(L,1)<<24>>24,L.Sb?8:4);break;case 4:if(L.Sb){E=r(v.oa(L,4));break}case 3:E=r(v.na(L,2),4);break;case 7:L= hq(v,v.tb(L,!0),v.na(L,2),null,L.type,L.Sb,L.pc);E=Rq(L);v=sr(v,L);v[0]&&(E+=" ("+v[0]+")");break;default:E="imm("+u(H)+")"}v=E}else 32==L?(b.pc?(v=8,E=a.oa(b,4)):(v=4,E=a.na(b,2)),v="["+r(E,v)+"]"):48==L?(v=1==H?a.Qa(b,1)<<24>>24:a.tb(b,!0),E=b.Ra+v&(b.Sb?-1:65535),v=r(E,b.Sb?8:4),E=sr(a,hq(a,E,b.Z)),E[0]&&(v+=" ("+E[0]+")")):96==L?v=9==H?"ST":10==H?"ST("+(g&7)+")":rr(a,(E&3840)>>8,E,b):112==L?v=rr(a,(E&3840)>>8,192,b):64==L?v="DS:[SI]":80==L&&(v="ES:[DI]");if(!v||!v.length){q="INVALID";break}0< q.length&&(q+=",");q+=v||"???"}}}g="";k=Rq(e)+" ";if(-1!==e.Da&&-1!==b.Da){do if(g+=r(a.Qa(e,1),2),null==e.Da)break;while(e.Da!=b.Da)}k+=ma(g,e.pc?24:16);k+=ma(n,8);q&&(k+=" "+q);a.F.ia=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);eb[0]?1:a[0]>>0,n],v=oa(z,p,a.sb);0>v&&z.splice(-(v+1),0,p)}F&&(q.a=F.replace(/''/g,'"'))}a.B.push({fg:b,lm:c,Z:d,Ra:e,Da:f,dm:g,Rd:h,ri:l})} -function Pq(a,b,c){for(var d=0;d>>0,f=a.dc(b)>>>0,g=0;g>>0,n=h.Da;null!=n&&(n>>>=0);var q=h.dm;48==k&&(k=40);if(k==b.Z&&e>=l&&e=n&&f>>0,n],v=oa(z,p,a.sb);0>v&&z.splice(-(v+1),0,p)}F&&(q.a=F.replace(/''/g,'"'))}a.B.push({fg:b,mm:c,Z:d,Ra:e,Da:f,em:g,Rd:h,ri:l})} +function Pq(a,b,c){for(var d=0;d>>0,f=a.dc(b)>>>0,g=0;g>>0,n=h.Da;null!=n&&(n>>>=0);var q=h.em;48==k&&(k=40);if(k==b.Z&&e>=l&&e=n&&f>>20;Da.ui=a.F.Pd+Da.bk;Da.yb=ce.sa[(Da.ui&ce.Gb)>>>ce.La];Da.Ui=Da.yb.Nd(Da.bk);Da.ck=(Te&4190208)>>>10;Da.vi=(Da.Ui&-4096)+Da.ck;Da.zb=ce.sa[(Da.vi&ce.Gb)>>>ce.La];Da.Vi=Da.zb.Nd(Da.ck);Da.Fk=(Da.Vi&-4096)+(Te&4095)}if(be=Da){a.O("linear PDE addr PDE PTE addr PTE physical");a.O("--------- ---------- -------- ---------- -------- ----------");var qd="%"+r(Te),qd=qd+(" %%"+cr(be.ui,be.Ui)),qd=qd+(" %%"+cr(be.vi,be.Vi,!0)), qd=qd+(" %%"+r(be.Fk));a.O(qd)}else a.O("unsupported operation")}}else a.O("missing address")}else{if("d"==ia){if("disk"==ja){P[0]="l";P[1]="json";Ir(a,P);break a}for(bb in vq)if(P[1]==bb){var Dn=a.$a[bb];Dn?(P.shift(),P.shift(),Dn(P)):a.O("no dump registered for "+ja);break a}ja||(ia=a.Cc||"db")}else a.Cc=ia;if("dh"==ia){var En=ja,Fn=Ha,Gn="",Hn=0,tb=a.Fa,tc=a.ja;if(tc.length){var Db=+En||a.Ub,de=+Fn||10;isNaN(Db)?Db=de:Gn="more ";Db>tc.length&&(a.O("note: only "+tc.length+" available"),Db=tc.length); tb-=Db;0>tb&&(null==tc[tc.length-1].Z?(Db=tb+Db,tb=0):tb+=tc.length);var ii=[];"call"==Fn&&(de=1E5,ii=["CALL"]);for(void 0!==En&&a.O(Db+" instructions earlier:");0=tc.length&&(tb=0);a.Ub=Db;Hn++;de--}}Hn||(a.O("no "+Gn+"history available"),a.Ub=void 0)}else if("di"==ia){P.shift(); diff --git a/versions/pcjs/1.21.4/pc.js b/versions/pcjs/1.21.4/pc.js index a3d40a8b53..81f50f3005 100644 --- a/versions/pcjs/1.21.4/pc.js +++ b/versions/pcjs/1.21.4/pc.js @@ -29,7 +29,7 @@ function mb(a,b,c){var d=1280/null.offsetWidth,e=720/null.offsetHeight,f=null.ge l.Xd=function(){};function qb(a,b,c,d){a.B.He[a.B.Gh++]={Ij:b,hd:c,type:d};return na(nb,b,c,0,d)}function ob(a,b,c,d){var e,f=null.style.color,g=a.xa=10;a.D=g;a.K=b;a.L=a.ka=18;e||(e=a.ia||a.ka+"px Monaco, Lucida Console, Courier New");a.S=a.ia=e;c&&(a.pa=c);d&&(a.G=d,a.qa=f||"white")} function pb(a,b,c,d,e){a.G.font=a.S;a.G.fillStyle=a.qa;a.G.fillText(b,a.D,a.K);a.D+=a.ba;null!=c&&(16!=a.Ja?b=c.toString():(b=8>a.va?"0x":"",b+=ea(c,a.va)),a.G.fillText(b,a.D,a.K),a.D+=a.ba);d&&(a.D+=a.ba*d);e&&(a.D=a.xa,a.K+=(a.L+2)*(e||1))}function lb(){for(var a=!1,b=Za(document,"pcjs","panel"),c=0;c=this.D?12:24>=this.D?14:15;this.vb=1<>2;this.B=this.vb-1;this.H=this.L/this.vb|0;this.C=this.H-1;this.I=[];this.K=[];this.P=[];this.S=[];a=new q;sb(a,this.Ia);this.R=Array(this.H);for(b=0;b>>a.da;0a.vb?a.vb:c;if(g&&g.size){if(g.type==d&&g.controller==e){if(b+c<=g.fe)return g.De+=g.fe-b,g.fe=b,!0;if(b>=g.fe+g.De){k=g.size-(b-h);k>c&&(k=c);g.De=b-g.fe+k;c-=k;b=h+a.vb;continue}}return zb(a,1,b,c)}g=a.R[f];b=new q(b,k,a.vb,d,e);sb(b,a.Ia,g);a.R[f++]=b;b=h+a.vb;c-=k}return 0>=c?(a=a.A,a.Pa&-2147483648&&Bb(a),!0):zb(a,2,b,c)} function xb(a,b){if(32==a.D)b?a.G&&(Cb(a,1048576,1048576,a.G),a.G=null):a.G||(a.G=Db(a,1048576,1048576),Cb(a,1048576,1048576,Db(a,0,1048576)));else if(20>>this.da;0>>a.da;0>>=a.da;0>>=f)&k;if(void 0!==g&&g[0])g[0](b,k,e);f+=h<<3;b+=h;c-=h}}function zb(a,b,c,d,e){b="Memory block error ("+b+": "+ea(c)+","+ea(d)+")";e?a.Ia?a.Ia.message(b):a.log(b):n(b);return!1}var Rb;if(db){var Sb=new ArrayBuffer(2);(new DataView(Sb)).setUint16(0,256,!0);Rb=256===(new Uint16Array(Sb))[0]}else Rb=!1;var Hb=Rb; function q(a,b,c,d,e,f){this.id=Tb+=2;this.V=null;this.H=0;this.fe=a;this.De=b;this.size=c||0;this.type=d||Ub;this.I=d==Gb;this.controller=null;this.A=f;sb(this);this.Ha=this.Oh=!1;if(c)if(e)this.controller=e,a=e.Th(a),this.V=a[0],this.H=a[1],Eb(this,e.lg());else if(db)this.R=new ArrayBuffer(c),this.P=new DataView(this.R,0,c),this.Ka=new Uint8Array(this.R,0,c),this.ud=new Uint16Array(this.R,0,c>>1),this.V=new Int32Array(this.R,0,c>>2),Eb(this,Hb?Ib:Jb);else{this.V=Array(c>>2);for(e=0;e>8&65280|a>>>24);return a} -q.prototype={constructor:q,parent:null,Pk:function(a){this.fe=a},save:function(){var a,b;if(this.controller)a=null;else if(db)for(a=Array(this.size>>2),b=0;b>2),b=0;b>8,c)},la:function(a,b,c){this.Yb(a++,b&255,c++);this.Yb(a++,b>>8&255,c++);this.Yb(a++,b>>16&255,c++);this.Yb(a,b>>>24,c)},va:function(a){return this.V[a>>2]>>>((a&3)<<3)&255},fb:function(a){var b=a>>2;a=(a&3)<<3;var c=this.V[b]>>a;return 24>a?c&65535:c&255|(this.V[b+1]&255)<<8},Ga:function(a){var b=a>>2;a=(a&3)<<3;var c=this.V[b];a&&(c=c>>> a|this.V[b+1]<<32-a);return c},Bb:function(a,b){var c=a>>2,d=(a&3)<<3;this.V[c]=this.V[c]&~(255<>2,d=(a&3)<<3;24>d?this.V[c]=this.V[c]&~(65535<>8);this.Ha=!0},fc:function(a,b){var c=a>>2,d=(a&3)<<3;if(d){var e=-1<>>32-d}else this.V[c]=b;this.Ha=!0},ua:function(a,b){this.A&&Yb(this.A,b,1,!1);return this.Ed(a,b)},Xa:function(a, b){this.A&&Yb(this.A,b,2,!1);return this.ef(a,b)},Fa:function(a,b){this.A&&Yb(this.A,b,4,!1);return this.ih(a,b)},Ab:function(a,b,c){this.A&&Yb(this.A,c,1,!0);this.I||this.kf(a,b,c)},wc:function(a,b,c){this.A&&Yb(this.A,c,2,!0);this.I||this.oh(a,b,c)},Zb:function(a,b,c){this.A&&Yb(this.A,c,4,!0);this.I||this.oa(a,b,c)},za:function(a,b){this.B.V[this.D]|=this.K;this.C.V[this.G]|=this.K;return this.L.Wb(a,b)},qb:function(a,b){this.B.V[this.D]|=this.K;this.C.V[this.G]|=this.K;return this.L.ye(a,b)}, @@ -58,14 +58,14 @@ l.pc=function(a,b,c,d){this.aa=a;this.ha=b;this.Ia=d;for(b=0;bc&&(c=60);2>c&&(c=2);var d=1;b&&1a.T.Df&&(c=Math.round(c/a.T.Bd));return c}function kc(a){a.T.Ad=0;a.$c=a.zc=a.mc=a.A=0;lc(a);pc(a,1)} +function sc(a,b){var c=30;60>c&&(c=60);2>c&&(c=2);var d=1;b&&1a.T.Df&&(c=Math.round(c/a.T.Bd));return c}function kc(a){a.T.Ad=0;a.$c=a.zc=a.mc=a.A=0;lc(a);pc(a,1)} function pc(a,b,c){if(void 0!==b){.8>a.T.Ad/a.T.te&&(b=1);a.T.Bd=b;b=a.T.Df*a.T.Bd;if(a.T.te!=b){a.T.te=b;b=a.T.te.toFixed(2)+"Mhz";var d=a.la.setSpeed;d&&(d.textContent=b);a.rc("target speed: "+b)}c&&a.aa&&uc(a.aa)}rc(a,a.zc);a.zc=0;a.T.ue=ka();a.T.Rd=0;sc(a)} -l.mh=function(a){if($a(this,!0)){if(!this.ea.Sb){pc(this);this.aa&&this.aa.start(this.T.ue,tc(this));this.ea.Sb=!0;this.ea.Qh=!0;this.P&&vc(this.P);var b=this.la.run;b&&(b.textContent="Halt");this.aa&&(this.aa.Xd(),a&&uc(this.aa,!0))}this.T.ug>=this.T.ad&&sc(this,!0);this.T.Se=0;this.T.Ef=ka();this.T.Rd&&(a=this.T.Ef-this.T.Rd,a>this.T.Xh&&(this.T.ue+=a,this.T.ue>this.T.Ef&&(this.T.ue=this.T.Ef)));try{do{var c=this.ea.zf?1:this.T.Wk;if(this.P){wc(this.P);var d=this.P;a=c;var e=d.K[0];if(e.Od){var f= +l.mh=function(a){if($a(this,!0)){if(!this.ea.Sb){pc(this);this.aa&&this.aa.start(this.T.ue,tc(this));this.ea.Sb=!0;this.ea.Qh=!0;this.P&&vc(this.P);var b=this.la.run;b&&(b.textContent="Halt");this.aa&&(this.aa.Xd(),a&&uc(this.aa,!0))}this.T.ug>=this.T.ad&&sc(this,!0);this.T.Se=0;this.T.Ef=ka();this.T.Rd&&(a=this.T.Ef-this.T.Rd,a>this.T.Xh&&(this.T.ue+=a,this.T.ue>this.T.Ef&&(this.T.ue=this.T.Ef)));try{do{var c=this.ea.zf?1:this.T.Xk;if(this.P){wc(this.P);var d=this.P;a=c;var e=d.K[0];if(e.Od){var f= (tc(d.A,d.ba)-e.ld)/d.Ga|0,g=xc(d,0)-f;6==e.mode&&(g-=f);var h=g*d.Ga|0;6==e.mode&&(h>>=1);a>h&&(a=h)}var c=a,k=this.P;a=c;if(k.B&&k.B[11]&64){var m=k.ia-tc(k.A,k.ba);0m&&(a=m)}c=a}try{this.mj(c)}catch(x){if("number"!=typeof x)throw x;}var p=this.mc-this.A;this.zc+=p;this.T.Se+=p;rc(this,0,!0);a=p;this.ea.zf&&(b=!1,this.T.Ff=this.T.Ff+this.Sh()|0,this.T.ve-=a,0>=this.T.ve&&(this.T.ve+=this.T.Ne,b=!0),0<=this.T.Oe&&this.T.Oe<=tc(this)&&(this.T.Ne=this.T.Oe=-1,lc(this),oc(this),b=!0),b&&this.rc(tc(this)+ " cycles: checksum="+ea(this.T.Ff)));this.T.Qe-=p;0>=this.T.Qe&&(this.T.Qe+=this.T.Zh,this.aa&&yc(this.aa));this.T.Pe-=p;0>=this.T.Pe&&(this.T.Pe+=this.T.Yh,this.aa&&this.aa.Xd());this.T.Re-=p;if(0>=this.T.Re){this.T.Re+=this.T.tg;break}}while(this.ea.Sb)}catch(x){oc(this);mc(this);this.aa&&this.aa.stop(ka(),tc(this));$a(this,!1);cb(this,x.stack||x.message);return}c=setTimeout;d=this.wj;this.T.Rd=ka();e=this.T.Xh;this.T.Se&&(e=Math.round(e*this.T.Se/this.T.tg));e-=this.T.Rd-this.T.Ef;if(f=this.T.Rd- this.T.ue)this.T.Ad=Math.round(this.zc/(10*f))/100,864E5<=f&&(this.$c=0,this.P&&wc(this.P,!0),pc(this));if(0>e||this.T.Adthis.id&&t.call(e,b&&3==this.id?10:13,a&65532)}return-1};l.Tk=function(a){var b=this.A;a=b.Ab+(a<<2);var c=b.ga(a);b.W&=-769;return this.load(b.ga(a+2))+c|0};l.Sk=function(a){var b=this.A;a<<=3;var c=b.Ab+a|0;if(7<=(b.xc-c|0))return this.D=!0,a=Bc(this,c,a),-1!==a&&(a+=this.cf),a;t.call(b,13,a|2);return-1};l.Ih=function(a){return this.ya+a|0}; +l.Cf=function(a,b){var c,d,e=this.A;a&=65535;a&4?(c=e.Zb.ya,d=c+e.Zb.Za|0):(c=e.ub,d=e.wc);if(c){c=c+(a&65528)|0;if(d-c|0)return e.A-=15,Bc(this,c,a,b);6>this.id&&t.call(e,b&&3==this.id?10:13,a&65532)}return-1};l.Uk=function(a){var b=this.A;a=b.Ab+(a<<2);var c=b.ga(a);b.W&=-769;return this.load(b.ga(a+2))+c|0};l.Tk=function(a){var b=this.A;a<<=3;var c=b.Ab+a|0;if(7<=(b.xc-c|0))return this.D=!0,a=Bc(this,c,a),-1!==a&&(a+=this.cf),a;t.call(b,13,a|2);return-1};l.Ih=function(a){return this.ya+a|0}; l.Kh=function(a){return this.ya+a|0};l.Hh=function(a,b){return(a>>>0)+b<=this.C?this.ya+a|0:this.wf()};l.zj=function(a,b){return(a>>>0)+b>this.C?this.ya+a|0:this.wf()};l.wf=function(){t.call(this.A,13,0);return-1};l.Jh=function(a,b){return(a>>>0)+b<=this.C?this.ya+a|0:this.xf()};l.Aj=function(a,b){return(a>>>0)+b>this.C?this.ya+a|0:this.xf()};l.xf=function(){t.call(this.A,13,0);return-1}; function Cc(a,b,c,d,e){a.ja=b;a.ya=d;a.Za=e;a.C=(e>>>0)+1;a.lb=c;a.type=c&7936;a.ext=c>>16&192;a.hc=(b&4?a.A.Zb.ya:a.A.ub)+(b&65528)|0;4>a.id&&Ac(a,!0)}function Dc(a,b,c){var d=a.A,e=d.ga(b+2),f=d.ga(b)|(e&255)<<16,d=d.ga(b+4);a.ja=c;a.ya=f;a.Za=d;a.C=(d>>>0)+1;a.lb=e;a.type=e&7936;a.ext=0;a.hc=b;4>a.id&&Ac(a,!0)} function Bc(a,b,c,d){var e=a.A;if(!d&&c===a.B.ja)return a.ja=c,a.ya=a.B.ya,a.Za=a.B.Za,a.C=(a.B.Za>>>0)+1,a.lb=a.B.lb,a.type=a.B.type,a.ext=a.B.ext,a.hc=a.B.hc,a.B.ja=-1,Ac(a,!0,!0,!1),a.ya;a.B.ja=-1;var f=e.ga(b+0),g=e.ga(b+4),h=g&7936,k=e.ga(b+2)|(g&255)<<16,m=e.ga(b+6),p=c&65528;if(80386<=e.ca){var x=f,k=k|(m&65280)<<16,f=f|(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case 1:var r=a.D;a.pe=!1;if(r&&1==c&&a.G.length){var z=a.G[a.cf-1];if(z&&!z())return-1}var E=c&3,J=(g&24576)>>13,z=-1,W,da;p|| @@ -77,13 +77,13 @@ function Fc(a,b,c){var d=a.A,e=a.sb,f=d.ia.ja,g=d.ia.ya;if(!c){if(!(d.ia.type&51 34,d.pa.ja),d.bb(g+36,d.Ba.ja),d.bb(g+38,d.S.ja),d.bb(g+40,d.xa.ja),d.Zb.load(d.ga(h+42)),Nc(d,d.ga(h+16)|(c?16384:0)),d.J=d.ga(h+18),d.G=d.ga(h+20),d.M=d.ga(h+22),d.D=d.ga(h+24),d.K=d.ga(h+28),d.I=d.ga(h+30),d.H=d.ga(h+32),d.pa.load(d.ga(h+34)),d.xa.load(d.ga(h+40)),Pc(d,d.ga(h+14),d.ga(h+36)),b=38,g=26,a.sb>>0)+1)}; -function Ac(a,b,c,d){void 0===c&&(c=!!(a.A.Pa&1));a.yd=!1;if(c)if(a.load=a.Cf,a.Vh=a.Sk,a.Pb=a.Hh,a.Qb=a.Jh,void 0===d&&(d=!!(a.A.W&131072)),d)a.load=a.L,a.Pb=a.I,a.Qb=a.K,a.sb=a.nc=3,a.U=a.Nc=2,a.N=a.sa=65535,a.Za=65535,a.C=a.Za+1,a.Nc=a.U,a.hc=-1,a.pe=!1;else{if(!(a.ja&-4))a.Pb=a.wf,a.Qb=a.xf;else if(a.type&4096){6144==(a.type&6656)&&(a.Pb=a.wf);if(a.type&2048||!(a.type&512))a.Qb=a.xf;1024==(a.type&3072)&&(a.Pb==a.Hh&&(a.Pb=a.zj),a.Qb==a.Jh&&(a.Qb=a.Aj),a.yd=!0);b&&6>a.id&&a.ja&-4&&-1!==a.hc&&(c= -a.hc+5,d=a.A.Jb(c),d&1||a.A.Mc(c,d|1))}b&&(a.sb=a.ja&3,a.nc=(a.lb&24576)>>13,80386>a.A.ca||!(a.ext&64)?(a.U=2,a.N=65535):(a.U=4,a.N=-1),a.Nc=a.U,a.sa=a.N)}else a.load=a.Wh,a.Vh=a.Tk,a.Pb=a.Ih,a.Qb=a.Kh,a.sb=a.nc=0,a.hc=-1,a.pe=!1} +function Ac(a,b,c,d){void 0===c&&(c=!!(a.A.Pa&1));a.yd=!1;if(c)if(a.load=a.Cf,a.Vh=a.Tk,a.Pb=a.Hh,a.Qb=a.Jh,void 0===d&&(d=!!(a.A.W&131072)),d)a.load=a.L,a.Pb=a.I,a.Qb=a.K,a.sb=a.nc=3,a.U=a.Nc=2,a.N=a.sa=65535,a.Za=65535,a.C=a.Za+1,a.Nc=a.U,a.hc=-1,a.pe=!1;else{if(!(a.ja&-4))a.Pb=a.wf,a.Qb=a.xf;else if(a.type&4096){6144==(a.type&6656)&&(a.Pb=a.wf);if(a.type&2048||!(a.type&512))a.Qb=a.xf;1024==(a.type&3072)&&(a.Pb==a.Hh&&(a.Pb=a.zj),a.Qb==a.Jh&&(a.Qb=a.Aj),a.yd=!0);b&&6>a.id&&a.ja&-4&&-1!==a.hc&&(c= +a.hc+5,d=a.A.Jb(c),d&1||a.A.Mc(c,d|1))}b&&(a.sb=a.ja&3,a.nc=(a.lb&24576)>>13,80386>a.A.ca||!(a.ext&64)?(a.U=2,a.N=65535):(a.U=4,a.N=-1),a.Nc=a.U,a.sa=a.N)}else a.load=a.Wh,a.Vh=a.Uk,a.Pb=a.Ih,a.Qb=a.Kh,a.sb=a.nc=0,a.hc=-1,a.pe=!1} function Rc(a){this.ca=a.model||8088;var b=a.stepping;this.pd=this.ca+(b?ca(b,16):0);b=0;switch(this.ca){default:b=4772727;break;case 80286:b=6E6;break;case 80386:b=16E6}hc.call(this,a,b);this.qh=61442;this.od=1792;this.ph=28672;this.ae=4;this.Da=255;this.B=80286<=this.ca?fb:eb;this.ma=Sc;this.th=Tc;this.uh=Uc;this.vh=Vc;if(80186<=this.ca&&(this.ma=Sc.slice(),this.th=Tc.slice(),this.uh=Uc.slice(),this.Da=31,this.ma[15]=Wc,this.ma[96]=Xc,this.ma[97]=Yc,this.ma[98]=Zc,this.ma[99]=Wc,this.ma[100]=Wc, this.ma[101]=Wc,this.ma[102]=Wc,this.ma[103]=Wc,this.ma[104]=$c,this.ma[105]=ad,this.ma[106]=bd,this.ma[107]=cd,this.ma[108]=dd,this.ma[109]=ed,this.ma[110]=fd,this.ma[111]=gd,this.ma[192]=hd,this.ma[193]=id,this.ma[200]=jd,this.ma[201]=kd,this.ma[241]=ld,this.th[7]=md,this.uh[7]=md,80286<=this.ca)){this.qh=2;this.od|=28672;this.ae=0;this.ma[15]=nd;this.Zc=od.slice();for(a=0;a=this.pd&&(this.Zc[166]=xd,this.Zc[167]=yd)}}this.of=[];this.sh=[];this.Vf=0;kc(this);this.ea.Le=this.ea.Hj=!1;this.xh=0;this.vc=this.R=[];this.da=this.vb=this.pb=this.mf=this.Yd=this.Fa=this.oc=0;zd(this)}Qa(Rc,hc); function Bb(a){var b;if(a.R===a.vc){a.R=Array(a.mf);a.pf=new q(null,0,0,5,null,a);sb(a.pf,a.Ia);for(b=0;ba.qf&&(a.rh[a.qf++]=d);a.R[b]=a.pf}a.nf=[]} -function Zb(a,b,c,d){var e=(b&-4194304)>>>20,f=a.vc[(a.dd+e&a.Fa)>>>a.da],g=f.Fd(e);if(!(g&1))return d||Ad.call(a,b,!1,c),a.Zd;if(!(g&4)&&3==a.za)return d||Ad.call(a,b,!0,c),a.Zd;var h=(b&4190208)>>>10,g=a.vc[((g&-4096)+h&a.Fa)>>>a.da],k=g.Fd(h);if(!(k&1))return d||Ad.call(a,b,!1,c),a.Zd;if(!(k&4)&&3==a.za)return d||Ad.call(a,b,!0,c),a.Zd;c=a.vc[((k&-4096)+(b&4095)&a.Fa)>>>a.da];if(d)return c;d=b>>>a.da;k=a.R[d];b=b&-4096;var m;0>>20,f=a.vc[(a.dd+e&a.Fa)>>>a.da],g=f.Fd(e);if(!(g&1))return d||Ad.call(a,b,!1,c),a.Zd;if(!(g&4)&&3==a.za)return d||Ad.call(a,b,!0,c),a.Zd;var h=(b&4190208)>>>10,g=a.vc[((g&-4096)+h&a.Fa)>>>a.da],k=g.Fd(h);if(!(k&1))return d||Ad.call(a,b,!1,c),a.Zd;if(!(k&4)&&3==a.za)return d||Ad.call(a,b,!0,c),a.Zd;c=a.vc[((k&-4096)+(b&4095)&a.Fa)>>>a.da];if(d)return c;d=b>>>a.da;k=a.R[d];b=b&-4096;var m;0>2;b.C=g;b.G=h>>2;db&&Hb&&c.V&&!c.controller&&!c.ge&&!c.he?(b.Ka=c.Ka,b.ud=c.ud,b.V=c.V,Eb(b,gc)):(b.K=c?Xb(32):0,b.S=c?Xb(96):0,Eb(b,ec));sb(b,a.Ia,k);a.R[d]=b;a.nf.push(d);return b}function Bd(a){a.R!==a.vc&&(a.R=a.vc,a.pf=null,a.nf=null,a.Zd=null)}l=Rc.prototype;l.reset=function(){this.ea.Sb&&oc(this);zd(this);kc(this);this.ea.Yc=!1}; function Cd(a,b){var c;switch(b){case 0:c=a.J;break;case 1:c=a.G;break;case 2:c=a.M;break;case 3:c=a.D;break;case 4:c=w(a);break;case 5:c=a.K;break;case 6:c=a.I;break;case 7:c=a.H}return c}function Dd(a,b,c){switch(b){case 0:a.J=c;break;case 1:a.G=c;break;case 2:a.M=c;break;case 3:a.D=c;break;case 4:v(a,c);break;case 5:a.K=c;break;case 6:a.I=c;break;case 7:a.H=c}} function zd(a){a.J=0;a.D=0;a.G=0;a.M=0;a.Nb=0;a.K=0;a.I=0;a.H=0;a.Hb=!1;a.ua=a.Ga=0;a.oa=0;a.wh=0;a.X=0;a.Pa=65520;a.Ab=0;a.xc=1023;a.W=a.Cb=0;a.Hd=a.Kd=a.sd=a.Id=0;a.fc=-1;a.Gc=a.ic=-1;a.Dd=a.ka=-1;a.Ba=new zc(a,1,"CS");a.xa=new zc(a,2,"DS");a.pa=new zc(a,2,"ES");a.S=new zc(a,3,"SS");v(a,0);Ec(a,0);if(80386<=a.ca){switch(a.pd){case 80562:case 80563:a.M=771;break;case 80578:a.M=772;break;case 80594:a.M=773;break;case 80595:case 80596:a.M=776}a.Pa=16;a.Ah=0;a.rd=0;a.dd=0;a.qb=[0,0,0,0,null,null,0, @@ -348,8 +348,8 @@ var be=[function(){this.A-=2+(-1===this.F?0:1);return this.Zb.ja},function(){thi var b=this.Ab;80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.U&&(a|=b<<16);this.Va(this.F+2,b);this.A-=12}return a},function(a){-1===this.F||this.W&131072?t.call(this,6):(this.ub=this.fa(this.F+2)&(this.N|this.N<<8),a&=65535,this.wc=this.ub+a,this.L|=2,this.A-=11);return a},function(a){-1===this.F||this.W&131072?t.call(this,6):(this.Ab=this.fa(this.F+2)&(this.N|this.N<<8),a&=65535,this.xc=this.Ab+a,this.L|=2,this.A-=12);return a},function(){this.A-=2+(-1===this.F?0:1);return this.Pa},R,function(a){this.W& 131072?t.call(this,6):(Be(this,a),this.A-=-1===this.F?3:6,this.L|=2);return a},R],yi=[R,R,R,R,fg,ig,hg,gg]; function S(a){Ia.call(this,"ChipSet",a,S);var b=a.model;b&&!zi[b]&&n("Unrecognized ChipSet model: "+b);this.ca=b&&zi[b]||Ai;this.D=[];b=Bi(a[Ci]);this.D[0]=[b,b];null==b&&(this.Y=[360,360],(b=a.floppies)&&b.length&&(this.Y=b),Di(this,Ei,this.Y.length),Di(this,Fi,a.monitor||(this.ca=Re&&(this.Ea=this.pa=2);this.ba=a.scaleTimers||!1;this.Xa=a.rtcDate;this.Oa=!1;a.sound&&(this.La=this.qa=null,window&&(this.La=window.AudioContext|| -window.webkitAudioContext),this.La&&(this.qa=new this.La));this.reset(!0);ab(this)}Qa(S);var Ai=5150.9,Re=5170,zi={5150:5150,5160:5160,5170:Re,att6300:5160.101,mpc1600:5150.101,z150:5160.15,compaq:5150.102,other:Ai,deskpro386:5180},Ci="sw1",Gi="sw2",Hi={uj:1,ONE:0,Im:64,Gm:128,km:192,lc:192,Zf:6},Ii={Hm:16,dm:32,sm:48,lc:48,Zf:4},Ei=1,Fi=4,T={5150:[{},{}]};T[5150][0][Ei]={lc:192,Oc:{1:0,2:64,3:128,4:192},gd:"Number of Floppy Drives"};T[5150][0][3]={lc:2,Oc:{0:0,1:2},gd:"Coprocessor"}; -T[5150][0][Fi]={lc:48,Oc:{0:0,1:16,2:32,3:48,none:0,tv:16,color:32,mono:48,ega:0,vga:0},gd:"Monitor Type"};T[5150][0][5]={lc:12,Oc:{16:0,32:4,48:8,64:12},gd:"Base Memory (16Kb Increments)"};T[5150][1][6]={lc:31,Oc:{0:0,32:1,64:2,96:3,128:4,160:5,192:6,224:7,256:8,288:9,320:10,352:11,384:12,416:13,448:14,480:15,512:16,544:17,576:18},gd:"Expansion Memory (32Kb Increments)"};T[5160]=[{},{}];T[5160][0][Ei]=T[5150][0][Ei];T[5160][0][3]=T[5150][0][3];T[5160][0][Fi]=T[5150][0][Fi]; +window.webkitAudioContext),this.La&&(this.qa=new this.La));this.reset(!0);ab(this)}Qa(S);var Ai=5150.9,Re=5170,zi={5150:5150,5160:5160,5170:Re,att6300:5160.101,mpc1600:5150.101,z150:5160.15,compaq:5150.102,other:Ai,deskpro386:5180},Ci="sw1",Gi="sw2",Hi={uj:1,ONE:0,Jm:64,Hm:128,lm:192,lc:192,Zf:6},Ii={Im:16,em:32,tm:48,lc:48,Zf:4},Ei=1,Fi=4,T={5150:[{},{}]};T[5150][0][Ei]={lc:192,Oc:{1:0,2:64,3:128,4:192},gd:"Number of Floppy Drives"};T[5150][0][3]={lc:2,Oc:{0:0,1:2},gd:"Coprocessor"}; +T[5150][0][Fi]={lc:48,Oc:{0:0,1:16,2:32,3:48,none:0,tv:16,color:32,cga:32,mda:48,mono:48,ega:0,vga:0},gd:"Monitor Type"};T[5150][0][5]={lc:12,Oc:{16:0,32:4,48:8,64:12},gd:"Base Memory (16Kb Increments)"};T[5150][1][6]={lc:31,Oc:{0:0,32:1,64:2,96:3,128:4,160:5,192:6,224:7,256:8,288:9,320:10,352:11,384:12,416:13,448:14,480:15,512:16,544:17,576:18},gd:"Expansion Memory (32Kb Increments)"};T[5160]=[{},{}];T[5160][0][Ei]=T[5150][0][Ei];T[5160][0][3]=T[5150][0][3];T[5160][0][Fi]=T[5150][0][Fi]; T[5160][0][5]={lc:12,Oc:{64:0,128:4,192:8,256:12},gd:"Base Memory (64Kb Increments)"};T[5160][1][6]=T[5150][1][6];T[5160.101]=[{},{}];T[5160.101][0][5]={lc:143,Oc:{128:1,256:130,512:8,640:141},gd:"Base Memory (128Kb Increments)"};T[5160.101][0][3]={lc:16,Oc:{0:0,1:16},gd:"Coprocessor"};T[5160.101][1][2]={lc:1,Oc:{0:0,1:1},gd:"Floppy Type"};T[5160.101][1][Ei]=T[5150][0][Ei];T[5160.101][1][Fi]=T[5150][0][Fi];l=S.prototype; l.zb=function(a,b,c){switch(b){case Ci:return this.la[b]=c,Ji(this,0,b),!0;case Gi:if(5150==(this.ca|0)||5160.101==this.ca)return this.la[b]=c,Ji(this,1,b),!0;break;case "swdesc":return this.la[b]=c,!0}return!1}; l.pc=function(a,b,c,d){this.ha=b;this.A=c;this.Ia=d;this.aa=a;this.qd=kb(a,"FPU");Di(this,3,this.qd?1:0,!0);this.C=kb(a,"Keyboard");this.Ga=c.T.ad/1193181;Nb(b,this,Ki);Pb(b,this,Li);this.ca=a;a++)this.B[a]=0;for(a=14;46>a;a++)void 0===this.B[a]&&(this.B[a]=0);a=0|+Zi(this,Fi,void 0)<c;c++)b+=a.B[c];a.B[47]=b&255;a.B[46]=b>>8} -l.save=function(){var a=new ce(this);C(a,0,[this.D]);for(var b=[],c=0;c=Re&&(C(a,5,[this.H,this.S,this.R,this.ua,this.X,this.va]),C(a,6,[this.I[7],this.I,this.da,this.B,this.ra,this.ia]));return a.data()}; l.restore=function(a){var b,c;b=a[0];Array.isArray(b[0])?this.D=b[0]:(this.D[0][0]=b[0],this.D[1][0]=b[1]&15,this.D[0][1]=b[2],this.D[1][1]=b[3]&15);Ui(this);b=a[1];for(c=0;c=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
'+f+"
\n"}e.innerHTML=d;jj(a,b,c,!0)}function kj(a,b,c){if(b=(a=T[a.ca|0])&&a[b])for(var d in b)if(a=b[d],a.lc&1<d.hb[0]&&(d.hb[0]=255,d.hb[1]--,0>d.hb[1]&&(d.hb[1]=255)));return e}function qj(a,b,c,d){a=a.G[b];c=a.$b[c];c.hb[a.Ib]=c.jc[a.Ib]=d;a.Ib^=1} -function rj(a,b){var c=a.G[b],d=c.Db|1;c.Db&=-16;return d}function wj(a,b,c){a=a.G[b];b=c&3;a.Db=a.Db&~(16<>2].$b[b&3],c,d,e)} +function rj(a,b){var c=a.G[b],d=c.Db|1;c.Db&=-16;return d}function wj(a,b,c){a=a.G[b];b=c&3;a.Db=a.Db&~(16<>2].$b[b&3],c,d,e)} function yj(a,b,c){b=a.G[b>>2].$b[b&3];b.yf&&b.kg&&b.Mf?(c&&(b.done=c),b.Qd||Dj(a,b,!0)):c&&c(!0)}function Dj(a,b,c){c&&(b.count=b.hb[1]<<8|b.hb[0],b.type=b.mode&12,b.Rh=b.Yc=!1);for(var d=!1;0<=b.count&&(c=b.tf<<16|b.gb[1]<<8|b.gb[0],4==b.type?(d=!0,function(c){b.kg.call(b.yf,b.Mf,-1,function(f,g){0>f&&(b.Rh||(b.Rh=!0),f=255);b.Qd||a.ha.Mc(c,f);(d=g)&&setTimeout(function(){Ej(b)||Dj(a,b)},0)})}(c)):8==b.type?(c=a.ha.Jb(c),0>b.kg.call(b.yf,b.Mf,c)&&(b.Yc=!0)):0!=b.type&&(b.Yc=!0)),!d&&!Ej(b););} function Ej(a){if(!a.Yc&&0<=--a.count&&(a.mode&32?(a.gb[0]--,0>a.gb[0]&&(a.gb[0]=255,a.gb[1]--,0>a.gb[1]&&(a.gb[1]=255))):(a.gb[0]++,255f&&(d.ld=e,f=0);var g=Nj(a,b),h=xc(a,b)-f;0==d.mode?(0>=h&&(h=0),h||(d.Tc=!0,d.Od=!1,b||Te(a,0))):4==d.mode?(d.Tc=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.Ec[0]=h&255,d.Ec[1]=h>>8&255,d.ld=e,!b&&d.Tc&&Te(a,0))):6==d.mode&&(h-=f,0>=h&&(d.Tc=!d.Tc,h=g+h,0>=h&&(h=g),d.Ec[0]=h&255,d.Ec[1]=h>>8&255,d.ld=e,!b&&d.Tc&&Te(a,0)));d.hb[0]=h&255;d.hb[1]=h>>8&255;c&&(a.ld=0)}return d} function wc(a,b){for(var c=0;c=Re){var c=a.A.T.ad,d=tc(a.A,a.ba);null==a.Fa&&(a.ra=tc(a.A,a.ba),a.Ta=1024,a.Fa=Math.floor(a.A.T.ad/a.Ta),cj(a));d>=a.ia&&(a.B[12]|=64,a.B[11]&64&&(a.B[12]|=128,Te(a,8)),a.ia=d+a.Fa);a.B[0]==a.B[1]&&a.B[2]==a.B[3]&&a.B[4]==a.B[5]&&(a.B[12]|=32,a.B[11]&32&&(a.B[12]|=128,Te(a,8)));var e=d-a.ra,f=Math.floor(e/c);if(f&&!(a.B[11]&128)){for(;f--;)if(60<=++a.B[0]&&(a.B[0]=0,60<=++a.B[2]&&(a.B[2]=0,24<=++a.B[4]))){a.B[4]=0;a.B[6]=a.B[6]%7+1; -var g;g=a.B[9];var h=ma[a.B[8]-1];28==h&&0===g%4&&(g%100||0===g%400)&&h++;g=h;++a.B[7]>g&&(a.B[7]=1,12<++a.B[8]&&(a.B[8]=1,a.B[9]=(a.B[9]+1)%100))}a.B[12]|=16;a.B[11]&16&&(a.B[12]|=128,Te(a,8))}a.ra=d-e%c}}l=S.prototype;l.Ak=function(){var a=this.Da;this.oa&16&&(this.P&128?a=this.D[0][1]:this.C&&(a=Qj(this.C)));return a};l.Nl=function(a,b){this.Da=b};l.Bk=function(){return this.P};l.Ol=function(a,b){Rj(this,b)}; -function Rj(a,b){var c=!!(b&2),d=!!(a.P&2);a.P=b;a.C&&Sj(a.C,!(b&128),!!(b&64));c!=d&&vc(a,c)}l.Ck=function(){var a=0,a=5150==(this.ca|0)?this.P&4?a|this.D[1][1]&15:a|this.D[1][1]>>4&1:this.P&8?a|this.D[0][1]>>4:a|this.D[0][1]&15;this.P&1&&Lj(this,2).Tc&&(a=this.P&2?a|32:a|16);return a};l.Pl=function(a,b){this.Ja=b};l.Dk=function(){return this.oa};l.Ql=function(a,b){this.oa=b};l.Mj=function(){var a=this.C?Qj(this.C):0;this.ka&=-2;return a};l.Zk=function(){};l.Lj=function(){return this.P}; -l.Yk=function(a,b){Rj(this,b)};l.Nj=function(){return this.ka};l.Oj=function(){var a=this.ua;this.H&=-258;this.C&&Tj(this.C);return a};l.al=function(a,b){if(this.H&8)switch(this.S){case 96:Uj(this,b);break;case 209:Vj(this,b);break;default:if(Uj(this,this.R&-17),this.C){var c=this.C,d=b,e=-1;switch(c.G||d){case 255:e=250;c.Ob=[];Wj(c,170);break;case 243:c.G&&(d=0);Wj(c,250);c.G=d;break;case 237:c.G&&(d=0),Wj(c,250),c.G=d}Xj(this,e)}}this.S=b;this.H&=-9}; -l.Pj=function(){return this.P&-209|(tc(this.A)&64?16:0)};l.bl=function(a,b){Rj(this,b)};l.Qj=function(){var a=this.H&255;this.H&256&&(this.H|=1,this.H&=-257);return a}; -l.$k=function(a,b){this.S=b;this.H|=8;var c=0;240<=this.S&&(c=this.S^15,this.S=240);switch(this.S){case 32:Xj(this,this.R);break;case 173:Uj(this,this.R|16);break;case 174:Uj(this,this.R&-17);this.C&&Tj(this.C);break;case 170:this.C&&(this.C.Ob=[]);Uj(this,this.R|16);Xj(this,85);Vj(this,3);break;case 171:Xj(this,0);break;case 192:Xj(this,this.X);break;case 208:Xj(this,this.va);break;case 224:Xj(this,this.R&16?0:1);break;case 240:c&1&&zd(this.A)}}; -function Uj(a,b){a.R=b;a.H=a.H&-5|b&4;a.C&&Sj(a.C,!!(b&8),!(b&16))}function Xj(a,b,c){0<=b&&(a.ua=b,c?a.H|=1:(a.H&=-2,a.H|=256))}function Vj(a,b){a.va=b;xb(a.ha,!!(b&2));b&1||zd(a.A)}function Yj(a,b){a.cag&&(a.B[7]=1,12<++a.B[8]&&(a.B[8]=1,a.B[9]=(a.B[9]+1)%100))}a.B[12]|=16;a.B[11]&16&&(a.B[12]|=128,Te(a,8))}a.ra=d-e%c}}l=S.prototype;l.Bk=function(){var a=this.Da;this.oa&16&&(this.P&128?a=this.D[0][1]:this.C&&(a=Qj(this.C)));return a};l.Ol=function(a,b){this.Da=b};l.Ck=function(){return this.P};l.Pl=function(a,b){Rj(this,b)}; +function Rj(a,b){var c=!!(b&2),d=!!(a.P&2);a.P=b;a.C&&Sj(a.C,!(b&128),!!(b&64));c!=d&&vc(a,c)}l.Dk=function(){var a=0,a=5150==(this.ca|0)?this.P&4?a|this.D[1][1]&15:a|this.D[1][1]>>4&1:this.P&8?a|this.D[0][1]>>4:a|this.D[0][1]&15;this.P&1&&Lj(this,2).Tc&&(a=this.P&2?a|32:a|16);return a};l.Ql=function(a,b){this.Ja=b};l.Ek=function(){return this.oa};l.Rl=function(a,b){this.oa=b};l.Mj=function(){var a=this.C?Qj(this.C):0;this.ka&=-2;return a};l.$k=function(){};l.Lj=function(){return this.P}; +l.Zk=function(a,b){Rj(this,b)};l.Nj=function(){return this.ka};l.Oj=function(){var a=this.ua;this.H&=-258;this.C&&Tj(this.C);return a};l.bl=function(a,b){if(this.H&8)switch(this.S){case 96:Uj(this,b);break;case 209:Vj(this,b);break;default:if(Uj(this,this.R&-17),this.C){var c=this.C,d=b,e=-1;switch(c.G||d){case 255:e=250;c.Ob=[];Wj(c,170);break;case 243:c.G&&(d=0);Wj(c,250);c.G=d;break;case 237:c.G&&(d=0),Wj(c,250),c.G=d}Xj(this,e)}}this.S=b;this.H&=-9}; +l.Pj=function(){return this.P&-209|(tc(this.A)&64?16:0)};l.cl=function(a,b){Rj(this,b)};l.Qj=function(){var a=this.H&255;this.H&256&&(this.H|=1,this.H&=-257);return a}; +l.al=function(a,b){this.S=b;this.H|=8;var c=0;240<=this.S&&(c=this.S^15,this.S=240);switch(this.S){case 32:Xj(this,this.R);break;case 173:Uj(this,this.R|16);break;case 174:Uj(this,this.R&-17);this.C&&Tj(this.C);break;case 170:this.C&&(this.C.Ob=[]);Uj(this,this.R|16);Xj(this,85);Vj(this,3);break;case 171:Xj(this,0);break;case 192:Xj(this,this.X);break;case 208:Xj(this,this.va);break;case 224:Xj(this,this.R&16?0:1);break;case 240:c&1&&zd(this.A)}}; +function Uj(a,b){a.R=b;a.H=a.H&-5|b&4;a.C&&Sj(a.C,!!(b&8),!(b&16))}function Xj(a,b,c){0<=b&&(a.ua=b,c?a.H|=1:(a.H&=-2,a.H|=256))}function Vj(a,b){a.va=b;xb(a.ha,!!(b&2));b&1||zd(a.A)}function Yj(a,b){a.ca=c)if(d=this.B[c],10>c){var e=!1;4!=c&&5!=c||this.B[11]&2||(12>d?d=d?d:12:d=(d-=12)?d+128:140,e=!0);this.B[11]&4||(e&&128=c){if(e=b,10>c){var f=!1;this.B[11]&4||(e=10*(e>>4)+(e&15),f=!0);if(4==c||5==c)f&&23=e?e=12==e?0:e:(e-=116,e=24==e?12:e))}}else e=b;this.B[c]=e;11==c&&d&64&&b&64&&cj(this)};l.dj=function(a,b){this.ma=b};l.Al=function(){};l.Bl=function(){this.qd&&Ne(this.qd)}; +l.rl=function(a,b){var c=this.da&63,d=b^this.B[c],e;if(13>=c){if(e=b,10>c){var f=!1;this.B[11]&4||(e=10*(e>>4)+(e&15),f=!0);if(4==c||5==c)f&&23=e?e=12==e?0:e:(e-=116,e=24==e?12:e))}}else e=b;this.B[c]=e;11==c&&d&64&&b&64&&cj(this)};l.dj=function(a,b){this.ma=b};l.Bl=function(){};l.Cl=function(){this.qd&&Ne(this.qd)}; function vc(a,b){if(a.qa)try{void 0!==b?a.Oa=b:b=a.Oa&&a.A&&a.A.ea.Sb;var c=Math.round(1193181/Nj(a,2));if(20>c||2E4>>4,0,this.I,this.D,this.K),delete this.K);return!0};ak.prototype.Ub=function(){return!0}; @@ -410,8 +410,8 @@ l.reset=function(){if(!this.C&&!this.G&&this.P){var a=1024*Yi(this.P);this.B&&a! 1]=c>>8;bj(a)}}else n("No RAM allocated")};l.save=function(){var a=new ce(this);this.controller&&C(a,0,this.controller.save());return a.data()};l.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function gk(a){this.G=a;this.C=ik;this.D=jk;this.B=kk;this.A=null}var hk=-2134900736,ik=65535,jk=2575,kk=2,lk=[null,0],mk=[function(a){return this.controller.Jb(a)},null,null,function(a,b){this.controller.Mc(a,b)},null,null];l=gk.prototype;l.save=function(){return[this.C,this.B]}; l.restore=function(a){this.Mc(0,a[0]&255);this.Mc(2,a[1]&255);return!0};l.Jb=function(a){var b=255;2>a?b=a&1?this.D>>8:this.D&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b};l.Mc=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){var c=this.G.ha;if(b&1)this.A&&(Cb(c,917504,131072,this.A),this.A=null);else{this.A||(this.A=Db(c,917504,131072));var d=Db(c,16646144,131072);Cb(c,917504,131072,d,b&2?1:Gb)}this.C=this.C&-256|b}};l.Th=function(){return lk};l.lg=function(){return mk}; Ea(function(){for(var a=Za(document,"pcjs","ram"),b=0;b":62,"?":63,"@":64,am:65,bm:66,cm:67,hm:68,E:69,im:70,lm:71,mm:72,nm:73,om:74,pm:75,qm:76,rm:77,tm:78,um:79,vm:80,Q:81,wm:82,Am:83,Fm:84,Jm:85,Km:86,Lm:87,Nm:88,Om:89,Pm:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Qm:97,Rm:98,Tm:99,d:100,e:101,Um:102,Vm:103,Wm:104, -Xm:105,Ym:106,k:107,Zm:108,$m:109,n:110,bn:111,p:112,q:113,r:114,cn:115,t:116,dn:117,en:118,fn:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126},qk={};qk[186]=U[";"];qk[187]=U["="];qk[188]=U[","];qk[189]=U["-"];qk[190]=U["."];qk[191]=U["/"];qk[192]=U["`"];qk[219]=U["["];qk[220]=U["\\"];qk[221]=U["]"];qk[222]=U["'"];qk[173]=U["-"];var V={};V[U["1"]]=U["!"];V[U["2"]]=U["@"];V[U["3"]]=U["#"];V[U["4"]]=U.$;V[U["5"]]=U["%"];V[U["6"]]=U["^"];V[U["7"]]=U["&"];V[U["8"]]=U["*"];V[U["9"]]=U["("]; +var pk=["US83","US84","US101"],U={fm:1,gm:3,hm:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,bm:65,cm:66,dm:67,im:68,E:69,jm:70,mm:71,nm:72,om:73,pm:74,qm:75,rm:76,sm:77,um:78,vm:79,wm:80,Q:81,xm:82,Bm:83,Gm:84,Km:85,Lm:86,Mm:87,Om:88,Pm:89,Qm:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Rm:97,Sm:98,Um:99,d:100,e:101,Vm:102,Wm:103,Xm:104, +Ym:105,Zm:106,k:107,$m:108,an:109,n:110,cn:111,p:112,q:113,r:114,dn:115,t:116,en:117,fn:118,gn:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126},qk={};qk[186]=U[";"];qk[187]=U["="];qk[188]=U[","];qk[189]=U["-"];qk[190]=U["."];qk[191]=U["/"];qk[192]=U["`"];qk[219]=U["["];qk[220]=U["\\"];qk[221]=U["]"];qk[222]=U["'"];qk[173]=U["-"];var V={};V[U["1"]]=U["!"];V[U["2"]]=U["@"];V[U["3"]]=U["#"];V[U["4"]]=U.$;V[U["5"]]=U["%"];V[U["6"]]=U["^"];V[U["7"]]=U["&"];V[U["8"]]=U["*"];V[U["9"]]=U["("]; V[U["0"]]=U[")"];V[186]=U[":"];V[187]=U["+"];V[188]=U["<"];V[189]=U._;V[190]=U[">"];V[191]=U["?"];V[192]=U["~"];V[219]=U["{"];V[220]=U["|"];V[221]=U["}"];V[222]=U['"'];V[173]=U._;V[61]=U["+"];V[59]=U[":"]; var rk={3016:1,1016:2,1017:8,1018:32,1091:128,1093:64,1224:128,1020:512,1144:1024,1145:2048},sk={TAB:1009,ESC:1027,F1:1112,F2:1113,F3:1114,F4:1115,F5:1116,F6:1117,F7:1118,F8:1119,F9:1120,F10:1121,LEFT:1037,UP:1038,RIGHT:1039,DOWN:1040,SYSREQ:4027,CTRL_C:4003,CTRL_BREAK:4008,CTRL_ALT_DEL:4046,CTRL_ALT_INS:4045,CTRL_ALT_ENTER:4013},tk={esc:1027,1:U["1"],2:U["2"],3:U["3"],4:U["4"],5:U["5"],6:U["6"],7:U["7"],8:U["8"],9:U["9"],0:U["0"],"-":U["-"],"=":U["="],bs:1008,tab:1009,q:81,w:87,e:69,r:82,t:84,y:89, u:85,i:73,o:79,p:80,"[":U["["],"]":U["]"],enter:13,ctrl:1017,a:65,s:83,d:68,f:70,g:71,h:72,j:74,k:75,l:76,";":U[";"],quote:U["'"],"`":U["`"],shift:1016,"\\":U["\\"],z:90,x:88,c:67,v:86,b:66,n:78,m:77,",":U[","],".":U["."],"/":U["/"],"right-shift":3016,prtsc:1044,alt:1018,space:1032,"caps-lock":1020,f1:1112,f2:1113,f3:1114,f4:1115,f5:1116,f6:1117,f7:1118,f8:1119,f9:1120,f10:1121,"num-lock":1144,"scroll-lock":1145,"num-home":1036,"num-up":1038,"num-pgup":1033,"num-sub":1109,"num-left":1037,"num-center":1101, @@ -442,7 +442,7 @@ var Mk=[[0,0,0,255],[127,192,127,255],[127,192,127,255],[127,255,127,255],[127,2 16777215,-16777216,-16776961,-16711936,-16711681,-65536,-65281,-256,-1],Tk=[0];Tk[128]=1;Tk[32768]=2;Tk[32896]=3;Tk[8388608]=4;Tk[8388736]=5;Tk[8421376]=6;Tk[8421504]=7;Tk[-2147483648]=8;Tk[-2147483520]=9;Tk[-2147450880]=10;Tk[-2147450752]=11;Tk[-2139095040]=12;Tk[-2139094912]=13;Tk[-2139062272]=14;Tk[-2139062144]=15; function Uk(a,b,c,d){if(void 0!==b&&(!c||c.length)){this.video=a;var e=Vk[b],f=a.ma||e[5];if(!c||6>c.length)c=[!1,0,null,null,0,Array(5>b?Wk:Xk)];this.Ra=b;this.cb=e[2];this.Fb=e[3];this.Wc=d||e[4];65536<=this.Wc&&720896<=this.cb&&(this.Fb=Math.min(this.Wc>>2,32768));this.cc=c[0];this.Lc=c[1];this.ff=c[2];this.Z=c[3];this.sc=c[4]&255;this.Qf=c[4]>>8&255;this.ab=c[5];this.pg=Wk;if(5<=b){this.pg=Xk;b=c[6];void 0===b&&(b=[!1,0,Array(20),0,3==f?0:1,0,0,Array(5),0,0,0,Array(9),0,[this.cb,this.Fb,this.Wc], Array(this.Wc>>2),-2147478512,0,-1,0,-1,0,-1,0,0,0,0,1,255,0,0,0,Array(256)]);this.Ke=b[0];this.Ud=b[1];this.Kc=b[2];this.kh=b[3];this.gf=b[4];this.Sf=b[5];this.Ce=b[6];this.Be=b[7];this.ej=b[8];this.fj=b[9];this.Ae=b[10];this.Gd=b[11];this.ob=b[12];d=b[13];"number"==typeof d&&(d=[this.cb,this.Fb,d]);this.cb=d[0];this.Fb=d[1];d=this.Wc>>2;if((this.td=b[14])&&this.td.length>this.controller.fh&255};Zk[17408]=function(a){return(this.controller.ob=this.V[(a&-4)+this.H])>>((a&3)<<3)&255};Zk[5120]=function(a){a+=this.H;var b=this.controller.ob=this.V[a&-2];return(a&1?b>>8:b)&255}; Zk[1280]=function(a){a+=this.H;a=this.controller.ob=this.V[a];for(var b=this.controller.rg,c=this.controller.qg&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};Zk[0]=function(a,b){var c=a+this.H,d;d=(b|b<<8|b<<16|b<<24)&this.controller.nd|this.controller.Cd;d=d&this.controller.tb|this.controller.ob&~this.controller.tb;d=d&this.controller.$a|this.V[c]&~this.controller.$a;this.V[c]!=d&&(this.V[c]=d,this.Ha=!0)}; Zk[32]=function(a,b){var c=a+this.H;b=b>>this.controller.Hc|b<<8-this.controller.Hc&255;var d;d=(b|b<<8|b<<16|b<<24)&this.controller.nd|this.controller.Cd;d=d&this.controller.tb|this.controller.ob&~this.controller.tb;d=d&this.controller.$a|this.V[c]&~this.controller.$a;this.V[c]!=d&&(this.V[c]=d,this.Ha=!0)}; @@ -490,31 +490,31 @@ function kl(a,b){if(a.ea.Rb){var c=!1,d=a.D;d&&(d!==a.B?d.Lc&8&&(c=!0):d.Ud&32&& a.S[d]=p,f++),c+=2,d++;a.qa=!0;f&&a.Ga&&a.X.drawImage(a.Fa,0,0,a.pb,a.qb,a.yc,a.zc,a.ic,a.mc);wl(a)}}else if(a.fc){for(var g=k,z,k=c,d=a.za=0,f=a.Hb,e=16==f?65536:196608,h=16==f?1:2,m=sl(a,h),x=p=0,r=a.H,E=0,J=a.L,W=0;k>8|(z&255)<<8;var da=e,ua=16;p>=h))>>(ua-=h);vl(a.Oa,p++,x,m[qd])}p>E&&(E=p);x=W&&(W=x+1)}k+=2;d++;if(p>=a.H){p=0;x+=2;if(x>a.L)break;x==a.L&&(x=1,k=c+a.fc)}}a.qa= !0;ra.H?a.Ta-a.H-z>>3:0;c>=8;m>r&&(r=m);p=J&&(J=p+1)}c+=W;if(m>=a.H){m=0;if(++p>a.L)break;c+=da}}z||(a.qa=!0);xa.H?a.Ta-a.H-J>>3:0;cda&&(ua=da)):(z<<=J,ua-=J,a.qa=!1):(a.qa&&z===a.S[d]?(h+=ua,ua=0):a.S[d]=z,d++);if(ua){hx&&(x=h);m=E&&(E=m+1)}if(h>=a.H){h=0;if(++m>a.L)break;c+=W}}J||(a.qa=!0);pd&&(b.wg=d,d=-d|0);d%b.sg>b.Vk&&(c|=1);d%b.vg>b.Xk&&(c|=9);b.gh=d/b.vg|0;return c}l.wk=function(){var a=this.ba,b;a.cc&&(b=a.sc);return b};l.Kl=function(a,b){var c=this.ba;c.Qf=c.sc;c.sc=b&31};l.vk=function(){return El(this.ba)};l.Jl=function(a,b){Fl(this,this.ba,b)};l.xk=function(){return this.ba.Lc};l.Ll=function(a,b){this.ba.Lc=b;ql(this,!1)};l.yk=function(){return Gl(this,this.ba)}; +r,x-p,E-r),a.X.drawImage(a.Fa,0,0,a.H,a.L,0,0,a.da,a.pa))}}}}function Dl(a,b){var c=0,d=tc(a.A)-b.wg;0>d&&(b.wg=d,d=-d|0);d%b.sg>b.Wk&&(c|=1);d%b.vg>b.Yk&&(c|=9);b.gh=d/b.vg|0;return c}l.xk=function(){var a=this.ba,b;a.cc&&(b=a.sc);return b};l.Ll=function(a,b){var c=this.ba;c.Qf=c.sc;c.sc=b&31};l.wk=function(){return El(this.ba)};l.Kl=function(a,b){Fl(this,this.ba,b)};l.yk=function(){return this.ba.Lc};l.Ml=function(a,b){this.ba.Lc=b;ql(this,!1)};l.zk=function(){return Gl(this,this.ba)}; l.cj=function(a,b){this.B.Sf=this.B.Sf&-4|b&3};l.Vj=function(){return this.B.Ud};l.vj=function(){return this.B.Kc[this.B.Ud&31]};l.bj=function(a,b){var c=this.B,d=c.Ud&32;if(c.Ke){c.Ke=!1;var e=c.Ud&31;if(16<=e||!d)c.Kc[e]=b,Bl(this,!1)}else c.Ud=b,c.Ke=!0,b&32&&!d&&ol(this,!0)&&kl(this,!0),d=(c.ab[12]<<8)+c.ab[13]|0,c.ed!=d&&(c.ed=d,Bl(this)),c.xe=0}; -l.Ik=function(){var a=0;if(5==this.Ra)a=3-((this.B.gf&12)>>2),a=(this.Bb&1<>this.B.Bc&63;this.B.Bc+=6;12>2),a=(this.Bb&1<>this.B.Bc&63;this.B.Bc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=(window?window.navigator.userAgent:"").indexOf("MSIE")&&(c.onresize=function(a, b,c,d){return function(){b.style.height=(a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());c.appendChild(e);var f=document.createElement("textarea");ya("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"));c.appendChild(f);var g=e.getContext("2d"),d=new Y(d,e,g,f,c);Ya(d,c)}}); function Hl(a){this.I=a.adapter;switch(this.I){case 1:this.G=956;this.D=7;break;case 2:this.G=888;this.D=7;break;case 3:this.G=632;this.D=5;break;default:n("Unrecognized parallel adapter #"+this.I);return}this.B=this.C=null;Ia.call(this,"ParallelPort",a,Hl);a=a.binding;"console"==a?this.C="":Xa(this,a,Il)}Qa(Hl);var Il="buffer";l=Hl.prototype;l.zb=function(a,b,c){switch(b){case Il:return this.la[b]=this.B=c,!0}return!1}; l.pc=function(a,b,c,d){this.ha=b;this.A=c;this.Ia=d;this.P=kb(a,"ChipSet");Nb(b,this,Jl,this.G);Pb(b,this,Kl,this.G);ab(this)};l.Vb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Ub=function(a){return a?this.save():!0};l.reset=function(){Ll(this)};l.save=function(){var a=new ce(this),b=0,c=[];c[b++]=this.H;c[b++]=this.Db;c[b]=this.Ie;C(a,0,c);return a.data()};l.restore=function(a){return Ll(this,a[0])}; -function Ll(a,b){var c=0;void 0===b&&(b=[0,0,0]);a.H=b[c++];a.Db=b[c++];a.Ie=b[c];return!0}l.jk=function(){return this.H};l.Hk=function(){return this.Db};l.fk=function(){return this.Ie}; -l.wl=function(a,b){this.H=b;this.Db|=64;var c;if(this.B)8==b?this.B.value=this.B.value.slice(0,-1):(this.B.value+=String.fromCharCode(b),this.B.scrollTop=this.B.scrollHeight),c=!0;else if(null!=this.C){if(10==b||1024<=this.C.length)this.rc(this.C),this.C="";10!=b&&(this.C+=String.fromCharCode(b));c=!0}else c=!1;c&&(this.Db&=-65);Ml(this)};l.rl=function(a,b){this.Ie=b;Ml(this)};function Ml(a){a.P&&a.D&&(a.Ie&16&&!(a.Db&64)?Te(a.P,a.D):Se(a.P,a.D))} -var Jl={0:Hl.prototype.jk,1:Hl.prototype.Hk,2:Hl.prototype.fk},Kl={0:Hl.prototype.wl,2:Hl.prototype.rl};Ea(function(){for(var a=Za(document,"pcjs","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64>8:this.X};l.rk=function(){return this.G};l.sk=function(){return this.I};l.uk=function(){return this.C};l.tk=function(){return this.B};l.zk=function(){return this.ia}; -l.Tl=function(a,b){if(this.I&128)this.R=this.R&-256|b;else{this.ka=b;this.B&=-97;var c;if(this.D){if(13==b)this.L=0;else if(8==b)this.D.value=this.D.value.slice(0,-1),0>8:this.X};l.sk=function(){return this.G};l.tk=function(){return this.I};l.vk=function(){return this.C};l.uk=function(){return this.B};l.Ak=function(){return this.ia}; +l.Ul=function(a,b){if(this.I&128)this.R=this.R&-256|b;else{this.ka=b;this.B&=-97;var c;if(this.D){if(13==b)this.L=0;else if(8==b)this.D.value=this.D.value.slice(0,-1),0b&&-2!=b&&this.controller.Ca("Unable to restore disk '"+this.B+": "+c);return b}; l.toJSON=function(){var a;a=0;for(var b;b=im(this,a++);)pm(b);a=JSON.stringify(this.A,function(a,b){return"file"==a?void 0:b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; function pm(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}function qm(a){Ia.call(this,"FDC",a,qm);this.dmaRead=this.pj;this.dmaWrite=this.qj;this.dmaFormat=this.Cj;this.K=a.autoMount||null;this.C=[];this.X=!ya("Mobi")&&window&&"FileReader"in window}Qa(qm);aa={}; -var rm={3:{jd:3,xd:0,name:aa.Em},4:{jd:2,xd:1,name:aa.Cm},5:{jd:9,xd:7,name:aa.Mm},6:{jd:9,xd:7,name:aa.xm},7:{jd:2,xd:0,name:aa.zm},8:{jd:1,xd:2,name:aa.Dm},10:{jd:2,xd:7,name:aa.ym},13:{jd:6,xd:7,name:aa.jm},15:{jd:3,xd:0,name:aa.Bm}};l=qm.prototype; +var rm={3:{jd:3,xd:0,name:aa.Fm},4:{jd:2,xd:1,name:aa.Dm},5:{jd:9,xd:7,name:aa.Nm},6:{jd:9,xd:7,name:aa.ym},7:{jd:2,xd:0,name:aa.Am},8:{jd:1,xd:2,name:aa.Em},10:{jd:2,xd:7,name:aa.zm},13:{jd:6,xd:7,name:aa.km},15:{jd:3,xd:0,name:aa.Cm}};l=qm.prototype; l.zb=function(a,b,c){var d=this;switch(b){case "listDisks":return this.la[b]=c,c.onchange=function(){var a=d.la.descDisk,b=c.options[c.selectedIndex];if(a&&b){var g={};if(b=b.getAttribute("data-value"))try{g=eval("("+b+")")}catch(h){n("FDC option error: "+h.message)}b=g.desc;void 0===b&&(b="");g=g.href;void 0!==g&&(b=''+b+"");a.innerHTML=b}},!0;case "descDisk":case "listDrives":return this.la[b]=c,c.onchange=function(){var a=ca(c.value,10);null!=a&&sm(d,a)},!0; case "loadDrive":return this.la[b]=c,c.onclick=function(){var a=d.la.listDisks;a&&tm(d,a.options[a.selectedIndex].text,a.value)},!0;case "saveDrive":if(!this.X){c.parentNode.removeChild(c);break}this.la[b]=c;c.onclick=function(){var a=d.la.listDrives;if(a&&a.options&&d.B)if(a=ca(a.value,10),a=d.B[a])if(a.ta){for(var b=a.ta,c="",h=0,k;k=im(b,h++);)for(var m=0,p=k.length;ma.ib||f[1]>a.jb)&&(this.Ca('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Qa)),b=null);b?(a.ta=b,a.hj=c,a.Vd=d,Cm(this,c,d,b),f=b.info(),this.L|=128,this.Ca('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Qa),a.Nd||e),a.Hf=f[0],a.Ue=f[1],a.Ve=f[2],this.aa&&uc(this.aa)):a.me=!1;a.Nd&&(a.Nd=!1,--this.R||ab(this));sm(this,a.Qa)}; function xm(a,b,c){if((a=a.la.listDisks)&&a.options){for(var d=0;d=this.D&&(this.Z&=-81,this.G=this.D=0);return a}; -l.yl=function(a,b){this.D=rm[c].jd){var d=!1;this.G=0;var c=Dm(this),e,f,g,h,k,m=c&31;switch(m){case 3:Dm(this);Dm(this);Em(this);break;case 4:f=Dm(this);this.Qa=f&3;e=this.B[this.Qa];Em(this);Fm(this,(e.kb&-16777216)>>>24);break;case 5:case 6:f=Dm(this);d=f>>2&1;this.Qa=f&3;e=this.B[this.Qa];e.Ya=d;f=e.xb=Dm(this);g=Dm(this);h=e.mb=Dm(this);k=Dm(this);e.wb=128<=this.D&&(this.Z&=-81,this.G=this.D=0);return a}; +l.zl=function(a,b){this.D=rm[c].jd){var d=!1;this.G=0;var c=Dm(this),e,f,g,h,k,m=c&31;switch(m){case 3:Dm(this);Dm(this);Em(this);break;case 4:f=Dm(this);this.Qa=f&3;e=this.B[this.Qa];Em(this);Fm(this,(e.kb&-16777216)>>>24);break;case 5:case 6:f=Dm(this);d=f>>2&1;this.Qa=f&3;e=this.B[this.Qa];e.Ya=d;f=e.xb=Dm(this);g=Dm(this);h=e.mb=Dm(this);k=Dm(this);e.wb=128<>2&1;this.Qa=f&3;e=this.B[this.Qa];f=e.xb;g=e.Ya=d;h= e.mb=1;k=0;e.kb=0;e.ta&&(e.Wa=e.ta.seek(e.xb,e.Ya,e.mb))?k=e.Wa.length>>8:e.kb=72;Gm(this,e,c,d,f,g,h,k);d=!0;break;case 13:f=Dm(this);d=f>>2&1;this.Qa=f&3;e=this.B[this.Qa];f=e.xb;g=e.Ya=d;h=1;k=Dm(this);e.wb=128<>2&1,f=Dm(this),e.xb+= -f-e.vd,0>e.xb&&(e.xb=0),e.xb>=e.ib&&(e.xb=e.ib-1),e.vd=f,e.kb=32,e.xb||(e.kb|=268435456),Em(this),d=!0}0>>8);Fm(a,(b.kb&16711680)>>>16);var k=0;if(e!=b.xb||f!=b.Ya)k=g=1;c&128&&(f^=k,d||(k=0));Fm(a,e+k);Fm(a,f);Fm(a,g);Fm(a,h)} +f-e.vd,0>e.xb&&(e.xb=0),e.xb>=e.ib&&(e.xb=e.ib-1),e.vd=f,e.kb=32,e.xb||(e.kb|=268435456),Em(this),d=!0}0>>8);Fm(a,(b.kb&16711680)>>>16);var k=0;if(e!=b.xb||f!=b.Ya)k=g=1;c&128&&(f^=k,d||(k=0));Fm(a,e+k);Fm(a,f);Fm(a,g);Fm(a,h)} function Dm(a){var b=a.I[a.G];a.G++;return b}function Em(a){a.G=a.D=0}function Fm(a,b){a.I[a.D++]=b}l.pj=function(a,b,c){if(void 0===b||0>b){b=-1;var d=null,e=0;if(!a.kb&&a.ta){do{if(a.Wa&&(e=a.Ua,0<=(b=a.ta.read(a.Wa,a.Ua++)))){d=a.Wa;break}a.Wa=a.ta.seek(a.xb,a.Ya,a.mb);if(!a.Wa){a.kb=1088;break}a.Ua=0;Hm(a)}while(1)}c(b,!1,d,e)}else c(-1,!1)};l.qj=function(a,b){return void 0!==b&&0<=b?Im(a,b):-1}; l.Cj=function(a,b){var c;if(void 0!==b&&0<=b)a:if(c=b,a.kb)c=-1;else{a.Pc[a.ie++]=c;if(a.ie==a.Pc.length){a.xb=a.Pc[0];a.Ya=a.Pc[1];a.mb=a.Pc[2];a.wb=128<Im(a,a.Eh)){c=-1;break a}a.vf++}a.vf>=a.wd&&(c=-1)}else c=-1;return c};function Im(a,b){if(a.kb||!a.ta)return-1;do{if(a.Wa&&a.ta.write(a.Wa,a.Ua++,b))break;a.Wa=a.ta.seek(a.xb,a.Ya,a.mb);if(!a.Wa){a.kb=8256;b=-1;break}a.Ua=0;Hm(a)}while(1);return b} -function Hm(a){a.mb++;a.mb>=a.Ve+1&&(a.mb=1,a.Ya++,a.Ya>=a.Ue&&(a.Ya=0,a.xb++))}var vm={1012:qm.prototype.mk,1013:qm.prototype.kk,1015:qm.prototype.lk},wm={1010:qm.prototype.zl,1013:qm.prototype.yl,1015:qm.prototype.xl};Ea(function(){for(var a=Za(document,"pcjs","fdc"),b=0;b=a.Ve+1&&(a.mb=1,a.Ya++,a.Ya>=a.Ue&&(a.Ya=0,a.xb++))}var vm={1009:qm.prototype.lk,1012:qm.prototype.nk,1013:qm.prototype.kk,1015:qm.prototype.mk},wm={1010:qm.prototype.Al,1013:qm.prototype.zl,1015:qm.prototype.yl};Ea(function(){for(var a=Za(document,"pcjs","fdc"),b=0;bk.ta.restore(g)&&(z=!1),z&&void 0!==k.Ua&&(k.Wa=k.ta.seek(k.Jd,k.Ya,k.mb+k.uf)));z||(e= !1);null!=a.da&&1>=d&&(a.da|=(f.type&3)<<(1-d<<1))}0<=a.Qa&&(a.C=a.B[a.Qa]);return e}function Rm(a,b,c){if(b){var d=0,e=0;null==c&&((d=b.de[2])?e=b.de[0]<<8|b.de[1]:c=b.type);null==c||d||(d=Km[a.H][c][1],e=Km[a.H][c][0]);d&&((c=Km[a.H][b.type])&&e!=c[0]&&d!=c[1]&&a.Ca("Warning: drive parameters ("+e+","+d+") do not match drive type "+b.type+" ("+c[0]+","+c[1]+")"),b.ib=e,b.jb=d,null==b.ta&&(b.ta=new am(a,b,b.mode)))}} function Pm(a,b){b||(a.R=0);for(var c=0;c=this.D&&(this.G=this.D=0,this.Z&=-15);return a}; -l.Vl=function(a,b){this.D=c&&(this.Z|=2,this.Z&=-2,Sm(this))};l.Ok=function(){var a=this.Z;this.G=this.D&&(this.G=this.D=0,this.Z&=-15);return a}; +l.Wl=function(a,b){this.D=c&&(this.Z|=2,this.Z&=-2,Sm(this))};l.Pk=function(){var a=this.Z;this.G=a.C.nb?(a.Z=128,Um(a.C,function(b){0<=b?(Vm(a),a.P&&5180==a.P.ca&&(a.Z=0),a.Z|=88):(a.Z=1,a.K=16)},!1)):a.Z=80));return b}l.tj=function(){return Tm(this)|Tm(this)<<8};function Wm(a,b){a.C&&a.C.wb>=a.C.nb&&(0>Xm(a.C,b)?(a.Z=1,a.K=16):(1==a.C.Ua||a.C.Ua==a.C.nb)&&1=a.C.nb&&(a.Z|=8)))} -l.fl=function(a,b){Wm(this,b&255);Wm(this,b>>8&255)};l.Uj=function(){return this.K};l.kl=function(a,b){this.za=b};l.Wj=function(){return this.L};l.il=function(a,b){this.L=b};l.Xj=function(){return this.oa};l.jl=function(a,b){this.oa=b};l.Sj=function(){return this.ma};l.el=function(a,b){this.ma=b};l.Rj=function(){return this.ka};l.dl=function(a,b){this.ka=b};l.Tj=function(){return this.ba};l.gl=function(a,b){this.ba=b;this.Z=this.B[this.ba&16?1:0]?this.Z|80:this.Z&-65}; -l.Yj=function(){var a=this.Z;this.Z&64&&(this.Z&=-129);return a};l.cl=function(a,b){this.pa=b;this.P&&Se(this.P,14);Ym(this)};l.hl=function(a,b){this.S&4&&!(b&4)&&(this.K=1);this.S=b}; +l.gl=function(a,b){Wm(this,b&255);Wm(this,b>>8&255)};l.Uj=function(){return this.K};l.ll=function(a,b){this.za=b};l.Wj=function(){return this.L};l.jl=function(a,b){this.L=b};l.Xj=function(){return this.oa};l.kl=function(a,b){this.oa=b};l.Sj=function(){return this.ma};l.fl=function(a,b){this.ma=b};l.Rj=function(){return this.ka};l.el=function(a,b){this.ka=b};l.Tj=function(){return this.ba};l.hl=function(a,b){this.ba=b;this.Z=this.B[this.ba&16?1:0]?this.Z|80:this.Z&-65}; +l.Yj=function(){var a=this.Z;this.Z&64&&(this.Z&=-129);return a};l.dl=function(a,b){this.pa=b;this.P&&Se(this.P,14);Ym(this)};l.il=function(a,b){this.S&4&&!(b&4)&&(this.K=1);this.S=b}; function Ym(a){var b=!1,c=a.pa,d=a.ba&16?1:0,e=a.ba&15,f=a.ma|(a.ka&3)<<8,g=a.oa,h=a.L||256;a.Qa=-1;a.C=null;a.K=0;a.Z=80;var k=a.B[d];k?(k.Jd=f,k.Ya=e,k.mb=g,k.wb=h*k.nb,c=144<=c?c:c&240,k.Wa=null,k.Ua=0,k.errorCode=0,a.Qa=d,a.C=k):c=-1;switch(c&240){case 16:b=!0;break;case 32:a.Z=128;Um(k,function(b){0<=b&&a.P?(Vm(a),a.Z=88):(a.Z=1,a.K=16)},!1);break;case 48:a.Z=8;break;case 64:b=!0;break;case 112:b=!0;break;case 144:a.K=1;b=!0;break;case 145:k.jb=e+1,k.eb=h,b=!0}b&&Vm(a)} function Vm(a){!a.P||a.S&2||Te(a.P,14,120)} function Sm(a){a.G=0;var b=Zm(a),c=Zm(a),d=c&32,e=d>>5,f=c&31,g=Zm(a),h=Zm(a),k=g<<2&768|h,m=g&63,p=Zm(a),x=Zm(a),r=a.B[e];r&&(r.Jd=k,r.Ya=f,r.mb=m,r.wb=p*r.nb);switch(b){case 3:$m(a,r?r.errorCode:4);dn(a,c);dn(a,g);dn(a,h);dn(a,0|d);b=-1;break;case 12:for(c=0;0<=(b=Zm(a));)r&&c=a.eb+b&&(a.mb=b,a.Ya++,a.Ya>=a.jb&&(a.Ya=0,a.Jd++))}l.Qk=function(){var a=this.A.M&255;!(this.A.J>>8)&&128>8||!this.P)||(a=!(this.P.gc[0].Vc&64));return a?!0:!1}; -var Mm={800:Z.prototype.Nk,801:Z.prototype.Ok,802:Z.prototype.Mk},Lm={496:Z.prototype.tj,497:Z.prototype.Uj,498:Z.prototype.Wj,499:Z.prototype.Xj,500:Z.prototype.Sj,501:Z.prototype.Rj,502:Z.prototype.Tj,503:Z.prototype.Yj},Om={800:Z.prototype.Vl,801:Z.prototype.Yl,802:Z.prototype.Xl,803:Z.prototype.Wl,807:Z.prototype.hh,811:Z.prototype.hh,815:Z.prototype.hh},Nm={496:Z.prototype.fl,497:Z.prototype.kl,498:Z.prototype.il,499:Z.prototype.jl,500:Z.prototype.el,501:Z.prototype.dl,502:Z.prototype.gl,503:Z.prototype.cl, -1014:Z.prototype.hl};Ea(function(){for(var a=Za(document,"pcjs","hdc"),b=0;b=a.eb+b&&(a.mb=b,a.Ya++,a.Ya>=a.jb&&(a.Ya=0,a.Jd++))}l.Rk=function(){var a=this.A.M&255;!(this.A.J>>8)&&128>8||!this.P)||(a=!(this.P.gc[0].Vc&64));return a?!0:!1}; +var Mm={800:Z.prototype.Ok,801:Z.prototype.Pk,802:Z.prototype.Nk},Lm={496:Z.prototype.tj,497:Z.prototype.Uj,498:Z.prototype.Wj,499:Z.prototype.Xj,500:Z.prototype.Sj,501:Z.prototype.Rj,502:Z.prototype.Tj,503:Z.prototype.Yj},Om={800:Z.prototype.Wl,801:Z.prototype.Zl,802:Z.prototype.Yl,803:Z.prototype.Xl,807:Z.prototype.hh,811:Z.prototype.hh,815:Z.prototype.hh},Nm={496:Z.prototype.gl,497:Z.prototype.ll,498:Z.prototype.jl,499:Z.prototype.kl,500:Z.prototype.fl,501:Z.prototype.el,502:Z.prototype.hl,503:Z.prototype.dl, +1014:Z.prototype.il};Ea(function(){for(var a=Za(document,"pcjs","hdc"),b=0;b