Overview
| Comment: | Implemented vector SS ports. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | origin/master | trunk |
| Files: | files | file ages | folders |
| SHA3-256: |
58cc84280f3236ff42bdf05b2ffd32b4 |
| User & Date: | gawthrop@users.sourceforge.net on 1998-07-28 10:30:50.000 |
| Other Links: | branch diff | manifest | tags |
Context
|
1998-07-28
| ||
| 11:23:31 | Put / explicitly in awk. check-in: 480592a58b user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
| 10:30:50 | Implemented vector SS ports. check-in: 58cc84280f user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
|
1998-07-27
| ||
| 20:33:17 | Aliases check-in: a983f793cd user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
Changes
Modified mttroot/mtt/bin/trans/m/rbg2abg.m
from [8516bd9170]
to [70a07044a9].
|
| | > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | function [bonds,components] = rbg2abg(name,rbonds,rstrokes,rcomponents,\ port_coord,port_name,\ infofile,errorfile) % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %% Version control history % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %% $Id$ % %% $Log$ % %% Revision 1.35 1998/07/08 15:35:15 peterg % %% Added errorfile argument % %% % %% Revision 1.34 1998/07/02 19:41:29 peterg % %% Fixed empty port string bug - set to null string. % %% % %% Revision 1.33 1998/07/02 17:16:06 peterg % %% Commented out redundent code -- obsolete due to new default mechanism % %% % %% Revision 1.32 1998/07/02 15:12:05 peterg |
| ︙ | ︙ | |||
290 291 292 293 294 295 296 |
end;
% Replace by alias -- if any
eval( ["alias = ", comp_type, '_alias';]); # Get aliases
if is_struct(alias) # are there any aliases
if struct_contains(alias,port_name_i) # Is this an alias?
eval(["new_port_name_i = alias.",port_name_i]);
| | | 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 |
end;
% Replace by alias -- if any
eval( ["alias = ", comp_type, '_alias';]); # Get aliases
if is_struct(alias) # are there any aliases
if struct_contains(alias,port_name_i) # Is this an alias?
eval(["new_port_name_i = alias.",port_name_i]);
mtt_info(["Aliasing name [" port_name_i "]\t on component " \
comp_name " (" comp_type ")\t to [" new_port_name_i "]"],infofile);
port_name = replace_name(port_name, \
["[",new_port_name_i,"]"], \
port_name_index);
end
end
end
|
| ︙ | ︙ | |||
458 459 460 461 462 463 464 465 466 467 468 469 470 471 |
%Find the port list for this component
if exist([comp_type, '_cause'])==0
eval(['[junk1,junk2,junk3,junk4,junk5,port_list]=', comp_type, '_rbg;']);
else
port_list=comp_ports(comp_type,n_comp_bonds);
end;
% Check that number of bonds on the component is the same as the number of
% ports
[n_comp_ports,m_comp_ports] = size(port_list);
if (n_comp_ports~=n_comp_bonds) & ...
~(strcmp(comp_type,'zero')|strcmp(comp_type,'one'))
| > > > > > > > > > > > > > | 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 |
%Find the port list for this component
if exist([comp_type, '_cause'])==0
eval(['[junk1,junk2,junk3,junk4,junk5,port_list]=', comp_type, '_rbg;']);
else
port_list=comp_ports(comp_type,n_comp_bonds);
end;
[n_comp_ports,m_comp_ports] = size(port_list);
subport_list="";
for p=1:n_comp_ports # Expand any vector ports
[subport,n_sub] = split_port(port_list(p,:), ','); # Find the components
# of the vector port
if n_sub>1
mtt_info(sprintf("Expanding vector port %s of component type %s",\
port_list(p,:), comp_type, infofile));
end;
subport_list = [subport_list; subport];
end;
port_list = subport_list; # Set the expanded port list.
% Check that number of bonds on the component is the same as the number of
% ports
[n_comp_ports,m_comp_ports] = size(port_list);
if (n_comp_ports~=n_comp_bonds) & ...
~(strcmp(comp_type,'zero')|strcmp(comp_type,'one'))
|
| ︙ | ︙ | |||
569 570 571 572 573 574 575 576 577 578 579 580 |
mtt_error(['Component ', comp_name, ' (', comp_type, ') has an unrecognised port: ', name_k], errorfile);
else
components(i,k) = signed_bond_list(j);
end;
end;
end;
end;
| > > | 586 587 588 589 590 591 592 593 594 595 596 597 598 599 |
mtt_error(['Component ', comp_name, ' (', comp_type, ') has an unrecognised port: ', name_k], errorfile);
else
components(i,k) = signed_bond_list(j);
end;
end;
end;
end;
|