Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
E
EMAM2Middleware
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
4
Issues
4
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
1
Merge Requests
1
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Test Cases
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
monticore
EmbeddedMontiArc
generators
EMAM2Middleware
Commits
e3dae7d8
Commit
e3dae7d8
authored
Feb 16, 2018
by
Alexander David Hellwig
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Changed SimpleDist.tag to use new Syntax: simple RosConnection tag
parent
de3f01f5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
5 deletions
+23
-5
src/main/java/de/monticore/lang/monticar/generator/master/DistributedTargetGenerator.java
...monticar/generator/master/DistributedTargetGenerator.java
+2
-0
src/test/resources/tests/dist/DistComp.emam
src/test/resources/tests/dist/DistComp.emam
+15
-1
src/test/resources/tests/dist/SimpleDist.tag
src/test/resources/tests/dist/SimpleDist.tag
+6
-4
No files found.
src/main/java/de/monticore/lang/monticar/generator/master/DistributedTargetGenerator.java
View file @
e3dae7d8
...
...
@@ -81,9 +81,11 @@ public class DistributedTargetGenerator extends CMakeMasterGenerator {
if
(
Objects
.
equals
(
connectorSymbol
.
getSourcePort
().
getComponentInstance
().
orElse
(
null
),
componentInstanceSymbol
))
{
//In port of supercomp
inferRosConnectionIfPossible
(
connectorSymbol
.
getSourcePort
(),
connectorSymbol
.
getTargetPort
());
generateRosConnectionIfPossible
(
connectorSymbol
);
}
else
if
(
Objects
.
equals
(
connectorSymbol
.
getTargetPort
().
getComponentInstance
().
orElse
(
null
),
componentInstanceSymbol
))
{
//out port of supercomp
inferRosConnectionIfPossible
(
connectorSymbol
.
getTargetPort
(),
connectorSymbol
.
getSourcePort
());
generateRosConnectionIfPossible
(
connectorSymbol
);
}
else
{
//In between subcomps
generateRosConnectionIfPossible
(
connectorSymbol
);
...
...
src/test/resources/tests/dist/DistComp.emam
View file @
e3dae7d8
package
tests
.
dist
;
component
DistComp
{
port
out
Q
resOut
;
component
SubComp1
{
ports
out
Q
out1
,
out
Q
out2
;
implementation
Math
{
out1
=
out1
+
1
;
out2
=
out2
+
2
;
}
}
component
SubComp2
{
ports
in
Q
in1
,
in
Q
in2
;
in
Q
in2
,
out
Q
resOut
;
implementation
Math
{
resOut
=
in1
+
in2
;
}
}
instance
SubComp1
sub1
;
...
...
@@ -16,4 +29,5 @@ component DistComp{
connect
sub1
.
out1
->
sub2
.
in1
;
connect
sub1
.
out2
->
sub2
.
in2
;
connect
sub2
.
resOut
->
resOut
;
}
\ No newline at end of file
src/test/resources/tests/dist/SimpleDist.tag
View file @
e3dae7d8
...
...
@@ -2,8 +2,10 @@ package tests.dist;
conforms
to
de
.
monticore
.
lang
.
monticar
.
generator
.
roscpp
.
RosToEmamTagSchema
;
tags
SimpleDist
{
tag
distComp
.
sub1
.
out1
with
RosConnection
=
{
topic
=
(
topicIn1
,
std_msgs
/
Float64
),
msgField
=
data
};
tag
distComp
.
sub1
.
out2
with
RosConnection
=
{
topic
=
(
topicIn2
,
std_msgs
/
Float64
),
msgField
=
data
};
tag
distComp
.
sub2
.
in1
with
RosConnection
=
{
topic
=
(
topicIn1
,
std_msgs
/
Float64
),
msgField
=
data
};
tag
distComp
.
sub2
.
in2
with
RosConnection
=
{
topic
=
(
topicIn2
,
std_msgs
/
Float64
),
msgField
=
data
};
tag
distComp
.
sub1
.
out1
with
RosConnection
;
tag
distComp
.
sub1
.
out2
with
RosConnection
;
tag
distComp
.
sub2
.
in1
with
RosConnection
;
tag
distComp
.
sub2
.
in2
with
RosConnection
;
tag
distComp
.
sub2
.
resOut
with
RosConnection
;
tag
distComp
.
resOut
with
RosConnection
;
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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