diff options
Diffstat (limited to 'js/Electrical/CCS.js')
-rw-r--r-- | js/Electrical/CCS.js | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/js/Electrical/CCS.js b/js/Electrical/CCS.js index 6754b973..2278d75e 100644 --- a/js/Electrical/CCS.js +++ b/js/Electrical/CCS.js @@ -4,7 +4,7 @@ function CCS() { ModelName = "CCS"; PrametersValue = []; ParametersName = []; - model = scicos_model(); + this.model = scicos_model(); Typein = []; Typeout = []; MI = []; @@ -29,22 +29,22 @@ function CCS() { MO = [[MO],[PortName[i-1]]]; } } - model = scicos_model(); + this.model = scicos_model(); mo = modelica(); - model.sim = ModelName; + this.model.sim = new ScilabString(ModelName); mo.inputs = MI; mo.outputs = MO; - model.rpar = PrametersValue; + this.model.rpar = PrametersValue; mo.parameters = list(ParametersName,PrametersValue,zeros(ParametersName)); exprs = []; gr_i = []; - model.blocktype = "c"; - model.dep_ut = [false,true]; + this.model.blocktype = new ScilabString("c"); + this.model.dep_ut = [false,true]; mo.model = ModelName; - model.equations = mo; - model.in1 = ones(size(MI,"*"),1); - model.out = ones(size(MO,"*"),1); - this.x = standard_define([2.1,3],model,exprs,list(gr_i,0)); + this.model.equations = new ScilabDouble(mo); + this.model.in1 = new ScilabDouble(ones(size(MI,"*"),1)); + this.model.out = new ScilabDouble(ones(size(MO,"*"),1)); + this.x = standard_define([2.1,3],this.model,exprs,list(gr_i,0)); this.x.graphics.in_implicit = Typein; this.x.graphics.out_implicit = Typeout; return new BasicBlock(this.x); @@ -61,7 +61,7 @@ function CCS() { this.x = arg1; graphics = arg1.graphics; exprs = graphics.exprs; - model = arg1.model; + this.model = arg1.model; this.x = arg1; return new BasicBlock(this.x); } |