Differences From Artifact [557276af06]:

To Artifact [1a54bd1685]:


1

2
3
4
5
6
7
8
function [eqn,insigs,innames] = SS_seqn (Name, name, cr, arg, outsig, insigs,innames)


  ## usage:  [eqn,inbonds] = SS_seqn (Name, cr, arg, outbond, inbonds)
  ##
  ## 
  ## Multi port SS's ??

  delim = "__";
|
>







1
2
3
4
5
6
7
8
9
function [eqn,insigs,innames] = SS_seqn (Name, name, cr, arg, outsig, \
					 insigs,innames,is_port)

  ## usage:  [eqn,inbonds] = SS_seqn (Name, cr, arg, outbond, inbonds)
  ##
  ## 
  ## Multi port SS's ??

  delim = "__";
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
    mtt_error(sprintf("SS should have 2 args not %i", N_a));
  end;

  effort_attribute = deblank(attrib_name(1,:));
  flow_attribute   = deblank(attrib_name(2,:));

  ## Default attributes
  if strcmp(effort_attribute,"")
    effort_attribute = "external";
  end;
  
  if strcmp(flow_attribute,"")
    flow_attribute = "external";
  end;


  if mtt_is_external("SS",outsig,insigs) # Source
    if outsig(2)==1		# effort output.
      attribute = effort_attribute;







|



|







18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
    mtt_error(sprintf("SS should have 2 args not %i", N_a));
  end;

  effort_attribute = deblank(attrib_name(1,:));
  flow_attribute   = deblank(attrib_name(2,:));

  ## Default attributes
  if strcmp(effort_attribute,"")||is_port
    effort_attribute = "external";
  end;
  
  if strcmp(flow_attribute,"")||is_port
    flow_attribute = "external";
  end;


  if mtt_is_external("SS",outsig,insigs) # Source
    if outsig(2)==1		# effort output.
      attribute = effort_attribute;
50
51
52
53
54
55
56
57
58

   ## Create the equation
   LHS = Sensor_seqn (attribute,full_name);
   RHS = varname(Name, insigs(1,1), insigs(1,2));
   eqn = sprintf("%s := %s;", LHS, RHS);
 endif
 

endfunction







<

51
52
53
54
55
56
57

58

   ## Create the equation
   LHS = Sensor_seqn (attribute,full_name);
   RHS = varname(Name, insigs(1,1), insigs(1,2));
   eqn = sprintf("%s := %s;", LHS, RHS);
 endif
 

endfunction

MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]