︙ | | | ︙ | |
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
# Copyright (c) P.J.Gawthrop, 1996.
###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.30 1998/04/12 15:01:17 peterg
## Converted to uniform port notation - always use []
##
## Revision 1.29 1998/04/12 12:35:32 peterg
## Named and unnamed SS handled in a uniform manner - in particular, the
## attributes are passed through
## wrote_component function used.
|
>
>
>
>
|
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
# Copyright (c) P.J.Gawthrop, 1996.
###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.31 1998/04/16 13:18:13 peterg
## Now ignores spurious ports (in lbl but not Figure \ref{) but gives
## warning
##
## Revision 1.30 1998/04/12 15:01:17 peterg
## Converted to uniform port notation - always use []
##
## Revision 1.29 1998/04/12 12:35:32 peterg
## Named and unnamed SS handled in a uniform manner - in particular, the
## attributes are passed through
## wrote_component function used.
|
︙ | | | ︙ | |
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
|
return ((match(name1,name2)>0)&&(length(name1)==length(name2)))
}
function write_component(i) {
name = label[i,1];
cr = label[i,2];
arg = label[i,3];
if (length(x[name])==0) {
# print error - its in lbl but not fig file
printf(warning_l, name);
}
else {
component_index++;
print x[name], y[name], info[name] >> b_file;
|
<
|
181
182
183
184
185
186
187
188
189
190
191
192
193
194
|
return ((match(name1,name2)>0)&&(length(name1)==length(name2)))
}
function write_component(i) {
name = label[i,1];
cr = label[i,2];
arg = label[i,3];
if (length(x[name])==0) {
# print error - its in lbl but not fig file
printf(warning_l, name);
}
else {
component_index++;
print x[name], y[name], info[name] >> b_file;
|
︙ | | | ︙ | |
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
|
sys_name = ARGV[1];
delete ARGV[1];
b_file = sprintf("%s_rbg.m", sys_name);
c_file = sprintf("%s_cmp.m", sys_name);
fig_file = sprintf("%s_fig.fig", sys_name);
cmp_file = sprintf("%s_cmp.fig", sys_name);
bnd_file = sprintf("%s_bnd.fig", sys_name);
head_file = sprintf("%s_head.fig", sys_name);
warning_f = "WARNING %s \t in fig file but not lbl file - using\n";
warning_l = "WARNING %s \t in lbl file but not fig file - ignoring\n";
warning_p = "ERROR system ports are not consecutively numbered\n";
warning_u = "ERROR %s has already appeared in the fig file\n";
|
|
|
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
|
sys_name = ARGV[1];
delete ARGV[1];
b_file = sprintf("%s_rbg.m", sys_name);
c_file = sprintf("%s_cmp.m", sys_name);
fig_file = sprintf("%s_fig.fig", sys_name);
cmp_file = sprintf("%s_cmp.fig", sys_name);
bnd_file = sprintf("%s_bnd.fig", sys_name);
head_file = sprintf("%s_head.fig", sys_name);
warning_f = "WARNING %s \t in fig file but not lbl file - using\n";
warning_l = "WARNING %s \t in lbl file but not fig file - ignoring\n";
warning_p = "ERROR system ports are not consecutively numbered\n";
warning_u = "ERROR %s has already appeared in the fig file\n";
|
︙ | | | ︙ | |
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
|
i_name = 0;
i_port_component = 0;
component_index = 0;
}
{
# Start of .fig file?
if ( (NF>0) && (match("#FIG", $1) > 0) ) {
isa_fig_file=1;
}
if (isa_fig_file==0) {
process_lbl()
}
else {
process_fig()
}
}
|
|
<
|
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
|
i_name = 0;
i_port_component = 0;
component_index = 0;
}
{
# Start of .fig file?
if ($1=="#FIG") {
isa_fig_file=1;
}
if (isa_fig_file==0) {
process_lbl()
}
else {
process_fig()
}
}
|
︙ | | | ︙ | |