Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
fcde587
declaration
valentinnodan May 5, 2022
2956824
merge master
valentinnodan May 5, 2022
19a1820
problem with build
valentinnodan Aug 5, 2022
42a2ecd
Regenerate build-bootstrap.xml, specify right jdk in project settings
qradimir Aug 5, 2022
4e96af1
ignored? declarations
valentinnodan Aug 5, 2022
b3ec713
.
valentinnodan Aug 6, 2022
ac0b770
.
valentinnodan Aug 6, 2022
790039f
Fix broken reference
qradimir Aug 6, 2022
1600707
Merge branch 'master' into dev-cat-templ
valentinnodan Apr 20, 2023
f2673df
converting
valentinnodan Apr 21, 2023
bc164aa
converters and printers
valentinnodan Apr 21, 2023
b611f79
Merge branch 'master' into dev-cat-templ
valentinnodan May 13, 2023
1a59813
.
valentinnodan May 13, 2023
a251f0a
support new format of persistence
valentinnodan May 13, 2023
dbb6393
hmi and dependent generation
valentinnodan May 14, 2023
88013ee
Merge branch 'master' into dev-cat-templ
valentinnodan May 15, 2023
6d1dddd
generators
valentinnodan May 17, 2023
49c46c6
check inputs and outputs
valentinnodan May 17, 2023
57e867b
.
valentinnodan May 18, 2023
3ba5d5f
add visuals
valentinnodan Jun 2, 2023
82cea9b
Merge branch 'master' into dev-cat-templ
valentinnodan Jun 2, 2023
94b2412
add visuals
valentinnodan Jun 2, 2023
3dded09
Merge branch 'master' into dev-cat-templ
valentinnodan Jan 24, 2024
52b9864
bug fixes and identifier changes(WIP)
valentinnodan Jan 24, 2024
3b14a59
update build-bootstrap.xml
qradimir Jan 27, 2024
b888046
Configure cat_visual's gradle.build.kts properly
qradimir Jan 27, 2024
3279ecd
Update .idea files
qradimir Jan 27, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .idea/codeStyles/Project.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion .idea/kotlinc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions .idea/libraries/ant_antlr.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions .idea/libraries/ant_launcher.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions .idea/libraries/apache_ant_junit.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 0 additions & 4 deletions .mps/encodings.xml

This file was deleted.

