Inputs / ouptputs
The Saber Suite :
SaberScope
,
SaberSketch
, and
Saber
,
consists in a complete development environment for complex systems. However, some tips are not always identified or are difficult to find.
format p1 - p2 :
This format was valid for the version 4 .* of
SaberScope
. Maybe is it still functionnal ?
Its advantage was to easily build ASCII files by scripting directly readable by
SaberScope
.
The format consists of two files whose names have the syntax *.p1.* et *.p2.*. For "p1" separators can be tabs
or spaces, except for the first line where the separation is delimited by spaces.
The first line of "P2" may be a comment by a "# ". The data can be separated by commas, spaces or tabs.
"courants.p1.test" file :
data_file courants.p2.test
xname t
xunits s
ynames "Input current @ 25.5v Rinrush = 0.4/In" i(v_sin.v_b) i(v_sin.v_c)
yunits A A A
"courants.p2.test" file :
0.094 0.0564 -0.0329 0.0234
0.095 0.0543 -0.0310 0.0233
0.096 0.0541 -0.0308 0.0233
...
|
|
Mast syntax
Comments, sentence termination et line continuation, file inclusion
-
# "sharp" symbol, comment in beginning of line
or after a completed command
-
; semi-colon for readability to keep the brace on the same line
for instance : struc {number n1, n2 ; } var_array[*]
-
\ "backslash" symbol, continuation character
-
< File inclusion , must be the first character of the line
for instance : "<consts.sin"
|
|
Mast functions
Initializing arrays :
In a
Mast
function, it is possible to initialize a fixed-length array directly.
However the trick is to declare it before intitializing it :
struc {
number n1, n2
} var_array[*]
var_array = [(0,1),(2,3)]
# or struc {number n1, n2 ; } var_array[*]
|
|