PDP-11 command-line (Node-based) operation is finally working

This commit is contained in:
Jeff Parsons 2016-12-30 14:51:32 -08:00 committed by Jeff Parsons
commit 4b345bb3d2
19 changed files with 552 additions and 438 deletions

View file

@ -184,7 +184,7 @@ k.Kb=function(a){null!=a&&(this.A="number"!=typeof a?a:this.A+String.fromCharCod
k.Jd=function(a,b,c){y(this,a,b,c,"DATA");this.O=b;this.ia&=~(Qd|Hf);pb(this,"transmitByte("+ea(b)+")");if(19==b)this.N=!0;else if(17==b)this.N=!1;else if(this.Ra&&this.Ra.call(this.b,b),this.g)if(8==b)this.g.value=this.g.value.slice(0,-1),0<this.w&&this.w--;else{var d;13!=b&&10!=b&&(d=pa[b]);a=d=d?"<"+d+">":String.fromCharCode(b);c=a.length;9==b?(b=this.V||8,c=b-this.w%b,this.V&&(a=na("",c))):13==b&&(this.w=c=0,a="\n");this.R&&!this.w&&c&&(a=String.fromCharCode(this.R)+a);this.g.value+=a;this.g.scrollTop=
this.g.scrollHeight;this.w+=c}else if(null!=this.j){if(10==b||1024<=this.j.length)this.i(this.j),this.j="";10!=b&&(this.j+=String.fromCharCode(b))}this.u&&Kc(this.u,this.Z,zf(this,If))};k.Id=function(a,b,c){y(this,a,b,c,"CONTROL");this.F?(this.I&&(b^this.C)&(Jf|Kf)&&(a=0,this.D?(a|=b&Jf?32:0,a|=b&Kf?320:0):(a|=b&Jf?16:0,a|=b&Kf?1048576:0),this.I.call(this.b,a)),this.C=b,this.C&Lf&&(this.F=!1)):(this.B=b,this.F=!0)};k.Hd=function(a,b,c){y(this,a,b,c,"BAUDRATES");this.L=b};
var Bf=12,Cf=16,Df=192,Kf=2,Jf=32,Lf=64,Qd=1,Ef=2,Hf=4,Gf=128,Ff=15,If=240,Af=[50,75,110,134.5,150,200,300,600,1200,1800,2E3,2400,3600,4800,9600,19200],yf=[!1,0,0,133,142,39,238],tf="buffer",vf={0:sf.prototype.zd,1:sf.prototype.yd},wf={0:sf.prototype.Jd,1:sf.prototype.Id,2:sf.prototype.Hd};Oa(function(){for(var a=hb(document,"pc8080","serial"),b=0;b<a.length;b++){var c=a[b],d=fb(c),d=new sf(d);gb(d,c)}});
function Mf(a){x.call(this,"Debugger",a);this.na=a.base||16;this.N=this.Y=this.C=0;this.L=!1;this.b=-1;this.g=[];this.R={}}ba(Mf,x);Mf.prototype.Gb=function(){return-1};Mf.prototype.Hb=function(){};
function Mf(a){x.call(this,"Debugger",a);this.na=+a.base||16;this.N=this.Y=this.C=0;this.L=!1;this.b=-1;this.g=[];this.R={}}ba(Mf,x);Mf.prototype.Gb=function(){return-1};Mf.prototype.Hb=function(){};
Mf.prototype.wb=function(a,b,c){if(b)if(a){0>this.b&&this.g.length&&(this.b=0);if(0>this.b||a!=this.g[this.b])this.g.splice(0,0,a),this.b=0;this.b--}else this.L?a="end":a=this.g[this.b+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(oa(a.substring(d,f))),d=f+1}}return b};
function Nf(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<<e;break;case ">>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f<e?1:0;break;case "<=":d=f<=e?1:0;break;case ">":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break;
case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0}