-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstallation.html
336 lines (334 loc) · 12.5 KB
/
installation.html
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" lang xml:lang>
<head>
<meta charset="utf-8" />
<meta name="generator" content="pandoc" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
<title>installation</title>
<style>
html {
font-family: Segoe UI;
color: #1a1a1a;
background-color: #fdfdfd;
}
body {
margin: 0 auto;
max-width: 36em;
padding-left: 50px;
padding-right: 50px;
padding-top: 50px;
padding-bottom: 50px;
hyphens: auto;
overflow-wrap: break-word;
text-rendering: optimizeLegibility;
font-kerning: normal;
}
@media (max-width: 600px) {
body {
font-size: 0.9em;
padding: 12px;
}
h1 {
font-size: 1.8em;
}
}
@media print {
html {
background-color: white;
}
body {
background-color: transparent;
color: black;
font-size: 12pt;
}
p, h2, h3 {
orphans: 3;
widows: 3;
}
h2, h3, h4 {
page-break-after: avoid;
}
}
p {
margin: 1em 0;
}
a {
color: #1a1a1a;
}
a:visited {
color: #1a1a1a;
}
img {
max-width: 100%;
}
h1, h2, h3, h4, h5, h6 {
margin-top: 1.4em;
}
h5, h6 {
font-size: 1em;
font-style: italic;
}
h6 {
font-weight: normal;
}
ol, ul {
padding-left: 1.7em;
margin-top: 1em;
}
li > ol, li > ul {
margin-top: 0;
}
blockquote {
margin: 1em 0 1em 1.7em;
padding-left: 1em;
border-left: 2px solid #e6e6e6;
color: #606060;
}
code {
font-family: Menlo, Monaco, Consolas, 'Lucida Console', monospace;
font-size: 85%;
margin: 0;
hyphens: manual;
}
pre {
margin: 1em 0;
overflow: auto;
}
pre code {
padding: 0;
overflow: visible;
overflow-wrap: normal;
}
.sourceCode {
background-color: transparent;
overflow: visible;
}
hr {
background-color: #1a1a1a;
border: none;
height: 1px;
margin: 1em 0;
}
table {
margin: 1em 0;
border-collapse: collapse;
width: 100%;
overflow-x: auto;
display: block;
font-variant-numeric: lining-nums tabular-nums;
}
table caption {
margin-bottom: 0.75em;
}
tbody {
margin-top: 0.5em;
border-top: 1px solid #1a1a1a;
border-bottom: 1px solid #1a1a1a;
}
th {
border-top: 1px solid #1a1a1a;
padding: 0.25em 0.5em 0.25em 0.5em;
}
td {
padding: 0.125em 0.5em 0.25em 0.5em;
}
header {
margin-bottom: 4em;
text-align: center;
}
#TOC li {
list-style: none;
}
#TOC ul {
padding-left: 1.3em;
}
#TOC > ul {
padding-left: 0;
}
#TOC a:not(:hover) {
text-decoration: none;
}
code{white-space: pre-wrap;}
span.smallcaps{font-variant: small-caps;}
div.columns{display: flex; gap: min(4vw, 1.5em);}
div.column{flex: auto; overflow-x: auto;}
div.hanging-indent{margin-left: 1.5em; text-indent: -1.5em;}
ul.task-list[class]{list-style: none;}
ul.task-list li input[type="checkbox"] {
font-size: inherit;
width: 0.8em;
margin: 0 0.8em 0.2em -1.6em;
vertical-align: middle;
}
.display.math{display: block; text-align: center; margin: 0.5rem auto;}
</style>
<!--[if lt IE 9]>
<script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv-printshiv.min.js"></script>
<![endif]-->
</head>
<body>
<nav id="TOC" role="doc-toc">
<ul>
<li><a href="#overview" id="toc-overview"><span class="toc-section-number">1</span> Overview</a></li>
<li><a href="#java" id="toc-java"><span class="toc-section-number">2</span> Java</a></li>
<li><a href="#code-generator" id="toc-code-generator"><span class="toc-section-number">3</span> Code generator</a></li>
<li><a href="#excelexporter" id="toc-excelexporter"><span class="toc-section-number">4</span> excelExporter</a></li>
<li><a href="#arduino-sample-integrations" id="toc-arduino-sample-integrations"><span class="toc-section-number">5</span> Arduino sample integrations</a></li>
<li><a href="#windows-sample-integrations" id="toc-windows-sample-integrations"><span class="toc-section-number">6</span> Windows sample integrations</a></li>
</ul>
</nav>
<!-- Installation -->
<h1 data-number="1" id="overview"><span class="header-section-number">1</span> Overview</h1>
<p>comFramework is distributed as a ZIP archive. The initial
installation step is unzipping the contents to a directory of your
choice. The directory should grant read and write access to all
users.</p>
<p>The downloaded comFramework archive contains:</p>
<ul>
<li>The source files of the CAN interface engine for integration in
target projects.</li>
<li>A couple of sample integrations of the CAN interface.</li>
<li>The Java applications, that implement the two code generators, which
support the interface design.</li>
<li>Many code generators samples, that demonstrate how to write useful
code generation templates.</li>
</ul>
<p>The source files of the CAN interface don't need any installation.
(With the trivial exception of a text editor to open and read them.)</p>
<p>The DBC code generator is always needed. Its installation means to
provide a Java runtime environment 8 (aka 1.8) or higher, to set two
environment variables and optionally to extend the system's search
path.</p>
<p>excelExporter, the auxiliary code generator, is not essential but
useful. excelExporter uses the same Java runtime environment as the DBC
code generator. The additional installation effort is no more than
setting an environment variable and optionally to extend the system's
search path.</p>
<p>Having this done, productive work with comFramework can already begin
– the rest is optional: A Java JDK and C (cross) compilers are (only)
needed to build the comFramework tools from the Java source code or to
build the sample integrations for deeper investigation.</p>
<p>The sample integrations come along with the generated C source code.
They are mainly meant as instructive sample code. An installation of
tools is not required if this suffices, if there's no need or intention
to alter the sample code and re-compile it:</p>
<p>The Arduino sample integrations comes along with source code and the
compiled executable; you can immediately upload it to your Arduino Mega
2560 board and see how it behaves. An installation of Arduino 1.8.19 is
required for this.</p>
<p>If the Windows sample integrations should be needed as running
applications for further investigation or debugging then GCC needs to be
installed. 32 and 64 Bit versions are supported but only a few versions
of GCC have been tested; see <a href="https://petervranken.github.io/comFramework/canInterface/sampleIntegrations/winTestMT/whichCCompilerToUse.html">whichCCompilerToUse.html</a>
for details. The same file can be found locally as
<em>comFramework/canInterface/sampleIntegrations/winTestMT/whichCCompilerToUse.html</em>.</p>
<p>All C compilation and related operations is controlled from
makefiles, which need the MinGW port of GNU make 3.82 or higher. If you
type "make --version" in a shell window this revision of make needs to
respond. Other make derivatives or elder revisions of GNU make won't
probably work.</p>
<h1 data-number="2" id="java"><span class="header-section-number">2</span> Java</h1>
<p>A Java SDK or RTE is not element of this repository but required for
build or execution, respectively.</p>
<p>Java binaries are not element of this repository. For running the
installed tools, a Java 8 RTE suffices (and should be found on nearly
any machine).</p>
<p>If you don't have suitable Java binaries on your machine or if you
want to build the tools from source code then a Java SDK of version 23
or higher is recommended. The installation of an according Java system
can be downloaded here <a href="https://jdk.java.net/23/">https://jdk.java.net/23/</a> (visited
November 2024).</p>
<p>After installing the Java package, you need to make the executables
accessible. Either:</p>
<ul>
<li>Extend the Windows search path. Add the path to the folder
containing java.exe to environment variable PATH.</li>
<li>Create a new environment variable COMFRAMEWORK_JAVA_HOME and assign
the Java JRE installation path. The right path is the one, which
contains bin\java.exe.</li>
</ul>
<p>Either of the two may be done globally and persistently or locally in
the startup scripting of your project, which makes use of
comFramework.</p>
<h1 data-number="3" id="code-generator"><span class="header-section-number">3</span> Code generator</h1>
<p>The installation of the main code generator is described in detail in
file <a href="https://petervranken.github.io/comFramework/codeGenerator/doc/installation.html">installation.html</a>;
the file can be found locally as
<em>comFramework/codeGenerator/doc/installation.html</em>.</p>
<p>For more details on running the code generator, see the readMe.md
files in the root directory of the examples that come with the code
generator.</p>
<h1 data-number="4" id="excelexporter"><span class="header-section-number">4</span> excelExporter</h1>
<p>The installation of the auxiliary code generator excelExporter is
described in detail in file <a href="https://petervranken.github.io/comFramework/excelExporter/doc/installation.html">installation.html</a>;
the file can be found locally as
<em>comFramework/excelExporter/doc/installation.html</em>.</p>
<p>For more details on running the code generator, see the readMe.md
files in the root directory of the examples that come with
excelExporter.</p>
<h1 data-number="5" id="arduino-sample-integrations"><span class="header-section-number">5</span> Arduino sample integrations</h1>
<p>Arduino 1.8.19 needs to be installed for compilation of the Arduino
samples and even for upload of the pre-compiled binaries. (The GCC avr
tools are taken from the Arduino installation.) Please refer to <a href="http://www.arduino.cc/">http://www.arduino.cc/</a> (visited
November 2024).</p>
<p>Caution: Do not install the elder revision Arduino 1.6.5: This
package did not contain all required GCC avr tools.</p>
<p>A new environment variable needs to be set. Let ARDUINO_HOME point to
the root directory of the Arduino installation. All tools are located
via this variable.</p>
<p>An installation of MinGW make is required. Modify the system path
variable such that GNU MinGW make 3.82 is found when typing "make".</p>
<p>In a shell window type:</p>
<pre><code>make --version</code></pre>
<p>The MinGW port of GNU make 3.82 should respond. Now CD to one of the
root directories
<em>comFramework/canInterface/sampleIntegrations/arduinoSampleIntegration</em>
or
<em>comFramework/canInterface/sampleIntegrations/arduinoSampleIntegrationEmbeddedCoder</em>
of the Arduino samples and type:</p>
<pre><code>make help
make -s clean
make -s build</code></pre>
<p>to rebuild the sample (which includes the generation of the network
database dependent C code of the CAN interface).</p>
<p>Please refer to file <em>readMe.md</em> in the root of the Arduino
samples for further details.</p>
<h1 data-number="6" id="windows-sample-integrations"><span class="header-section-number">6</span> Windows sample integrations</h1>
<p>GNU make 3.82 needs to be installed. Under Windows, only use MinGW
distributions. The Cygwin distributions will probably need some
modifications of the makefiles.</p>
<p>The GNU C compiler GCC (32 or 64 Bit, e.g.,
mingw-i686-8.1.0-release-win32-dwarf-rt_v6-rev0 or
mingw-w64-x86_64-8.1.0-posix-seh-rt_v6-rev0) needs to be installed.</p>
<p>Compilation of the Windows samples has been done under Windows 7 and
10. The code is free of specific operating system calls and only uses
functions from the GCC libraries. As these are widely operating system
independent the sample should compile and run under other Windows
versions, Linux and Mac OS as well; this has however never been tested
and as a matter of experience most often there are some minor
incompatibilities, which have to be sorted out first – just give it a
try.</p>
<p>Using another compiler than GCC will mean code changes in the
application interface, command line evaluation in the first place.</p>
<p>On principle, the makefiles are prepared to support the compilation
under Linux and Mac OS as well. If problems appear you should first have
a look into sub-makefile <em>locateTools.mk</em>, which is responsible
to find the paths to the executables. There are different configuration
possibilities to find the tools either via system search path or via
environment variable settings. Maybe you need to alter this
configuration first. The same holds if you have different GCC revisions
installed and want to switch between them.</p>
<p>If MinGW GNU make 3.82 and GCC are installed then you can CD to the
root directory
<em>comFramework/canInterface/sampleIntegrations/winSampleIntegration</em>
or <em>comFramework/canInterface/sampleIntegrations/winTestMT</em> of
the Windows sample integrations and type:</p>
<pre><code>make help
make -s clean
make -s build</code></pre>
<p>to rebuild the samples (which includes the generation of the network
database dependent C code of the CAN interface).</p>
<p>Please refer to files <em>readMe.md</em> in the root of the Windows
samples for further details.</p>
</body>
</html>