| ... |
... |
@@ -1,4 +1,4 @@ |
| 1 |
|
-[[~[~[image:attach:SCCharts@download.png~]~]>>url:http://rtsys.informatik.uni-kiel.de/confluence/display/KIELER/SCCharts#SCCharts-Downloads||shape="rect"]] [[~[~[image:attach:SCCharts@onlinecompiler.png~]~]>>url:http://www.sccharts.com||shape="rect"]] (% class="confluence-link" %)[[image:attach:Command Line Compiler@commandlinecompiler2.png]][[doc:Command Line Compiler]](%%) [[image:attach:SCCharts@quickstart.png]][[doc:Quick Start Guide]] |
|
1 |
+[[~[~[image:attach:SCCharts@download.png~]~]>>url:http://rtsys.informatik.uni-kiel.de/confluence/display/KIELER/SCCharts#SCCharts-Downloads||shape="rect"]] [[~[~[image:attach:SCCharts@onlinecompiler.png~]~]>>url:http://www.sccharts.com||shape="rect"]] (% class="confluence-link" %)[[image:attach:Command Line Compiler@commandlinecompiler2.png]][[doc:Command Line Compiler]](%%) [[image:attach:SCCharts@quickstart.png]][[doc:Quick Start Guide (pre 0\.13)]] |
| 2 |
2 |
|
| 3 |
3 |
= SCCharts Examples = |
| 4 |
4 |
|
| ... |
... |
@@ -16,6 +16,43 @@ |
| 16 |
16 |
))) |
| 17 |
17 |
|(% colspan="1" %)(% colspan="1" %) |
| 18 |
18 |
((( |
|
19 |
+= ABO = |
|
20 |
+)))|(% colspan="1" %)(% colspan="1" %) |
|
21 |
+((( |
|
22 |
+ |
|
23 |
+)))|(% colspan="1" %)(% colspan="1" %) |
|
24 |
+((( |
|
25 |
+[[image:attach:abo.png]] |
|
26 |
+)))|(% colspan="1" %)(% colspan="1" %) |
|
27 |
+((( |
|
28 |
+{{code title="ABO.sct"}} |
|
29 |
+@VHLayout |
|
30 |
+scchart ABO { |
|
31 |
+ input output bool A; |
|
32 |
+ input output bool B; |
|
33 |
+ output bool O1; |
|
34 |
+ output bool O2; |
|
35 |
+ region: |
|
36 |
+ |
|
37 |
+ initial state Init |
|
38 |
+ --> WaitAB immediate with / O1 = false; O2 = false; |
|
39 |
+ state WaitAB { |
|
40 |
+ region HandleA: |
|
41 |
+ initial state WaitA |
|
42 |
+ --> DoneA immediate with A / B = true; O1 = true; |
|
43 |
+ final state DoneA; |
|
44 |
+ region HandleB: |
|
45 |
+ initial state WaitB |
|
46 |
+ --> DoneB with B / O1 = true; |
|
47 |
+ final state DoneB; |
|
48 |
+ } |
|
49 |
+ >-> GotAB with / O1 = false; O2 = true; |
|
50 |
+ state GotAB; |
|
51 |
+} |
|
52 |
+{{/code}} |
|
53 |
+))) |
|
54 |
+|(% colspan="1" %)(% colspan="1" %) |
|
55 |
+((( |
| 19 |
19 |
= clock = |
| 20 |
20 |
|
| 21 |
21 |
(Referenced SCCharts Example) |
| ... |
... |
@@ -35,7 +35,7 @@ |
| 35 |
35 |
[[image:attach:clock2h.png]] |
| 36 |
36 |
)))|(% colspan="1" %)(% colspan="1" %) |
| 37 |
37 |
((( |
| 38 |
|
-{{code title="shifter3.sct" language="sct"}} |
|
75 |
+{{code language="sct" title="shifter3.sct"}} |
| 39 |
39 |
scchart delay { |
| 40 |
40 |
input int ticksToWait; |
| 41 |
41 |
input bool clock; |
| ... |
... |
@@ -49,7 +49,7 @@ |
| 49 |
49 |
} |
| 50 |
50 |
{{/code}} |
| 51 |
51 |
|
| 52 |
|
-{{code title="shifter3.sct" language="sct"}} |
|
89 |
+{{code language="sct" title="shifter3.sct"}} |
| 53 |
53 |
scchart emitter { |
| 54 |
54 |
input bool clock; |
| 55 |
55 |
input bool delay; |
| ... |
... |
@@ -68,7 +68,7 @@ |
| 68 |
68 |
} |
| 69 |
69 |
{{/code}} |
| 70 |
70 |
|
| 71 |
|
-{{code title="shifter3.sct" language="sct"}} |
|
108 |
+{{code language="sct" title="shifter3.sct"}} |
| 72 |
72 |
scchart clock { |
| 73 |
73 |
input bool msClock; |
| 74 |
74 |
output bool second; |
| ... |
... |
@@ -129,7 +129,7 @@ |
| 129 |
129 |
[[image:attach:PLDI'14 Artifact on SCCharts@shifter3.png]] |
| 130 |
130 |
)))|(% colspan="1" %)(% colspan="1" %) |
| 131 |
131 |
((( |
| 132 |
|
-{{code title="shifter3.sct" language="sct"}} |
|
169 |
+{{code language="sct" title="shifter3.sct"}} |
| 133 |
133 |
scchart shifter3 { |
| 134 |
134 |
input signal int I = 1; |
| 135 |
135 |
signal int S0; |
| ... |
... |
@@ -155,7 +155,7 @@ |
| 155 |
155 |
[[image:attach:PLDI'14 Artifact on SCCharts@reincarnation.png]] |
| 156 |
156 |
)))|(% colspan="1" %)(% colspan="1" %) |
| 157 |
157 |
((( |
| 158 |
|
-{{code title="reincarnation.sct" language="sct"}} |
|
195 |
+{{code language="sct" title="reincarnation.sct"}} |
| 159 |
159 |
scchart reincarnation { |
| 160 |
160 |
input signal A; |
| 161 |
161 |
output signal gotS; |
| ... |
... |
@@ -185,7 +185,7 @@ |
| 185 |
185 |
[[image:attach:PLDI'14 Artifact on SCCharts@cabin.png]] |
| 186 |
186 |
)))|(% colspan="1" %)(% colspan="1" %) |
| 187 |
187 |
((( |
| 188 |
|
-{{code title="cabin.sct" language="sct"}} |
|
225 |
+{{code language="sct" title="cabin.sct"}} |
| 189 |
189 |
scchart Cabin { |
| 190 |
190 |
input signal Stop; |
| 191 |
191 |
input signal CabinStopped; |
| ... |
... |
@@ -233,7 +233,7 @@ |
| 233 |
233 |
[[image:attach:PLDI'14 Artifact on SCCharts@reactor-control.png]] |
| 234 |
234 |
)))|(% colspan="1" %)(% colspan="1" %) |
| 235 |
235 |
((( |
| 236 |
|
-{{code title="reactor-control.sct" language="sct"}} |
|
273 |
+{{code language="sct" title="reactor-control.sct"}} |
| 237 |
237 |
scchart Module_ReactorControl { |
| 238 |
238 |
output signal PullOutRods; |
| 239 |
239 |
output signal PushInRods; |