Overview
Comment:Now handles [1:N] style port labels
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: 343c9497592d60156efd91a3908cb12342d4e4afee7e283e924de639e0ab1323
User & Date: gawthrop@users.sourceforge.net on 2001-10-15 14:27:34
Other Links: branch diff | manifest | tags
Context
2001-10-15
14:28:35
Now has . at start of components library path $MTT_COMPONENTS check-in: ebe667eb0a user: gawthrop@users.sourceforge.net tags: origin/master, trunk
14:27:34
Now handles [1:N] style port labels check-in: 343c949759 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
14:25:44
Now handles white space at the end of component names
Converts ports lables [1:5] into [1,2,3,4,5]
check-in: d23e8145fd user: gawthrop@users.sourceforge.net tags: origin/master, trunk
Changes

Modified mttroot/mtt/bin/trans/abg2lbl_fig2txt from [202d6a713d] to [3e21c7fb36].

9
10
11
12
13
14
15



16
17
18
19
20
21
22
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25







+
+
+







# Acausal bond graph to causal bond graph: mfile format

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.24  2001/08/02 03:24:48  geraint
## Replaced mtt_version.sh with mtt_banner.sh - I think this was the intent.
##
## Revision 1.23  2001/07/26 04:08:35  gawthrop
## Removed lines deleting _type.sh and cbg.m
##  -- how did they get there ??
##
## Revision 1.22  2001/07/08 03:28:11  gawthrop
## Fixed a bug: abg2sympar_m2txt neads a _lbl.txt file when using
## "usinglabel" option
165
166
167
168
169
170
171
172
173



174
175
176
177
178
179
180
168
169
170
171
172
173
174


175
176
177
178
179
180
181
182
183
184







-
-
+
+
+







## ---- Component labels ----
EOF
}

create_lbl_body()
{

## Find names aof all components
awk '/:/ {print $NF}' $1_abg.fig | \
## Find names of all components
grep -v '\[[0-9]*:[0-9]*\]' $1_abg.fig  |\
awk '/:/ {print $NF}'  | \
sed 's/\\001//' | \
sort | \
tee $1_raw_list | \
sort -u> $1_unique_raw_list


#Write out non-unique names

Modified mttroot/mtt/bin/trans/abg2sub_fig2sh from [89a28ef619] to [9598bba015].

10
11
12
13
14
15
16



17
18
19
20
21
22
23
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26







+
+
+







  ######################################
  
  ###############################################################
  ## Version control history
  ###############################################################
  ## $Id$
  ## $Log$
  ## Revision 1.2  2001/07/23 23:26:23  gawthrop
  ## Removed some boring user feedback
  ##
  ## Revision 1.1  2001/06/11 19:47:49  gawthrop
  ## Makes the sub.sh file directly from the abg.fig file
  ## Used for making lbl files (abg2lbl_fig2txt)
  ##
  ##
  ###############################################################

35
36
37
38
39
40
41

42
43
44
45
46
47
48
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52







+







echo '# Commands to generate subsystem representations'>  $1_sub.sh
echo "# File $1_sub.sh"			>> $1_sub.sh
echo "# Generated by MTT on `date`."	>> $1_sub.sh
echo					>> $1_sub.sh

# Get a list of all components for the _abg file
cat $1_abg.fig |\
grep -v '\[[0-9]*:[0-9]*\]' |\
grep ':' |\
awk '{if ($1==4) split($14,a,":"); print a[1]}'  |\
sort -u > mtt_tmp1

# Remove all components starting with 0 or 1
grep -v '^[01]' < mtt_tmp1 > mtt_tmp4


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