1 change: 1 addition & 0 deletions .mps/modules.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
<modulePath path="$PROJECT_DIR$/samples/smv-debugger/solutions/org.fbme.smvDebugger.sandbox/org.fbme.smvDebugger.sandbox.msd" folder="samples.smv debugger" />
<modulePath path="$PROJECT_DIR$/samples/statistics-plugin/buildsolution/org.fbme.samples.statisticsPlugin.build.msd" folder="samples.statistics plugin" />
<modulePath path="$PROJECT_DIR$/samples/statistics-plugin/solutions/org.fbme.samples.statisticsPlugin/org.fbme.samples.statisticsPlugin.msd" folder="samples.statistics plugin" />
<modulePath path="$PROJECT_DIR$/solutions/WaterTank/WaterTank.msd" folder="samples" />
</projectModules>
</component>
</project>
6 changes: 2 additions & 4 deletions .mps/runConfigurations/MPS_with_IEC_61499.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,13 @@
<MyState>
<option name="myVmOptions" value="-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005" />
<option name="myJrePath" value="" />
<option name="mySettingsPath" value="$USER_HOME$/Library/Preferences" />
<option name="mySettingsPath" value="$PROJECT_DIR$/../Library/Preferences" />
</MyState>
</myMpsSettings>
<myPluginsSettings>
<MyState>
<option name="myPluginsToDeploy">
<list>
<option value="r:d873dcfc-44fd-449a-83a0-b73f30522ba6(iec61499.build)/7065554940418943295" />
</list>
<list />
</option>
</MyState>
</myPluginsSettings>
Expand Down
3 changes: 3 additions & 0 deletions build-bootstrap.xml
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,9 @@
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.dataFlow.runtime.jar" />
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.findUsages.runtime.jar" />
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.lang.behavior.api.jar" />
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.lang.feedback.context.jar" />
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.lang.feedback.problem.legacy-constraints.jar" />
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.lang.feedback.problem.rt.jar" />
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.lang.migration.runtime.jar" />
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.lang.smodel.query.runtime.jar" />
<library file="${artifacts.mps}/languages/runtimes/jetbrains.mps.refactoring.runtime.jar" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,7 @@
</concept>
</language>
<language id="7866978e-a0f0-4cc7-81bc-4d213d9375e1" name="jetbrains.mps.lang.smodel">
<concept id="1179168000618" name="jetbrains.mps.lang.smodel.structure.Node_GetIndexInParentOperation" flags="nn" index="2bSWHS" />
<concept id="1177026924588" name="jetbrains.mps.lang.smodel.structure.RefConcept_Reference" flags="nn" index="chp4Y">
<reference id="1177026940964" name="conceptDeclaration" index="cht4Q" />
</concept>
Expand All @@ -487,6 +488,7 @@
<concept id="1145404486709" name="jetbrains.mps.lang.smodel.structure.SemanticDowncastExpression" flags="nn" index="2JrnkZ">
<child id="1145404616321" name="leftExpression" index="2JrQYb" />
</concept>
<concept id="1171310072040" name="jetbrains.mps.lang.smodel.structure.Node_GetContainingRootOperation" flags="nn" index="2Rxl7S" />
<concept id="2644386474300074836" name="jetbrains.mps.lang.smodel.structure.ConceptIdRefExpression" flags="nn" index="35c_gC">
<reference id="2644386474300074837" name="conceptDeclaration" index="35c_gD" />
</concept>
Expand Down Expand Up @@ -3052,6 +3054,17 @@
</node>
</node>
</node>
<node concept="3clFbF" id="6wjDFs17gjt" role="3cqZAp">
<node concept="2OqwBi" id="6wjDFs18bsu" role="3clFbG">
<node concept="2OqwBi" id="6wjDFs184KQ" role="2Oq$k0">
<node concept="37vLTw" id="6wjDFs17gjr" role="2Oq$k0">
<ref role="3cqZAo" node="5HzRr7EKTG3" resolve="fb" />
</node>
<node concept="2Rxl7S" id="6wjDFs188eD" role="2OqNvi" />
</node>
<node concept="2bSWHS" id="6wjDFs18f3d" role="2OqNvi" />
</node>
</node>
<node concept="3cpWs8" id="5HzRr7EKXYd" role="3cqZAp">
<node concept="3cpWsn" id="5HzRr7EKXYe" role="3cpWs9">
<property role="TrG5h" value="resource" />
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
<?xml version="1.0" encoding="UTF-8"?>
<FBType Name="JSON_DESERIALIZER" Comment="Composite FB wrapping other FBs">
<Identification Standard="61499-2">
</Identification>
<VersionInfo Version="1.0" Author="valentinnodan" Date="2023-04-20">
</VersionInfo>
<InterfaceList>
<EventInputs>
<Event Name="REQ" Type="Event" Comment="Normal Execution Request">
<With Var="DATA"/>
</Event>
</EventInputs>
<EventOutputs>
<Event Name="RES" Type="Event" Comment="Execution Confirmation">
<With Var="BOOL_VALUE"/>
<With Var="INT_VALUE"/>
<With Var="STRING_VALUE"/>
<With Var="REAL_VALUE"/>
<With Var="LREAL_VALUE"/>
<With Var="NAME"/>
</Event>
</EventOutputs>
<InputVars>
<VarDeclaration Name="DATA" Type="STRING" Comment="Input event qualifier"/>
</InputVars>
<OutputVars>
<VarDeclaration Name="NAME" Type="STRING" Comment=""/>
<VarDeclaration Name="BOOL_VALUE" Type="BOOL" Comment="Output event qualifier"/>
<VarDeclaration Name="INT_VALUE" Type="INT" Comment=""/>
<VarDeclaration Name="STRING_VALUE" Type="STRING" Comment=""/>
<VarDeclaration Name="REAL_VALUE" Type="REAL" Comment=""/>
<VarDeclaration Name="LREAL_VALUE" Type="LREAL" Comment=""/>
</OutputVars>
</InterfaceList>
<FBNetwork>
<FB Name="TYPE_DETECTOR" Type="TYPE_DETECTOR" Comment="" x="1529.4117647058822" y="-235.2941176470588">
</FB>
<FB Name="JSON_PARSER" Type="JSON_PARSER" Comment="" x="470.5882352941176" y="-1058.8235294117646">
</FB>
<FB Name="F_STRING_TO_BOOL" Type="F_STRING_TO_BOOL" Comment="" x="3764.705882352941" y="-588.2352941176471">
</FB>
<FB Name="F_STRING_TO_INT" Type="F_STRING_TO_INT" Comment="" x="3764.705882352941" y="0.0">
</FB>
<FB Name="F_STRING_TO_REAL" Type="F_STRING_TO_REAL" Comment="" x="3764.705882352941" y="588.2352941176471">
</FB>
<FB Name="F_STRING_TO_LREAL" Type="F_STRING_TO_LREAL" Comment="" x="3764.705882352941" y="1176.4705882352941">
</FB>
<EventConnections>
<Connection Source="REQ" Destination="JSON_PARSER.REQ" Comment="" dx1="294.11764705882354"/>
<Connection Source="JSON_PARSER.RES" Destination="TYPE_DETECTOR.REQ" Comment="" dx1="129.41176470588235"/>
<Connection Source="TYPE_DETECTOR.IS_BOOL" Destination="F_STRING_TO_BOOL.REQ" Comment="" dx1="670.5882352941176"/>
<Connection Source="F_STRING_TO_BOOL.CNF" Destination="RES" Comment="" dx1="241.17647058823528"/>
<Connection Source="TYPE_DETECTOR.IS_INT" Destination="F_STRING_TO_INT.REQ" Comment="" dx1="494.1176470588235"/>
<Connection Source="TYPE_DETECTOR.IS_REAL" Destination="F_STRING_TO_REAL.REQ" Comment="" dx1="670.5882352941176"/>
<Connection Source="TYPE_DETECTOR.IS_LREAL" Destination="F_STRING_TO_LREAL.REQ" Comment="" dx1="670.5882352941176"/>
<Connection Source="F_STRING_TO_INT.CNF" Destination="RES" Comment="" dx1="558.8235294117646"/>
<Connection Source="F_STRING_TO_REAL.CNF" Destination="RES" Comment="" dx1="535.2941176470588"/>
<Connection Source="F_STRING_TO_LREAL.CNF" Destination="RES" Comment="" dx1="511.7647058823529"/>
<Connection Source="TYPE_DETECTOR.IS_STRING" Destination="RES" Comment="" dx1="1723.5294117647059"/>
</EventConnections>
<DataConnections>
<Connection Source="DATA" Destination="JSON_PARSER.DATA" Comment="" dx1="294.11764705882354"/>
<Connection Source="JSON_PARSER.TYPE" Destination="TYPE_DETECTOR.TYPE_NAME" Comment="" dx1="129.41176470588235"/>
<Connection Source="JSON_PARSER.VALUE" Destination="F_STRING_TO_BOOL.IN" Comment="" dx1="1270.5882352941176"/>
<Connection Source="JSON_PARSER.VALUE" Destination="F_STRING_TO_INT.IN" Comment="" dx1="1558.8235294117646"/>
<Connection Source="F_STRING_TO_BOOL.OUT" Destination="BOOL_VALUE" Comment="" dx1="241.17647058823528"/>
<Connection Source="JSON_PARSER.NAME" Destination="NAME" Comment="" dx1="1652.941176470588"/>
<Connection Source="JSON_PARSER.VALUE" Destination="F_STRING_TO_REAL.IN" Comment="" dx1="1247.0588235294117"/>
<Connection Source="JSON_PARSER.VALUE" Destination="F_STRING_TO_LREAL.IN" Comment="" dx1="1247.0588235294117"/>
<Connection Source="F_STRING_TO_INT.OUT" Destination="INT_VALUE" Comment="" dx1="558.8235294117646"/>
<Connection Source="F_STRING_TO_REAL.OUT" Destination="REAL_VALUE" Comment="" dx1="535.2941176470588"/>
<Connection Source="F_STRING_TO_LREAL.OUT" Destination="LREAL_VALUE" Comment="" dx1="511.7647058823529"/>
<Connection Source="JSON_PARSER.VALUE" Destination="STRING_VALUE" Comment="" dx1="2300.0"/>
</DataConnections>
</FBNetwork>
</FBType>
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<FBType Name="JSON_FORMER" Comment="Basic FB with empty ECC">
<Identification Standard="61499-2">
</Identification>
<VersionInfo Version="1.0" Author="valentinnodan" Date="2023-04-20">
</VersionInfo>
<InterfaceList>
<EventInputs>
<Event Name="REQ" Type="Event" Comment="">
<With Var="NAME"/>
<With Var="TYPE"/>
<With Var="VALUE"/>
</Event>
</EventInputs>
<EventOutputs>
<Event Name="RES" Type="Event" Comment="">
<With Var="DATA_MSG"/>
</Event>
</EventOutputs>
<InputVars>
<VarDeclaration Name="NAME" Type="STRING" Comment=""/>
<VarDeclaration Name="TYPE" Type="STRING" Comment=""/>
<VarDeclaration Name="VALUE" Type="STRING" Comment=""/>
</InputVars>
<OutputVars>
<VarDeclaration Name="DATA_MSG" Type="STRING" Comment=""/>
</OutputVars>
</InterfaceList>
<BasicFB>
<ECC>
<ECState Name="START" Comment="Initial State" x="547.0588235294117" y="423.52941176470586">
</ECState>
<ECState Name="FORM_MSG" Comment="" x="2470.5882352941176" y="588.2352941176471">
<ECAction Algorithm="formMessage" Output="RES"/>
</ECState>
<ECTransition Source="START" Destination="FORM_MSG" Condition="REQ" Comment="" x="1658.8235294117646" y="770.5882352941176"/>
<ECTransition Source="FORM_MSG" Destination="START" Condition="1" Comment="" x="1623.5294117647059" y="488.235294117647"/>
</ECC>
<Algorithm Name="formMessage" Comment="">
<ST><![CDATA[VAR
openBrace: STRING;
closeBrace: STRING;
quote: STRING;
splitter: STRING;
separator: STRING;
nameMsg:STRING;
typeMsg: STRING;
valueMsg: STRING;
valueName: STRING;
nameName: STRING;
typeName: STRING;
END_VAR;
quote := '"';
openBrace := '{';
closeBrace := '}';
splitter:= ':';
separator:=',';
nameName:='NAME';
typeName:='TYPE';
valueName:='VALUE';
nameMsg:=CONCAT(quote, nameName, quote, splitter, quote, NAME, quote);
typeMsg:=CONCAT(quote, typeName, quote, splitter, quote, TYPE, quote);
valueMsg:=CONCAT(quote, valueName, quote, splitter, quote, VALUE, quote);
DATA_MSG:=CONCAT(CONCAT(openBrace, CONCAT(nameMsg, separator)), CONCAT(CONCAT(typeMsg, separator), CONCAT(valueMsg, closeBrace)));]]></ST>
</Algorithm>
</BasicFB>
</FBType>
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
<?xml version="1.0" encoding="UTF-8"?>
<FBType Name="JSON_PARSER" Comment="Basic FB with empty ECC">
<Identification Standard="61499-2">
</Identification>
<VersionInfo Version="1.0" Author="valentinnodan" Date="2023-04-19">
</VersionInfo>
<InterfaceList>
<EventInputs>
<Event Name="REQ" Type="Event" Comment="">
<With Var="DATA"/>
</Event>
</EventInputs>
<EventOutputs>
<Event Name="RES" Type="Event" Comment="">
<With Var="NAME"/>
<With Var="TYPE"/>
<With Var="VALUE"/>
</Event>
</EventOutputs>
<InputVars>
<VarDeclaration Name="DATA" Type="STRING" Comment=""/>
</InputVars>
<OutputVars>
<VarDeclaration Name="NAME" Type="STRING" Comment=""/>
<VarDeclaration Name="TYPE" Type="STRING" Comment=""/>
<VarDeclaration Name="VALUE" Type="STRING" Comment=""/>
</OutputVars>
</InterfaceList>
<BasicFB>
<ECC>
<ECState Name="START" Comment="Initial State" x="588.2352941176471" y="470.5882352941176">
</ECState>
<ECState Name="PARSE" Comment="" x="2300.0" y="641.1764705882352">
<ECAction Algorithm="ALG1" Output="RES"/>
</ECState>
<ECTransition Source="START" Destination="PARSE" Condition="REQ" Comment="" x="1641.1764705882351" y="647.0588235294117"/>
<ECTransition Source="PARSE" Destination="START" Condition="1" Comment="" x="1599.9999999999998" y="617.6470588235294"/>
</ECC>
<Algorithm Name="ALG1" Comment="">
<ST><![CDATA[VAR
pos : INT;
currLen: INT;
inString: BOOL;
c: STRING;
fieldType: STRING;
fieldValue: STRING;
currField: STRING;
step: INT;
END_VAR;
step := 1;
WHILE pos < LEN(DATA) DO
c := MID(DATA, step, pos);
IF c = '{' THEN (* Start of object *)
pos := pos + 1;
ELSIF c = '}' THEN (* End of object *)
pos := pos + 1;
ELSIF c = '"' or c = '$'' THEN (* Start or end of string *)
IF inString THEN (* End of string *)
inString := FALSE;
pos := pos + 1;
ELSE (* Start of string *)
inString := TRUE;
pos := pos + 1;
END_IF;
ELSIF c = ':' THEN (* Key-value pair separator *)
IF NOT inString THEN (* Outside of string *)
currField := fieldValue;
fieldValue := "";
pos := pos + 1;
ELSE (* Inside of string *)
fieldValue := CONCAT(fieldValue, c);
pos := pos + 1;
END_IF;
ELSIF c = ',' THEN (* Value separator *)
IF NOT inString THEN (* Outside of string *)
IF currField = 'NAME' THEN
NAME := fieldValue;
ELSIF currField = 'TYPE' THEN
TYPE :=fieldValue;
ELSIF currField = 'VALUE' THEN
VALUE := fieldValue;
END_IF;
currField := '';
fieldValue := '';
pos := pos + 1;
ELSE (* Inside of string *)
fieldValue := CONCAT(fieldValue, c);
pos := pos + 1;
END_IF;
ELSE (* Other characters *)
IF inString THEN (* Inside of string *)
fieldValue := CONCAT(fieldValue, c);
pos := pos + 1;
ELSE (* Outside of string *)
pos := pos + 1;
END_IF;
END_IF;
END_WHILE;
IF currField = 'NAME' THEN
NAME := fieldValue;
ELSIF currField = 'TYPE' THEN
TYPE :=fieldValue;
ELSIF currField = 'VALUE' THEN
VALUE := fieldValue;
END_IF;]]></ST>
</Algorithm>
</BasicFB>
</FBType>
Loading