Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
monticore
EmbeddedMontiArc
generators
EMAM2Cpp
Commits
bef0bcc4
Commit
bef0bcc4
authored
Jan 08, 2018
by
Sascha Niklas Schneiders
Browse files
error is fixed now
parent
67f1d3d7
Changes
10
Hide whitespace changes
Inline
Side-by-side
src/test/resources/fas/basicLibrary/Not.emam
View file @
bef0bcc4
...
...
@@ -6,10 +6,10 @@ component Not<T> {
out
T
out1
;
implementation
Math
{
if
in1
==
0
{
if
in1
==
0
out1
=
1
;
}
else
{
else
out1
=
0
;
}
end
end
}
}
src/test/resources/fas/basicLibrary/Switch.emam
View file @
bef0bcc4
...
...
@@ -9,11 +9,11 @@ component Switch<T=B> { // if no generic is given, then default type B is taken
out
T
out1
;
implementation
Math
{
if
cond
{
if
cond
out1
=
in1
;
}
else
{
else
out1
=
in3
;
}
end
}
}
src/test/resources/optimizer/ComplexMatrixLeftMultiplicationAddition2.emam
View file @
bef0bcc4
...
...
@@ -12,8 +12,8 @@ component ComplexMatrixLeftMultiplicationAddition2{
Q
^{
1000
,
200
}
a
=
mat1
;
Q
^{
1000
,
200
}
b
=
mat1
;
Q
^{
1000
,
200
}
c
=
a
;
Q
^{
1000
,
200
}
d
=
b
;
matOut
=
c
*
mat2
+
d
*
mat4
;
Q
^{
1000
,
200
}
mat
d
=
b
;
matOut
=
c
*
mat2
+
mat
d
*
mat4
;
}
}
\ No newline at end of file
src/test/resources/optimizer/ComplexMatrixRightMultiplicationAddition2.emam
View file @
bef0bcc4
...
...
@@ -11,10 +11,10 @@ component ComplexMatrixRightMultiplicationAddition2{
Q
^{
200
,
1000
}
a
=
mat1
;
Q
^{
200
,
1000
}
b
=
mat1
;
Q
^{
200
,
1000
}
c
=
a
;
Q
^{
200
,
1000
}
d
=
b
;
Q
^{
200
,
1000
}
mat
d
=
b
;
matOut
=
mat2
*
c
+
mat4
*
d
;
matOut
=
mat2
*
c
+
mat4
*
mat
d
;
}
}
\ No newline at end of file
src/test/resources/results/optimizer/l1/optimizer_complexMatrixLeftMultiplicationAddition2.h
View file @
bef0bcc4
...
...
@@ -23,7 +23,7 @@ void execute()
Matrix
a
=
mat1
;
Matrix
b
=
mat1
;
Matrix
c
=
a
;
Matrix
d
=
b
;
Matrix
mat
d
=
b
;
matOut
=
mat1
*
(
mat2
+
mat4
);
}
...
...
src/test/resources/results/optimizer/l1/optimizer_complexMatrixRightMultiplicationAddition2.h
View file @
bef0bcc4
...
...
@@ -22,7 +22,7 @@ void execute()
Matrix
a
=
mat1
;
Matrix
b
=
mat1
;
Matrix
c
=
a
;
Matrix
d
=
b
;
Matrix
mat
d
=
b
;
matOut
=
(
mat2
+
mat4
)
*
mat1
;
}
...
...
src/test/resources/simulator-ts/visualization/movement/ConstantVelocity.emam
View file @
bef0bcc4
...
...
@@ -10,12 +10,12 @@ component ConstantVelocity {
B
cond
=
time
<
1
s
;
if
cond
{
if
cond
acceleration
=
0
m
/
s
^
2
;
}
else
{
else
acceleration
=
2
m
/
s
^
2
;
}
end
}
}
src/test/resources/simulator-ts/visualization/movement/SteeringControl.emam
View file @
bef0bcc4
...
...
@@ -21,35 +21,35 @@ component SteeringControl {
B
comp3
=
(
slf
<
slb
)
&&
(
srf
<
srb
);
Q
(
0
°
:-
1
°
)
resComp3
=
0
°
;
if
comp3
{
if
comp3
resComp3
=
-
1
°
;
}
else
{
else
resComp3
=
0
°
;
}
end
Q
(
5
°
:-
1
°
)
resComp2
=
0
°
;
if
comp2
{
if
comp2
resComp2
=
5
°
;
}
else
{
else
resComp2
=
resComp3
;
}
end
if
comp1
{
if
comp1
steering
=
-
5
°
;
}
else
{
else
steering
=
resComp2
;
}
end
}
...
...
src/test/resources/testing/ForLoopIf.emam
View file @
bef0bcc4
...
...
@@ -8,15 +8,15 @@ for i = 1:1:8
result
=
result
+
counter
;
end
if
counter
<
0
{
if
counter
<
0
result
=
0
;
}
elseif
counter
<
100
{
elseif
counter
<
100
result
=
counter
;
}
else
{
else
result
=
100
;
}
end
}
}
\ No newline at end of file
src/test/resources/testing/subpackage1/Comp1.emam
View file @
bef0bcc4
...
...
@@ -11,11 +11,11 @@ component Comp1 {
out
Q
(
0.0
:
0.1
:
100.0
)
out3
;
implementation
Math
{
if
in1
==
0
{
if
in1
==
0
out1
=
1
;
}
else
{
else
out1
=
0
;
}
end
end
out2
=
-
in2
;
out3
=
100.0
-
in3
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment