<
From version < 4.1 >
edited by aas2
on 2017/08/03 10:05
To version < 3.1 >
edited by aas2
on 2017/08/02 21:12
>
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -83,327 +83,6 @@
83 83  
84 84  The new project builder is configured using a domain specific language, namely KiBuild. Corresponding to the actions that are performed during the build, its configuration consists of //model compilers//, //simulation compilers// and //template processors//. A template processor is either a //simple template processor//, //wrapper code template processor// or //simulation template processor//.
85 85  
86 -When writing the configuration, use code completion to see available attributes for the entities. The following table describes the available attributes.
87 -
88 -(% class="relative-table" style="width: 99.937%;" %)
89 -|=(((
90 -**Attribute**
91 -)))|=(((
92 -Domain
93 -)))|=(% colspan="1" %)(% colspan="1" %)
94 -(((
95 -Default Value
96 -)))|=(((
97 -Description
98 -)))
99 -|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
100 -(((
101 -**KiCo Model Compiler**
102 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
103 -(((
104 -\\
105 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
106 -(((
107 -\\
108 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
109 -(((
110 -\\
111 -)))
112 -|(% colspan="1" %)(% colspan="1" %)
113 -(((
114 -outputFolder
115 -)))|(% colspan="1" %)(% colspan="1" %)
116 -(((
117 -String
118 -)))|(% colspan="1" %)(% colspan="1" %)
119 -(((
120 -kieler-gen
121 -)))|(% colspan="1" %)(% colspan="1" %)
122 -(((
123 -{{{The folder in which compilation output is saved}}}
124 -)))
125 -|(% colspan="1" %)(% colspan="1" %)
126 -(((
127 -whitelist
128 -)))|(% colspan="1" %)(% colspan="1" %)
129 -(((
130 -String, Regular expression
131 -)))|(% colspan="1" %)(% colspan="1" %)
132 -(((
133 --
134 -)))|(% colspan="1" %)(% colspan="1" %)
135 -(((
136 -Only model files that have a location matching this regular expression are compiled. Thus to compile only a specific model, one can use the expression "ModelName.sctx"
137 -)))
138 -|(% colspan="1" %)(% colspan="1" %)
139 -(((
140 -blacklist
141 -)))|(% colspan="1" %)(% colspan="1" %)
142 -(((
143 -String, Regular expression
144 -)))|(% colspan="1" %)(% colspan="1" %)
145 -(((
146 --
147 -)))|(% colspan="1" %)(% colspan="1" %)
148 -(((
149 -Model files that have a location matching this regular expression are exluded from the build. Thus to exclued all models and skip compilation, one can use ".*", which matches everything.
150 -)))
151 -|(% colspan="1" %)(% colspan="1" %)
152 -(((
153 -compilationSystem
154 -)))|(% colspan="1" %)(% colspan="1" %)
155 -(((
156 -String, Id of a pre-defined compilation system or project relative file path to a system definition
157 -)))|(% colspan="1" %)(% colspan="1" %)
158 -(((
159 -de.cau.cs.kieler.sccharts.netlist.simple
160 -)))|(% colspan="1" %)(% colspan="1" %)
161 -(((
162 -The compilation system that is used by KiCo to determine the compile chain.
163 -)))
164 -|(% colspan="1" %)(% colspan="1" %)
165 -(((
166 -outputFileExtension
167 -)))|(% colspan="1" %)(% colspan="1" %)
168 -(((
169 -String
170 -)))|(% colspan="1" %)(% colspan="1" %)
171 -(((
172 -c
173 -)))|(% colspan="1" %)(% colspan="1" %)
174 -(((
175 -Compiled models are saved with using this file extension. Thus this attribute should match the code format that is generated by KiCo at the end of the compilation.
176 -)))
177 -|(% colspan="1" %)(% colspan="1" %)
178 -(((
179 -outputTemplate
180 -)))|(% colspan="1" %)(% colspan="1" %)
181 -(((
182 -String, Project relative file path
183 -)))|(% colspan="1" %)(% colspan="1" %)
184 -(((
185 --
186 -)))|(% colspan="1" %)(% colspan="1" %)
187 -(((
188 -An optional template to add surrounding code to KiCo generated output for every compiled file. In the template the placeholder **${kico_code}** can be used an will be replaced with the compiled code.
189 -)))
190 -|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
191 -(((
192 -**Simulation Compiler**
193 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
194 -(((
195 -\\
196 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
197 -(((
198 -\\
199 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
200 -(((
201 -\\
202 -)))
203 -|(% colspan="1" %)(% colspan="1" %)
204 -(((
205 -command
206 -)))|(% colspan="1" %)(% colspan="1" %)
207 -(((
208 -String
209 -)))|(% colspan="1" %)(% colspan="1" %)
210 -(((
211 -For C:
212 -
213 -"gcc -std=c99 -Werror=int-conversion -o \"./${outputFolder}/${executable_name}\""
214 -
215 -For Java:
216 -
217 -"jar cvfe \"../${outputFolder}/${executable_name}\""
218 -)))|(% colspan="1" %)(% colspan="1" %)
219 -(((
220 -The command that is called to compile simulation code to an executable.
221 -
222 -In case of the C simulation, the compiled file is added implicitly as additional parameter, to create an executable.
223 -
224 -In case of Java, all class files and the class file of the compiled model are added implicitly to create an executable JAR file.
225 -)))
226 -|(% colspan="1" %)(% colspan="1" %)
227 -(((
228 -outputFolder
229 -)))|(% colspan="1" %)(% colspan="1" %)
230 -(((
231 -String, Project relative folder path
232 -)))|(% colspan="1" %)(% colspan="1" %)
233 -(((
234 -kieler-gen/sim/bin
235 -)))|(% colspan="1" %)(% colspan="1" %)
236 -(((
237 -The folder in which compiled output will be saved.
238 -
239 -Note that it is possible to use a command that creates the compiled files in a different location. However the folder specified in this attribute is created before the command is executed and refreshed afterwards. This ensures that the folder exists and changes will be noticed in the Eclipse workspace.
240 -)))
241 -|(% colspan="1" %)(% colspan="1" %)
242 -(((
243 -libFolder
244 -)))|(% colspan="1" %)(% colspan="1" %)
245 -(((
246 -String, Project relative folder path
247 -)))|(% colspan="1" %)(% colspan="1" %)
248 -(((
249 -kieler-gen/sim/lib
250 -)))|(% colspan="1" %)(% colspan="1" %)
251 -(((
252 -The folder where additional files are saved before the command is run. These files can be linked into the simulation code, e.g., for JSON handling.
253 -)))
254 -|(% colspan="1" %)(% colspan="1" %)
255 -(((
256 -timeout
257 -)))|(% colspan="1" %)(% colspan="1" %)
258 -(((
259 -int
260 -)))|(% colspan="1" %)(% colspan="1" %)
261 -(((
262 -10
263 -)))|(% colspan="1" %)(% colspan="1" %)
264 -(((
265 -Time in seconds that is waited for the executed command to finish. If the command runs longer, it is assumed to be failed and aborted.
266 -)))
267 -|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
268 -(((
269 -**Template Processor**
270 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
271 -(((
272 -\\
273 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
274 -(((
275 -\\
276 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
277 -(((
278 -\\
279 -)))
280 -|(% colspan="1" %)(% colspan="1" %)
281 -(((
282 -file
283 -)))|(% colspan="1" %)(% colspan="1" %)
284 -(((
285 -String, Project relative file path
286 -)))|(% colspan="1" %)(% colspan="1" %)
287 -(((
288 --
289 -)))|(% colspan="1" %)(% colspan="1" %)
290 -(((
291 -The template file that should be processed
292 -)))
293 -|(% colspan="1" %)(% colspan="1" %)
294 -(((
295 -target
296 -)))|(% colspan="1" %)(% colspan="1" %)
297 -(((
298 -String, Project relative file path
299 -)))|(% colspan="1" %)(% colspan="1" %)
300 -(((
301 --
302 -)))|(% colspan="1" %)(% colspan="1" %)
303 -(((
304 -The file in which the output should be saved
305 -)))
306 -|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
307 -(((
308 -**Wrapper Code Template Processor**
309 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
310 -(((
311 -\\
312 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
313 -(((
314 -\\
315 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
316 -(((
317 -\\
318 -)))
319 -|(% colspan="1" %)(% colspan="1" %)
320 -(((
321 -modelFile
322 -)))|(% colspan="1" %)(% colspan="1" %)
323 -(((
324 -String, Project relative file path
325 -)))|(% colspan="1" %)(% colspan="1" %)
326 -(((
327 --
328 -)))|(% colspan="1" %)(% colspan="1" %)
329 -(((
330 -The model file that is searched for annotations to determine the code snippets to be injected.
331 -)))
332 -|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
333 -(((
334 -**Simulation Code Template Processor**
335 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
336 -(((
337 -\\
338 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
339 -(((
340 -\\
341 -)))|(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)(% class="highlight-blue" colspan="1" data-highlight-colour="blue" %)
342 -(((
343 -\\
344 -)))
345 -|(% colspan="1" %)(% colspan="1" %)
346 -(((
347 -modelFile
348 -)))|(% colspan="1" %)(% colspan="1" %)
349 -(((
350 -String, Project relative file path
351 -)))|(% colspan="1" %)(% colspan="1" %)
352 -(((
353 --
354 -)))|(% colspan="1" %)(% colspan="1" %)
355 -(((
356 -The model file that is searched for annotations to determine the code snippets to be injected
357 -)))
358 -|(% colspan="1" %)(% colspan="1" %)
359 -(((
360 -compiledModelFile
361 -)))|(% colspan="1" %)(% colspan="1" %)
362 -(((
363 -String, Absolute file system path
364 -)))|(% colspan="1" %)(% colspan="1" %)
365 -(((
366 --
367 -)))|(% colspan="1" %)(% colspan="1" %)
368 -(((
369 -The absolute path of the compiled model file for which the simulation is created. This is used to replace the placeholder ${compiled_model_loc} in the simulation code template
370 -)))
371 -|(% colspan="1" %)(% colspan="1" %)
372 -(((
373 -variables
374 -)))|(% colspan="1" %)(% colspan="1" %)
375 -(((
376 -Map, e.g.,
377 -variables: {
378 - input: a,b,c
379 - output: x,y,z
380 - other: g1,g2,g3
381 -}
382 -)))|(% colspan="1" %)(% colspan="1" %)
383 -(((
384 --
385 -)))|(% colspan="1" %)(% colspan="1" %)
386 -(((
387 -Optional additional variables that should be communicated to the outside
388 -)))
389 -|(% colspan="1" %)(% colspan="1" %)
390 -(((
391 -interfaceTypes
392 -)))|(% colspan="1" %)(% colspan="1" %)
393 -(((
394 -String, List of Strings
395 -)))|(% colspan="1" %)(% colspan="1" %)
396 -(((
397 --
398 -)))|(% colspan="1" %)(% colspan="1" %)
399 -(((
400 -The interface types that should be communicated in the simulation, e.g., input, output, internal
401 -)))
402 -
403 -\\
404 -
405 -Example for KiBuild files:
406 -
407 407  {{code title="Simple KiBuild Example" linenumbers="true"}}
408 408  // Compile models to C code
409 409  model compiler kico {
... ... @@ -462,18 +462,6 @@
462 462   target: kieler-gen/Main.c
463 463   modelFile: MyModel.sctx
464 464  }
465 -
466 -// Process a template to generate a simulation for a model that has been compiled with some other framework
467 -process simulation template {
468 - file: assets/JavaSimulationForOtherModel.ftl
469 - target: kieler-gen/Sim_OtherModel.java
470 - variables: { // These variables should be communicated to the outside
471 - input: a,b,c
472 - output: x,y,z
473 - internal: foo, bar
474 - }
475 - interfaceTypes: input, output // Only communicate these interface types. In this case, internal variables are not communicated.
476 -}
477 477  {{/code}}
478 478  
479 479  \\
Confluence.Code.ConfluencePageClass[0]
Id
... ... @@ -1,1 +1,1 @@
1 -31162491
1 +31162488
URL
... ... @@ -1,1 +1,1 @@
1 -https://rtsys.informatik.uni-kiel.de/confluence//wiki/spaces/KIELER/pages/31162491/V2 Project Management
1 +https://rtsys.informatik.uni-kiel.de/confluence//wiki/spaces/KIELER/pages/31162488/V2 Project Management