summaryrefslogtreecommitdiff
path: root/js/Linear/PID.js
diff options
context:
space:
mode:
authorSunil Shetye2018-07-13 15:37:42 +0530
committerSunil Shetye2018-07-15 07:11:58 +0530
commit6ee02952c836bb31e9b51783e6a16724fba64637 (patch)
treebde996b5477f57f4faca4ba3a173bed2fdf0c359 /js/Linear/PID.js
parent214ade87a6cef2bf55f9b9f2848ffafc02f37f18 (diff)
downloadsci2js-6ee02952c836bb31e9b51783e6a16724fba64637.tar.gz
sci2js-6ee02952c836bb31e9b51783e6a16724fba64637.tar.bz2
sci2js-6ee02952c836bb31e9b51783e6a16724fba64637.zip
change in1 to in
Diffstat (limited to 'js/Linear/PID.js')
-rw-r--r--js/Linear/PID.js13
1 files changed, 1 insertions, 12 deletions
diff --git a/js/Linear/PID.js b/js/Linear/PID.js
index 439f4907..bca0affb 100644
--- a/js/Linear/PID.js
+++ b/js/Linear/PID.js
@@ -25,7 +25,7 @@ function PID() {
scs_m.objs[21-1] = scicos_link(xx=[[213.97067],[233.97067]],yy=[[203.11733],[203.11733]],id="drawlink",thick=[0,0],ct=[1,1],from=[20,1,0],to=[15,1,1]);
this.model = scicos_model();
this.model.sim = new ScilabString(["csuper"]);
- this.model.in1 = new ScilabDouble([-1]);
+ this.model.in = new ScilabDouble([-1]);
this.model.in2 = new ScilabDouble([-2]);
this.model.out = new ScilabDouble([-1]);
this.model.out2 = new ScilabDouble([-2]);
@@ -56,11 +56,7 @@ function PID() {
this.d = arguments[0]["d"]
this.exprs0 = arguments[0]["exprs0"]
var ppath = list(0,0,0);
- for (i=1;i<=length(arg1.model.rpar.objs);i+=1) {
- var o = arg1.model.rpar.objs[this.i-1];
if (typeof(o)=="Link") {
- var from = arg1.model.rpar.objs[o.from[1-1]-1];
- var to = arg1.model.rpar.objs[o.to[1-1]-1];
if (from.gui=="GAINBLK") {
switch (to.gui) {
case "SUMMATION":
@@ -86,13 +82,10 @@ function PID() {
}
}
var newpar = list();
- var xx1 = arg1.model.rpar.objs[ppath[1-1]-1];
this.exprs[1-1] = xx1.graphics.exprs[1-1];
var p_old = xx1.model.rpar;
- var xx2 = arg1.model.rpar.objs[ppath[2-1]-1];
this.exprs[2-1] = xx2.graphics.exprs[1-1];
var i_old = xx2.model.rpar;
- var xx3 = arg1.model.rpar.objs[ppath[3-1]-1];
this.exprs[3-1] = xx3.graphics.exprs[1-1];
var d_old = xx3.model.rpar;
var y = 0;
@@ -108,9 +101,6 @@ function PID() {
xx2.model.rpar = this.i;
xx3.graphics.exprs = this.exprs0[3-1];
xx3.model.rpar = this.d;
- arg1.model.rpar.objs[ppath[1-1]-1] = xx1;
- arg1.model.rpar.objs[ppath[2-1]-1] = xx2;
- arg1.model.rpar.objs[ppath[3-1]-1] = xx3;
break;
}
}
@@ -121,7 +111,6 @@ function PID() {
newpar[size(newpar)+1-1] = ppath[3-1];
var needcompile = 2;
}
- this.x = arg1;
var y = max(y,needcompile);
var typ = newpar;
return new BasicBlock(this.x);