Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: 47e7cc00eb37c5003455281e24654f7816f7d750 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Create a new model from scratch</title>
<link href="book.css" rel="stylesheet" type="text/css">
<meta content="DocBook XSL Stylesheets V1.75.1" name="generator">
<link rel="home" href="index.html" title="eTrice User Guide">
<link rel="up" href="TutorialBlinkyJava.html" title="Tutorial Blinky (Java)">
<link rel="prev" href="TutorialBlinkyJava.html" title="Tutorial Blinky (Java)">
<link rel="next" href="Addtwoadditionalactorclasses.html" title="Add two additional actor classes">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<h1 xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0">Create a new model from scratch</h1>
<div class="section" title="Create a new model from scratch">
<div class="titlepage">
<div>
<div>
<h2 class="title" style="clear: both">
<a name="Createanewmodelfromscratch2"></a>Create a new model from scratch</h2>
</div>
</div>
</div>
<p>Remember the exercise 
				<span class="emphasis"><em>HelloWorld</em></span>.
				Create a new eTrice project and name it 
				<span class="emphasis"><em>Blinky</em></span>
			
</p>
<p>To use the GUI please copy the package 
				<span class="emphasis"><em>org.eclipse.etrice.tutorials.PedLightGUI</em></span> from 
				<span class="emphasis"><em>org.eclipse.etrice.tutorials/src</em></span> to your 
				<span class="bold"><strong>src</strong></span> directory 
				<span class="emphasis"><em>Blinky/src</em></span>. For this tutorial you must remove the error markers by editing the file 
				<span class="emphasis"><em>PedestrianLightWndNoTcp.java</em></span>. Appropriate comments are provided to remove the error markers for this turorial.
			</p>
<p>Open the 
				<span class="emphasis"><em>Blinky.room</em></span> file and copy the following code into the file or use content assist to create the model.
			</p>
<div class="literallayout">
<p>
<code class="code">RoomModel&nbsp;Blinky&nbsp;{<br>

<br>
&nbsp;&nbsp;&nbsp;&nbsp;LogicalSystem&nbsp;System_Blinky&nbsp;{<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;SubSystemRef&nbsp;subsystem&nbsp;:&nbsp;SubSystem_Blinky<br>
&nbsp;&nbsp;&nbsp;&nbsp;}<br>

<br>
&nbsp;&nbsp;&nbsp;&nbsp;SubSystemClass&nbsp;SubSystem_Blinky&nbsp;{<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ActorRef&nbsp;application&nbsp;:&nbsp;BlinkyTop<br>
&nbsp;&nbsp;&nbsp;&nbsp;}<br>

<br>
&nbsp;&nbsp;&nbsp;&nbsp;ActorClass&nbsp;BlinkyTop&nbsp;{<br>
&nbsp;&nbsp;&nbsp;&nbsp;}<br>
}<br>

</code>
</p>
</div>
<div class="blockquote">
<blockquote class="blockquote">
<p></p>
</blockquote>
</div>
</div>
</body>
</html>

Back to the top