Project

General

Profile

Task #3199 » gcov.src_fsw_spacewire.c.html

Veronique bouzid, 14/11/2018 11:51 AM

 
1

    
2
<html>
3

    
4
<head>
5
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
6
  <title>Head</title>
7
  <style media="screen" type="text/css">
8

    
9
    body
10
    {
11
      color: #000000;
12
      background-color: #FFFFFF;
13
    }
14

    
15
    /* Link formats: use maroon w/underlines */
16
    a:link
17
    {
18
      color: navy;
19
      text-decoration: underline;
20
    }
21
    a:visited
22
    {
23
      color: maroon;
24
      text-decoration: underline;
25
    }
26
    a:active
27
    {
28
      color: navy;
29
      text-decoration: underline;
30
    }
31

    
32
    /*** TD formats ***/
33
    td
34
    {
35
      font-family: sans-serif;
36
    }
37
    td.title
38
    {
39
      text-align: center;
40
      padding-bottom: 10px;
41
      font-size: 20pt;
42
      font-weight: bold;
43
    }
44

    
45
    /* TD Header Information */
46
    td.headerName
47
    {
48
      text-align: right;
49
      color: black;
50
      padding-right: 6px;
51
      font-weight: bold;
52
      vertical-align: top;
53
      white-space: nowrap;
54
    }
55
    td.headerValue
56
    {
57
      text-align: left;
58
      color: blue;
59
      font-weight: bold;
60
      white-space: nowrap;
61
    }
62
    td.headerTableEntry
63
    {
64
      text-align: right;
65
      color: black;
66
      font-weight: bold;
67
      white-space: nowrap;
68
      padding-left: 12px;
69
      padding-right: 4px;
70
      background-color: LightBlue;
71
    }
72
    td.headerValueLeg
73
    {
74
      text-align: left;
75
      color: black;
76
      font-size: 80%;
77
      white-space: nowrap;
78
      padding-left: 10px;
79
      padding-right: 10px;
80
      padding-top: 2px;
81
    }
82

    
83
    /* Color of horizontal ruler */
84
    td.hr
85
    {
86
      background-color: navy;
87
      height:3px;
88
    }
89
    /* Footer format */
90
    td.footer
91
    {
92
      text-align: center;
93
      padding-top: 3px;
94
      font-family: sans-serif;
95
    }
96

    
97
    /* Coverage Table */
98

    
99
    td.coverTableHead
100
    {
101
      text-align: center;
102
      color: white;
103
      background-color: SteelBlue;
104
      font-family: sans-serif;
105
      font-size: 120%;
106
      white-space: nowrap;
107
      padding-left: 4px;
108
      padding-right: 4px;
109
    }
110
    td.coverFile
111
    {
112
      text-align: left;
113
      padding-left: 10px;
114
      padding-right: 20px;
115
      color: black;
116
      background-color: LightBlue;
117
      font-family: monospace;
118
      font-weight: bold;
119
      font-size: 110%;
120
    }
121
    td.coverBar
122
    {
123
      padding-left: 10px;
124
      padding-right: 10px;
125
      background-color: LightBlue;
126
    }
127
    td.coverBarOutline
128
    {
129
      background-color: white;
130
    }
131
    td.coverValue
132
    {
133
      padding-top: 2px;
134
      text-align: right;
135
      padding-left: 10px;
136
      padding-right: 10px;
137
      font-family: sans-serif;
138
      white-space: nowrap;
139
      font-weight: bold;
140
    }
141

    
142
    /* Link Details */
143
    a.detail:link
144
    {
145
      color: #B8D0FF;
146
      font-size:80%;
147
    }
148
    a.detail:visited
149
    {
150
      color: #B8D0FF;
151
      font-size:80%;
152
    }
153
    a.detail:active
154
    {
155
      color: #FFFFFF;
156
      font-size:80%;
157
    }
158

    
159
    .graphcont{
160
        color:#000;
161
        font-weight:700;
162
        float:left
163
    }
164

    
165
    .graph{
166
        float:left;
167
        background-color: white;
168
        position:relative;
169
        width:280px;
170
        padding:0
171
    }
172

    
173
    .graph .bar{
174
        display:block;
175
        position:relative;
176
        border:black 1px solid;
177
        text-align:center;
178
        color:#fff;
179
        height:10px;
180
        font-family:Arial,Helvetica,sans-serif;
181
        font-size:12px;
182
        line-height:1.9em
183
    }
184

    
185
    .graph .bar span{
186
        position:absolute;
187
        left:1em
188
    }
189

    
190
    td.coveredLine,
191
    span.coveredLine
192
    {
193
        background-color: LightGreen!important;
194
    }
195

    
196
    td.uncoveredLine,
197
    span.uncoveredLine
198
    {
199
        background-color: LightPink!important;
200
    }
201

    
202
    .linebranch, .linecount
203
    {
204
        border-right: 1px gray solid;
205
        background-color: lightgray;
206
    }
207

    
208
    span.takenBranch
209
    {
210
        color: Green!important;
211
        cursor: help;
212
    }
213

    
214
    span.notTakenBranch
215
    {
216
        color: Red!important;
217
        cursor: help;
218
    }
219

    
220
    .src
221
    {
222
        padding-left: 12px;
223
    }
224

    
225
    .srcHeader,
226
    span.takenBranch,
227
    span.notTakenBranch
228
    {
229
        font-family: monospace;
230
        font-weight: bold;
231
    }
232

    
233
    pre
234
    {
235
        height : 15px;
236
        margin-top: 0;
237
        margin-bottom: 0;
238
    }
239

    
240
    .lineno
241
    {
242
        background-color: #EFE383;
243
        border-right: 1px solid #BBB15F;
244
    }
245

    
246
  </style>
247
</head>
248

    
249
<body>
250

    
251
  <table width="100%" border="0" cellspacing="0" cellpadding="0">
252
    <tr><td class="title">GCC Code Coverage Report</td></tr>
253
    <tr><td class="hr"></td></tr>
254

    
255
    <tr>
256
      <td width="100%">
257
        <table cellpadding="1" border="0" width="100%">
258
          <tr>
259
            <td width="10%" class="headerName">Directory:</td>
260
            <td width="35%" class="headerValue">./</td>
261
            <td width="5%"></td>
262
            <td width="15%"></td>
263
            <td width="10%" class="headerValue" style="text-align:right;">Exec</td>
264
            <td width="10%" class="headerValue" style="text-align:right;">Total</td>
265
            <td width="15%" class="headerValue" style="text-align:right;">Coverage</td>
266
          </tr>
267
          <tr>
268
            <td class="headerName">File:</td>
269
            <td class="headerValue">src/fsw_spacewire.c</td>
270
            <td></td>
271
            <td class="headerName">Lines:</td>
272
            <td class="headerTableEntry">624</td>
273
            <td class="headerTableEntry">655</td>
274
            <td class="headerTableEntry" style="background-color:LightGreen">95.3 %</td>
275
          </tr>
276
          <tr>
277
            <td class="headerName">Date:</td>
278
            <td class="headerValue">2018-11-13 11:16:07</td>
279
            <td></td>
280
            <td class="headerName">Branches:</td>
281
            <td class="headerTableEntry">117</td>
282
            <td class="headerTableEntry">140</td>
283
            <td class="headerTableEntry" style="background-color:#FFFF55">83.6 %</td>
284
          </tr>
285
        </table>
286
      </td>
287
    </tr>
288

    
289
    <tr><td class="hr"></td></tr>
290
  </table>
291

    
292
  <br>
293
  <table cellspacing="0" cellpadding="1">
294
    <tr>
295
      <td width="5%" align="right" class="srcHeader">Line</td>
296
      <td width="5%" align="right" class="srcHeader">Branch</td>
297
      <td width="5%" align="right" class="srcHeader">Exec</td>
298
      <td width="75%" align="left" class="srcHeader src">Source</td>
299
    </tr>
300

    
301

    
302
    <tr>
303
    <td align="right" class="lineno"><pre>1</pre></td>
304
    <td align="right" class="linebranch"></td>
305
    <td align="right" class="linecount "><pre></pre></td>
306
    <td align="left" class="src "><pre>/*------------------------------------------------------------------------------</pre></td>
307
    </tr>
308

    
309
    <tr>
310
    <td align="right" class="lineno"><pre>2</pre></td>
311
    <td align="right" class="linebranch"></td>
312
    <td align="right" class="linecount "><pre></pre></td>
313
    <td align="left" class="src "><pre>--  Solar Orbiter's Low Frequency Receiver Flight Software (LFR FSW),</pre></td>
314
    </tr>
315

    
316
    <tr>
317
    <td align="right" class="lineno"><pre>3</pre></td>
318
    <td align="right" class="linebranch"></td>
319
    <td align="right" class="linecount "><pre></pre></td>
320
    <td align="left" class="src "><pre>--  This file is a part of the LFR FSW</pre></td>
321
    </tr>
322

    
323
    <tr>
324
    <td align="right" class="lineno"><pre>4</pre></td>
325
    <td align="right" class="linebranch"></td>
326
    <td align="right" class="linecount "><pre></pre></td>
327
    <td align="left" class="src "><pre>--  Copyright (C) 2012-2018, Plasma Physics Laboratory - CNRS</pre></td>
328
    </tr>
329

    
330
    <tr>
331
    <td align="right" class="lineno"><pre>5</pre></td>
332
    <td align="right" class="linebranch"></td>
333
    <td align="right" class="linecount "><pre></pre></td>
334
    <td align="left" class="src "><pre>--</pre></td>
335
    </tr>
336

    
337
    <tr>
338
    <td align="right" class="lineno"><pre>6</pre></td>
339
    <td align="right" class="linebranch"></td>
340
    <td align="right" class="linecount "><pre></pre></td>
341
    <td align="left" class="src "><pre>--  This program is free software; you can redistribute it and/or modify</pre></td>
342
    </tr>
343

    
344
    <tr>
345
    <td align="right" class="lineno"><pre>7</pre></td>
346
    <td align="right" class="linebranch"></td>
347
    <td align="right" class="linecount "><pre></pre></td>
348
    <td align="left" class="src "><pre>--  it under the terms of the GNU General Public License as published by</pre></td>
349
    </tr>
350

    
351
    <tr>
352
    <td align="right" class="lineno"><pre>8</pre></td>
353
    <td align="right" class="linebranch"></td>
354
    <td align="right" class="linecount "><pre></pre></td>
355
    <td align="left" class="src "><pre>--  the Free Software Foundation; either version 2 of the License, or</pre></td>
356
    </tr>
357

    
358
    <tr>
359
    <td align="right" class="lineno"><pre>9</pre></td>
360
    <td align="right" class="linebranch"></td>
361
    <td align="right" class="linecount "><pre></pre></td>
362
    <td align="left" class="src "><pre>--  (at your option) any later version.</pre></td>
363
    </tr>
364

    
365
    <tr>
366
    <td align="right" class="lineno"><pre>10</pre></td>
367
    <td align="right" class="linebranch"></td>
368
    <td align="right" class="linecount "><pre></pre></td>
369
    <td align="left" class="src "><pre>--</pre></td>
370
    </tr>
371

    
372
    <tr>
373
    <td align="right" class="lineno"><pre>11</pre></td>
374
    <td align="right" class="linebranch"></td>
375
    <td align="right" class="linecount "><pre></pre></td>
376
    <td align="left" class="src "><pre>--  This program is distributed in the hope that it will be useful,</pre></td>
377
    </tr>
378

    
379
    <tr>
380
    <td align="right" class="lineno"><pre>12</pre></td>
381
    <td align="right" class="linebranch"></td>
382
    <td align="right" class="linecount "><pre></pre></td>
383
    <td align="left" class="src "><pre>--  but WITHOUT ANY WARRANTY; without even the implied warranty of</pre></td>
384
    </tr>
385

    
386
    <tr>
387
    <td align="right" class="lineno"><pre>13</pre></td>
388
    <td align="right" class="linebranch"></td>
389
    <td align="right" class="linecount "><pre></pre></td>
390
    <td align="left" class="src "><pre>--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</pre></td>
391
    </tr>
392

    
393
    <tr>
394
    <td align="right" class="lineno"><pre>14</pre></td>
395
    <td align="right" class="linebranch"></td>
396
    <td align="right" class="linecount "><pre></pre></td>
397
    <td align="left" class="src "><pre>--  GNU General Public License for more details.</pre></td>
398
    </tr>
399

    
400
    <tr>
401
    <td align="right" class="lineno"><pre>15</pre></td>
402
    <td align="right" class="linebranch"></td>
403
    <td align="right" class="linecount "><pre></pre></td>
404
    <td align="left" class="src "><pre>--</pre></td>
405
    </tr>
406

    
407
    <tr>
408
    <td align="right" class="lineno"><pre>16</pre></td>
409
    <td align="right" class="linebranch"></td>
410
    <td align="right" class="linecount "><pre></pre></td>
411
    <td align="left" class="src "><pre>--  You should have received a copy of the GNU General Public License</pre></td>
412
    </tr>
413

    
414
    <tr>
415
    <td align="right" class="lineno"><pre>17</pre></td>
416
    <td align="right" class="linebranch"></td>
417
    <td align="right" class="linecount "><pre></pre></td>
418
    <td align="left" class="src "><pre>--  along with this program; if not, write to the Free Software</pre></td>
419
    </tr>
420

    
421
    <tr>
422
    <td align="right" class="lineno"><pre>18</pre></td>
423
    <td align="right" class="linebranch"></td>
424
    <td align="right" class="linecount "><pre></pre></td>
425
    <td align="left" class="src "><pre>--  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA</pre></td>
426
    </tr>
427

    
428
    <tr>
429
    <td align="right" class="lineno"><pre>19</pre></td>
430
    <td align="right" class="linebranch"></td>
431
    <td align="right" class="linecount "><pre></pre></td>
432
    <td align="left" class="src "><pre>-------------------------------------------------------------------------------*/</pre></td>
433
    </tr>
434

    
435
    <tr>
436
    <td align="right" class="lineno"><pre>20</pre></td>
437
    <td align="right" class="linebranch"></td>
438
    <td align="right" class="linecount "><pre></pre></td>
439
    <td align="left" class="src "><pre>/*--                  Author : Paul Leroy</pre></td>
440
    </tr>
441

    
442
    <tr>
443
    <td align="right" class="lineno"><pre>21</pre></td>
444
    <td align="right" class="linebranch"></td>
445
    <td align="right" class="linecount "><pre></pre></td>
446
    <td align="left" class="src "><pre>--                   Contact : Alexis Jeandet</pre></td>
447
    </tr>
448

    
449
    <tr>
450
    <td align="right" class="lineno"><pre>22</pre></td>
451
    <td align="right" class="linebranch"></td>
452
    <td align="right" class="linecount "><pre></pre></td>
453
    <td align="left" class="src "><pre>--                      Mail : alexis.jeandet@lpp.polytechnique.fr</pre></td>
454
    </tr>
455

    
456
    <tr>
457
    <td align="right" class="lineno"><pre>23</pre></td>
458
    <td align="right" class="linebranch"></td>
459
    <td align="right" class="linecount "><pre></pre></td>
460
    <td align="left" class="src "><pre>----------------------------------------------------------------------------*/</pre></td>
461
    </tr>
462

    
463
    <tr>
464
    <td align="right" class="lineno"><pre>24</pre></td>
465
    <td align="right" class="linebranch"></td>
466
    <td align="right" class="linecount "><pre></pre></td>
467
    <td align="left" class="src "><pre></pre></td>
468
    </tr>
469

    
470
    <tr>
471
    <td align="right" class="lineno"><pre>25</pre></td>
472
    <td align="right" class="linebranch"></td>
473
    <td align="right" class="linecount "><pre></pre></td>
474
    <td align="left" class="src "><pre>/** Functions related to the SpaceWire interface.</pre></td>
475
    </tr>
476

    
477
    <tr>
478
    <td align="right" class="lineno"><pre>26</pre></td>
479
    <td align="right" class="linebranch"></td>
480
    <td align="right" class="linecount "><pre></pre></td>
481
    <td align="left" class="src "><pre> *</pre></td>
482
    </tr>
483

    
484
    <tr>
485
    <td align="right" class="lineno"><pre>27</pre></td>
486
    <td align="right" class="linebranch"></td>
487
    <td align="right" class="linecount "><pre></pre></td>
488
    <td align="left" class="src "><pre> * @file</pre></td>
489
    </tr>
490

    
491
    <tr>
492
    <td align="right" class="lineno"><pre>28</pre></td>
493
    <td align="right" class="linebranch"></td>
494
    <td align="right" class="linecount "><pre></pre></td>
495
    <td align="left" class="src "><pre> * @author P. LEROY</pre></td>
496
    </tr>
497

    
498
    <tr>
499
    <td align="right" class="lineno"><pre>29</pre></td>
500
    <td align="right" class="linebranch"></td>
501
    <td align="right" class="linecount "><pre></pre></td>
502
    <td align="left" class="src "><pre> *</pre></td>
503
    </tr>
504

    
505
    <tr>
506
    <td align="right" class="lineno"><pre>30</pre></td>
507
    <td align="right" class="linebranch"></td>
508
    <td align="right" class="linecount "><pre></pre></td>
509
    <td align="left" class="src "><pre> * A group of functions to handle SpaceWire transmissions:</pre></td>
510
    </tr>
511

    
512
    <tr>
513
    <td align="right" class="lineno"><pre>31</pre></td>
514
    <td align="right" class="linebranch"></td>
515
    <td align="right" class="linecount "><pre></pre></td>
516
    <td align="left" class="src "><pre> * - configuration of the SpaceWire link</pre></td>
517
    </tr>
518

    
519
    <tr>
520
    <td align="right" class="lineno"><pre>32</pre></td>
521
    <td align="right" class="linebranch"></td>
522
    <td align="right" class="linecount "><pre></pre></td>
523
    <td align="left" class="src "><pre> * - SpaceWire related interruption requests processing</pre></td>
524
    </tr>
525

    
526
    <tr>
527
    <td align="right" class="lineno"><pre>33</pre></td>
528
    <td align="right" class="linebranch"></td>
529
    <td align="right" class="linecount "><pre></pre></td>
530
    <td align="left" class="src "><pre> * - transmission of TeleMetry packets by a dedicated RTEMS task</pre></td>
531
    </tr>
532

    
533
    <tr>
534
    <td align="right" class="lineno"><pre>34</pre></td>
535
    <td align="right" class="linebranch"></td>
536
    <td align="right" class="linecount "><pre></pre></td>
537
    <td align="left" class="src "><pre> * - reception of TeleCommands by a dedicated RTEMS task</pre></td>
538
    </tr>
539

    
540
    <tr>
541
    <td align="right" class="lineno"><pre>35</pre></td>
542
    <td align="right" class="linebranch"></td>
543
    <td align="right" class="linecount "><pre></pre></td>
544
    <td align="left" class="src "><pre> *</pre></td>
545
    </tr>
546

    
547
    <tr>
548
    <td align="right" class="lineno"><pre>36</pre></td>
549
    <td align="right" class="linebranch"></td>
550
    <td align="right" class="linecount "><pre></pre></td>
551
    <td align="left" class="src "><pre> */</pre></td>
552
    </tr>
553

    
554
    <tr>
555
    <td align="right" class="lineno"><pre>37</pre></td>
556
    <td align="right" class="linebranch"></td>
557
    <td align="right" class="linecount "><pre></pre></td>
558
    <td align="left" class="src "><pre></pre></td>
559
    </tr>
560

    
561
    <tr>
562
    <td align="right" class="lineno"><pre>38</pre></td>
563
    <td align="right" class="linebranch"></td>
564
    <td align="right" class="linecount "><pre></pre></td>
565
    <td align="left" class="src "><pre>#include "fsw_spacewire.h"</pre></td>
566
    </tr>
567

    
568
    <tr>
569
    <td align="right" class="lineno"><pre>39</pre></td>
570
    <td align="right" class="linebranch"></td>
571
    <td align="right" class="linecount "><pre></pre></td>
572
    <td align="left" class="src "><pre></pre></td>
573
    </tr>
574

    
575
    <tr>
576
    <td align="right" class="lineno"><pre>40</pre></td>
577
    <td align="right" class="linebranch"></td>
578
    <td align="right" class="linecount "><pre></pre></td>
579
    <td align="left" class="src "><pre>rtems_name semq_name    = 0;</pre></td>
580
    </tr>
581

    
582
    <tr>
583
    <td align="right" class="lineno"><pre>41</pre></td>
584
    <td align="right" class="linebranch"></td>
585
    <td align="right" class="linecount "><pre></pre></td>
586
    <td align="left" class="src "><pre>rtems_id semq_id        = RTEMS_ID_NONE;</pre></td>
587
    </tr>
588

    
589
    <tr>
590
    <td align="right" class="lineno"><pre>42</pre></td>
591
    <td align="right" class="linebranch"></td>
592
    <td align="right" class="linecount "><pre></pre></td>
593
    <td align="left" class="src "><pre></pre></td>
594
    </tr>
595

    
596
    <tr>
597
    <td align="right" class="lineno"><pre>43</pre></td>
598
    <td align="right" class="linebranch"></td>
599
    <td align="right" class="linecount "><pre></pre></td>
600
    <td align="left" class="src "><pre>//*****************</pre></td>
601
    </tr>
602

    
603
    <tr>
604
    <td align="right" class="lineno"><pre>44</pre></td>
605
    <td align="right" class="linebranch"></td>
606
    <td align="right" class="linecount "><pre></pre></td>
607
    <td align="left" class="src "><pre>// waveform headers</pre></td>
608
    </tr>
609

    
610
    <tr>
611
    <td align="right" class="lineno"><pre>45</pre></td>
612
    <td align="right" class="linebranch"></td>
613
    <td align="right" class="linecount "><pre></pre></td>
614
    <td align="left" class="src "><pre>Header_TM_LFR_SCIENCE_CWF_t headerCWF = {0};</pre></td>
615
    </tr>
616

    
617
    <tr>
618
    <td align="right" class="lineno"><pre>46</pre></td>
619
    <td align="right" class="linebranch"></td>
620
    <td align="right" class="linecount "><pre></pre></td>
621
    <td align="left" class="src "><pre>Header_TM_LFR_SCIENCE_SWF_t headerSWF = {0};</pre></td>
622
    </tr>
623

    
624
    <tr>
625
    <td align="right" class="lineno"><pre>47</pre></td>
626
    <td align="right" class="linebranch"></td>
627
    <td align="right" class="linecount "><pre></pre></td>
628
    <td align="left" class="src "><pre>Header_TM_LFR_SCIENCE_ASM_t headerASM = {0};</pre></td>
629
    </tr>
630

    
631
    <tr>
632
    <td align="right" class="lineno"><pre>48</pre></td>
633
    <td align="right" class="linebranch"></td>
634
    <td align="right" class="linecount "><pre></pre></td>
635
    <td align="left" class="src "><pre></pre></td>
636
    </tr>
637

    
638
    <tr>
639
    <td align="right" class="lineno"><pre>49</pre></td>
640
    <td align="right" class="linebranch"></td>
641
    <td align="right" class="linecount "><pre></pre></td>
642
    <td align="left" class="src "><pre>unsigned char previousTimecodeCtr = 0;</pre></td>
643
    </tr>
644

    
645
    <tr>
646
    <td align="right" class="lineno"><pre>50</pre></td>
647
    <td align="right" class="linebranch"></td>
648
    <td align="right" class="linecount "><pre></pre></td>
649
    <td align="left" class="src "><pre>unsigned int *grspwPtr = (unsigned int *) (REGS_ADDR_GRSPW + APB_OFFSET_GRSPW_TIME_REGISTER);</pre></td>
650
    </tr>
651

    
652
    <tr>
653
    <td align="right" class="lineno"><pre>51</pre></td>
654
    <td align="right" class="linebranch"></td>
655
    <td align="right" class="linecount "><pre></pre></td>
656
    <td align="left" class="src "><pre></pre></td>
657
    </tr>
658

    
659
    <tr>
660
    <td align="right" class="lineno"><pre>52</pre></td>
661
    <td align="right" class="linebranch"></td>
662
    <td align="right" class="linecount "><pre></pre></td>
663
    <td align="left" class="src "><pre>//***********</pre></td>
664
    </tr>
665

    
666
    <tr>
667
    <td align="right" class="lineno"><pre>53</pre></td>
668
    <td align="right" class="linebranch"></td>
669
    <td align="right" class="linecount "><pre></pre></td>
670
    <td align="left" class="src "><pre>// RTEMS TASK</pre></td>
671
    </tr>
672

    
673
    <tr>
674
    <td align="right" class="lineno"><pre>54</pre></td>
675
    <td align="right" class="linebranch"></td>
676
    <td align="right" class="linecount coveredLine"><pre>92</pre></td>
677
    <td align="left" class="src coveredLine"><pre>rtems_task spiq_task(rtems_task_argument unused)</pre></td>
678
    </tr>
679

    
680
    <tr>
681
    <td align="right" class="lineno"><pre>55</pre></td>
682
    <td align="right" class="linebranch"></td>
683
    <td align="right" class="linecount "><pre></pre></td>
684
    <td align="left" class="src "><pre>{</pre></td>
685
    </tr>
686

    
687
    <tr>
688
    <td align="right" class="lineno"><pre>56</pre></td>
689
    <td align="right" class="linebranch"></td>
690
    <td align="right" class="linecount "><pre></pre></td>
691
    <td align="left" class="src "><pre>    /** This RTEMS task is awaken by an rtems_event sent by the interruption subroutine of the SpaceWire driver.</pre></td>
692
    </tr>
693

    
694
    <tr>
695
    <td align="right" class="lineno"><pre>57</pre></td>
696
    <td align="right" class="linebranch"></td>
697
    <td align="right" class="linecount "><pre></pre></td>
698
    <td align="left" class="src "><pre>     *</pre></td>
699
    </tr>
700

    
701
    <tr>
702
    <td align="right" class="lineno"><pre>58</pre></td>
703
    <td align="right" class="linebranch"></td>
704
    <td align="right" class="linecount "><pre></pre></td>
705
    <td align="left" class="src "><pre>     * @param unused is the starting argument of the RTEMS task</pre></td>
706
    </tr>
707

    
708
    <tr>
709
    <td align="right" class="lineno"><pre>59</pre></td>
710
    <td align="right" class="linebranch"></td>
711
    <td align="right" class="linecount "><pre></pre></td>
712
    <td align="left" class="src "><pre>     *</pre></td>
713
    </tr>
714

    
715
    <tr>
716
    <td align="right" class="lineno"><pre>60</pre></td>
717
    <td align="right" class="linebranch"></td>
718
    <td align="right" class="linecount "><pre></pre></td>
719
    <td align="left" class="src "><pre>     */</pre></td>
720
    </tr>
721

    
722
    <tr>
723
    <td align="right" class="lineno"><pre>61</pre></td>
724
    <td align="right" class="linebranch"></td>
725
    <td align="right" class="linecount "><pre></pre></td>
726
    <td align="left" class="src "><pre></pre></td>
727
    </tr>
728

    
729
    <tr>
730
    <td align="right" class="lineno"><pre>62</pre></td>
731
    <td align="right" class="linebranch"></td>
732
    <td align="right" class="linecount "><pre></pre></td>
733
    <td align="left" class="src "><pre>    rtems_event_set event_out;</pre></td>
734
    </tr>
735

    
736
    <tr>
737
    <td align="right" class="lineno"><pre>63</pre></td>
738
    <td align="right" class="linebranch"></td>
739
    <td align="right" class="linecount "><pre></pre></td>
740
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
741
    </tr>
742

    
743
    <tr>
744
    <td align="right" class="lineno"><pre>64</pre></td>
745
    <td align="right" class="linebranch"></td>
746
    <td align="right" class="linecount "><pre></pre></td>
747
    <td align="left" class="src "><pre>    int linkStatus;</pre></td>
748
    </tr>
749

    
750
    <tr>
751
    <td align="right" class="lineno"><pre>65</pre></td>
752
    <td align="right" class="linebranch"></td>
753
    <td align="right" class="linecount "><pre></pre></td>
754
    <td align="left" class="src "><pre></pre></td>
755
    </tr>
756

    
757
    <tr>
758
    <td align="right" class="lineno"><pre>66</pre></td>
759
    <td align="right" class="linebranch"></td>
760
    <td align="right" class="linecount coveredLine"><pre>92</pre></td>
761
    <td align="left" class="src coveredLine"><pre>    event_out = EVENT_SETS_NONE_PENDING;</pre></td>
762
    </tr>
763

    
764
    <tr>
765
    <td align="right" class="lineno"><pre>67</pre></td>
766
    <td align="right" class="linebranch"></td>
767
    <td align="right" class="linecount coveredLine"><pre>92</pre></td>
768
    <td align="left" class="src coveredLine"><pre>    linkStatus = 0;</pre></td>
769
    </tr>
770

    
771
    <tr>
772
    <td align="right" class="lineno"><pre>68</pre></td>
773
    <td align="right" class="linebranch"></td>
774
    <td align="right" class="linecount "><pre></pre></td>
775
    <td align="left" class="src "><pre></pre></td>
776
    </tr>
777

    
778
    <tr>
779
    <td align="right" class="lineno"><pre>69</pre></td>
780
    <td align="right" class="linebranch"></td>
781
    <td align="right" class="linecount "><pre></pre></td>
782
    <td align="left" class="src "><pre>    BOOT_PRINTF("in SPIQ *** \n")</pre></td>
783
    </tr>
784

    
785
    <tr>
786
    <td align="right" class="lineno"><pre>70</pre></td>
787
    <td align="right" class="linebranch"></td>
788
    <td align="right" class="linecount "><pre></pre></td>
789
    <td align="left" class="src "><pre></pre></td>
790
    </tr>
791

    
792
    <tr>
793
    <td align="right" class="lineno"><pre>71</pre></td>
794
    <td align="right" class="linebranch"></td>
795
    <td align="right" class="linecount "><pre></pre></td>
796
    <td align="left" class="src "><pre>    while(true){</pre></td>
797
    </tr>
798

    
799
    <tr>
800
    <td align="right" class="lineno"><pre>72</pre></td>
801
    <td align="right" class="linebranch"></td>
802
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
803
    <td align="left" class="src coveredLine"><pre>        rtems_event_receive(SPW_LINKERR_EVENT, RTEMS_WAIT, RTEMS_NO_TIMEOUT, &amp;event_out); // wait for an SPW_LINKERR_EVENT</pre></td>
804
    </tr>
805

    
806
    <tr>
807
    <td align="right" class="lineno"><pre>73</pre></td>
808
    <td align="right" class="linebranch"></td>
809
    <td align="right" class="linecount "><pre></pre></td>
810
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** got SPW_LINKERR_EVENT\n")</pre></td>
811
    </tr>
812

    
813
    <tr>
814
    <td align="right" class="lineno"><pre>74</pre></td>
815
    <td align="right" class="linebranch"></td>
816
    <td align="right" class="linecount "><pre></pre></td>
817
    <td align="left" class="src "><pre></pre></td>
818
    </tr>
819

    
820
    <tr>
821
    <td align="right" class="lineno"><pre>75</pre></td>
822
    <td align="right" class="linebranch"></td>
823
    <td align="right" class="linecount "><pre></pre></td>
824
    <td align="left" class="src "><pre>        // [0] SUSPEND RECV AND SEND TASKS</pre></td>
825
    </tr>
826

    
827
    <tr>
828
    <td align="right" class="lineno"><pre>76</pre></td>
829
    <td align="right" class="linebranch"></td>
830
    <td align="right" class="linecount coveredLine"><pre>7</pre></td>
831
    <td align="left" class="src coveredLine"><pre>        status = rtems_task_suspend( Task_id[ TASKID_RECV ] );</pre></td>
832
    </tr>
833

    
834
    <tr>
835
    <td align="right" class="lineno"><pre>77</pre></td>
836
    <td align="right" class="linebranch"></td>
837
    <td align="right" class="linecount "><pre></pre></td>
838
    <td align="left" class="src "><pre>        if ( status != RTEMS_SUCCESSFUL ) {</pre></td>
839
    </tr>
840

    
841
    <tr>
842
    <td align="right" class="lineno"><pre>78</pre></td>
843
    <td align="right" class="linebranch"></td>
844
    <td align="right" class="linecount "><pre></pre></td>
845
    <td align="left" class="src "><pre>            PRINTF("in SPIQ *** ERR suspending RECV Task\n")</pre></td>
846
    </tr>
847

    
848
    <tr>
849
    <td align="right" class="lineno"><pre>79</pre></td>
850
    <td align="right" class="linebranch"></td>
851
    <td align="right" class="linecount "><pre></pre></td>
852
    <td align="left" class="src "><pre>        }</pre></td>
853
    </tr>
854

    
855
    <tr>
856
    <td align="right" class="lineno"><pre>80</pre></td>
857
    <td align="right" class="linebranch"></td>
858
    <td align="right" class="linecount coveredLine"><pre>7</pre></td>
859
    <td align="left" class="src coveredLine"><pre>        status = rtems_task_suspend( Task_id[ TASKID_SEND ] );</pre></td>
860
    </tr>
861

    
862
    <tr>
863
    <td align="right" class="lineno"><pre>81</pre></td>
864
    <td align="right" class="linebranch"></td>
865
    <td align="right" class="linecount "><pre></pre></td>
866
    <td align="left" class="src "><pre>        if ( status != RTEMS_SUCCESSFUL ) {</pre></td>
867
    </tr>
868

    
869
    <tr>
870
    <td align="right" class="lineno"><pre>82</pre></td>
871
    <td align="right" class="linebranch"></td>
872
    <td align="right" class="linecount "><pre></pre></td>
873
    <td align="left" class="src "><pre>            PRINTF("in SPIQ *** ERR suspending SEND Task\n")</pre></td>
874
    </tr>
875

    
876
    <tr>
877
    <td align="right" class="lineno"><pre>83</pre></td>
878
    <td align="right" class="linebranch"></td>
879
    <td align="right" class="linecount "><pre></pre></td>
880
    <td align="left" class="src "><pre>        }</pre></td>
881
    </tr>
882

    
883
    <tr>
884
    <td align="right" class="lineno"><pre>84</pre></td>
885
    <td align="right" class="linebranch"></td>
886
    <td align="right" class="linecount "><pre></pre></td>
887
    <td align="left" class="src "><pre></pre></td>
888
    </tr>
889

    
890
    <tr>
891
    <td align="right" class="lineno"><pre>85</pre></td>
892
    <td align="right" class="linebranch"></td>
893
    <td align="right" class="linecount "><pre></pre></td>
894
    <td align="left" class="src "><pre>        // [1] CHECK THE LINK</pre></td>
895
    </tr>
896

    
897
    <tr>
898
    <td align="right" class="lineno"><pre>86</pre></td>
899
    <td align="right" class="linebranch"></td>
900
    <td align="right" class="linecount coveredLine"><pre>7</pre></td>
901
    <td align="left" class="src coveredLine"><pre>        status = ioctl(fdSPW, SPACEWIRE_IOCTRL_GET_LINK_STATUS, &amp;linkStatus);   // get the link status (1)</pre></td>
902
    </tr>
903

    
904
    <tr>
905
    <td align="right" class="lineno"><pre>87</pre></td>
906
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 5 times">&check;</span><span class="takenBranch" title="Branch 1 taken 2 times">&check;</span></td>
907
    <td align="right" class="linecount coveredLine"><pre>7</pre></td>
908
    <td align="left" class="src coveredLine"><pre>        if ( linkStatus != SPW_LINK_OK) {</pre></td>
909
    </tr>
910

    
911
    <tr>
912
    <td align="right" class="lineno"><pre>88</pre></td>
913
    <td align="right" class="linebranch"></td>
914
    <td align="right" class="linecount "><pre></pre></td>
915
    <td align="left" class="src "><pre>            PRINTF1("in SPIQ *** linkStatus %d, wait...\n", linkStatus)</pre></td>
916
    </tr>
917

    
918
    <tr>
919
    <td align="right" class="lineno"><pre>89</pre></td>
920
    <td align="right" class="linebranch"></td>
921
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
922
    <td align="left" class="src coveredLine"><pre>            status = rtems_task_wake_after( SY_LFR_DPU_CONNECT_TIMEOUT );        // wait SY_LFR_DPU_CONNECT_TIMEOUT 1000 ms</pre></td>
923
    </tr>
924

    
925
    <tr>
926
    <td align="right" class="lineno"><pre>90</pre></td>
927
    <td align="right" class="linebranch"></td>
928
    <td align="right" class="linecount "><pre></pre></td>
929
    <td align="left" class="src "><pre>        }</pre></td>
930
    </tr>
931

    
932
    <tr>
933
    <td align="right" class="lineno"><pre>91</pre></td>
934
    <td align="right" class="linebranch"></td>
935
    <td align="right" class="linecount "><pre></pre></td>
936
    <td align="left" class="src "><pre></pre></td>
937
    </tr>
938

    
939
    <tr>
940
    <td align="right" class="lineno"><pre>92</pre></td>
941
    <td align="right" class="linebranch"></td>
942
    <td align="right" class="linecount "><pre></pre></td>
943
    <td align="left" class="src "><pre>        // [2] RECHECK THE LINK AFTER SY_LFR_DPU_CONNECT_TIMEOUT</pre></td>
944
    </tr>
945

    
946
    <tr>
947
    <td align="right" class="lineno"><pre>93</pre></td>
948
    <td align="right" class="linebranch"></td>
949
    <td align="right" class="linecount coveredLine"><pre>7</pre></td>
950
    <td align="left" class="src coveredLine"><pre>        status = ioctl(fdSPW, SPACEWIRE_IOCTRL_GET_LINK_STATUS, &amp;linkStatus);   // get the link status (2)</pre></td>
951
    </tr>
952

    
953
    <tr>
954
    <td align="right" class="lineno"><pre>94</pre></td>
955
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 5 times">&check;</span><span class="takenBranch" title="Branch 1 taken 2 times">&check;</span></td>
956
    <td align="right" class="linecount coveredLine"><pre>7</pre></td>
957
    <td align="left" class="src coveredLine"><pre>        if ( linkStatus != SPW_LINK_OK )  // [2.a] not in run state, reset the link</pre></td>
958
    </tr>
959

    
960
    <tr>
961
    <td align="right" class="lineno"><pre>95</pre></td>
962
    <td align="right" class="linebranch"></td>
963
    <td align="right" class="linecount "><pre></pre></td>
964
    <td align="left" class="src "><pre>        {</pre></td>
965
    </tr>
966

    
967
    <tr>
968
    <td align="right" class="lineno"><pre>96</pre></td>
969
    <td align="right" class="linebranch"></td>
970
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
971
    <td align="left" class="src coveredLine"><pre>            spacewire_read_statistics();</pre></td>
972
    </tr>
973

    
974
    <tr>
975
    <td align="right" class="lineno"><pre>97</pre></td>
976
    <td align="right" class="linebranch"></td>
977
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
978
    <td align="left" class="src coveredLine"><pre>            status = spacewire_several_connect_attemps( );</pre></td>
979
    </tr>
980

    
981
    <tr>
982
    <td align="right" class="lineno"><pre>98</pre></td>
983
    <td align="right" class="linebranch"></td>
984
    <td align="right" class="linecount "><pre></pre></td>
985
    <td align="left" class="src "><pre>        }</pre></td>
986
    </tr>
987

    
988
    <tr>
989
    <td align="right" class="lineno"><pre>99</pre></td>
990
    <td align="right" class="linebranch"></td>
991
    <td align="right" class="linecount "><pre></pre></td>
992
    <td align="left" class="src "><pre>        else                    // [2.b] in run state, start the link</pre></td>
993
    </tr>
994

    
995
    <tr>
996
    <td align="right" class="lineno"><pre>100</pre></td>
997
    <td align="right" class="linebranch"></td>
998
    <td align="right" class="linecount "><pre></pre></td>
999
    <td align="left" class="src "><pre>        {</pre></td>
1000
    </tr>
1001

    
1002
    <tr>
1003
    <td align="right" class="lineno"><pre>101</pre></td>
1004
    <td align="right" class="linebranch"></td>
1005
    <td align="right" class="linecount coveredLine"><pre>2</pre></td>
1006
    <td align="left" class="src coveredLine"><pre>            status = spacewire_stop_and_start_link( fdSPW ); // start the link</pre></td>
1007
    </tr>
1008

    
1009
    <tr>
1010
    <td align="right" class="lineno"><pre>102</pre></td>
1011
    <td align="right" class="linebranch"></td>
1012
    <td align="right" class="linecount "><pre></pre></td>
1013
    <td align="left" class="src "><pre>            if ( status != RTEMS_SUCCESSFUL)</pre></td>
1014
    </tr>
1015

    
1016
    <tr>
1017
    <td align="right" class="lineno"><pre>103</pre></td>
1018
    <td align="right" class="linebranch"></td>
1019
    <td align="right" class="linecount "><pre></pre></td>
1020
    <td align="left" class="src "><pre>            {</pre></td>
1021
    </tr>
1022

    
1023
    <tr>
1024
    <td align="right" class="lineno"><pre>104</pre></td>
1025
    <td align="right" class="linebranch"></td>
1026
    <td align="right" class="linecount "><pre></pre></td>
1027
    <td align="left" class="src "><pre>                PRINTF1("in SPIQ *** ERR spacewire_stop_and_start_link %d\n", status)</pre></td>
1028
    </tr>
1029

    
1030
    <tr>
1031
    <td align="right" class="lineno"><pre>105</pre></td>
1032
    <td align="right" class="linebranch"></td>
1033
    <td align="right" class="linecount "><pre></pre></td>
1034
    <td align="left" class="src "><pre>            }</pre></td>
1035
    </tr>
1036

    
1037
    <tr>
1038
    <td align="right" class="lineno"><pre>106</pre></td>
1039
    <td align="right" class="linebranch"></td>
1040
    <td align="right" class="linecount "><pre></pre></td>
1041
    <td align="left" class="src "><pre>        }</pre></td>
1042
    </tr>
1043

    
1044
    <tr>
1045
    <td align="right" class="lineno"><pre>107</pre></td>
1046
    <td align="right" class="linebranch"></td>
1047
    <td align="right" class="linecount "><pre></pre></td>
1048
    <td align="left" class="src "><pre></pre></td>
1049
    </tr>
1050

    
1051
    <tr>
1052
    <td align="right" class="lineno"><pre>108</pre></td>
1053
    <td align="right" class="linebranch"></td>
1054
    <td align="right" class="linecount "><pre></pre></td>
1055
    <td align="left" class="src "><pre>        // [3] COMPLETE RECOVERY ACTION AFTER SY_LFR_DPU_CONNECT_ATTEMPTS</pre></td>
1056
    </tr>
1057

    
1058
    <tr>
1059
    <td align="right" class="lineno"><pre>109</pre></td>
1060
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 2 times">&check;</span><span class="takenBranch" title="Branch 1 taken 5 times">&check;</span></td>
1061
    <td align="right" class="linecount coveredLine"><pre>7</pre></td>
1062
    <td align="left" class="src coveredLine"><pre>        if ( status == RTEMS_SUCCESSFUL )   // [3.a] the link is in run state and has been started successfully</pre></td>
1063
    </tr>
1064

    
1065
    <tr>
1066
    <td align="right" class="lineno"><pre>110</pre></td>
1067
    <td align="right" class="linebranch"></td>
1068
    <td align="right" class="linecount "><pre></pre></td>
1069
    <td align="left" class="src "><pre>        {</pre></td>
1070
    </tr>
1071

    
1072
    <tr>
1073
    <td align="right" class="lineno"><pre>111</pre></td>
1074
    <td align="right" class="linebranch"></td>
1075
    <td align="right" class="linecount coveredLine"><pre>2</pre></td>
1076
    <td align="left" class="src coveredLine"><pre>            status = rtems_task_restart( Task_id[ TASKID_SEND ], 1 );</pre></td>
1077
    </tr>
1078

    
1079
    <tr>
1080
    <td align="right" class="lineno"><pre>112</pre></td>
1081
    <td align="right" class="linebranch"></td>
1082
    <td align="right" class="linecount "><pre></pre></td>
1083
    <td align="left" class="src "><pre>            if ( status != RTEMS_SUCCESSFUL ) {</pre></td>
1084
    </tr>
1085

    
1086
    <tr>
1087
    <td align="right" class="lineno"><pre>113</pre></td>
1088
    <td align="right" class="linebranch"></td>
1089
    <td align="right" class="linecount "><pre></pre></td>
1090
    <td align="left" class="src "><pre>                PRINTF("in SPIQ *** ERR resuming SEND Task\n")</pre></td>
1091
    </tr>
1092

    
1093
    <tr>
1094
    <td align="right" class="lineno"><pre>114</pre></td>
1095
    <td align="right" class="linebranch"></td>
1096
    <td align="right" class="linecount "><pre></pre></td>
1097
    <td align="left" class="src "><pre>            }</pre></td>
1098
    </tr>
1099

    
1100
    <tr>
1101
    <td align="right" class="lineno"><pre>115</pre></td>
1102
    <td align="right" class="linebranch"></td>
1103
    <td align="right" class="linecount coveredLine"><pre>2</pre></td>
1104
    <td align="left" class="src coveredLine"><pre>            status = rtems_task_restart( Task_id[ TASKID_RECV ], 1 );</pre></td>
1105
    </tr>
1106

    
1107
    <tr>
1108
    <td align="right" class="lineno"><pre>116</pre></td>
1109
    <td align="right" class="linebranch"></td>
1110
    <td align="right" class="linecount "><pre></pre></td>
1111
    <td align="left" class="src "><pre>            if ( status != RTEMS_SUCCESSFUL ) {</pre></td>
1112
    </tr>
1113

    
1114
    <tr>
1115
    <td align="right" class="lineno"><pre>117</pre></td>
1116
    <td align="right" class="linebranch"></td>
1117
    <td align="right" class="linecount "><pre></pre></td>
1118
    <td align="left" class="src "><pre>                PRINTF("in SPIQ *** ERR resuming RECV Task\n")</pre></td>
1119
    </tr>
1120

    
1121
    <tr>
1122
    <td align="right" class="lineno"><pre>118</pre></td>
1123
    <td align="right" class="linebranch"></td>
1124
    <td align="right" class="linecount "><pre></pre></td>
1125
    <td align="left" class="src "><pre>            }</pre></td>
1126
    </tr>
1127

    
1128
    <tr>
1129
    <td align="right" class="lineno"><pre>119</pre></td>
1130
    <td align="right" class="linebranch"></td>
1131
    <td align="right" class="linecount "><pre></pre></td>
1132
    <td align="left" class="src "><pre>        }</pre></td>
1133
    </tr>
1134

    
1135
    <tr>
1136
    <td align="right" class="lineno"><pre>120</pre></td>
1137
    <td align="right" class="linebranch"></td>
1138
    <td align="right" class="linecount "><pre></pre></td>
1139
    <td align="left" class="src "><pre>        else                                // [3.b] the link is not in run state, go in STANDBY mode</pre></td>
1140
    </tr>
1141

    
1142
    <tr>
1143
    <td align="right" class="lineno"><pre>121</pre></td>
1144
    <td align="right" class="linebranch"></td>
1145
    <td align="right" class="linecount "><pre></pre></td>
1146
    <td align="left" class="src "><pre>        {</pre></td>
1147
    </tr>
1148

    
1149
    <tr>
1150
    <td align="right" class="lineno"><pre>122</pre></td>
1151
    <td align="right" class="linebranch"></td>
1152
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
1153
    <td align="left" class="src coveredLine"><pre>            status = enter_mode_standby();</pre></td>
1154
    </tr>
1155

    
1156
    <tr>
1157
    <td align="right" class="lineno"><pre>123</pre></td>
1158
    <td align="right" class="linebranch"></td>
1159
    <td align="right" class="linecount "><pre></pre></td>
1160
    <td align="left" class="src "><pre>            if ( status != RTEMS_SUCCESSFUL )</pre></td>
1161
    </tr>
1162

    
1163
    <tr>
1164
    <td align="right" class="lineno"><pre>124</pre></td>
1165
    <td align="right" class="linebranch"></td>
1166
    <td align="right" class="linecount "><pre></pre></td>
1167
    <td align="left" class="src "><pre>            {</pre></td>
1168
    </tr>
1169

    
1170
    <tr>
1171
    <td align="right" class="lineno"><pre>125</pre></td>
1172
    <td align="right" class="linebranch"></td>
1173
    <td align="right" class="linecount "><pre></pre></td>
1174
    <td align="left" class="src "><pre>                PRINTF1("in SPIQ *** ERR enter_standby_mode *** code %d\n", status)</pre></td>
1175
    </tr>
1176

    
1177
    <tr>
1178
    <td align="right" class="lineno"><pre>126</pre></td>
1179
    <td align="right" class="linebranch"></td>
1180
    <td align="right" class="linecount "><pre></pre></td>
1181
    <td align="left" class="src "><pre>            }</pre></td>
1182
    </tr>
1183

    
1184
    <tr>
1185
    <td align="right" class="lineno"><pre>127</pre></td>
1186
    <td align="right" class="linebranch"></td>
1187
    <td align="right" class="linecount "><pre></pre></td>
1188
    <td align="left" class="src "><pre>            {</pre></td>
1189
    </tr>
1190

    
1191
    <tr>
1192
    <td align="right" class="lineno"><pre>128</pre></td>
1193
    <td align="right" class="linebranch"></td>
1194
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
1195
    <td align="left" class="src coveredLine"><pre>                updateLFRCurrentMode( LFR_MODE_STANDBY );</pre></td>
1196
    </tr>
1197

    
1198
    <tr>
1199
    <td align="right" class="lineno"><pre>129</pre></td>
1200
    <td align="right" class="linebranch"></td>
1201
    <td align="right" class="linecount "><pre></pre></td>
1202
    <td align="left" class="src "><pre>            }</pre></td>
1203
    </tr>
1204

    
1205
    <tr>
1206
    <td align="right" class="lineno"><pre>130</pre></td>
1207
    <td align="right" class="linebranch"></td>
1208
    <td align="right" class="linecount "><pre></pre></td>
1209
    <td align="left" class="src "><pre>            // wake the LINK task up to wait for the link recovery</pre></td>
1210
    </tr>
1211

    
1212
    <tr>
1213
    <td align="right" class="lineno"><pre>131</pre></td>
1214
    <td align="right" class="linebranch"></td>
1215
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
1216
    <td align="left" class="src coveredLine"><pre>            status =  rtems_event_send ( Task_id[TASKID_LINK], RTEMS_EVENT_0 );</pre></td>
1217
    </tr>
1218

    
1219
    <tr>
1220
    <td align="right" class="lineno"><pre>132</pre></td>
1221
    <td align="right" class="linebranch"></td>
1222
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
1223
    <td align="left" class="src coveredLine"><pre>            status = rtems_task_suspend( RTEMS_SELF );</pre></td>
1224
    </tr>
1225

    
1226
    <tr>
1227
    <td align="right" class="lineno"><pre>133</pre></td>
1228
    <td align="right" class="linebranch"></td>
1229
    <td align="right" class="linecount "><pre></pre></td>
1230
    <td align="left" class="src "><pre>        }</pre></td>
1231
    </tr>
1232

    
1233
    <tr>
1234
    <td align="right" class="lineno"><pre>134</pre></td>
1235
    <td align="right" class="linebranch"></td>
1236
    <td align="right" class="linecount "><pre></pre></td>
1237
    <td align="left" class="src "><pre>    }</pre></td>
1238
    </tr>
1239

    
1240
    <tr>
1241
    <td align="right" class="lineno"><pre>135</pre></td>
1242
    <td align="right" class="linebranch"></td>
1243
    <td align="right" class="linecount "><pre></pre></td>
1244
    <td align="left" class="src "><pre>}</pre></td>
1245
    </tr>
1246

    
1247
    <tr>
1248
    <td align="right" class="lineno"><pre>136</pre></td>
1249
    <td align="right" class="linebranch"></td>
1250
    <td align="right" class="linecount "><pre></pre></td>
1251
    <td align="left" class="src "><pre></pre></td>
1252
    </tr>
1253

    
1254
    <tr>
1255
    <td align="right" class="lineno"><pre>137</pre></td>
1256
    <td align="right" class="linebranch"></td>
1257
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1258
    <td align="left" class="src coveredLine"><pre>rtems_task recv_task( rtems_task_argument unused )</pre></td>
1259
    </tr>
1260

    
1261
    <tr>
1262
    <td align="right" class="lineno"><pre>138</pre></td>
1263
    <td align="right" class="linebranch"></td>
1264
    <td align="right" class="linecount "><pre></pre></td>
1265
    <td align="left" class="src "><pre>{</pre></td>
1266
    </tr>
1267

    
1268
    <tr>
1269
    <td align="right" class="lineno"><pre>139</pre></td>
1270
    <td align="right" class="linebranch"></td>
1271
    <td align="right" class="linecount "><pre></pre></td>
1272
    <td align="left" class="src "><pre>    /** This RTEMS task is dedicated to the reception of incoming TeleCommands.</pre></td>
1273
    </tr>
1274

    
1275
    <tr>
1276
    <td align="right" class="lineno"><pre>140</pre></td>
1277
    <td align="right" class="linebranch"></td>
1278
    <td align="right" class="linecount "><pre></pre></td>
1279
    <td align="left" class="src "><pre>     *</pre></td>
1280
    </tr>
1281

    
1282
    <tr>
1283
    <td align="right" class="lineno"><pre>141</pre></td>
1284
    <td align="right" class="linebranch"></td>
1285
    <td align="right" class="linecount "><pre></pre></td>
1286
    <td align="left" class="src "><pre>     * @param unused is the starting argument of the RTEMS task</pre></td>
1287
    </tr>
1288

    
1289
    <tr>
1290
    <td align="right" class="lineno"><pre>142</pre></td>
1291
    <td align="right" class="linebranch"></td>
1292
    <td align="right" class="linecount "><pre></pre></td>
1293
    <td align="left" class="src "><pre>     *</pre></td>
1294
    </tr>
1295

    
1296
    <tr>
1297
    <td align="right" class="lineno"><pre>143</pre></td>
1298
    <td align="right" class="linebranch"></td>
1299
    <td align="right" class="linecount "><pre></pre></td>
1300
    <td align="left" class="src "><pre>     * The RECV task blocks on a call to the read system call, waiting for incoming SpaceWire data. When unblocked:</pre></td>
1301
    </tr>
1302

    
1303
    <tr>
1304
    <td align="right" class="lineno"><pre>144</pre></td>
1305
    <td align="right" class="linebranch"></td>
1306
    <td align="right" class="linecount "><pre></pre></td>
1307
    <td align="left" class="src "><pre>     * 1. It reads the incoming data.</pre></td>
1308
    </tr>
1309

    
1310
    <tr>
1311
    <td align="right" class="lineno"><pre>145</pre></td>
1312
    <td align="right" class="linebranch"></td>
1313
    <td align="right" class="linecount "><pre></pre></td>
1314
    <td align="left" class="src "><pre>     * 2. Launches the acceptance procedure.</pre></td>
1315
    </tr>
1316

    
1317
    <tr>
1318
    <td align="right" class="lineno"><pre>146</pre></td>
1319
    <td align="right" class="linebranch"></td>
1320
    <td align="right" class="linecount "><pre></pre></td>
1321
    <td align="left" class="src "><pre>     * 3. If the Telecommand is valid, sends it to a dedicated RTEMS message queue.</pre></td>
1322
    </tr>
1323

    
1324
    <tr>
1325
    <td align="right" class="lineno"><pre>147</pre></td>
1326
    <td align="right" class="linebranch"></td>
1327
    <td align="right" class="linecount "><pre></pre></td>
1328
    <td align="left" class="src "><pre>     *</pre></td>
1329
    </tr>
1330

    
1331
    <tr>
1332
    <td align="right" class="lineno"><pre>148</pre></td>
1333
    <td align="right" class="linebranch"></td>
1334
    <td align="right" class="linecount "><pre></pre></td>
1335
    <td align="left" class="src "><pre>     */</pre></td>
1336
    </tr>
1337

    
1338
    <tr>
1339
    <td align="right" class="lineno"><pre>149</pre></td>
1340
    <td align="right" class="linebranch"></td>
1341
    <td align="right" class="linecount "><pre></pre></td>
1342
    <td align="left" class="src "><pre></pre></td>
1343
    </tr>
1344

    
1345
    <tr>
1346
    <td align="right" class="lineno"><pre>150</pre></td>
1347
    <td align="right" class="linebranch"></td>
1348
    <td align="right" class="linecount "><pre></pre></td>
1349
    <td align="left" class="src "><pre>    int len;</pre></td>
1350
    </tr>
1351

    
1352
    <tr>
1353
    <td align="right" class="lineno"><pre>151</pre></td>
1354
    <td align="right" class="linebranch"></td>
1355
    <td align="right" class="linecount "><pre></pre></td>
1356
    <td align="left" class="src "><pre>    ccsdsTelecommandPacket_t __attribute__((aligned(4))) currentTC;</pre></td>
1357
    </tr>
1358

    
1359
    <tr>
1360
    <td align="right" class="lineno"><pre>152</pre></td>
1361
    <td align="right" class="linebranch"></td>
1362
    <td align="right" class="linecount "><pre></pre></td>
1363
    <td align="left" class="src "><pre>    unsigned char computed_CRC[ BYTES_PER_CRC ];</pre></td>
1364
    </tr>
1365

    
1366
    <tr>
1367
    <td align="right" class="lineno"><pre>153</pre></td>
1368
    <td align="right" class="linebranch"></td>
1369
    <td align="right" class="linecount "><pre></pre></td>
1370
    <td align="left" class="src "><pre>    unsigned char currentTC_LEN_RCV[ BYTES_PER_PKT_LEN ];</pre></td>
1371
    </tr>
1372

    
1373
    <tr>
1374
    <td align="right" class="lineno"><pre>154</pre></td>
1375
    <td align="right" class="linebranch"></td>
1376
    <td align="right" class="linecount "><pre></pre></td>
1377
    <td align="left" class="src "><pre>    unsigned char destinationID;</pre></td>
1378
    </tr>
1379

    
1380
    <tr>
1381
    <td align="right" class="lineno"><pre>155</pre></td>
1382
    <td align="right" class="linebranch"></td>
1383
    <td align="right" class="linecount "><pre></pre></td>
1384
    <td align="left" class="src "><pre>    unsigned int estimatedPacketLength;</pre></td>
1385
    </tr>
1386

    
1387
    <tr>
1388
    <td align="right" class="lineno"><pre>156</pre></td>
1389
    <td align="right" class="linebranch"></td>
1390
    <td align="right" class="linecount "><pre></pre></td>
1391
    <td align="left" class="src "><pre>    unsigned int parserCode;</pre></td>
1392
    </tr>
1393

    
1394
    <tr>
1395
    <td align="right" class="lineno"><pre>157</pre></td>
1396
    <td align="right" class="linebranch"></td>
1397
    <td align="right" class="linecount "><pre></pre></td>
1398
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
1399
    </tr>
1400

    
1401
    <tr>
1402
    <td align="right" class="lineno"><pre>158</pre></td>
1403
    <td align="right" class="linebranch"></td>
1404
    <td align="right" class="linecount "><pre></pre></td>
1405
    <td align="left" class="src "><pre>    rtems_id queue_recv_id;</pre></td>
1406
    </tr>
1407

    
1408
    <tr>
1409
    <td align="right" class="lineno"><pre>159</pre></td>
1410
    <td align="right" class="linebranch"></td>
1411
    <td align="right" class="linecount "><pre></pre></td>
1412
    <td align="left" class="src "><pre>    rtems_id queue_send_id;</pre></td>
1413
    </tr>
1414

    
1415
    <tr>
1416
    <td align="right" class="lineno"><pre>160</pre></td>
1417
    <td align="right" class="linebranch"></td>
1418
    <td align="right" class="linecount "><pre></pre></td>
1419
    <td align="left" class="src "><pre></pre></td>
1420
    </tr>
1421

    
1422
    <tr>
1423
    <td align="right" class="lineno"><pre>161</pre></td>
1424
    <td align="right" class="linebranch"></td>
1425
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1426
    <td align="left" class="src coveredLine"><pre>    memset( &amp;currentTC, 0, sizeof(ccsdsTelecommandPacket_t) );</pre></td>
1427
    </tr>
1428

    
1429
    <tr>
1430
    <td align="right" class="lineno"><pre>162</pre></td>
1431
    <td align="right" class="linebranch"></td>
1432
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1433
    <td align="left" class="src coveredLine"><pre>    destinationID = 0;</pre></td>
1434
    </tr>
1435

    
1436
    <tr>
1437
    <td align="right" class="lineno"><pre>163</pre></td>
1438
    <td align="right" class="linebranch"></td>
1439
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1440
    <td align="left" class="src coveredLine"><pre>    queue_recv_id = RTEMS_ID_NONE;</pre></td>
1441
    </tr>
1442

    
1443
    <tr>
1444
    <td align="right" class="lineno"><pre>164</pre></td>
1445
    <td align="right" class="linebranch"></td>
1446
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1447
    <td align="left" class="src coveredLine"><pre>    queue_send_id = RTEMS_ID_NONE;</pre></td>
1448
    </tr>
1449

    
1450
    <tr>
1451
    <td align="right" class="lineno"><pre>165</pre></td>
1452
    <td align="right" class="linebranch"></td>
1453
    <td align="right" class="linecount "><pre></pre></td>
1454
    <td align="left" class="src "><pre></pre></td>
1455
    </tr>
1456

    
1457
    <tr>
1458
    <td align="right" class="lineno"><pre>166</pre></td>
1459
    <td align="right" class="linebranch"></td>
1460
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1461
    <td align="left" class="src coveredLine"><pre>    initLookUpTableForCRC(); // the table is used to compute Cyclic Redundancy Codes</pre></td>
1462
    </tr>
1463

    
1464
    <tr>
1465
    <td align="right" class="lineno"><pre>167</pre></td>
1466
    <td align="right" class="linebranch"></td>
1467
    <td align="right" class="linecount "><pre></pre></td>
1468
    <td align="left" class="src "><pre></pre></td>
1469
    </tr>
1470

    
1471
    <tr>
1472
    <td align="right" class="lineno"><pre>168</pre></td>
1473
    <td align="right" class="linebranch"></td>
1474
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1475
    <td align="left" class="src coveredLine"><pre>    status =  get_message_queue_id_recv( &amp;queue_recv_id );</pre></td>
1476
    </tr>
1477

    
1478
    <tr>
1479
    <td align="right" class="lineno"><pre>169</pre></td>
1480
    <td align="right" class="linebranch"></td>
1481
    <td align="right" class="linecount "><pre></pre></td>
1482
    <td align="left" class="src "><pre>    if (status != RTEMS_SUCCESSFUL)</pre></td>
1483
    </tr>
1484

    
1485
    <tr>
1486
    <td align="right" class="lineno"><pre>170</pre></td>
1487
    <td align="right" class="linebranch"></td>
1488
    <td align="right" class="linecount "><pre></pre></td>
1489
    <td align="left" class="src "><pre>    {</pre></td>
1490
    </tr>
1491

    
1492
    <tr>
1493
    <td align="right" class="lineno"><pre>171</pre></td>
1494
    <td align="right" class="linebranch"></td>
1495
    <td align="right" class="linecount "><pre></pre></td>
1496
    <td align="left" class="src "><pre>        PRINTF1("in RECV *** ERR get_message_queue_id_recv %d\n", status)</pre></td>
1497
    </tr>
1498

    
1499
    <tr>
1500
    <td align="right" class="lineno"><pre>172</pre></td>
1501
    <td align="right" class="linebranch"></td>
1502
    <td align="right" class="linecount "><pre></pre></td>
1503
    <td align="left" class="src "><pre>    }</pre></td>
1504
    </tr>
1505

    
1506
    <tr>
1507
    <td align="right" class="lineno"><pre>173</pre></td>
1508
    <td align="right" class="linebranch"></td>
1509
    <td align="right" class="linecount "><pre></pre></td>
1510
    <td align="left" class="src "><pre></pre></td>
1511
    </tr>
1512

    
1513
    <tr>
1514
    <td align="right" class="lineno"><pre>174</pre></td>
1515
    <td align="right" class="linebranch"></td>
1516
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1517
    <td align="left" class="src coveredLine"><pre>    status =  get_message_queue_id_send( &amp;queue_send_id );</pre></td>
1518
    </tr>
1519

    
1520
    <tr>
1521
    <td align="right" class="lineno"><pre>175</pre></td>
1522
    <td align="right" class="linebranch"></td>
1523
    <td align="right" class="linecount "><pre></pre></td>
1524
    <td align="left" class="src "><pre>    if (status != RTEMS_SUCCESSFUL)</pre></td>
1525
    </tr>
1526

    
1527
    <tr>
1528
    <td align="right" class="lineno"><pre>176</pre></td>
1529
    <td align="right" class="linebranch"></td>
1530
    <td align="right" class="linecount "><pre></pre></td>
1531
    <td align="left" class="src "><pre>    {</pre></td>
1532
    </tr>
1533

    
1534
    <tr>
1535
    <td align="right" class="lineno"><pre>177</pre></td>
1536
    <td align="right" class="linebranch"></td>
1537
    <td align="right" class="linecount "><pre></pre></td>
1538
    <td align="left" class="src "><pre>        PRINTF1("in RECV *** ERR get_message_queue_id_send %d\n", status)</pre></td>
1539
    </tr>
1540

    
1541
    <tr>
1542
    <td align="right" class="lineno"><pre>178</pre></td>
1543
    <td align="right" class="linebranch"></td>
1544
    <td align="right" class="linecount "><pre></pre></td>
1545
    <td align="left" class="src "><pre>    }</pre></td>
1546
    </tr>
1547

    
1548
    <tr>
1549
    <td align="right" class="lineno"><pre>179</pre></td>
1550
    <td align="right" class="linebranch"></td>
1551
    <td align="right" class="linecount "><pre></pre></td>
1552
    <td align="left" class="src "><pre></pre></td>
1553
    </tr>
1554

    
1555
    <tr>
1556
    <td align="right" class="lineno"><pre>180</pre></td>
1557
    <td align="right" class="linebranch"></td>
1558
    <td align="right" class="linecount "><pre></pre></td>
1559
    <td align="left" class="src "><pre>    BOOT_PRINTF("in RECV *** \n")</pre></td>
1560
    </tr>
1561

    
1562
    <tr>
1563
    <td align="right" class="lineno"><pre>181</pre></td>
1564
    <td align="right" class="linebranch"></td>
1565
    <td align="right" class="linecount "><pre></pre></td>
1566
    <td align="left" class="src "><pre></pre></td>
1567
    </tr>
1568

    
1569
    <tr>
1570
    <td align="right" class="lineno"><pre>182</pre></td>
1571
    <td align="right" class="linebranch"></td>
1572
    <td align="right" class="linecount "><pre></pre></td>
1573
    <td align="left" class="src "><pre>    while(1)</pre></td>
1574
    </tr>
1575

    
1576
    <tr>
1577
    <td align="right" class="lineno"><pre>183</pre></td>
1578
    <td align="right" class="linebranch"></td>
1579
    <td align="right" class="linecount "><pre></pre></td>
1580
    <td align="left" class="src "><pre>    {</pre></td>
1581
    </tr>
1582

    
1583
    <tr>
1584
    <td align="right" class="lineno"><pre>184</pre></td>
1585
    <td align="right" class="linebranch"></td>
1586
    <td align="right" class="linecount coveredLine"><pre>42271</pre></td>
1587
    <td align="left" class="src coveredLine"><pre>        len = read( fdSPW, (char*) &amp;currentTC, CCSDS_TC_PKT_MAX_SIZE ); // the call to read is blocking</pre></td>
1588
    </tr>
1589

    
1590
    <tr>
1591
    <td align="right" class="lineno"><pre>185</pre></td>
1592
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 42177 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
1593
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1594
    <td align="left" class="src coveredLine"><pre>        if (len == -1){ // error during the read call</pre></td>
1595
    </tr>
1596

    
1597
    <tr>
1598
    <td align="right" class="lineno"><pre>186</pre></td>
1599
    <td align="right" class="linebranch"></td>
1600
    <td align="right" class="linecount "><pre></pre></td>
1601
    <td align="left" class="src "><pre>            PRINTF1("in RECV *** last read call returned -1, ERRNO %d\n", errno)</pre></td>
1602
    </tr>
1603

    
1604
    <tr>
1605
    <td align="right" class="lineno"><pre>187</pre></td>
1606
    <td align="right" class="linebranch"></td>
1607
    <td align="right" class="linecount "><pre></pre></td>
1608
    <td align="left" class="src "><pre>        }</pre></td>
1609
    </tr>
1610

    
1611
    <tr>
1612
    <td align="right" class="lineno"><pre>188</pre></td>
1613
    <td align="right" class="linebranch"></td>
1614
    <td align="right" class="linecount "><pre></pre></td>
1615
    <td align="left" class="src "><pre>        else {</pre></td>
1616
    </tr>
1617

    
1618
    <tr>
1619
    <td align="right" class="lineno"><pre>189</pre></td>
1620
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 42177 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
1621
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1622
    <td align="left" class="src coveredLine"><pre>            if ( (len+1) &lt; CCSDS_TC_PKT_MIN_SIZE ) {</pre></td>
1623
    </tr>
1624

    
1625
    <tr>
1626
    <td align="right" class="lineno"><pre>190</pre></td>
1627
    <td align="right" class="linebranch"></td>
1628
    <td align="right" class="linecount "><pre></pre></td>
1629
    <td align="left" class="src "><pre>                PRINTF("in RECV *** packet lenght too short\n")</pre></td>
1630
    </tr>
1631

    
1632
    <tr>
1633
    <td align="right" class="lineno"><pre>191</pre></td>
1634
    <td align="right" class="linebranch"></td>
1635
    <td align="right" class="linecount "><pre></pre></td>
1636
    <td align="left" class="src "><pre>            }</pre></td>
1637
    </tr>
1638

    
1639
    <tr>
1640
    <td align="right" class="lineno"><pre>192</pre></td>
1641
    <td align="right" class="linebranch"></td>
1642
    <td align="right" class="linecount "><pre></pre></td>
1643
    <td align="left" class="src "><pre>            else {</pre></td>
1644
    </tr>
1645

    
1646
    <tr>
1647
    <td align="right" class="lineno"><pre>193</pre></td>
1648
    <td align="right" class="linebranch"></td>
1649
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1650
    <td align="left" class="src coveredLine"><pre>                estimatedPacketLength = (unsigned int) (len - CCSDS_TC_TM_PACKET_OFFSET - PROTID_RES_APP); // => -3 is for Prot ID, Reserved and User App bytes</pre></td>
1651
    </tr>
1652

    
1653
    <tr>
1654
    <td align="right" class="lineno"><pre>194</pre></td>
1655
    <td align="right" class="linebranch"></td>
1656
    <td align="right" class="linecount "><pre></pre></td>
1657
    <td align="left" class="src "><pre>                PRINTF1("incoming TC with Length (byte): %d\n", len - 3);</pre></td>
1658
    </tr>
1659

    
1660
    <tr>
1661
    <td align="right" class="lineno"><pre>195</pre></td>
1662
    <td align="right" class="linebranch"></td>
1663
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1664
    <td align="left" class="src coveredLine"><pre>                currentTC_LEN_RCV[ 0 ] = (unsigned char) (estimatedPacketLength >> SHIFT_1_BYTE);</pre></td>
1665
    </tr>
1666

    
1667
    <tr>
1668
    <td align="right" class="lineno"><pre>196</pre></td>
1669
    <td align="right" class="linebranch"></td>
1670
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1671
    <td align="left" class="src coveredLine"><pre>                currentTC_LEN_RCV[ 1 ] = (unsigned char) (estimatedPacketLength     );</pre></td>
1672
    </tr>
1673

    
1674
    <tr>
1675
    <td align="right" class="lineno"><pre>197</pre></td>
1676
    <td align="right" class="linebranch"></td>
1677
    <td align="right" class="linecount "><pre></pre></td>
1678
    <td align="left" class="src "><pre>                // CHECK THE TC</pre></td>
1679
    </tr>
1680

    
1681
    <tr>
1682
    <td align="right" class="lineno"><pre>198</pre></td>
1683
    <td align="right" class="linebranch"></td>
1684
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1685
    <td align="left" class="src coveredLine"><pre>                parserCode = tc_parser( &amp;currentTC, estimatedPacketLength, computed_CRC ) ;</pre></td>
1686
    </tr>
1687

    
1688
    <tr>
1689
    <td align="right" class="lineno"><pre>199</pre></td>
1690
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 12374 times">&check;</span><span class="takenBranch" title="Branch 1 taken 29803 times">&check;</span></td>
1691
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1692
    <td align="left" class="src coveredLine"><pre>                if ( (parserCode == ILLEGAL_APID)       || (parserCode == WRONG_LEN_PKT)</pre></td>
1693
    </tr>
1694

    
1695
    <tr>
1696
    <td align="right" class="lineno"><pre>200</pre></td>
1697
    <td align="right" class="linebranch"></td>
1698
    <td align="right" class="linecount "><pre></pre></td>
1699
    <td align="left" class="src "><pre>                     || (parserCode == INCOR_CHECKSUM)  || (parserCode == ILL_TYPE)</pre></td>
1700
    </tr>
1701

    
1702
    <tr>
1703
    <td align="right" class="lineno"><pre>201</pre></td>
1704
    <td align="right" class="linebranch"></td>
1705
    <td align="right" class="linecount "><pre></pre></td>
1706
    <td align="left" class="src "><pre>                     || (parserCode == ILL_SUBTYPE)     || (parserCode == WRONG_APP_DATA)</pre></td>
1707
    </tr>
1708

    
1709
    <tr>
1710
    <td align="right" class="lineno"><pre>202</pre></td>
1711
    <td align="right" class="linebranch"></td>
1712
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1713
    <td align="left" class="src coveredLine"><pre>                     || (parserCode == WRONG_SRC_ID) )</pre></td>
1714
    </tr>
1715

    
1716
    <tr>
1717
    <td align="right" class="lineno"><pre>203</pre></td>
1718
    <td align="right" class="linebranch"></td>
1719
    <td align="right" class="linecount "><pre></pre></td>
1720
    <td align="left" class="src "><pre>                { // send TM_LFR_TC_EXE_CORRUPTED</pre></td>
1721
    </tr>
1722

    
1723
    <tr>
1724
    <td align="right" class="lineno"><pre>204</pre></td>
1725
    <td align="right" class="linebranch"></td>
1726
    <td align="right" class="linecount "><pre></pre></td>
1727
    <td align="left" class="src "><pre>                    PRINTF1("TC corrupted received, with code: %d\n", parserCode);</pre></td>
1728
    </tr>
1729

    
1730
    <tr>
1731
    <td align="right" class="lineno"><pre>205</pre></td>
1732
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 117 times">&check;</span><span class="takenBranch" title="Branch 1 taken 12257 times">&check;</span><span class="takenBranch" title="Branch 2 taken 66 times">&check;</span><span class="takenBranch" title="Branch 3 taken 51 times">&check;</span><br/><span class="takenBranch" title="Branch 4 taken 3997 times">&check;</span><span class="takenBranch" title="Branch 5 taken 8326 times">&check;</span><span class="takenBranch" title="Branch 6 taken 3951 times">&check;</span><span class="takenBranch" title="Branch 7 taken 46 times">&check;</span><br/></td>
1733
    <td align="right" class="linecount coveredLine"><pre>12374</pre></td>
1734
    <td align="left" class="src coveredLine"><pre>                    if ( !( (currentTC.serviceType==TC_TYPE_TIME) &amp;&amp; (currentTC.serviceSubType==TC_SUBTYPE_UPDT_TIME) )</pre></td>
1735
    </tr>
1736

    
1737
    <tr>
1738
    <td align="right" class="lineno"><pre>206</pre></td>
1739
    <td align="right" class="linebranch"></td>
1740
    <td align="right" class="linecount "><pre></pre></td>
1741
    <td align="left" class="src "><pre>                         &amp;&amp;</pre></td>
1742
    </tr>
1743

    
1744
    <tr>
1745
    <td align="right" class="lineno"><pre>207</pre></td>
1746
    <td align="right" class="linebranch"></td>
1747
    <td align="right" class="linecount "><pre></pre></td>
1748
    <td align="left" class="src "><pre>                         !( (currentTC.serviceType==TC_TYPE_GEN) &amp;&amp; (currentTC.serviceSubType==TC_SUBTYPE_UPDT_INFO))</pre></td>
1749
    </tr>
1750

    
1751
    <tr>
1752
    <td align="right" class="lineno"><pre>208</pre></td>
1753
    <td align="right" class="linebranch"></td>
1754
    <td align="right" class="linecount "><pre></pre></td>
1755
    <td align="left" class="src "><pre>                         )</pre></td>
1756
    </tr>
1757

    
1758
    <tr>
1759
    <td align="right" class="lineno"><pre>209</pre></td>
1760
    <td align="right" class="linebranch"></td>
1761
    <td align="right" class="linecount "><pre></pre></td>
1762
    <td align="left" class="src "><pre>                    {</pre></td>
1763
    </tr>
1764

    
1765
    <tr>
1766
    <td align="right" class="lineno"><pre>210</pre></td>
1767
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 3273 times">&check;</span><span class="takenBranch" title="Branch 1 taken 9004 times">&check;</span></td>
1768
    <td align="right" class="linecount coveredLine"><pre>12277</pre></td>
1769
    <td align="left" class="src coveredLine"><pre>                        if ( parserCode == WRONG_SRC_ID )</pre></td>
1770
    </tr>
1771

    
1772
    <tr>
1773
    <td align="right" class="lineno"><pre>211</pre></td>
1774
    <td align="right" class="linebranch"></td>
1775
    <td align="right" class="linecount "><pre></pre></td>
1776
    <td align="left" class="src "><pre>                        {</pre></td>
1777
    </tr>
1778

    
1779
    <tr>
1780
    <td align="right" class="lineno"><pre>212</pre></td>
1781
    <td align="right" class="linebranch"></td>
1782
    <td align="right" class="linecount coveredLine"><pre>3273</pre></td>
1783
    <td align="left" class="src coveredLine"><pre>                            destinationID = SID_TC_GROUND;</pre></td>
1784
    </tr>
1785

    
1786
    <tr>
1787
    <td align="right" class="lineno"><pre>213</pre></td>
1788
    <td align="right" class="linebranch"></td>
1789
    <td align="right" class="linecount "><pre></pre></td>
1790
    <td align="left" class="src "><pre>                        }</pre></td>
1791
    </tr>
1792

    
1793
    <tr>
1794
    <td align="right" class="lineno"><pre>214</pre></td>
1795
    <td align="right" class="linebranch"></td>
1796
    <td align="right" class="linecount "><pre></pre></td>
1797
    <td align="left" class="src "><pre>                        else</pre></td>
1798
    </tr>
1799

    
1800
    <tr>
1801
    <td align="right" class="lineno"><pre>215</pre></td>
1802
    <td align="right" class="linebranch"></td>
1803
    <td align="right" class="linecount "><pre></pre></td>
1804
    <td align="left" class="src "><pre>                        {</pre></td>
1805
    </tr>
1806

    
1807
    <tr>
1808
    <td align="right" class="lineno"><pre>216</pre></td>
1809
    <td align="right" class="linebranch"></td>
1810
    <td align="right" class="linecount coveredLine"><pre>9004</pre></td>
1811
    <td align="left" class="src coveredLine"><pre>                            destinationID = currentTC.sourceID;</pre></td>
1812
    </tr>
1813

    
1814
    <tr>
1815
    <td align="right" class="lineno"><pre>217</pre></td>
1816
    <td align="right" class="linebranch"></td>
1817
    <td align="right" class="linecount "><pre></pre></td>
1818
    <td align="left" class="src "><pre>                        }</pre></td>
1819
    </tr>
1820

    
1821
    <tr>
1822
    <td align="right" class="lineno"><pre>218</pre></td>
1823
    <td align="right" class="linebranch"></td>
1824
    <td align="right" class="linecount coveredLine"><pre>12277</pre></td>
1825
    <td align="left" class="src coveredLine"><pre>                        send_tm_lfr_tc_exe_corrupted( &amp;currentTC, queue_send_id,</pre></td>
1826
    </tr>
1827

    
1828
    <tr>
1829
    <td align="right" class="lineno"><pre>219</pre></td>
1830
    <td align="right" class="linebranch"></td>
1831
    <td align="right" class="linecount "><pre></pre></td>
1832
    <td align="left" class="src "><pre>                                                      computed_CRC, currentTC_LEN_RCV,</pre></td>
1833
    </tr>
1834

    
1835
    <tr>
1836
    <td align="right" class="lineno"><pre>220</pre></td>
1837
    <td align="right" class="linebranch"></td>
1838
    <td align="right" class="linecount "><pre></pre></td>
1839
    <td align="left" class="src "><pre>                                                      destinationID );</pre></td>
1840
    </tr>
1841

    
1842
    <tr>
1843
    <td align="right" class="lineno"><pre>221</pre></td>
1844
    <td align="right" class="linebranch"></td>
1845
    <td align="right" class="linecount "><pre></pre></td>
1846
    <td align="left" class="src "><pre>                    }</pre></td>
1847
    </tr>
1848

    
1849
    <tr>
1850
    <td align="right" class="lineno"><pre>222</pre></td>
1851
    <td align="right" class="linebranch"></td>
1852
    <td align="right" class="linecount "><pre></pre></td>
1853
    <td align="left" class="src "><pre>                }</pre></td>
1854
    </tr>
1855

    
1856
    <tr>
1857
    <td align="right" class="lineno"><pre>223</pre></td>
1858
    <td align="right" class="linebranch"></td>
1859
    <td align="right" class="linecount "><pre></pre></td>
1860
    <td align="left" class="src "><pre>                else</pre></td>
1861
    </tr>
1862

    
1863
    <tr>
1864
    <td align="right" class="lineno"><pre>224</pre></td>
1865
    <td align="right" class="linebranch"></td>
1866
    <td align="right" class="linecount "><pre></pre></td>
1867
    <td align="left" class="src "><pre>                { // send valid TC to the action launcher</pre></td>
1868
    </tr>
1869

    
1870
    <tr>
1871
    <td align="right" class="lineno"><pre>225</pre></td>
1872
    <td align="right" class="linebranch"></td>
1873
    <td align="right" class="linecount coveredLine"><pre>29803</pre></td>
1874
    <td align="left" class="src coveredLine"><pre>                    status =  rtems_message_queue_send( queue_recv_id, &amp;currentTC,</pre></td>
1875
    </tr>
1876

    
1877
    <tr>
1878
    <td align="right" class="lineno"><pre>226</pre></td>
1879
    <td align="right" class="linebranch"></td>
1880
    <td align="right" class="linecount "><pre></pre></td>
1881
    <td align="left" class="src "><pre>                                                        estimatedPacketLength + CCSDS_TC_TM_PACKET_OFFSET + PROTID_RES_APP);</pre></td>
1882
    </tr>
1883

    
1884
    <tr>
1885
    <td align="right" class="lineno"><pre>227</pre></td>
1886
    <td align="right" class="linebranch"></td>
1887
    <td align="right" class="linecount "><pre></pre></td>
1888
    <td align="left" class="src "><pre>                }</pre></td>
1889
    </tr>
1890

    
1891
    <tr>
1892
    <td align="right" class="lineno"><pre>228</pre></td>
1893
    <td align="right" class="linebranch"></td>
1894
    <td align="right" class="linecount "><pre></pre></td>
1895
    <td align="left" class="src "><pre>            }</pre></td>
1896
    </tr>
1897

    
1898
    <tr>
1899
    <td align="right" class="lineno"><pre>229</pre></td>
1900
    <td align="right" class="linebranch"></td>
1901
    <td align="right" class="linecount "><pre></pre></td>
1902
    <td align="left" class="src "><pre>        }</pre></td>
1903
    </tr>
1904

    
1905
    <tr>
1906
    <td align="right" class="lineno"><pre>230</pre></td>
1907
    <td align="right" class="linebranch"></td>
1908
    <td align="right" class="linecount "><pre></pre></td>
1909
    <td align="left" class="src "><pre></pre></td>
1910
    </tr>
1911

    
1912
    <tr>
1913
    <td align="right" class="lineno"><pre>231</pre></td>
1914
    <td align="right" class="linebranch"></td>
1915
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1916
    <td align="left" class="src coveredLine"><pre>        update_queue_max_count( queue_recv_id, &amp;hk_lfr_q_rv_fifo_size_max );</pre></td>
1917
    </tr>
1918

    
1919
    <tr>
1920
    <td align="right" class="lineno"><pre>232</pre></td>
1921
    <td align="right" class="linebranch"></td>
1922
    <td align="right" class="linecount "><pre></pre></td>
1923
    <td align="left" class="src "><pre></pre></td>
1924
    </tr>
1925

    
1926
    <tr>
1927
    <td align="right" class="lineno"><pre>233</pre></td>
1928
    <td align="right" class="linebranch"></td>
1929
    <td align="right" class="linecount coveredLine"><pre>42177</pre></td>
1930
    <td align="left" class="src coveredLine"><pre>    }</pre></td>
1931
    </tr>
1932

    
1933
    <tr>
1934
    <td align="right" class="lineno"><pre>234</pre></td>
1935
    <td align="right" class="linebranch"></td>
1936
    <td align="right" class="linecount "><pre></pre></td>
1937
    <td align="left" class="src "><pre>}</pre></td>
1938
    </tr>
1939

    
1940
    <tr>
1941
    <td align="right" class="lineno"><pre>235</pre></td>
1942
    <td align="right" class="linebranch"></td>
1943
    <td align="right" class="linecount "><pre></pre></td>
1944
    <td align="left" class="src "><pre></pre></td>
1945
    </tr>
1946

    
1947
    <tr>
1948
    <td align="right" class="lineno"><pre>236</pre></td>
1949
    <td align="right" class="linebranch"></td>
1950
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
1951
    <td align="left" class="src coveredLine"><pre>rtems_task send_task( rtems_task_argument argument)</pre></td>
1952
    </tr>
1953

    
1954
    <tr>
1955
    <td align="right" class="lineno"><pre>237</pre></td>
1956
    <td align="right" class="linebranch"></td>
1957
    <td align="right" class="linecount "><pre></pre></td>
1958
    <td align="left" class="src "><pre>{</pre></td>
1959
    </tr>
1960

    
1961
    <tr>
1962
    <td align="right" class="lineno"><pre>238</pre></td>
1963
    <td align="right" class="linebranch"></td>
1964
    <td align="right" class="linecount "><pre></pre></td>
1965
    <td align="left" class="src "><pre>    /** This RTEMS task is dedicated to the transmission of TeleMetry packets.</pre></td>
1966
    </tr>
1967

    
1968
    <tr>
1969
    <td align="right" class="lineno"><pre>239</pre></td>
1970
    <td align="right" class="linebranch"></td>
1971
    <td align="right" class="linecount "><pre></pre></td>
1972
    <td align="left" class="src "><pre>     *</pre></td>
1973
    </tr>
1974

    
1975
    <tr>
1976
    <td align="right" class="lineno"><pre>240</pre></td>
1977
    <td align="right" class="linebranch"></td>
1978
    <td align="right" class="linecount "><pre></pre></td>
1979
    <td align="left" class="src "><pre>     * @param unused is the starting argument of the RTEMS task</pre></td>
1980
    </tr>
1981

    
1982
    <tr>
1983
    <td align="right" class="lineno"><pre>241</pre></td>
1984
    <td align="right" class="linebranch"></td>
1985
    <td align="right" class="linecount "><pre></pre></td>
1986
    <td align="left" class="src "><pre>     *</pre></td>
1987
    </tr>
1988

    
1989
    <tr>
1990
    <td align="right" class="lineno"><pre>242</pre></td>
1991
    <td align="right" class="linebranch"></td>
1992
    <td align="right" class="linecount "><pre></pre></td>
1993
    <td align="left" class="src "><pre>     * The SEND task waits for a message to become available in the dedicated RTEMS queue. When a message arrives:</pre></td>
1994
    </tr>
1995

    
1996
    <tr>
1997
    <td align="right" class="lineno"><pre>243</pre></td>
1998
    <td align="right" class="linebranch"></td>
1999
    <td align="right" class="linecount "><pre></pre></td>
2000
    <td align="left" class="src "><pre>     * - if the first byte is equal to CCSDS_DESTINATION_ID, the message is sent as is using the write system call.</pre></td>
2001
    </tr>
2002

    
2003
    <tr>
2004
    <td align="right" class="lineno"><pre>244</pre></td>
2005
    <td align="right" class="linebranch"></td>
2006
    <td align="right" class="linecount "><pre></pre></td>
2007
    <td align="left" class="src "><pre>     * - if the first byte is not equal to CCSDS_DESTINATION_ID, the message is handled as a spw_ioctl_pkt_send. After</pre></td>
2008
    </tr>
2009

    
2010
    <tr>
2011
    <td align="right" class="lineno"><pre>245</pre></td>
2012
    <td align="right" class="linebranch"></td>
2013
    <td align="right" class="linecount "><pre></pre></td>
2014
    <td align="left" class="src "><pre>     * analyzis, the packet is sent either using the write system call or using the ioctl call SPACEWIRE_IOCTRL_SEND, depending on the</pre></td>
2015
    </tr>
2016

    
2017
    <tr>
2018
    <td align="right" class="lineno"><pre>246</pre></td>
2019
    <td align="right" class="linebranch"></td>
2020
    <td align="right" class="linecount "><pre></pre></td>
2021
    <td align="left" class="src "><pre>     * data it contains.</pre></td>
2022
    </tr>
2023

    
2024
    <tr>
2025
    <td align="right" class="lineno"><pre>247</pre></td>
2026
    <td align="right" class="linebranch"></td>
2027
    <td align="right" class="linecount "><pre></pre></td>
2028
    <td align="left" class="src "><pre>     *</pre></td>
2029
    </tr>
2030

    
2031
    <tr>
2032
    <td align="right" class="lineno"><pre>248</pre></td>
2033
    <td align="right" class="linebranch"></td>
2034
    <td align="right" class="linecount "><pre></pre></td>
2035
    <td align="left" class="src "><pre>     */</pre></td>
2036
    </tr>
2037

    
2038
    <tr>
2039
    <td align="right" class="lineno"><pre>249</pre></td>
2040
    <td align="right" class="linebranch"></td>
2041
    <td align="right" class="linecount "><pre></pre></td>
2042
    <td align="left" class="src "><pre></pre></td>
2043
    </tr>
2044

    
2045
    <tr>
2046
    <td align="right" class="lineno"><pre>250</pre></td>
2047
    <td align="right" class="linebranch"></td>
2048
    <td align="right" class="linecount "><pre></pre></td>
2049
    <td align="left" class="src "><pre>    rtems_status_code status;                // RTEMS status code</pre></td>
2050
    </tr>
2051

    
2052
    <tr>
2053
    <td align="right" class="lineno"><pre>251</pre></td>
2054
    <td align="right" class="linebranch"></td>
2055
    <td align="right" class="linecount "><pre></pre></td>
2056
    <td align="left" class="src "><pre>    char incomingData[MSG_QUEUE_SIZE_SEND];  // incoming data buffer</pre></td>
2057
    </tr>
2058

    
2059
    <tr>
2060
    <td align="right" class="lineno"><pre>252</pre></td>
2061
    <td align="right" class="linebranch"></td>
2062
    <td align="right" class="linecount "><pre></pre></td>
2063
    <td align="left" class="src "><pre>    ring_node *incomingRingNodePtr;</pre></td>
2064
    </tr>
2065

    
2066
    <tr>
2067
    <td align="right" class="lineno"><pre>253</pre></td>
2068
    <td align="right" class="linebranch"></td>
2069
    <td align="right" class="linecount "><pre></pre></td>
2070
    <td align="left" class="src "><pre>    int ring_node_address;</pre></td>
2071
    </tr>
2072

    
2073
    <tr>
2074
    <td align="right" class="lineno"><pre>254</pre></td>
2075
    <td align="right" class="linebranch"></td>
2076
    <td align="right" class="linecount "><pre></pre></td>
2077
    <td align="left" class="src "><pre>    char *charPtr;</pre></td>
2078
    </tr>
2079

    
2080
    <tr>
2081
    <td align="right" class="lineno"><pre>255</pre></td>
2082
    <td align="right" class="linebranch"></td>
2083
    <td align="right" class="linecount "><pre></pre></td>
2084
    <td align="left" class="src "><pre>    spw_ioctl_pkt_send *spw_ioctl_send;</pre></td>
2085
    </tr>
2086

    
2087
    <tr>
2088
    <td align="right" class="lineno"><pre>256</pre></td>
2089
    <td align="right" class="linebranch"></td>
2090
    <td align="right" class="linecount "><pre></pre></td>
2091
    <td align="left" class="src "><pre>    size_t size;                            // size of the incoming TC packet</pre></td>
2092
    </tr>
2093

    
2094
    <tr>
2095
    <td align="right" class="lineno"><pre>257</pre></td>
2096
    <td align="right" class="linebranch"></td>
2097
    <td align="right" class="linecount "><pre></pre></td>
2098
    <td align="left" class="src "><pre>    rtems_id queue_send_id;</pre></td>
2099
    </tr>
2100

    
2101
    <tr>
2102
    <td align="right" class="lineno"><pre>258</pre></td>
2103
    <td align="right" class="linebranch"></td>
2104
    <td align="right" class="linecount "><pre></pre></td>
2105
    <td align="left" class="src "><pre>    unsigned int sid;</pre></td>
2106
    </tr>
2107

    
2108
    <tr>
2109
    <td align="right" class="lineno"><pre>259</pre></td>
2110
    <td align="right" class="linebranch"></td>
2111
    <td align="right" class="linecount "><pre></pre></td>
2112
    <td align="left" class="src "><pre>    unsigned char sidAsUnsignedChar;</pre></td>
2113
    </tr>
2114

    
2115
    <tr>
2116
    <td align="right" class="lineno"><pre>260</pre></td>
2117
    <td align="right" class="linebranch"></td>
2118
    <td align="right" class="linecount "><pre></pre></td>
2119
    <td align="left" class="src "><pre>    unsigned char type;</pre></td>
2120
    </tr>
2121

    
2122
    <tr>
2123
    <td align="right" class="lineno"><pre>261</pre></td>
2124
    <td align="right" class="linebranch"></td>
2125
    <td align="right" class="linecount "><pre></pre></td>
2126
    <td align="left" class="src "><pre></pre></td>
2127
    </tr>
2128

    
2129
    <tr>
2130
    <td align="right" class="lineno"><pre>262</pre></td>
2131
    <td align="right" class="linebranch"></td>
2132
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2133
    <td align="left" class="src coveredLine"><pre>    incomingRingNodePtr = NULL;</pre></td>
2134
    </tr>
2135

    
2136
    <tr>
2137
    <td align="right" class="lineno"><pre>263</pre></td>
2138
    <td align="right" class="linebranch"></td>
2139
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2140
    <td align="left" class="src coveredLine"><pre>    ring_node_address = 0;</pre></td>
2141
    </tr>
2142

    
2143
    <tr>
2144
    <td align="right" class="lineno"><pre>264</pre></td>
2145
    <td align="right" class="linebranch"></td>
2146
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2147
    <td align="left" class="src coveredLine"><pre>    charPtr = (char *) &amp;ring_node_address;</pre></td>
2148
    </tr>
2149

    
2150
    <tr>
2151
    <td align="right" class="lineno"><pre>265</pre></td>
2152
    <td align="right" class="linebranch"></td>
2153
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2154
    <td align="left" class="src coveredLine"><pre>    size = 0;</pre></td>
2155
    </tr>
2156

    
2157
    <tr>
2158
    <td align="right" class="lineno"><pre>266</pre></td>
2159
    <td align="right" class="linebranch"></td>
2160
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2161
    <td align="left" class="src coveredLine"><pre>    queue_send_id = RTEMS_ID_NONE;</pre></td>
2162
    </tr>
2163

    
2164
    <tr>
2165
    <td align="right" class="lineno"><pre>267</pre></td>
2166
    <td align="right" class="linebranch"></td>
2167
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2168
    <td align="left" class="src coveredLine"><pre>    sid = 0;</pre></td>
2169
    </tr>
2170

    
2171
    <tr>
2172
    <td align="right" class="lineno"><pre>268</pre></td>
2173
    <td align="right" class="linebranch"></td>
2174
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2175
    <td align="left" class="src coveredLine"><pre>    sidAsUnsignedChar = 0;</pre></td>
2176
    </tr>
2177

    
2178
    <tr>
2179
    <td align="right" class="lineno"><pre>269</pre></td>
2180
    <td align="right" class="linebranch"></td>
2181
    <td align="right" class="linecount "><pre></pre></td>
2182
    <td align="left" class="src "><pre></pre></td>
2183
    </tr>
2184

    
2185
    <tr>
2186
    <td align="right" class="lineno"><pre>270</pre></td>
2187
    <td align="right" class="linebranch"></td>
2188
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2189
    <td align="left" class="src coveredLine"><pre>    init_header_cwf( &amp;headerCWF );</pre></td>
2190
    </tr>
2191

    
2192
    <tr>
2193
    <td align="right" class="lineno"><pre>271</pre></td>
2194
    <td align="right" class="linebranch"></td>
2195
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2196
    <td align="left" class="src coveredLine"><pre>    init_header_swf( &amp;headerSWF );</pre></td>
2197
    </tr>
2198

    
2199
    <tr>
2200
    <td align="right" class="lineno"><pre>272</pre></td>
2201
    <td align="right" class="linebranch"></td>
2202
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2203
    <td align="left" class="src coveredLine"><pre>    init_header_asm( &amp;headerASM );</pre></td>
2204
    </tr>
2205

    
2206
    <tr>
2207
    <td align="right" class="lineno"><pre>273</pre></td>
2208
    <td align="right" class="linebranch"></td>
2209
    <td align="right" class="linecount "><pre></pre></td>
2210
    <td align="left" class="src "><pre></pre></td>
2211
    </tr>
2212

    
2213
    <tr>
2214
    <td align="right" class="lineno"><pre>274</pre></td>
2215
    <td align="right" class="linebranch"></td>
2216
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
2217
    <td align="left" class="src coveredLine"><pre>    status =  get_message_queue_id_send( &amp;queue_send_id );</pre></td>
2218
    </tr>
2219

    
2220
    <tr>
2221
    <td align="right" class="lineno"><pre>275</pre></td>
2222
    <td align="right" class="linebranch"></td>
2223
    <td align="right" class="linecount "><pre></pre></td>
2224
    <td align="left" class="src "><pre>    if (status != RTEMS_SUCCESSFUL)</pre></td>
2225
    </tr>
2226

    
2227
    <tr>
2228
    <td align="right" class="lineno"><pre>276</pre></td>
2229
    <td align="right" class="linebranch"></td>
2230
    <td align="right" class="linecount "><pre></pre></td>
2231
    <td align="left" class="src "><pre>    {</pre></td>
2232
    </tr>
2233

    
2234
    <tr>
2235
    <td align="right" class="lineno"><pre>277</pre></td>
2236
    <td align="right" class="linebranch"></td>
2237
    <td align="right" class="linecount "><pre></pre></td>
2238
    <td align="left" class="src "><pre>        PRINTF1("in HOUS *** ERR get_message_queue_id_send %d\n", status)</pre></td>
2239
    </tr>
2240

    
2241
    <tr>
2242
    <td align="right" class="lineno"><pre>278</pre></td>
2243
    <td align="right" class="linebranch"></td>
2244
    <td align="right" class="linecount "><pre></pre></td>
2245
    <td align="left" class="src "><pre>    }</pre></td>
2246
    </tr>
2247

    
2248
    <tr>
2249
    <td align="right" class="lineno"><pre>279</pre></td>
2250
    <td align="right" class="linebranch"></td>
2251
    <td align="right" class="linecount "><pre></pre></td>
2252
    <td align="left" class="src "><pre></pre></td>
2253
    </tr>
2254

    
2255
    <tr>
2256
    <td align="right" class="lineno"><pre>280</pre></td>
2257
    <td align="right" class="linebranch"></td>
2258
    <td align="right" class="linecount "><pre></pre></td>
2259
    <td align="left" class="src "><pre>    BOOT_PRINTF("in SEND *** \n")</pre></td>
2260
    </tr>
2261

    
2262
    <tr>
2263
    <td align="right" class="lineno"><pre>281</pre></td>
2264
    <td align="right" class="linebranch"></td>
2265
    <td align="right" class="linecount "><pre></pre></td>
2266
    <td align="left" class="src "><pre></pre></td>
2267
    </tr>
2268

    
2269
    <tr>
2270
    <td align="right" class="lineno"><pre>282</pre></td>
2271
    <td align="right" class="linebranch"></td>
2272
    <td align="right" class="linecount "><pre></pre></td>
2273
    <td align="left" class="src "><pre>    while(1)</pre></td>
2274
    </tr>
2275

    
2276
    <tr>
2277
    <td align="right" class="lineno"><pre>283</pre></td>
2278
    <td align="right" class="linebranch"></td>
2279
    <td align="right" class="linecount "><pre></pre></td>
2280
    <td align="left" class="src "><pre>    {</pre></td>
2281
    </tr>
2282

    
2283
    <tr>
2284
    <td align="right" class="lineno"><pre>284</pre></td>
2285
    <td align="right" class="linebranch"></td>
2286
    <td align="right" class="linecount coveredLine"><pre>567365</pre></td>
2287
    <td align="left" class="src coveredLine"><pre>        status = rtems_message_queue_receive( queue_send_id, incomingData, &amp;size,</pre></td>
2288
    </tr>
2289

    
2290
    <tr>
2291
    <td align="right" class="lineno"><pre>285</pre></td>
2292
    <td align="right" class="linebranch"></td>
2293
    <td align="right" class="linecount "><pre></pre></td>
2294
    <td align="left" class="src "><pre>                                             RTEMS_WAIT, RTEMS_NO_TIMEOUT );</pre></td>
2295
    </tr>
2296

    
2297
    <tr>
2298
    <td align="right" class="lineno"><pre>286</pre></td>
2299
    <td align="right" class="linebranch"></td>
2300
    <td align="right" class="linecount "><pre></pre></td>
2301
    <td align="left" class="src "><pre></pre></td>
2302
    </tr>
2303

    
2304
    <tr>
2305
    <td align="right" class="lineno"><pre>287</pre></td>
2306
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 567271 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
2307
    <td align="right" class="linecount coveredLine"><pre>567271</pre></td>
2308
    <td align="left" class="src coveredLine"><pre>        if (status!=RTEMS_SUCCESSFUL)</pre></td>
2309
    </tr>
2310

    
2311
    <tr>
2312
    <td align="right" class="lineno"><pre>288</pre></td>
2313
    <td align="right" class="linebranch"></td>
2314
    <td align="right" class="linecount "><pre></pre></td>
2315
    <td align="left" class="src "><pre>        {</pre></td>
2316
    </tr>
2317

    
2318
    <tr>
2319
    <td align="right" class="lineno"><pre>289</pre></td>
2320
    <td align="right" class="linebranch"></td>
2321
    <td align="right" class="linecount "><pre></pre></td>
2322
    <td align="left" class="src "><pre>            PRINTF1("in SEND *** (1) ERR = %d\n", status)</pre></td>
2323
    </tr>
2324

    
2325
    <tr>
2326
    <td align="right" class="lineno"><pre>290</pre></td>
2327
    <td align="right" class="linebranch"></td>
2328
    <td align="right" class="linecount "><pre></pre></td>
2329
    <td align="left" class="src "><pre>        }</pre></td>
2330
    </tr>
2331

    
2332
    <tr>
2333
    <td align="right" class="lineno"><pre>291</pre></td>
2334
    <td align="right" class="linebranch"></td>
2335
    <td align="right" class="linecount "><pre></pre></td>
2336
    <td align="left" class="src "><pre>        else</pre></td>
2337
    </tr>
2338

    
2339
    <tr>
2340
    <td align="right" class="lineno"><pre>292</pre></td>
2341
    <td align="right" class="linebranch"></td>
2342
    <td align="right" class="linecount "><pre></pre></td>
2343
    <td align="left" class="src "><pre>        {</pre></td>
2344
    </tr>
2345

    
2346
    <tr>
2347
    <td align="right" class="lineno"><pre>293</pre></td>
2348
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 101382 times">&check;</span><span class="takenBranch" title="Branch 1 taken 465889 times">&check;</span></td>
2349
    <td align="right" class="linecount coveredLine"><pre>567271</pre></td>
2350
    <td align="left" class="src coveredLine"><pre>            if ( size == sizeof(ring_node*) )</pre></td>
2351
    </tr>
2352

    
2353
    <tr>
2354
    <td align="right" class="lineno"><pre>294</pre></td>
2355
    <td align="right" class="linebranch"></td>
2356
    <td align="right" class="linecount "><pre></pre></td>
2357
    <td align="left" class="src "><pre>            {</pre></td>
2358
    </tr>
2359

    
2360
    <tr>
2361
    <td align="right" class="lineno"><pre>295</pre></td>
2362
    <td align="right" class="linebranch"></td>
2363
    <td align="right" class="linecount coveredLine"><pre>101382</pre></td>
2364
    <td align="left" class="src coveredLine"><pre>                charPtr[0] = incomingData[0];</pre></td>
2365
    </tr>
2366

    
2367
    <tr>
2368
    <td align="right" class="lineno"><pre>296</pre></td>
2369
    <td align="right" class="linebranch"></td>
2370
    <td align="right" class="linecount coveredLine"><pre>101382</pre></td>
2371
    <td align="left" class="src coveredLine"><pre>                charPtr[1] = incomingData[1];</pre></td>
2372
    </tr>
2373

    
2374
    <tr>
2375
    <td align="right" class="lineno"><pre>297</pre></td>
2376
    <td align="right" class="linebranch"></td>
2377
    <td align="right" class="linecount coveredLine"><pre>101382</pre></td>
2378
    <td align="left" class="src coveredLine"><pre>                charPtr[BYTE_2] = incomingData[BYTE_2];</pre></td>
2379
    </tr>
2380

    
2381
    <tr>
2382
    <td align="right" class="lineno"><pre>298</pre></td>
2383
    <td align="right" class="linebranch"></td>
2384
    <td align="right" class="linecount coveredLine"><pre>101382</pre></td>
2385
    <td align="left" class="src coveredLine"><pre>                charPtr[BYTE_3] = incomingData[BYTE_3];</pre></td>
2386
    </tr>
2387

    
2388
    <tr>
2389
    <td align="right" class="lineno"><pre>299</pre></td>
2390
    <td align="right" class="linebranch"></td>
2391
    <td align="right" class="linecount coveredLine"><pre>101382</pre></td>
2392
    <td align="left" class="src coveredLine"><pre>                incomingRingNodePtr = (ring_node*) ring_node_address;</pre></td>
2393
    </tr>
2394

    
2395
    <tr>
2396
    <td align="right" class="lineno"><pre>300</pre></td>
2397
    <td align="right" class="linebranch"></td>
2398
    <td align="right" class="linecount coveredLine"><pre>101382</pre></td>
2399
    <td align="left" class="src coveredLine"><pre>                sid = incomingRingNodePtr->sid;</pre></td>
2400
    </tr>
2401

    
2402
    <tr>
2403
    <td align="right" class="lineno"><pre>301</pre></td>
2404
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 100293 times">&check;</span><span class="takenBranch" title="Branch 1 taken 1089 times">&check;</span><span class="takenBranch" title="Branch 2 taken 42991 times">&check;</span><span class="takenBranch" title="Branch 3 taken 57302 times">&check;</span><br/></td>
2405
    <td align="right" class="linecount coveredLine"><pre>347137</pre></td>
2406
    <td align="left" class="src coveredLine"><pre>                if ( (sid==SID_NORM_CWF_LONG_F3)</pre></td>
2407
    </tr>
2408

    
2409
    <tr>
2410
    <td align="right" class="lineno"><pre>302</pre></td>
2411
    <td align="right" class="linebranch"></td>
2412
    <td align="right" class="linecount coveredLine"><pre>101382</pre></td>
2413
    <td align="left" class="src coveredLine"><pre>                     || (sid==SID_BURST_CWF_F2 )</pre></td>
2414
    </tr>
2415

    
2416
    <tr>
2417
    <td align="right" class="lineno"><pre>303</pre></td>
2418
    <td align="right" class="linebranch"></td>
2419
    <td align="right" class="linecount coveredLine"><pre>201675</pre></td>
2420
    <td align="left" class="src coveredLine"><pre>                     || (sid==SID_SBM1_CWF_F1  )</pre></td>
2421
    </tr>
2422

    
2423
    <tr>
2424
    <td align="right" class="lineno"><pre>304</pre></td>
2425
    <td align="right" class="linebranch"></td>
2426
    <td align="right" class="linecount coveredLine"><pre>100293</pre></td>
2427
    <td align="left" class="src coveredLine"><pre>                     || (sid==SID_SBM2_CWF_F2  ))</pre></td>
2428
    </tr>
2429

    
2430
    <tr>
2431
    <td align="right" class="lineno"><pre>305</pre></td>
2432
    <td align="right" class="linebranch"></td>
2433
    <td align="right" class="linecount "><pre></pre></td>
2434
    <td align="left" class="src "><pre>                {</pre></td>
2435
    </tr>
2436

    
2437
    <tr>
2438
    <td align="right" class="lineno"><pre>306</pre></td>
2439
    <td align="right" class="linebranch"></td>
2440
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
2441
    <td align="left" class="src coveredLine"><pre>                    spw_send_waveform_CWF( incomingRingNodePtr, &amp;headerCWF );</pre></td>
2442
    </tr>
2443

    
2444
    <tr>
2445
    <td align="right" class="lineno"><pre>307</pre></td>
2446
    <td align="right" class="linebranch"></td>
2447
    <td align="right" class="linecount "><pre></pre></td>
2448
    <td align="left" class="src "><pre>                }</pre></td>
2449
    </tr>
2450

    
2451
    <tr>
2452
    <td align="right" class="lineno"><pre>308</pre></td>
2453
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 5535 times">&check;</span><span class="takenBranch" title="Branch 1 taken 51767 times">&check;</span></td>
2454
    <td align="right" class="linecount coveredLine"><pre>57302</pre></td>
2455
    <td align="left" class="src coveredLine"><pre>                else if ( (sid==SID_NORM_SWF_F0) || (sid==SID_NORM_SWF_F1) || (sid==SID_NORM_SWF_F2) )</pre></td>
2456
    </tr>
2457

    
2458
    <tr>
2459
    <td align="right" class="lineno"><pre>309</pre></td>
2460
    <td align="right" class="linebranch"></td>
2461
    <td align="right" class="linecount "><pre></pre></td>
2462
    <td align="left" class="src "><pre>                {</pre></td>
2463
    </tr>
2464

    
2465
    <tr>
2466
    <td align="right" class="lineno"><pre>310</pre></td>
2467
    <td align="right" class="linebranch"></td>
2468
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
2469
    <td align="left" class="src coveredLine"><pre>                    spw_send_waveform_SWF( incomingRingNodePtr, &amp;headerSWF );</pre></td>
2470
    </tr>
2471

    
2472
    <tr>
2473
    <td align="right" class="lineno"><pre>311</pre></td>
2474
    <td align="right" class="linebranch"></td>
2475
    <td align="right" class="linecount "><pre></pre></td>
2476
    <td align="left" class="src "><pre>                }</pre></td>
2477
    </tr>
2478

    
2479
    <tr>
2480
    <td align="right" class="lineno"><pre>312</pre></td>
2481
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 391 times">&check;</span><span class="takenBranch" title="Branch 1 taken 51376 times">&check;</span></td>
2482
    <td align="right" class="linecount coveredLine"><pre>51767</pre></td>
2483
    <td align="left" class="src coveredLine"><pre>                else if (sid==SID_NORM_CWF_F3)</pre></td>
2484
    </tr>
2485

    
2486
    <tr>
2487
    <td align="right" class="lineno"><pre>313</pre></td>
2488
    <td align="right" class="linebranch"></td>
2489
    <td align="right" class="linecount "><pre></pre></td>
2490
    <td align="left" class="src "><pre>                {</pre></td>
2491
    </tr>
2492

    
2493
    <tr>
2494
    <td align="right" class="lineno"><pre>314</pre></td>
2495
    <td align="right" class="linebranch"></td>
2496
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
2497
    <td align="left" class="src coveredLine"><pre>                    spw_send_waveform_CWF3_light( incomingRingNodePtr, &amp;headerCWF );</pre></td>
2498
    </tr>
2499

    
2500
    <tr>
2501
    <td align="right" class="lineno"><pre>315</pre></td>
2502
    <td align="right" class="linebranch"></td>
2503
    <td align="right" class="linecount "><pre></pre></td>
2504
    <td align="left" class="src "><pre>                }</pre></td>
2505
    </tr>
2506

    
2507
    <tr>
2508
    <td align="right" class="lineno"><pre>316</pre></td>
2509
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 16114 times">&check;</span><span class="takenBranch" title="Branch 1 taken 35262 times">&check;</span></td>
2510
    <td align="right" class="linecount coveredLine"><pre>51376</pre></td>
2511
    <td align="left" class="src coveredLine"><pre>                else if (sid==SID_NORM_ASM_F0)</pre></td>
2512
    </tr>
2513

    
2514
    <tr>
2515
    <td align="right" class="lineno"><pre>317</pre></td>
2516
    <td align="right" class="linebranch"></td>
2517
    <td align="right" class="linecount "><pre></pre></td>
2518
    <td align="left" class="src "><pre>                {</pre></td>
2519
    </tr>
2520

    
2521
    <tr>
2522
    <td align="right" class="lineno"><pre>318</pre></td>
2523
    <td align="right" class="linebranch"></td>
2524
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
2525
    <td align="left" class="src coveredLine"><pre>                    spw_send_asm_f0( incomingRingNodePtr, &amp;headerASM );</pre></td>
2526
    </tr>
2527

    
2528
    <tr>
2529
    <td align="right" class="lineno"><pre>319</pre></td>
2530
    <td align="right" class="linebranch"></td>
2531
    <td align="right" class="linecount "><pre></pre></td>
2532
    <td align="left" class="src "><pre>                }</pre></td>
2533
    </tr>
2534

    
2535
    <tr>
2536
    <td align="right" class="lineno"><pre>320</pre></td>
2537
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 16112 times">&check;</span><span class="takenBranch" title="Branch 1 taken 19150 times">&check;</span></td>
2538
    <td align="right" class="linecount coveredLine"><pre>35262</pre></td>
2539
    <td align="left" class="src coveredLine"><pre>                else if (sid==SID_NORM_ASM_F1)</pre></td>
2540
    </tr>
2541

    
2542
    <tr>
2543
    <td align="right" class="lineno"><pre>321</pre></td>
2544
    <td align="right" class="linebranch"></td>
2545
    <td align="right" class="linecount "><pre></pre></td>
2546
    <td align="left" class="src "><pre>                {</pre></td>
2547
    </tr>
2548

    
2549
    <tr>
2550
    <td align="right" class="lineno"><pre>322</pre></td>
2551
    <td align="right" class="linebranch"></td>
2552
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
2553
    <td align="left" class="src coveredLine"><pre>                    spw_send_asm_f1( incomingRingNodePtr, &amp;headerASM );</pre></td>
2554
    </tr>
2555

    
2556
    <tr>
2557
    <td align="right" class="lineno"><pre>323</pre></td>
2558
    <td align="right" class="linebranch"></td>
2559
    <td align="right" class="linecount "><pre></pre></td>
2560
    <td align="left" class="src "><pre>                }</pre></td>
2561
    </tr>
2562

    
2563
    <tr>
2564
    <td align="right" class="lineno"><pre>324</pre></td>
2565
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 16100 times">&check;</span><span class="takenBranch" title="Branch 1 taken 3050 times">&check;</span></td>
2566
    <td align="right" class="linecount coveredLine"><pre>19150</pre></td>
2567
    <td align="left" class="src coveredLine"><pre>                else if (sid==SID_NORM_ASM_F2)</pre></td>
2568
    </tr>
2569

    
2570
    <tr>
2571
    <td align="right" class="lineno"><pre>325</pre></td>
2572
    <td align="right" class="linebranch"></td>
2573
    <td align="right" class="linecount "><pre></pre></td>
2574
    <td align="left" class="src "><pre>                {</pre></td>
2575
    </tr>
2576

    
2577
    <tr>
2578
    <td align="right" class="lineno"><pre>326</pre></td>
2579
    <td align="right" class="linebranch"></td>
2580
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
2581
    <td align="left" class="src coveredLine"><pre>                    spw_send_asm_f2( incomingRingNodePtr, &amp;headerASM );</pre></td>
2582
    </tr>
2583

    
2584
    <tr>
2585
    <td align="right" class="lineno"><pre>327</pre></td>
2586
    <td align="right" class="linebranch"></td>
2587
    <td align="right" class="linecount "><pre></pre></td>
2588
    <td align="left" class="src "><pre>                }</pre></td>
2589
    </tr>
2590

    
2591
    <tr>
2592
    <td align="right" class="lineno"><pre>328</pre></td>
2593
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 3050 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
2594
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
2595
    <td align="left" class="src coveredLine"><pre>                else if (sid==TM_CODE_K_DUMP)</pre></td>
2596
    </tr>
2597

    
2598
    <tr>
2599
    <td align="right" class="lineno"><pre>329</pre></td>
2600
    <td align="right" class="linebranch"></td>
2601
    <td align="right" class="linecount "><pre></pre></td>
2602
    <td align="left" class="src "><pre>                {</pre></td>
2603
    </tr>
2604

    
2605
    <tr>
2606
    <td align="right" class="lineno"><pre>330</pre></td>
2607
    <td align="right" class="linebranch"></td>
2608
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
2609
    <td align="left" class="src coveredLine"><pre>                    spw_send_k_dump( incomingRingNodePtr );</pre></td>
2610
    </tr>
2611

    
2612
    <tr>
2613
    <td align="right" class="lineno"><pre>331</pre></td>
2614
    <td align="right" class="linebranch"></td>
2615
    <td align="right" class="linecount "><pre></pre></td>
2616
    <td align="left" class="src "><pre>                }</pre></td>
2617
    </tr>
2618

    
2619
    <tr>
2620
    <td align="right" class="lineno"><pre>332</pre></td>
2621
    <td align="right" class="linebranch"></td>
2622
    <td align="right" class="linecount "><pre></pre></td>
2623
    <td align="left" class="src "><pre>                else</pre></td>
2624
    </tr>
2625

    
2626
    <tr>
2627
    <td align="right" class="lineno"><pre>333</pre></td>
2628
    <td align="right" class="linebranch"></td>
2629
    <td align="right" class="linecount "><pre></pre></td>
2630
    <td align="left" class="src "><pre>                {</pre></td>
2631
    </tr>
2632

    
2633
    <tr>
2634
    <td align="right" class="lineno"><pre>334</pre></td>
2635
    <td align="right" class="linebranch"></td>
2636
    <td align="right" class="linecount "><pre></pre></td>
2637
    <td align="left" class="src "><pre>                    PRINTF1("unexpected sid = %d\n", sid);</pre></td>
2638
    </tr>
2639

    
2640
    <tr>
2641
    <td align="right" class="lineno"><pre>335</pre></td>
2642
    <td align="right" class="linebranch"></td>
2643
    <td align="right" class="linecount "><pre></pre></td>
2644
    <td align="left" class="src "><pre>                }</pre></td>
2645
    </tr>
2646

    
2647
    <tr>
2648
    <td align="right" class="lineno"><pre>336</pre></td>
2649
    <td align="right" class="linebranch"></td>
2650
    <td align="right" class="linecount "><pre></pre></td>
2651
    <td align="left" class="src "><pre>            }</pre></td>
2652
    </tr>
2653

    
2654
    <tr>
2655
    <td align="right" class="lineno"><pre>337</pre></td>
2656
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 465889 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
2657
    <td align="right" class="linecount coveredLine"><pre>465889</pre></td>
2658
    <td align="left" class="src coveredLine"><pre>            else if ( incomingData[0] == CCSDS_DESTINATION_ID ) // the incoming message is a ccsds packet</pre></td>
2659
    </tr>
2660

    
2661
    <tr>
2662
    <td align="right" class="lineno"><pre>338</pre></td>
2663
    <td align="right" class="linebranch"></td>
2664
    <td align="right" class="linecount "><pre></pre></td>
2665
    <td align="left" class="src "><pre>            {</pre></td>
2666
    </tr>
2667

    
2668
    <tr>
2669
    <td align="right" class="lineno"><pre>339</pre></td>
2670
    <td align="right" class="linebranch"></td>
2671
    <td align="right" class="linecount coveredLine"><pre>465889</pre></td>
2672
    <td align="left" class="src coveredLine"><pre>                sidAsUnsignedChar = (unsigned char) incomingData[ PACKET_POS_PA_LFR_SID_PKT ];</pre></td>
2673
    </tr>
2674

    
2675
    <tr>
2676
    <td align="right" class="lineno"><pre>340</pre></td>
2677
    <td align="right" class="linebranch"></td>
2678
    <td align="right" class="linecount coveredLine"><pre>465889</pre></td>
2679
    <td align="left" class="src coveredLine"><pre>                sid = sidAsUnsignedChar;</pre></td>
2680
    </tr>
2681

    
2682
    <tr>
2683
    <td align="right" class="lineno"><pre>341</pre></td>
2684
    <td align="right" class="linebranch"></td>
2685
    <td align="right" class="linecount coveredLine"><pre>465889</pre></td>
2686
    <td align="left" class="src coveredLine"><pre>                type = (unsigned char) incomingData[ PACKET_POS_SERVICE_TYPE ];</pre></td>
2687
    </tr>
2688

    
2689
    <tr>
2690
    <td align="right" class="lineno"><pre>342</pre></td>
2691
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 295839 times">&check;</span><span class="takenBranch" title="Branch 1 taken 170050 times">&check;</span></td>
2692
    <td align="right" class="linecount coveredLine"><pre>465889</pre></td>
2693
    <td align="left" class="src coveredLine"><pre>                if (type == TM_TYPE_LFR_SCIENCE)    // this is a BP packet, all other types are handled differently</pre></td>
2694
    </tr>
2695

    
2696
    <tr>
2697
    <td align="right" class="lineno"><pre>343</pre></td>
2698
    <td align="right" class="linebranch"></td>
2699
    <td align="right" class="linecount "><pre></pre></td>
2700
    <td align="left" class="src "><pre>                // SET THE SEQUENCE_CNT PARAMETER IN CASE OF BP0 OR BP1 PACKETS</pre></td>
2701
    </tr>
2702

    
2703
    <tr>
2704
    <td align="right" class="lineno"><pre>344</pre></td>
2705
    <td align="right" class="linebranch"></td>
2706
    <td align="right" class="linecount "><pre></pre></td>
2707
    <td align="left" class="src "><pre>                {</pre></td>
2708
    </tr>
2709

    
2710
    <tr>
2711
    <td align="right" class="lineno"><pre>345</pre></td>
2712
    <td align="right" class="linebranch"></td>
2713
    <td align="right" class="linecount coveredLine"><pre>295839</pre></td>
2714
    <td align="left" class="src coveredLine"><pre>                    increment_seq_counter_source_id( (unsigned char*) &amp;incomingData[ PACKET_POS_SEQUENCE_CNT ], sid );</pre></td>
2715
    </tr>
2716

    
2717
    <tr>
2718
    <td align="right" class="lineno"><pre>346</pre></td>
2719
    <td align="right" class="linebranch"></td>
2720
    <td align="right" class="linecount "><pre></pre></td>
2721
    <td align="left" class="src "><pre>                }</pre></td>
2722
    </tr>
2723

    
2724
    <tr>
2725
    <td align="right" class="lineno"><pre>347</pre></td>
2726
    <td align="right" class="linebranch"></td>
2727
    <td align="right" class="linecount "><pre></pre></td>
2728
    <td align="left" class="src "><pre></pre></td>
2729
    </tr>
2730

    
2731
    <tr>
2732
    <td align="right" class="lineno"><pre>348</pre></td>
2733
    <td align="right" class="linebranch"></td>
2734
    <td align="right" class="linecount coveredLine"><pre>465889</pre></td>
2735
    <td align="left" class="src coveredLine"><pre>                status = write( fdSPW, incomingData, size );</pre></td>
2736
    </tr>
2737

    
2738
    <tr>
2739
    <td align="right" class="lineno"><pre>349</pre></td>
2740
    <td align="right" class="linebranch"></td>
2741
    <td align="right" class="linecount "><pre></pre></td>
2742
    <td align="left" class="src "><pre>                if (status == -1){</pre></td>
2743
    </tr>
2744

    
2745
    <tr>
2746
    <td align="right" class="lineno"><pre>350</pre></td>
2747
    <td align="right" class="linebranch"></td>
2748
    <td align="right" class="linecount "><pre></pre></td>
2749
    <td align="left" class="src "><pre>                    PRINTF2("in SEND *** (2.a) ERRNO = %d, size = %d\n", errno, size)</pre></td>
2750
    </tr>
2751

    
2752
    <tr>
2753
    <td align="right" class="lineno"><pre>351</pre></td>
2754
    <td align="right" class="linebranch"></td>
2755
    <td align="right" class="linecount "><pre></pre></td>
2756
    <td align="left" class="src "><pre>                }</pre></td>
2757
    </tr>
2758

    
2759
    <tr>
2760
    <td align="right" class="lineno"><pre>352</pre></td>
2761
    <td align="right" class="linebranch"></td>
2762
    <td align="right" class="linecount "><pre></pre></td>
2763
    <td align="left" class="src "><pre>            }</pre></td>
2764
    </tr>
2765

    
2766
    <tr>
2767
    <td align="right" class="lineno"><pre>353</pre></td>
2768
    <td align="right" class="linebranch"></td>
2769
    <td align="right" class="linecount "><pre></pre></td>
2770
    <td align="left" class="src "><pre>            else // the incoming message is a spw_ioctl_pkt_send structure</pre></td>
2771
    </tr>
2772

    
2773
    <tr>
2774
    <td align="right" class="lineno"><pre>354</pre></td>
2775
    <td align="right" class="linebranch"></td>
2776
    <td align="right" class="linecount "><pre></pre></td>
2777
    <td align="left" class="src "><pre>            {</pre></td>
2778
    </tr>
2779

    
2780
    <tr>
2781
    <td align="right" class="lineno"><pre>355</pre></td>
2782
    <td align="right" class="linebranch"></td>
2783
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
2784
    <td align="left" class="src uncoveredLine"><pre>                spw_ioctl_send = (spw_ioctl_pkt_send*) incomingData;</pre></td>
2785
    </tr>
2786

    
2787
    <tr>
2788
    <td align="right" class="lineno"><pre>356</pre></td>
2789
    <td align="right" class="linebranch"></td>
2790
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
2791
    <td align="left" class="src uncoveredLine"><pre>                status = ioctl( fdSPW, SPACEWIRE_IOCTRL_SEND, spw_ioctl_send );</pre></td>
2792
    </tr>
2793

    
2794
    <tr>
2795
    <td align="right" class="lineno"><pre>357</pre></td>
2796
    <td align="right" class="linebranch"></td>
2797
    <td align="right" class="linecount "><pre></pre></td>
2798
    <td align="left" class="src "><pre>                if (status == -1){</pre></td>
2799
    </tr>
2800

    
2801
    <tr>
2802
    <td align="right" class="lineno"><pre>358</pre></td>
2803
    <td align="right" class="linebranch"></td>
2804
    <td align="right" class="linecount "><pre></pre></td>
2805
    <td align="left" class="src "><pre>                    PRINTF2("in SEND *** (2.b) ERRNO = %d, RTEMS = %d\n", errno, status)</pre></td>
2806
    </tr>
2807

    
2808
    <tr>
2809
    <td align="right" class="lineno"><pre>359</pre></td>
2810
    <td align="right" class="linebranch"></td>
2811
    <td align="right" class="linecount "><pre></pre></td>
2812
    <td align="left" class="src "><pre>                }</pre></td>
2813
    </tr>
2814

    
2815
    <tr>
2816
    <td align="right" class="lineno"><pre>360</pre></td>
2817
    <td align="right" class="linebranch"></td>
2818
    <td align="right" class="linecount "><pre></pre></td>
2819
    <td align="left" class="src "><pre>            }</pre></td>
2820
    </tr>
2821

    
2822
    <tr>
2823
    <td align="right" class="lineno"><pre>361</pre></td>
2824
    <td align="right" class="linebranch"></td>
2825
    <td align="right" class="linecount "><pre></pre></td>
2826
    <td align="left" class="src "><pre>        }</pre></td>
2827
    </tr>
2828

    
2829
    <tr>
2830
    <td align="right" class="lineno"><pre>362</pre></td>
2831
    <td align="right" class="linebranch"></td>
2832
    <td align="right" class="linecount "><pre></pre></td>
2833
    <td align="left" class="src "><pre></pre></td>
2834
    </tr>
2835

    
2836
    <tr>
2837
    <td align="right" class="lineno"><pre>363</pre></td>
2838
    <td align="right" class="linebranch"></td>
2839
    <td align="right" class="linecount coveredLine"><pre>567271</pre></td>
2840
    <td align="left" class="src coveredLine"><pre>        update_queue_max_count( queue_send_id, &amp;hk_lfr_q_sd_fifo_size_max );</pre></td>
2841
    </tr>
2842

    
2843
    <tr>
2844
    <td align="right" class="lineno"><pre>364</pre></td>
2845
    <td align="right" class="linebranch"></td>
2846
    <td align="right" class="linecount "><pre></pre></td>
2847
    <td align="left" class="src "><pre></pre></td>
2848
    </tr>
2849

    
2850
    <tr>
2851
    <td align="right" class="lineno"><pre>365</pre></td>
2852
    <td align="right" class="linebranch"></td>
2853
    <td align="right" class="linecount coveredLine"><pre>567271</pre></td>
2854
    <td align="left" class="src coveredLine"><pre>    }</pre></td>
2855
    </tr>
2856

    
2857
    <tr>
2858
    <td align="right" class="lineno"><pre>366</pre></td>
2859
    <td align="right" class="linebranch"></td>
2860
    <td align="right" class="linecount "><pre></pre></td>
2861
    <td align="left" class="src "><pre>}</pre></td>
2862
    </tr>
2863

    
2864
    <tr>
2865
    <td align="right" class="lineno"><pre>367</pre></td>
2866
    <td align="right" class="linebranch"></td>
2867
    <td align="right" class="linecount "><pre></pre></td>
2868
    <td align="left" class="src "><pre></pre></td>
2869
    </tr>
2870

    
2871
    <tr>
2872
    <td align="right" class="lineno"><pre>368</pre></td>
2873
    <td align="right" class="linebranch"></td>
2874
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
2875
    <td align="left" class="src coveredLine"><pre>rtems_task link_task( rtems_task_argument argument )</pre></td>
2876
    </tr>
2877

    
2878
    <tr>
2879
    <td align="right" class="lineno"><pre>369</pre></td>
2880
    <td align="right" class="linebranch"></td>
2881
    <td align="right" class="linecount "><pre></pre></td>
2882
    <td align="left" class="src "><pre>{</pre></td>
2883
    </tr>
2884

    
2885
    <tr>
2886
    <td align="right" class="lineno"><pre>370</pre></td>
2887
    <td align="right" class="linebranch"></td>
2888
    <td align="right" class="linecount "><pre></pre></td>
2889
    <td align="left" class="src "><pre>    rtems_event_set event_out;</pre></td>
2890
    </tr>
2891

    
2892
    <tr>
2893
    <td align="right" class="lineno"><pre>371</pre></td>
2894
    <td align="right" class="linebranch"></td>
2895
    <td align="right" class="linecount "><pre></pre></td>
2896
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
2897
    </tr>
2898

    
2899
    <tr>
2900
    <td align="right" class="lineno"><pre>372</pre></td>
2901
    <td align="right" class="linebranch"></td>
2902
    <td align="right" class="linecount "><pre></pre></td>
2903
    <td align="left" class="src "><pre>    int linkStatus;</pre></td>
2904
    </tr>
2905

    
2906
    <tr>
2907
    <td align="right" class="lineno"><pre>373</pre></td>
2908
    <td align="right" class="linebranch"></td>
2909
    <td align="right" class="linecount "><pre></pre></td>
2910
    <td align="left" class="src "><pre></pre></td>
2911
    </tr>
2912

    
2913
    <tr>
2914
    <td align="right" class="lineno"><pre>374</pre></td>
2915
    <td align="right" class="linebranch"></td>
2916
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
2917
    <td align="left" class="src coveredLine"><pre>    event_out = EVENT_SETS_NONE_PENDING;</pre></td>
2918
    </tr>
2919

    
2920
    <tr>
2921
    <td align="right" class="lineno"><pre>375</pre></td>
2922
    <td align="right" class="linebranch"></td>
2923
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
2924
    <td align="left" class="src coveredLine"><pre>    linkStatus = 0;</pre></td>
2925
    </tr>
2926

    
2927
    <tr>
2928
    <td align="right" class="lineno"><pre>376</pre></td>
2929
    <td align="right" class="linebranch"></td>
2930
    <td align="right" class="linecount "><pre></pre></td>
2931
    <td align="left" class="src "><pre></pre></td>
2932
    </tr>
2933

    
2934
    <tr>
2935
    <td align="right" class="lineno"><pre>377</pre></td>
2936
    <td align="right" class="linebranch"></td>
2937
    <td align="right" class="linecount "><pre></pre></td>
2938
    <td align="left" class="src "><pre>    BOOT_PRINTF("in LINK ***\n")</pre></td>
2939
    </tr>
2940

    
2941
    <tr>
2942
    <td align="right" class="lineno"><pre>378</pre></td>
2943
    <td align="right" class="linebranch"></td>
2944
    <td align="right" class="linecount "><pre></pre></td>
2945
    <td align="left" class="src "><pre></pre></td>
2946
    </tr>
2947

    
2948
    <tr>
2949
    <td align="right" class="lineno"><pre>379</pre></td>
2950
    <td align="right" class="linebranch"></td>
2951
    <td align="right" class="linecount "><pre></pre></td>
2952
    <td align="left" class="src "><pre>    while(1)</pre></td>
2953
    </tr>
2954

    
2955
    <tr>
2956
    <td align="right" class="lineno"><pre>380</pre></td>
2957
    <td align="right" class="linebranch"></td>
2958
    <td align="right" class="linecount "><pre></pre></td>
2959
    <td align="left" class="src "><pre>    {</pre></td>
2960
    </tr>
2961

    
2962
    <tr>
2963
    <td align="right" class="lineno"><pre>381</pre></td>
2964
    <td align="right" class="linebranch"></td>
2965
    <td align="right" class="linecount "><pre></pre></td>
2966
    <td align="left" class="src "><pre>        // wait for an RTEMS_EVENT</pre></td>
2967
    </tr>
2968

    
2969
    <tr>
2970
    <td align="right" class="lineno"><pre>382</pre></td>
2971
    <td align="right" class="linebranch"></td>
2972
    <td align="right" class="linecount coveredLine"><pre>92</pre></td>
2973
    <td align="left" class="src coveredLine"><pre>        rtems_event_receive( RTEMS_EVENT_0,</pre></td>
2974
    </tr>
2975

    
2976
    <tr>
2977
    <td align="right" class="lineno"><pre>383</pre></td>
2978
    <td align="right" class="linebranch"></td>
2979
    <td align="right" class="linecount "><pre></pre></td>
2980
    <td align="left" class="src "><pre>                            RTEMS_WAIT | RTEMS_EVENT_ANY, RTEMS_NO_TIMEOUT, &amp;event_out);</pre></td>
2981
    </tr>
2982

    
2983
    <tr>
2984
    <td align="right" class="lineno"><pre>384</pre></td>
2985
    <td align="right" class="linebranch"></td>
2986
    <td align="right" class="linecount "><pre></pre></td>
2987
    <td align="left" class="src "><pre>        PRINTF("in LINK *** wait for the link\n")</pre></td>
2988
    </tr>
2989

    
2990
    <tr>
2991
    <td align="right" class="lineno"><pre>385</pre></td>
2992
    <td align="right" class="linebranch"></td>
2993
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
2994
    <td align="left" class="src coveredLine"><pre>        status = ioctl(fdSPW, SPACEWIRE_IOCTRL_GET_LINK_STATUS, &amp;linkStatus);       // get the link status</pre></td>
2995
    </tr>
2996

    
2997
    <tr>
2998
    <td align="right" class="lineno"><pre>386</pre></td>
2999
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 115 times">&check;</span><span class="takenBranch" title="Branch 1 taken 5 times">&check;</span></td>
3000
    <td align="right" class="linecount coveredLine"><pre>125</pre></td>
3001
    <td align="left" class="src coveredLine"><pre>        while( linkStatus != SPW_LINK_OK)                                           // wait for the link</pre></td>
3002
    </tr>
3003

    
3004
    <tr>
3005
    <td align="right" class="lineno"><pre>387</pre></td>
3006
    <td align="right" class="linebranch"></td>
3007
    <td align="right" class="linecount "><pre></pre></td>
3008
    <td align="left" class="src "><pre>        {</pre></td>
3009
    </tr>
3010

    
3011
    <tr>
3012
    <td align="right" class="lineno"><pre>388</pre></td>
3013
    <td align="right" class="linebranch"></td>
3014
    <td align="right" class="linecount coveredLine"><pre>115</pre></td>
3015
    <td align="left" class="src coveredLine"><pre>            status = rtems_task_wake_after( SPW_LINK_WAIT );                        // monitor the link each 100ms</pre></td>
3016
    </tr>
3017

    
3018
    <tr>
3019
    <td align="right" class="lineno"><pre>389</pre></td>
3020
    <td align="right" class="linebranch"></td>
3021
    <td align="right" class="linecount coveredLine"><pre>115</pre></td>
3022
    <td align="left" class="src coveredLine"><pre>            status = ioctl(fdSPW, SPACEWIRE_IOCTRL_GET_LINK_STATUS, &amp;linkStatus);   // get the link status</pre></td>
3023
    </tr>
3024

    
3025
    <tr>
3026
    <td align="right" class="lineno"><pre>390</pre></td>
3027
    <td align="right" class="linebranch"></td>
3028
    <td align="right" class="linecount coveredLine"><pre>115</pre></td>
3029
    <td align="left" class="src coveredLine"><pre>            watchdog_reload();</pre></td>
3030
    </tr>
3031

    
3032
    <tr>
3033
    <td align="right" class="lineno"><pre>391</pre></td>
3034
    <td align="right" class="linebranch"></td>
3035
    <td align="right" class="linecount "><pre></pre></td>
3036
    <td align="left" class="src "><pre>        }</pre></td>
3037
    </tr>
3038

    
3039
    <tr>
3040
    <td align="right" class="lineno"><pre>392</pre></td>
3041
    <td align="right" class="linebranch"></td>
3042
    <td align="right" class="linecount "><pre></pre></td>
3043
    <td align="left" class="src "><pre></pre></td>
3044
    </tr>
3045

    
3046
    <tr>
3047
    <td align="right" class="lineno"><pre>393</pre></td>
3048
    <td align="right" class="linebranch"></td>
3049
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
3050
    <td align="left" class="src coveredLine"><pre>        spacewire_read_statistics();</pre></td>
3051
    </tr>
3052

    
3053
    <tr>
3054
    <td align="right" class="lineno"><pre>394</pre></td>
3055
    <td align="right" class="linebranch"></td>
3056
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
3057
    <td align="left" class="src coveredLine"><pre>        status = spacewire_stop_and_start_link( fdSPW );</pre></td>
3058
    </tr>
3059

    
3060
    <tr>
3061
    <td align="right" class="lineno"><pre>395</pre></td>
3062
    <td align="right" class="linebranch"></td>
3063
    <td align="right" class="linecount "><pre></pre></td>
3064
    <td align="left" class="src "><pre></pre></td>
3065
    </tr>
3066

    
3067
    <tr>
3068
    <td align="right" class="lineno"><pre>396</pre></td>
3069
    <td align="right" class="linebranch"></td>
3070
    <td align="right" class="linecount "><pre></pre></td>
3071
    <td align="left" class="src "><pre>        if (status != RTEMS_SUCCESSFUL)</pre></td>
3072
    </tr>
3073

    
3074
    <tr>
3075
    <td align="right" class="lineno"><pre>397</pre></td>
3076
    <td align="right" class="linebranch"></td>
3077
    <td align="right" class="linecount "><pre></pre></td>
3078
    <td align="left" class="src "><pre>        {</pre></td>
3079
    </tr>
3080

    
3081
    <tr>
3082
    <td align="right" class="lineno"><pre>398</pre></td>
3083
    <td align="right" class="linebranch"></td>
3084
    <td align="right" class="linecount "><pre></pre></td>
3085
    <td align="left" class="src "><pre>            PRINTF1("in LINK *** ERR link not started %d\n", status)</pre></td>
3086
    </tr>
3087

    
3088
    <tr>
3089
    <td align="right" class="lineno"><pre>399</pre></td>
3090
    <td align="right" class="linebranch"></td>
3091
    <td align="right" class="linecount "><pre></pre></td>
3092
    <td align="left" class="src "><pre>        }</pre></td>
3093
    </tr>
3094

    
3095
    <tr>
3096
    <td align="right" class="lineno"><pre>400</pre></td>
3097
    <td align="right" class="linebranch"></td>
3098
    <td align="right" class="linecount "><pre></pre></td>
3099
    <td align="left" class="src "><pre>        else</pre></td>
3100
    </tr>
3101

    
3102
    <tr>
3103
    <td align="right" class="lineno"><pre>401</pre></td>
3104
    <td align="right" class="linebranch"></td>
3105
    <td align="right" class="linecount "><pre></pre></td>
3106
    <td align="left" class="src "><pre>        {</pre></td>
3107
    </tr>
3108

    
3109
    <tr>
3110
    <td align="right" class="lineno"><pre>402</pre></td>
3111
    <td align="right" class="linebranch"></td>
3112
    <td align="right" class="linecount "><pre></pre></td>
3113
    <td align="left" class="src "><pre>            PRINTF("in LINK *** OK  link started\n")</pre></td>
3114
    </tr>
3115

    
3116
    <tr>
3117
    <td align="right" class="lineno"><pre>403</pre></td>
3118
    <td align="right" class="linebranch"></td>
3119
    <td align="right" class="linecount "><pre></pre></td>
3120
    <td align="left" class="src "><pre>        }</pre></td>
3121
    </tr>
3122

    
3123
    <tr>
3124
    <td align="right" class="lineno"><pre>404</pre></td>
3125
    <td align="right" class="linebranch"></td>
3126
    <td align="right" class="linecount "><pre></pre></td>
3127
    <td align="left" class="src "><pre></pre></td>
3128
    </tr>
3129

    
3130
    <tr>
3131
    <td align="right" class="lineno"><pre>405</pre></td>
3132
    <td align="right" class="linebranch"></td>
3133
    <td align="right" class="linecount "><pre></pre></td>
3134
    <td align="left" class="src "><pre>        // restart the SPIQ task</pre></td>
3135
    </tr>
3136

    
3137
    <tr>
3138
    <td align="right" class="lineno"><pre>406</pre></td>
3139
    <td align="right" class="linebranch"></td>
3140
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
3141
    <td align="left" class="src coveredLine"><pre>        status = rtems_task_restart( Task_id[TASKID_SPIQ], 1 );</pre></td>
3142
    </tr>
3143

    
3144
    <tr>
3145
    <td align="right" class="lineno"><pre>407</pre></td>
3146
    <td align="right" class="linebranch"></td>
3147
    <td align="right" class="linecount "><pre></pre></td>
3148
    <td align="left" class="src "><pre>        if ( status != RTEMS_SUCCESSFUL ) {</pre></td>
3149
    </tr>
3150

    
3151
    <tr>
3152
    <td align="right" class="lineno"><pre>408</pre></td>
3153
    <td align="right" class="linebranch"></td>
3154
    <td align="right" class="linecount "><pre></pre></td>
3155
    <td align="left" class="src "><pre>            PRINTF("in SPIQ *** ERR restarting SPIQ Task\n")</pre></td>
3156
    </tr>
3157

    
3158
    <tr>
3159
    <td align="right" class="lineno"><pre>409</pre></td>
3160
    <td align="right" class="linebranch"></td>
3161
    <td align="right" class="linecount "><pre></pre></td>
3162
    <td align="left" class="src "><pre>        }</pre></td>
3163
    </tr>
3164

    
3165
    <tr>
3166
    <td align="right" class="lineno"><pre>410</pre></td>
3167
    <td align="right" class="linebranch"></td>
3168
    <td align="right" class="linecount "><pre></pre></td>
3169
    <td align="left" class="src "><pre></pre></td>
3170
    </tr>
3171

    
3172
    <tr>
3173
    <td align="right" class="lineno"><pre>411</pre></td>
3174
    <td align="right" class="linebranch"></td>
3175
    <td align="right" class="linecount "><pre></pre></td>
3176
    <td align="left" class="src "><pre>        // restart RECV and SEND</pre></td>
3177
    </tr>
3178

    
3179
    <tr>
3180
    <td align="right" class="lineno"><pre>412</pre></td>
3181
    <td align="right" class="linebranch"></td>
3182
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
3183
    <td align="left" class="src coveredLine"><pre>        status = rtems_task_restart( Task_id[ TASKID_SEND ], 1 );</pre></td>
3184
    </tr>
3185

    
3186
    <tr>
3187
    <td align="right" class="lineno"><pre>413</pre></td>
3188
    <td align="right" class="linebranch"></td>
3189
    <td align="right" class="linecount "><pre></pre></td>
3190
    <td align="left" class="src "><pre>        if ( status != RTEMS_SUCCESSFUL ) {</pre></td>
3191
    </tr>
3192

    
3193
    <tr>
3194
    <td align="right" class="lineno"><pre>414</pre></td>
3195
    <td align="right" class="linebranch"></td>
3196
    <td align="right" class="linecount "><pre></pre></td>
3197
    <td align="left" class="src "><pre>            PRINTF("in SPIQ *** ERR restarting SEND Task\n")</pre></td>
3198
    </tr>
3199

    
3200
    <tr>
3201
    <td align="right" class="lineno"><pre>415</pre></td>
3202
    <td align="right" class="linebranch"></td>
3203
    <td align="right" class="linecount "><pre></pre></td>
3204
    <td align="left" class="src "><pre>        }</pre></td>
3205
    </tr>
3206

    
3207
    <tr>
3208
    <td align="right" class="lineno"><pre>416</pre></td>
3209
    <td align="right" class="linebranch"></td>
3210
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
3211
    <td align="left" class="src coveredLine"><pre>        status = rtems_task_restart( Task_id[ TASKID_RECV ], 1 );</pre></td>
3212
    </tr>
3213

    
3214
    <tr>
3215
    <td align="right" class="lineno"><pre>417</pre></td>
3216
    <td align="right" class="linebranch"></td>
3217
    <td align="right" class="linecount "><pre></pre></td>
3218
    <td align="left" class="src "><pre>        if ( status != RTEMS_SUCCESSFUL ) {</pre></td>
3219
    </tr>
3220

    
3221
    <tr>
3222
    <td align="right" class="lineno"><pre>418</pre></td>
3223
    <td align="right" class="linebranch"></td>
3224
    <td align="right" class="linecount "><pre></pre></td>
3225
    <td align="left" class="src "><pre>            PRINTF("in SPIQ *** ERR restarting RECV Task\n")</pre></td>
3226
    </tr>
3227

    
3228
    <tr>
3229
    <td align="right" class="lineno"><pre>419</pre></td>
3230
    <td align="right" class="linebranch"></td>
3231
    <td align="right" class="linecount "><pre></pre></td>
3232
    <td align="left" class="src "><pre>        }</pre></td>
3233
    </tr>
3234

    
3235
    <tr>
3236
    <td align="right" class="lineno"><pre>420</pre></td>
3237
    <td align="right" class="linebranch"></td>
3238
    <td align="right" class="linecount "><pre></pre></td>
3239
    <td align="left" class="src "><pre>    }</pre></td>
3240
    </tr>
3241

    
3242
    <tr>
3243
    <td align="right" class="lineno"><pre>421</pre></td>
3244
    <td align="right" class="linebranch"></td>
3245
    <td align="right" class="linecount "><pre></pre></td>
3246
    <td align="left" class="src "><pre>}</pre></td>
3247
    </tr>
3248

    
3249
    <tr>
3250
    <td align="right" class="lineno"><pre>422</pre></td>
3251
    <td align="right" class="linebranch"></td>
3252
    <td align="right" class="linecount "><pre></pre></td>
3253
    <td align="left" class="src "><pre></pre></td>
3254
    </tr>
3255

    
3256
    <tr>
3257
    <td align="right" class="lineno"><pre>423</pre></td>
3258
    <td align="right" class="linebranch"></td>
3259
    <td align="right" class="linecount "><pre></pre></td>
3260
    <td align="left" class="src "><pre>//****************</pre></td>
3261
    </tr>
3262

    
3263
    <tr>
3264
    <td align="right" class="lineno"><pre>424</pre></td>
3265
    <td align="right" class="linebranch"></td>
3266
    <td align="right" class="linecount "><pre></pre></td>
3267
    <td align="left" class="src "><pre>// OTHER FUNCTIONS</pre></td>
3268
    </tr>
3269

    
3270
    <tr>
3271
    <td align="right" class="lineno"><pre>425</pre></td>
3272
    <td align="right" class="linebranch"></td>
3273
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3274
    <td align="left" class="src coveredLine"><pre>int spacewire_open_link( void )  // by default, the driver resets the core: [SPW_CTRL_WRITE(pDev, SPW_CTRL_RESET);]</pre></td>
3275
    </tr>
3276

    
3277
    <tr>
3278
    <td align="right" class="lineno"><pre>426</pre></td>
3279
    <td align="right" class="linebranch"></td>
3280
    <td align="right" class="linecount "><pre></pre></td>
3281
    <td align="left" class="src "><pre>{</pre></td>
3282
    </tr>
3283

    
3284
    <tr>
3285
    <td align="right" class="lineno"><pre>427</pre></td>
3286
    <td align="right" class="linebranch"></td>
3287
    <td align="right" class="linecount "><pre></pre></td>
3288
    <td align="left" class="src "><pre>    /** This function opens the SpaceWire link.</pre></td>
3289
    </tr>
3290

    
3291
    <tr>
3292
    <td align="right" class="lineno"><pre>428</pre></td>
3293
    <td align="right" class="linebranch"></td>
3294
    <td align="right" class="linecount "><pre></pre></td>
3295
    <td align="left" class="src "><pre>     *</pre></td>
3296
    </tr>
3297

    
3298
    <tr>
3299
    <td align="right" class="lineno"><pre>429</pre></td>
3300
    <td align="right" class="linebranch"></td>
3301
    <td align="right" class="linecount "><pre></pre></td>
3302
    <td align="left" class="src "><pre>     * @return a valid file descriptor in case of success, -1 in case of a failure</pre></td>
3303
    </tr>
3304

    
3305
    <tr>
3306
    <td align="right" class="lineno"><pre>430</pre></td>
3307
    <td align="right" class="linebranch"></td>
3308
    <td align="right" class="linecount "><pre></pre></td>
3309
    <td align="left" class="src "><pre>     *</pre></td>
3310
    </tr>
3311

    
3312
    <tr>
3313
    <td align="right" class="lineno"><pre>431</pre></td>
3314
    <td align="right" class="linebranch"></td>
3315
    <td align="right" class="linecount "><pre></pre></td>
3316
    <td align="left" class="src "><pre>     */</pre></td>
3317
    </tr>
3318

    
3319
    <tr>
3320
    <td align="right" class="lineno"><pre>432</pre></td>
3321
    <td align="right" class="linebranch"></td>
3322
    <td align="right" class="linecount "><pre></pre></td>
3323
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
3324
    </tr>
3325

    
3326
    <tr>
3327
    <td align="right" class="lineno"><pre>433</pre></td>
3328
    <td align="right" class="linebranch"></td>
3329
    <td align="right" class="linecount "><pre></pre></td>
3330
    <td align="left" class="src "><pre></pre></td>
3331
    </tr>
3332

    
3333
    <tr>
3334
    <td align="right" class="lineno"><pre>434</pre></td>
3335
    <td align="right" class="linebranch"></td>
3336
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3337
    <td align="left" class="src coveredLine"><pre>    status = RTEMS_SUCCESSFUL;</pre></td>
3338
    </tr>
3339

    
3340
    <tr>
3341
    <td align="right" class="lineno"><pre>435</pre></td>
3342
    <td align="right" class="linebranch"></td>
3343
    <td align="right" class="linecount "><pre></pre></td>
3344
    <td align="left" class="src "><pre></pre></td>
3345
    </tr>
3346

    
3347
    <tr>
3348
    <td align="right" class="lineno"><pre>436</pre></td>
3349
    <td align="right" class="linebranch"></td>
3350
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3351
    <td align="left" class="src coveredLine"><pre>    fdSPW = open(GRSPW_DEVICE_NAME, O_RDWR); // open the device. the open call resets the hardware</pre></td>
3352
    </tr>
3353

    
3354
    <tr>
3355
    <td align="right" class="lineno"><pre>437</pre></td>
3356
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 87 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
3357
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3358
    <td align="left" class="src coveredLine"><pre>    if ( fdSPW &lt; 0 ) {</pre></td>
3359
    </tr>
3360

    
3361
    <tr>
3362
    <td align="right" class="lineno"><pre>438</pre></td>
3363
    <td align="right" class="linebranch"></td>
3364
    <td align="right" class="linecount "><pre></pre></td>
3365
    <td align="left" class="src "><pre>        PRINTF1("ERR *** in configure_spw_link *** error opening "GRSPW_DEVICE_NAME" with ERR %d\n", errno)</pre></td>
3366
    </tr>
3367

    
3368
    <tr>
3369
    <td align="right" class="lineno"><pre>439</pre></td>
3370
    <td align="right" class="linebranch"></td>
3371
    <td align="right" class="linecount "><pre></pre></td>
3372
    <td align="left" class="src "><pre>    }</pre></td>
3373
    </tr>
3374

    
3375
    <tr>
3376
    <td align="right" class="lineno"><pre>440</pre></td>
3377
    <td align="right" class="linebranch"></td>
3378
    <td align="right" class="linecount "><pre></pre></td>
3379
    <td align="left" class="src "><pre>    else</pre></td>
3380
    </tr>
3381

    
3382
    <tr>
3383
    <td align="right" class="lineno"><pre>441</pre></td>
3384
    <td align="right" class="linebranch"></td>
3385
    <td align="right" class="linecount "><pre></pre></td>
3386
    <td align="left" class="src "><pre>    {</pre></td>
3387
    </tr>
3388

    
3389
    <tr>
3390
    <td align="right" class="lineno"><pre>442</pre></td>
3391
    <td align="right" class="linebranch"></td>
3392
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3393
    <td align="left" class="src coveredLine"><pre>        status = RTEMS_SUCCESSFUL;</pre></td>
3394
    </tr>
3395

    
3396
    <tr>
3397
    <td align="right" class="lineno"><pre>443</pre></td>
3398
    <td align="right" class="linebranch"></td>
3399
    <td align="right" class="linecount "><pre></pre></td>
3400
    <td align="left" class="src "><pre>    }</pre></td>
3401
    </tr>
3402

    
3403
    <tr>
3404
    <td align="right" class="lineno"><pre>444</pre></td>
3405
    <td align="right" class="linebranch"></td>
3406
    <td align="right" class="linecount "><pre></pre></td>
3407
    <td align="left" class="src "><pre></pre></td>
3408
    </tr>
3409

    
3410
    <tr>
3411
    <td align="right" class="lineno"><pre>445</pre></td>
3412
    <td align="right" class="linebranch"></td>
3413
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3414
    <td align="left" class="src coveredLine"><pre>    return status;</pre></td>
3415
    </tr>
3416

    
3417
    <tr>
3418
    <td align="right" class="lineno"><pre>446</pre></td>
3419
    <td align="right" class="linebranch"></td>
3420
    <td align="right" class="linecount "><pre></pre></td>
3421
    <td align="left" class="src "><pre>}</pre></td>
3422
    </tr>
3423

    
3424
    <tr>
3425
    <td align="right" class="lineno"><pre>447</pre></td>
3426
    <td align="right" class="linebranch"></td>
3427
    <td align="right" class="linecount "><pre></pre></td>
3428
    <td align="left" class="src "><pre></pre></td>
3429
    </tr>
3430

    
3431
    <tr>
3432
    <td align="right" class="lineno"><pre>448</pre></td>
3433
    <td align="right" class="linebranch"></td>
3434
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3435
    <td align="left" class="src coveredLine"><pre>int spacewire_start_link( int fd )</pre></td>
3436
    </tr>
3437

    
3438
    <tr>
3439
    <td align="right" class="lineno"><pre>449</pre></td>
3440
    <td align="right" class="linebranch"></td>
3441
    <td align="right" class="linecount "><pre></pre></td>
3442
    <td align="left" class="src "><pre>{</pre></td>
3443
    </tr>
3444

    
3445
    <tr>
3446
    <td align="right" class="lineno"><pre>450</pre></td>
3447
    <td align="right" class="linebranch"></td>
3448
    <td align="right" class="linecount "><pre></pre></td>
3449
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
3450
    </tr>
3451

    
3452
    <tr>
3453
    <td align="right" class="lineno"><pre>451</pre></td>
3454
    <td align="right" class="linebranch"></td>
3455
    <td align="right" class="linecount "><pre></pre></td>
3456
    <td align="left" class="src "><pre></pre></td>
3457
    </tr>
3458

    
3459
    <tr>
3460
    <td align="right" class="lineno"><pre>452</pre></td>
3461
    <td align="right" class="linebranch"></td>
3462
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3463
    <td align="left" class="src coveredLine"><pre>    status = ioctl( fd, SPACEWIRE_IOCTRL_START, -1); // returns successfuly if the link is started</pre></td>
3464
    </tr>
3465

    
3466
    <tr>
3467
    <td align="right" class="lineno"><pre>453</pre></td>
3468
    <td align="right" class="linebranch"></td>
3469
    <td align="right" class="linecount "><pre></pre></td>
3470
    <td align="left" class="src "><pre>                                                        // -1 default hardcoded driver timeout</pre></td>
3471
    </tr>
3472

    
3473
    <tr>
3474
    <td align="right" class="lineno"><pre>454</pre></td>
3475
    <td align="right" class="linebranch"></td>
3476
    <td align="right" class="linecount "><pre></pre></td>
3477
    <td align="left" class="src "><pre></pre></td>
3478
    </tr>
3479

    
3480
    <tr>
3481
    <td align="right" class="lineno"><pre>455</pre></td>
3482
    <td align="right" class="linebranch"></td>
3483
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3484
    <td align="left" class="src coveredLine"><pre>    return status;</pre></td>
3485
    </tr>
3486

    
3487
    <tr>
3488
    <td align="right" class="lineno"><pre>456</pre></td>
3489
    <td align="right" class="linebranch"></td>
3490
    <td align="right" class="linecount "><pre></pre></td>
3491
    <td align="left" class="src "><pre>}</pre></td>
3492
    </tr>
3493

    
3494
    <tr>
3495
    <td align="right" class="lineno"><pre>457</pre></td>
3496
    <td align="right" class="linebranch"></td>
3497
    <td align="right" class="linecount "><pre></pre></td>
3498
    <td align="left" class="src "><pre></pre></td>
3499
    </tr>
3500

    
3501
    <tr>
3502
    <td align="right" class="lineno"><pre>458</pre></td>
3503
    <td align="right" class="linebranch"></td>
3504
    <td align="right" class="linecount coveredLine"><pre>22</pre></td>
3505
    <td align="left" class="src coveredLine"><pre>int spacewire_stop_and_start_link( int fd )</pre></td>
3506
    </tr>
3507

    
3508
    <tr>
3509
    <td align="right" class="lineno"><pre>459</pre></td>
3510
    <td align="right" class="linebranch"></td>
3511
    <td align="right" class="linecount "><pre></pre></td>
3512
    <td align="left" class="src "><pre>{</pre></td>
3513
    </tr>
3514

    
3515
    <tr>
3516
    <td align="right" class="lineno"><pre>460</pre></td>
3517
    <td align="right" class="linebranch"></td>
3518
    <td align="right" class="linecount "><pre></pre></td>
3519
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
3520
    </tr>
3521

    
3522
    <tr>
3523
    <td align="right" class="lineno"><pre>461</pre></td>
3524
    <td align="right" class="linebranch"></td>
3525
    <td align="right" class="linecount "><pre></pre></td>
3526
    <td align="left" class="src "><pre></pre></td>
3527
    </tr>
3528

    
3529
    <tr>
3530
    <td align="right" class="lineno"><pre>462</pre></td>
3531
    <td align="right" class="linebranch"></td>
3532
    <td align="right" class="linecount coveredLine"><pre>22</pre></td>
3533
    <td align="left" class="src coveredLine"><pre>    status = ioctl( fd, SPACEWIRE_IOCTRL_STOP);      // start fails if link pDev->running != 0</pre></td>
3534
    </tr>
3535

    
3536
    <tr>
3537
    <td align="right" class="lineno"><pre>463</pre></td>
3538
    <td align="right" class="linebranch"></td>
3539
    <td align="right" class="linecount coveredLine"><pre>22</pre></td>
3540
    <td align="left" class="src coveredLine"><pre>    status = ioctl( fd, SPACEWIRE_IOCTRL_START, -1); // returns successfuly if the link is started</pre></td>
3541
    </tr>
3542

    
3543
    <tr>
3544
    <td align="right" class="lineno"><pre>464</pre></td>
3545
    <td align="right" class="linebranch"></td>
3546
    <td align="right" class="linecount "><pre></pre></td>
3547
    <td align="left" class="src "><pre>                                                        // -1 default hardcoded driver timeout</pre></td>
3548
    </tr>
3549

    
3550
    <tr>
3551
    <td align="right" class="lineno"><pre>465</pre></td>
3552
    <td align="right" class="linebranch"></td>
3553
    <td align="right" class="linecount "><pre></pre></td>
3554
    <td align="left" class="src "><pre></pre></td>
3555
    </tr>
3556

    
3557
    <tr>
3558
    <td align="right" class="lineno"><pre>466</pre></td>
3559
    <td align="right" class="linebranch"></td>
3560
    <td align="right" class="linecount coveredLine"><pre>22</pre></td>
3561
    <td align="left" class="src coveredLine"><pre>    return status;</pre></td>
3562
    </tr>
3563

    
3564
    <tr>
3565
    <td align="right" class="lineno"><pre>467</pre></td>
3566
    <td align="right" class="linebranch"></td>
3567
    <td align="right" class="linecount "><pre></pre></td>
3568
    <td align="left" class="src "><pre>}</pre></td>
3569
    </tr>
3570

    
3571
    <tr>
3572
    <td align="right" class="lineno"><pre>468</pre></td>
3573
    <td align="right" class="linebranch"></td>
3574
    <td align="right" class="linecount "><pre></pre></td>
3575
    <td align="left" class="src "><pre></pre></td>
3576
    </tr>
3577

    
3578
    <tr>
3579
    <td align="right" class="lineno"><pre>469</pre></td>
3580
    <td align="right" class="linebranch"></td>
3581
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3582
    <td align="left" class="src coveredLine"><pre>int spacewire_configure_link( int fd )</pre></td>
3583
    </tr>
3584

    
3585
    <tr>
3586
    <td align="right" class="lineno"><pre>470</pre></td>
3587
    <td align="right" class="linebranch"></td>
3588
    <td align="right" class="linecount "><pre></pre></td>
3589
    <td align="left" class="src "><pre>{</pre></td>
3590
    </tr>
3591

    
3592
    <tr>
3593
    <td align="right" class="lineno"><pre>471</pre></td>
3594
    <td align="right" class="linebranch"></td>
3595
    <td align="right" class="linecount "><pre></pre></td>
3596
    <td align="left" class="src "><pre>    /** This function configures the SpaceWire link.</pre></td>
3597
    </tr>
3598

    
3599
    <tr>
3600
    <td align="right" class="lineno"><pre>472</pre></td>
3601
    <td align="right" class="linebranch"></td>
3602
    <td align="right" class="linecount "><pre></pre></td>
3603
    <td align="left" class="src "><pre>     *</pre></td>
3604
    </tr>
3605

    
3606
    <tr>
3607
    <td align="right" class="lineno"><pre>473</pre></td>
3608
    <td align="right" class="linebranch"></td>
3609
    <td align="right" class="linecount "><pre></pre></td>
3610
    <td align="left" class="src "><pre>     * @return GR-RTEMS-DRIVER directive status codes:</pre></td>
3611
    </tr>
3612

    
3613
    <tr>
3614
    <td align="right" class="lineno"><pre>474</pre></td>
3615
    <td align="right" class="linebranch"></td>
3616
    <td align="right" class="linecount "><pre></pre></td>
3617
    <td align="left" class="src "><pre>     * - 22  EINVAL - Null pointer or an out of range value was given as the argument.</pre></td>
3618
    </tr>
3619

    
3620
    <tr>
3621
    <td align="right" class="lineno"><pre>475</pre></td>
3622
    <td align="right" class="linebranch"></td>
3623
    <td align="right" class="linecount "><pre></pre></td>
3624
    <td align="left" class="src "><pre>     * - 16  EBUSY - Only used for SEND. Returned when no descriptors are avialble in non-blocking mode.</pre></td>
3625
    </tr>
3626

    
3627
    <tr>
3628
    <td align="right" class="lineno"><pre>476</pre></td>
3629
    <td align="right" class="linebranch"></td>
3630
    <td align="right" class="linecount "><pre></pre></td>
3631
    <td align="left" class="src "><pre>     * - 88  ENOSYS - Returned for SET_DESTKEY if RMAP command handler is not available or if a non-implemented call is used.</pre></td>
3632
    </tr>
3633

    
3634
    <tr>
3635
    <td align="right" class="lineno"><pre>477</pre></td>
3636
    <td align="right" class="linebranch"></td>
3637
    <td align="right" class="linecount "><pre></pre></td>
3638
    <td align="left" class="src "><pre>     * - 116 ETIMEDOUT - REturned for SET_PACKET_SIZE and START if the link could not be brought up.</pre></td>
3639
    </tr>
3640

    
3641
    <tr>
3642
    <td align="right" class="lineno"><pre>478</pre></td>
3643
    <td align="right" class="linebranch"></td>
3644
    <td align="right" class="linecount "><pre></pre></td>
3645
    <td align="left" class="src "><pre>     * - 12  ENOMEM - Returned for SET_PACKETSIZE if it was unable to allocate the new buffers.</pre></td>
3646
    </tr>
3647

    
3648
    <tr>
3649
    <td align="right" class="lineno"><pre>479</pre></td>
3650
    <td align="right" class="linebranch"></td>
3651
    <td align="right" class="linecount "><pre></pre></td>
3652
    <td align="left" class="src "><pre>     * - 5   EIO - Error when writing to grswp hardware registers.</pre></td>
3653
    </tr>
3654

    
3655
    <tr>
3656
    <td align="right" class="lineno"><pre>480</pre></td>
3657
    <td align="right" class="linebranch"></td>
3658
    <td align="right" class="linecount "><pre></pre></td>
3659
    <td align="left" class="src "><pre>     * - 2   ENOENT - No such file or directory</pre></td>
3660
    </tr>
3661

    
3662
    <tr>
3663
    <td align="right" class="lineno"><pre>481</pre></td>
3664
    <td align="right" class="linebranch"></td>
3665
    <td align="right" class="linecount "><pre></pre></td>
3666
    <td align="left" class="src "><pre>     */</pre></td>
3667
    </tr>
3668

    
3669
    <tr>
3670
    <td align="right" class="lineno"><pre>482</pre></td>
3671
    <td align="right" class="linebranch"></td>
3672
    <td align="right" class="linecount "><pre></pre></td>
3673
    <td align="left" class="src "><pre></pre></td>
3674
    </tr>
3675

    
3676
    <tr>
3677
    <td align="right" class="lineno"><pre>483</pre></td>
3678
    <td align="right" class="linebranch"></td>
3679
    <td align="right" class="linecount "><pre></pre></td>
3680
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
3681
    </tr>
3682

    
3683
    <tr>
3684
    <td align="right" class="lineno"><pre>484</pre></td>
3685
    <td align="right" class="linebranch"></td>
3686
    <td align="right" class="linecount "><pre></pre></td>
3687
    <td align="left" class="src "><pre></pre></td>
3688
    </tr>
3689

    
3690
    <tr>
3691
    <td align="right" class="lineno"><pre>485</pre></td>
3692
    <td align="right" class="linebranch"></td>
3693
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3694
    <td align="left" class="src coveredLine"><pre>    spacewire_set_NP(1, REGS_ADDR_GRSPW); // [N]o [P]ort force</pre></td>
3695
    </tr>
3696

    
3697
    <tr>
3698
    <td align="right" class="lineno"><pre>486</pre></td>
3699
    <td align="right" class="linebranch"></td>
3700
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3701
    <td align="left" class="src coveredLine"><pre>    spacewire_set_RE(1, REGS_ADDR_GRSPW); // [R]MAP [E]nable, the dedicated call seems to  break the no port force configuration</pre></td>
3702
    </tr>
3703

    
3704
    <tr>
3705
    <td align="right" class="lineno"><pre>487</pre></td>
3706
    <td align="right" class="linebranch"></td>
3707
    <td align="right" class="linecount "><pre></pre></td>
3708
    <td align="left" class="src "><pre>    spw_ioctl_packetsize packetsize;</pre></td>
3709
    </tr>
3710

    
3711
    <tr>
3712
    <td align="right" class="lineno"><pre>488</pre></td>
3713
    <td align="right" class="linebranch"></td>
3714
    <td align="right" class="linecount "><pre></pre></td>
3715
    <td align="left" class="src "><pre></pre></td>
3716
    </tr>
3717

    
3718
    <tr>
3719
    <td align="right" class="lineno"><pre>489</pre></td>
3720
    <td align="right" class="linebranch"></td>
3721
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3722
    <td align="left" class="src coveredLine"><pre>    packetsize.rxsize   = SPW_RXSIZE;</pre></td>
3723
    </tr>
3724

    
3725
    <tr>
3726
    <td align="right" class="lineno"><pre>490</pre></td>
3727
    <td align="right" class="linebranch"></td>
3728
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3729
    <td align="left" class="src coveredLine"><pre>    packetsize.txdsize  = SPW_TXDSIZE;</pre></td>
3730
    </tr>
3731

    
3732
    <tr>
3733
    <td align="right" class="lineno"><pre>491</pre></td>
3734
    <td align="right" class="linebranch"></td>
3735
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3736
    <td align="left" class="src coveredLine"><pre>    packetsize.txhsize  = SPW_TXHSIZE;</pre></td>
3737
    </tr>
3738

    
3739
    <tr>
3740
    <td align="right" class="lineno"><pre>492</pre></td>
3741
    <td align="right" class="linebranch"></td>
3742
    <td align="right" class="linecount "><pre></pre></td>
3743
    <td align="left" class="src "><pre></pre></td>
3744
    </tr>
3745

    
3746
    <tr>
3747
    <td align="right" class="lineno"><pre>493</pre></td>
3748
    <td align="right" class="linebranch"></td>
3749
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3750
    <td align="left" class="src coveredLine"><pre>    status = ioctl(fd, SPACEWIRE_IOCTRL_SET_RXBLOCK, 1);              // sets the blocking mode for reception</pre></td>
3751
    </tr>
3752

    
3753
    <tr>
3754
    <td align="right" class="lineno"><pre>494</pre></td>
3755
    <td align="right" class="linebranch"></td>
3756
    <td align="right" class="linecount "><pre></pre></td>
3757
    <td align="left" class="src "><pre>    if (status!=RTEMS_SUCCESSFUL) {</pre></td>
3758
    </tr>
3759

    
3760
    <tr>
3761
    <td align="right" class="lineno"><pre>495</pre></td>
3762
    <td align="right" class="linebranch"></td>
3763
    <td align="right" class="linecount "><pre></pre></td>
3764
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** Error SPACEWIRE_IOCTRL_SET_RXBLOCK\n")</pre></td>
3765
    </tr>
3766

    
3767
    <tr>
3768
    <td align="right" class="lineno"><pre>496</pre></td>
3769
    <td align="right" class="linebranch"></td>
3770
    <td align="right" class="linecount "><pre></pre></td>
3771
    <td align="left" class="src "><pre>    }</pre></td>
3772
    </tr>
3773

    
3774
    <tr>
3775
    <td align="right" class="lineno"><pre>497</pre></td>
3776
    <td align="right" class="linebranch"></td>
3777
    <td align="right" class="linecount "><pre></pre></td>
3778
    <td align="left" class="src "><pre>    //</pre></td>
3779
    </tr>
3780

    
3781
    <tr>
3782
    <td align="right" class="lineno"><pre>498</pre></td>
3783
    <td align="right" class="linebranch"></td>
3784
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3785
    <td align="left" class="src coveredLine"><pre>    status = ioctl(fd, SPACEWIRE_IOCTRL_SET_EVENT_ID, Task_id[TASKID_SPIQ]); // sets the task ID to which an event is sent when a</pre></td>
3786
    </tr>
3787

    
3788
    <tr>
3789
    <td align="right" class="lineno"><pre>499</pre></td>
3790
    <td align="right" class="linebranch"></td>
3791
    <td align="right" class="linecount "><pre></pre></td>
3792
    <td align="left" class="src "><pre>    if (status!=RTEMS_SUCCESSFUL) {</pre></td>
3793
    </tr>
3794

    
3795
    <tr>
3796
    <td align="right" class="lineno"><pre>500</pre></td>
3797
    <td align="right" class="linebranch"></td>
3798
    <td align="right" class="linecount "><pre></pre></td>
3799
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** Error SPACEWIRE_IOCTRL_SET_EVENT_ID\n")          // link-error interrupt occurs</pre></td>
3800
    </tr>
3801

    
3802
    <tr>
3803
    <td align="right" class="lineno"><pre>501</pre></td>
3804
    <td align="right" class="linebranch"></td>
3805
    <td align="right" class="linecount "><pre></pre></td>
3806
    <td align="left" class="src "><pre>    }</pre></td>
3807
    </tr>
3808

    
3809
    <tr>
3810
    <td align="right" class="lineno"><pre>502</pre></td>
3811
    <td align="right" class="linebranch"></td>
3812
    <td align="right" class="linecount "><pre></pre></td>
3813
    <td align="left" class="src "><pre>    //</pre></td>
3814
    </tr>
3815

    
3816
    <tr>
3817
    <td align="right" class="lineno"><pre>503</pre></td>
3818
    <td align="right" class="linebranch"></td>
3819
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3820
    <td align="left" class="src coveredLine"><pre>    status = ioctl(fd, SPACEWIRE_IOCTRL_SET_DISABLE_ERR, 0);          // automatic link-disabling due to link-error interrupts</pre></td>
3821
    </tr>
3822

    
3823
    <tr>
3824
    <td align="right" class="lineno"><pre>504</pre></td>
3825
    <td align="right" class="linebranch"></td>
3826
    <td align="right" class="linecount "><pre></pre></td>
3827
    <td align="left" class="src "><pre>    if (status!=RTEMS_SUCCESSFUL) {</pre></td>
3828
    </tr>
3829

    
3830
    <tr>
3831
    <td align="right" class="lineno"><pre>505</pre></td>
3832
    <td align="right" class="linebranch"></td>
3833
    <td align="right" class="linecount "><pre></pre></td>
3834
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** Error SPACEWIRE_IOCTRL_SET_DISABLE_ERR\n")</pre></td>
3835
    </tr>
3836

    
3837
    <tr>
3838
    <td align="right" class="lineno"><pre>506</pre></td>
3839
    <td align="right" class="linebranch"></td>
3840
    <td align="right" class="linecount "><pre></pre></td>
3841
    <td align="left" class="src "><pre>    }</pre></td>
3842
    </tr>
3843

    
3844
    <tr>
3845
    <td align="right" class="lineno"><pre>507</pre></td>
3846
    <td align="right" class="linebranch"></td>
3847
    <td align="right" class="linecount "><pre></pre></td>
3848
    <td align="left" class="src "><pre>    //</pre></td>
3849
    </tr>
3850

    
3851
    <tr>
3852
    <td align="right" class="lineno"><pre>508</pre></td>
3853
    <td align="right" class="linebranch"></td>
3854
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3855
    <td align="left" class="src coveredLine"><pre>    status = ioctl(fd, SPACEWIRE_IOCTRL_SET_LINK_ERR_IRQ, 1);         // sets the link-error interrupt bit</pre></td>
3856
    </tr>
3857

    
3858
    <tr>
3859
    <td align="right" class="lineno"><pre>509</pre></td>
3860
    <td align="right" class="linebranch"></td>
3861
    <td align="right" class="linecount "><pre></pre></td>
3862
    <td align="left" class="src "><pre>    if (status!=RTEMS_SUCCESSFUL) {</pre></td>
3863
    </tr>
3864

    
3865
    <tr>
3866
    <td align="right" class="lineno"><pre>510</pre></td>
3867
    <td align="right" class="linebranch"></td>
3868
    <td align="right" class="linecount "><pre></pre></td>
3869
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** Error SPACEWIRE_IOCTRL_SET_LINK_ERR_IRQ\n")</pre></td>
3870
    </tr>
3871

    
3872
    <tr>
3873
    <td align="right" class="lineno"><pre>511</pre></td>
3874
    <td align="right" class="linebranch"></td>
3875
    <td align="right" class="linecount "><pre></pre></td>
3876
    <td align="left" class="src "><pre>    }</pre></td>
3877
    </tr>
3878

    
3879
    <tr>
3880
    <td align="right" class="lineno"><pre>512</pre></td>
3881
    <td align="right" class="linebranch"></td>
3882
    <td align="right" class="linecount "><pre></pre></td>
3883
    <td align="left" class="src "><pre>    //</pre></td>
3884
    </tr>
3885

    
3886
    <tr>
3887
    <td align="right" class="lineno"><pre>513</pre></td>
3888
    <td align="right" class="linebranch"></td>
3889
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3890
    <td align="left" class="src coveredLine"><pre>    status = ioctl(fd, SPACEWIRE_IOCTRL_SET_TXBLOCK, 1);              // transmission blocks</pre></td>
3891
    </tr>
3892

    
3893
    <tr>
3894
    <td align="right" class="lineno"><pre>514</pre></td>
3895
    <td align="right" class="linebranch"></td>
3896
    <td align="right" class="linecount "><pre></pre></td>
3897
    <td align="left" class="src "><pre>    if (status!=RTEMS_SUCCESSFUL) {</pre></td>
3898
    </tr>
3899

    
3900
    <tr>
3901
    <td align="right" class="lineno"><pre>515</pre></td>
3902
    <td align="right" class="linebranch"></td>
3903
    <td align="right" class="linecount "><pre></pre></td>
3904
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** Error SPACEWIRE_IOCTRL_SET_TXBLOCK\n")</pre></td>
3905
    </tr>
3906

    
3907
    <tr>
3908
    <td align="right" class="lineno"><pre>516</pre></td>
3909
    <td align="right" class="linebranch"></td>
3910
    <td align="right" class="linecount "><pre></pre></td>
3911
    <td align="left" class="src "><pre>    }</pre></td>
3912
    </tr>
3913

    
3914
    <tr>
3915
    <td align="right" class="lineno"><pre>517</pre></td>
3916
    <td align="right" class="linebranch"></td>
3917
    <td align="right" class="linecount "><pre></pre></td>
3918
    <td align="left" class="src "><pre>    //</pre></td>
3919
    </tr>
3920

    
3921
    <tr>
3922
    <td align="right" class="lineno"><pre>518</pre></td>
3923
    <td align="right" class="linebranch"></td>
3924
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3925
    <td align="left" class="src coveredLine"><pre>    status = ioctl(fd, SPACEWIRE_IOCTRL_SET_TXBLOCK_ON_FULL, 1);      // transmission blocks when no transmission descriptor is available</pre></td>
3926
    </tr>
3927

    
3928
    <tr>
3929
    <td align="right" class="lineno"><pre>519</pre></td>
3930
    <td align="right" class="linebranch"></td>
3931
    <td align="right" class="linecount "><pre></pre></td>
3932
    <td align="left" class="src "><pre>    if (status!=RTEMS_SUCCESSFUL) {</pre></td>
3933
    </tr>
3934

    
3935
    <tr>
3936
    <td align="right" class="lineno"><pre>520</pre></td>
3937
    <td align="right" class="linebranch"></td>
3938
    <td align="right" class="linecount "><pre></pre></td>
3939
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** Error SPACEWIRE_IOCTRL_SET_TXBLOCK_ON_FULL\n")</pre></td>
3940
    </tr>
3941

    
3942
    <tr>
3943
    <td align="right" class="lineno"><pre>521</pre></td>
3944
    <td align="right" class="linebranch"></td>
3945
    <td align="right" class="linecount "><pre></pre></td>
3946
    <td align="left" class="src "><pre>    }</pre></td>
3947
    </tr>
3948

    
3949
    <tr>
3950
    <td align="right" class="lineno"><pre>522</pre></td>
3951
    <td align="right" class="linebranch"></td>
3952
    <td align="right" class="linecount "><pre></pre></td>
3953
    <td align="left" class="src "><pre>    //</pre></td>
3954
    </tr>
3955

    
3956
    <tr>
3957
    <td align="right" class="lineno"><pre>523</pre></td>
3958
    <td align="right" class="linebranch"></td>
3959
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3960
    <td align="left" class="src coveredLine"><pre>    status = ioctl(fd, SPACEWIRE_IOCTRL_SET_TCODE_CTRL, CONF_TCODE_CTRL); // [Time Rx : Time Tx : Link error : Tick-out IRQ]</pre></td>
3961
    </tr>
3962

    
3963
    <tr>
3964
    <td align="right" class="lineno"><pre>524</pre></td>
3965
    <td align="right" class="linebranch"></td>
3966
    <td align="right" class="linecount "><pre></pre></td>
3967
    <td align="left" class="src "><pre>    if (status!=RTEMS_SUCCESSFUL) {</pre></td>
3968
    </tr>
3969

    
3970
    <tr>
3971
    <td align="right" class="lineno"><pre>525</pre></td>
3972
    <td align="right" class="linebranch"></td>
3973
    <td align="right" class="linecount "><pre></pre></td>
3974
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** Error SPACEWIRE_IOCTRL_SET_TCODE_CTRL,\n")</pre></td>
3975
    </tr>
3976

    
3977
    <tr>
3978
    <td align="right" class="lineno"><pre>526</pre></td>
3979
    <td align="right" class="linebranch"></td>
3980
    <td align="right" class="linecount "><pre></pre></td>
3981
    <td align="left" class="src "><pre>    }</pre></td>
3982
    </tr>
3983

    
3984
    <tr>
3985
    <td align="right" class="lineno"><pre>527</pre></td>
3986
    <td align="right" class="linebranch"></td>
3987
    <td align="right" class="linecount "><pre></pre></td>
3988
    <td align="left" class="src "><pre>    //</pre></td>
3989
    </tr>
3990

    
3991
    <tr>
3992
    <td align="right" class="lineno"><pre>528</pre></td>
3993
    <td align="right" class="linebranch"></td>
3994
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
3995
    <td align="left" class="src coveredLine"><pre>    status = ioctl(fd, SPACEWIRE_IOCTRL_SET_PACKETSIZE, packetsize); // set rxsize, txdsize and txhsize</pre></td>
3996
    </tr>
3997

    
3998
    <tr>
3999
    <td align="right" class="lineno"><pre>529</pre></td>
4000
    <td align="right" class="linebranch"></td>
4001
    <td align="right" class="linecount "><pre></pre></td>
4002
    <td align="left" class="src "><pre>    if (status!=RTEMS_SUCCESSFUL) {</pre></td>
4003
    </tr>
4004

    
4005
    <tr>
4006
    <td align="right" class="lineno"><pre>530</pre></td>
4007
    <td align="right" class="linebranch"></td>
4008
    <td align="right" class="linecount "><pre></pre></td>
4009
    <td align="left" class="src "><pre>        PRINTF("in SPIQ *** Error SPACEWIRE_IOCTRL_SET_PACKETSIZE,\n")</pre></td>
4010
    </tr>
4011

    
4012
    <tr>
4013
    <td align="right" class="lineno"><pre>531</pre></td>
4014
    <td align="right" class="linebranch"></td>
4015
    <td align="right" class="linecount "><pre></pre></td>
4016
    <td align="left" class="src "><pre>    }</pre></td>
4017
    </tr>
4018

    
4019
    <tr>
4020
    <td align="right" class="lineno"><pre>532</pre></td>
4021
    <td align="right" class="linebranch"></td>
4022
    <td align="right" class="linecount "><pre></pre></td>
4023
    <td align="left" class="src "><pre></pre></td>
4024
    </tr>
4025

    
4026
    <tr>
4027
    <td align="right" class="lineno"><pre>533</pre></td>
4028
    <td align="right" class="linebranch"></td>
4029
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4030
    <td align="left" class="src coveredLine"><pre>    return status;</pre></td>
4031
    </tr>
4032

    
4033
    <tr>
4034
    <td align="right" class="lineno"><pre>534</pre></td>
4035
    <td align="right" class="linebranch"></td>
4036
    <td align="right" class="linecount "><pre></pre></td>
4037
    <td align="left" class="src "><pre>}</pre></td>
4038
    </tr>
4039

    
4040
    <tr>
4041
    <td align="right" class="lineno"><pre>535</pre></td>
4042
    <td align="right" class="linebranch"></td>
4043
    <td align="right" class="linecount "><pre></pre></td>
4044
    <td align="left" class="src "><pre></pre></td>
4045
    </tr>
4046

    
4047
    <tr>
4048
    <td align="right" class="lineno"><pre>536</pre></td>
4049
    <td align="right" class="linebranch"></td>
4050
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
4051
    <td align="left" class="src coveredLine"><pre>int spacewire_several_connect_attemps( void )</pre></td>
4052
    </tr>
4053

    
4054
    <tr>
4055
    <td align="right" class="lineno"><pre>537</pre></td>
4056
    <td align="right" class="linebranch"></td>
4057
    <td align="right" class="linecount "><pre></pre></td>
4058
    <td align="left" class="src "><pre>{</pre></td>
4059
    </tr>
4060

    
4061
    <tr>
4062
    <td align="right" class="lineno"><pre>538</pre></td>
4063
    <td align="right" class="linebranch"></td>
4064
    <td align="right" class="linecount "><pre></pre></td>
4065
    <td align="left" class="src "><pre>    /** This function is executed by the SPIQ rtems_task wehn it has been awaken by an interruption raised by the SpaceWire driver.</pre></td>
4066
    </tr>
4067

    
4068
    <tr>
4069
    <td align="right" class="lineno"><pre>539</pre></td>
4070
    <td align="right" class="linebranch"></td>
4071
    <td align="right" class="linecount "><pre></pre></td>
4072
    <td align="left" class="src "><pre>     *</pre></td>
4073
    </tr>
4074

    
4075
    <tr>
4076
    <td align="right" class="lineno"><pre>540</pre></td>
4077
    <td align="right" class="linebranch"></td>
4078
    <td align="right" class="linecount "><pre></pre></td>
4079
    <td align="left" class="src "><pre>     * @return RTEMS directive status code:</pre></td>
4080
    </tr>
4081

    
4082
    <tr>
4083
    <td align="right" class="lineno"><pre>541</pre></td>
4084
    <td align="right" class="linebranch"></td>
4085
    <td align="right" class="linecount "><pre></pre></td>
4086
    <td align="left" class="src "><pre>     * - RTEMS_UNSATISFIED is returned is the link is not in the running state after 10 s.</pre></td>
4087
    </tr>
4088

    
4089
    <tr>
4090
    <td align="right" class="lineno"><pre>542</pre></td>
4091
    <td align="right" class="linebranch"></td>
4092
    <td align="right" class="linecount "><pre></pre></td>
4093
    <td align="left" class="src "><pre>     * - RTEMS_SUCCESSFUL is returned if the link is up before the timeout.</pre></td>
4094
    </tr>
4095

    
4096
    <tr>
4097
    <td align="right" class="lineno"><pre>543</pre></td>
4098
    <td align="right" class="linebranch"></td>
4099
    <td align="right" class="linecount "><pre></pre></td>
4100
    <td align="left" class="src "><pre>     *</pre></td>
4101
    </tr>
4102

    
4103
    <tr>
4104
    <td align="right" class="lineno"><pre>544</pre></td>
4105
    <td align="right" class="linebranch"></td>
4106
    <td align="right" class="linecount "><pre></pre></td>
4107
    <td align="left" class="src "><pre>     */</pre></td>
4108
    </tr>
4109

    
4110
    <tr>
4111
    <td align="right" class="lineno"><pre>545</pre></td>
4112
    <td align="right" class="linebranch"></td>
4113
    <td align="right" class="linecount "><pre></pre></td>
4114
    <td align="left" class="src "><pre></pre></td>
4115
    </tr>
4116

    
4117
    <tr>
4118
    <td align="right" class="lineno"><pre>546</pre></td>
4119
    <td align="right" class="linebranch"></td>
4120
    <td align="right" class="linecount "><pre></pre></td>
4121
    <td align="left" class="src "><pre>    rtems_status_code status_spw;</pre></td>
4122
    </tr>
4123

    
4124
    <tr>
4125
    <td align="right" class="lineno"><pre>547</pre></td>
4126
    <td align="right" class="linebranch"></td>
4127
    <td align="right" class="linecount "><pre></pre></td>
4128
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
4129
    </tr>
4130

    
4131
    <tr>
4132
    <td align="right" class="lineno"><pre>548</pre></td>
4133
    <td align="right" class="linebranch"></td>
4134
    <td align="right" class="linecount "><pre></pre></td>
4135
    <td align="left" class="src "><pre>    int i;</pre></td>
4136
    </tr>
4137

    
4138
    <tr>
4139
    <td align="right" class="lineno"><pre>549</pre></td>
4140
    <td align="right" class="linebranch"></td>
4141
    <td align="right" class="linecount "><pre></pre></td>
4142
    <td align="left" class="src "><pre></pre></td>
4143
    </tr>
4144

    
4145
    <tr>
4146
    <td align="right" class="lineno"><pre>550</pre></td>
4147
    <td align="right" class="linebranch"></td>
4148
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
4149
    <td align="left" class="src coveredLine"><pre>    status_spw = RTEMS_SUCCESSFUL;</pre></td>
4150
    </tr>
4151

    
4152
    <tr>
4153
    <td align="right" class="lineno"><pre>551</pre></td>
4154
    <td align="right" class="linebranch"></td>
4155
    <td align="right" class="linecount "><pre></pre></td>
4156
    <td align="left" class="src "><pre></pre></td>
4157
    </tr>
4158

    
4159
    <tr>
4160
    <td align="right" class="lineno"><pre>552</pre></td>
4161
    <td align="right" class="linebranch"></td>
4162
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
4163
    <td align="left" class="src coveredLine"><pre>    i = 0;</pre></td>
4164
    </tr>
4165

    
4166
    <tr>
4167
    <td align="right" class="lineno"><pre>553</pre></td>
4168
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 15 times">&check;</span><span class="takenBranch" title="Branch 1 taken 5 times">&check;</span></td>
4169
    <td align="right" class="linecount coveredLine"><pre>25</pre></td>
4170
    <td align="left" class="src coveredLine"><pre>    while (i &lt; SY_LFR_DPU_CONNECT_ATTEMPT)</pre></td>
4171
    </tr>
4172

    
4173
    <tr>
4174
    <td align="right" class="lineno"><pre>554</pre></td>
4175
    <td align="right" class="linebranch"></td>
4176
    <td align="right" class="linecount "><pre></pre></td>
4177
    <td align="left" class="src "><pre>    {</pre></td>
4178
    </tr>
4179

    
4180
    <tr>
4181
    <td align="right" class="lineno"><pre>555</pre></td>
4182
    <td align="right" class="linebranch"></td>
4183
    <td align="right" class="linecount "><pre></pre></td>
4184
    <td align="left" class="src "><pre>        PRINTF1("in spacewire_reset_link *** link recovery, try %d\n", i);</pre></td>
4185
    </tr>
4186

    
4187
    <tr>
4188
    <td align="right" class="lineno"><pre>556</pre></td>
4189
    <td align="right" class="linebranch"></td>
4190
    <td align="right" class="linecount "><pre></pre></td>
4191
    <td align="left" class="src "><pre></pre></td>
4192
    </tr>
4193

    
4194
    <tr>
4195
    <td align="right" class="lineno"><pre>557</pre></td>
4196
    <td align="right" class="linebranch"></td>
4197
    <td align="right" class="linecount "><pre></pre></td>
4198
    <td align="left" class="src "><pre>        // CLOSING THE DRIVER AT THIS POINT WILL MAKE THE SEND TASK BLOCK THE SYSTEM</pre></td>
4199
    </tr>
4200

    
4201
    <tr>
4202
    <td align="right" class="lineno"><pre>558</pre></td>
4203
    <td align="right" class="linebranch"></td>
4204
    <td align="right" class="linecount "><pre></pre></td>
4205
    <td align="left" class="src "><pre></pre></td>
4206
    </tr>
4207

    
4208
    <tr>
4209
    <td align="right" class="lineno"><pre>559</pre></td>
4210
    <td align="right" class="linebranch"></td>
4211
    <td align="right" class="linecount coveredLine"><pre>15</pre></td>
4212
    <td align="left" class="src coveredLine"><pre>        status = rtems_task_wake_after( SY_LFR_DPU_CONNECT_TIMEOUT );        // wait SY_LFR_DPU_CONNECT_TIMEOUT 1000 ms</pre></td>
4213
    </tr>
4214

    
4215
    <tr>
4216
    <td align="right" class="lineno"><pre>560</pre></td>
4217
    <td align="right" class="linebranch"></td>
4218
    <td align="right" class="linecount "><pre></pre></td>
4219
    <td align="left" class="src "><pre></pre></td>
4220
    </tr>
4221

    
4222
    <tr>
4223
    <td align="right" class="lineno"><pre>561</pre></td>
4224
    <td align="right" class="linebranch"></td>
4225
    <td align="right" class="linecount coveredLine"><pre>15</pre></td>
4226
    <td align="left" class="src coveredLine"><pre>        status_spw = spacewire_stop_and_start_link( fdSPW );</pre></td>
4227
    </tr>
4228

    
4229
    <tr>
4230
    <td align="right" class="lineno"><pre>562</pre></td>
4231
    <td align="right" class="linebranch"></td>
4232
    <td align="right" class="linecount "><pre></pre></td>
4233
    <td align="left" class="src "><pre></pre></td>
4234
    </tr>
4235

    
4236
    <tr>
4237
    <td align="right" class="lineno"><pre>563</pre></td>
4238
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 15 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
4239
    <td align="right" class="linecount coveredLine"><pre>15</pre></td>
4240
    <td align="left" class="src coveredLine"><pre>        if (  status_spw != RTEMS_SUCCESSFUL )</pre></td>
4241
    </tr>
4242

    
4243
    <tr>
4244
    <td align="right" class="lineno"><pre>564</pre></td>
4245
    <td align="right" class="linebranch"></td>
4246
    <td align="right" class="linecount "><pre></pre></td>
4247
    <td align="left" class="src "><pre>        {</pre></td>
4248
    </tr>
4249

    
4250
    <tr>
4251
    <td align="right" class="lineno"><pre>565</pre></td>
4252
    <td align="right" class="linebranch"></td>
4253
    <td align="right" class="linecount coveredLine"><pre>15</pre></td>
4254
    <td align="left" class="src coveredLine"><pre>            i = i + 1;</pre></td>
4255
    </tr>
4256

    
4257
    <tr>
4258
    <td align="right" class="lineno"><pre>566</pre></td>
4259
    <td align="right" class="linebranch"></td>
4260
    <td align="right" class="linecount "><pre></pre></td>
4261
    <td align="left" class="src "><pre>            PRINTF1("in spacewire_reset_link *** ERR spacewire_start_link code %d\n",  status_spw);</pre></td>
4262
    </tr>
4263

    
4264
    <tr>
4265
    <td align="right" class="lineno"><pre>567</pre></td>
4266
    <td align="right" class="linebranch"></td>
4267
    <td align="right" class="linecount "><pre></pre></td>
4268
    <td align="left" class="src "><pre>        }</pre></td>
4269
    </tr>
4270

    
4271
    <tr>
4272
    <td align="right" class="lineno"><pre>568</pre></td>
4273
    <td align="right" class="linebranch"></td>
4274
    <td align="right" class="linecount "><pre></pre></td>
4275
    <td align="left" class="src "><pre>        else</pre></td>
4276
    </tr>
4277

    
4278
    <tr>
4279
    <td align="right" class="lineno"><pre>569</pre></td>
4280
    <td align="right" class="linebranch"></td>
4281
    <td align="right" class="linecount "><pre></pre></td>
4282
    <td align="left" class="src "><pre>        {</pre></td>
4283
    </tr>
4284

    
4285
    <tr>
4286
    <td align="right" class="lineno"><pre>570</pre></td>
4287
    <td align="right" class="linebranch"></td>
4288
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
4289
    <td align="left" class="src uncoveredLine"><pre>            i = SY_LFR_DPU_CONNECT_ATTEMPT;</pre></td>
4290
    </tr>
4291

    
4292
    <tr>
4293
    <td align="right" class="lineno"><pre>571</pre></td>
4294
    <td align="right" class="linebranch"></td>
4295
    <td align="right" class="linecount "><pre></pre></td>
4296
    <td align="left" class="src "><pre>        }</pre></td>
4297
    </tr>
4298

    
4299
    <tr>
4300
    <td align="right" class="lineno"><pre>572</pre></td>
4301
    <td align="right" class="linebranch"></td>
4302
    <td align="right" class="linecount "><pre></pre></td>
4303
    <td align="left" class="src "><pre>    }</pre></td>
4304
    </tr>
4305

    
4306
    <tr>
4307
    <td align="right" class="lineno"><pre>573</pre></td>
4308
    <td align="right" class="linebranch"></td>
4309
    <td align="right" class="linecount "><pre></pre></td>
4310
    <td align="left" class="src "><pre></pre></td>
4311
    </tr>
4312

    
4313
    <tr>
4314
    <td align="right" class="lineno"><pre>574</pre></td>
4315
    <td align="right" class="linebranch"></td>
4316
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
4317
    <td align="left" class="src coveredLine"><pre>    return status_spw;</pre></td>
4318
    </tr>
4319

    
4320
    <tr>
4321
    <td align="right" class="lineno"><pre>575</pre></td>
4322
    <td align="right" class="linebranch"></td>
4323
    <td align="right" class="linecount "><pre></pre></td>
4324
    <td align="left" class="src "><pre>}</pre></td>
4325
    </tr>
4326

    
4327
    <tr>
4328
    <td align="right" class="lineno"><pre>576</pre></td>
4329
    <td align="right" class="linebranch"></td>
4330
    <td align="right" class="linecount "><pre></pre></td>
4331
    <td align="left" class="src "><pre></pre></td>
4332
    </tr>
4333

    
4334
    <tr>
4335
    <td align="right" class="lineno"><pre>577</pre></td>
4336
    <td align="right" class="linebranch"></td>
4337
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4338
    <td align="left" class="src coveredLine"><pre>void spacewire_set_NP( unsigned char val, unsigned int regAddr ) // [N]o [P]ort force</pre></td>
4339
    </tr>
4340

    
4341
    <tr>
4342
    <td align="right" class="lineno"><pre>578</pre></td>
4343
    <td align="right" class="linebranch"></td>
4344
    <td align="right" class="linecount "><pre></pre></td>
4345
    <td align="left" class="src "><pre>{</pre></td>
4346
    </tr>
4347

    
4348
    <tr>
4349
    <td align="right" class="lineno"><pre>579</pre></td>
4350
    <td align="right" class="linebranch"></td>
4351
    <td align="right" class="linecount "><pre></pre></td>
4352
    <td align="left" class="src "><pre>    /** This function sets the [N]o [P]ort force bit of the GRSPW control register.</pre></td>
4353
    </tr>
4354

    
4355
    <tr>
4356
    <td align="right" class="lineno"><pre>580</pre></td>
4357
    <td align="right" class="linebranch"></td>
4358
    <td align="right" class="linecount "><pre></pre></td>
4359
    <td align="left" class="src "><pre>     *</pre></td>
4360
    </tr>
4361

    
4362
    <tr>
4363
    <td align="right" class="lineno"><pre>581</pre></td>
4364
    <td align="right" class="linebranch"></td>
4365
    <td align="right" class="linecount "><pre></pre></td>
4366
    <td align="left" class="src "><pre>     * @param val is the value, 0 or 1, used to set the value of the NP bit.</pre></td>
4367
    </tr>
4368

    
4369
    <tr>
4370
    <td align="right" class="lineno"><pre>582</pre></td>
4371
    <td align="right" class="linebranch"></td>
4372
    <td align="right" class="linecount "><pre></pre></td>
4373
    <td align="left" class="src "><pre>     * @param regAddr is the address of the GRSPW control register.</pre></td>
4374
    </tr>
4375

    
4376
    <tr>
4377
    <td align="right" class="lineno"><pre>583</pre></td>
4378
    <td align="right" class="linebranch"></td>
4379
    <td align="right" class="linecount "><pre></pre></td>
4380
    <td align="left" class="src "><pre>     *</pre></td>
4381
    </tr>
4382

    
4383
    <tr>
4384
    <td align="right" class="lineno"><pre>584</pre></td>
4385
    <td align="right" class="linebranch"></td>
4386
    <td align="right" class="linecount "><pre></pre></td>
4387
    <td align="left" class="src "><pre>     * NP is the bit 20 of the GRSPW control register.</pre></td>
4388
    </tr>
4389

    
4390
    <tr>
4391
    <td align="right" class="lineno"><pre>585</pre></td>
4392
    <td align="right" class="linebranch"></td>
4393
    <td align="right" class="linecount "><pre></pre></td>
4394
    <td align="left" class="src "><pre>     *</pre></td>
4395
    </tr>
4396

    
4397
    <tr>
4398
    <td align="right" class="lineno"><pre>586</pre></td>
4399
    <td align="right" class="linebranch"></td>
4400
    <td align="right" class="linecount "><pre></pre></td>
4401
    <td align="left" class="src "><pre>     */</pre></td>
4402
    </tr>
4403

    
4404
    <tr>
4405
    <td align="right" class="lineno"><pre>587</pre></td>
4406
    <td align="right" class="linebranch"></td>
4407
    <td align="right" class="linecount "><pre></pre></td>
4408
    <td align="left" class="src "><pre></pre></td>
4409
    </tr>
4410

    
4411
    <tr>
4412
    <td align="right" class="lineno"><pre>588</pre></td>
4413
    <td align="right" class="linebranch"></td>
4414
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4415
    <td align="left" class="src coveredLine"><pre>    unsigned int *spwptr = (unsigned int*) regAddr;</pre></td>
4416
    </tr>
4417

    
4418
    <tr>
4419
    <td align="right" class="lineno"><pre>589</pre></td>
4420
    <td align="right" class="linebranch"></td>
4421
    <td align="right" class="linecount "><pre></pre></td>
4422
    <td align="left" class="src "><pre></pre></td>
4423
    </tr>
4424

    
4425
    <tr>
4426
    <td align="right" class="lineno"><pre>590</pre></td>
4427
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 87 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
4428
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4429
    <td align="left" class="src coveredLine"><pre>    if (val == 1) {</pre></td>
4430
    </tr>
4431

    
4432
    <tr>
4433
    <td align="right" class="lineno"><pre>591</pre></td>
4434
    <td align="right" class="linebranch"></td>
4435
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4436
    <td align="left" class="src coveredLine"><pre>        *spwptr = *spwptr | SPW_BIT_NP; // [NP] set the No port force bit</pre></td>
4437
    </tr>
4438

    
4439
    <tr>
4440
    <td align="right" class="lineno"><pre>592</pre></td>
4441
    <td align="right" class="linebranch"></td>
4442
    <td align="right" class="linecount "><pre></pre></td>
4443
    <td align="left" class="src "><pre>    }</pre></td>
4444
    </tr>
4445

    
4446
    <tr>
4447
    <td align="right" class="lineno"><pre>593</pre></td>
4448
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 87 times">&check;</span></td>
4449
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4450
    <td align="left" class="src coveredLine"><pre>    if (val== 0) {</pre></td>
4451
    </tr>
4452

    
4453
    <tr>
4454
    <td align="right" class="lineno"><pre>594</pre></td>
4455
    <td align="right" class="linebranch"></td>
4456
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
4457
    <td align="left" class="src uncoveredLine"><pre>        *spwptr = *spwptr &amp; SPW_BIT_NP_MASK;</pre></td>
4458
    </tr>
4459

    
4460
    <tr>
4461
    <td align="right" class="lineno"><pre>595</pre></td>
4462
    <td align="right" class="linebranch"></td>
4463
    <td align="right" class="linecount "><pre></pre></td>
4464
    <td align="left" class="src "><pre>    }</pre></td>
4465
    </tr>
4466

    
4467
    <tr>
4468
    <td align="right" class="lineno"><pre>596</pre></td>
4469
    <td align="right" class="linebranch"></td>
4470
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4471
    <td align="left" class="src coveredLine"><pre>}</pre></td>
4472
    </tr>
4473

    
4474
    <tr>
4475
    <td align="right" class="lineno"><pre>597</pre></td>
4476
    <td align="right" class="linebranch"></td>
4477
    <td align="right" class="linecount "><pre></pre></td>
4478
    <td align="left" class="src "><pre></pre></td>
4479
    </tr>
4480

    
4481
    <tr>
4482
    <td align="right" class="lineno"><pre>598</pre></td>
4483
    <td align="right" class="linebranch"></td>
4484
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4485
    <td align="left" class="src coveredLine"><pre>void spacewire_set_RE( unsigned char val, unsigned int regAddr ) // [R]MAP [E]nable</pre></td>
4486
    </tr>
4487

    
4488
    <tr>
4489
    <td align="right" class="lineno"><pre>599</pre></td>
4490
    <td align="right" class="linebranch"></td>
4491
    <td align="right" class="linecount "><pre></pre></td>
4492
    <td align="left" class="src "><pre>{</pre></td>
4493
    </tr>
4494

    
4495
    <tr>
4496
    <td align="right" class="lineno"><pre>600</pre></td>
4497
    <td align="right" class="linebranch"></td>
4498
    <td align="right" class="linecount "><pre></pre></td>
4499
    <td align="left" class="src "><pre>    /** This function sets the [R]MAP [E]nable bit of the GRSPW control register.</pre></td>
4500
    </tr>
4501

    
4502
    <tr>
4503
    <td align="right" class="lineno"><pre>601</pre></td>
4504
    <td align="right" class="linebranch"></td>
4505
    <td align="right" class="linecount "><pre></pre></td>
4506
    <td align="left" class="src "><pre>     *</pre></td>
4507
    </tr>
4508

    
4509
    <tr>
4510
    <td align="right" class="lineno"><pre>602</pre></td>
4511
    <td align="right" class="linebranch"></td>
4512
    <td align="right" class="linecount "><pre></pre></td>
4513
    <td align="left" class="src "><pre>     * @param val is the value, 0 or 1, used to set the value of the RE bit.</pre></td>
4514
    </tr>
4515

    
4516
    <tr>
4517
    <td align="right" class="lineno"><pre>603</pre></td>
4518
    <td align="right" class="linebranch"></td>
4519
    <td align="right" class="linecount "><pre></pre></td>
4520
    <td align="left" class="src "><pre>     * @param regAddr is the address of the GRSPW control register.</pre></td>
4521
    </tr>
4522

    
4523
    <tr>
4524
    <td align="right" class="lineno"><pre>604</pre></td>
4525
    <td align="right" class="linebranch"></td>
4526
    <td align="right" class="linecount "><pre></pre></td>
4527
    <td align="left" class="src "><pre>     *</pre></td>
4528
    </tr>
4529

    
4530
    <tr>
4531
    <td align="right" class="lineno"><pre>605</pre></td>
4532
    <td align="right" class="linebranch"></td>
4533
    <td align="right" class="linecount "><pre></pre></td>
4534
    <td align="left" class="src "><pre>     * RE is the bit 16 of the GRSPW control register.</pre></td>
4535
    </tr>
4536

    
4537
    <tr>
4538
    <td align="right" class="lineno"><pre>606</pre></td>
4539
    <td align="right" class="linebranch"></td>
4540
    <td align="right" class="linecount "><pre></pre></td>
4541
    <td align="left" class="src "><pre>     *</pre></td>
4542
    </tr>
4543

    
4544
    <tr>
4545
    <td align="right" class="lineno"><pre>607</pre></td>
4546
    <td align="right" class="linebranch"></td>
4547
    <td align="right" class="linecount "><pre></pre></td>
4548
    <td align="left" class="src "><pre>     */</pre></td>
4549
    </tr>
4550

    
4551
    <tr>
4552
    <td align="right" class="lineno"><pre>608</pre></td>
4553
    <td align="right" class="linebranch"></td>
4554
    <td align="right" class="linecount "><pre></pre></td>
4555
    <td align="left" class="src "><pre></pre></td>
4556
    </tr>
4557

    
4558
    <tr>
4559
    <td align="right" class="lineno"><pre>609</pre></td>
4560
    <td align="right" class="linebranch"></td>
4561
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4562
    <td align="left" class="src coveredLine"><pre>    unsigned int *spwptr = (unsigned int*) regAddr;</pre></td>
4563
    </tr>
4564

    
4565
    <tr>
4566
    <td align="right" class="lineno"><pre>610</pre></td>
4567
    <td align="right" class="linebranch"></td>
4568
    <td align="right" class="linecount "><pre></pre></td>
4569
    <td align="left" class="src "><pre></pre></td>
4570
    </tr>
4571

    
4572
    <tr>
4573
    <td align="right" class="lineno"><pre>611</pre></td>
4574
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 87 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
4575
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4576
    <td align="left" class="src coveredLine"><pre>    if (val == 1)</pre></td>
4577
    </tr>
4578

    
4579
    <tr>
4580
    <td align="right" class="lineno"><pre>612</pre></td>
4581
    <td align="right" class="linebranch"></td>
4582
    <td align="right" class="linecount "><pre></pre></td>
4583
    <td align="left" class="src "><pre>    {</pre></td>
4584
    </tr>
4585

    
4586
    <tr>
4587
    <td align="right" class="lineno"><pre>613</pre></td>
4588
    <td align="right" class="linebranch"></td>
4589
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4590
    <td align="left" class="src coveredLine"><pre>        *spwptr = *spwptr | SPW_BIT_RE; // [RE] set the RMAP Enable bit</pre></td>
4591
    </tr>
4592

    
4593
    <tr>
4594
    <td align="right" class="lineno"><pre>614</pre></td>
4595
    <td align="right" class="linebranch"></td>
4596
    <td align="right" class="linecount "><pre></pre></td>
4597
    <td align="left" class="src "><pre>    }</pre></td>
4598
    </tr>
4599

    
4600
    <tr>
4601
    <td align="right" class="lineno"><pre>615</pre></td>
4602
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 87 times">&check;</span></td>
4603
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4604
    <td align="left" class="src coveredLine"><pre>    if (val== 0)</pre></td>
4605
    </tr>
4606

    
4607
    <tr>
4608
    <td align="right" class="lineno"><pre>616</pre></td>
4609
    <td align="right" class="linebranch"></td>
4610
    <td align="right" class="linecount "><pre></pre></td>
4611
    <td align="left" class="src "><pre>    {</pre></td>
4612
    </tr>
4613

    
4614
    <tr>
4615
    <td align="right" class="lineno"><pre>617</pre></td>
4616
    <td align="right" class="linebranch"></td>
4617
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
4618
    <td align="left" class="src uncoveredLine"><pre>        *spwptr = *spwptr &amp; SPW_BIT_RE_MASK;</pre></td>
4619
    </tr>
4620

    
4621
    <tr>
4622
    <td align="right" class="lineno"><pre>618</pre></td>
4623
    <td align="right" class="linebranch"></td>
4624
    <td align="right" class="linecount "><pre></pre></td>
4625
    <td align="left" class="src "><pre>    }</pre></td>
4626
    </tr>
4627

    
4628
    <tr>
4629
    <td align="right" class="lineno"><pre>619</pre></td>
4630
    <td align="right" class="linebranch"></td>
4631
    <td align="right" class="linecount coveredLine"><pre>87</pre></td>
4632
    <td align="left" class="src coveredLine"><pre>}</pre></td>
4633
    </tr>
4634

    
4635
    <tr>
4636
    <td align="right" class="lineno"><pre>620</pre></td>
4637
    <td align="right" class="linebranch"></td>
4638
    <td align="right" class="linecount "><pre></pre></td>
4639
    <td align="left" class="src "><pre></pre></td>
4640
    </tr>
4641

    
4642
    <tr>
4643
    <td align="right" class="lineno"><pre>621</pre></td>
4644
    <td align="right" class="linebranch"></td>
4645
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4646
    <td align="left" class="src coveredLine"><pre>void spacewire_read_statistics( void )</pre></td>
4647
    </tr>
4648

    
4649
    <tr>
4650
    <td align="right" class="lineno"><pre>622</pre></td>
4651
    <td align="right" class="linebranch"></td>
4652
    <td align="right" class="linecount "><pre></pre></td>
4653
    <td align="left" class="src "><pre>{</pre></td>
4654
    </tr>
4655

    
4656
    <tr>
4657
    <td align="right" class="lineno"><pre>623</pre></td>
4658
    <td align="right" class="linebranch"></td>
4659
    <td align="right" class="linecount "><pre></pre></td>
4660
    <td align="left" class="src "><pre>    /** This function reads the SpaceWire statistics from the grspw RTEMS driver.</pre></td>
4661
    </tr>
4662

    
4663
    <tr>
4664
    <td align="right" class="lineno"><pre>624</pre></td>
4665
    <td align="right" class="linebranch"></td>
4666
    <td align="right" class="linecount "><pre></pre></td>
4667
    <td align="left" class="src "><pre>     *</pre></td>
4668
    </tr>
4669

    
4670
    <tr>
4671
    <td align="right" class="lineno"><pre>625</pre></td>
4672
    <td align="right" class="linebranch"></td>
4673
    <td align="right" class="linecount "><pre></pre></td>
4674
    <td align="left" class="src "><pre>     * @param void</pre></td>
4675
    </tr>
4676

    
4677
    <tr>
4678
    <td align="right" class="lineno"><pre>626</pre></td>
4679
    <td align="right" class="linebranch"></td>
4680
    <td align="right" class="linecount "><pre></pre></td>
4681
    <td align="left" class="src "><pre>     *</pre></td>
4682
    </tr>
4683

    
4684
    <tr>
4685
    <td align="right" class="lineno"><pre>627</pre></td>
4686
    <td align="right" class="linebranch"></td>
4687
    <td align="right" class="linecount "><pre></pre></td>
4688
    <td align="left" class="src "><pre>     * @return void</pre></td>
4689
    </tr>
4690

    
4691
    <tr>
4692
    <td align="right" class="lineno"><pre>628</pre></td>
4693
    <td align="right" class="linebranch"></td>
4694
    <td align="right" class="linecount "><pre></pre></td>
4695
    <td align="left" class="src "><pre>     *</pre></td>
4696
    </tr>
4697

    
4698
    <tr>
4699
    <td align="right" class="lineno"><pre>629</pre></td>
4700
    <td align="right" class="linebranch"></td>
4701
    <td align="right" class="linecount "><pre></pre></td>
4702
    <td align="left" class="src "><pre>     * Once they are read, the counters are stored in a global variable used during the building of the</pre></td>
4703
    </tr>
4704

    
4705
    <tr>
4706
    <td align="right" class="lineno"><pre>630</pre></td>
4707
    <td align="right" class="linebranch"></td>
4708
    <td align="right" class="linecount "><pre></pre></td>
4709
    <td align="left" class="src "><pre>     * HK packets.</pre></td>
4710
    </tr>
4711

    
4712
    <tr>
4713
    <td align="right" class="lineno"><pre>631</pre></td>
4714
    <td align="right" class="linebranch"></td>
4715
    <td align="right" class="linecount "><pre></pre></td>
4716
    <td align="left" class="src "><pre>     *</pre></td>
4717
    </tr>
4718

    
4719
    <tr>
4720
    <td align="right" class="lineno"><pre>632</pre></td>
4721
    <td align="right" class="linebranch"></td>
4722
    <td align="right" class="linecount "><pre></pre></td>
4723
    <td align="left" class="src "><pre>     */</pre></td>
4724
    </tr>
4725

    
4726
    <tr>
4727
    <td align="right" class="lineno"><pre>633</pre></td>
4728
    <td align="right" class="linebranch"></td>
4729
    <td align="right" class="linecount "><pre></pre></td>
4730
    <td align="left" class="src "><pre></pre></td>
4731
    </tr>
4732

    
4733
    <tr>
4734
    <td align="right" class="lineno"><pre>634</pre></td>
4735
    <td align="right" class="linebranch"></td>
4736
    <td align="right" class="linecount "><pre></pre></td>
4737
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
4738
    </tr>
4739

    
4740
    <tr>
4741
    <td align="right" class="lineno"><pre>635</pre></td>
4742
    <td align="right" class="linebranch"></td>
4743
    <td align="right" class="linecount "><pre></pre></td>
4744
    <td align="left" class="src "><pre>    spw_stats current;</pre></td>
4745
    </tr>
4746

    
4747
    <tr>
4748
    <td align="right" class="lineno"><pre>636</pre></td>
4749
    <td align="right" class="linebranch"></td>
4750
    <td align="right" class="linecount "><pre></pre></td>
4751
    <td align="left" class="src "><pre></pre></td>
4752
    </tr>
4753

    
4754
    <tr>
4755
    <td align="right" class="lineno"><pre>637</pre></td>
4756
    <td align="right" class="linebranch"></td>
4757
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4758
    <td align="left" class="src coveredLine"><pre>    memset(&amp;current, 0, sizeof(spw_stats));</pre></td>
4759
    </tr>
4760

    
4761
    <tr>
4762
    <td align="right" class="lineno"><pre>638</pre></td>
4763
    <td align="right" class="linebranch"></td>
4764
    <td align="right" class="linecount "><pre></pre></td>
4765
    <td align="left" class="src "><pre></pre></td>
4766
    </tr>
4767

    
4768
    <tr>
4769
    <td align="right" class="lineno"><pre>639</pre></td>
4770
    <td align="right" class="linebranch"></td>
4771
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4772
    <td align="left" class="src coveredLine"><pre>    spacewire_get_last_error();</pre></td>
4773
    </tr>
4774

    
4775
    <tr>
4776
    <td align="right" class="lineno"><pre>640</pre></td>
4777
    <td align="right" class="linebranch"></td>
4778
    <td align="right" class="linecount "><pre></pre></td>
4779
    <td align="left" class="src "><pre></pre></td>
4780
    </tr>
4781

    
4782
    <tr>
4783
    <td align="right" class="lineno"><pre>641</pre></td>
4784
    <td align="right" class="linebranch"></td>
4785
    <td align="right" class="linecount "><pre></pre></td>
4786
    <td align="left" class="src "><pre>    // read the current statistics</pre></td>
4787
    </tr>
4788

    
4789
    <tr>
4790
    <td align="right" class="lineno"><pre>642</pre></td>
4791
    <td align="right" class="linebranch"></td>
4792
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4793
    <td align="left" class="src coveredLine"><pre>    status = ioctl( fdSPW, SPACEWIRE_IOCTRL_GET_STATISTICS, &amp;current );</pre></td>
4794
    </tr>
4795

    
4796
    <tr>
4797
    <td align="right" class="lineno"><pre>643</pre></td>
4798
    <td align="right" class="linebranch"></td>
4799
    <td align="right" class="linecount "><pre></pre></td>
4800
    <td align="left" class="src "><pre></pre></td>
4801
    </tr>
4802

    
4803
    <tr>
4804
    <td align="right" class="lineno"><pre>644</pre></td>
4805
    <td align="right" class="linebranch"></td>
4806
    <td align="right" class="linecount "><pre></pre></td>
4807
    <td align="left" class="src "><pre>    // clear the counters</pre></td>
4808
    </tr>
4809

    
4810
    <tr>
4811
    <td align="right" class="lineno"><pre>645</pre></td>
4812
    <td align="right" class="linebranch"></td>
4813
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4814
    <td align="left" class="src coveredLine"><pre>    status = ioctl( fdSPW, SPACEWIRE_IOCTRL_CLR_STATISTICS );</pre></td>
4815
    </tr>
4816

    
4817
    <tr>
4818
    <td align="right" class="lineno"><pre>646</pre></td>
4819
    <td align="right" class="linebranch"></td>
4820
    <td align="right" class="linecount "><pre></pre></td>
4821
    <td align="left" class="src "><pre></pre></td>
4822
    </tr>
4823

    
4824
    <tr>
4825
    <td align="right" class="lineno"><pre>647</pre></td>
4826
    <td align="right" class="linebranch"></td>
4827
    <td align="right" class="linecount "><pre></pre></td>
4828
    <td align="left" class="src "><pre>    // rx_eep_err</pre></td>
4829
    </tr>
4830

    
4831
    <tr>
4832
    <td align="right" class="lineno"><pre>648</pre></td>
4833
    <td align="right" class="linebranch"></td>
4834
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4835
    <td align="left" class="src coveredLine"><pre>    grspw_stats.rx_eep_err      = grspw_stats.rx_eep_err        + current.rx_eep_err;</pre></td>
4836
    </tr>
4837

    
4838
    <tr>
4839
    <td align="right" class="lineno"><pre>649</pre></td>
4840
    <td align="right" class="linebranch"></td>
4841
    <td align="right" class="linecount "><pre></pre></td>
4842
    <td align="left" class="src "><pre>    // rx_truncated</pre></td>
4843
    </tr>
4844

    
4845
    <tr>
4846
    <td align="right" class="lineno"><pre>650</pre></td>
4847
    <td align="right" class="linebranch"></td>
4848
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4849
    <td align="left" class="src coveredLine"><pre>    grspw_stats.rx_truncated    = grspw_stats.rx_truncated      + current.rx_truncated;</pre></td>
4850
    </tr>
4851

    
4852
    <tr>
4853
    <td align="right" class="lineno"><pre>651</pre></td>
4854
    <td align="right" class="linebranch"></td>
4855
    <td align="right" class="linecount "><pre></pre></td>
4856
    <td align="left" class="src "><pre>    // parity_err</pre></td>
4857
    </tr>
4858

    
4859
    <tr>
4860
    <td align="right" class="lineno"><pre>652</pre></td>
4861
    <td align="right" class="linebranch"></td>
4862
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4863
    <td align="left" class="src coveredLine"><pre>    grspw_stats.parity_err      = grspw_stats.parity_err        + current.parity_err;</pre></td>
4864
    </tr>
4865

    
4866
    <tr>
4867
    <td align="right" class="lineno"><pre>653</pre></td>
4868
    <td align="right" class="linebranch"></td>
4869
    <td align="right" class="linecount "><pre></pre></td>
4870
    <td align="left" class="src "><pre>    // escape_err</pre></td>
4871
    </tr>
4872

    
4873
    <tr>
4874
    <td align="right" class="lineno"><pre>654</pre></td>
4875
    <td align="right" class="linebranch"></td>
4876
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4877
    <td align="left" class="src coveredLine"><pre>    grspw_stats.escape_err      = grspw_stats.escape_err        + current.escape_err;</pre></td>
4878
    </tr>
4879

    
4880
    <tr>
4881
    <td align="right" class="lineno"><pre>655</pre></td>
4882
    <td align="right" class="linebranch"></td>
4883
    <td align="right" class="linecount "><pre></pre></td>
4884
    <td align="left" class="src "><pre>    // credit_err</pre></td>
4885
    </tr>
4886

    
4887
    <tr>
4888
    <td align="right" class="lineno"><pre>656</pre></td>
4889
    <td align="right" class="linebranch"></td>
4890
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4891
    <td align="left" class="src coveredLine"><pre>    grspw_stats.credit_err      = grspw_stats.credit_err        + current.credit_err;</pre></td>
4892
    </tr>
4893

    
4894
    <tr>
4895
    <td align="right" class="lineno"><pre>657</pre></td>
4896
    <td align="right" class="linebranch"></td>
4897
    <td align="right" class="linecount "><pre></pre></td>
4898
    <td align="left" class="src "><pre>    // write_sync_err</pre></td>
4899
    </tr>
4900

    
4901
    <tr>
4902
    <td align="right" class="lineno"><pre>658</pre></td>
4903
    <td align="right" class="linebranch"></td>
4904
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4905
    <td align="left" class="src coveredLine"><pre>    grspw_stats.write_sync_err  = grspw_stats.write_sync_err    + current.write_sync_err;</pre></td>
4906
    </tr>
4907

    
4908
    <tr>
4909
    <td align="right" class="lineno"><pre>659</pre></td>
4910
    <td align="right" class="linebranch"></td>
4911
    <td align="right" class="linecount "><pre></pre></td>
4912
    <td align="left" class="src "><pre>    // disconnect_err</pre></td>
4913
    </tr>
4914

    
4915
    <tr>
4916
    <td align="right" class="lineno"><pre>660</pre></td>
4917
    <td align="right" class="linebranch"></td>
4918
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4919
    <td align="left" class="src coveredLine"><pre>    grspw_stats.disconnect_err  = grspw_stats.disconnect_err    + current.disconnect_err;</pre></td>
4920
    </tr>
4921

    
4922
    <tr>
4923
    <td align="right" class="lineno"><pre>661</pre></td>
4924
    <td align="right" class="linebranch"></td>
4925
    <td align="right" class="linecount "><pre></pre></td>
4926
    <td align="left" class="src "><pre>    // early_ep</pre></td>
4927
    </tr>
4928

    
4929
    <tr>
4930
    <td align="right" class="lineno"><pre>662</pre></td>
4931
    <td align="right" class="linebranch"></td>
4932
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4933
    <td align="left" class="src coveredLine"><pre>    grspw_stats.early_ep        = grspw_stats.early_ep          + current.early_ep;</pre></td>
4934
    </tr>
4935

    
4936
    <tr>
4937
    <td align="right" class="lineno"><pre>663</pre></td>
4938
    <td align="right" class="linebranch"></td>
4939
    <td align="right" class="linecount "><pre></pre></td>
4940
    <td align="left" class="src "><pre>    // invalid_address</pre></td>
4941
    </tr>
4942

    
4943
    <tr>
4944
    <td align="right" class="lineno"><pre>664</pre></td>
4945
    <td align="right" class="linebranch"></td>
4946
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4947
    <td align="left" class="src coveredLine"><pre>    grspw_stats.invalid_address = grspw_stats.invalid_address   + current.invalid_address;</pre></td>
4948
    </tr>
4949

    
4950
    <tr>
4951
    <td align="right" class="lineno"><pre>665</pre></td>
4952
    <td align="right" class="linebranch"></td>
4953
    <td align="right" class="linecount "><pre></pre></td>
4954
    <td align="left" class="src "><pre>    // packets_sent</pre></td>
4955
    </tr>
4956

    
4957
    <tr>
4958
    <td align="right" class="lineno"><pre>666</pre></td>
4959
    <td align="right" class="linebranch"></td>
4960
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4961
    <td align="left" class="src coveredLine"><pre>    grspw_stats.packets_sent    = grspw_stats.packets_sent      + current.packets_sent;</pre></td>
4962
    </tr>
4963

    
4964
    <tr>
4965
    <td align="right" class="lineno"><pre>667</pre></td>
4966
    <td align="right" class="linebranch"></td>
4967
    <td align="right" class="linecount "><pre></pre></td>
4968
    <td align="left" class="src "><pre>    // packets_received</pre></td>
4969
    </tr>
4970

    
4971
    <tr>
4972
    <td align="right" class="lineno"><pre>668</pre></td>
4973
    <td align="right" class="linebranch"></td>
4974
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4975
    <td align="left" class="src coveredLine"><pre>    grspw_stats.packets_received= grspw_stats.packets_received  + current.packets_received;</pre></td>
4976
    </tr>
4977

    
4978
    <tr>
4979
    <td align="right" class="lineno"><pre>669</pre></td>
4980
    <td align="right" class="linebranch"></td>
4981
    <td align="right" class="linecount "><pre></pre></td>
4982
    <td align="left" class="src "><pre></pre></td>
4983
    </tr>
4984

    
4985
    <tr>
4986
    <td align="right" class="lineno"><pre>670</pre></td>
4987
    <td align="right" class="linebranch"></td>
4988
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
4989
    <td align="left" class="src coveredLine"><pre>}</pre></td>
4990
    </tr>
4991

    
4992
    <tr>
4993
    <td align="right" class="lineno"><pre>671</pre></td>
4994
    <td align="right" class="linebranch"></td>
4995
    <td align="right" class="linecount "><pre></pre></td>
4996
    <td align="left" class="src "><pre></pre></td>
4997
    </tr>
4998

    
4999
    <tr>
5000
    <td align="right" class="lineno"><pre>672</pre></td>
5001
    <td align="right" class="linebranch"></td>
5002
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5003
    <td align="left" class="src coveredLine"><pre>void spacewire_get_last_error( void )</pre></td>
5004
    </tr>
5005

    
5006
    <tr>
5007
    <td align="right" class="lineno"><pre>673</pre></td>
5008
    <td align="right" class="linebranch"></td>
5009
    <td align="right" class="linecount "><pre></pre></td>
5010
    <td align="left" class="src "><pre>{</pre></td>
5011
    </tr>
5012

    
5013
    <tr>
5014
    <td align="right" class="lineno"><pre>674</pre></td>
5015
    <td align="right" class="linebranch"></td>
5016
    <td align="right" class="linecount "><pre></pre></td>
5017
    <td align="left" class="src "><pre>    static spw_stats previous = {0};</pre></td>
5018
    </tr>
5019

    
5020
    <tr>
5021
    <td align="right" class="lineno"><pre>675</pre></td>
5022
    <td align="right" class="linebranch"></td>
5023
    <td align="right" class="linecount "><pre></pre></td>
5024
    <td align="left" class="src "><pre>    spw_stats current;</pre></td>
5025
    </tr>
5026

    
5027
    <tr>
5028
    <td align="right" class="lineno"><pre>676</pre></td>
5029
    <td align="right" class="linebranch"></td>
5030
    <td align="right" class="linecount "><pre></pre></td>
5031
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
5032
    </tr>
5033

    
5034
    <tr>
5035
    <td align="right" class="lineno"><pre>677</pre></td>
5036
    <td align="right" class="linebranch"></td>
5037
    <td align="right" class="linecount "><pre></pre></td>
5038
    <td align="left" class="src "><pre></pre></td>
5039
    </tr>
5040

    
5041
    <tr>
5042
    <td align="right" class="lineno"><pre>678</pre></td>
5043
    <td align="right" class="linebranch"></td>
5044
    <td align="right" class="linecount "><pre></pre></td>
5045
    <td align="left" class="src "><pre>    unsigned int  hk_lfr_last_er_rid;</pre></td>
5046
    </tr>
5047

    
5048
    <tr>
5049
    <td align="right" class="lineno"><pre>679</pre></td>
5050
    <td align="right" class="linebranch"></td>
5051
    <td align="right" class="linecount "><pre></pre></td>
5052
    <td align="left" class="src "><pre>    unsigned char hk_lfr_last_er_code;</pre></td>
5053
    </tr>
5054

    
5055
    <tr>
5056
    <td align="right" class="lineno"><pre>680</pre></td>
5057
    <td align="right" class="linebranch"></td>
5058
    <td align="right" class="linecount "><pre></pre></td>
5059
    <td align="left" class="src "><pre>    int coarseTime;</pre></td>
5060
    </tr>
5061

    
5062
    <tr>
5063
    <td align="right" class="lineno"><pre>681</pre></td>
5064
    <td align="right" class="linebranch"></td>
5065
    <td align="right" class="linecount "><pre></pre></td>
5066
    <td align="left" class="src "><pre>    int fineTime;</pre></td>
5067
    </tr>
5068

    
5069
    <tr>
5070
    <td align="right" class="lineno"><pre>682</pre></td>
5071
    <td align="right" class="linebranch"></td>
5072
    <td align="right" class="linecount "><pre></pre></td>
5073
    <td align="left" class="src "><pre>    unsigned char update_hk_lfr_last_er;</pre></td>
5074
    </tr>
5075

    
5076
    <tr>
5077
    <td align="right" class="lineno"><pre>683</pre></td>
5078
    <td align="right" class="linebranch"></td>
5079
    <td align="right" class="linecount "><pre></pre></td>
5080
    <td align="left" class="src "><pre></pre></td>
5081
    </tr>
5082

    
5083
    <tr>
5084
    <td align="right" class="lineno"><pre>684</pre></td>
5085
    <td align="right" class="linebranch"></td>
5086
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5087
    <td align="left" class="src coveredLine"><pre>    memset(&amp;current, 0, sizeof(spw_stats));</pre></td>
5088
    </tr>
5089

    
5090
    <tr>
5091
    <td align="right" class="lineno"><pre>685</pre></td>
5092
    <td align="right" class="linebranch"></td>
5093
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5094
    <td align="left" class="src coveredLine"><pre>    hk_lfr_last_er_rid  = INIT_CHAR;</pre></td>
5095
    </tr>
5096

    
5097
    <tr>
5098
    <td align="right" class="lineno"><pre>686</pre></td>
5099
    <td align="right" class="linebranch"></td>
5100
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5101
    <td align="left" class="src coveredLine"><pre>    hk_lfr_last_er_code = INIT_CHAR;</pre></td>
5102
    </tr>
5103

    
5104
    <tr>
5105
    <td align="right" class="lineno"><pre>687</pre></td>
5106
    <td align="right" class="linebranch"></td>
5107
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5108
    <td align="left" class="src coveredLine"><pre>    update_hk_lfr_last_er = INIT_CHAR;</pre></td>
5109
    </tr>
5110

    
5111
    <tr>
5112
    <td align="right" class="lineno"><pre>688</pre></td>
5113
    <td align="right" class="linebranch"></td>
5114
    <td align="right" class="linecount "><pre></pre></td>
5115
    <td align="left" class="src "><pre></pre></td>
5116
    </tr>
5117

    
5118
    <tr>
5119
    <td align="right" class="lineno"><pre>689</pre></td>
5120
    <td align="right" class="linebranch"></td>
5121
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5122
    <td align="left" class="src coveredLine"><pre>    status = ioctl( fdSPW, SPACEWIRE_IOCTRL_GET_STATISTICS, &amp;current );</pre></td>
5123
    </tr>
5124

    
5125
    <tr>
5126
    <td align="right" class="lineno"><pre>690</pre></td>
5127
    <td align="right" class="linebranch"></td>
5128
    <td align="right" class="linecount "><pre></pre></td>
5129
    <td align="left" class="src "><pre></pre></td>
5130
    </tr>
5131

    
5132
    <tr>
5133
    <td align="right" class="lineno"><pre>691</pre></td>
5134
    <td align="right" class="linebranch"></td>
5135
    <td align="right" class="linecount "><pre></pre></td>
5136
    <td align="left" class="src "><pre>    // get current time</pre></td>
5137
    </tr>
5138

    
5139
    <tr>
5140
    <td align="right" class="lineno"><pre>692</pre></td>
5141
    <td align="right" class="linebranch"></td>
5142
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5143
    <td align="left" class="src coveredLine"><pre>    coarseTime = time_management_regs->coarse_time;</pre></td>
5144
    </tr>
5145

    
5146
    <tr>
5147
    <td align="right" class="lineno"><pre>693</pre></td>
5148
    <td align="right" class="linebranch"></td>
5149
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5150
    <td align="left" class="src coveredLine"><pre>    fineTime   = time_management_regs->fine_time;</pre></td>
5151
    </tr>
5152

    
5153
    <tr>
5154
    <td align="right" class="lineno"><pre>694</pre></td>
5155
    <td align="right" class="linebranch"></td>
5156
    <td align="right" class="linecount "><pre></pre></td>
5157
    <td align="left" class="src "><pre></pre></td>
5158
    </tr>
5159

    
5160
    <tr>
5161
    <td align="right" class="lineno"><pre>695</pre></td>
5162
    <td align="right" class="linebranch"></td>
5163
    <td align="right" class="linecount "><pre></pre></td>
5164
    <td align="left" class="src "><pre>    // tx_link_err *** no code associated to this field</pre></td>
5165
    </tr>
5166

    
5167
    <tr>
5168
    <td align="right" class="lineno"><pre>696</pre></td>
5169
    <td align="right" class="linebranch"></td>
5170
    <td align="right" class="linecount "><pre></pre></td>
5171
    <td align="left" class="src "><pre>    // rx_rmap_header_crc_err ***  LE *** in HK</pre></td>
5172
    </tr>
5173

    
5174
    <tr>
5175
    <td align="right" class="lineno"><pre>697</pre></td>
5176
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 129642 times">&check;</span></td>
5177
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5178
    <td align="left" class="src coveredLine"><pre>    if (previous.rx_rmap_header_crc_err != current.rx_rmap_header_crc_err)</pre></td>
5179
    </tr>
5180

    
5181
    <tr>
5182
    <td align="right" class="lineno"><pre>698</pre></td>
5183
    <td align="right" class="linebranch"></td>
5184
    <td align="right" class="linecount "><pre></pre></td>
5185
    <td align="left" class="src "><pre>    {</pre></td>
5186
    </tr>
5187

    
5188
    <tr>
5189
    <td align="right" class="lineno"><pre>699</pre></td>
5190
    <td align="right" class="linebranch"></td>
5191
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5192
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_rid  = RID_LE_LFR_DPU_SPW;</pre></td>
5193
    </tr>
5194

    
5195
    <tr>
5196
    <td align="right" class="lineno"><pre>700</pre></td>
5197
    <td align="right" class="linebranch"></td>
5198
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5199
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_code = CODE_HEADER_CRC;</pre></td>
5200
    </tr>
5201

    
5202
    <tr>
5203
    <td align="right" class="lineno"><pre>701</pre></td>
5204
    <td align="right" class="linebranch"></td>
5205
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5206
    <td align="left" class="src uncoveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5207
    </tr>
5208

    
5209
    <tr>
5210
    <td align="right" class="lineno"><pre>702</pre></td>
5211
    <td align="right" class="linebranch"></td>
5212
    <td align="right" class="linecount "><pre></pre></td>
5213
    <td align="left" class="src "><pre>    }</pre></td>
5214
    </tr>
5215

    
5216
    <tr>
5217
    <td align="right" class="lineno"><pre>703</pre></td>
5218
    <td align="right" class="linebranch"></td>
5219
    <td align="right" class="linecount "><pre></pre></td>
5220
    <td align="left" class="src "><pre>    // rx_rmap_data_crc_err ***  LE *** NOT IN HK</pre></td>
5221
    </tr>
5222

    
5223
    <tr>
5224
    <td align="right" class="lineno"><pre>704</pre></td>
5225
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 129642 times">&check;</span></td>
5226
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5227
    <td align="left" class="src coveredLine"><pre>    if (previous.rx_rmap_data_crc_err != current.rx_rmap_data_crc_err)</pre></td>
5228
    </tr>
5229

    
5230
    <tr>
5231
    <td align="right" class="lineno"><pre>705</pre></td>
5232
    <td align="right" class="linebranch"></td>
5233
    <td align="right" class="linecount "><pre></pre></td>
5234
    <td align="left" class="src "><pre>    {</pre></td>
5235
    </tr>
5236

    
5237
    <tr>
5238
    <td align="right" class="lineno"><pre>706</pre></td>
5239
    <td align="right" class="linebranch"></td>
5240
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5241
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_rid  = RID_LE_LFR_DPU_SPW;</pre></td>
5242
    </tr>
5243

    
5244
    <tr>
5245
    <td align="right" class="lineno"><pre>707</pre></td>
5246
    <td align="right" class="linebranch"></td>
5247
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5248
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_code = CODE_DATA_CRC;</pre></td>
5249
    </tr>
5250

    
5251
    <tr>
5252
    <td align="right" class="lineno"><pre>708</pre></td>
5253
    <td align="right" class="linebranch"></td>
5254
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5255
    <td align="left" class="src uncoveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5256
    </tr>
5257

    
5258
    <tr>
5259
    <td align="right" class="lineno"><pre>709</pre></td>
5260
    <td align="right" class="linebranch"></td>
5261
    <td align="right" class="linecount "><pre></pre></td>
5262
    <td align="left" class="src "><pre>    }</pre></td>
5263
    </tr>
5264

    
5265
    <tr>
5266
    <td align="right" class="lineno"><pre>710</pre></td>
5267
    <td align="right" class="linebranch"></td>
5268
    <td align="right" class="linecount "><pre></pre></td>
5269
    <td align="left" class="src "><pre>    // rx_eep_err</pre></td>
5270
    </tr>
5271

    
5272
    <tr>
5273
    <td align="right" class="lineno"><pre>711</pre></td>
5274
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 129642 times">&check;</span></td>
5275
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5276
    <td align="left" class="src coveredLine"><pre>    if (previous.rx_eep_err != current.rx_eep_err)</pre></td>
5277
    </tr>
5278

    
5279
    <tr>
5280
    <td align="right" class="lineno"><pre>712</pre></td>
5281
    <td align="right" class="linebranch"></td>
5282
    <td align="right" class="linecount "><pre></pre></td>
5283
    <td align="left" class="src "><pre>    {</pre></td>
5284
    </tr>
5285

    
5286
    <tr>
5287
    <td align="right" class="lineno"><pre>713</pre></td>
5288
    <td align="right" class="linebranch"></td>
5289
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5290
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_rid  = RID_ME_LFR_DPU_SPW;</pre></td>
5291
    </tr>
5292

    
5293
    <tr>
5294
    <td align="right" class="lineno"><pre>714</pre></td>
5295
    <td align="right" class="linebranch"></td>
5296
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5297
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_code = CODE_EEP;</pre></td>
5298
    </tr>
5299

    
5300
    <tr>
5301
    <td align="right" class="lineno"><pre>715</pre></td>
5302
    <td align="right" class="linebranch"></td>
5303
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5304
    <td align="left" class="src uncoveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5305
    </tr>
5306

    
5307
    <tr>
5308
    <td align="right" class="lineno"><pre>716</pre></td>
5309
    <td align="right" class="linebranch"></td>
5310
    <td align="right" class="linecount "><pre></pre></td>
5311
    <td align="left" class="src "><pre>    }</pre></td>
5312
    </tr>
5313

    
5314
    <tr>
5315
    <td align="right" class="lineno"><pre>717</pre></td>
5316
    <td align="right" class="linebranch"></td>
5317
    <td align="right" class="linecount "><pre></pre></td>
5318
    <td align="left" class="src "><pre>    // rx_truncated</pre></td>
5319
    </tr>
5320

    
5321
    <tr>
5322
    <td align="right" class="lineno"><pre>718</pre></td>
5323
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 534 times">&check;</span><span class="takenBranch" title="Branch 1 taken 129108 times">&check;</span></td>
5324
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5325
    <td align="left" class="src coveredLine"><pre>    if (previous.rx_truncated != current.rx_truncated)</pre></td>
5326
    </tr>
5327

    
5328
    <tr>
5329
    <td align="right" class="lineno"><pre>719</pre></td>
5330
    <td align="right" class="linebranch"></td>
5331
    <td align="right" class="linecount "><pre></pre></td>
5332
    <td align="left" class="src "><pre>    {</pre></td>
5333
    </tr>
5334

    
5335
    <tr>
5336
    <td align="right" class="lineno"><pre>720</pre></td>
5337
    <td align="right" class="linebranch"></td>
5338
    <td align="right" class="linecount coveredLine"><pre>534</pre></td>
5339
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_rid  = RID_ME_LFR_DPU_SPW;</pre></td>
5340
    </tr>
5341

    
5342
    <tr>
5343
    <td align="right" class="lineno"><pre>721</pre></td>
5344
    <td align="right" class="linebranch"></td>
5345
    <td align="right" class="linecount coveredLine"><pre>534</pre></td>
5346
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_code = CODE_RX_TOO_BIG;</pre></td>
5347
    </tr>
5348

    
5349
    <tr>
5350
    <td align="right" class="lineno"><pre>722</pre></td>
5351
    <td align="right" class="linebranch"></td>
5352
    <td align="right" class="linecount coveredLine"><pre>534</pre></td>
5353
    <td align="left" class="src coveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5354
    </tr>
5355

    
5356
    <tr>
5357
    <td align="right" class="lineno"><pre>723</pre></td>
5358
    <td align="right" class="linebranch"></td>
5359
    <td align="right" class="linecount "><pre></pre></td>
5360
    <td align="left" class="src "><pre>    }</pre></td>
5361
    </tr>
5362

    
5363
    <tr>
5364
    <td align="right" class="lineno"><pre>724</pre></td>
5365
    <td align="right" class="linebranch"></td>
5366
    <td align="right" class="linecount "><pre></pre></td>
5367
    <td align="left" class="src "><pre>    // parity_err</pre></td>
5368
    </tr>
5369

    
5370
    <tr>
5371
    <td align="right" class="lineno"><pre>725</pre></td>
5372
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 4 times">&check;</span><span class="takenBranch" title="Branch 1 taken 129638 times">&check;</span></td>
5373
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5374
    <td align="left" class="src coveredLine"><pre>    if (previous.parity_err != current.parity_err)</pre></td>
5375
    </tr>
5376

    
5377
    <tr>
5378
    <td align="right" class="lineno"><pre>726</pre></td>
5379
    <td align="right" class="linebranch"></td>
5380
    <td align="right" class="linecount "><pre></pre></td>
5381
    <td align="left" class="src "><pre>    {</pre></td>
5382
    </tr>
5383

    
5384
    <tr>
5385
    <td align="right" class="lineno"><pre>727</pre></td>
5386
    <td align="right" class="linebranch"></td>
5387
    <td align="right" class="linecount coveredLine"><pre>4</pre></td>
5388
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_rid  = RID_LE_LFR_DPU_SPW;</pre></td>
5389
    </tr>
5390

    
5391
    <tr>
5392
    <td align="right" class="lineno"><pre>728</pre></td>
5393
    <td align="right" class="linebranch"></td>
5394
    <td align="right" class="linecount coveredLine"><pre>4</pre></td>
5395
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_code = CODE_PARITY;</pre></td>
5396
    </tr>
5397

    
5398
    <tr>
5399
    <td align="right" class="lineno"><pre>729</pre></td>
5400
    <td align="right" class="linebranch"></td>
5401
    <td align="right" class="linecount coveredLine"><pre>4</pre></td>
5402
    <td align="left" class="src coveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5403
    </tr>
5404

    
5405
    <tr>
5406
    <td align="right" class="lineno"><pre>730</pre></td>
5407
    <td align="right" class="linebranch"></td>
5408
    <td align="right" class="linecount "><pre></pre></td>
5409
    <td align="left" class="src "><pre>    }</pre></td>
5410
    </tr>
5411

    
5412
    <tr>
5413
    <td align="right" class="lineno"><pre>731</pre></td>
5414
    <td align="right" class="linebranch"></td>
5415
    <td align="right" class="linecount "><pre></pre></td>
5416
    <td align="left" class="src "><pre>    // escape_err</pre></td>
5417
    </tr>
5418

    
5419
    <tr>
5420
    <td align="right" class="lineno"><pre>732</pre></td>
5421
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 4 times">&check;</span><span class="takenBranch" title="Branch 1 taken 129638 times">&check;</span></td>
5422
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5423
    <td align="left" class="src coveredLine"><pre>    if (previous.parity_err != current.parity_err)</pre></td>
5424
    </tr>
5425

    
5426
    <tr>
5427
    <td align="right" class="lineno"><pre>733</pre></td>
5428
    <td align="right" class="linebranch"></td>
5429
    <td align="right" class="linecount "><pre></pre></td>
5430
    <td align="left" class="src "><pre>    {</pre></td>
5431
    </tr>
5432

    
5433
    <tr>
5434
    <td align="right" class="lineno"><pre>734</pre></td>
5435
    <td align="right" class="linebranch"></td>
5436
    <td align="right" class="linecount coveredLine"><pre>4</pre></td>
5437
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_rid  = RID_LE_LFR_DPU_SPW;</pre></td>
5438
    </tr>
5439

    
5440
    <tr>
5441
    <td align="right" class="lineno"><pre>735</pre></td>
5442
    <td align="right" class="linebranch"></td>
5443
    <td align="right" class="linecount coveredLine"><pre>4</pre></td>
5444
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_code = CODE_ESCAPE;</pre></td>
5445
    </tr>
5446

    
5447
    <tr>
5448
    <td align="right" class="lineno"><pre>736</pre></td>
5449
    <td align="right" class="linebranch"></td>
5450
    <td align="right" class="linecount coveredLine"><pre>4</pre></td>
5451
    <td align="left" class="src coveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5452
    </tr>
5453

    
5454
    <tr>
5455
    <td align="right" class="lineno"><pre>737</pre></td>
5456
    <td align="right" class="linebranch"></td>
5457
    <td align="right" class="linecount "><pre></pre></td>
5458
    <td align="left" class="src "><pre>    }</pre></td>
5459
    </tr>
5460

    
5461
    <tr>
5462
    <td align="right" class="lineno"><pre>738</pre></td>
5463
    <td align="right" class="linebranch"></td>
5464
    <td align="right" class="linecount "><pre></pre></td>
5465
    <td align="left" class="src "><pre>    // credit_err</pre></td>
5466
    </tr>
5467

    
5468
    <tr>
5469
    <td align="right" class="lineno"><pre>739</pre></td>
5470
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 129642 times">&check;</span></td>
5471
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5472
    <td align="left" class="src coveredLine"><pre>    if (previous.credit_err != current.credit_err)</pre></td>
5473
    </tr>
5474

    
5475
    <tr>
5476
    <td align="right" class="lineno"><pre>740</pre></td>
5477
    <td align="right" class="linebranch"></td>
5478
    <td align="right" class="linecount "><pre></pre></td>
5479
    <td align="left" class="src "><pre>    {</pre></td>
5480
    </tr>
5481

    
5482
    <tr>
5483
    <td align="right" class="lineno"><pre>741</pre></td>
5484
    <td align="right" class="linebranch"></td>
5485
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5486
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_rid  = RID_LE_LFR_DPU_SPW;</pre></td>
5487
    </tr>
5488

    
5489
    <tr>
5490
    <td align="right" class="lineno"><pre>742</pre></td>
5491
    <td align="right" class="linebranch"></td>
5492
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5493
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_code = CODE_CREDIT;</pre></td>
5494
    </tr>
5495

    
5496
    <tr>
5497
    <td align="right" class="lineno"><pre>743</pre></td>
5498
    <td align="right" class="linebranch"></td>
5499
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5500
    <td align="left" class="src uncoveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5501
    </tr>
5502

    
5503
    <tr>
5504
    <td align="right" class="lineno"><pre>744</pre></td>
5505
    <td align="right" class="linebranch"></td>
5506
    <td align="right" class="linecount "><pre></pre></td>
5507
    <td align="left" class="src "><pre>    }</pre></td>
5508
    </tr>
5509

    
5510
    <tr>
5511
    <td align="right" class="lineno"><pre>745</pre></td>
5512
    <td align="right" class="linebranch"></td>
5513
    <td align="right" class="linecount "><pre></pre></td>
5514
    <td align="left" class="src "><pre>    // write_sync_err</pre></td>
5515
    </tr>
5516

    
5517
    <tr>
5518
    <td align="right" class="lineno"><pre>746</pre></td>
5519
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 129642 times">&check;</span></td>
5520
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5521
    <td align="left" class="src coveredLine"><pre>    if (previous.write_sync_err != current.write_sync_err)</pre></td>
5522
    </tr>
5523

    
5524
    <tr>
5525
    <td align="right" class="lineno"><pre>747</pre></td>
5526
    <td align="right" class="linebranch"></td>
5527
    <td align="right" class="linecount "><pre></pre></td>
5528
    <td align="left" class="src "><pre>    {</pre></td>
5529
    </tr>
5530

    
5531
    <tr>
5532
    <td align="right" class="lineno"><pre>748</pre></td>
5533
    <td align="right" class="linebranch"></td>
5534
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5535
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_rid  = RID_LE_LFR_DPU_SPW;</pre></td>
5536
    </tr>
5537

    
5538
    <tr>
5539
    <td align="right" class="lineno"><pre>749</pre></td>
5540
    <td align="right" class="linebranch"></td>
5541
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5542
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_code = CODE_WRITE_SYNC;</pre></td>
5543
    </tr>
5544

    
5545
    <tr>
5546
    <td align="right" class="lineno"><pre>750</pre></td>
5547
    <td align="right" class="linebranch"></td>
5548
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5549
    <td align="left" class="src uncoveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5550
    </tr>
5551

    
5552
    <tr>
5553
    <td align="right" class="lineno"><pre>751</pre></td>
5554
    <td align="right" class="linebranch"></td>
5555
    <td align="right" class="linecount "><pre></pre></td>
5556
    <td align="left" class="src "><pre>    }</pre></td>
5557
    </tr>
5558

    
5559
    <tr>
5560
    <td align="right" class="lineno"><pre>752</pre></td>
5561
    <td align="right" class="linebranch"></td>
5562
    <td align="right" class="linecount "><pre></pre></td>
5563
    <td align="left" class="src "><pre>    // disconnect_err</pre></td>
5564
    </tr>
5565

    
5566
    <tr>
5567
    <td align="right" class="lineno"><pre>753</pre></td>
5568
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 6 times">&check;</span><span class="takenBranch" title="Branch 1 taken 129636 times">&check;</span></td>
5569
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5570
    <td align="left" class="src coveredLine"><pre>    if (previous.disconnect_err != current.disconnect_err)</pre></td>
5571
    </tr>
5572

    
5573
    <tr>
5574
    <td align="right" class="lineno"><pre>754</pre></td>
5575
    <td align="right" class="linebranch"></td>
5576
    <td align="right" class="linecount "><pre></pre></td>
5577
    <td align="left" class="src "><pre>    {</pre></td>
5578
    </tr>
5579

    
5580
    <tr>
5581
    <td align="right" class="lineno"><pre>755</pre></td>
5582
    <td align="right" class="linebranch"></td>
5583
    <td align="right" class="linecount coveredLine"><pre>6</pre></td>
5584
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_rid  = RID_LE_LFR_DPU_SPW;</pre></td>
5585
    </tr>
5586

    
5587
    <tr>
5588
    <td align="right" class="lineno"><pre>756</pre></td>
5589
    <td align="right" class="linebranch"></td>
5590
    <td align="right" class="linecount coveredLine"><pre>6</pre></td>
5591
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_code = CODE_DISCONNECT;</pre></td>
5592
    </tr>
5593

    
5594
    <tr>
5595
    <td align="right" class="lineno"><pre>757</pre></td>
5596
    <td align="right" class="linebranch"></td>
5597
    <td align="right" class="linecount coveredLine"><pre>6</pre></td>
5598
    <td align="left" class="src coveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5599
    </tr>
5600

    
5601
    <tr>
5602
    <td align="right" class="lineno"><pre>758</pre></td>
5603
    <td align="right" class="linebranch"></td>
5604
    <td align="right" class="linecount "><pre></pre></td>
5605
    <td align="left" class="src "><pre>    }</pre></td>
5606
    </tr>
5607

    
5608
    <tr>
5609
    <td align="right" class="lineno"><pre>759</pre></td>
5610
    <td align="right" class="linebranch"></td>
5611
    <td align="right" class="linecount "><pre></pre></td>
5612
    <td align="left" class="src "><pre>    // early_ep</pre></td>
5613
    </tr>
5614

    
5615
    <tr>
5616
    <td align="right" class="lineno"><pre>760</pre></td>
5617
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 129642 times">&check;</span></td>
5618
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5619
    <td align="left" class="src coveredLine"><pre>    if (previous.early_ep != current.early_ep)</pre></td>
5620
    </tr>
5621

    
5622
    <tr>
5623
    <td align="right" class="lineno"><pre>761</pre></td>
5624
    <td align="right" class="linebranch"></td>
5625
    <td align="right" class="linecount "><pre></pre></td>
5626
    <td align="left" class="src "><pre>    {</pre></td>
5627
    </tr>
5628

    
5629
    <tr>
5630
    <td align="right" class="lineno"><pre>762</pre></td>
5631
    <td align="right" class="linebranch"></td>
5632
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5633
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_rid  = RID_ME_LFR_DPU_SPW;</pre></td>
5634
    </tr>
5635

    
5636
    <tr>
5637
    <td align="right" class="lineno"><pre>763</pre></td>
5638
    <td align="right" class="linebranch"></td>
5639
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5640
    <td align="left" class="src uncoveredLine"><pre>        hk_lfr_last_er_code = CODE_EARLY_EOP_EEP;</pre></td>
5641
    </tr>
5642

    
5643
    <tr>
5644
    <td align="right" class="lineno"><pre>764</pre></td>
5645
    <td align="right" class="linebranch"></td>
5646
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
5647
    <td align="left" class="src uncoveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5648
    </tr>
5649

    
5650
    <tr>
5651
    <td align="right" class="lineno"><pre>765</pre></td>
5652
    <td align="right" class="linebranch"></td>
5653
    <td align="right" class="linecount "><pre></pre></td>
5654
    <td align="left" class="src "><pre>    }</pre></td>
5655
    </tr>
5656

    
5657
    <tr>
5658
    <td align="right" class="lineno"><pre>766</pre></td>
5659
    <td align="right" class="linebranch"></td>
5660
    <td align="right" class="linecount "><pre></pre></td>
5661
    <td align="left" class="src "><pre>    // invalid_address</pre></td>
5662
    </tr>
5663

    
5664
    <tr>
5665
    <td align="right" class="lineno"><pre>767</pre></td>
5666
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 2 times">&check;</span><span class="takenBranch" title="Branch 1 taken 129640 times">&check;</span></td>
5667
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5668
    <td align="left" class="src coveredLine"><pre>    if (previous.invalid_address != current.invalid_address)</pre></td>
5669
    </tr>
5670

    
5671
    <tr>
5672
    <td align="right" class="lineno"><pre>768</pre></td>
5673
    <td align="right" class="linebranch"></td>
5674
    <td align="right" class="linecount "><pre></pre></td>
5675
    <td align="left" class="src "><pre>    {</pre></td>
5676
    </tr>
5677

    
5678
    <tr>
5679
    <td align="right" class="lineno"><pre>769</pre></td>
5680
    <td align="right" class="linebranch"></td>
5681
    <td align="right" class="linecount coveredLine"><pre>2</pre></td>
5682
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_rid = RID_ME_LFR_DPU_SPW;</pre></td>
5683
    </tr>
5684

    
5685
    <tr>
5686
    <td align="right" class="lineno"><pre>770</pre></td>
5687
    <td align="right" class="linebranch"></td>
5688
    <td align="right" class="linecount coveredLine"><pre>2</pre></td>
5689
    <td align="left" class="src coveredLine"><pre>        hk_lfr_last_er_code = CODE_INVALID_ADDRESS;</pre></td>
5690
    </tr>
5691

    
5692
    <tr>
5693
    <td align="right" class="lineno"><pre>771</pre></td>
5694
    <td align="right" class="linebranch"></td>
5695
    <td align="right" class="linecount coveredLine"><pre>2</pre></td>
5696
    <td align="left" class="src coveredLine"><pre>        update_hk_lfr_last_er = 1;</pre></td>
5697
    </tr>
5698

    
5699
    <tr>
5700
    <td align="right" class="lineno"><pre>772</pre></td>
5701
    <td align="right" class="linebranch"></td>
5702
    <td align="right" class="linecount "><pre></pre></td>
5703
    <td align="left" class="src "><pre>    }</pre></td>
5704
    </tr>
5705

    
5706
    <tr>
5707
    <td align="right" class="lineno"><pre>773</pre></td>
5708
    <td align="right" class="linebranch"></td>
5709
    <td align="right" class="linecount "><pre></pre></td>
5710
    <td align="left" class="src "><pre></pre></td>
5711
    </tr>
5712

    
5713
    <tr>
5714
    <td align="right" class="lineno"><pre>774</pre></td>
5715
    <td align="right" class="linebranch"></td>
5716
    <td align="right" class="linecount "><pre></pre></td>
5717
    <td align="left" class="src "><pre>    // if a field has changed, update the hk_last_er fields</pre></td>
5718
    </tr>
5719

    
5720
    <tr>
5721
    <td align="right" class="lineno"><pre>775</pre></td>
5722
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 544 times">&check;</span><span class="takenBranch" title="Branch 1 taken 129098 times">&check;</span></td>
5723
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5724
    <td align="left" class="src coveredLine"><pre>    if (update_hk_lfr_last_er == 1)</pre></td>
5725
    </tr>
5726

    
5727
    <tr>
5728
    <td align="right" class="lineno"><pre>776</pre></td>
5729
    <td align="right" class="linebranch"></td>
5730
    <td align="right" class="linecount "><pre></pre></td>
5731
    <td align="left" class="src "><pre>    {</pre></td>
5732
    </tr>
5733

    
5734
    <tr>
5735
    <td align="right" class="lineno"><pre>777</pre></td>
5736
    <td align="right" class="linebranch"></td>
5737
    <td align="right" class="linecount coveredLine"><pre>544</pre></td>
5738
    <td align="left" class="src coveredLine"><pre>        update_hk_lfr_last_er_fields( hk_lfr_last_er_rid, hk_lfr_last_er_code );</pre></td>
5739
    </tr>
5740

    
5741
    <tr>
5742
    <td align="right" class="lineno"><pre>778</pre></td>
5743
    <td align="right" class="linebranch"></td>
5744
    <td align="right" class="linecount "><pre></pre></td>
5745
    <td align="left" class="src "><pre>    }</pre></td>
5746
    </tr>
5747

    
5748
    <tr>
5749
    <td align="right" class="lineno"><pre>779</pre></td>
5750
    <td align="right" class="linebranch"></td>
5751
    <td align="right" class="linecount "><pre></pre></td>
5752
    <td align="left" class="src "><pre></pre></td>
5753
    </tr>
5754

    
5755
    <tr>
5756
    <td align="right" class="lineno"><pre>780</pre></td>
5757
    <td align="right" class="linebranch"></td>
5758
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5759
    <td align="left" class="src coveredLine"><pre>    previous = current;</pre></td>
5760
    </tr>
5761

    
5762
    <tr>
5763
    <td align="right" class="lineno"><pre>781</pre></td>
5764
    <td align="right" class="linebranch"></td>
5765
    <td align="right" class="linecount coveredLine"><pre>129642</pre></td>
5766
    <td align="left" class="src coveredLine"><pre>}</pre></td>
5767
    </tr>
5768

    
5769
    <tr>
5770
    <td align="right" class="lineno"><pre>782</pre></td>
5771
    <td align="right" class="linebranch"></td>
5772
    <td align="right" class="linecount "><pre></pre></td>
5773
    <td align="left" class="src "><pre></pre></td>
5774
    </tr>
5775

    
5776
    <tr>
5777
    <td align="right" class="lineno"><pre>783</pre></td>
5778
    <td align="right" class="linebranch"></td>
5779
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5780
    <td align="left" class="src coveredLine"><pre>void update_hk_lfr_last_er_fields(unsigned int rid, unsigned char code)</pre></td>
5781
    </tr>
5782

    
5783
    <tr>
5784
    <td align="right" class="lineno"><pre>784</pre></td>
5785
    <td align="right" class="linebranch"></td>
5786
    <td align="right" class="linecount "><pre></pre></td>
5787
    <td align="left" class="src "><pre>{</pre></td>
5788
    </tr>
5789

    
5790
    <tr>
5791
    <td align="right" class="lineno"><pre>785</pre></td>
5792
    <td align="right" class="linebranch"></td>
5793
    <td align="right" class="linecount "><pre></pre></td>
5794
    <td align="left" class="src "><pre>    unsigned char *coarseTimePtr;</pre></td>
5795
    </tr>
5796

    
5797
    <tr>
5798
    <td align="right" class="lineno"><pre>786</pre></td>
5799
    <td align="right" class="linebranch"></td>
5800
    <td align="right" class="linecount "><pre></pre></td>
5801
    <td align="left" class="src "><pre>    unsigned char *fineTimePtr;</pre></td>
5802
    </tr>
5803

    
5804
    <tr>
5805
    <td align="right" class="lineno"><pre>787</pre></td>
5806
    <td align="right" class="linebranch"></td>
5807
    <td align="right" class="linecount "><pre></pre></td>
5808
    <td align="left" class="src "><pre></pre></td>
5809
    </tr>
5810

    
5811
    <tr>
5812
    <td align="right" class="lineno"><pre>788</pre></td>
5813
    <td align="right" class="linebranch"></td>
5814
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5815
    <td align="left" class="src coveredLine"><pre>    coarseTimePtr = (unsigned char*) &amp;time_management_regs->coarse_time;</pre></td>
5816
    </tr>
5817

    
5818
    <tr>
5819
    <td align="right" class="lineno"><pre>789</pre></td>
5820
    <td align="right" class="linebranch"></td>
5821
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5822
    <td align="left" class="src coveredLine"><pre>    fineTimePtr = (unsigned char*) &amp;time_management_regs->fine_time;</pre></td>
5823
    </tr>
5824

    
5825
    <tr>
5826
    <td align="right" class="lineno"><pre>790</pre></td>
5827
    <td align="right" class="linebranch"></td>
5828
    <td align="right" class="linecount "><pre></pre></td>
5829
    <td align="left" class="src "><pre></pre></td>
5830
    </tr>
5831

    
5832
    <tr>
5833
    <td align="right" class="lineno"><pre>791</pre></td>
5834
    <td align="right" class="linebranch"></td>
5835
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5836
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_rid[0]   = (unsigned char) ((rid &amp; BYTE0_MASK) >> SHIFT_1_BYTE );</pre></td>
5837
    </tr>
5838

    
5839
    <tr>
5840
    <td align="right" class="lineno"><pre>792</pre></td>
5841
    <td align="right" class="linebranch"></td>
5842
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5843
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_rid[1]   = (unsigned char)  (rid &amp; BYTE1_MASK);</pre></td>
5844
    </tr>
5845

    
5846
    <tr>
5847
    <td align="right" class="lineno"><pre>793</pre></td>
5848
    <td align="right" class="linebranch"></td>
5849
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5850
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_code     = code;</pre></td>
5851
    </tr>
5852

    
5853
    <tr>
5854
    <td align="right" class="lineno"><pre>794</pre></td>
5855
    <td align="right" class="linebranch"></td>
5856
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5857
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_time[0]  = coarseTimePtr[0];</pre></td>
5858
    </tr>
5859

    
5860
    <tr>
5861
    <td align="right" class="lineno"><pre>795</pre></td>
5862
    <td align="right" class="linebranch"></td>
5863
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5864
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_time[1]  = coarseTimePtr[1];</pre></td>
5865
    </tr>
5866

    
5867
    <tr>
5868
    <td align="right" class="lineno"><pre>796</pre></td>
5869
    <td align="right" class="linebranch"></td>
5870
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5871
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_time[BYTE_2]  = coarseTimePtr[BYTE_2];</pre></td>
5872
    </tr>
5873

    
5874
    <tr>
5875
    <td align="right" class="lineno"><pre>797</pre></td>
5876
    <td align="right" class="linebranch"></td>
5877
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5878
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_time[BYTE_3]  = coarseTimePtr[BYTE_3];</pre></td>
5879
    </tr>
5880

    
5881
    <tr>
5882
    <td align="right" class="lineno"><pre>798</pre></td>
5883
    <td align="right" class="linebranch"></td>
5884
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5885
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_time[BYTE_4]  = fineTimePtr[BYTE_2];</pre></td>
5886
    </tr>
5887

    
5888
    <tr>
5889
    <td align="right" class="lineno"><pre>799</pre></td>
5890
    <td align="right" class="linebranch"></td>
5891
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5892
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_last_er_time[BYTE_5]  = fineTimePtr[BYTE_3];</pre></td>
5893
    </tr>
5894

    
5895
    <tr>
5896
    <td align="right" class="lineno"><pre>800</pre></td>
5897
    <td align="right" class="linebranch"></td>
5898
    <td align="right" class="linecount coveredLine"><pre>4506</pre></td>
5899
    <td align="left" class="src coveredLine"><pre>}</pre></td>
5900
    </tr>
5901

    
5902
    <tr>
5903
    <td align="right" class="lineno"><pre>801</pre></td>
5904
    <td align="right" class="linebranch"></td>
5905
    <td align="right" class="linecount "><pre></pre></td>
5906
    <td align="left" class="src "><pre></pre></td>
5907
    </tr>
5908

    
5909
    <tr>
5910
    <td align="right" class="lineno"><pre>802</pre></td>
5911
    <td align="right" class="linebranch"></td>
5912
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
5913
    <td align="left" class="src coveredLine"><pre>void update_hk_with_grspw_stats( void )</pre></td>
5914
    </tr>
5915

    
5916
    <tr>
5917
    <td align="right" class="lineno"><pre>803</pre></td>
5918
    <td align="right" class="linebranch"></td>
5919
    <td align="right" class="linecount "><pre></pre></td>
5920
    <td align="left" class="src "><pre>{</pre></td>
5921
    </tr>
5922

    
5923
    <tr>
5924
    <td align="right" class="lineno"><pre>804</pre></td>
5925
    <td align="right" class="linebranch"></td>
5926
    <td align="right" class="linecount "><pre></pre></td>
5927
    <td align="left" class="src "><pre>    //****************************</pre></td>
5928
    </tr>
5929

    
5930
    <tr>
5931
    <td align="right" class="lineno"><pre>805</pre></td>
5932
    <td align="right" class="linebranch"></td>
5933
    <td align="right" class="linecount "><pre></pre></td>
5934
    <td align="left" class="src "><pre>    // DPU_SPACEWIRE_IF_STATISTICS</pre></td>
5935
    </tr>
5936

    
5937
    <tr>
5938
    <td align="right" class="lineno"><pre>806</pre></td>
5939
    <td align="right" class="linebranch"></td>
5940
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
5941
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_pkt_rcv_cnt[0]   = (unsigned char) (grspw_stats.packets_received >> SHIFT_1_BYTE);</pre></td>
5942
    </tr>
5943

    
5944
    <tr>
5945
    <td align="right" class="lineno"><pre>807</pre></td>
5946
    <td align="right" class="linebranch"></td>
5947
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
5948
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_pkt_rcv_cnt[1]   = (unsigned char) (grspw_stats.packets_received);</pre></td>
5949
    </tr>
5950

    
5951
    <tr>
5952
    <td align="right" class="lineno"><pre>808</pre></td>
5953
    <td align="right" class="linebranch"></td>
5954
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
5955
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_pkt_sent_cnt[0]  = (unsigned char) (grspw_stats.packets_sent >> SHIFT_1_BYTE);</pre></td>
5956
    </tr>
5957

    
5958
    <tr>
5959
    <td align="right" class="lineno"><pre>809</pre></td>
5960
    <td align="right" class="linebranch"></td>
5961
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
5962
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_pkt_sent_cnt[1]  = (unsigned char) (grspw_stats.packets_sent);</pre></td>
5963
    </tr>
5964

    
5965
    <tr>
5966
    <td align="right" class="lineno"><pre>810</pre></td>
5967
    <td align="right" class="linebranch"></td>
5968
    <td align="right" class="linecount "><pre></pre></td>
5969
    <td align="left" class="src "><pre></pre></td>
5970
    </tr>
5971

    
5972
    <tr>
5973
    <td align="right" class="lineno"><pre>811</pre></td>
5974
    <td align="right" class="linebranch"></td>
5975
    <td align="right" class="linecount "><pre></pre></td>
5976
    <td align="left" class="src "><pre>    //******************************************</pre></td>
5977
    </tr>
5978

    
5979
    <tr>
5980
    <td align="right" class="lineno"><pre>812</pre></td>
5981
    <td align="right" class="linebranch"></td>
5982
    <td align="right" class="linecount "><pre></pre></td>
5983
    <td align="left" class="src "><pre>    // ERROR COUNTERS / SPACEWIRE / LOW SEVERITY</pre></td>
5984
    </tr>
5985

    
5986
    <tr>
5987
    <td align="right" class="lineno"><pre>813</pre></td>
5988
    <td align="right" class="linebranch"></td>
5989
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
5990
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_parity       = (unsigned char) grspw_stats.parity_err;</pre></td>
5991
    </tr>
5992

    
5993
    <tr>
5994
    <td align="right" class="lineno"><pre>814</pre></td>
5995
    <td align="right" class="linebranch"></td>
5996
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
5997
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_disconnect   = (unsigned char) grspw_stats.disconnect_err;</pre></td>
5998
    </tr>
5999

    
6000
    <tr>
6001
    <td align="right" class="lineno"><pre>815</pre></td>
6002
    <td align="right" class="linebranch"></td>
6003
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6004
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_escape       = (unsigned char) grspw_stats.escape_err;</pre></td>
6005
    </tr>
6006

    
6007
    <tr>
6008
    <td align="right" class="lineno"><pre>816</pre></td>
6009
    <td align="right" class="linebranch"></td>
6010
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6011
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_credit       = (unsigned char) grspw_stats.credit_err;</pre></td>
6012
    </tr>
6013

    
6014
    <tr>
6015
    <td align="right" class="lineno"><pre>817</pre></td>
6016
    <td align="right" class="linebranch"></td>
6017
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6018
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_write_sync   = (unsigned char) grspw_stats.write_sync_err;</pre></td>
6019
    </tr>
6020

    
6021
    <tr>
6022
    <td align="right" class="lineno"><pre>818</pre></td>
6023
    <td align="right" class="linebranch"></td>
6024
    <td align="right" class="linecount "><pre></pre></td>
6025
    <td align="left" class="src "><pre></pre></td>
6026
    </tr>
6027

    
6028
    <tr>
6029
    <td align="right" class="lineno"><pre>819</pre></td>
6030
    <td align="right" class="linebranch"></td>
6031
    <td align="right" class="linecount "><pre></pre></td>
6032
    <td align="left" class="src "><pre>    //*********************************************</pre></td>
6033
    </tr>
6034

    
6035
    <tr>
6036
    <td align="right" class="lineno"><pre>820</pre></td>
6037
    <td align="right" class="linebranch"></td>
6038
    <td align="right" class="linecount "><pre></pre></td>
6039
    <td align="left" class="src "><pre>    // ERROR COUNTERS / SPACEWIRE / MEDIUM SEVERITY</pre></td>
6040
    </tr>
6041

    
6042
    <tr>
6043
    <td align="right" class="lineno"><pre>821</pre></td>
6044
    <td align="right" class="linebranch"></td>
6045
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6046
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_early_eop    = (unsigned char) grspw_stats.early_ep;</pre></td>
6047
    </tr>
6048

    
6049
    <tr>
6050
    <td align="right" class="lineno"><pre>822</pre></td>
6051
    <td align="right" class="linebranch"></td>
6052
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6053
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_invalid_addr = (unsigned char) grspw_stats.invalid_address;</pre></td>
6054
    </tr>
6055

    
6056
    <tr>
6057
    <td align="right" class="lineno"><pre>823</pre></td>
6058
    <td align="right" class="linebranch"></td>
6059
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6060
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_eep          = (unsigned char) grspw_stats.rx_eep_err;</pre></td>
6061
    </tr>
6062

    
6063
    <tr>
6064
    <td align="right" class="lineno"><pre>824</pre></td>
6065
    <td align="right" class="linebranch"></td>
6066
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6067
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_rx_too_big   = (unsigned char) grspw_stats.rx_truncated;</pre></td>
6068
    </tr>
6069

    
6070
    <tr>
6071
    <td align="right" class="lineno"><pre>825</pre></td>
6072
    <td align="right" class="linebranch"></td>
6073
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6074
    <td align="left" class="src coveredLine"><pre>}</pre></td>
6075
    </tr>
6076

    
6077
    <tr>
6078
    <td align="right" class="lineno"><pre>826</pre></td>
6079
    <td align="right" class="linebranch"></td>
6080
    <td align="right" class="linecount "><pre></pre></td>
6081
    <td align="left" class="src "><pre></pre></td>
6082
    </tr>
6083

    
6084
    <tr>
6085
    <td align="right" class="lineno"><pre>827</pre></td>
6086
    <td align="right" class="linebranch"></td>
6087
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6088
    <td align="left" class="src coveredLine"><pre>void spacewire_update_hk_lfr_link_state( unsigned char *hk_lfr_status_word_0 )</pre></td>
6089
    </tr>
6090

    
6091
    <tr>
6092
    <td align="right" class="lineno"><pre>828</pre></td>
6093
    <td align="right" class="linebranch"></td>
6094
    <td align="right" class="linecount "><pre></pre></td>
6095
    <td align="left" class="src "><pre>{</pre></td>
6096
    </tr>
6097

    
6098
    <tr>
6099
    <td align="right" class="lineno"><pre>829</pre></td>
6100
    <td align="right" class="linebranch"></td>
6101
    <td align="right" class="linecount "><pre></pre></td>
6102
    <td align="left" class="src "><pre>    unsigned int *statusRegisterPtr;</pre></td>
6103
    </tr>
6104

    
6105
    <tr>
6106
    <td align="right" class="lineno"><pre>830</pre></td>
6107
    <td align="right" class="linebranch"></td>
6108
    <td align="right" class="linecount "><pre></pre></td>
6109
    <td align="left" class="src "><pre>    unsigned char linkState;</pre></td>
6110
    </tr>
6111

    
6112
    <tr>
6113
    <td align="right" class="lineno"><pre>831</pre></td>
6114
    <td align="right" class="linebranch"></td>
6115
    <td align="right" class="linecount "><pre></pre></td>
6116
    <td align="left" class="src "><pre></pre></td>
6117
    </tr>
6118

    
6119
    <tr>
6120
    <td align="right" class="lineno"><pre>832</pre></td>
6121
    <td align="right" class="linebranch"></td>
6122
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6123
    <td align="left" class="src coveredLine"><pre>    statusRegisterPtr = (unsigned int *) (REGS_ADDR_GRSPW + APB_OFFSET_GRSPW_STATUS_REGISTER);</pre></td>
6124
    </tr>
6125

    
6126
    <tr>
6127
    <td align="right" class="lineno"><pre>833</pre></td>
6128
    <td align="right" class="linebranch"></td>
6129
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6130
    <td align="left" class="src coveredLine"><pre>    linkState =</pre></td>
6131
    </tr>
6132

    
6133
    <tr>
6134
    <td align="right" class="lineno"><pre>834</pre></td>
6135
    <td align="right" class="linebranch"></td>
6136
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6137
    <td align="left" class="src coveredLine"><pre>            (unsigned char) ( ( (*statusRegisterPtr) >>  SPW_LINK_STAT_POS) &amp; STATUS_WORD_LINK_STATE_BITS);   // [0000 0111]</pre></td>
6138
    </tr>
6139

    
6140
    <tr>
6141
    <td align="right" class="lineno"><pre>835</pre></td>
6142
    <td align="right" class="linebranch"></td>
6143
    <td align="right" class="linecount "><pre></pre></td>
6144
    <td align="left" class="src "><pre></pre></td>
6145
    </tr>
6146

    
6147
    <tr>
6148
    <td align="right" class="lineno"><pre>836</pre></td>
6149
    <td align="right" class="linebranch"></td>
6150
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6151
    <td align="left" class="src coveredLine"><pre>    *hk_lfr_status_word_0 = *hk_lfr_status_word_0 &amp; STATUS_WORD_LINK_STATE_MASK;       // [1111 1000] set link state to 0</pre></td>
6152
    </tr>
6153

    
6154
    <tr>
6155
    <td align="right" class="lineno"><pre>837</pre></td>
6156
    <td align="right" class="linebranch"></td>
6157
    <td align="right" class="linecount "><pre></pre></td>
6158
    <td align="left" class="src "><pre></pre></td>
6159
    </tr>
6160

    
6161
    <tr>
6162
    <td align="right" class="lineno"><pre>838</pre></td>
6163
    <td align="right" class="linebranch"></td>
6164
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6165
    <td align="left" class="src coveredLine"><pre>    *hk_lfr_status_word_0 = *hk_lfr_status_word_0 | linkState;  // update hk_lfr_dpu_spw_link_state</pre></td>
6166
    </tr>
6167

    
6168
    <tr>
6169
    <td align="right" class="lineno"><pre>839</pre></td>
6170
    <td align="right" class="linebranch"></td>
6171
    <td align="right" class="linecount coveredLine"><pre>129632</pre></td>
6172
    <td align="left" class="src coveredLine"><pre>}</pre></td>
6173
    </tr>
6174

    
6175
    <tr>
6176
    <td align="right" class="lineno"><pre>840</pre></td>
6177
    <td align="right" class="linebranch"></td>
6178
    <td align="right" class="linecount "><pre></pre></td>
6179
    <td align="left" class="src "><pre></pre></td>
6180
    </tr>
6181

    
6182
    <tr>
6183
    <td align="right" class="lineno"><pre>841</pre></td>
6184
    <td align="right" class="linebranch"></td>
6185
    <td align="right" class="linecount coveredLine"><pre>6193</pre></td>
6186
    <td align="left" class="src coveredLine"><pre>void increase_unsigned_char_counter( unsigned char *counter )</pre></td>
6187
    </tr>
6188

    
6189
    <tr>
6190
    <td align="right" class="lineno"><pre>842</pre></td>
6191
    <td align="right" class="linebranch"></td>
6192
    <td align="right" class="linecount "><pre></pre></td>
6193
    <td align="left" class="src "><pre>{</pre></td>
6194
    </tr>
6195

    
6196
    <tr>
6197
    <td align="right" class="lineno"><pre>843</pre></td>
6198
    <td align="right" class="linebranch"></td>
6199
    <td align="right" class="linecount "><pre></pre></td>
6200
    <td align="left" class="src "><pre>    // update the number of valid timecodes that have been received</pre></td>
6201
    </tr>
6202

    
6203
    <tr>
6204
    <td align="right" class="lineno"><pre>844</pre></td>
6205
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 8 times">&check;</span><span class="takenBranch" title="Branch 1 taken 6185 times">&check;</span></td>
6206
    <td align="right" class="linecount coveredLine"><pre>6193</pre></td>
6207
    <td align="left" class="src coveredLine"><pre>    if (*counter == UINT8_MAX)</pre></td>
6208
    </tr>
6209

    
6210
    <tr>
6211
    <td align="right" class="lineno"><pre>845</pre></td>
6212
    <td align="right" class="linebranch"></td>
6213
    <td align="right" class="linecount "><pre></pre></td>
6214
    <td align="left" class="src "><pre>    {</pre></td>
6215
    </tr>
6216

    
6217
    <tr>
6218
    <td align="right" class="lineno"><pre>846</pre></td>
6219
    <td align="right" class="linebranch"></td>
6220
    <td align="right" class="linecount coveredLine"><pre>8</pre></td>
6221
    <td align="left" class="src coveredLine"><pre>        *counter = 0;</pre></td>
6222
    </tr>
6223

    
6224
    <tr>
6225
    <td align="right" class="lineno"><pre>847</pre></td>
6226
    <td align="right" class="linebranch"></td>
6227
    <td align="right" class="linecount "><pre></pre></td>
6228
    <td align="left" class="src "><pre>    }</pre></td>
6229
    </tr>
6230

    
6231
    <tr>
6232
    <td align="right" class="lineno"><pre>848</pre></td>
6233
    <td align="right" class="linebranch"></td>
6234
    <td align="right" class="linecount "><pre></pre></td>
6235
    <td align="left" class="src "><pre>    else</pre></td>
6236
    </tr>
6237

    
6238
    <tr>
6239
    <td align="right" class="lineno"><pre>849</pre></td>
6240
    <td align="right" class="linebranch"></td>
6241
    <td align="right" class="linecount "><pre></pre></td>
6242
    <td align="left" class="src "><pre>    {</pre></td>
6243
    </tr>
6244

    
6245
    <tr>
6246
    <td align="right" class="lineno"><pre>850</pre></td>
6247
    <td align="right" class="linebranch"></td>
6248
    <td align="right" class="linecount coveredLine"><pre>6185</pre></td>
6249
    <td align="left" class="src coveredLine"><pre>        *counter = *counter + 1;</pre></td>
6250
    </tr>
6251

    
6252
    <tr>
6253
    <td align="right" class="lineno"><pre>851</pre></td>
6254
    <td align="right" class="linebranch"></td>
6255
    <td align="right" class="linecount "><pre></pre></td>
6256
    <td align="left" class="src "><pre>    }</pre></td>
6257
    </tr>
6258

    
6259
    <tr>
6260
    <td align="right" class="lineno"><pre>852</pre></td>
6261
    <td align="right" class="linebranch"></td>
6262
    <td align="right" class="linecount coveredLine"><pre>6193</pre></td>
6263
    <td align="left" class="src coveredLine"><pre>}</pre></td>
6264
    </tr>
6265

    
6266
    <tr>
6267
    <td align="right" class="lineno"><pre>853</pre></td>
6268
    <td align="right" class="linebranch"></td>
6269
    <td align="right" class="linecount "><pre></pre></td>
6270
    <td align="left" class="src "><pre></pre></td>
6271
    </tr>
6272

    
6273
    <tr>
6274
    <td align="right" class="lineno"><pre>854</pre></td>
6275
    <td align="right" class="linebranch"></td>
6276
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6277
    <td align="left" class="src coveredLine"><pre>unsigned int check_timecode_and_previous_timecode_coherency(unsigned char currentTimecodeCtr)</pre></td>
6278
    </tr>
6279

    
6280
    <tr>
6281
    <td align="right" class="lineno"><pre>855</pre></td>
6282
    <td align="right" class="linebranch"></td>
6283
    <td align="right" class="linecount "><pre></pre></td>
6284
    <td align="left" class="src "><pre>{</pre></td>
6285
    </tr>
6286

    
6287
    <tr>
6288
    <td align="right" class="lineno"><pre>856</pre></td>
6289
    <td align="right" class="linebranch"></td>
6290
    <td align="right" class="linecount "><pre></pre></td>
6291
    <td align="left" class="src "><pre>    /** This function checks the coherency between the incoming timecode and the last valid timecode.</pre></td>
6292
    </tr>
6293

    
6294
    <tr>
6295
    <td align="right" class="lineno"><pre>857</pre></td>
6296
    <td align="right" class="linebranch"></td>
6297
    <td align="right" class="linecount "><pre></pre></td>
6298
    <td align="left" class="src "><pre>     *</pre></td>
6299
    </tr>
6300

    
6301
    <tr>
6302
    <td align="right" class="lineno"><pre>858</pre></td>
6303
    <td align="right" class="linebranch"></td>
6304
    <td align="right" class="linecount "><pre></pre></td>
6305
    <td align="left" class="src "><pre>     * @param currentTimecodeCtr is the incoming timecode</pre></td>
6306
    </tr>
6307

    
6308
    <tr>
6309
    <td align="right" class="lineno"><pre>859</pre></td>
6310
    <td align="right" class="linebranch"></td>
6311
    <td align="right" class="linecount "><pre></pre></td>
6312
    <td align="left" class="src "><pre>     *</pre></td>
6313
    </tr>
6314

    
6315
    <tr>
6316
    <td align="right" class="lineno"><pre>860</pre></td>
6317
    <td align="right" class="linebranch"></td>
6318
    <td align="right" class="linecount "><pre></pre></td>
6319
    <td align="left" class="src "><pre>     * @return returned codes::</pre></td>
6320
    </tr>
6321

    
6322
    <tr>
6323
    <td align="right" class="lineno"><pre>861</pre></td>
6324
    <td align="right" class="linebranch"></td>
6325
    <td align="right" class="linecount "><pre></pre></td>
6326
    <td align="left" class="src "><pre>     * - LFR_DEFAULT</pre></td>
6327
    </tr>
6328

    
6329
    <tr>
6330
    <td align="right" class="lineno"><pre>862</pre></td>
6331
    <td align="right" class="linebranch"></td>
6332
    <td align="right" class="linecount "><pre></pre></td>
6333
    <td align="left" class="src "><pre>     * - LFR_SUCCESSFUL</pre></td>
6334
    </tr>
6335

    
6336
    <tr>
6337
    <td align="right" class="lineno"><pre>863</pre></td>
6338
    <td align="right" class="linebranch"></td>
6339
    <td align="right" class="linecount "><pre></pre></td>
6340
    <td align="left" class="src "><pre>     *</pre></td>
6341
    </tr>
6342

    
6343
    <tr>
6344
    <td align="right" class="lineno"><pre>864</pre></td>
6345
    <td align="right" class="linebranch"></td>
6346
    <td align="right" class="linecount "><pre></pre></td>
6347
    <td align="left" class="src "><pre>     */</pre></td>
6348
    </tr>
6349

    
6350
    <tr>
6351
    <td align="right" class="lineno"><pre>865</pre></td>
6352
    <td align="right" class="linebranch"></td>
6353
    <td align="right" class="linecount "><pre></pre></td>
6354
    <td align="left" class="src "><pre></pre></td>
6355
    </tr>
6356

    
6357
    <tr>
6358
    <td align="right" class="lineno"><pre>866</pre></td>
6359
    <td align="right" class="linebranch"></td>
6360
    <td align="right" class="linecount "><pre></pre></td>
6361
    <td align="left" class="src "><pre>    static unsigned char firstTickout = 1;</pre></td>
6362
    </tr>
6363

    
6364
    <tr>
6365
    <td align="right" class="lineno"><pre>867</pre></td>
6366
    <td align="right" class="linebranch"></td>
6367
    <td align="right" class="linecount "><pre></pre></td>
6368
    <td align="left" class="src "><pre>    unsigned char ret;</pre></td>
6369
    </tr>
6370

    
6371
    <tr>
6372
    <td align="right" class="lineno"><pre>868</pre></td>
6373
    <td align="right" class="linebranch"></td>
6374
    <td align="right" class="linecount "><pre></pre></td>
6375
    <td align="left" class="src "><pre></pre></td>
6376
    </tr>
6377

    
6378
    <tr>
6379
    <td align="right" class="lineno"><pre>869</pre></td>
6380
    <td align="right" class="linebranch"></td>
6381
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6382
    <td align="left" class="src coveredLine"><pre>    ret = LFR_DEFAULT;</pre></td>
6383
    </tr>
6384

    
6385
    <tr>
6386
    <td align="right" class="lineno"><pre>870</pre></td>
6387
    <td align="right" class="linebranch"></td>
6388
    <td align="right" class="linecount "><pre></pre></td>
6389
    <td align="left" class="src "><pre></pre></td>
6390
    </tr>
6391

    
6392
    <tr>
6393
    <td align="right" class="lineno"><pre>871</pre></td>
6394
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 2207 times">&check;</span><span class="takenBranch" title="Branch 1 taken 24 times">&check;</span></td>
6395
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6396
    <td align="left" class="src coveredLine"><pre>    if (firstTickout == 0)</pre></td>
6397
    </tr>
6398

    
6399
    <tr>
6400
    <td align="right" class="lineno"><pre>872</pre></td>
6401
    <td align="right" class="linebranch"></td>
6402
    <td align="right" class="linecount "><pre></pre></td>
6403
    <td align="left" class="src "><pre>    {</pre></td>
6404
    </tr>
6405

    
6406
    <tr>
6407
    <td align="right" class="lineno"><pre>873</pre></td>
6408
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 26 times">&check;</span><span class="takenBranch" title="Branch 1 taken 2181 times">&check;</span></td>
6409
    <td align="right" class="linecount coveredLine"><pre>2207</pre></td>
6410
    <td align="left" class="src coveredLine"><pre>        if (currentTimecodeCtr == 0)</pre></td>
6411
    </tr>
6412

    
6413
    <tr>
6414
    <td align="right" class="lineno"><pre>874</pre></td>
6415
    <td align="right" class="linebranch"></td>
6416
    <td align="right" class="linecount "><pre></pre></td>
6417
    <td align="left" class="src "><pre>        {</pre></td>
6418
    </tr>
6419

    
6420
    <tr>
6421
    <td align="right" class="lineno"><pre>875</pre></td>
6422
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 26 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
6423
    <td align="right" class="linecount coveredLine"><pre>26</pre></td>
6424
    <td align="left" class="src coveredLine"><pre>            if (previousTimecodeCtr == SPW_TIMECODE_MAX)</pre></td>
6425
    </tr>
6426

    
6427
    <tr>
6428
    <td align="right" class="lineno"><pre>876</pre></td>
6429
    <td align="right" class="linebranch"></td>
6430
    <td align="right" class="linecount "><pre></pre></td>
6431
    <td align="left" class="src "><pre>            {</pre></td>
6432
    </tr>
6433

    
6434
    <tr>
6435
    <td align="right" class="lineno"><pre>877</pre></td>
6436
    <td align="right" class="linebranch"></td>
6437
    <td align="right" class="linecount coveredLine"><pre>26</pre></td>
6438
    <td align="left" class="src coveredLine"><pre>                ret = LFR_SUCCESSFUL;</pre></td>
6439
    </tr>
6440

    
6441
    <tr>
6442
    <td align="right" class="lineno"><pre>878</pre></td>
6443
    <td align="right" class="linebranch"></td>
6444
    <td align="right" class="linecount "><pre></pre></td>
6445
    <td align="left" class="src "><pre>            }</pre></td>
6446
    </tr>
6447

    
6448
    <tr>
6449
    <td align="right" class="lineno"><pre>879</pre></td>
6450
    <td align="right" class="linebranch"></td>
6451
    <td align="right" class="linecount "><pre></pre></td>
6452
    <td align="left" class="src "><pre>            else</pre></td>
6453
    </tr>
6454

    
6455
    <tr>
6456
    <td align="right" class="lineno"><pre>880</pre></td>
6457
    <td align="right" class="linebranch"></td>
6458
    <td align="right" class="linecount "><pre></pre></td>
6459
    <td align="left" class="src "><pre>            {</pre></td>
6460
    </tr>
6461

    
6462
    <tr>
6463
    <td align="right" class="lineno"><pre>881</pre></td>
6464
    <td align="right" class="linebranch"></td>
6465
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
6466
    <td align="left" class="src uncoveredLine"><pre>                ret = LFR_DEFAULT;</pre></td>
6467
    </tr>
6468

    
6469
    <tr>
6470
    <td align="right" class="lineno"><pre>882</pre></td>
6471
    <td align="right" class="linebranch"></td>
6472
    <td align="right" class="linecount "><pre></pre></td>
6473
    <td align="left" class="src "><pre>            }</pre></td>
6474
    </tr>
6475

    
6476
    <tr>
6477
    <td align="right" class="lineno"><pre>883</pre></td>
6478
    <td align="right" class="linebranch"></td>
6479
    <td align="right" class="linecount "><pre></pre></td>
6480
    <td align="left" class="src "><pre>        }</pre></td>
6481
    </tr>
6482

    
6483
    <tr>
6484
    <td align="right" class="lineno"><pre>884</pre></td>
6485
    <td align="right" class="linebranch"></td>
6486
    <td align="right" class="linecount "><pre></pre></td>
6487
    <td align="left" class="src "><pre>        else</pre></td>
6488
    </tr>
6489

    
6490
    <tr>
6491
    <td align="right" class="lineno"><pre>885</pre></td>
6492
    <td align="right" class="linebranch"></td>
6493
    <td align="right" class="linecount "><pre></pre></td>
6494
    <td align="left" class="src "><pre>        {</pre></td>
6495
    </tr>
6496

    
6497
    <tr>
6498
    <td align="right" class="lineno"><pre>886</pre></td>
6499
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 2176 times">&check;</span><span class="takenBranch" title="Branch 1 taken 5 times">&check;</span></td>
6500
    <td align="right" class="linecount coveredLine"><pre>2181</pre></td>
6501
    <td align="left" class="src coveredLine"><pre>            if (currentTimecodeCtr == (previousTimecodeCtr +1))</pre></td>
6502
    </tr>
6503

    
6504
    <tr>
6505
    <td align="right" class="lineno"><pre>887</pre></td>
6506
    <td align="right" class="linebranch"></td>
6507
    <td align="right" class="linecount "><pre></pre></td>
6508
    <td align="left" class="src "><pre>            {</pre></td>
6509
    </tr>
6510

    
6511
    <tr>
6512
    <td align="right" class="lineno"><pre>888</pre></td>
6513
    <td align="right" class="linebranch"></td>
6514
    <td align="right" class="linecount coveredLine"><pre>2176</pre></td>
6515
    <td align="left" class="src coveredLine"><pre>                ret = LFR_SUCCESSFUL;</pre></td>
6516
    </tr>
6517

    
6518
    <tr>
6519
    <td align="right" class="lineno"><pre>889</pre></td>
6520
    <td align="right" class="linebranch"></td>
6521
    <td align="right" class="linecount "><pre></pre></td>
6522
    <td align="left" class="src "><pre>            }</pre></td>
6523
    </tr>
6524

    
6525
    <tr>
6526
    <td align="right" class="lineno"><pre>890</pre></td>
6527
    <td align="right" class="linebranch"></td>
6528
    <td align="right" class="linecount "><pre></pre></td>
6529
    <td align="left" class="src "><pre>            else</pre></td>
6530
    </tr>
6531

    
6532
    <tr>
6533
    <td align="right" class="lineno"><pre>891</pre></td>
6534
    <td align="right" class="linebranch"></td>
6535
    <td align="right" class="linecount "><pre></pre></td>
6536
    <td align="left" class="src "><pre>            {</pre></td>
6537
    </tr>
6538

    
6539
    <tr>
6540
    <td align="right" class="lineno"><pre>892</pre></td>
6541
    <td align="right" class="linebranch"></td>
6542
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
6543
    <td align="left" class="src coveredLine"><pre>                ret = LFR_DEFAULT;</pre></td>
6544
    </tr>
6545

    
6546
    <tr>
6547
    <td align="right" class="lineno"><pre>893</pre></td>
6548
    <td align="right" class="linebranch"></td>
6549
    <td align="right" class="linecount "><pre></pre></td>
6550
    <td align="left" class="src "><pre>            }</pre></td>
6551
    </tr>
6552

    
6553
    <tr>
6554
    <td align="right" class="lineno"><pre>894</pre></td>
6555
    <td align="right" class="linebranch"></td>
6556
    <td align="right" class="linecount "><pre></pre></td>
6557
    <td align="left" class="src "><pre>        }</pre></td>
6558
    </tr>
6559

    
6560
    <tr>
6561
    <td align="right" class="lineno"><pre>895</pre></td>
6562
    <td align="right" class="linebranch"></td>
6563
    <td align="right" class="linecount "><pre></pre></td>
6564
    <td align="left" class="src "><pre>    }</pre></td>
6565
    </tr>
6566

    
6567
    <tr>
6568
    <td align="right" class="lineno"><pre>896</pre></td>
6569
    <td align="right" class="linebranch"></td>
6570
    <td align="right" class="linecount "><pre></pre></td>
6571
    <td align="left" class="src "><pre>    else</pre></td>
6572
    </tr>
6573

    
6574
    <tr>
6575
    <td align="right" class="lineno"><pre>897</pre></td>
6576
    <td align="right" class="linebranch"></td>
6577
    <td align="right" class="linecount "><pre></pre></td>
6578
    <td align="left" class="src "><pre>    {</pre></td>
6579
    </tr>
6580

    
6581
    <tr>
6582
    <td align="right" class="lineno"><pre>898</pre></td>
6583
    <td align="right" class="linebranch"></td>
6584
    <td align="right" class="linecount coveredLine"><pre>24</pre></td>
6585
    <td align="left" class="src coveredLine"><pre>        firstTickout = 0;</pre></td>
6586
    </tr>
6587

    
6588
    <tr>
6589
    <td align="right" class="lineno"><pre>899</pre></td>
6590
    <td align="right" class="linebranch"></td>
6591
    <td align="right" class="linecount coveredLine"><pre>24</pre></td>
6592
    <td align="left" class="src coveredLine"><pre>        ret = LFR_SUCCESSFUL;</pre></td>
6593
    </tr>
6594

    
6595
    <tr>
6596
    <td align="right" class="lineno"><pre>900</pre></td>
6597
    <td align="right" class="linebranch"></td>
6598
    <td align="right" class="linecount "><pre></pre></td>
6599
    <td align="left" class="src "><pre>    }</pre></td>
6600
    </tr>
6601

    
6602
    <tr>
6603
    <td align="right" class="lineno"><pre>901</pre></td>
6604
    <td align="right" class="linebranch"></td>
6605
    <td align="right" class="linecount "><pre></pre></td>
6606
    <td align="left" class="src "><pre></pre></td>
6607
    </tr>
6608

    
6609
    <tr>
6610
    <td align="right" class="lineno"><pre>902</pre></td>
6611
    <td align="right" class="linebranch"></td>
6612
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6613
    <td align="left" class="src coveredLine"><pre>    return ret;</pre></td>
6614
    </tr>
6615

    
6616
    <tr>
6617
    <td align="right" class="lineno"><pre>903</pre></td>
6618
    <td align="right" class="linebranch"></td>
6619
    <td align="right" class="linecount "><pre></pre></td>
6620
    <td align="left" class="src "><pre>}</pre></td>
6621
    </tr>
6622

    
6623
    <tr>
6624
    <td align="right" class="lineno"><pre>904</pre></td>
6625
    <td align="right" class="linebranch"></td>
6626
    <td align="right" class="linecount "><pre></pre></td>
6627
    <td align="left" class="src "><pre></pre></td>
6628
    </tr>
6629

    
6630
    <tr>
6631
    <td align="right" class="lineno"><pre>905</pre></td>
6632
    <td align="right" class="linebranch"></td>
6633
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6634
    <td align="left" class="src coveredLine"><pre>unsigned int check_timecode_and_internal_time_coherency(unsigned char timecode, unsigned char internalTime)</pre></td>
6635
    </tr>
6636

    
6637
    <tr>
6638
    <td align="right" class="lineno"><pre>906</pre></td>
6639
    <td align="right" class="linebranch"></td>
6640
    <td align="right" class="linecount "><pre></pre></td>
6641
    <td align="left" class="src "><pre>{</pre></td>
6642
    </tr>
6643

    
6644
    <tr>
6645
    <td align="right" class="lineno"><pre>907</pre></td>
6646
    <td align="right" class="linebranch"></td>
6647
    <td align="right" class="linecount "><pre></pre></td>
6648
    <td align="left" class="src "><pre>    unsigned int ret;</pre></td>
6649
    </tr>
6650

    
6651
    <tr>
6652
    <td align="right" class="lineno"><pre>908</pre></td>
6653
    <td align="right" class="linebranch"></td>
6654
    <td align="right" class="linecount "><pre></pre></td>
6655
    <td align="left" class="src "><pre></pre></td>
6656
    </tr>
6657

    
6658
    <tr>
6659
    <td align="right" class="lineno"><pre>909</pre></td>
6660
    <td align="right" class="linebranch"></td>
6661
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6662
    <td align="left" class="src coveredLine"><pre>    ret = LFR_DEFAULT;</pre></td>
6663
    </tr>
6664

    
6665
    <tr>
6666
    <td align="right" class="lineno"><pre>910</pre></td>
6667
    <td align="right" class="linebranch"></td>
6668
    <td align="right" class="linecount "><pre></pre></td>
6669
    <td align="left" class="src "><pre></pre></td>
6670
    </tr>
6671

    
6672
    <tr>
6673
    <td align="right" class="lineno"><pre>911</pre></td>
6674
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 735 times">&check;</span><span class="takenBranch" title="Branch 1 taken 1496 times">&check;</span></td>
6675
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6676
    <td align="left" class="src coveredLine"><pre>    if (timecode == internalTime)</pre></td>
6677
    </tr>
6678

    
6679
    <tr>
6680
    <td align="right" class="lineno"><pre>912</pre></td>
6681
    <td align="right" class="linebranch"></td>
6682
    <td align="right" class="linecount "><pre></pre></td>
6683
    <td align="left" class="src "><pre>    {</pre></td>
6684
    </tr>
6685

    
6686
    <tr>
6687
    <td align="right" class="lineno"><pre>913</pre></td>
6688
    <td align="right" class="linebranch"></td>
6689
    <td align="right" class="linecount coveredLine"><pre>735</pre></td>
6690
    <td align="left" class="src coveredLine"><pre>        ret = LFR_SUCCESSFUL;</pre></td>
6691
    </tr>
6692

    
6693
    <tr>
6694
    <td align="right" class="lineno"><pre>914</pre></td>
6695
    <td align="right" class="linebranch"></td>
6696
    <td align="right" class="linecount "><pre></pre></td>
6697
    <td align="left" class="src "><pre>    }</pre></td>
6698
    </tr>
6699

    
6700
    <tr>
6701
    <td align="right" class="lineno"><pre>915</pre></td>
6702
    <td align="right" class="linebranch"></td>
6703
    <td align="right" class="linecount "><pre></pre></td>
6704
    <td align="left" class="src "><pre>    else</pre></td>
6705
    </tr>
6706

    
6707
    <tr>
6708
    <td align="right" class="lineno"><pre>916</pre></td>
6709
    <td align="right" class="linebranch"></td>
6710
    <td align="right" class="linecount "><pre></pre></td>
6711
    <td align="left" class="src "><pre>    {</pre></td>
6712
    </tr>
6713

    
6714
    <tr>
6715
    <td align="right" class="lineno"><pre>917</pre></td>
6716
    <td align="right" class="linebranch"></td>
6717
    <td align="right" class="linecount coveredLine"><pre>1496</pre></td>
6718
    <td align="left" class="src coveredLine"><pre>        ret = LFR_DEFAULT;</pre></td>
6719
    </tr>
6720

    
6721
    <tr>
6722
    <td align="right" class="lineno"><pre>918</pre></td>
6723
    <td align="right" class="linebranch"></td>
6724
    <td align="right" class="linecount "><pre></pre></td>
6725
    <td align="left" class="src "><pre>    }</pre></td>
6726
    </tr>
6727

    
6728
    <tr>
6729
    <td align="right" class="lineno"><pre>919</pre></td>
6730
    <td align="right" class="linebranch"></td>
6731
    <td align="right" class="linecount "><pre></pre></td>
6732
    <td align="left" class="src "><pre></pre></td>
6733
    </tr>
6734

    
6735
    <tr>
6736
    <td align="right" class="lineno"><pre>920</pre></td>
6737
    <td align="right" class="linebranch"></td>
6738
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6739
    <td align="left" class="src coveredLine"><pre>    return ret;</pre></td>
6740
    </tr>
6741

    
6742
    <tr>
6743
    <td align="right" class="lineno"><pre>921</pre></td>
6744
    <td align="right" class="linebranch"></td>
6745
    <td align="right" class="linecount "><pre></pre></td>
6746
    <td align="left" class="src "><pre>}</pre></td>
6747
    </tr>
6748

    
6749
    <tr>
6750
    <td align="right" class="lineno"><pre>922</pre></td>
6751
    <td align="right" class="linebranch"></td>
6752
    <td align="right" class="linecount "><pre></pre></td>
6753
    <td align="left" class="src "><pre></pre></td>
6754
    </tr>
6755

    
6756
    <tr>
6757
    <td align="right" class="lineno"><pre>923</pre></td>
6758
    <td align="right" class="linebranch"></td>
6759
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6760
    <td align="left" class="src coveredLine"><pre>void timecode_irq_handler( void *pDev, void *regs, int minor, unsigned int tc )</pre></td>
6761
    </tr>
6762

    
6763
    <tr>
6764
    <td align="right" class="lineno"><pre>924</pre></td>
6765
    <td align="right" class="linebranch"></td>
6766
    <td align="right" class="linecount "><pre></pre></td>
6767
    <td align="left" class="src "><pre>{</pre></td>
6768
    </tr>
6769

    
6770
    <tr>
6771
    <td align="right" class="lineno"><pre>925</pre></td>
6772
    <td align="right" class="linebranch"></td>
6773
    <td align="right" class="linecount "><pre></pre></td>
6774
    <td align="left" class="src "><pre>    // a tickout has been emitted, perform actions on the incoming timecode</pre></td>
6775
    </tr>
6776

    
6777
    <tr>
6778
    <td align="right" class="lineno"><pre>926</pre></td>
6779
    <td align="right" class="linebranch"></td>
6780
    <td align="right" class="linecount "><pre></pre></td>
6781
    <td align="left" class="src "><pre></pre></td>
6782
    </tr>
6783

    
6784
    <tr>
6785
    <td align="right" class="lineno"><pre>927</pre></td>
6786
    <td align="right" class="linebranch"></td>
6787
    <td align="right" class="linecount "><pre></pre></td>
6788
    <td align="left" class="src "><pre>    unsigned char incomingTimecode;</pre></td>
6789
    </tr>
6790

    
6791
    <tr>
6792
    <td align="right" class="lineno"><pre>928</pre></td>
6793
    <td align="right" class="linebranch"></td>
6794
    <td align="right" class="linecount "><pre></pre></td>
6795
    <td align="left" class="src "><pre>    unsigned char updateTime;</pre></td>
6796
    </tr>
6797

    
6798
    <tr>
6799
    <td align="right" class="lineno"><pre>929</pre></td>
6800
    <td align="right" class="linebranch"></td>
6801
    <td align="right" class="linecount "><pre></pre></td>
6802
    <td align="left" class="src "><pre>    unsigned char internalTime;</pre></td>
6803
    </tr>
6804

    
6805
    <tr>
6806
    <td align="right" class="lineno"><pre>930</pre></td>
6807
    <td align="right" class="linebranch"></td>
6808
    <td align="right" class="linecount "><pre></pre></td>
6809
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
6810
    </tr>
6811

    
6812
    <tr>
6813
    <td align="right" class="lineno"><pre>931</pre></td>
6814
    <td align="right" class="linebranch"></td>
6815
    <td align="right" class="linecount "><pre></pre></td>
6816
    <td align="left" class="src "><pre></pre></td>
6817
    </tr>
6818

    
6819
    <tr>
6820
    <td align="right" class="lineno"><pre>932</pre></td>
6821
    <td align="right" class="linebranch"></td>
6822
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6823
    <td align="left" class="src coveredLine"><pre>    incomingTimecode =        (unsigned char) (grspwPtr[0] &amp; TIMECODE_MASK);</pre></td>
6824
    </tr>
6825

    
6826
    <tr>
6827
    <td align="right" class="lineno"><pre>933</pre></td>
6828
    <td align="right" class="linebranch"></td>
6829
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6830
    <td align="left" class="src coveredLine"><pre>    updateTime    = time_management_regs->coarse_time_load &amp; TIMECODE_MASK;</pre></td>
6831
    </tr>
6832

    
6833
    <tr>
6834
    <td align="right" class="lineno"><pre>934</pre></td>
6835
    <td align="right" class="linebranch"></td>
6836
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6837
    <td align="left" class="src coveredLine"><pre>    internalTime  = time_management_regs->coarse_time      &amp; TIMECODE_MASK;</pre></td>
6838
    </tr>
6839

    
6840
    <tr>
6841
    <td align="right" class="lineno"><pre>935</pre></td>
6842
    <td align="right" class="linebranch"></td>
6843
    <td align="right" class="linecount "><pre></pre></td>
6844
    <td align="left" class="src "><pre></pre></td>
6845
    </tr>
6846

    
6847
    <tr>
6848
    <td align="right" class="lineno"><pre>936</pre></td>
6849
    <td align="right" class="linebranch"></td>
6850
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6851
    <td align="left" class="src coveredLine"><pre>    housekeeping_packet.hk_lfr_dpu_spw_last_timc = incomingTimecode;</pre></td>
6852
    </tr>
6853

    
6854
    <tr>
6855
    <td align="right" class="lineno"><pre>937</pre></td>
6856
    <td align="right" class="linebranch"></td>
6857
    <td align="right" class="linecount "><pre></pre></td>
6858
    <td align="left" class="src "><pre></pre></td>
6859
    </tr>
6860

    
6861
    <tr>
6862
    <td align="right" class="lineno"><pre>938</pre></td>
6863
    <td align="right" class="linebranch"></td>
6864
    <td align="right" class="linecount "><pre></pre></td>
6865
    <td align="left" class="src "><pre>    // update the number of tickout that have been generated</pre></td>
6866
    </tr>
6867

    
6868
    <tr>
6869
    <td align="right" class="lineno"><pre>939</pre></td>
6870
    <td align="right" class="linebranch"></td>
6871
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6872
    <td align="left" class="src coveredLine"><pre>    increase_unsigned_char_counter( &amp;housekeeping_packet.hk_lfr_dpu_spw_tick_out_cnt );</pre></td>
6873
    </tr>
6874

    
6875
    <tr>
6876
    <td align="right" class="lineno"><pre>940</pre></td>
6877
    <td align="right" class="linebranch"></td>
6878
    <td align="right" class="linecount "><pre></pre></td>
6879
    <td align="left" class="src "><pre></pre></td>
6880
    </tr>
6881

    
6882
    <tr>
6883
    <td align="right" class="lineno"><pre>941</pre></td>
6884
    <td align="right" class="linebranch"></td>
6885
    <td align="right" class="linecount "><pre></pre></td>
6886
    <td align="left" class="src "><pre>    //**************************</pre></td>
6887
    </tr>
6888

    
6889
    <tr>
6890
    <td align="right" class="lineno"><pre>942</pre></td>
6891
    <td align="right" class="linebranch"></td>
6892
    <td align="right" class="linecount "><pre></pre></td>
6893
    <td align="left" class="src "><pre>    // HK_LFR_TIMECODE_ERRONEOUS</pre></td>
6894
    </tr>
6895

    
6896
    <tr>
6897
    <td align="right" class="lineno"><pre>943</pre></td>
6898
    <td align="right" class="linebranch"></td>
6899
    <td align="right" class="linecount "><pre></pre></td>
6900
    <td align="left" class="src "><pre>    // MISSING and INVALID are handled by the timecode_timer_routine service routine</pre></td>
6901
    </tr>
6902

    
6903
    <tr>
6904
    <td align="right" class="lineno"><pre>944</pre></td>
6905
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 1 taken 5 times">&check;</span><span class="takenBranch" title="Branch 2 taken 2226 times">&check;</span></td>
6906
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6907
    <td align="left" class="src coveredLine"><pre>    if (check_timecode_and_previous_timecode_coherency( incomingTimecode ) == LFR_DEFAULT)</pre></td>
6908
    </tr>
6909

    
6910
    <tr>
6911
    <td align="right" class="lineno"><pre>945</pre></td>
6912
    <td align="right" class="linebranch"></td>
6913
    <td align="right" class="linecount "><pre></pre></td>
6914
    <td align="left" class="src "><pre>    {</pre></td>
6915
    </tr>
6916

    
6917
    <tr>
6918
    <td align="right" class="lineno"><pre>946</pre></td>
6919
    <td align="right" class="linebranch"></td>
6920
    <td align="right" class="linecount "><pre></pre></td>
6921
    <td align="left" class="src "><pre>        // this is unexpected but a tickout could have been raised despite of the timecode being erroneous</pre></td>
6922
    </tr>
6923

    
6924
    <tr>
6925
    <td align="right" class="lineno"><pre>947</pre></td>
6926
    <td align="right" class="linebranch"></td>
6927
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
6928
    <td align="left" class="src coveredLine"><pre>        increase_unsigned_char_counter( &amp;housekeeping_packet.hk_lfr_timecode_erroneous );</pre></td>
6929
    </tr>
6930

    
6931
    <tr>
6932
    <td align="right" class="lineno"><pre>948</pre></td>
6933
    <td align="right" class="linebranch"></td>
6934
    <td align="right" class="linecount coveredLine"><pre>5</pre></td>
6935
    <td align="left" class="src coveredLine"><pre>        update_hk_lfr_last_er_fields( RID_LE_LFR_TIMEC, CODE_ERRONEOUS );</pre></td>
6936
    </tr>
6937

    
6938
    <tr>
6939
    <td align="right" class="lineno"><pre>949</pre></td>
6940
    <td align="right" class="linebranch"></td>
6941
    <td align="right" class="linecount "><pre></pre></td>
6942
    <td align="left" class="src "><pre>    }</pre></td>
6943
    </tr>
6944

    
6945
    <tr>
6946
    <td align="right" class="lineno"><pre>950</pre></td>
6947
    <td align="right" class="linebranch"></td>
6948
    <td align="right" class="linecount "><pre></pre></td>
6949
    <td align="left" class="src "><pre></pre></td>
6950
    </tr>
6951

    
6952
    <tr>
6953
    <td align="right" class="lineno"><pre>951</pre></td>
6954
    <td align="right" class="linebranch"></td>
6955
    <td align="right" class="linecount "><pre></pre></td>
6956
    <td align="left" class="src "><pre>    //************************</pre></td>
6957
    </tr>
6958

    
6959
    <tr>
6960
    <td align="right" class="lineno"><pre>952</pre></td>
6961
    <td align="right" class="linebranch"></td>
6962
    <td align="right" class="linecount "><pre></pre></td>
6963
    <td align="left" class="src "><pre>    // HK_LFR_TIME_TIMECODE_IT</pre></td>
6964
    </tr>
6965

    
6966
    <tr>
6967
    <td align="right" class="lineno"><pre>953</pre></td>
6968
    <td align="right" class="linebranch"></td>
6969
    <td align="right" class="linecount "><pre></pre></td>
6970
    <td align="left" class="src "><pre>    // check the coherency between the SpaceWire timecode and the Internal Time</pre></td>
6971
    </tr>
6972

    
6973
    <tr>
6974
    <td align="right" class="lineno"><pre>954</pre></td>
6975
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 1 taken 1496 times">&check;</span><span class="takenBranch" title="Branch 2 taken 735 times">&check;</span></td>
6976
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
6977
    <td align="left" class="src coveredLine"><pre>    if (check_timecode_and_internal_time_coherency( incomingTimecode, internalTime ) == LFR_DEFAULT)</pre></td>
6978
    </tr>
6979

    
6980
    <tr>
6981
    <td align="right" class="lineno"><pre>955</pre></td>
6982
    <td align="right" class="linebranch"></td>
6983
    <td align="right" class="linecount "><pre></pre></td>
6984
    <td align="left" class="src "><pre>    {</pre></td>
6985
    </tr>
6986

    
6987
    <tr>
6988
    <td align="right" class="lineno"><pre>956</pre></td>
6989
    <td align="right" class="linebranch"></td>
6990
    <td align="right" class="linecount coveredLine"><pre>1496</pre></td>
6991
    <td align="left" class="src coveredLine"><pre>        increase_unsigned_char_counter( &amp;housekeeping_packet.hk_lfr_time_timecode_it );</pre></td>
6992
    </tr>
6993

    
6994
    <tr>
6995
    <td align="right" class="lineno"><pre>957</pre></td>
6996
    <td align="right" class="linebranch"></td>
6997
    <td align="right" class="linecount coveredLine"><pre>1496</pre></td>
6998
    <td align="left" class="src coveredLine"><pre>        update_hk_lfr_last_er_fields( RID_LE_LFR_TIME, CODE_TIMECODE_IT );</pre></td>
6999
    </tr>
7000

    
7001
    <tr>
7002
    <td align="right" class="lineno"><pre>958</pre></td>
7003
    <td align="right" class="linebranch"></td>
7004
    <td align="right" class="linecount "><pre></pre></td>
7005
    <td align="left" class="src "><pre>    }</pre></td>
7006
    </tr>
7007

    
7008
    <tr>
7009
    <td align="right" class="lineno"><pre>959</pre></td>
7010
    <td align="right" class="linebranch"></td>
7011
    <td align="right" class="linecount "><pre></pre></td>
7012
    <td align="left" class="src "><pre></pre></td>
7013
    </tr>
7014

    
7015
    <tr>
7016
    <td align="right" class="lineno"><pre>960</pre></td>
7017
    <td align="right" class="linebranch"></td>
7018
    <td align="right" class="linecount "><pre></pre></td>
7019
    <td align="left" class="src "><pre>    //********************</pre></td>
7020
    </tr>
7021

    
7022
    <tr>
7023
    <td align="right" class="lineno"><pre>961</pre></td>
7024
    <td align="right" class="linebranch"></td>
7025
    <td align="right" class="linecount "><pre></pre></td>
7026
    <td align="left" class="src "><pre>    // HK_LFR_TIMECODE_CTR</pre></td>
7027
    </tr>
7028

    
7029
    <tr>
7030
    <td align="right" class="lineno"><pre>962</pre></td>
7031
    <td align="right" class="linebranch"></td>
7032
    <td align="right" class="linecount "><pre></pre></td>
7033
    <td align="left" class="src "><pre>    // check the value of the timecode with respect to the last TC_LFR_UPDATE_TIME => SSS-CP-FS-370</pre></td>
7034
    </tr>
7035

    
7036
    <tr>
7037
    <td align="right" class="lineno"><pre>963</pre></td>
7038
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 2006 times">&check;</span><span class="takenBranch" title="Branch 1 taken 225 times">&check;</span></td>
7039
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
7040
    <td align="left" class="src coveredLine"><pre>    if (oneTcLfrUpdateTimeReceived == 1)</pre></td>
7041
    </tr>
7042

    
7043
    <tr>
7044
    <td align="right" class="lineno"><pre>964</pre></td>
7045
    <td align="right" class="linebranch"></td>
7046
    <td align="right" class="linecount "><pre></pre></td>
7047
    <td align="left" class="src "><pre>    {</pre></td>
7048
    </tr>
7049

    
7050
    <tr>
7051
    <td align="right" class="lineno"><pre>965</pre></td>
7052
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 1660 times">&check;</span><span class="takenBranch" title="Branch 1 taken 346 times">&check;</span></td>
7053
    <td align="right" class="linecount coveredLine"><pre>2006</pre></td>
7054
    <td align="left" class="src coveredLine"><pre>        if ( incomingTimecode != updateTime )</pre></td>
7055
    </tr>
7056

    
7057
    <tr>
7058
    <td align="right" class="lineno"><pre>966</pre></td>
7059
    <td align="right" class="linebranch"></td>
7060
    <td align="right" class="linecount "><pre></pre></td>
7061
    <td align="left" class="src "><pre>        {</pre></td>
7062
    </tr>
7063

    
7064
    <tr>
7065
    <td align="right" class="lineno"><pre>967</pre></td>
7066
    <td align="right" class="linebranch"></td>
7067
    <td align="right" class="linecount coveredLine"><pre>1660</pre></td>
7068
    <td align="left" class="src coveredLine"><pre>            increase_unsigned_char_counter( &amp;housekeeping_packet.hk_lfr_time_timecode_ctr );</pre></td>
7069
    </tr>
7070

    
7071
    <tr>
7072
    <td align="right" class="lineno"><pre>968</pre></td>
7073
    <td align="right" class="linebranch"></td>
7074
    <td align="right" class="linecount coveredLine"><pre>1660</pre></td>
7075
    <td align="left" class="src coveredLine"><pre>            update_hk_lfr_last_er_fields( RID_LE_LFR_TIME, CODE_TIMECODE_CTR );</pre></td>
7076
    </tr>
7077

    
7078
    <tr>
7079
    <td align="right" class="lineno"><pre>969</pre></td>
7080
    <td align="right" class="linebranch"></td>
7081
    <td align="right" class="linecount "><pre></pre></td>
7082
    <td align="left" class="src "><pre>        }</pre></td>
7083
    </tr>
7084

    
7085
    <tr>
7086
    <td align="right" class="lineno"><pre>970</pre></td>
7087
    <td align="right" class="linebranch"></td>
7088
    <td align="right" class="linecount "><pre></pre></td>
7089
    <td align="left" class="src "><pre>    }</pre></td>
7090
    </tr>
7091

    
7092
    <tr>
7093
    <td align="right" class="lineno"><pre>971</pre></td>
7094
    <td align="right" class="linebranch"></td>
7095
    <td align="right" class="linecount "><pre></pre></td>
7096
    <td align="left" class="src "><pre></pre></td>
7097
    </tr>
7098

    
7099
    <tr>
7100
    <td align="right" class="lineno"><pre>972</pre></td>
7101
    <td align="right" class="linebranch"></td>
7102
    <td align="right" class="linecount "><pre></pre></td>
7103
    <td align="left" class="src "><pre>    // launch the timecode timer to detect missing or invalid timecodes</pre></td>
7104
    </tr>
7105

    
7106
    <tr>
7107
    <td align="right" class="lineno"><pre>973</pre></td>
7108
    <td align="right" class="linebranch"></td>
7109
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
7110
    <td align="left" class="src coveredLine"><pre>    previousTimecodeCtr = incomingTimecode;  // update the previousTimecodeCtr value</pre></td>
7111
    </tr>
7112

    
7113
    <tr>
7114
    <td align="right" class="lineno"><pre>974</pre></td>
7115
    <td align="right" class="linebranch"></td>
7116
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
7117
    <td align="left" class="src coveredLine"><pre>    status = rtems_timer_fire_after( timecode_timer_id, TIMECODE_TIMER_TIMEOUT, timecode_timer_routine, NULL );</pre></td>
7118
    </tr>
7119

    
7120
    <tr>
7121
    <td align="right" class="lineno"><pre>975</pre></td>
7122
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 2231 times">&check;</span></td>
7123
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
7124
    <td align="left" class="src coveredLine"><pre>    if (status != RTEMS_SUCCESSFUL)</pre></td>
7125
    </tr>
7126

    
7127
    <tr>
7128
    <td align="right" class="lineno"><pre>976</pre></td>
7129
    <td align="right" class="linebranch"></td>
7130
    <td align="right" class="linecount "><pre></pre></td>
7131
    <td align="left" class="src "><pre>    {</pre></td>
7132
    </tr>
7133

    
7134
    <tr>
7135
    <td align="right" class="lineno"><pre>977</pre></td>
7136
    <td align="right" class="linebranch"></td>
7137
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
7138
    <td align="left" class="src uncoveredLine"><pre>        rtems_event_send( Task_id[TASKID_DUMB], RTEMS_EVENT_14 );</pre></td>
7139
    </tr>
7140

    
7141
    <tr>
7142
    <td align="right" class="lineno"><pre>978</pre></td>
7143
    <td align="right" class="linebranch"></td>
7144
    <td align="right" class="linecount "><pre></pre></td>
7145
    <td align="left" class="src "><pre>    }</pre></td>
7146
    </tr>
7147

    
7148
    <tr>
7149
    <td align="right" class="lineno"><pre>979</pre></td>
7150
    <td align="right" class="linebranch"></td>
7151
    <td align="right" class="linecount coveredLine"><pre>2231</pre></td>
7152
    <td align="left" class="src coveredLine"><pre>}</pre></td>
7153
    </tr>
7154

    
7155
    <tr>
7156
    <td align="right" class="lineno"><pre>980</pre></td>
7157
    <td align="right" class="linebranch"></td>
7158
    <td align="right" class="linecount "><pre></pre></td>
7159
    <td align="left" class="src "><pre></pre></td>
7160
    </tr>
7161

    
7162
    <tr>
7163
    <td align="right" class="lineno"><pre>981</pre></td>
7164
    <td align="right" class="linebranch"></td>
7165
    <td align="right" class="linecount coveredLine"><pre>771</pre></td>
7166
    <td align="left" class="src coveredLine"><pre>rtems_timer_service_routine timecode_timer_routine( rtems_id timer_id, void *user_data )</pre></td>
7167
    </tr>
7168

    
7169
    <tr>
7170
    <td align="right" class="lineno"><pre>982</pre></td>
7171
    <td align="right" class="linebranch"></td>
7172
    <td align="right" class="linecount "><pre></pre></td>
7173
    <td align="left" class="src "><pre>{</pre></td>
7174
    </tr>
7175

    
7176
    <tr>
7177
    <td align="right" class="lineno"><pre>983</pre></td>
7178
    <td align="right" class="linebranch"></td>
7179
    <td align="right" class="linecount "><pre></pre></td>
7180
    <td align="left" class="src "><pre>    static unsigned char initStep = 1;</pre></td>
7181
    </tr>
7182

    
7183
    <tr>
7184
    <td align="right" class="lineno"><pre>984</pre></td>
7185
    <td align="right" class="linebranch"></td>
7186
    <td align="right" class="linecount "><pre></pre></td>
7187
    <td align="left" class="src "><pre></pre></td>
7188
    </tr>
7189

    
7190
    <tr>
7191
    <td align="right" class="lineno"><pre>985</pre></td>
7192
    <td align="right" class="linebranch"></td>
7193
    <td align="right" class="linecount "><pre></pre></td>
7194
    <td align="left" class="src "><pre>    unsigned char currentTimecodeCtr;</pre></td>
7195
    </tr>
7196

    
7197
    <tr>
7198
    <td align="right" class="lineno"><pre>986</pre></td>
7199
    <td align="right" class="linebranch"></td>
7200
    <td align="right" class="linecount "><pre></pre></td>
7201
    <td align="left" class="src "><pre></pre></td>
7202
    </tr>
7203

    
7204
    <tr>
7205
    <td align="right" class="lineno"><pre>987</pre></td>
7206
    <td align="right" class="linebranch"></td>
7207
    <td align="right" class="linecount coveredLine"><pre>771</pre></td>
7208
    <td align="left" class="src coveredLine"><pre>    currentTimecodeCtr = (unsigned char) (grspwPtr[0] &amp; TIMECODE_MASK);</pre></td>
7209
    </tr>
7210

    
7211
    <tr>
7212
    <td align="right" class="lineno"><pre>988</pre></td>
7213
    <td align="right" class="linebranch"></td>
7214
    <td align="right" class="linecount "><pre></pre></td>
7215
    <td align="left" class="src "><pre></pre></td>
7216
    </tr>
7217

    
7218
    <tr>
7219
    <td align="right" class="lineno"><pre>989</pre></td>
7220
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 771 times">&check;</span><span class="notTakenBranch" title="Branch 1 not taken">&cross;</span></td>
7221
    <td align="right" class="linecount coveredLine"><pre>771</pre></td>
7222
    <td align="left" class="src coveredLine"><pre>    if (initStep == 1)</pre></td>
7223
    </tr>
7224

    
7225
    <tr>
7226
    <td align="right" class="lineno"><pre>990</pre></td>
7227
    <td align="right" class="linebranch"></td>
7228
    <td align="right" class="linecount "><pre></pre></td>
7229
    <td align="left" class="src "><pre>    {</pre></td>
7230
    </tr>
7231

    
7232
    <tr>
7233
    <td align="right" class="lineno"><pre>991</pre></td>
7234
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 751 times">&check;</span><span class="takenBranch" title="Branch 1 taken 20 times">&check;</span></td>
7235
    <td align="right" class="linecount coveredLine"><pre>771</pre></td>
7236
    <td align="left" class="src coveredLine"><pre>        if (currentTimecodeCtr == previousTimecodeCtr)</pre></td>
7237
    </tr>
7238

    
7239
    <tr>
7240
    <td align="right" class="lineno"><pre>992</pre></td>
7241
    <td align="right" class="linebranch"></td>
7242
    <td align="right" class="linecount "><pre></pre></td>
7243
    <td align="left" class="src "><pre>        {</pre></td>
7244
    </tr>
7245

    
7246
    <tr>
7247
    <td align="right" class="lineno"><pre>993</pre></td>
7248
    <td align="right" class="linebranch"></td>
7249
    <td align="right" class="linecount "><pre></pre></td>
7250
    <td align="left" class="src "><pre>            //************************</pre></td>
7251
    </tr>
7252

    
7253
    <tr>
7254
    <td align="right" class="lineno"><pre>994</pre></td>
7255
    <td align="right" class="linebranch"></td>
7256
    <td align="right" class="linecount "><pre></pre></td>
7257
    <td align="left" class="src "><pre>            // HK_LFR_TIMECODE_MISSING</pre></td>
7258
    </tr>
7259

    
7260
    <tr>
7261
    <td align="right" class="lineno"><pre>995</pre></td>
7262
    <td align="right" class="linebranch"></td>
7263
    <td align="right" class="linecount "><pre></pre></td>
7264
    <td align="left" class="src "><pre>            // the timecode value has not changed, no valid timecode has been received, the timecode is MISSING</pre></td>
7265
    </tr>
7266

    
7267
    <tr>
7268
    <td align="right" class="lineno"><pre>996</pre></td>
7269
    <td align="right" class="linebranch"></td>
7270
    <td align="right" class="linecount coveredLine"><pre>751</pre></td>
7271
    <td align="left" class="src coveredLine"><pre>            increase_unsigned_char_counter( &amp;housekeeping_packet.hk_lfr_timecode_missing );</pre></td>
7272
    </tr>
7273

    
7274
    <tr>
7275
    <td align="right" class="lineno"><pre>997</pre></td>
7276
    <td align="right" class="linebranch"></td>
7277
    <td align="right" class="linecount coveredLine"><pre>751</pre></td>
7278
    <td align="left" class="src coveredLine"><pre>            update_hk_lfr_last_er_fields( RID_LE_LFR_TIMEC, CODE_MISSING );</pre></td>
7279
    </tr>
7280

    
7281
    <tr>
7282
    <td align="right" class="lineno"><pre>998</pre></td>
7283
    <td align="right" class="linebranch"></td>
7284
    <td align="right" class="linecount "><pre></pre></td>
7285
    <td align="left" class="src "><pre>        }</pre></td>
7286
    </tr>
7287

    
7288
    <tr>
7289
    <td align="right" class="lineno"><pre>999</pre></td>
7290
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 17 times">&check;</span><span class="takenBranch" title="Branch 1 taken 3 times">&check;</span></td>
7291
    <td align="right" class="linecount coveredLine"><pre>20</pre></td>
7292
    <td align="left" class="src coveredLine"><pre>        else if (currentTimecodeCtr == (previousTimecodeCtr+1))</pre></td>
7293
    </tr>
7294

    
7295
    <tr>
7296
    <td align="right" class="lineno"><pre>1000</pre></td>
7297
    <td align="right" class="linebranch"></td>
7298
    <td align="right" class="linecount "><pre></pre></td>
7299
    <td align="left" class="src "><pre>        {</pre></td>
7300
    </tr>
7301

    
7302
    <tr>
7303
    <td align="right" class="lineno"><pre>1001</pre></td>
7304
    <td align="right" class="linebranch"></td>
7305
    <td align="right" class="linecount "><pre></pre></td>
7306
    <td align="left" class="src "><pre>            // the timecode value has changed and the value is valid, this is unexpected because</pre></td>
7307
    </tr>
7308

    
7309
    <tr>
7310
    <td align="right" class="lineno"><pre>1002</pre></td>
7311
    <td align="right" class="linebranch"></td>
7312
    <td align="right" class="linecount "><pre></pre></td>
7313
    <td align="left" class="src "><pre>            // the timer should not have fired, the timecode_irq_handler should have been raised</pre></td>
7314
    </tr>
7315

    
7316
    <tr>
7317
    <td align="right" class="lineno"><pre>1003</pre></td>
7318
    <td align="right" class="linebranch"></td>
7319
    <td align="right" class="linecount "><pre></pre></td>
7320
    <td align="left" class="src "><pre>        }</pre></td>
7321
    </tr>
7322

    
7323
    <tr>
7324
    <td align="right" class="lineno"><pre>1004</pre></td>
7325
    <td align="right" class="linebranch"></td>
7326
    <td align="right" class="linecount "><pre></pre></td>
7327
    <td align="left" class="src "><pre>        else</pre></td>
7328
    </tr>
7329

    
7330
    <tr>
7331
    <td align="right" class="lineno"><pre>1005</pre></td>
7332
    <td align="right" class="linebranch"></td>
7333
    <td align="right" class="linecount "><pre></pre></td>
7334
    <td align="left" class="src "><pre>        {</pre></td>
7335
    </tr>
7336

    
7337
    <tr>
7338
    <td align="right" class="lineno"><pre>1006</pre></td>
7339
    <td align="right" class="linebranch"></td>
7340
    <td align="right" class="linecount "><pre></pre></td>
7341
    <td align="left" class="src "><pre>            //************************</pre></td>
7342
    </tr>
7343

    
7344
    <tr>
7345
    <td align="right" class="lineno"><pre>1007</pre></td>
7346
    <td align="right" class="linebranch"></td>
7347
    <td align="right" class="linecount "><pre></pre></td>
7348
    <td align="left" class="src "><pre>            // HK_LFR_TIMECODE_INVALID</pre></td>
7349
    </tr>
7350

    
7351
    <tr>
7352
    <td align="right" class="lineno"><pre>1008</pre></td>
7353
    <td align="right" class="linebranch"></td>
7354
    <td align="right" class="linecount "><pre></pre></td>
7355
    <td align="left" class="src "><pre>            // the timecode value has changed and the value is not valid, no tickout has been generated</pre></td>
7356
    </tr>
7357

    
7358
    <tr>
7359
    <td align="right" class="lineno"><pre>1009</pre></td>
7360
    <td align="right" class="linebranch"></td>
7361
    <td align="right" class="linecount "><pre></pre></td>
7362
    <td align="left" class="src "><pre>            // this is why the timer has fired</pre></td>
7363
    </tr>
7364

    
7365
    <tr>
7366
    <td align="right" class="lineno"><pre>1010</pre></td>
7367
    <td align="right" class="linebranch"></td>
7368
    <td align="right" class="linecount coveredLine"><pre>17</pre></td>
7369
    <td align="left" class="src coveredLine"><pre>            increase_unsigned_char_counter( &amp;housekeeping_packet.hk_lfr_timecode_invalid );</pre></td>
7370
    </tr>
7371

    
7372
    <tr>
7373
    <td align="right" class="lineno"><pre>1011</pre></td>
7374
    <td align="right" class="linebranch"></td>
7375
    <td align="right" class="linecount coveredLine"><pre>17</pre></td>
7376
    <td align="left" class="src coveredLine"><pre>            update_hk_lfr_last_er_fields( RID_LE_LFR_TIMEC, CODE_INVALID );</pre></td>
7377
    </tr>
7378

    
7379
    <tr>
7380
    <td align="right" class="lineno"><pre>1012</pre></td>
7381
    <td align="right" class="linebranch"></td>
7382
    <td align="right" class="linecount "><pre></pre></td>
7383
    <td align="left" class="src "><pre>        }</pre></td>
7384
    </tr>
7385

    
7386
    <tr>
7387
    <td align="right" class="lineno"><pre>1013</pre></td>
7388
    <td align="right" class="linebranch"></td>
7389
    <td align="right" class="linecount "><pre></pre></td>
7390
    <td align="left" class="src "><pre>    }</pre></td>
7391
    </tr>
7392

    
7393
    <tr>
7394
    <td align="right" class="lineno"><pre>1014</pre></td>
7395
    <td align="right" class="linebranch"></td>
7396
    <td align="right" class="linecount "><pre></pre></td>
7397
    <td align="left" class="src "><pre>    else</pre></td>
7398
    </tr>
7399

    
7400
    <tr>
7401
    <td align="right" class="lineno"><pre>1015</pre></td>
7402
    <td align="right" class="linebranch"></td>
7403
    <td align="right" class="linecount "><pre></pre></td>
7404
    <td align="left" class="src "><pre>    {</pre></td>
7405
    </tr>
7406

    
7407
    <tr>
7408
    <td align="right" class="lineno"><pre>1016</pre></td>
7409
    <td align="right" class="linebranch"></td>
7410
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
7411
    <td align="left" class="src uncoveredLine"><pre>        initStep = 1;</pre></td>
7412
    </tr>
7413

    
7414
    <tr>
7415
    <td align="right" class="lineno"><pre>1017</pre></td>
7416
    <td align="right" class="linebranch"></td>
7417
    <td align="right" class="linecount "><pre></pre></td>
7418
    <td align="left" class="src "><pre>        //************************</pre></td>
7419
    </tr>
7420

    
7421
    <tr>
7422
    <td align="right" class="lineno"><pre>1018</pre></td>
7423
    <td align="right" class="linebranch"></td>
7424
    <td align="right" class="linecount "><pre></pre></td>
7425
    <td align="left" class="src "><pre>        // HK_LFR_TIMECODE_MISSING</pre></td>
7426
    </tr>
7427

    
7428
    <tr>
7429
    <td align="right" class="lineno"><pre>1019</pre></td>
7430
    <td align="right" class="linebranch"></td>
7431
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
7432
    <td align="left" class="src uncoveredLine"><pre>        increase_unsigned_char_counter( &amp;housekeeping_packet.hk_lfr_timecode_missing );</pre></td>
7433
    </tr>
7434

    
7435
    <tr>
7436
    <td align="right" class="lineno"><pre>1020</pre></td>
7437
    <td align="right" class="linebranch"></td>
7438
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
7439
    <td align="left" class="src uncoveredLine"><pre>        update_hk_lfr_last_er_fields( RID_LE_LFR_TIMEC, CODE_MISSING );</pre></td>
7440
    </tr>
7441

    
7442
    <tr>
7443
    <td align="right" class="lineno"><pre>1021</pre></td>
7444
    <td align="right" class="linebranch"></td>
7445
    <td align="right" class="linecount "><pre></pre></td>
7446
    <td align="left" class="src "><pre>    }</pre></td>
7447
    </tr>
7448

    
7449
    <tr>
7450
    <td align="right" class="lineno"><pre>1022</pre></td>
7451
    <td align="right" class="linebranch"></td>
7452
    <td align="right" class="linecount "><pre></pre></td>
7453
    <td align="left" class="src "><pre></pre></td>
7454
    </tr>
7455

    
7456
    <tr>
7457
    <td align="right" class="lineno"><pre>1023</pre></td>
7458
    <td align="right" class="linebranch"></td>
7459
    <td align="right" class="linecount coveredLine"><pre>771</pre></td>
7460
    <td align="left" class="src coveredLine"><pre>    rtems_event_send( Task_id[TASKID_DUMB], RTEMS_EVENT_13 );</pre></td>
7461
    </tr>
7462

    
7463
    <tr>
7464
    <td align="right" class="lineno"><pre>1024</pre></td>
7465
    <td align="right" class="linebranch"></td>
7466
    <td align="right" class="linecount coveredLine"><pre>771</pre></td>
7467
    <td align="left" class="src coveredLine"><pre>}</pre></td>
7468
    </tr>
7469

    
7470
    <tr>
7471
    <td align="right" class="lineno"><pre>1025</pre></td>
7472
    <td align="right" class="linebranch"></td>
7473
    <td align="right" class="linecount "><pre></pre></td>
7474
    <td align="left" class="src "><pre></pre></td>
7475
    </tr>
7476

    
7477
    <tr>
7478
    <td align="right" class="lineno"><pre>1026</pre></td>
7479
    <td align="right" class="linebranch"></td>
7480
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7481
    <td align="left" class="src coveredLine"><pre>void init_header_cwf( Header_TM_LFR_SCIENCE_CWF_t *header )</pre></td>
7482
    </tr>
7483

    
7484
    <tr>
7485
    <td align="right" class="lineno"><pre>1027</pre></td>
7486
    <td align="right" class="linebranch"></td>
7487
    <td align="right" class="linecount "><pre></pre></td>
7488
    <td align="left" class="src "><pre>{</pre></td>
7489
    </tr>
7490

    
7491
    <tr>
7492
    <td align="right" class="lineno"><pre>1028</pre></td>
7493
    <td align="right" class="linebranch"></td>
7494
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7495
    <td align="left" class="src coveredLine"><pre>    header->targetLogicalAddress    = CCSDS_DESTINATION_ID;</pre></td>
7496
    </tr>
7497

    
7498
    <tr>
7499
    <td align="right" class="lineno"><pre>1029</pre></td>
7500
    <td align="right" class="linebranch"></td>
7501
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7502
    <td align="left" class="src coveredLine"><pre>    header->protocolIdentifier      = CCSDS_PROTOCOLE_ID;</pre></td>
7503
    </tr>
7504

    
7505
    <tr>
7506
    <td align="right" class="lineno"><pre>1030</pre></td>
7507
    <td align="right" class="linebranch"></td>
7508
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7509
    <td align="left" class="src coveredLine"><pre>    header->reserved                = DEFAULT_RESERVED;</pre></td>
7510
    </tr>
7511

    
7512
    <tr>
7513
    <td align="right" class="lineno"><pre>1031</pre></td>
7514
    <td align="right" class="linebranch"></td>
7515
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7516
    <td align="left" class="src coveredLine"><pre>    header->userApplication         = CCSDS_USER_APP;</pre></td>
7517
    </tr>
7518

    
7519
    <tr>
7520
    <td align="right" class="lineno"><pre>1032</pre></td>
7521
    <td align="right" class="linebranch"></td>
7522
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7523
    <td align="left" class="src coveredLine"><pre>    header->packetSequenceControl[0]= TM_PACKET_SEQ_CTRL_STANDALONE;</pre></td>
7524
    </tr>
7525

    
7526
    <tr>
7527
    <td align="right" class="lineno"><pre>1033</pre></td>
7528
    <td align="right" class="linebranch"></td>
7529
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7530
    <td align="left" class="src coveredLine"><pre>    header->packetSequenceControl[1]= TM_PACKET_SEQ_CNT_DEFAULT;</pre></td>
7531
    </tr>
7532

    
7533
    <tr>
7534
    <td align="right" class="lineno"><pre>1034</pre></td>
7535
    <td align="right" class="linebranch"></td>
7536
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7537
    <td align="left" class="src coveredLine"><pre>    header->packetLength[0] = INIT_CHAR;</pre></td>
7538
    </tr>
7539

    
7540
    <tr>
7541
    <td align="right" class="lineno"><pre>1035</pre></td>
7542
    <td align="right" class="linebranch"></td>
7543
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7544
    <td align="left" class="src coveredLine"><pre>    header->packetLength[1] = INIT_CHAR;</pre></td>
7545
    </tr>
7546

    
7547
    <tr>
7548
    <td align="right" class="lineno"><pre>1036</pre></td>
7549
    <td align="right" class="linebranch"></td>
7550
    <td align="right" class="linecount "><pre></pre></td>
7551
    <td align="left" class="src "><pre>    // DATA FIELD HEADER</pre></td>
7552
    </tr>
7553

    
7554
    <tr>
7555
    <td align="right" class="lineno"><pre>1037</pre></td>
7556
    <td align="right" class="linebranch"></td>
7557
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7558
    <td align="left" class="src coveredLine"><pre>    header->spare1_pusVersion_spare2    = DEFAULT_SPARE1_PUSVERSION_SPARE2;</pre></td>
7559
    </tr>
7560

    
7561
    <tr>
7562
    <td align="right" class="lineno"><pre>1038</pre></td>
7563
    <td align="right" class="linebranch"></td>
7564
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7565
    <td align="left" class="src coveredLine"><pre>    header->serviceType     = TM_TYPE_LFR_SCIENCE; // service type</pre></td>
7566
    </tr>
7567

    
7568
    <tr>
7569
    <td align="right" class="lineno"><pre>1039</pre></td>
7570
    <td align="right" class="linebranch"></td>
7571
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7572
    <td align="left" class="src coveredLine"><pre>    header->serviceSubType  = TM_SUBTYPE_LFR_SCIENCE_6; // service subtype</pre></td>
7573
    </tr>
7574

    
7575
    <tr>
7576
    <td align="right" class="lineno"><pre>1040</pre></td>
7577
    <td align="right" class="linebranch"></td>
7578
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7579
    <td align="left" class="src coveredLine"><pre>    header->destinationID   = TM_DESTINATION_ID_GROUND;</pre></td>
7580
    </tr>
7581

    
7582
    <tr>
7583
    <td align="right" class="lineno"><pre>1041</pre></td>
7584
    <td align="right" class="linebranch"></td>
7585
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7586
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_0] = INIT_CHAR;</pre></td>
7587
    </tr>
7588

    
7589
    <tr>
7590
    <td align="right" class="lineno"><pre>1042</pre></td>
7591
    <td align="right" class="linebranch"></td>
7592
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7593
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_1] = INIT_CHAR;</pre></td>
7594
    </tr>
7595

    
7596
    <tr>
7597
    <td align="right" class="lineno"><pre>1043</pre></td>
7598
    <td align="right" class="linebranch"></td>
7599
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7600
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_2] = INIT_CHAR;</pre></td>
7601
    </tr>
7602

    
7603
    <tr>
7604
    <td align="right" class="lineno"><pre>1044</pre></td>
7605
    <td align="right" class="linebranch"></td>
7606
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7607
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_3] = INIT_CHAR;</pre></td>
7608
    </tr>
7609

    
7610
    <tr>
7611
    <td align="right" class="lineno"><pre>1045</pre></td>
7612
    <td align="right" class="linebranch"></td>
7613
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7614
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_4] = INIT_CHAR;</pre></td>
7615
    </tr>
7616

    
7617
    <tr>
7618
    <td align="right" class="lineno"><pre>1046</pre></td>
7619
    <td align="right" class="linebranch"></td>
7620
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7621
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_5] = INIT_CHAR;</pre></td>
7622
    </tr>
7623

    
7624
    <tr>
7625
    <td align="right" class="lineno"><pre>1047</pre></td>
7626
    <td align="right" class="linebranch"></td>
7627
    <td align="right" class="linecount "><pre></pre></td>
7628
    <td align="left" class="src "><pre>    // AUXILIARY DATA HEADER</pre></td>
7629
    </tr>
7630

    
7631
    <tr>
7632
    <td align="right" class="lineno"><pre>1048</pre></td>
7633
    <td align="right" class="linebranch"></td>
7634
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7635
    <td align="left" class="src coveredLine"><pre>    header->sid = INIT_CHAR;</pre></td>
7636
    </tr>
7637

    
7638
    <tr>
7639
    <td align="right" class="lineno"><pre>1049</pre></td>
7640
    <td align="right" class="linebranch"></td>
7641
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7642
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info = DEFAULT_HKBIA;</pre></td>
7643
    </tr>
7644

    
7645
    <tr>
7646
    <td align="right" class="lineno"><pre>1050</pre></td>
7647
    <td align="right" class="linebranch"></td>
7648
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7649
    <td align="left" class="src coveredLine"><pre>    header->blkNr[0] = INIT_CHAR;</pre></td>
7650
    </tr>
7651

    
7652
    <tr>
7653
    <td align="right" class="lineno"><pre>1051</pre></td>
7654
    <td align="right" class="linebranch"></td>
7655
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7656
    <td align="left" class="src coveredLine"><pre>    header->blkNr[1] = INIT_CHAR;</pre></td>
7657
    </tr>
7658

    
7659
    <tr>
7660
    <td align="right" class="lineno"><pre>1052</pre></td>
7661
    <td align="right" class="linebranch"></td>
7662
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7663
    <td align="left" class="src coveredLine"><pre>}</pre></td>
7664
    </tr>
7665

    
7666
    <tr>
7667
    <td align="right" class="lineno"><pre>1053</pre></td>
7668
    <td align="right" class="linebranch"></td>
7669
    <td align="right" class="linecount "><pre></pre></td>
7670
    <td align="left" class="src "><pre></pre></td>
7671
    </tr>
7672

    
7673
    <tr>
7674
    <td align="right" class="lineno"><pre>1054</pre></td>
7675
    <td align="right" class="linebranch"></td>
7676
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7677
    <td align="left" class="src coveredLine"><pre>void init_header_swf( Header_TM_LFR_SCIENCE_SWF_t *header )</pre></td>
7678
    </tr>
7679

    
7680
    <tr>
7681
    <td align="right" class="lineno"><pre>1055</pre></td>
7682
    <td align="right" class="linebranch"></td>
7683
    <td align="right" class="linecount "><pre></pre></td>
7684
    <td align="left" class="src "><pre>{</pre></td>
7685
    </tr>
7686

    
7687
    <tr>
7688
    <td align="right" class="lineno"><pre>1056</pre></td>
7689
    <td align="right" class="linebranch"></td>
7690
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7691
    <td align="left" class="src coveredLine"><pre>    header->targetLogicalAddress        = CCSDS_DESTINATION_ID;</pre></td>
7692
    </tr>
7693

    
7694
    <tr>
7695
    <td align="right" class="lineno"><pre>1057</pre></td>
7696
    <td align="right" class="linebranch"></td>
7697
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7698
    <td align="left" class="src coveredLine"><pre>    header->protocolIdentifier          = CCSDS_PROTOCOLE_ID;</pre></td>
7699
    </tr>
7700

    
7701
    <tr>
7702
    <td align="right" class="lineno"><pre>1058</pre></td>
7703
    <td align="right" class="linebranch"></td>
7704
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7705
    <td align="left" class="src coveredLine"><pre>    header->reserved        = DEFAULT_RESERVED;</pre></td>
7706
    </tr>
7707

    
7708
    <tr>
7709
    <td align="right" class="lineno"><pre>1059</pre></td>
7710
    <td align="right" class="linebranch"></td>
7711
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7712
    <td align="left" class="src coveredLine"><pre>    header->userApplication = CCSDS_USER_APP;</pre></td>
7713
    </tr>
7714

    
7715
    <tr>
7716
    <td align="right" class="lineno"><pre>1060</pre></td>
7717
    <td align="right" class="linebranch"></td>
7718
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7719
    <td align="left" class="src coveredLine"><pre>    header->packetID[0] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST >> SHIFT_1_BYTE);</pre></td>
7720
    </tr>
7721

    
7722
    <tr>
7723
    <td align="right" class="lineno"><pre>1061</pre></td>
7724
    <td align="right" class="linebranch"></td>
7725
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7726
    <td align="left" class="src coveredLine"><pre>    header->packetID[1] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST);</pre></td>
7727
    </tr>
7728

    
7729
    <tr>
7730
    <td align="right" class="lineno"><pre>1062</pre></td>
7731
    <td align="right" class="linebranch"></td>
7732
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7733
    <td align="left" class="src coveredLine"><pre>    header->packetSequenceControl[0]    = TM_PACKET_SEQ_CTRL_STANDALONE;</pre></td>
7734
    </tr>
7735

    
7736
    <tr>
7737
    <td align="right" class="lineno"><pre>1063</pre></td>
7738
    <td align="right" class="linebranch"></td>
7739
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7740
    <td align="left" class="src coveredLine"><pre>    header->packetSequenceControl[1]    = TM_PACKET_SEQ_CNT_DEFAULT;</pre></td>
7741
    </tr>
7742

    
7743
    <tr>
7744
    <td align="right" class="lineno"><pre>1064</pre></td>
7745
    <td align="right" class="linebranch"></td>
7746
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7747
    <td align="left" class="src coveredLine"><pre>    header->packetLength[0] = (unsigned char) (TM_LEN_SCI_CWF_336 >> SHIFT_1_BYTE);</pre></td>
7748
    </tr>
7749

    
7750
    <tr>
7751
    <td align="right" class="lineno"><pre>1065</pre></td>
7752
    <td align="right" class="linebranch"></td>
7753
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7754
    <td align="left" class="src coveredLine"><pre>    header->packetLength[1] = (unsigned char) (TM_LEN_SCI_CWF_336     );</pre></td>
7755
    </tr>
7756

    
7757
    <tr>
7758
    <td align="right" class="lineno"><pre>1066</pre></td>
7759
    <td align="right" class="linebranch"></td>
7760
    <td align="right" class="linecount "><pre></pre></td>
7761
    <td align="left" class="src "><pre>    // DATA FIELD HEADER</pre></td>
7762
    </tr>
7763

    
7764
    <tr>
7765
    <td align="right" class="lineno"><pre>1067</pre></td>
7766
    <td align="right" class="linebranch"></td>
7767
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7768
    <td align="left" class="src coveredLine"><pre>    header->spare1_pusVersion_spare2    = DEFAULT_SPARE1_PUSVERSION_SPARE2;</pre></td>
7769
    </tr>
7770

    
7771
    <tr>
7772
    <td align="right" class="lineno"><pre>1068</pre></td>
7773
    <td align="right" class="linebranch"></td>
7774
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7775
    <td align="left" class="src coveredLine"><pre>    header->serviceType     = TM_TYPE_LFR_SCIENCE; // service type</pre></td>
7776
    </tr>
7777

    
7778
    <tr>
7779
    <td align="right" class="lineno"><pre>1069</pre></td>
7780
    <td align="right" class="linebranch"></td>
7781
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7782
    <td align="left" class="src coveredLine"><pre>    header->serviceSubType  = TM_SUBTYPE_LFR_SCIENCE_6; // service subtype</pre></td>
7783
    </tr>
7784

    
7785
    <tr>
7786
    <td align="right" class="lineno"><pre>1070</pre></td>
7787
    <td align="right" class="linebranch"></td>
7788
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7789
    <td align="left" class="src coveredLine"><pre>    header->destinationID   = TM_DESTINATION_ID_GROUND;</pre></td>
7790
    </tr>
7791

    
7792
    <tr>
7793
    <td align="right" class="lineno"><pre>1071</pre></td>
7794
    <td align="right" class="linebranch"></td>
7795
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7796
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_0] = INIT_CHAR;</pre></td>
7797
    </tr>
7798

    
7799
    <tr>
7800
    <td align="right" class="lineno"><pre>1072</pre></td>
7801
    <td align="right" class="linebranch"></td>
7802
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7803
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_1] = INIT_CHAR;</pre></td>
7804
    </tr>
7805

    
7806
    <tr>
7807
    <td align="right" class="lineno"><pre>1073</pre></td>
7808
    <td align="right" class="linebranch"></td>
7809
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7810
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_2] = INIT_CHAR;</pre></td>
7811
    </tr>
7812

    
7813
    <tr>
7814
    <td align="right" class="lineno"><pre>1074</pre></td>
7815
    <td align="right" class="linebranch"></td>
7816
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7817
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_3] = INIT_CHAR;</pre></td>
7818
    </tr>
7819

    
7820
    <tr>
7821
    <td align="right" class="lineno"><pre>1075</pre></td>
7822
    <td align="right" class="linebranch"></td>
7823
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7824
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_4] = INIT_CHAR;</pre></td>
7825
    </tr>
7826

    
7827
    <tr>
7828
    <td align="right" class="lineno"><pre>1076</pre></td>
7829
    <td align="right" class="linebranch"></td>
7830
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7831
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_5] = INIT_CHAR;</pre></td>
7832
    </tr>
7833

    
7834
    <tr>
7835
    <td align="right" class="lineno"><pre>1077</pre></td>
7836
    <td align="right" class="linebranch"></td>
7837
    <td align="right" class="linecount "><pre></pre></td>
7838
    <td align="left" class="src "><pre>    // AUXILIARY DATA HEADER</pre></td>
7839
    </tr>
7840

    
7841
    <tr>
7842
    <td align="right" class="lineno"><pre>1078</pre></td>
7843
    <td align="right" class="linebranch"></td>
7844
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7845
    <td align="left" class="src coveredLine"><pre>    header->sid     = INIT_CHAR;</pre></td>
7846
    </tr>
7847

    
7848
    <tr>
7849
    <td align="right" class="lineno"><pre>1079</pre></td>
7850
    <td align="right" class="linebranch"></td>
7851
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7852
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info   = DEFAULT_HKBIA;</pre></td>
7853
    </tr>
7854

    
7855
    <tr>
7856
    <td align="right" class="lineno"><pre>1080</pre></td>
7857
    <td align="right" class="linebranch"></td>
7858
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7859
    <td align="left" class="src coveredLine"><pre>    header->pktCnt  = PKTCNT_SWF;  // PKT_CNT</pre></td>
7860
    </tr>
7861

    
7862
    <tr>
7863
    <td align="right" class="lineno"><pre>1081</pre></td>
7864
    <td align="right" class="linebranch"></td>
7865
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7866
    <td align="left" class="src coveredLine"><pre>    header->pktNr   = INIT_CHAR;</pre></td>
7867
    </tr>
7868

    
7869
    <tr>
7870
    <td align="right" class="lineno"><pre>1082</pre></td>
7871
    <td align="right" class="linebranch"></td>
7872
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7873
    <td align="left" class="src coveredLine"><pre>    header->blkNr[0]        = (unsigned char) (BLK_NR_CWF >> SHIFT_1_BYTE);</pre></td>
7874
    </tr>
7875

    
7876
    <tr>
7877
    <td align="right" class="lineno"><pre>1083</pre></td>
7878
    <td align="right" class="linebranch"></td>
7879
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7880
    <td align="left" class="src coveredLine"><pre>    header->blkNr[1]        = (unsigned char) (BLK_NR_CWF     );</pre></td>
7881
    </tr>
7882

    
7883
    <tr>
7884
    <td align="right" class="lineno"><pre>1084</pre></td>
7885
    <td align="right" class="linebranch"></td>
7886
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7887
    <td align="left" class="src coveredLine"><pre>}</pre></td>
7888
    </tr>
7889

    
7890
    <tr>
7891
    <td align="right" class="lineno"><pre>1085</pre></td>
7892
    <td align="right" class="linebranch"></td>
7893
    <td align="right" class="linecount "><pre></pre></td>
7894
    <td align="left" class="src "><pre></pre></td>
7895
    </tr>
7896

    
7897
    <tr>
7898
    <td align="right" class="lineno"><pre>1086</pre></td>
7899
    <td align="right" class="linebranch"></td>
7900
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7901
    <td align="left" class="src coveredLine"><pre>void init_header_asm( Header_TM_LFR_SCIENCE_ASM_t *header )</pre></td>
7902
    </tr>
7903

    
7904
    <tr>
7905
    <td align="right" class="lineno"><pre>1087</pre></td>
7906
    <td align="right" class="linebranch"></td>
7907
    <td align="right" class="linecount "><pre></pre></td>
7908
    <td align="left" class="src "><pre>{</pre></td>
7909
    </tr>
7910

    
7911
    <tr>
7912
    <td align="right" class="lineno"><pre>1088</pre></td>
7913
    <td align="right" class="linebranch"></td>
7914
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7915
    <td align="left" class="src coveredLine"><pre>    header->targetLogicalAddress        = CCSDS_DESTINATION_ID;</pre></td>
7916
    </tr>
7917

    
7918
    <tr>
7919
    <td align="right" class="lineno"><pre>1089</pre></td>
7920
    <td align="right" class="linebranch"></td>
7921
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7922
    <td align="left" class="src coveredLine"><pre>    header->protocolIdentifier          = CCSDS_PROTOCOLE_ID;</pre></td>
7923
    </tr>
7924

    
7925
    <tr>
7926
    <td align="right" class="lineno"><pre>1090</pre></td>
7927
    <td align="right" class="linebranch"></td>
7928
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7929
    <td align="left" class="src coveredLine"><pre>    header->reserved        = DEFAULT_RESERVED;</pre></td>
7930
    </tr>
7931

    
7932
    <tr>
7933
    <td align="right" class="lineno"><pre>1091</pre></td>
7934
    <td align="right" class="linebranch"></td>
7935
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7936
    <td align="left" class="src coveredLine"><pre>    header->userApplication = CCSDS_USER_APP;</pre></td>
7937
    </tr>
7938

    
7939
    <tr>
7940
    <td align="right" class="lineno"><pre>1092</pre></td>
7941
    <td align="right" class="linebranch"></td>
7942
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7943
    <td align="left" class="src coveredLine"><pre>    header->packetID[0] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST >> SHIFT_1_BYTE);</pre></td>
7944
    </tr>
7945

    
7946
    <tr>
7947
    <td align="right" class="lineno"><pre>1093</pre></td>
7948
    <td align="right" class="linebranch"></td>
7949
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7950
    <td align="left" class="src coveredLine"><pre>    header->packetID[1] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST);</pre></td>
7951
    </tr>
7952

    
7953
    <tr>
7954
    <td align="right" class="lineno"><pre>1094</pre></td>
7955
    <td align="right" class="linebranch"></td>
7956
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7957
    <td align="left" class="src coveredLine"><pre>    header->packetSequenceControl[0]    = TM_PACKET_SEQ_CTRL_STANDALONE;</pre></td>
7958
    </tr>
7959

    
7960
    <tr>
7961
    <td align="right" class="lineno"><pre>1095</pre></td>
7962
    <td align="right" class="linebranch"></td>
7963
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7964
    <td align="left" class="src coveredLine"><pre>    header->packetSequenceControl[1]    = TM_PACKET_SEQ_CNT_DEFAULT;</pre></td>
7965
    </tr>
7966

    
7967
    <tr>
7968
    <td align="right" class="lineno"><pre>1096</pre></td>
7969
    <td align="right" class="linebranch"></td>
7970
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7971
    <td align="left" class="src coveredLine"><pre>    header->packetLength[0] = INIT_CHAR;</pre></td>
7972
    </tr>
7973

    
7974
    <tr>
7975
    <td align="right" class="lineno"><pre>1097</pre></td>
7976
    <td align="right" class="linebranch"></td>
7977
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7978
    <td align="left" class="src coveredLine"><pre>    header->packetLength[1] = INIT_CHAR;</pre></td>
7979
    </tr>
7980

    
7981
    <tr>
7982
    <td align="right" class="lineno"><pre>1098</pre></td>
7983
    <td align="right" class="linebranch"></td>
7984
    <td align="right" class="linecount "><pre></pre></td>
7985
    <td align="left" class="src "><pre>    // DATA FIELD HEADER</pre></td>
7986
    </tr>
7987

    
7988
    <tr>
7989
    <td align="right" class="lineno"><pre>1099</pre></td>
7990
    <td align="right" class="linebranch"></td>
7991
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7992
    <td align="left" class="src coveredLine"><pre>    header->spare1_pusVersion_spare2    = DEFAULT_SPARE1_PUSVERSION_SPARE2;</pre></td>
7993
    </tr>
7994

    
7995
    <tr>
7996
    <td align="right" class="lineno"><pre>1100</pre></td>
7997
    <td align="right" class="linebranch"></td>
7998
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
7999
    <td align="left" class="src coveredLine"><pre>    header->serviceType     = TM_TYPE_LFR_SCIENCE; // service type</pre></td>
8000
    </tr>
8001

    
8002
    <tr>
8003
    <td align="right" class="lineno"><pre>1101</pre></td>
8004
    <td align="right" class="linebranch"></td>
8005
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8006
    <td align="left" class="src coveredLine"><pre>    header->serviceSubType  = TM_SUBTYPE_LFR_SCIENCE_3; // service subtype</pre></td>
8007
    </tr>
8008

    
8009
    <tr>
8010
    <td align="right" class="lineno"><pre>1102</pre></td>
8011
    <td align="right" class="linebranch"></td>
8012
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8013
    <td align="left" class="src coveredLine"><pre>    header->destinationID   = TM_DESTINATION_ID_GROUND;</pre></td>
8014
    </tr>
8015

    
8016
    <tr>
8017
    <td align="right" class="lineno"><pre>1103</pre></td>
8018
    <td align="right" class="linebranch"></td>
8019
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8020
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_0] = INIT_CHAR;</pre></td>
8021
    </tr>
8022

    
8023
    <tr>
8024
    <td align="right" class="lineno"><pre>1104</pre></td>
8025
    <td align="right" class="linebranch"></td>
8026
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8027
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_1] = INIT_CHAR;</pre></td>
8028
    </tr>
8029

    
8030
    <tr>
8031
    <td align="right" class="lineno"><pre>1105</pre></td>
8032
    <td align="right" class="linebranch"></td>
8033
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8034
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_2] = INIT_CHAR;</pre></td>
8035
    </tr>
8036

    
8037
    <tr>
8038
    <td align="right" class="lineno"><pre>1106</pre></td>
8039
    <td align="right" class="linebranch"></td>
8040
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8041
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_3] = INIT_CHAR;</pre></td>
8042
    </tr>
8043

    
8044
    <tr>
8045
    <td align="right" class="lineno"><pre>1107</pre></td>
8046
    <td align="right" class="linebranch"></td>
8047
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8048
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_4] = INIT_CHAR;</pre></td>
8049
    </tr>
8050

    
8051
    <tr>
8052
    <td align="right" class="lineno"><pre>1108</pre></td>
8053
    <td align="right" class="linebranch"></td>
8054
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8055
    <td align="left" class="src coveredLine"><pre>    header->time[BYTE_5] = INIT_CHAR;</pre></td>
8056
    </tr>
8057

    
8058
    <tr>
8059
    <td align="right" class="lineno"><pre>1109</pre></td>
8060
    <td align="right" class="linebranch"></td>
8061
    <td align="right" class="linecount "><pre></pre></td>
8062
    <td align="left" class="src "><pre>    // AUXILIARY DATA HEADER</pre></td>
8063
    </tr>
8064

    
8065
    <tr>
8066
    <td align="right" class="lineno"><pre>1110</pre></td>
8067
    <td align="right" class="linebranch"></td>
8068
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8069
    <td align="left" class="src coveredLine"><pre>    header->sid     = INIT_CHAR;</pre></td>
8070
    </tr>
8071

    
8072
    <tr>
8073
    <td align="right" class="lineno"><pre>1111</pre></td>
8074
    <td align="right" class="linebranch"></td>
8075
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8076
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info = INIT_CHAR;</pre></td>
8077
    </tr>
8078

    
8079
    <tr>
8080
    <td align="right" class="lineno"><pre>1112</pre></td>
8081
    <td align="right" class="linebranch"></td>
8082
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8083
    <td align="left" class="src coveredLine"><pre>    header->pa_lfr_pkt_cnt_asm = INIT_CHAR;</pre></td>
8084
    </tr>
8085

    
8086
    <tr>
8087
    <td align="right" class="lineno"><pre>1113</pre></td>
8088
    <td align="right" class="linebranch"></td>
8089
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8090
    <td align="left" class="src coveredLine"><pre>    header->pa_lfr_pkt_nr_asm = INIT_CHAR;</pre></td>
8091
    </tr>
8092

    
8093
    <tr>
8094
    <td align="right" class="lineno"><pre>1114</pre></td>
8095
    <td align="right" class="linebranch"></td>
8096
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8097
    <td align="left" class="src coveredLine"><pre>    header->pa_lfr_asm_blk_nr[0] = INIT_CHAR;</pre></td>
8098
    </tr>
8099

    
8100
    <tr>
8101
    <td align="right" class="lineno"><pre>1115</pre></td>
8102
    <td align="right" class="linebranch"></td>
8103
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8104
    <td align="left" class="src coveredLine"><pre>    header->pa_lfr_asm_blk_nr[1] = INIT_CHAR;</pre></td>
8105
    </tr>
8106

    
8107
    <tr>
8108
    <td align="right" class="lineno"><pre>1116</pre></td>
8109
    <td align="right" class="linebranch"></td>
8110
    <td align="right" class="linecount coveredLine"><pre>94</pre></td>
8111
    <td align="left" class="src coveredLine"><pre>}</pre></td>
8112
    </tr>
8113

    
8114
    <tr>
8115
    <td align="right" class="lineno"><pre>1117</pre></td>
8116
    <td align="right" class="linebranch"></td>
8117
    <td align="right" class="linecount "><pre></pre></td>
8118
    <td align="left" class="src "><pre></pre></td>
8119
    </tr>
8120

    
8121
    <tr>
8122
    <td align="right" class="lineno"><pre>1118</pre></td>
8123
    <td align="right" class="linebranch"></td>
8124
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8125
    <td align="left" class="src coveredLine"><pre>int spw_send_waveform_CWF( ring_node *ring_node_to_send,</pre></td>
8126
    </tr>
8127

    
8128
    <tr>
8129
    <td align="right" class="lineno"><pre>1119</pre></td>
8130
    <td align="right" class="linebranch"></td>
8131
    <td align="right" class="linecount "><pre></pre></td>
8132
    <td align="left" class="src "><pre>                      Header_TM_LFR_SCIENCE_CWF_t *header )</pre></td>
8133
    </tr>
8134

    
8135
    <tr>
8136
    <td align="right" class="lineno"><pre>1120</pre></td>
8137
    <td align="right" class="linebranch"></td>
8138
    <td align="right" class="linecount "><pre></pre></td>
8139
    <td align="left" class="src "><pre>{</pre></td>
8140
    </tr>
8141

    
8142
    <tr>
8143
    <td align="right" class="lineno"><pre>1121</pre></td>
8144
    <td align="right" class="linebranch"></td>
8145
    <td align="right" class="linecount "><pre></pre></td>
8146
    <td align="left" class="src "><pre>    /** This function sends CWF CCSDS packets (F2, F1 or F0).</pre></td>
8147
    </tr>
8148

    
8149
    <tr>
8150
    <td align="right" class="lineno"><pre>1122</pre></td>
8151
    <td align="right" class="linebranch"></td>
8152
    <td align="right" class="linecount "><pre></pre></td>
8153
    <td align="left" class="src "><pre>     *</pre></td>
8154
    </tr>
8155

    
8156
    <tr>
8157
    <td align="right" class="lineno"><pre>1123</pre></td>
8158
    <td align="right" class="linebranch"></td>
8159
    <td align="right" class="linecount "><pre></pre></td>
8160
    <td align="left" class="src "><pre>     * @param waveform points to the buffer containing the data that will be send.</pre></td>
8161
    </tr>
8162

    
8163
    <tr>
8164
    <td align="right" class="lineno"><pre>1124</pre></td>
8165
    <td align="right" class="linebranch"></td>
8166
    <td align="right" class="linecount "><pre></pre></td>
8167
    <td align="left" class="src "><pre>     * @param sid is the source identifier of the data that will be sent.</pre></td>
8168
    </tr>
8169

    
8170
    <tr>
8171
    <td align="right" class="lineno"><pre>1125</pre></td>
8172
    <td align="right" class="linebranch"></td>
8173
    <td align="right" class="linecount "><pre></pre></td>
8174
    <td align="left" class="src "><pre>     * @param headerCWF points to a table of headers that have been prepared for the data transmission.</pre></td>
8175
    </tr>
8176

    
8177
    <tr>
8178
    <td align="right" class="lineno"><pre>1126</pre></td>
8179
    <td align="right" class="linebranch"></td>
8180
    <td align="right" class="linecount "><pre></pre></td>
8181
    <td align="left" class="src "><pre>     * @param queue_id is the id of the rtems queue to which spw_ioctl_pkt_send structures will be send. The structures</pre></td>
8182
    </tr>
8183

    
8184
    <tr>
8185
    <td align="right" class="lineno"><pre>1127</pre></td>
8186
    <td align="right" class="linebranch"></td>
8187
    <td align="right" class="linecount "><pre></pre></td>
8188
    <td align="left" class="src "><pre>     * contain information to setup the transmission of the data packets.</pre></td>
8189
    </tr>
8190

    
8191
    <tr>
8192
    <td align="right" class="lineno"><pre>1128</pre></td>
8193
    <td align="right" class="linebranch"></td>
8194
    <td align="right" class="linecount "><pre></pre></td>
8195
    <td align="left" class="src "><pre>     *</pre></td>
8196
    </tr>
8197

    
8198
    <tr>
8199
    <td align="right" class="lineno"><pre>1129</pre></td>
8200
    <td align="right" class="linebranch"></td>
8201
    <td align="right" class="linecount "><pre></pre></td>
8202
    <td align="left" class="src "><pre>     * One group of 2048 samples is sent as 7 consecutive packets, 6 packets containing 340 blocks and 8 packets containing 8 blocks.</pre></td>
8203
    </tr>
8204

    
8205
    <tr>
8206
    <td align="right" class="lineno"><pre>1130</pre></td>
8207
    <td align="right" class="linebranch"></td>
8208
    <td align="right" class="linecount "><pre></pre></td>
8209
    <td align="left" class="src "><pre>     *</pre></td>
8210
    </tr>
8211

    
8212
    <tr>
8213
    <td align="right" class="lineno"><pre>1131</pre></td>
8214
    <td align="right" class="linebranch"></td>
8215
    <td align="right" class="linecount "><pre></pre></td>
8216
    <td align="left" class="src "><pre>     */</pre></td>
8217
    </tr>
8218

    
8219
    <tr>
8220
    <td align="right" class="lineno"><pre>1132</pre></td>
8221
    <td align="right" class="linebranch"></td>
8222
    <td align="right" class="linecount "><pre></pre></td>
8223
    <td align="left" class="src "><pre></pre></td>
8224
    </tr>
8225

    
8226
    <tr>
8227
    <td align="right" class="lineno"><pre>1133</pre></td>
8228
    <td align="right" class="linebranch"></td>
8229
    <td align="right" class="linecount "><pre></pre></td>
8230
    <td align="left" class="src "><pre>    unsigned int i;</pre></td>
8231
    </tr>
8232

    
8233
    <tr>
8234
    <td align="right" class="lineno"><pre>1134</pre></td>
8235
    <td align="right" class="linebranch"></td>
8236
    <td align="right" class="linecount "><pre></pre></td>
8237
    <td align="left" class="src "><pre>    int ret;</pre></td>
8238
    </tr>
8239

    
8240
    <tr>
8241
    <td align="right" class="lineno"><pre>1135</pre></td>
8242
    <td align="right" class="linebranch"></td>
8243
    <td align="right" class="linecount "><pre></pre></td>
8244
    <td align="left" class="src "><pre>    unsigned int coarseTime;</pre></td>
8245
    </tr>
8246

    
8247
    <tr>
8248
    <td align="right" class="lineno"><pre>1136</pre></td>
8249
    <td align="right" class="linebranch"></td>
8250
    <td align="right" class="linecount "><pre></pre></td>
8251
    <td align="left" class="src "><pre>    unsigned int fineTime;</pre></td>
8252
    </tr>
8253

    
8254
    <tr>
8255
    <td align="right" class="lineno"><pre>1137</pre></td>
8256
    <td align="right" class="linebranch"></td>
8257
    <td align="right" class="linecount "><pre></pre></td>
8258
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
8259
    </tr>
8260

    
8261
    <tr>
8262
    <td align="right" class="lineno"><pre>1138</pre></td>
8263
    <td align="right" class="linebranch"></td>
8264
    <td align="right" class="linecount "><pre></pre></td>
8265
    <td align="left" class="src "><pre>    spw_ioctl_pkt_send spw_ioctl_send_CWF;</pre></td>
8266
    </tr>
8267

    
8268
    <tr>
8269
    <td align="right" class="lineno"><pre>1139</pre></td>
8270
    <td align="right" class="linebranch"></td>
8271
    <td align="right" class="linecount "><pre></pre></td>
8272
    <td align="left" class="src "><pre>    int *dataPtr;</pre></td>
8273
    </tr>
8274

    
8275
    <tr>
8276
    <td align="right" class="lineno"><pre>1140</pre></td>
8277
    <td align="right" class="linebranch"></td>
8278
    <td align="right" class="linecount "><pre></pre></td>
8279
    <td align="left" class="src "><pre>    unsigned char sid;</pre></td>
8280
    </tr>
8281

    
8282
    <tr>
8283
    <td align="right" class="lineno"><pre>1141</pre></td>
8284
    <td align="right" class="linebranch"></td>
8285
    <td align="right" class="linecount "><pre></pre></td>
8286
    <td align="left" class="src "><pre></pre></td>
8287
    </tr>
8288

    
8289
    <tr>
8290
    <td align="right" class="lineno"><pre>1142</pre></td>
8291
    <td align="right" class="linebranch"></td>
8292
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8293
    <td align="left" class="src coveredLine"><pre>    spw_ioctl_send_CWF.hlen = HEADER_LENGTH_TM_LFR_SCIENCE_CWF;</pre></td>
8294
    </tr>
8295

    
8296
    <tr>
8297
    <td align="right" class="lineno"><pre>1143</pre></td>
8298
    <td align="right" class="linebranch"></td>
8299
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8300
    <td align="left" class="src coveredLine"><pre>    spw_ioctl_send_CWF.options = 0;</pre></td>
8301
    </tr>
8302

    
8303
    <tr>
8304
    <td align="right" class="lineno"><pre>1144</pre></td>
8305
    <td align="right" class="linebranch"></td>
8306
    <td align="right" class="linecount "><pre></pre></td>
8307
    <td align="left" class="src "><pre></pre></td>
8308
    </tr>
8309

    
8310
    <tr>
8311
    <td align="right" class="lineno"><pre>1145</pre></td>
8312
    <td align="right" class="linebranch"></td>
8313
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8314
    <td align="left" class="src coveredLine"><pre>    ret = LFR_DEFAULT;</pre></td>
8315
    </tr>
8316

    
8317
    <tr>
8318
    <td align="right" class="lineno"><pre>1146</pre></td>
8319
    <td align="right" class="linebranch"></td>
8320
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8321
    <td align="left" class="src coveredLine"><pre>    sid = (unsigned char) ring_node_to_send->sid;</pre></td>
8322
    </tr>
8323

    
8324
    <tr>
8325
    <td align="right" class="lineno"><pre>1147</pre></td>
8326
    <td align="right" class="linebranch"></td>
8327
    <td align="right" class="linecount "><pre></pre></td>
8328
    <td align="left" class="src "><pre></pre></td>
8329
    </tr>
8330

    
8331
    <tr>
8332
    <td align="right" class="lineno"><pre>1148</pre></td>
8333
    <td align="right" class="linebranch"></td>
8334
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8335
    <td align="left" class="src coveredLine"><pre>    coarseTime  = ring_node_to_send->coarseTime;</pre></td>
8336
    </tr>
8337

    
8338
    <tr>
8339
    <td align="right" class="lineno"><pre>1149</pre></td>
8340
    <td align="right" class="linebranch"></td>
8341
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8342
    <td align="left" class="src coveredLine"><pre>    fineTime    = ring_node_to_send->fineTime;</pre></td>
8343
    </tr>
8344

    
8345
    <tr>
8346
    <td align="right" class="lineno"><pre>1150</pre></td>
8347
    <td align="right" class="linebranch"></td>
8348
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8349
    <td align="left" class="src coveredLine"><pre>    dataPtr     = (int*) ring_node_to_send->buffer_address;</pre></td>
8350
    </tr>
8351

    
8352
    <tr>
8353
    <td align="right" class="lineno"><pre>1151</pre></td>
8354
    <td align="right" class="linebranch"></td>
8355
    <td align="right" class="linecount "><pre></pre></td>
8356
    <td align="left" class="src "><pre></pre></td>
8357
    </tr>
8358

    
8359
    <tr>
8360
    <td align="right" class="lineno"><pre>1152</pre></td>
8361
    <td align="right" class="linebranch"></td>
8362
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8363
    <td align="left" class="src coveredLine"><pre>    header->packetLength[0] = (unsigned char) (TM_LEN_SCI_CWF_336 >> SHIFT_1_BYTE);</pre></td>
8364
    </tr>
8365

    
8366
    <tr>
8367
    <td align="right" class="lineno"><pre>1153</pre></td>
8368
    <td align="right" class="linebranch"></td>
8369
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8370
    <td align="left" class="src coveredLine"><pre>    header->packetLength[1] = (unsigned char) (TM_LEN_SCI_CWF_336     );</pre></td>
8371
    </tr>
8372

    
8373
    <tr>
8374
    <td align="right" class="lineno"><pre>1154</pre></td>
8375
    <td align="right" class="linebranch"></td>
8376
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8377
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info = pa_bia_status_info;</pre></td>
8378
    </tr>
8379

    
8380
    <tr>
8381
    <td align="right" class="lineno"><pre>1155</pre></td>
8382
    <td align="right" class="linebranch"></td>
8383
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8384
    <td align="left" class="src coveredLine"><pre>    header->sy_lfr_common_parameters = parameter_dump_packet.sy_lfr_common_parameters;</pre></td>
8385
    </tr>
8386

    
8387
    <tr>
8388
    <td align="right" class="lineno"><pre>1156</pre></td>
8389
    <td align="right" class="linebranch"></td>
8390
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8391
    <td align="left" class="src coveredLine"><pre>    header->blkNr[0] = (unsigned char) (BLK_NR_CWF >> SHIFT_1_BYTE);</pre></td>
8392
    </tr>
8393

    
8394
    <tr>
8395
    <td align="right" class="lineno"><pre>1157</pre></td>
8396
    <td align="right" class="linebranch"></td>
8397
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8398
    <td align="left" class="src coveredLine"><pre>    header->blkNr[1] = (unsigned char) (BLK_NR_CWF     );</pre></td>
8399
    </tr>
8400

    
8401
    <tr>
8402
    <td align="right" class="lineno"><pre>1158</pre></td>
8403
    <td align="right" class="linebranch"></td>
8404
    <td align="right" class="linecount "><pre></pre></td>
8405
    <td align="left" class="src "><pre></pre></td>
8406
    </tr>
8407

    
8408
    <tr>
8409
    <td align="right" class="lineno"><pre>1159</pre></td>
8410
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 352640 times">&check;</span><span class="takenBranch" title="Branch 1 taken 44080 times">&check;</span></td>
8411
    <td align="right" class="linecount coveredLine"><pre>396720</pre></td>
8412
    <td align="left" class="src coveredLine"><pre>    for (i=0; i&lt;NB_PACKETS_PER_GROUP_OF_CWF; i++) // send waveform</pre></td>
8413
    </tr>
8414

    
8415
    <tr>
8416
    <td align="right" class="lineno"><pre>1160</pre></td>
8417
    <td align="right" class="linebranch"></td>
8418
    <td align="right" class="linecount "><pre></pre></td>
8419
    <td align="left" class="src "><pre>    {</pre></td>
8420
    </tr>
8421

    
8422
    <tr>
8423
    <td align="right" class="lineno"><pre>1161</pre></td>
8424
    <td align="right" class="linebranch"></td>
8425
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8426
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_CWF.data = (char*) &amp;dataPtr[ (i * BLK_NR_CWF * NB_WORDS_SWF_BLK) ];</pre></td>
8427
    </tr>
8428

    
8429
    <tr>
8430
    <td align="right" class="lineno"><pre>1162</pre></td>
8431
    <td align="right" class="linebranch"></td>
8432
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8433
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_CWF.hdr  = (char*) header;</pre></td>
8434
    </tr>
8435

    
8436
    <tr>
8437
    <td align="right" class="lineno"><pre>1163</pre></td>
8438
    <td align="right" class="linebranch"></td>
8439
    <td align="right" class="linecount "><pre></pre></td>
8440
    <td align="left" class="src "><pre>        // BUILD THE DATA</pre></td>
8441
    </tr>
8442

    
8443
    <tr>
8444
    <td align="right" class="lineno"><pre>1164</pre></td>
8445
    <td align="right" class="linebranch"></td>
8446
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8447
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_CWF.dlen = BLK_NR_CWF * NB_BYTES_SWF_BLK;</pre></td>
8448
    </tr>
8449

    
8450
    <tr>
8451
    <td align="right" class="lineno"><pre>1165</pre></td>
8452
    <td align="right" class="linebranch"></td>
8453
    <td align="right" class="linecount "><pre></pre></td>
8454
    <td align="left" class="src "><pre></pre></td>
8455
    </tr>
8456

    
8457
    <tr>
8458
    <td align="right" class="lineno"><pre>1166</pre></td>
8459
    <td align="right" class="linebranch"></td>
8460
    <td align="right" class="linecount "><pre></pre></td>
8461
    <td align="left" class="src "><pre>        // SET PACKET SEQUENCE CONTROL</pre></td>
8462
    </tr>
8463

    
8464
    <tr>
8465
    <td align="right" class="lineno"><pre>1167</pre></td>
8466
    <td align="right" class="linebranch"></td>
8467
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8468
    <td align="left" class="src coveredLine"><pre>        increment_seq_counter_source_id( header->packetSequenceControl, sid );</pre></td>
8469
    </tr>
8470

    
8471
    <tr>
8472
    <td align="right" class="lineno"><pre>1168</pre></td>
8473
    <td align="right" class="linebranch"></td>
8474
    <td align="right" class="linecount "><pre></pre></td>
8475
    <td align="left" class="src "><pre></pre></td>
8476
    </tr>
8477

    
8478
    <tr>
8479
    <td align="right" class="lineno"><pre>1169</pre></td>
8480
    <td align="right" class="linebranch"></td>
8481
    <td align="right" class="linecount "><pre></pre></td>
8482
    <td align="left" class="src "><pre>        // SET SID</pre></td>
8483
    </tr>
8484

    
8485
    <tr>
8486
    <td align="right" class="lineno"><pre>1170</pre></td>
8487
    <td align="right" class="linebranch"></td>
8488
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8489
    <td align="left" class="src coveredLine"><pre>        header->sid = sid;</pre></td>
8490
    </tr>
8491

    
8492
    <tr>
8493
    <td align="right" class="lineno"><pre>1171</pre></td>
8494
    <td align="right" class="linebranch"></td>
8495
    <td align="right" class="linecount "><pre></pre></td>
8496
    <td align="left" class="src "><pre></pre></td>
8497
    </tr>
8498

    
8499
    <tr>
8500
    <td align="right" class="lineno"><pre>1172</pre></td>
8501
    <td align="right" class="linebranch"></td>
8502
    <td align="right" class="linecount "><pre></pre></td>
8503
    <td align="left" class="src "><pre>        // SET PACKET TIME</pre></td>
8504
    </tr>
8505

    
8506
    <tr>
8507
    <td align="right" class="lineno"><pre>1173</pre></td>
8508
    <td align="right" class="linebranch"></td>
8509
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8510
    <td align="left" class="src coveredLine"><pre>        compute_acquisition_time( coarseTime, fineTime, sid, i, header->acquisitionTime);</pre></td>
8511
    </tr>
8512

    
8513
    <tr>
8514
    <td align="right" class="lineno"><pre>1174</pre></td>
8515
    <td align="right" class="linebranch"></td>
8516
    <td align="right" class="linecount "><pre></pre></td>
8517
    <td align="left" class="src "><pre>        //</pre></td>
8518
    </tr>
8519

    
8520
    <tr>
8521
    <td align="right" class="lineno"><pre>1175</pre></td>
8522
    <td align="right" class="linebranch"></td>
8523
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8524
    <td align="left" class="src coveredLine"><pre>        header->time[0] = header->acquisitionTime[0];</pre></td>
8525
    </tr>
8526

    
8527
    <tr>
8528
    <td align="right" class="lineno"><pre>1176</pre></td>
8529
    <td align="right" class="linebranch"></td>
8530
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8531
    <td align="left" class="src coveredLine"><pre>        header->time[1] = header->acquisitionTime[1];</pre></td>
8532
    </tr>
8533

    
8534
    <tr>
8535
    <td align="right" class="lineno"><pre>1177</pre></td>
8536
    <td align="right" class="linebranch"></td>
8537
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8538
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_2] = header->acquisitionTime[BYTE_2];</pre></td>
8539
    </tr>
8540

    
8541
    <tr>
8542
    <td align="right" class="lineno"><pre>1178</pre></td>
8543
    <td align="right" class="linebranch"></td>
8544
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8545
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_3] = header->acquisitionTime[BYTE_3];</pre></td>
8546
    </tr>
8547

    
8548
    <tr>
8549
    <td align="right" class="lineno"><pre>1179</pre></td>
8550
    <td align="right" class="linebranch"></td>
8551
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8552
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_4] = header->acquisitionTime[BYTE_4];</pre></td>
8553
    </tr>
8554

    
8555
    <tr>
8556
    <td align="right" class="lineno"><pre>1180</pre></td>
8557
    <td align="right" class="linebranch"></td>
8558
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8559
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_5] = header->acquisitionTime[BYTE_5];</pre></td>
8560
    </tr>
8561

    
8562
    <tr>
8563
    <td align="right" class="lineno"><pre>1181</pre></td>
8564
    <td align="right" class="linebranch"></td>
8565
    <td align="right" class="linecount "><pre></pre></td>
8566
    <td align="left" class="src "><pre></pre></td>
8567
    </tr>
8568

    
8569
    <tr>
8570
    <td align="right" class="lineno"><pre>1182</pre></td>
8571
    <td align="right" class="linebranch"></td>
8572
    <td align="right" class="linecount "><pre></pre></td>
8573
    <td align="left" class="src "><pre>        // SET PACKET ID</pre></td>
8574
    </tr>
8575

    
8576
    <tr>
8577
    <td align="right" class="lineno"><pre>1183</pre></td>
8578
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 343928 times">&check;</span><span class="takenBranch" title="Branch 1 taken 8712 times">&check;</span></td>
8579
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8580
    <td align="left" class="src coveredLine"><pre>        if ( (sid == SID_SBM1_CWF_F1) || (sid == SID_SBM2_CWF_F2) )</pre></td>
8581
    </tr>
8582

    
8583
    <tr>
8584
    <td align="right" class="lineno"><pre>1184</pre></td>
8585
    <td align="right" class="linebranch"></td>
8586
    <td align="right" class="linecount "><pre></pre></td>
8587
    <td align="left" class="src "><pre>        {</pre></td>
8588
    </tr>
8589

    
8590
    <tr>
8591
    <td align="right" class="lineno"><pre>1185</pre></td>
8592
    <td align="right" class="linebranch"></td>
8593
    <td align="right" class="linecount coveredLine"><pre>343928</pre></td>
8594
    <td align="left" class="src coveredLine"><pre>            header->packetID[0] = (unsigned char) (APID_TM_SCIENCE_SBM1_SBM2 >> SHIFT_1_BYTE);</pre></td>
8595
    </tr>
8596

    
8597
    <tr>
8598
    <td align="right" class="lineno"><pre>1186</pre></td>
8599
    <td align="right" class="linebranch"></td>
8600
    <td align="right" class="linecount coveredLine"><pre>343928</pre></td>
8601
    <td align="left" class="src coveredLine"><pre>            header->packetID[1] = (unsigned char) (APID_TM_SCIENCE_SBM1_SBM2);</pre></td>
8602
    </tr>
8603

    
8604
    <tr>
8605
    <td align="right" class="lineno"><pre>1187</pre></td>
8606
    <td align="right" class="linebranch"></td>
8607
    <td align="right" class="linecount "><pre></pre></td>
8608
    <td align="left" class="src "><pre>        }</pre></td>
8609
    </tr>
8610

    
8611
    <tr>
8612
    <td align="right" class="lineno"><pre>1188</pre></td>
8613
    <td align="right" class="linebranch"></td>
8614
    <td align="right" class="linecount "><pre></pre></td>
8615
    <td align="left" class="src "><pre>        else</pre></td>
8616
    </tr>
8617

    
8618
    <tr>
8619
    <td align="right" class="lineno"><pre>1189</pre></td>
8620
    <td align="right" class="linebranch"></td>
8621
    <td align="right" class="linecount "><pre></pre></td>
8622
    <td align="left" class="src "><pre>        {</pre></td>
8623
    </tr>
8624

    
8625
    <tr>
8626
    <td align="right" class="lineno"><pre>1190</pre></td>
8627
    <td align="right" class="linebranch"></td>
8628
    <td align="right" class="linecount coveredLine"><pre>8712</pre></td>
8629
    <td align="left" class="src coveredLine"><pre>            header->packetID[0] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST >> SHIFT_1_BYTE);</pre></td>
8630
    </tr>
8631

    
8632
    <tr>
8633
    <td align="right" class="lineno"><pre>1191</pre></td>
8634
    <td align="right" class="linebranch"></td>
8635
    <td align="right" class="linecount coveredLine"><pre>8712</pre></td>
8636
    <td align="left" class="src coveredLine"><pre>            header->packetID[1] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST);</pre></td>
8637
    </tr>
8638

    
8639
    <tr>
8640
    <td align="right" class="lineno"><pre>1192</pre></td>
8641
    <td align="right" class="linebranch"></td>
8642
    <td align="right" class="linecount "><pre></pre></td>
8643
    <td align="left" class="src "><pre>        }</pre></td>
8644
    </tr>
8645

    
8646
    <tr>
8647
    <td align="right" class="lineno"><pre>1193</pre></td>
8648
    <td align="right" class="linebranch"></td>
8649
    <td align="right" class="linecount "><pre></pre></td>
8650
    <td align="left" class="src "><pre></pre></td>
8651
    </tr>
8652

    
8653
    <tr>
8654
    <td align="right" class="lineno"><pre>1194</pre></td>
8655
    <td align="right" class="linebranch"></td>
8656
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8657
    <td align="left" class="src coveredLine"><pre>        status = ioctl( fdSPW, SPACEWIRE_IOCTRL_SEND, &amp;spw_ioctl_send_CWF );</pre></td>
8658
    </tr>
8659

    
8660
    <tr>
8661
    <td align="right" class="lineno"><pre>1195</pre></td>
8662
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 352640 times">&check;</span></td>
8663
    <td align="right" class="linecount coveredLine"><pre>352640</pre></td>
8664
    <td align="left" class="src coveredLine"><pre>        if (status != RTEMS_SUCCESSFUL) {</pre></td>
8665
    </tr>
8666

    
8667
    <tr>
8668
    <td align="right" class="lineno"><pre>1196</pre></td>
8669
    <td align="right" class="linebranch"></td>
8670
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
8671
    <td align="left" class="src uncoveredLine"><pre>            ret = LFR_DEFAULT;</pre></td>
8672
    </tr>
8673

    
8674
    <tr>
8675
    <td align="right" class="lineno"><pre>1197</pre></td>
8676
    <td align="right" class="linebranch"></td>
8677
    <td align="right" class="linecount "><pre></pre></td>
8678
    <td align="left" class="src "><pre>        }</pre></td>
8679
    </tr>
8680

    
8681
    <tr>
8682
    <td align="right" class="lineno"><pre>1198</pre></td>
8683
    <td align="right" class="linebranch"></td>
8684
    <td align="right" class="linecount "><pre></pre></td>
8685
    <td align="left" class="src "><pre>    }</pre></td>
8686
    </tr>
8687

    
8688
    <tr>
8689
    <td align="right" class="lineno"><pre>1199</pre></td>
8690
    <td align="right" class="linebranch"></td>
8691
    <td align="right" class="linecount "><pre></pre></td>
8692
    <td align="left" class="src "><pre></pre></td>
8693
    </tr>
8694

    
8695
    <tr>
8696
    <td align="right" class="lineno"><pre>1200</pre></td>
8697
    <td align="right" class="linebranch"></td>
8698
    <td align="right" class="linecount coveredLine"><pre>44080</pre></td>
8699
    <td align="left" class="src coveredLine"><pre>    return ret;</pre></td>
8700
    </tr>
8701

    
8702
    <tr>
8703
    <td align="right" class="lineno"><pre>1201</pre></td>
8704
    <td align="right" class="linebranch"></td>
8705
    <td align="right" class="linecount "><pre></pre></td>
8706
    <td align="left" class="src "><pre>}</pre></td>
8707
    </tr>
8708

    
8709
    <tr>
8710
    <td align="right" class="lineno"><pre>1202</pre></td>
8711
    <td align="right" class="linebranch"></td>
8712
    <td align="right" class="linecount "><pre></pre></td>
8713
    <td align="left" class="src "><pre></pre></td>
8714
    </tr>
8715

    
8716
    <tr>
8717
    <td align="right" class="lineno"><pre>1203</pre></td>
8718
    <td align="right" class="linebranch"></td>
8719
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8720
    <td align="left" class="src coveredLine"><pre>int spw_send_waveform_SWF( ring_node *ring_node_to_send,</pre></td>
8721
    </tr>
8722

    
8723
    <tr>
8724
    <td align="right" class="lineno"><pre>1204</pre></td>
8725
    <td align="right" class="linebranch"></td>
8726
    <td align="right" class="linecount "><pre></pre></td>
8727
    <td align="left" class="src "><pre>                       Header_TM_LFR_SCIENCE_SWF_t *header )</pre></td>
8728
    </tr>
8729

    
8730
    <tr>
8731
    <td align="right" class="lineno"><pre>1205</pre></td>
8732
    <td align="right" class="linebranch"></td>
8733
    <td align="right" class="linecount "><pre></pre></td>
8734
    <td align="left" class="src "><pre>{</pre></td>
8735
    </tr>
8736

    
8737
    <tr>
8738
    <td align="right" class="lineno"><pre>1206</pre></td>
8739
    <td align="right" class="linebranch"></td>
8740
    <td align="right" class="linecount "><pre></pre></td>
8741
    <td align="left" class="src "><pre>    /** This function sends SWF CCSDS packets (F2, F1 or F0).</pre></td>
8742
    </tr>
8743

    
8744
    <tr>
8745
    <td align="right" class="lineno"><pre>1207</pre></td>
8746
    <td align="right" class="linebranch"></td>
8747
    <td align="right" class="linecount "><pre></pre></td>
8748
    <td align="left" class="src "><pre>     *</pre></td>
8749
    </tr>
8750

    
8751
    <tr>
8752
    <td align="right" class="lineno"><pre>1208</pre></td>
8753
    <td align="right" class="linebranch"></td>
8754
    <td align="right" class="linecount "><pre></pre></td>
8755
    <td align="left" class="src "><pre>     * @param waveform points to the buffer containing the data that will be send.</pre></td>
8756
    </tr>
8757

    
8758
    <tr>
8759
    <td align="right" class="lineno"><pre>1209</pre></td>
8760
    <td align="right" class="linebranch"></td>
8761
    <td align="right" class="linecount "><pre></pre></td>
8762
    <td align="left" class="src "><pre>     * @param sid is the source identifier of the data that will be sent.</pre></td>
8763
    </tr>
8764

    
8765
    <tr>
8766
    <td align="right" class="lineno"><pre>1210</pre></td>
8767
    <td align="right" class="linebranch"></td>
8768
    <td align="right" class="linecount "><pre></pre></td>
8769
    <td align="left" class="src "><pre>     * @param headerSWF points to a table of headers that have been prepared for the data transmission.</pre></td>
8770
    </tr>
8771

    
8772
    <tr>
8773
    <td align="right" class="lineno"><pre>1211</pre></td>
8774
    <td align="right" class="linebranch"></td>
8775
    <td align="right" class="linecount "><pre></pre></td>
8776
    <td align="left" class="src "><pre>     * @param queue_id is the id of the rtems queue to which spw_ioctl_pkt_send structures will be send. The structures</pre></td>
8777
    </tr>
8778

    
8779
    <tr>
8780
    <td align="right" class="lineno"><pre>1212</pre></td>
8781
    <td align="right" class="linebranch"></td>
8782
    <td align="right" class="linecount "><pre></pre></td>
8783
    <td align="left" class="src "><pre>     * contain information to setup the transmission of the data packets.</pre></td>
8784
    </tr>
8785

    
8786
    <tr>
8787
    <td align="right" class="lineno"><pre>1213</pre></td>
8788
    <td align="right" class="linebranch"></td>
8789
    <td align="right" class="linecount "><pre></pre></td>
8790
    <td align="left" class="src "><pre>     *</pre></td>
8791
    </tr>
8792

    
8793
    <tr>
8794
    <td align="right" class="lineno"><pre>1214</pre></td>
8795
    <td align="right" class="linebranch"></td>
8796
    <td align="right" class="linecount "><pre></pre></td>
8797
    <td align="left" class="src "><pre>     * One group of 2048 samples is sent as 7 consecutive packets, 6 packets containing 340 blocks and 8 packets containing 8 blocks.</pre></td>
8798
    </tr>
8799

    
8800
    <tr>
8801
    <td align="right" class="lineno"><pre>1215</pre></td>
8802
    <td align="right" class="linebranch"></td>
8803
    <td align="right" class="linecount "><pre></pre></td>
8804
    <td align="left" class="src "><pre>     *</pre></td>
8805
    </tr>
8806

    
8807
    <tr>
8808
    <td align="right" class="lineno"><pre>1216</pre></td>
8809
    <td align="right" class="linebranch"></td>
8810
    <td align="right" class="linecount "><pre></pre></td>
8811
    <td align="left" class="src "><pre>     */</pre></td>
8812
    </tr>
8813

    
8814
    <tr>
8815
    <td align="right" class="lineno"><pre>1217</pre></td>
8816
    <td align="right" class="linebranch"></td>
8817
    <td align="right" class="linecount "><pre></pre></td>
8818
    <td align="left" class="src "><pre></pre></td>
8819
    </tr>
8820

    
8821
    <tr>
8822
    <td align="right" class="lineno"><pre>1218</pre></td>
8823
    <td align="right" class="linebranch"></td>
8824
    <td align="right" class="linecount "><pre></pre></td>
8825
    <td align="left" class="src "><pre>    unsigned int i;</pre></td>
8826
    </tr>
8827

    
8828
    <tr>
8829
    <td align="right" class="lineno"><pre>1219</pre></td>
8830
    <td align="right" class="linebranch"></td>
8831
    <td align="right" class="linecount "><pre></pre></td>
8832
    <td align="left" class="src "><pre>    int ret;</pre></td>
8833
    </tr>
8834

    
8835
    <tr>
8836
    <td align="right" class="lineno"><pre>1220</pre></td>
8837
    <td align="right" class="linebranch"></td>
8838
    <td align="right" class="linecount "><pre></pre></td>
8839
    <td align="left" class="src "><pre>    unsigned int coarseTime;</pre></td>
8840
    </tr>
8841

    
8842
    <tr>
8843
    <td align="right" class="lineno"><pre>1221</pre></td>
8844
    <td align="right" class="linebranch"></td>
8845
    <td align="right" class="linecount "><pre></pre></td>
8846
    <td align="left" class="src "><pre>    unsigned int fineTime;</pre></td>
8847
    </tr>
8848

    
8849
    <tr>
8850
    <td align="right" class="lineno"><pre>1222</pre></td>
8851
    <td align="right" class="linebranch"></td>
8852
    <td align="right" class="linecount "><pre></pre></td>
8853
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
8854
    </tr>
8855

    
8856
    <tr>
8857
    <td align="right" class="lineno"><pre>1223</pre></td>
8858
    <td align="right" class="linebranch"></td>
8859
    <td align="right" class="linecount "><pre></pre></td>
8860
    <td align="left" class="src "><pre>    spw_ioctl_pkt_send spw_ioctl_send_SWF;</pre></td>
8861
    </tr>
8862

    
8863
    <tr>
8864
    <td align="right" class="lineno"><pre>1224</pre></td>
8865
    <td align="right" class="linebranch"></td>
8866
    <td align="right" class="linecount "><pre></pre></td>
8867
    <td align="left" class="src "><pre>    int *dataPtr;</pre></td>
8868
    </tr>
8869

    
8870
    <tr>
8871
    <td align="right" class="lineno"><pre>1225</pre></td>
8872
    <td align="right" class="linebranch"></td>
8873
    <td align="right" class="linecount "><pre></pre></td>
8874
    <td align="left" class="src "><pre>    unsigned char sid;</pre></td>
8875
    </tr>
8876

    
8877
    <tr>
8878
    <td align="right" class="lineno"><pre>1226</pre></td>
8879
    <td align="right" class="linebranch"></td>
8880
    <td align="right" class="linecount "><pre></pre></td>
8881
    <td align="left" class="src "><pre></pre></td>
8882
    </tr>
8883

    
8884
    <tr>
8885
    <td align="right" class="lineno"><pre>1227</pre></td>
8886
    <td align="right" class="linebranch"></td>
8887
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8888
    <td align="left" class="src coveredLine"><pre>    spw_ioctl_send_SWF.hlen = HEADER_LENGTH_TM_LFR_SCIENCE_SWF;</pre></td>
8889
    </tr>
8890

    
8891
    <tr>
8892
    <td align="right" class="lineno"><pre>1228</pre></td>
8893
    <td align="right" class="linebranch"></td>
8894
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8895
    <td align="left" class="src coveredLine"><pre>    spw_ioctl_send_SWF.options = 0;</pre></td>
8896
    </tr>
8897

    
8898
    <tr>
8899
    <td align="right" class="lineno"><pre>1229</pre></td>
8900
    <td align="right" class="linebranch"></td>
8901
    <td align="right" class="linecount "><pre></pre></td>
8902
    <td align="left" class="src "><pre></pre></td>
8903
    </tr>
8904

    
8905
    <tr>
8906
    <td align="right" class="lineno"><pre>1230</pre></td>
8907
    <td align="right" class="linebranch"></td>
8908
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8909
    <td align="left" class="src coveredLine"><pre>    ret = LFR_DEFAULT;</pre></td>
8910
    </tr>
8911

    
8912
    <tr>
8913
    <td align="right" class="lineno"><pre>1231</pre></td>
8914
    <td align="right" class="linebranch"></td>
8915
    <td align="right" class="linecount "><pre></pre></td>
8916
    <td align="left" class="src "><pre></pre></td>
8917
    </tr>
8918

    
8919
    <tr>
8920
    <td align="right" class="lineno"><pre>1232</pre></td>
8921
    <td align="right" class="linebranch"></td>
8922
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8923
    <td align="left" class="src coveredLine"><pre>    coarseTime  = ring_node_to_send->coarseTime;</pre></td>
8924
    </tr>
8925

    
8926
    <tr>
8927
    <td align="right" class="lineno"><pre>1233</pre></td>
8928
    <td align="right" class="linebranch"></td>
8929
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8930
    <td align="left" class="src coveredLine"><pre>    fineTime    = ring_node_to_send->fineTime;</pre></td>
8931
    </tr>
8932

    
8933
    <tr>
8934
    <td align="right" class="lineno"><pre>1234</pre></td>
8935
    <td align="right" class="linebranch"></td>
8936
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8937
    <td align="left" class="src coveredLine"><pre>    dataPtr     = (int*) ring_node_to_send->buffer_address;</pre></td>
8938
    </tr>
8939

    
8940
    <tr>
8941
    <td align="right" class="lineno"><pre>1235</pre></td>
8942
    <td align="right" class="linebranch"></td>
8943
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8944
    <td align="left" class="src coveredLine"><pre>    sid = ring_node_to_send->sid;</pre></td>
8945
    </tr>
8946

    
8947
    <tr>
8948
    <td align="right" class="lineno"><pre>1236</pre></td>
8949
    <td align="right" class="linebranch"></td>
8950
    <td align="right" class="linecount "><pre></pre></td>
8951
    <td align="left" class="src "><pre></pre></td>
8952
    </tr>
8953

    
8954
    <tr>
8955
    <td align="right" class="lineno"><pre>1237</pre></td>
8956
    <td align="right" class="linebranch"></td>
8957
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8958
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info = pa_bia_status_info;</pre></td>
8959
    </tr>
8960

    
8961
    <tr>
8962
    <td align="right" class="lineno"><pre>1238</pre></td>
8963
    <td align="right" class="linebranch"></td>
8964
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
8965
    <td align="left" class="src coveredLine"><pre>    header->sy_lfr_common_parameters = parameter_dump_packet.sy_lfr_common_parameters;</pre></td>
8966
    </tr>
8967

    
8968
    <tr>
8969
    <td align="right" class="lineno"><pre>1239</pre></td>
8970
    <td align="right" class="linebranch"></td>
8971
    <td align="right" class="linecount "><pre></pre></td>
8972
    <td align="left" class="src "><pre></pre></td>
8973
    </tr>
8974

    
8975
    <tr>
8976
    <td align="right" class="lineno"><pre>1240</pre></td>
8977
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 38745 times">&check;</span><span class="takenBranch" title="Branch 1 taken 5535 times">&check;</span></td>
8978
    <td align="right" class="linecount coveredLine"><pre>44280</pre></td>
8979
    <td align="left" class="src coveredLine"><pre>    for (i=0; i&lt;PKTCNT_SWF; i++) // send waveform</pre></td>
8980
    </tr>
8981

    
8982
    <tr>
8983
    <td align="right" class="lineno"><pre>1241</pre></td>
8984
    <td align="right" class="linebranch"></td>
8985
    <td align="right" class="linecount "><pre></pre></td>
8986
    <td align="left" class="src "><pre>    {</pre></td>
8987
    </tr>
8988

    
8989
    <tr>
8990
    <td align="right" class="lineno"><pre>1242</pre></td>
8991
    <td align="right" class="linebranch"></td>
8992
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
8993
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_SWF.data = (char*) &amp;dataPtr[ (i * BLK_NR_304 * NB_WORDS_SWF_BLK) ];</pre></td>
8994
    </tr>
8995

    
8996
    <tr>
8997
    <td align="right" class="lineno"><pre>1243</pre></td>
8998
    <td align="right" class="linebranch"></td>
8999
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9000
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_SWF.hdr = (char*) header;</pre></td>
9001
    </tr>
9002

    
9003
    <tr>
9004
    <td align="right" class="lineno"><pre>1244</pre></td>
9005
    <td align="right" class="linebranch"></td>
9006
    <td align="right" class="linecount "><pre></pre></td>
9007
    <td align="left" class="src "><pre></pre></td>
9008
    </tr>
9009

    
9010
    <tr>
9011
    <td align="right" class="lineno"><pre>1245</pre></td>
9012
    <td align="right" class="linebranch"></td>
9013
    <td align="right" class="linecount "><pre></pre></td>
9014
    <td align="left" class="src "><pre>        // SET PACKET SEQUENCE CONTROL</pre></td>
9015
    </tr>
9016

    
9017
    <tr>
9018
    <td align="right" class="lineno"><pre>1246</pre></td>
9019
    <td align="right" class="linebranch"></td>
9020
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9021
    <td align="left" class="src coveredLine"><pre>        increment_seq_counter_source_id( header->packetSequenceControl, sid );</pre></td>
9022
    </tr>
9023

    
9024
    <tr>
9025
    <td align="right" class="lineno"><pre>1247</pre></td>
9026
    <td align="right" class="linebranch"></td>
9027
    <td align="right" class="linecount "><pre></pre></td>
9028
    <td align="left" class="src "><pre></pre></td>
9029
    </tr>
9030

    
9031
    <tr>
9032
    <td align="right" class="lineno"><pre>1248</pre></td>
9033
    <td align="right" class="linebranch"></td>
9034
    <td align="right" class="linecount "><pre></pre></td>
9035
    <td align="left" class="src "><pre>        // SET PACKET LENGTH AND BLKNR</pre></td>
9036
    </tr>
9037

    
9038
    <tr>
9039
    <td align="right" class="lineno"><pre>1249</pre></td>
9040
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 5535 times">&check;</span><span class="takenBranch" title="Branch 1 taken 33210 times">&check;</span></td>
9041
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9042
    <td align="left" class="src coveredLine"><pre>        if (i == (PKTCNT_SWF-1))</pre></td>
9043
    </tr>
9044

    
9045
    <tr>
9046
    <td align="right" class="lineno"><pre>1250</pre></td>
9047
    <td align="right" class="linebranch"></td>
9048
    <td align="right" class="linecount "><pre></pre></td>
9049
    <td align="left" class="src "><pre>        {</pre></td>
9050
    </tr>
9051

    
9052
    <tr>
9053
    <td align="right" class="lineno"><pre>1251</pre></td>
9054
    <td align="right" class="linebranch"></td>
9055
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
9056
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_SWF.dlen = BLK_NR_224 * NB_BYTES_SWF_BLK;</pre></td>
9057
    </tr>
9058

    
9059
    <tr>
9060
    <td align="right" class="lineno"><pre>1252</pre></td>
9061
    <td align="right" class="linebranch"></td>
9062
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
9063
    <td align="left" class="src coveredLine"><pre>            header->packetLength[0] = (unsigned char) (TM_LEN_SCI_SWF_224 >> SHIFT_1_BYTE);</pre></td>
9064
    </tr>
9065

    
9066
    <tr>
9067
    <td align="right" class="lineno"><pre>1253</pre></td>
9068
    <td align="right" class="linebranch"></td>
9069
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
9070
    <td align="left" class="src coveredLine"><pre>            header->packetLength[1] = (unsigned char) (TM_LEN_SCI_SWF_224     );</pre></td>
9071
    </tr>
9072

    
9073
    <tr>
9074
    <td align="right" class="lineno"><pre>1254</pre></td>
9075
    <td align="right" class="linebranch"></td>
9076
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
9077
    <td align="left" class="src coveredLine"><pre>            header->blkNr[0] = (unsigned char) (BLK_NR_224 >> SHIFT_1_BYTE);</pre></td>
9078
    </tr>
9079

    
9080
    <tr>
9081
    <td align="right" class="lineno"><pre>1255</pre></td>
9082
    <td align="right" class="linebranch"></td>
9083
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
9084
    <td align="left" class="src coveredLine"><pre>            header->blkNr[1] = (unsigned char) (BLK_NR_224     );</pre></td>
9085
    </tr>
9086

    
9087
    <tr>
9088
    <td align="right" class="lineno"><pre>1256</pre></td>
9089
    <td align="right" class="linebranch"></td>
9090
    <td align="right" class="linecount "><pre></pre></td>
9091
    <td align="left" class="src "><pre>        }</pre></td>
9092
    </tr>
9093

    
9094
    <tr>
9095
    <td align="right" class="lineno"><pre>1257</pre></td>
9096
    <td align="right" class="linebranch"></td>
9097
    <td align="right" class="linecount "><pre></pre></td>
9098
    <td align="left" class="src "><pre>        else</pre></td>
9099
    </tr>
9100

    
9101
    <tr>
9102
    <td align="right" class="lineno"><pre>1258</pre></td>
9103
    <td align="right" class="linebranch"></td>
9104
    <td align="right" class="linecount "><pre></pre></td>
9105
    <td align="left" class="src "><pre>        {</pre></td>
9106
    </tr>
9107

    
9108
    <tr>
9109
    <td align="right" class="lineno"><pre>1259</pre></td>
9110
    <td align="right" class="linebranch"></td>
9111
    <td align="right" class="linecount coveredLine"><pre>33210</pre></td>
9112
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_SWF.dlen = BLK_NR_304 * NB_BYTES_SWF_BLK;</pre></td>
9113
    </tr>
9114

    
9115
    <tr>
9116
    <td align="right" class="lineno"><pre>1260</pre></td>
9117
    <td align="right" class="linebranch"></td>
9118
    <td align="right" class="linecount coveredLine"><pre>33210</pre></td>
9119
    <td align="left" class="src coveredLine"><pre>            header->packetLength[0] = (unsigned char) (TM_LEN_SCI_SWF_304 >> SHIFT_1_BYTE);</pre></td>
9120
    </tr>
9121

    
9122
    <tr>
9123
    <td align="right" class="lineno"><pre>1261</pre></td>
9124
    <td align="right" class="linebranch"></td>
9125
    <td align="right" class="linecount coveredLine"><pre>33210</pre></td>
9126
    <td align="left" class="src coveredLine"><pre>            header->packetLength[1] = (unsigned char) (TM_LEN_SCI_SWF_304     );</pre></td>
9127
    </tr>
9128

    
9129
    <tr>
9130
    <td align="right" class="lineno"><pre>1262</pre></td>
9131
    <td align="right" class="linebranch"></td>
9132
    <td align="right" class="linecount coveredLine"><pre>33210</pre></td>
9133
    <td align="left" class="src coveredLine"><pre>            header->blkNr[0] = (unsigned char) (BLK_NR_304 >> SHIFT_1_BYTE);</pre></td>
9134
    </tr>
9135

    
9136
    <tr>
9137
    <td align="right" class="lineno"><pre>1263</pre></td>
9138
    <td align="right" class="linebranch"></td>
9139
    <td align="right" class="linecount coveredLine"><pre>33210</pre></td>
9140
    <td align="left" class="src coveredLine"><pre>            header->blkNr[1] = (unsigned char) (BLK_NR_304     );</pre></td>
9141
    </tr>
9142

    
9143
    <tr>
9144
    <td align="right" class="lineno"><pre>1264</pre></td>
9145
    <td align="right" class="linebranch"></td>
9146
    <td align="right" class="linecount "><pre></pre></td>
9147
    <td align="left" class="src "><pre>        }</pre></td>
9148
    </tr>
9149

    
9150
    <tr>
9151
    <td align="right" class="lineno"><pre>1265</pre></td>
9152
    <td align="right" class="linebranch"></td>
9153
    <td align="right" class="linecount "><pre></pre></td>
9154
    <td align="left" class="src "><pre></pre></td>
9155
    </tr>
9156

    
9157
    <tr>
9158
    <td align="right" class="lineno"><pre>1266</pre></td>
9159
    <td align="right" class="linebranch"></td>
9160
    <td align="right" class="linecount "><pre></pre></td>
9161
    <td align="left" class="src "><pre>        // SET PACKET TIME</pre></td>
9162
    </tr>
9163

    
9164
    <tr>
9165
    <td align="right" class="lineno"><pre>1267</pre></td>
9166
    <td align="right" class="linebranch"></td>
9167
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9168
    <td align="left" class="src coveredLine"><pre>        compute_acquisition_time( coarseTime, fineTime, sid, i, header->acquisitionTime );</pre></td>
9169
    </tr>
9170

    
9171
    <tr>
9172
    <td align="right" class="lineno"><pre>1268</pre></td>
9173
    <td align="right" class="linebranch"></td>
9174
    <td align="right" class="linecount "><pre></pre></td>
9175
    <td align="left" class="src "><pre>        //</pre></td>
9176
    </tr>
9177

    
9178
    <tr>
9179
    <td align="right" class="lineno"><pre>1269</pre></td>
9180
    <td align="right" class="linebranch"></td>
9181
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9182
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_0] = header->acquisitionTime[BYTE_0];</pre></td>
9183
    </tr>
9184

    
9185
    <tr>
9186
    <td align="right" class="lineno"><pre>1270</pre></td>
9187
    <td align="right" class="linebranch"></td>
9188
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9189
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_1] = header->acquisitionTime[BYTE_1];</pre></td>
9190
    </tr>
9191

    
9192
    <tr>
9193
    <td align="right" class="lineno"><pre>1271</pre></td>
9194
    <td align="right" class="linebranch"></td>
9195
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9196
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_2] = header->acquisitionTime[BYTE_2];</pre></td>
9197
    </tr>
9198

    
9199
    <tr>
9200
    <td align="right" class="lineno"><pre>1272</pre></td>
9201
    <td align="right" class="linebranch"></td>
9202
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9203
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_3] = header->acquisitionTime[BYTE_3];</pre></td>
9204
    </tr>
9205

    
9206
    <tr>
9207
    <td align="right" class="lineno"><pre>1273</pre></td>
9208
    <td align="right" class="linebranch"></td>
9209
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9210
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_4] = header->acquisitionTime[BYTE_4];</pre></td>
9211
    </tr>
9212

    
9213
    <tr>
9214
    <td align="right" class="lineno"><pre>1274</pre></td>
9215
    <td align="right" class="linebranch"></td>
9216
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9217
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_5] = header->acquisitionTime[BYTE_5];</pre></td>
9218
    </tr>
9219

    
9220
    <tr>
9221
    <td align="right" class="lineno"><pre>1275</pre></td>
9222
    <td align="right" class="linebranch"></td>
9223
    <td align="right" class="linecount "><pre></pre></td>
9224
    <td align="left" class="src "><pre></pre></td>
9225
    </tr>
9226

    
9227
    <tr>
9228
    <td align="right" class="lineno"><pre>1276</pre></td>
9229
    <td align="right" class="linebranch"></td>
9230
    <td align="right" class="linecount "><pre></pre></td>
9231
    <td align="left" class="src "><pre>        // SET SID</pre></td>
9232
    </tr>
9233

    
9234
    <tr>
9235
    <td align="right" class="lineno"><pre>1277</pre></td>
9236
    <td align="right" class="linebranch"></td>
9237
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9238
    <td align="left" class="src coveredLine"><pre>        header->sid = sid;</pre></td>
9239
    </tr>
9240

    
9241
    <tr>
9242
    <td align="right" class="lineno"><pre>1278</pre></td>
9243
    <td align="right" class="linebranch"></td>
9244
    <td align="right" class="linecount "><pre></pre></td>
9245
    <td align="left" class="src "><pre></pre></td>
9246
    </tr>
9247

    
9248
    <tr>
9249
    <td align="right" class="lineno"><pre>1279</pre></td>
9250
    <td align="right" class="linebranch"></td>
9251
    <td align="right" class="linecount "><pre></pre></td>
9252
    <td align="left" class="src "><pre>        // SET PKTNR</pre></td>
9253
    </tr>
9254

    
9255
    <tr>
9256
    <td align="right" class="lineno"><pre>1280</pre></td>
9257
    <td align="right" class="linebranch"></td>
9258
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9259
    <td align="left" class="src coveredLine"><pre>        header->pktNr = i+1;    // PKT_NR</pre></td>
9260
    </tr>
9261

    
9262
    <tr>
9263
    <td align="right" class="lineno"><pre>1281</pre></td>
9264
    <td align="right" class="linebranch"></td>
9265
    <td align="right" class="linecount "><pre></pre></td>
9266
    <td align="left" class="src "><pre></pre></td>
9267
    </tr>
9268

    
9269
    <tr>
9270
    <td align="right" class="lineno"><pre>1282</pre></td>
9271
    <td align="right" class="linebranch"></td>
9272
    <td align="right" class="linecount "><pre></pre></td>
9273
    <td align="left" class="src "><pre>        // SEND PACKET</pre></td>
9274
    </tr>
9275

    
9276
    <tr>
9277
    <td align="right" class="lineno"><pre>1283</pre></td>
9278
    <td align="right" class="linebranch"></td>
9279
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9280
    <td align="left" class="src coveredLine"><pre>        status = ioctl( fdSPW, SPACEWIRE_IOCTRL_SEND, &amp;spw_ioctl_send_SWF );</pre></td>
9281
    </tr>
9282

    
9283
    <tr>
9284
    <td align="right" class="lineno"><pre>1284</pre></td>
9285
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 38745 times">&check;</span></td>
9286
    <td align="right" class="linecount coveredLine"><pre>38745</pre></td>
9287
    <td align="left" class="src coveredLine"><pre>        if (status != RTEMS_SUCCESSFUL) {</pre></td>
9288
    </tr>
9289

    
9290
    <tr>
9291
    <td align="right" class="lineno"><pre>1285</pre></td>
9292
    <td align="right" class="linebranch"></td>
9293
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
9294
    <td align="left" class="src uncoveredLine"><pre>            ret = LFR_DEFAULT;</pre></td>
9295
    </tr>
9296

    
9297
    <tr>
9298
    <td align="right" class="lineno"><pre>1286</pre></td>
9299
    <td align="right" class="linebranch"></td>
9300
    <td align="right" class="linecount "><pre></pre></td>
9301
    <td align="left" class="src "><pre>        }</pre></td>
9302
    </tr>
9303

    
9304
    <tr>
9305
    <td align="right" class="lineno"><pre>1287</pre></td>
9306
    <td align="right" class="linebranch"></td>
9307
    <td align="right" class="linecount "><pre></pre></td>
9308
    <td align="left" class="src "><pre>    }</pre></td>
9309
    </tr>
9310

    
9311
    <tr>
9312
    <td align="right" class="lineno"><pre>1288</pre></td>
9313
    <td align="right" class="linebranch"></td>
9314
    <td align="right" class="linecount "><pre></pre></td>
9315
    <td align="left" class="src "><pre></pre></td>
9316
    </tr>
9317

    
9318
    <tr>
9319
    <td align="right" class="lineno"><pre>1289</pre></td>
9320
    <td align="right" class="linebranch"></td>
9321
    <td align="right" class="linecount coveredLine"><pre>5535</pre></td>
9322
    <td align="left" class="src coveredLine"><pre>    return ret;</pre></td>
9323
    </tr>
9324

    
9325
    <tr>
9326
    <td align="right" class="lineno"><pre>1290</pre></td>
9327
    <td align="right" class="linebranch"></td>
9328
    <td align="right" class="linecount "><pre></pre></td>
9329
    <td align="left" class="src "><pre>}</pre></td>
9330
    </tr>
9331

    
9332
    <tr>
9333
    <td align="right" class="lineno"><pre>1291</pre></td>
9334
    <td align="right" class="linebranch"></td>
9335
    <td align="right" class="linecount "><pre></pre></td>
9336
    <td align="left" class="src "><pre></pre></td>
9337
    </tr>
9338

    
9339
    <tr>
9340
    <td align="right" class="lineno"><pre>1292</pre></td>
9341
    <td align="right" class="linebranch"></td>
9342
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9343
    <td align="left" class="src coveredLine"><pre>int spw_send_waveform_CWF3_light( ring_node *ring_node_to_send,</pre></td>
9344
    </tr>
9345

    
9346
    <tr>
9347
    <td align="right" class="lineno"><pre>1293</pre></td>
9348
    <td align="right" class="linebranch"></td>
9349
    <td align="right" class="linecount "><pre></pre></td>
9350
    <td align="left" class="src "><pre>                                  Header_TM_LFR_SCIENCE_CWF_t *header )</pre></td>
9351
    </tr>
9352

    
9353
    <tr>
9354
    <td align="right" class="lineno"><pre>1294</pre></td>
9355
    <td align="right" class="linebranch"></td>
9356
    <td align="right" class="linecount "><pre></pre></td>
9357
    <td align="left" class="src "><pre>{</pre></td>
9358
    </tr>
9359

    
9360
    <tr>
9361
    <td align="right" class="lineno"><pre>1295</pre></td>
9362
    <td align="right" class="linebranch"></td>
9363
    <td align="right" class="linecount "><pre></pre></td>
9364
    <td align="left" class="src "><pre>    /** This function sends CWF_F3 CCSDS packets without the b1, b2 and b3 data.</pre></td>
9365
    </tr>
9366

    
9367
    <tr>
9368
    <td align="right" class="lineno"><pre>1296</pre></td>
9369
    <td align="right" class="linebranch"></td>
9370
    <td align="right" class="linecount "><pre></pre></td>
9371
    <td align="left" class="src "><pre>     *</pre></td>
9372
    </tr>
9373

    
9374
    <tr>
9375
    <td align="right" class="lineno"><pre>1297</pre></td>
9376
    <td align="right" class="linebranch"></td>
9377
    <td align="right" class="linecount "><pre></pre></td>
9378
    <td align="left" class="src "><pre>     * @param waveform points to the buffer containing the data that will be send.</pre></td>
9379
    </tr>
9380

    
9381
    <tr>
9382
    <td align="right" class="lineno"><pre>1298</pre></td>
9383
    <td align="right" class="linebranch"></td>
9384
    <td align="right" class="linecount "><pre></pre></td>
9385
    <td align="left" class="src "><pre>     * @param headerCWF points to a table of headers that have been prepared for the data transmission.</pre></td>
9386
    </tr>
9387

    
9388
    <tr>
9389
    <td align="right" class="lineno"><pre>1299</pre></td>
9390
    <td align="right" class="linebranch"></td>
9391
    <td align="right" class="linecount "><pre></pre></td>
9392
    <td align="left" class="src "><pre>     * @param queue_id is the id of the rtems queue to which spw_ioctl_pkt_send structures will be send. The structures</pre></td>
9393
    </tr>
9394

    
9395
    <tr>
9396
    <td align="right" class="lineno"><pre>1300</pre></td>
9397
    <td align="right" class="linebranch"></td>
9398
    <td align="right" class="linecount "><pre></pre></td>
9399
    <td align="left" class="src "><pre>     * contain information to setup the transmission of the data packets.</pre></td>
9400
    </tr>
9401

    
9402
    <tr>
9403
    <td align="right" class="lineno"><pre>1301</pre></td>
9404
    <td align="right" class="linebranch"></td>
9405
    <td align="right" class="linecount "><pre></pre></td>
9406
    <td align="left" class="src "><pre>     *</pre></td>
9407
    </tr>
9408

    
9409
    <tr>
9410
    <td align="right" class="lineno"><pre>1302</pre></td>
9411
    <td align="right" class="linebranch"></td>
9412
    <td align="right" class="linecount "><pre></pre></td>
9413
    <td align="left" class="src "><pre>     * By default, CWF_F3 packet are send without the b1, b2 and b3 data. This function rebuilds a data buffer</pre></td>
9414
    </tr>
9415

    
9416
    <tr>
9417
    <td align="right" class="lineno"><pre>1303</pre></td>
9418
    <td align="right" class="linebranch"></td>
9419
    <td align="right" class="linecount "><pre></pre></td>
9420
    <td align="left" class="src "><pre>     * from the incoming data and sends it in 7 packets, 6 containing 340 blocks and 1 one containing 8 blocks.</pre></td>
9421
    </tr>
9422

    
9423
    <tr>
9424
    <td align="right" class="lineno"><pre>1304</pre></td>
9425
    <td align="right" class="linebranch"></td>
9426
    <td align="right" class="linecount "><pre></pre></td>
9427
    <td align="left" class="src "><pre>     *</pre></td>
9428
    </tr>
9429

    
9430
    <tr>
9431
    <td align="right" class="lineno"><pre>1305</pre></td>
9432
    <td align="right" class="linebranch"></td>
9433
    <td align="right" class="linecount "><pre></pre></td>
9434
    <td align="left" class="src "><pre>     */</pre></td>
9435
    </tr>
9436

    
9437
    <tr>
9438
    <td align="right" class="lineno"><pre>1306</pre></td>
9439
    <td align="right" class="linebranch"></td>
9440
    <td align="right" class="linecount "><pre></pre></td>
9441
    <td align="left" class="src "><pre></pre></td>
9442
    </tr>
9443

    
9444
    <tr>
9445
    <td align="right" class="lineno"><pre>1307</pre></td>
9446
    <td align="right" class="linebranch"></td>
9447
    <td align="right" class="linecount "><pre></pre></td>
9448
    <td align="left" class="src "><pre>    unsigned int i;</pre></td>
9449
    </tr>
9450

    
9451
    <tr>
9452
    <td align="right" class="lineno"><pre>1308</pre></td>
9453
    <td align="right" class="linebranch"></td>
9454
    <td align="right" class="linecount "><pre></pre></td>
9455
    <td align="left" class="src "><pre>    int ret;</pre></td>
9456
    </tr>
9457

    
9458
    <tr>
9459
    <td align="right" class="lineno"><pre>1309</pre></td>
9460
    <td align="right" class="linebranch"></td>
9461
    <td align="right" class="linecount "><pre></pre></td>
9462
    <td align="left" class="src "><pre>    unsigned int coarseTime;</pre></td>
9463
    </tr>
9464

    
9465
    <tr>
9466
    <td align="right" class="lineno"><pre>1310</pre></td>
9467
    <td align="right" class="linebranch"></td>
9468
    <td align="right" class="linecount "><pre></pre></td>
9469
    <td align="left" class="src "><pre>    unsigned int fineTime;</pre></td>
9470
    </tr>
9471

    
9472
    <tr>
9473
    <td align="right" class="lineno"><pre>1311</pre></td>
9474
    <td align="right" class="linebranch"></td>
9475
    <td align="right" class="linecount "><pre></pre></td>
9476
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
9477
    </tr>
9478

    
9479
    <tr>
9480
    <td align="right" class="lineno"><pre>1312</pre></td>
9481
    <td align="right" class="linebranch"></td>
9482
    <td align="right" class="linecount "><pre></pre></td>
9483
    <td align="left" class="src "><pre>    spw_ioctl_pkt_send spw_ioctl_send_CWF;</pre></td>
9484
    </tr>
9485

    
9486
    <tr>
9487
    <td align="right" class="lineno"><pre>1313</pre></td>
9488
    <td align="right" class="linebranch"></td>
9489
    <td align="right" class="linecount "><pre></pre></td>
9490
    <td align="left" class="src "><pre>    char *dataPtr;</pre></td>
9491
    </tr>
9492

    
9493
    <tr>
9494
    <td align="right" class="lineno"><pre>1314</pre></td>
9495
    <td align="right" class="linebranch"></td>
9496
    <td align="right" class="linecount "><pre></pre></td>
9497
    <td align="left" class="src "><pre>    unsigned char sid;</pre></td>
9498
    </tr>
9499

    
9500
    <tr>
9501
    <td align="right" class="lineno"><pre>1315</pre></td>
9502
    <td align="right" class="linebranch"></td>
9503
    <td align="right" class="linecount "><pre></pre></td>
9504
    <td align="left" class="src "><pre></pre></td>
9505
    </tr>
9506

    
9507
    <tr>
9508
    <td align="right" class="lineno"><pre>1316</pre></td>
9509
    <td align="right" class="linebranch"></td>
9510
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9511
    <td align="left" class="src coveredLine"><pre>    spw_ioctl_send_CWF.hlen = HEADER_LENGTH_TM_LFR_SCIENCE_CWF;</pre></td>
9512
    </tr>
9513

    
9514
    <tr>
9515
    <td align="right" class="lineno"><pre>1317</pre></td>
9516
    <td align="right" class="linebranch"></td>
9517
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9518
    <td align="left" class="src coveredLine"><pre>    spw_ioctl_send_CWF.options = 0;</pre></td>
9519
    </tr>
9520

    
9521
    <tr>
9522
    <td align="right" class="lineno"><pre>1318</pre></td>
9523
    <td align="right" class="linebranch"></td>
9524
    <td align="right" class="linecount "><pre></pre></td>
9525
    <td align="left" class="src "><pre></pre></td>
9526
    </tr>
9527

    
9528
    <tr>
9529
    <td align="right" class="lineno"><pre>1319</pre></td>
9530
    <td align="right" class="linebranch"></td>
9531
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9532
    <td align="left" class="src coveredLine"><pre>    ret = LFR_DEFAULT;</pre></td>
9533
    </tr>
9534

    
9535
    <tr>
9536
    <td align="right" class="lineno"><pre>1320</pre></td>
9537
    <td align="right" class="linebranch"></td>
9538
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9539
    <td align="left" class="src coveredLine"><pre>    sid = ring_node_to_send->sid;</pre></td>
9540
    </tr>
9541

    
9542
    <tr>
9543
    <td align="right" class="lineno"><pre>1321</pre></td>
9544
    <td align="right" class="linebranch"></td>
9545
    <td align="right" class="linecount "><pre></pre></td>
9546
    <td align="left" class="src "><pre></pre></td>
9547
    </tr>
9548

    
9549
    <tr>
9550
    <td align="right" class="lineno"><pre>1322</pre></td>
9551
    <td align="right" class="linebranch"></td>
9552
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9553
    <td align="left" class="src coveredLine"><pre>    coarseTime  = ring_node_to_send->coarseTime;</pre></td>
9554
    </tr>
9555

    
9556
    <tr>
9557
    <td align="right" class="lineno"><pre>1323</pre></td>
9558
    <td align="right" class="linebranch"></td>
9559
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9560
    <td align="left" class="src coveredLine"><pre>    fineTime    = ring_node_to_send->fineTime;</pre></td>
9561
    </tr>
9562

    
9563
    <tr>
9564
    <td align="right" class="lineno"><pre>1324</pre></td>
9565
    <td align="right" class="linebranch"></td>
9566
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9567
    <td align="left" class="src coveredLine"><pre>    dataPtr     = (char*) ring_node_to_send->buffer_address;</pre></td>
9568
    </tr>
9569

    
9570
    <tr>
9571
    <td align="right" class="lineno"><pre>1325</pre></td>
9572
    <td align="right" class="linebranch"></td>
9573
    <td align="right" class="linecount "><pre></pre></td>
9574
    <td align="left" class="src "><pre></pre></td>
9575
    </tr>
9576

    
9577
    <tr>
9578
    <td align="right" class="lineno"><pre>1326</pre></td>
9579
    <td align="right" class="linebranch"></td>
9580
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9581
    <td align="left" class="src coveredLine"><pre>    header->packetLength[0] = (unsigned char) (TM_LEN_SCI_CWF_672 >> SHIFT_1_BYTE);</pre></td>
9582
    </tr>
9583

    
9584
    <tr>
9585
    <td align="right" class="lineno"><pre>1327</pre></td>
9586
    <td align="right" class="linebranch"></td>
9587
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9588
    <td align="left" class="src coveredLine"><pre>    header->packetLength[1] = (unsigned char) (TM_LEN_SCI_CWF_672     );</pre></td>
9589
    </tr>
9590

    
9591
    <tr>
9592
    <td align="right" class="lineno"><pre>1328</pre></td>
9593
    <td align="right" class="linebranch"></td>
9594
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9595
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info = pa_bia_status_info;</pre></td>
9596
    </tr>
9597

    
9598
    <tr>
9599
    <td align="right" class="lineno"><pre>1329</pre></td>
9600
    <td align="right" class="linebranch"></td>
9601
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9602
    <td align="left" class="src coveredLine"><pre>    header->sy_lfr_common_parameters = parameter_dump_packet.sy_lfr_common_parameters;</pre></td>
9603
    </tr>
9604

    
9605
    <tr>
9606
    <td align="right" class="lineno"><pre>1330</pre></td>
9607
    <td align="right" class="linebranch"></td>
9608
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9609
    <td align="left" class="src coveredLine"><pre>    header->blkNr[0] = (unsigned char) (BLK_NR_CWF_SHORT_F3 >> SHIFT_1_BYTE);</pre></td>
9610
    </tr>
9611

    
9612
    <tr>
9613
    <td align="right" class="lineno"><pre>1331</pre></td>
9614
    <td align="right" class="linebranch"></td>
9615
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9616
    <td align="left" class="src coveredLine"><pre>    header->blkNr[1] = (unsigned char) (BLK_NR_CWF_SHORT_F3     );</pre></td>
9617
    </tr>
9618

    
9619
    <tr>
9620
    <td align="right" class="lineno"><pre>1332</pre></td>
9621
    <td align="right" class="linebranch"></td>
9622
    <td align="right" class="linecount "><pre></pre></td>
9623
    <td align="left" class="src "><pre></pre></td>
9624
    </tr>
9625

    
9626
    <tr>
9627
    <td align="right" class="lineno"><pre>1333</pre></td>
9628
    <td align="right" class="linebranch"></td>
9629
    <td align="right" class="linecount "><pre></pre></td>
9630
    <td align="left" class="src "><pre>    //*********************</pre></td>
9631
    </tr>
9632

    
9633
    <tr>
9634
    <td align="right" class="lineno"><pre>1334</pre></td>
9635
    <td align="right" class="linebranch"></td>
9636
    <td align="right" class="linecount "><pre></pre></td>
9637
    <td align="left" class="src "><pre>    // SEND CWF3_light DATA</pre></td>
9638
    </tr>
9639

    
9640
    <tr>
9641
    <td align="right" class="lineno"><pre>1335</pre></td>
9642
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 1564 times">&check;</span><span class="takenBranch" title="Branch 1 taken 391 times">&check;</span></td>
9643
    <td align="right" class="linecount coveredLine"><pre>1955</pre></td>
9644
    <td align="left" class="src coveredLine"><pre>    for (i=0; i&lt;NB_PACKETS_PER_GROUP_OF_CWF_LIGHT; i++) // send waveform</pre></td>
9645
    </tr>
9646

    
9647
    <tr>
9648
    <td align="right" class="lineno"><pre>1336</pre></td>
9649
    <td align="right" class="linebranch"></td>
9650
    <td align="right" class="linecount "><pre></pre></td>
9651
    <td align="left" class="src "><pre>    {</pre></td>
9652
    </tr>
9653

    
9654
    <tr>
9655
    <td align="right" class="lineno"><pre>1337</pre></td>
9656
    <td align="right" class="linebranch"></td>
9657
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9658
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_CWF.data = (char*) &amp;dataPtr[ (i * BLK_NR_CWF_SHORT_F3 * NB_BYTES_CWF3_LIGHT_BLK) ];</pre></td>
9659
    </tr>
9660

    
9661
    <tr>
9662
    <td align="right" class="lineno"><pre>1338</pre></td>
9663
    <td align="right" class="linebranch"></td>
9664
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9665
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_CWF.hdr = (char*) header;</pre></td>
9666
    </tr>
9667

    
9668
    <tr>
9669
    <td align="right" class="lineno"><pre>1339</pre></td>
9670
    <td align="right" class="linebranch"></td>
9671
    <td align="right" class="linecount "><pre></pre></td>
9672
    <td align="left" class="src "><pre>        // BUILD THE DATA</pre></td>
9673
    </tr>
9674

    
9675
    <tr>
9676
    <td align="right" class="lineno"><pre>1340</pre></td>
9677
    <td align="right" class="linebranch"></td>
9678
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9679
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_CWF.dlen = BLK_NR_CWF_SHORT_F3 * NB_BYTES_CWF3_LIGHT_BLK;</pre></td>
9680
    </tr>
9681

    
9682
    <tr>
9683
    <td align="right" class="lineno"><pre>1341</pre></td>
9684
    <td align="right" class="linebranch"></td>
9685
    <td align="right" class="linecount "><pre></pre></td>
9686
    <td align="left" class="src "><pre></pre></td>
9687
    </tr>
9688

    
9689
    <tr>
9690
    <td align="right" class="lineno"><pre>1342</pre></td>
9691
    <td align="right" class="linebranch"></td>
9692
    <td align="right" class="linecount "><pre></pre></td>
9693
    <td align="left" class="src "><pre>        // SET PACKET SEQUENCE COUNTER</pre></td>
9694
    </tr>
9695

    
9696
    <tr>
9697
    <td align="right" class="lineno"><pre>1343</pre></td>
9698
    <td align="right" class="linebranch"></td>
9699
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9700
    <td align="left" class="src coveredLine"><pre>        increment_seq_counter_source_id( header->packetSequenceControl, sid );</pre></td>
9701
    </tr>
9702

    
9703
    <tr>
9704
    <td align="right" class="lineno"><pre>1344</pre></td>
9705
    <td align="right" class="linebranch"></td>
9706
    <td align="right" class="linecount "><pre></pre></td>
9707
    <td align="left" class="src "><pre></pre></td>
9708
    </tr>
9709

    
9710
    <tr>
9711
    <td align="right" class="lineno"><pre>1345</pre></td>
9712
    <td align="right" class="linebranch"></td>
9713
    <td align="right" class="linecount "><pre></pre></td>
9714
    <td align="left" class="src "><pre>        // SET SID</pre></td>
9715
    </tr>
9716

    
9717
    <tr>
9718
    <td align="right" class="lineno"><pre>1346</pre></td>
9719
    <td align="right" class="linebranch"></td>
9720
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9721
    <td align="left" class="src coveredLine"><pre>        header->sid = sid;</pre></td>
9722
    </tr>
9723

    
9724
    <tr>
9725
    <td align="right" class="lineno"><pre>1347</pre></td>
9726
    <td align="right" class="linebranch"></td>
9727
    <td align="right" class="linecount "><pre></pre></td>
9728
    <td align="left" class="src "><pre></pre></td>
9729
    </tr>
9730

    
9731
    <tr>
9732
    <td align="right" class="lineno"><pre>1348</pre></td>
9733
    <td align="right" class="linebranch"></td>
9734
    <td align="right" class="linecount "><pre></pre></td>
9735
    <td align="left" class="src "><pre>        // SET PACKET TIME</pre></td>
9736
    </tr>
9737

    
9738
    <tr>
9739
    <td align="right" class="lineno"><pre>1349</pre></td>
9740
    <td align="right" class="linebranch"></td>
9741
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9742
    <td align="left" class="src coveredLine"><pre>        compute_acquisition_time( coarseTime, fineTime, SID_NORM_CWF_F3, i, header->acquisitionTime );</pre></td>
9743
    </tr>
9744

    
9745
    <tr>
9746
    <td align="right" class="lineno"><pre>1350</pre></td>
9747
    <td align="right" class="linebranch"></td>
9748
    <td align="right" class="linecount "><pre></pre></td>
9749
    <td align="left" class="src "><pre>        //</pre></td>
9750
    </tr>
9751

    
9752
    <tr>
9753
    <td align="right" class="lineno"><pre>1351</pre></td>
9754
    <td align="right" class="linebranch"></td>
9755
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9756
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_0] = header->acquisitionTime[BYTE_0];</pre></td>
9757
    </tr>
9758

    
9759
    <tr>
9760
    <td align="right" class="lineno"><pre>1352</pre></td>
9761
    <td align="right" class="linebranch"></td>
9762
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9763
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_1] = header->acquisitionTime[BYTE_1];</pre></td>
9764
    </tr>
9765

    
9766
    <tr>
9767
    <td align="right" class="lineno"><pre>1353</pre></td>
9768
    <td align="right" class="linebranch"></td>
9769
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9770
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_2] = header->acquisitionTime[BYTE_2];</pre></td>
9771
    </tr>
9772

    
9773
    <tr>
9774
    <td align="right" class="lineno"><pre>1354</pre></td>
9775
    <td align="right" class="linebranch"></td>
9776
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9777
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_3] = header->acquisitionTime[BYTE_3];</pre></td>
9778
    </tr>
9779

    
9780
    <tr>
9781
    <td align="right" class="lineno"><pre>1355</pre></td>
9782
    <td align="right" class="linebranch"></td>
9783
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9784
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_4] = header->acquisitionTime[BYTE_4];</pre></td>
9785
    </tr>
9786

    
9787
    <tr>
9788
    <td align="right" class="lineno"><pre>1356</pre></td>
9789
    <td align="right" class="linebranch"></td>
9790
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9791
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_5] = header->acquisitionTime[BYTE_5];</pre></td>
9792
    </tr>
9793

    
9794
    <tr>
9795
    <td align="right" class="lineno"><pre>1357</pre></td>
9796
    <td align="right" class="linebranch"></td>
9797
    <td align="right" class="linecount "><pre></pre></td>
9798
    <td align="left" class="src "><pre></pre></td>
9799
    </tr>
9800

    
9801
    <tr>
9802
    <td align="right" class="lineno"><pre>1358</pre></td>
9803
    <td align="right" class="linebranch"></td>
9804
    <td align="right" class="linecount "><pre></pre></td>
9805
    <td align="left" class="src "><pre>        // SET PACKET ID</pre></td>
9806
    </tr>
9807

    
9808
    <tr>
9809
    <td align="right" class="lineno"><pre>1359</pre></td>
9810
    <td align="right" class="linebranch"></td>
9811
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9812
    <td align="left" class="src coveredLine"><pre>        header->packetID[0] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST >> SHIFT_1_BYTE);</pre></td>
9813
    </tr>
9814

    
9815
    <tr>
9816
    <td align="right" class="lineno"><pre>1360</pre></td>
9817
    <td align="right" class="linebranch"></td>
9818
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9819
    <td align="left" class="src coveredLine"><pre>        header->packetID[1] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST);</pre></td>
9820
    </tr>
9821

    
9822
    <tr>
9823
    <td align="right" class="lineno"><pre>1361</pre></td>
9824
    <td align="right" class="linebranch"></td>
9825
    <td align="right" class="linecount "><pre></pre></td>
9826
    <td align="left" class="src "><pre></pre></td>
9827
    </tr>
9828

    
9829
    <tr>
9830
    <td align="right" class="lineno"><pre>1362</pre></td>
9831
    <td align="right" class="linebranch"></td>
9832
    <td align="right" class="linecount "><pre></pre></td>
9833
    <td align="left" class="src "><pre>        // SEND PACKET</pre></td>
9834
    </tr>
9835

    
9836
    <tr>
9837
    <td align="right" class="lineno"><pre>1363</pre></td>
9838
    <td align="right" class="linebranch"></td>
9839
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9840
    <td align="left" class="src coveredLine"><pre>        status = ioctl( fdSPW, SPACEWIRE_IOCTRL_SEND, &amp;spw_ioctl_send_CWF );</pre></td>
9841
    </tr>
9842

    
9843
    <tr>
9844
    <td align="right" class="lineno"><pre>1364</pre></td>
9845
    <td align="right" class="linebranch"><span class="notTakenBranch" title="Branch 0 not taken">&cross;</span><span class="takenBranch" title="Branch 1 taken 1564 times">&check;</span></td>
9846
    <td align="right" class="linecount coveredLine"><pre>1564</pre></td>
9847
    <td align="left" class="src coveredLine"><pre>        if (status != RTEMS_SUCCESSFUL) {</pre></td>
9848
    </tr>
9849

    
9850
    <tr>
9851
    <td align="right" class="lineno"><pre>1365</pre></td>
9852
    <td align="right" class="linebranch"></td>
9853
    <td align="right" class="linecount uncoveredLine"><pre></pre></td>
9854
    <td align="left" class="src uncoveredLine"><pre>            ret = LFR_DEFAULT;</pre></td>
9855
    </tr>
9856

    
9857
    <tr>
9858
    <td align="right" class="lineno"><pre>1366</pre></td>
9859
    <td align="right" class="linebranch"></td>
9860
    <td align="right" class="linecount "><pre></pre></td>
9861
    <td align="left" class="src "><pre>        }</pre></td>
9862
    </tr>
9863

    
9864
    <tr>
9865
    <td align="right" class="lineno"><pre>1367</pre></td>
9866
    <td align="right" class="linebranch"></td>
9867
    <td align="right" class="linecount "><pre></pre></td>
9868
    <td align="left" class="src "><pre>    }</pre></td>
9869
    </tr>
9870

    
9871
    <tr>
9872
    <td align="right" class="lineno"><pre>1368</pre></td>
9873
    <td align="right" class="linebranch"></td>
9874
    <td align="right" class="linecount "><pre></pre></td>
9875
    <td align="left" class="src "><pre></pre></td>
9876
    </tr>
9877

    
9878
    <tr>
9879
    <td align="right" class="lineno"><pre>1369</pre></td>
9880
    <td align="right" class="linebranch"></td>
9881
    <td align="right" class="linecount coveredLine"><pre>391</pre></td>
9882
    <td align="left" class="src coveredLine"><pre>    return ret;</pre></td>
9883
    </tr>
9884

    
9885
    <tr>
9886
    <td align="right" class="lineno"><pre>1370</pre></td>
9887
    <td align="right" class="linebranch"></td>
9888
    <td align="right" class="linecount "><pre></pre></td>
9889
    <td align="left" class="src "><pre>}</pre></td>
9890
    </tr>
9891

    
9892
    <tr>
9893
    <td align="right" class="lineno"><pre>1371</pre></td>
9894
    <td align="right" class="linebranch"></td>
9895
    <td align="right" class="linecount "><pre></pre></td>
9896
    <td align="left" class="src "><pre></pre></td>
9897
    </tr>
9898

    
9899
    <tr>
9900
    <td align="right" class="lineno"><pre>1372</pre></td>
9901
    <td align="right" class="linebranch"></td>
9902
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
9903
    <td align="left" class="src coveredLine"><pre>void spw_send_asm_f0( ring_node *ring_node_to_send,</pre></td>
9904
    </tr>
9905

    
9906
    <tr>
9907
    <td align="right" class="lineno"><pre>1373</pre></td>
9908
    <td align="right" class="linebranch"></td>
9909
    <td align="right" class="linecount "><pre></pre></td>
9910
    <td align="left" class="src "><pre>                   Header_TM_LFR_SCIENCE_ASM_t *header )</pre></td>
9911
    </tr>
9912

    
9913
    <tr>
9914
    <td align="right" class="lineno"><pre>1374</pre></td>
9915
    <td align="right" class="linebranch"></td>
9916
    <td align="right" class="linecount "><pre></pre></td>
9917
    <td align="left" class="src "><pre>{</pre></td>
9918
    </tr>
9919

    
9920
    <tr>
9921
    <td align="right" class="lineno"><pre>1375</pre></td>
9922
    <td align="right" class="linebranch"></td>
9923
    <td align="right" class="linecount "><pre></pre></td>
9924
    <td align="left" class="src "><pre>    unsigned int i;</pre></td>
9925
    </tr>
9926

    
9927
    <tr>
9928
    <td align="right" class="lineno"><pre>1376</pre></td>
9929
    <td align="right" class="linebranch"></td>
9930
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
9931
    <td align="left" class="src coveredLine"><pre>    unsigned int length = 0;</pre></td>
9932
    </tr>
9933

    
9934
    <tr>
9935
    <td align="right" class="lineno"><pre>1377</pre></td>
9936
    <td align="right" class="linebranch"></td>
9937
    <td align="right" class="linecount "><pre></pre></td>
9938
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
9939
    </tr>
9940

    
9941
    <tr>
9942
    <td align="right" class="lineno"><pre>1378</pre></td>
9943
    <td align="right" class="linebranch"></td>
9944
    <td align="right" class="linecount "><pre></pre></td>
9945
    <td align="left" class="src "><pre>    unsigned int sid;</pre></td>
9946
    </tr>
9947

    
9948
    <tr>
9949
    <td align="right" class="lineno"><pre>1379</pre></td>
9950
    <td align="right" class="linebranch"></td>
9951
    <td align="right" class="linecount "><pre></pre></td>
9952
    <td align="left" class="src "><pre>    float *spectral_matrix;</pre></td>
9953
    </tr>
9954

    
9955
    <tr>
9956
    <td align="right" class="lineno"><pre>1380</pre></td>
9957
    <td align="right" class="linebranch"></td>
9958
    <td align="right" class="linecount "><pre></pre></td>
9959
    <td align="left" class="src "><pre>    int coarseTime;</pre></td>
9960
    </tr>
9961

    
9962
    <tr>
9963
    <td align="right" class="lineno"><pre>1381</pre></td>
9964
    <td align="right" class="linebranch"></td>
9965
    <td align="right" class="linecount "><pre></pre></td>
9966
    <td align="left" class="src "><pre>    int fineTime;</pre></td>
9967
    </tr>
9968

    
9969
    <tr>
9970
    <td align="right" class="lineno"><pre>1382</pre></td>
9971
    <td align="right" class="linebranch"></td>
9972
    <td align="right" class="linecount "><pre></pre></td>
9973
    <td align="left" class="src "><pre>    spw_ioctl_pkt_send spw_ioctl_send_ASM;</pre></td>
9974
    </tr>
9975

    
9976
    <tr>
9977
    <td align="right" class="lineno"><pre>1383</pre></td>
9978
    <td align="right" class="linebranch"></td>
9979
    <td align="right" class="linecount "><pre></pre></td>
9980
    <td align="left" class="src "><pre></pre></td>
9981
    </tr>
9982

    
9983
    <tr>
9984
    <td align="right" class="lineno"><pre>1384</pre></td>
9985
    <td align="right" class="linebranch"></td>
9986
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
9987
    <td align="left" class="src coveredLine"><pre>    sid = ring_node_to_send->sid;</pre></td>
9988
    </tr>
9989

    
9990
    <tr>
9991
    <td align="right" class="lineno"><pre>1385</pre></td>
9992
    <td align="right" class="linebranch"></td>
9993
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
9994
    <td align="left" class="src coveredLine"><pre>    spectral_matrix = (float*) ring_node_to_send->buffer_address;</pre></td>
9995
    </tr>
9996

    
9997
    <tr>
9998
    <td align="right" class="lineno"><pre>1386</pre></td>
9999
    <td align="right" class="linebranch"></td>
10000
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10001
    <td align="left" class="src coveredLine"><pre>    coarseTime = ring_node_to_send->coarseTime;</pre></td>
10002
    </tr>
10003

    
10004
    <tr>
10005
    <td align="right" class="lineno"><pre>1387</pre></td>
10006
    <td align="right" class="linebranch"></td>
10007
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10008
    <td align="left" class="src coveredLine"><pre>    fineTime = ring_node_to_send->fineTime;</pre></td>
10009
    </tr>
10010

    
10011
    <tr>
10012
    <td align="right" class="lineno"><pre>1388</pre></td>
10013
    <td align="right" class="linebranch"></td>
10014
    <td align="right" class="linecount "><pre></pre></td>
10015
    <td align="left" class="src "><pre></pre></td>
10016
    </tr>
10017

    
10018
    <tr>
10019
    <td align="right" class="lineno"><pre>1389</pre></td>
10020
    <td align="right" class="linebranch"></td>
10021
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10022
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info = pa_bia_status_info;</pre></td>
10023
    </tr>
10024

    
10025
    <tr>
10026
    <td align="right" class="lineno"><pre>1390</pre></td>
10027
    <td align="right" class="linebranch"></td>
10028
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10029
    <td align="left" class="src coveredLine"><pre>    header->sy_lfr_common_parameters = parameter_dump_packet.sy_lfr_common_parameters;</pre></td>
10030
    </tr>
10031

    
10032
    <tr>
10033
    <td align="right" class="lineno"><pre>1391</pre></td>
10034
    <td align="right" class="linebranch"></td>
10035
    <td align="right" class="linecount "><pre></pre></td>
10036
    <td align="left" class="src "><pre></pre></td>
10037
    </tr>
10038

    
10039
    <tr>
10040
    <td align="right" class="lineno"><pre>1392</pre></td>
10041
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 48342 times">&check;</span><span class="takenBranch" title="Branch 1 taken 16114 times">&check;</span></td>
10042
    <td align="right" class="linecount coveredLine"><pre>64456</pre></td>
10043
    <td align="left" class="src coveredLine"><pre>    for (i=0; i&lt;PKTCNT_ASM; i++)</pre></td>
10044
    </tr>
10045

    
10046
    <tr>
10047
    <td align="right" class="lineno"><pre>1393</pre></td>
10048
    <td align="right" class="linebranch"></td>
10049
    <td align="right" class="linecount "><pre></pre></td>
10050
    <td align="left" class="src "><pre>    {</pre></td>
10051
    </tr>
10052

    
10053
    <tr>
10054
    <td align="right" class="lineno"><pre>1394</pre></td>
10055
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 32228 times">&check;</span><span class="takenBranch" title="Branch 1 taken 16114 times">&check;</span></td>
10056
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10057
    <td align="left" class="src coveredLine"><pre>        if ((i==0) || (i==1))</pre></td>
10058
    </tr>
10059

    
10060
    <tr>
10061
    <td align="right" class="lineno"><pre>1395</pre></td>
10062
    <td align="right" class="linebranch"></td>
10063
    <td align="right" class="linecount "><pre></pre></td>
10064
    <td align="left" class="src "><pre>        {</pre></td>
10065
    </tr>
10066

    
10067
    <tr>
10068
    <td align="right" class="lineno"><pre>1396</pre></td>
10069
    <td align="right" class="linebranch"></td>
10070
    <td align="right" class="linecount coveredLine"><pre>32228</pre></td>
10071
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_ASM.dlen = DLEN_ASM_F0_PKT_1;</pre></td>
10072
    </tr>
10073

    
10074
    <tr>
10075
    <td align="right" class="lineno"><pre>1397</pre></td>
10076
    <td align="right" class="linebranch"></td>
10077
    <td align="right" class="linecount coveredLine"><pre>32228</pre></td>
10078
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_ASM.data = (char *) &amp;spectral_matrix[</pre></td>
10079
    </tr>
10080

    
10081
    <tr>
10082
    <td align="right" class="lineno"><pre>1398</pre></td>
10083
    <td align="right" class="linebranch"></td>
10084
    <td align="right" class="linecount "><pre></pre></td>
10085
    <td align="left" class="src "><pre>                    ( (ASM_F0_INDICE_START + (i*NB_BINS_PER_PKT_ASM_F0_1) ) * NB_VALUES_PER_SM )</pre></td>
10086
    </tr>
10087

    
10088
    <tr>
10089
    <td align="right" class="lineno"><pre>1399</pre></td>
10090
    <td align="right" class="linebranch"></td>
10091
    <td align="right" class="linecount coveredLine"><pre>32228</pre></td>
10092
    <td align="left" class="src coveredLine"><pre>                    ];</pre></td>
10093
    </tr>
10094

    
10095
    <tr>
10096
    <td align="right" class="lineno"><pre>1400</pre></td>
10097
    <td align="right" class="linebranch"></td>
10098
    <td align="right" class="linecount coveredLine"><pre>32228</pre></td>
10099
    <td align="left" class="src coveredLine"><pre>            length = PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F0_1;</pre></td>
10100
    </tr>
10101

    
10102
    <tr>
10103
    <td align="right" class="lineno"><pre>1401</pre></td>
10104
    <td align="right" class="linebranch"></td>
10105
    <td align="right" class="linecount coveredLine"><pre>32228</pre></td>
10106
    <td align="left" class="src coveredLine"><pre>            header->serviceSubType = TM_SUBTYPE_LFR_SCIENCE_6;</pre></td>
10107
    </tr>
10108

    
10109
    <tr>
10110
    <td align="right" class="lineno"><pre>1402</pre></td>
10111
    <td align="right" class="linebranch"></td>
10112
    <td align="right" class="linecount coveredLine"><pre>32228</pre></td>
10113
    <td align="left" class="src coveredLine"><pre>            header->pa_lfr_asm_blk_nr[0] = (unsigned char)  ( (NB_BINS_PER_PKT_ASM_F0_1) >> SHIFT_1_BYTE ); // BLK_NR MSB</pre></td>
10114
    </tr>
10115

    
10116
    <tr>
10117
    <td align="right" class="lineno"><pre>1403</pre></td>
10118
    <td align="right" class="linebranch"></td>
10119
    <td align="right" class="linecount coveredLine"><pre>32228</pre></td>
10120
    <td align="left" class="src coveredLine"><pre>            header->pa_lfr_asm_blk_nr[1] = (unsigned char)    (NB_BINS_PER_PKT_ASM_F0_1);        // BLK_NR LSB</pre></td>
10121
    </tr>
10122

    
10123
    <tr>
10124
    <td align="right" class="lineno"><pre>1404</pre></td>
10125
    <td align="right" class="linebranch"></td>
10126
    <td align="right" class="linecount "><pre></pre></td>
10127
    <td align="left" class="src "><pre>        }</pre></td>
10128
    </tr>
10129

    
10130
    <tr>
10131
    <td align="right" class="lineno"><pre>1405</pre></td>
10132
    <td align="right" class="linebranch"></td>
10133
    <td align="right" class="linecount "><pre></pre></td>
10134
    <td align="left" class="src "><pre>        else</pre></td>
10135
    </tr>
10136

    
10137
    <tr>
10138
    <td align="right" class="lineno"><pre>1406</pre></td>
10139
    <td align="right" class="linebranch"></td>
10140
    <td align="right" class="linecount "><pre></pre></td>
10141
    <td align="left" class="src "><pre>        {</pre></td>
10142
    </tr>
10143

    
10144
    <tr>
10145
    <td align="right" class="lineno"><pre>1407</pre></td>
10146
    <td align="right" class="linebranch"></td>
10147
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10148
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_ASM.dlen = DLEN_ASM_F0_PKT_2;</pre></td>
10149
    </tr>
10150

    
10151
    <tr>
10152
    <td align="right" class="lineno"><pre>1408</pre></td>
10153
    <td align="right" class="linebranch"></td>
10154
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10155
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_ASM.data = (char*) &amp;spectral_matrix[</pre></td>
10156
    </tr>
10157

    
10158
    <tr>
10159
    <td align="right" class="lineno"><pre>1409</pre></td>
10160
    <td align="right" class="linebranch"></td>
10161
    <td align="right" class="linecount "><pre></pre></td>
10162
    <td align="left" class="src "><pre>                    ( (ASM_F0_INDICE_START + (i*NB_BINS_PER_PKT_ASM_F0_1) ) * NB_VALUES_PER_SM )</pre></td>
10163
    </tr>
10164

    
10165
    <tr>
10166
    <td align="right" class="lineno"><pre>1410</pre></td>
10167
    <td align="right" class="linebranch"></td>
10168
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10169
    <td align="left" class="src coveredLine"><pre>                    ];</pre></td>
10170
    </tr>
10171

    
10172
    <tr>
10173
    <td align="right" class="lineno"><pre>1411</pre></td>
10174
    <td align="right" class="linebranch"></td>
10175
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10176
    <td align="left" class="src coveredLine"><pre>            length = PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F0_2;</pre></td>
10177
    </tr>
10178

    
10179
    <tr>
10180
    <td align="right" class="lineno"><pre>1412</pre></td>
10181
    <td align="right" class="linebranch"></td>
10182
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10183
    <td align="left" class="src coveredLine"><pre>            header->serviceSubType = TM_SUBTYPE_LFR_SCIENCE_6;</pre></td>
10184
    </tr>
10185

    
10186
    <tr>
10187
    <td align="right" class="lineno"><pre>1413</pre></td>
10188
    <td align="right" class="linebranch"></td>
10189
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10190
    <td align="left" class="src coveredLine"><pre>            header->pa_lfr_asm_blk_nr[0] = (unsigned char)  ( (NB_BINS_PER_PKT_ASM_F0_2) >> SHIFT_1_BYTE ); // BLK_NR MSB</pre></td>
10191
    </tr>
10192

    
10193
    <tr>
10194
    <td align="right" class="lineno"><pre>1414</pre></td>
10195
    <td align="right" class="linebranch"></td>
10196
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10197
    <td align="left" class="src coveredLine"><pre>            header->pa_lfr_asm_blk_nr[1] = (unsigned char)    (NB_BINS_PER_PKT_ASM_F0_2);        // BLK_NR LSB</pre></td>
10198
    </tr>
10199

    
10200
    <tr>
10201
    <td align="right" class="lineno"><pre>1415</pre></td>
10202
    <td align="right" class="linebranch"></td>
10203
    <td align="right" class="linecount "><pre></pre></td>
10204
    <td align="left" class="src "><pre>        }</pre></td>
10205
    </tr>
10206

    
10207
    <tr>
10208
    <td align="right" class="lineno"><pre>1416</pre></td>
10209
    <td align="right" class="linebranch"></td>
10210
    <td align="right" class="linecount "><pre></pre></td>
10211
    <td align="left" class="src "><pre></pre></td>
10212
    </tr>
10213

    
10214
    <tr>
10215
    <td align="right" class="lineno"><pre>1417</pre></td>
10216
    <td align="right" class="linebranch"></td>
10217
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10218
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.hlen = HEADER_LENGTH_TM_LFR_SCIENCE_ASM;</pre></td>
10219
    </tr>
10220

    
10221
    <tr>
10222
    <td align="right" class="lineno"><pre>1418</pre></td>
10223
    <td align="right" class="linebranch"></td>
10224
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10225
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.hdr = (char *) header;</pre></td>
10226
    </tr>
10227

    
10228
    <tr>
10229
    <td align="right" class="lineno"><pre>1419</pre></td>
10230
    <td align="right" class="linebranch"></td>
10231
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10232
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.options = 0;</pre></td>
10233
    </tr>
10234

    
10235
    <tr>
10236
    <td align="right" class="lineno"><pre>1420</pre></td>
10237
    <td align="right" class="linebranch"></td>
10238
    <td align="right" class="linecount "><pre></pre></td>
10239
    <td align="left" class="src "><pre></pre></td>
10240
    </tr>
10241

    
10242
    <tr>
10243
    <td align="right" class="lineno"><pre>1421</pre></td>
10244
    <td align="right" class="linebranch"></td>
10245
    <td align="right" class="linecount "><pre></pre></td>
10246
    <td align="left" class="src "><pre>        // (2) BUILD THE HEADER</pre></td>
10247
    </tr>
10248

    
10249
    <tr>
10250
    <td align="right" class="lineno"><pre>1422</pre></td>
10251
    <td align="right" class="linebranch"></td>
10252
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10253
    <td align="left" class="src coveredLine"><pre>        increment_seq_counter_source_id( header->packetSequenceControl, sid );</pre></td>
10254
    </tr>
10255

    
10256
    <tr>
10257
    <td align="right" class="lineno"><pre>1423</pre></td>
10258
    <td align="right" class="linebranch"></td>
10259
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10260
    <td align="left" class="src coveredLine"><pre>        header->packetLength[0] = (unsigned char) (length >> SHIFT_1_BYTE);</pre></td>
10261
    </tr>
10262

    
10263
    <tr>
10264
    <td align="right" class="lineno"><pre>1424</pre></td>
10265
    <td align="right" class="linebranch"></td>
10266
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10267
    <td align="left" class="src coveredLine"><pre>        header->packetLength[1] = (unsigned char) (length);</pre></td>
10268
    </tr>
10269

    
10270
    <tr>
10271
    <td align="right" class="lineno"><pre>1425</pre></td>
10272
    <td align="right" class="linebranch"></td>
10273
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10274
    <td align="left" class="src coveredLine"><pre>        header->sid = (unsigned char) sid;   // SID</pre></td>
10275
    </tr>
10276

    
10277
    <tr>
10278
    <td align="right" class="lineno"><pre>1426</pre></td>
10279
    <td align="right" class="linebranch"></td>
10280
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10281
    <td align="left" class="src coveredLine"><pre>        header->pa_lfr_pkt_cnt_asm = PKTCNT_ASM;</pre></td>
10282
    </tr>
10283

    
10284
    <tr>
10285
    <td align="right" class="lineno"><pre>1427</pre></td>
10286
    <td align="right" class="linebranch"></td>
10287
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10288
    <td align="left" class="src coveredLine"><pre>        header->pa_lfr_pkt_nr_asm = (unsigned char) (i+1);</pre></td>
10289
    </tr>
10290

    
10291
    <tr>
10292
    <td align="right" class="lineno"><pre>1428</pre></td>
10293
    <td align="right" class="linebranch"></td>
10294
    <td align="right" class="linecount "><pre></pre></td>
10295
    <td align="left" class="src "><pre></pre></td>
10296
    </tr>
10297

    
10298
    <tr>
10299
    <td align="right" class="lineno"><pre>1429</pre></td>
10300
    <td align="right" class="linebranch"></td>
10301
    <td align="right" class="linecount "><pre></pre></td>
10302
    <td align="left" class="src "><pre>        // (3) SET PACKET TIME</pre></td>
10303
    </tr>
10304

    
10305
    <tr>
10306
    <td align="right" class="lineno"><pre>1430</pre></td>
10307
    <td align="right" class="linebranch"></td>
10308
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10309
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_0] = (unsigned char) (coarseTime >> SHIFT_3_BYTES);</pre></td>
10310
    </tr>
10311

    
10312
    <tr>
10313
    <td align="right" class="lineno"><pre>1431</pre></td>
10314
    <td align="right" class="linebranch"></td>
10315
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10316
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_1] = (unsigned char) (coarseTime >> SHIFT_2_BYTES);</pre></td>
10317
    </tr>
10318

    
10319
    <tr>
10320
    <td align="right" class="lineno"><pre>1432</pre></td>
10321
    <td align="right" class="linebranch"></td>
10322
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10323
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_2] = (unsigned char) (coarseTime >> SHIFT_1_BYTE);</pre></td>
10324
    </tr>
10325

    
10326
    <tr>
10327
    <td align="right" class="lineno"><pre>1433</pre></td>
10328
    <td align="right" class="linebranch"></td>
10329
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10330
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_3] = (unsigned char) (coarseTime);</pre></td>
10331
    </tr>
10332

    
10333
    <tr>
10334
    <td align="right" class="lineno"><pre>1434</pre></td>
10335
    <td align="right" class="linebranch"></td>
10336
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10337
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_4] = (unsigned char) (fineTime >> SHIFT_1_BYTE);</pre></td>
10338
    </tr>
10339

    
10340
    <tr>
10341
    <td align="right" class="lineno"><pre>1435</pre></td>
10342
    <td align="right" class="linebranch"></td>
10343
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10344
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_5] = (unsigned char) (fineTime);</pre></td>
10345
    </tr>
10346

    
10347
    <tr>
10348
    <td align="right" class="lineno"><pre>1436</pre></td>
10349
    <td align="right" class="linebranch"></td>
10350
    <td align="right" class="linecount "><pre></pre></td>
10351
    <td align="left" class="src "><pre>        //</pre></td>
10352
    </tr>
10353

    
10354
    <tr>
10355
    <td align="right" class="lineno"><pre>1437</pre></td>
10356
    <td align="right" class="linebranch"></td>
10357
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10358
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_0] = header->time[BYTE_0];</pre></td>
10359
    </tr>
10360

    
10361
    <tr>
10362
    <td align="right" class="lineno"><pre>1438</pre></td>
10363
    <td align="right" class="linebranch"></td>
10364
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10365
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_1] = header->time[BYTE_1];</pre></td>
10366
    </tr>
10367

    
10368
    <tr>
10369
    <td align="right" class="lineno"><pre>1439</pre></td>
10370
    <td align="right" class="linebranch"></td>
10371
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10372
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_2] = header->time[BYTE_2];</pre></td>
10373
    </tr>
10374

    
10375
    <tr>
10376
    <td align="right" class="lineno"><pre>1440</pre></td>
10377
    <td align="right" class="linebranch"></td>
10378
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10379
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_3] = header->time[BYTE_3];</pre></td>
10380
    </tr>
10381

    
10382
    <tr>
10383
    <td align="right" class="lineno"><pre>1441</pre></td>
10384
    <td align="right" class="linebranch"></td>
10385
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10386
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_4] = header->time[BYTE_4];</pre></td>
10387
    </tr>
10388

    
10389
    <tr>
10390
    <td align="right" class="lineno"><pre>1442</pre></td>
10391
    <td align="right" class="linebranch"></td>
10392
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10393
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_5] = header->time[BYTE_5];</pre></td>
10394
    </tr>
10395

    
10396
    <tr>
10397
    <td align="right" class="lineno"><pre>1443</pre></td>
10398
    <td align="right" class="linebranch"></td>
10399
    <td align="right" class="linecount "><pre></pre></td>
10400
    <td align="left" class="src "><pre></pre></td>
10401
    </tr>
10402

    
10403
    <tr>
10404
    <td align="right" class="lineno"><pre>1444</pre></td>
10405
    <td align="right" class="linebranch"></td>
10406
    <td align="right" class="linecount "><pre></pre></td>
10407
    <td align="left" class="src "><pre>        // (4) SEND PACKET</pre></td>
10408
    </tr>
10409

    
10410
    <tr>
10411
    <td align="right" class="lineno"><pre>1445</pre></td>
10412
    <td align="right" class="linebranch"></td>
10413
    <td align="right" class="linecount coveredLine"><pre>48342</pre></td>
10414
    <td align="left" class="src coveredLine"><pre>        status = ioctl( fdSPW, SPACEWIRE_IOCTRL_SEND, &amp;spw_ioctl_send_ASM );</pre></td>
10415
    </tr>
10416

    
10417
    <tr>
10418
    <td align="right" class="lineno"><pre>1446</pre></td>
10419
    <td align="right" class="linebranch"></td>
10420
    <td align="right" class="linecount "><pre></pre></td>
10421
    <td align="left" class="src "><pre>        if (status != RTEMS_SUCCESSFUL) {</pre></td>
10422
    </tr>
10423

    
10424
    <tr>
10425
    <td align="right" class="lineno"><pre>1447</pre></td>
10426
    <td align="right" class="linebranch"></td>
10427
    <td align="right" class="linecount "><pre></pre></td>
10428
    <td align="left" class="src "><pre>            PRINTF1("in ASM_send *** ERR %d\n", (int) status)</pre></td>
10429
    </tr>
10430

    
10431
    <tr>
10432
    <td align="right" class="lineno"><pre>1448</pre></td>
10433
    <td align="right" class="linebranch"></td>
10434
    <td align="right" class="linecount "><pre></pre></td>
10435
    <td align="left" class="src "><pre>        }</pre></td>
10436
    </tr>
10437

    
10438
    <tr>
10439
    <td align="right" class="lineno"><pre>1449</pre></td>
10440
    <td align="right" class="linebranch"></td>
10441
    <td align="right" class="linecount "><pre></pre></td>
10442
    <td align="left" class="src "><pre>    }</pre></td>
10443
    </tr>
10444

    
10445
    <tr>
10446
    <td align="right" class="lineno"><pre>1450</pre></td>
10447
    <td align="right" class="linebranch"></td>
10448
    <td align="right" class="linecount coveredLine"><pre>16114</pre></td>
10449
    <td align="left" class="src coveredLine"><pre>}</pre></td>
10450
    </tr>
10451

    
10452
    <tr>
10453
    <td align="right" class="lineno"><pre>1451</pre></td>
10454
    <td align="right" class="linebranch"></td>
10455
    <td align="right" class="linecount "><pre></pre></td>
10456
    <td align="left" class="src "><pre></pre></td>
10457
    </tr>
10458

    
10459
    <tr>
10460
    <td align="right" class="lineno"><pre>1452</pre></td>
10461
    <td align="right" class="linebranch"></td>
10462
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10463
    <td align="left" class="src coveredLine"><pre>void spw_send_asm_f1( ring_node *ring_node_to_send,</pre></td>
10464
    </tr>
10465

    
10466
    <tr>
10467
    <td align="right" class="lineno"><pre>1453</pre></td>
10468
    <td align="right" class="linebranch"></td>
10469
    <td align="right" class="linecount "><pre></pre></td>
10470
    <td align="left" class="src "><pre>                   Header_TM_LFR_SCIENCE_ASM_t *header )</pre></td>
10471
    </tr>
10472

    
10473
    <tr>
10474
    <td align="right" class="lineno"><pre>1454</pre></td>
10475
    <td align="right" class="linebranch"></td>
10476
    <td align="right" class="linecount "><pre></pre></td>
10477
    <td align="left" class="src "><pre>{</pre></td>
10478
    </tr>
10479

    
10480
    <tr>
10481
    <td align="right" class="lineno"><pre>1455</pre></td>
10482
    <td align="right" class="linebranch"></td>
10483
    <td align="right" class="linecount "><pre></pre></td>
10484
    <td align="left" class="src "><pre>    unsigned int i;</pre></td>
10485
    </tr>
10486

    
10487
    <tr>
10488
    <td align="right" class="lineno"><pre>1456</pre></td>
10489
    <td align="right" class="linebranch"></td>
10490
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10491
    <td align="left" class="src coveredLine"><pre>    unsigned int length = 0;</pre></td>
10492
    </tr>
10493

    
10494
    <tr>
10495
    <td align="right" class="lineno"><pre>1457</pre></td>
10496
    <td align="right" class="linebranch"></td>
10497
    <td align="right" class="linecount "><pre></pre></td>
10498
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
10499
    </tr>
10500

    
10501
    <tr>
10502
    <td align="right" class="lineno"><pre>1458</pre></td>
10503
    <td align="right" class="linebranch"></td>
10504
    <td align="right" class="linecount "><pre></pre></td>
10505
    <td align="left" class="src "><pre>    unsigned int sid;</pre></td>
10506
    </tr>
10507

    
10508
    <tr>
10509
    <td align="right" class="lineno"><pre>1459</pre></td>
10510
    <td align="right" class="linebranch"></td>
10511
    <td align="right" class="linecount "><pre></pre></td>
10512
    <td align="left" class="src "><pre>    float *spectral_matrix;</pre></td>
10513
    </tr>
10514

    
10515
    <tr>
10516
    <td align="right" class="lineno"><pre>1460</pre></td>
10517
    <td align="right" class="linebranch"></td>
10518
    <td align="right" class="linecount "><pre></pre></td>
10519
    <td align="left" class="src "><pre>    int coarseTime;</pre></td>
10520
    </tr>
10521

    
10522
    <tr>
10523
    <td align="right" class="lineno"><pre>1461</pre></td>
10524
    <td align="right" class="linebranch"></td>
10525
    <td align="right" class="linecount "><pre></pre></td>
10526
    <td align="left" class="src "><pre>    int fineTime;</pre></td>
10527
    </tr>
10528

    
10529
    <tr>
10530
    <td align="right" class="lineno"><pre>1462</pre></td>
10531
    <td align="right" class="linebranch"></td>
10532
    <td align="right" class="linecount "><pre></pre></td>
10533
    <td align="left" class="src "><pre>    spw_ioctl_pkt_send spw_ioctl_send_ASM;</pre></td>
10534
    </tr>
10535

    
10536
    <tr>
10537
    <td align="right" class="lineno"><pre>1463</pre></td>
10538
    <td align="right" class="linebranch"></td>
10539
    <td align="right" class="linecount "><pre></pre></td>
10540
    <td align="left" class="src "><pre></pre></td>
10541
    </tr>
10542

    
10543
    <tr>
10544
    <td align="right" class="lineno"><pre>1464</pre></td>
10545
    <td align="right" class="linebranch"></td>
10546
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10547
    <td align="left" class="src coveredLine"><pre>    sid = ring_node_to_send->sid;</pre></td>
10548
    </tr>
10549

    
10550
    <tr>
10551
    <td align="right" class="lineno"><pre>1465</pre></td>
10552
    <td align="right" class="linebranch"></td>
10553
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10554
    <td align="left" class="src coveredLine"><pre>    spectral_matrix = (float*) ring_node_to_send->buffer_address;</pre></td>
10555
    </tr>
10556

    
10557
    <tr>
10558
    <td align="right" class="lineno"><pre>1466</pre></td>
10559
    <td align="right" class="linebranch"></td>
10560
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10561
    <td align="left" class="src coveredLine"><pre>    coarseTime = ring_node_to_send->coarseTime;</pre></td>
10562
    </tr>
10563

    
10564
    <tr>
10565
    <td align="right" class="lineno"><pre>1467</pre></td>
10566
    <td align="right" class="linebranch"></td>
10567
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10568
    <td align="left" class="src coveredLine"><pre>    fineTime = ring_node_to_send->fineTime;</pre></td>
10569
    </tr>
10570

    
10571
    <tr>
10572
    <td align="right" class="lineno"><pre>1468</pre></td>
10573
    <td align="right" class="linebranch"></td>
10574
    <td align="right" class="linecount "><pre></pre></td>
10575
    <td align="left" class="src "><pre></pre></td>
10576
    </tr>
10577

    
10578
    <tr>
10579
    <td align="right" class="lineno"><pre>1469</pre></td>
10580
    <td align="right" class="linebranch"></td>
10581
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10582
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info = pa_bia_status_info;</pre></td>
10583
    </tr>
10584

    
10585
    <tr>
10586
    <td align="right" class="lineno"><pre>1470</pre></td>
10587
    <td align="right" class="linebranch"></td>
10588
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10589
    <td align="left" class="src coveredLine"><pre>    header->sy_lfr_common_parameters = parameter_dump_packet.sy_lfr_common_parameters;</pre></td>
10590
    </tr>
10591

    
10592
    <tr>
10593
    <td align="right" class="lineno"><pre>1471</pre></td>
10594
    <td align="right" class="linebranch"></td>
10595
    <td align="right" class="linecount "><pre></pre></td>
10596
    <td align="left" class="src "><pre></pre></td>
10597
    </tr>
10598

    
10599
    <tr>
10600
    <td align="right" class="lineno"><pre>1472</pre></td>
10601
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 48336 times">&check;</span><span class="takenBranch" title="Branch 1 taken 16112 times">&check;</span></td>
10602
    <td align="right" class="linecount coveredLine"><pre>64448</pre></td>
10603
    <td align="left" class="src coveredLine"><pre>    for (i=0; i&lt;PKTCNT_ASM; i++)</pre></td>
10604
    </tr>
10605

    
10606
    <tr>
10607
    <td align="right" class="lineno"><pre>1473</pre></td>
10608
    <td align="right" class="linebranch"></td>
10609
    <td align="right" class="linecount "><pre></pre></td>
10610
    <td align="left" class="src "><pre>    {</pre></td>
10611
    </tr>
10612

    
10613
    <tr>
10614
    <td align="right" class="lineno"><pre>1474</pre></td>
10615
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 32224 times">&check;</span><span class="takenBranch" title="Branch 1 taken 16112 times">&check;</span></td>
10616
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10617
    <td align="left" class="src coveredLine"><pre>        if ((i==0) || (i==1))</pre></td>
10618
    </tr>
10619

    
10620
    <tr>
10621
    <td align="right" class="lineno"><pre>1475</pre></td>
10622
    <td align="right" class="linebranch"></td>
10623
    <td align="right" class="linecount "><pre></pre></td>
10624
    <td align="left" class="src "><pre>        {</pre></td>
10625
    </tr>
10626

    
10627
    <tr>
10628
    <td align="right" class="lineno"><pre>1476</pre></td>
10629
    <td align="right" class="linebranch"></td>
10630
    <td align="right" class="linecount coveredLine"><pre>32224</pre></td>
10631
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_ASM.dlen = DLEN_ASM_F1_PKT_1;</pre></td>
10632
    </tr>
10633

    
10634
    <tr>
10635
    <td align="right" class="lineno"><pre>1477</pre></td>
10636
    <td align="right" class="linebranch"></td>
10637
    <td align="right" class="linecount coveredLine"><pre>32224</pre></td>
10638
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_ASM.data = (char *) &amp;spectral_matrix[</pre></td>
10639
    </tr>
10640

    
10641
    <tr>
10642
    <td align="right" class="lineno"><pre>1478</pre></td>
10643
    <td align="right" class="linebranch"></td>
10644
    <td align="right" class="linecount "><pre></pre></td>
10645
    <td align="left" class="src "><pre>                    ( (ASM_F1_INDICE_START + (i*NB_BINS_PER_PKT_ASM_F1_1) ) * NB_VALUES_PER_SM )</pre></td>
10646
    </tr>
10647

    
10648
    <tr>
10649
    <td align="right" class="lineno"><pre>1479</pre></td>
10650
    <td align="right" class="linebranch"></td>
10651
    <td align="right" class="linecount coveredLine"><pre>32224</pre></td>
10652
    <td align="left" class="src coveredLine"><pre>                    ];</pre></td>
10653
    </tr>
10654

    
10655
    <tr>
10656
    <td align="right" class="lineno"><pre>1480</pre></td>
10657
    <td align="right" class="linebranch"></td>
10658
    <td align="right" class="linecount coveredLine"><pre>32224</pre></td>
10659
    <td align="left" class="src coveredLine"><pre>            length = PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F1_1;</pre></td>
10660
    </tr>
10661

    
10662
    <tr>
10663
    <td align="right" class="lineno"><pre>1481</pre></td>
10664
    <td align="right" class="linebranch"></td>
10665
    <td align="right" class="linecount coveredLine"><pre>32224</pre></td>
10666
    <td align="left" class="src coveredLine"><pre>            header->serviceSubType = TM_SUBTYPE_LFR_SCIENCE_6;</pre></td>
10667
    </tr>
10668

    
10669
    <tr>
10670
    <td align="right" class="lineno"><pre>1482</pre></td>
10671
    <td align="right" class="linebranch"></td>
10672
    <td align="right" class="linecount coveredLine"><pre>32224</pre></td>
10673
    <td align="left" class="src coveredLine"><pre>            header->pa_lfr_asm_blk_nr[0] = (unsigned char)  ( (NB_BINS_PER_PKT_ASM_F1_1) >> SHIFT_1_BYTE ); // BLK_NR MSB</pre></td>
10674
    </tr>
10675

    
10676
    <tr>
10677
    <td align="right" class="lineno"><pre>1483</pre></td>
10678
    <td align="right" class="linebranch"></td>
10679
    <td align="right" class="linecount coveredLine"><pre>32224</pre></td>
10680
    <td align="left" class="src coveredLine"><pre>            header->pa_lfr_asm_blk_nr[1] = (unsigned char)    (NB_BINS_PER_PKT_ASM_F1_1);        // BLK_NR LSB</pre></td>
10681
    </tr>
10682

    
10683
    <tr>
10684
    <td align="right" class="lineno"><pre>1484</pre></td>
10685
    <td align="right" class="linebranch"></td>
10686
    <td align="right" class="linecount "><pre></pre></td>
10687
    <td align="left" class="src "><pre>        }</pre></td>
10688
    </tr>
10689

    
10690
    <tr>
10691
    <td align="right" class="lineno"><pre>1485</pre></td>
10692
    <td align="right" class="linebranch"></td>
10693
    <td align="right" class="linecount "><pre></pre></td>
10694
    <td align="left" class="src "><pre>        else</pre></td>
10695
    </tr>
10696

    
10697
    <tr>
10698
    <td align="right" class="lineno"><pre>1486</pre></td>
10699
    <td align="right" class="linebranch"></td>
10700
    <td align="right" class="linecount "><pre></pre></td>
10701
    <td align="left" class="src "><pre>        {</pre></td>
10702
    </tr>
10703

    
10704
    <tr>
10705
    <td align="right" class="lineno"><pre>1487</pre></td>
10706
    <td align="right" class="linebranch"></td>
10707
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10708
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_ASM.dlen = DLEN_ASM_F1_PKT_2;</pre></td>
10709
    </tr>
10710

    
10711
    <tr>
10712
    <td align="right" class="lineno"><pre>1488</pre></td>
10713
    <td align="right" class="linebranch"></td>
10714
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10715
    <td align="left" class="src coveredLine"><pre>            spw_ioctl_send_ASM.data = (char*) &amp;spectral_matrix[</pre></td>
10716
    </tr>
10717

    
10718
    <tr>
10719
    <td align="right" class="lineno"><pre>1489</pre></td>
10720
    <td align="right" class="linebranch"></td>
10721
    <td align="right" class="linecount "><pre></pre></td>
10722
    <td align="left" class="src "><pre>                    ( (ASM_F1_INDICE_START + (i*NB_BINS_PER_PKT_ASM_F1_1) ) * NB_VALUES_PER_SM )</pre></td>
10723
    </tr>
10724

    
10725
    <tr>
10726
    <td align="right" class="lineno"><pre>1490</pre></td>
10727
    <td align="right" class="linebranch"></td>
10728
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10729
    <td align="left" class="src coveredLine"><pre>                    ];</pre></td>
10730
    </tr>
10731

    
10732
    <tr>
10733
    <td align="right" class="lineno"><pre>1491</pre></td>
10734
    <td align="right" class="linebranch"></td>
10735
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10736
    <td align="left" class="src coveredLine"><pre>            length = PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F1_2;</pre></td>
10737
    </tr>
10738

    
10739
    <tr>
10740
    <td align="right" class="lineno"><pre>1492</pre></td>
10741
    <td align="right" class="linebranch"></td>
10742
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10743
    <td align="left" class="src coveredLine"><pre>            header->serviceSubType = TM_SUBTYPE_LFR_SCIENCE_6;</pre></td>
10744
    </tr>
10745

    
10746
    <tr>
10747
    <td align="right" class="lineno"><pre>1493</pre></td>
10748
    <td align="right" class="linebranch"></td>
10749
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10750
    <td align="left" class="src coveredLine"><pre>            header->pa_lfr_asm_blk_nr[0] = (unsigned char)  ( (NB_BINS_PER_PKT_ASM_F1_2) >> SHIFT_1_BYTE ); // BLK_NR MSB</pre></td>
10751
    </tr>
10752

    
10753
    <tr>
10754
    <td align="right" class="lineno"><pre>1494</pre></td>
10755
    <td align="right" class="linebranch"></td>
10756
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
10757
    <td align="left" class="src coveredLine"><pre>            header->pa_lfr_asm_blk_nr[1] = (unsigned char)    (NB_BINS_PER_PKT_ASM_F1_2);        // BLK_NR LSB</pre></td>
10758
    </tr>
10759

    
10760
    <tr>
10761
    <td align="right" class="lineno"><pre>1495</pre></td>
10762
    <td align="right" class="linebranch"></td>
10763
    <td align="right" class="linecount "><pre></pre></td>
10764
    <td align="left" class="src "><pre>        }</pre></td>
10765
    </tr>
10766

    
10767
    <tr>
10768
    <td align="right" class="lineno"><pre>1496</pre></td>
10769
    <td align="right" class="linebranch"></td>
10770
    <td align="right" class="linecount "><pre></pre></td>
10771
    <td align="left" class="src "><pre></pre></td>
10772
    </tr>
10773

    
10774
    <tr>
10775
    <td align="right" class="lineno"><pre>1497</pre></td>
10776
    <td align="right" class="linebranch"></td>
10777
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10778
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.hlen = HEADER_LENGTH_TM_LFR_SCIENCE_ASM;</pre></td>
10779
    </tr>
10780

    
10781
    <tr>
10782
    <td align="right" class="lineno"><pre>1498</pre></td>
10783
    <td align="right" class="linebranch"></td>
10784
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10785
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.hdr = (char *) header;</pre></td>
10786
    </tr>
10787

    
10788
    <tr>
10789
    <td align="right" class="lineno"><pre>1499</pre></td>
10790
    <td align="right" class="linebranch"></td>
10791
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10792
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.options = 0;</pre></td>
10793
    </tr>
10794

    
10795
    <tr>
10796
    <td align="right" class="lineno"><pre>1500</pre></td>
10797
    <td align="right" class="linebranch"></td>
10798
    <td align="right" class="linecount "><pre></pre></td>
10799
    <td align="left" class="src "><pre></pre></td>
10800
    </tr>
10801

    
10802
    <tr>
10803
    <td align="right" class="lineno"><pre>1501</pre></td>
10804
    <td align="right" class="linebranch"></td>
10805
    <td align="right" class="linecount "><pre></pre></td>
10806
    <td align="left" class="src "><pre>        // (2) BUILD THE HEADER</pre></td>
10807
    </tr>
10808

    
10809
    <tr>
10810
    <td align="right" class="lineno"><pre>1502</pre></td>
10811
    <td align="right" class="linebranch"></td>
10812
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10813
    <td align="left" class="src coveredLine"><pre>        increment_seq_counter_source_id( header->packetSequenceControl, sid );</pre></td>
10814
    </tr>
10815

    
10816
    <tr>
10817
    <td align="right" class="lineno"><pre>1503</pre></td>
10818
    <td align="right" class="linebranch"></td>
10819
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10820
    <td align="left" class="src coveredLine"><pre>        header->packetLength[0] = (unsigned char) (length >> SHIFT_1_BYTE);</pre></td>
10821
    </tr>
10822

    
10823
    <tr>
10824
    <td align="right" class="lineno"><pre>1504</pre></td>
10825
    <td align="right" class="linebranch"></td>
10826
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10827
    <td align="left" class="src coveredLine"><pre>        header->packetLength[1] = (unsigned char) (length);</pre></td>
10828
    </tr>
10829

    
10830
    <tr>
10831
    <td align="right" class="lineno"><pre>1505</pre></td>
10832
    <td align="right" class="linebranch"></td>
10833
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10834
    <td align="left" class="src coveredLine"><pre>        header->sid = (unsigned char) sid;   // SID</pre></td>
10835
    </tr>
10836

    
10837
    <tr>
10838
    <td align="right" class="lineno"><pre>1506</pre></td>
10839
    <td align="right" class="linebranch"></td>
10840
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10841
    <td align="left" class="src coveredLine"><pre>        header->pa_lfr_pkt_cnt_asm = PKTCNT_ASM;</pre></td>
10842
    </tr>
10843

    
10844
    <tr>
10845
    <td align="right" class="lineno"><pre>1507</pre></td>
10846
    <td align="right" class="linebranch"></td>
10847
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10848
    <td align="left" class="src coveredLine"><pre>        header->pa_lfr_pkt_nr_asm = (unsigned char) (i+1);</pre></td>
10849
    </tr>
10850

    
10851
    <tr>
10852
    <td align="right" class="lineno"><pre>1508</pre></td>
10853
    <td align="right" class="linebranch"></td>
10854
    <td align="right" class="linecount "><pre></pre></td>
10855
    <td align="left" class="src "><pre></pre></td>
10856
    </tr>
10857

    
10858
    <tr>
10859
    <td align="right" class="lineno"><pre>1509</pre></td>
10860
    <td align="right" class="linebranch"></td>
10861
    <td align="right" class="linecount "><pre></pre></td>
10862
    <td align="left" class="src "><pre>        // (3) SET PACKET TIME</pre></td>
10863
    </tr>
10864

    
10865
    <tr>
10866
    <td align="right" class="lineno"><pre>1510</pre></td>
10867
    <td align="right" class="linebranch"></td>
10868
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10869
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_0] = (unsigned char) (coarseTime >> SHIFT_3_BYTES);</pre></td>
10870
    </tr>
10871

    
10872
    <tr>
10873
    <td align="right" class="lineno"><pre>1511</pre></td>
10874
    <td align="right" class="linebranch"></td>
10875
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10876
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_1] = (unsigned char) (coarseTime >> SHIFT_2_BYTES);</pre></td>
10877
    </tr>
10878

    
10879
    <tr>
10880
    <td align="right" class="lineno"><pre>1512</pre></td>
10881
    <td align="right" class="linebranch"></td>
10882
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10883
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_2] = (unsigned char) (coarseTime >> SHIFT_1_BYTE);</pre></td>
10884
    </tr>
10885

    
10886
    <tr>
10887
    <td align="right" class="lineno"><pre>1513</pre></td>
10888
    <td align="right" class="linebranch"></td>
10889
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10890
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_3] = (unsigned char) (coarseTime);</pre></td>
10891
    </tr>
10892

    
10893
    <tr>
10894
    <td align="right" class="lineno"><pre>1514</pre></td>
10895
    <td align="right" class="linebranch"></td>
10896
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10897
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_4] = (unsigned char) (fineTime >> SHIFT_1_BYTE);</pre></td>
10898
    </tr>
10899

    
10900
    <tr>
10901
    <td align="right" class="lineno"><pre>1515</pre></td>
10902
    <td align="right" class="linebranch"></td>
10903
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10904
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_5] = (unsigned char) (fineTime);</pre></td>
10905
    </tr>
10906

    
10907
    <tr>
10908
    <td align="right" class="lineno"><pre>1516</pre></td>
10909
    <td align="right" class="linebranch"></td>
10910
    <td align="right" class="linecount "><pre></pre></td>
10911
    <td align="left" class="src "><pre>        //</pre></td>
10912
    </tr>
10913

    
10914
    <tr>
10915
    <td align="right" class="lineno"><pre>1517</pre></td>
10916
    <td align="right" class="linebranch"></td>
10917
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10918
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_0] = header->time[BYTE_0];</pre></td>
10919
    </tr>
10920

    
10921
    <tr>
10922
    <td align="right" class="lineno"><pre>1518</pre></td>
10923
    <td align="right" class="linebranch"></td>
10924
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10925
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_1] = header->time[BYTE_1];</pre></td>
10926
    </tr>
10927

    
10928
    <tr>
10929
    <td align="right" class="lineno"><pre>1519</pre></td>
10930
    <td align="right" class="linebranch"></td>
10931
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10932
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_2] = header->time[BYTE_2];</pre></td>
10933
    </tr>
10934

    
10935
    <tr>
10936
    <td align="right" class="lineno"><pre>1520</pre></td>
10937
    <td align="right" class="linebranch"></td>
10938
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10939
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_3] = header->time[BYTE_3];</pre></td>
10940
    </tr>
10941

    
10942
    <tr>
10943
    <td align="right" class="lineno"><pre>1521</pre></td>
10944
    <td align="right" class="linebranch"></td>
10945
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10946
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_4] = header->time[BYTE_4];</pre></td>
10947
    </tr>
10948

    
10949
    <tr>
10950
    <td align="right" class="lineno"><pre>1522</pre></td>
10951
    <td align="right" class="linebranch"></td>
10952
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10953
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_5] = header->time[BYTE_5];</pre></td>
10954
    </tr>
10955

    
10956
    <tr>
10957
    <td align="right" class="lineno"><pre>1523</pre></td>
10958
    <td align="right" class="linebranch"></td>
10959
    <td align="right" class="linecount "><pre></pre></td>
10960
    <td align="left" class="src "><pre></pre></td>
10961
    </tr>
10962

    
10963
    <tr>
10964
    <td align="right" class="lineno"><pre>1524</pre></td>
10965
    <td align="right" class="linebranch"></td>
10966
    <td align="right" class="linecount "><pre></pre></td>
10967
    <td align="left" class="src "><pre>        // (4) SEND PACKET</pre></td>
10968
    </tr>
10969

    
10970
    <tr>
10971
    <td align="right" class="lineno"><pre>1525</pre></td>
10972
    <td align="right" class="linebranch"></td>
10973
    <td align="right" class="linecount coveredLine"><pre>48336</pre></td>
10974
    <td align="left" class="src coveredLine"><pre>        status = ioctl( fdSPW, SPACEWIRE_IOCTRL_SEND, &amp;spw_ioctl_send_ASM );</pre></td>
10975
    </tr>
10976

    
10977
    <tr>
10978
    <td align="right" class="lineno"><pre>1526</pre></td>
10979
    <td align="right" class="linebranch"></td>
10980
    <td align="right" class="linecount "><pre></pre></td>
10981
    <td align="left" class="src "><pre>        if (status != RTEMS_SUCCESSFUL) {</pre></td>
10982
    </tr>
10983

    
10984
    <tr>
10985
    <td align="right" class="lineno"><pre>1527</pre></td>
10986
    <td align="right" class="linebranch"></td>
10987
    <td align="right" class="linecount "><pre></pre></td>
10988
    <td align="left" class="src "><pre>            PRINTF1("in ASM_send *** ERR %d\n", (int) status)</pre></td>
10989
    </tr>
10990

    
10991
    <tr>
10992
    <td align="right" class="lineno"><pre>1528</pre></td>
10993
    <td align="right" class="linebranch"></td>
10994
    <td align="right" class="linecount "><pre></pre></td>
10995
    <td align="left" class="src "><pre>        }</pre></td>
10996
    </tr>
10997

    
10998
    <tr>
10999
    <td align="right" class="lineno"><pre>1529</pre></td>
11000
    <td align="right" class="linebranch"></td>
11001
    <td align="right" class="linecount "><pre></pre></td>
11002
    <td align="left" class="src "><pre>    }</pre></td>
11003
    </tr>
11004

    
11005
    <tr>
11006
    <td align="right" class="lineno"><pre>1530</pre></td>
11007
    <td align="right" class="linebranch"></td>
11008
    <td align="right" class="linecount coveredLine"><pre>16112</pre></td>
11009
    <td align="left" class="src coveredLine"><pre>}</pre></td>
11010
    </tr>
11011

    
11012
    <tr>
11013
    <td align="right" class="lineno"><pre>1531</pre></td>
11014
    <td align="right" class="linebranch"></td>
11015
    <td align="right" class="linecount "><pre></pre></td>
11016
    <td align="left" class="src "><pre></pre></td>
11017
    </tr>
11018

    
11019
    <tr>
11020
    <td align="right" class="lineno"><pre>1532</pre></td>
11021
    <td align="right" class="linebranch"></td>
11022
    <td align="right" class="linecount "><pre></pre></td>
11023
    <td align="left" class="src "><pre>/**</pre></td>
11024
    </tr>
11025

    
11026
    <tr>
11027
    <td align="right" class="lineno"><pre>1533</pre></td>
11028
    <td align="right" class="linebranch"></td>
11029
    <td align="right" class="linecount "><pre></pre></td>
11030
    <td align="left" class="src "><pre> * @brief spw_send_asm_f2 Sends an ASM packet at F2 over spacewire</pre></td>
11031
    </tr>
11032

    
11033
    <tr>
11034
    <td align="right" class="lineno"><pre>1534</pre></td>
11035
    <td align="right" class="linebranch"></td>
11036
    <td align="right" class="linecount "><pre></pre></td>
11037
    <td align="left" class="src "><pre> * @param ring_node_to_send node pointing to the actual buffer to send</pre></td>
11038
    </tr>
11039

    
11040
    <tr>
11041
    <td align="right" class="lineno"><pre>1535</pre></td>
11042
    <td align="right" class="linebranch"></td>
11043
    <td align="right" class="linecount "><pre></pre></td>
11044
    <td align="left" class="src "><pre> * @param header</pre></td>
11045
    </tr>
11046

    
11047
    <tr>
11048
    <td align="right" class="lineno"><pre>1536</pre></td>
11049
    <td align="right" class="linebranch"></td>
11050
    <td align="right" class="linecount "><pre></pre></td>
11051
    <td align="left" class="src "><pre> */</pre></td>
11052
    </tr>
11053

    
11054
    <tr>
11055
    <td align="right" class="lineno"><pre>1537</pre></td>
11056
    <td align="right" class="linebranch"></td>
11057
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11058
    <td align="left" class="src coveredLine"><pre>void spw_send_asm_f2( ring_node *ring_node_to_send,</pre></td>
11059
    </tr>
11060

    
11061
    <tr>
11062
    <td align="right" class="lineno"><pre>1538</pre></td>
11063
    <td align="right" class="linebranch"></td>
11064
    <td align="right" class="linecount "><pre></pre></td>
11065
    <td align="left" class="src "><pre>                   Header_TM_LFR_SCIENCE_ASM_t *header )</pre></td>
11066
    </tr>
11067

    
11068
    <tr>
11069
    <td align="right" class="lineno"><pre>1539</pre></td>
11070
    <td align="right" class="linebranch"></td>
11071
    <td align="right" class="linecount "><pre></pre></td>
11072
    <td align="left" class="src "><pre>{</pre></td>
11073
    </tr>
11074

    
11075
    <tr>
11076
    <td align="right" class="lineno"><pre>1540</pre></td>
11077
    <td align="right" class="linebranch"></td>
11078
    <td align="right" class="linecount "><pre></pre></td>
11079
    <td align="left" class="src "><pre>    unsigned int i;</pre></td>
11080
    </tr>
11081

    
11082
    <tr>
11083
    <td align="right" class="lineno"><pre>1541</pre></td>
11084
    <td align="right" class="linebranch"></td>
11085
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11086
    <td align="left" class="src coveredLine"><pre>    unsigned int length = 0;</pre></td>
11087
    </tr>
11088

    
11089
    <tr>
11090
    <td align="right" class="lineno"><pre>1542</pre></td>
11091
    <td align="right" class="linebranch"></td>
11092
    <td align="right" class="linecount "><pre></pre></td>
11093
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
11094
    </tr>
11095

    
11096
    <tr>
11097
    <td align="right" class="lineno"><pre>1543</pre></td>
11098
    <td align="right" class="linebranch"></td>
11099
    <td align="right" class="linecount "><pre></pre></td>
11100
    <td align="left" class="src "><pre>    unsigned int sid;</pre></td>
11101
    </tr>
11102

    
11103
    <tr>
11104
    <td align="right" class="lineno"><pre>1544</pre></td>
11105
    <td align="right" class="linebranch"></td>
11106
    <td align="right" class="linecount "><pre></pre></td>
11107
    <td align="left" class="src "><pre>    float *spectral_matrix;</pre></td>
11108
    </tr>
11109

    
11110
    <tr>
11111
    <td align="right" class="lineno"><pre>1545</pre></td>
11112
    <td align="right" class="linebranch"></td>
11113
    <td align="right" class="linecount "><pre></pre></td>
11114
    <td align="left" class="src "><pre>    int coarseTime;</pre></td>
11115
    </tr>
11116

    
11117
    <tr>
11118
    <td align="right" class="lineno"><pre>1546</pre></td>
11119
    <td align="right" class="linebranch"></td>
11120
    <td align="right" class="linecount "><pre></pre></td>
11121
    <td align="left" class="src "><pre>    int fineTime;</pre></td>
11122
    </tr>
11123

    
11124
    <tr>
11125
    <td align="right" class="lineno"><pre>1547</pre></td>
11126
    <td align="right" class="linebranch"></td>
11127
    <td align="right" class="linecount "><pre></pre></td>
11128
    <td align="left" class="src "><pre>    spw_ioctl_pkt_send spw_ioctl_send_ASM;</pre></td>
11129
    </tr>
11130

    
11131
    <tr>
11132
    <td align="right" class="lineno"><pre>1548</pre></td>
11133
    <td align="right" class="linebranch"></td>
11134
    <td align="right" class="linecount "><pre></pre></td>
11135
    <td align="left" class="src "><pre></pre></td>
11136
    </tr>
11137

    
11138
    <tr>
11139
    <td align="right" class="lineno"><pre>1549</pre></td>
11140
    <td align="right" class="linebranch"></td>
11141
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11142
    <td align="left" class="src coveredLine"><pre>    sid = ring_node_to_send->sid;</pre></td>
11143
    </tr>
11144

    
11145
    <tr>
11146
    <td align="right" class="lineno"><pre>1550</pre></td>
11147
    <td align="right" class="linebranch"></td>
11148
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11149
    <td align="left" class="src coveredLine"><pre>    spectral_matrix = (float*) ring_node_to_send->buffer_address;</pre></td>
11150
    </tr>
11151

    
11152
    <tr>
11153
    <td align="right" class="lineno"><pre>1551</pre></td>
11154
    <td align="right" class="linebranch"></td>
11155
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11156
    <td align="left" class="src coveredLine"><pre>    coarseTime = ring_node_to_send->coarseTime;</pre></td>
11157
    </tr>
11158

    
11159
    <tr>
11160
    <td align="right" class="lineno"><pre>1552</pre></td>
11161
    <td align="right" class="linebranch"></td>
11162
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11163
    <td align="left" class="src coveredLine"><pre>    fineTime = ring_node_to_send->fineTime;</pre></td>
11164
    </tr>
11165

    
11166
    <tr>
11167
    <td align="right" class="lineno"><pre>1553</pre></td>
11168
    <td align="right" class="linebranch"></td>
11169
    <td align="right" class="linecount "><pre></pre></td>
11170
    <td align="left" class="src "><pre></pre></td>
11171
    </tr>
11172

    
11173
    <tr>
11174
    <td align="right" class="lineno"><pre>1554</pre></td>
11175
    <td align="right" class="linebranch"></td>
11176
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11177
    <td align="left" class="src coveredLine"><pre>    header->pa_bia_status_info = pa_bia_status_info;</pre></td>
11178
    </tr>
11179

    
11180
    <tr>
11181
    <td align="right" class="lineno"><pre>1555</pre></td>
11182
    <td align="right" class="linebranch"></td>
11183
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11184
    <td align="left" class="src coveredLine"><pre>    header->sy_lfr_common_parameters = parameter_dump_packet.sy_lfr_common_parameters;</pre></td>
11185
    </tr>
11186

    
11187
    <tr>
11188
    <td align="right" class="lineno"><pre>1556</pre></td>
11189
    <td align="right" class="linebranch"></td>
11190
    <td align="right" class="linecount "><pre></pre></td>
11191
    <td align="left" class="src "><pre></pre></td>
11192
    </tr>
11193

    
11194
    <tr>
11195
    <td align="right" class="lineno"><pre>1557</pre></td>
11196
    <td align="right" class="linebranch"><span class="takenBranch" title="Branch 0 taken 48300 times">&check;</span><span class="takenBranch" title="Branch 1 taken 16100 times">&check;</span></td>
11197
    <td align="right" class="linecount coveredLine"><pre>64400</pre></td>
11198
    <td align="left" class="src coveredLine"><pre>    for (i=0; i&lt;PKTCNT_ASM; i++)</pre></td>
11199
    </tr>
11200

    
11201
    <tr>
11202
    <td align="right" class="lineno"><pre>1558</pre></td>
11203
    <td align="right" class="linebranch"></td>
11204
    <td align="right" class="linecount "><pre></pre></td>
11205
    <td align="left" class="src "><pre>    {</pre></td>
11206
    </tr>
11207

    
11208
    <tr>
11209
    <td align="right" class="lineno"><pre>1559</pre></td>
11210
    <td align="right" class="linebranch"></td>
11211
    <td align="right" class="linecount "><pre></pre></td>
11212
    <td align="left" class="src "><pre></pre></td>
11213
    </tr>
11214

    
11215
    <tr>
11216
    <td align="right" class="lineno"><pre>1560</pre></td>
11217
    <td align="right" class="linebranch"></td>
11218
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11219
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.dlen = DLEN_ASM_F2_PKT;</pre></td>
11220
    </tr>
11221

    
11222
    <tr>
11223
    <td align="right" class="lineno"><pre>1561</pre></td>
11224
    <td align="right" class="linebranch"></td>
11225
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11226
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.data = (char *) &amp;spectral_matrix[</pre></td>
11227
    </tr>
11228

    
11229
    <tr>
11230
    <td align="right" class="lineno"><pre>1562</pre></td>
11231
    <td align="right" class="linebranch"></td>
11232
    <td align="right" class="linecount "><pre></pre></td>
11233
    <td align="left" class="src "><pre>                ( (ASM_F2_INDICE_START + (i*NB_BINS_PER_PKT_ASM_F2) ) * NB_VALUES_PER_SM )</pre></td>
11234
    </tr>
11235

    
11236
    <tr>
11237
    <td align="right" class="lineno"><pre>1563</pre></td>
11238
    <td align="right" class="linebranch"></td>
11239
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11240
    <td align="left" class="src coveredLine"><pre>                ];</pre></td>
11241
    </tr>
11242

    
11243
    <tr>
11244
    <td align="right" class="lineno"><pre>1564</pre></td>
11245
    <td align="right" class="linebranch"></td>
11246
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11247
    <td align="left" class="src coveredLine"><pre>        length = PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F2;</pre></td>
11248
    </tr>
11249

    
11250
    <tr>
11251
    <td align="right" class="lineno"><pre>1565</pre></td>
11252
    <td align="right" class="linebranch"></td>
11253
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11254
    <td align="left" class="src coveredLine"><pre>        header->serviceSubType = TM_SUBTYPE_LFR_SCIENCE_3;</pre></td>
11255
    </tr>
11256

    
11257
    <tr>
11258
    <td align="right" class="lineno"><pre>1566</pre></td>
11259
    <td align="right" class="linebranch"></td>
11260
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11261
    <td align="left" class="src coveredLine"><pre>        header->pa_lfr_asm_blk_nr[0] = (unsigned char)  ( (NB_BINS_PER_PKT_ASM_F2) >> SHIFT_1_BYTE ); // BLK_NR MSB</pre></td>
11262
    </tr>
11263

    
11264
    <tr>
11265
    <td align="right" class="lineno"><pre>1567</pre></td>
11266
    <td align="right" class="linebranch"></td>
11267
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11268
    <td align="left" class="src coveredLine"><pre>        header->pa_lfr_asm_blk_nr[1] = (unsigned char)    (NB_BINS_PER_PKT_ASM_F2);        // BLK_NR LSB</pre></td>
11269
    </tr>
11270

    
11271
    <tr>
11272
    <td align="right" class="lineno"><pre>1568</pre></td>
11273
    <td align="right" class="linebranch"></td>
11274
    <td align="right" class="linecount "><pre></pre></td>
11275
    <td align="left" class="src "><pre></pre></td>
11276
    </tr>
11277

    
11278
    <tr>
11279
    <td align="right" class="lineno"><pre>1569</pre></td>
11280
    <td align="right" class="linebranch"></td>
11281
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11282
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.hlen = HEADER_LENGTH_TM_LFR_SCIENCE_ASM;</pre></td>
11283
    </tr>
11284

    
11285
    <tr>
11286
    <td align="right" class="lineno"><pre>1570</pre></td>
11287
    <td align="right" class="linebranch"></td>
11288
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11289
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.hdr = (char *) header;</pre></td>
11290
    </tr>
11291

    
11292
    <tr>
11293
    <td align="right" class="lineno"><pre>1571</pre></td>
11294
    <td align="right" class="linebranch"></td>
11295
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11296
    <td align="left" class="src coveredLine"><pre>        spw_ioctl_send_ASM.options = 0;</pre></td>
11297
    </tr>
11298

    
11299
    <tr>
11300
    <td align="right" class="lineno"><pre>1572</pre></td>
11301
    <td align="right" class="linebranch"></td>
11302
    <td align="right" class="linecount "><pre></pre></td>
11303
    <td align="left" class="src "><pre></pre></td>
11304
    </tr>
11305

    
11306
    <tr>
11307
    <td align="right" class="lineno"><pre>1573</pre></td>
11308
    <td align="right" class="linebranch"></td>
11309
    <td align="right" class="linecount "><pre></pre></td>
11310
    <td align="left" class="src "><pre>        // (2) BUILD THE HEADER</pre></td>
11311
    </tr>
11312

    
11313
    <tr>
11314
    <td align="right" class="lineno"><pre>1574</pre></td>
11315
    <td align="right" class="linebranch"></td>
11316
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11317
    <td align="left" class="src coveredLine"><pre>        increment_seq_counter_source_id( header->packetSequenceControl, sid );</pre></td>
11318
    </tr>
11319

    
11320
    <tr>
11321
    <td align="right" class="lineno"><pre>1575</pre></td>
11322
    <td align="right" class="linebranch"></td>
11323
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11324
    <td align="left" class="src coveredLine"><pre>        header->packetLength[0] = (unsigned char) (length >> SHIFT_1_BYTE);</pre></td>
11325
    </tr>
11326

    
11327
    <tr>
11328
    <td align="right" class="lineno"><pre>1576</pre></td>
11329
    <td align="right" class="linebranch"></td>
11330
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11331
    <td align="left" class="src coveredLine"><pre>        header->packetLength[1] = (unsigned char) (length);</pre></td>
11332
    </tr>
11333

    
11334
    <tr>
11335
    <td align="right" class="lineno"><pre>1577</pre></td>
11336
    <td align="right" class="linebranch"></td>
11337
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11338
    <td align="left" class="src coveredLine"><pre>        header->sid = (unsigned char) sid;   // SID</pre></td>
11339
    </tr>
11340

    
11341
    <tr>
11342
    <td align="right" class="lineno"><pre>1578</pre></td>
11343
    <td align="right" class="linebranch"></td>
11344
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11345
    <td align="left" class="src coveredLine"><pre>        header->pa_lfr_pkt_cnt_asm = PKTCNT_ASM;</pre></td>
11346
    </tr>
11347

    
11348
    <tr>
11349
    <td align="right" class="lineno"><pre>1579</pre></td>
11350
    <td align="right" class="linebranch"></td>
11351
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11352
    <td align="left" class="src coveredLine"><pre>        header->pa_lfr_pkt_nr_asm = (unsigned char) (i+1);</pre></td>
11353
    </tr>
11354

    
11355
    <tr>
11356
    <td align="right" class="lineno"><pre>1580</pre></td>
11357
    <td align="right" class="linebranch"></td>
11358
    <td align="right" class="linecount "><pre></pre></td>
11359
    <td align="left" class="src "><pre></pre></td>
11360
    </tr>
11361

    
11362
    <tr>
11363
    <td align="right" class="lineno"><pre>1581</pre></td>
11364
    <td align="right" class="linebranch"></td>
11365
    <td align="right" class="linecount "><pre></pre></td>
11366
    <td align="left" class="src "><pre>        // (3) SET PACKET TIME</pre></td>
11367
    </tr>
11368

    
11369
    <tr>
11370
    <td align="right" class="lineno"><pre>1582</pre></td>
11371
    <td align="right" class="linebranch"></td>
11372
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11373
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_0] = (unsigned char) (coarseTime >> SHIFT_3_BYTES);</pre></td>
11374
    </tr>
11375

    
11376
    <tr>
11377
    <td align="right" class="lineno"><pre>1583</pre></td>
11378
    <td align="right" class="linebranch"></td>
11379
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11380
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_1] = (unsigned char) (coarseTime >> SHIFT_2_BYTES);</pre></td>
11381
    </tr>
11382

    
11383
    <tr>
11384
    <td align="right" class="lineno"><pre>1584</pre></td>
11385
    <td align="right" class="linebranch"></td>
11386
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11387
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_2] = (unsigned char) (coarseTime >> SHIFT_1_BYTE);</pre></td>
11388
    </tr>
11389

    
11390
    <tr>
11391
    <td align="right" class="lineno"><pre>1585</pre></td>
11392
    <td align="right" class="linebranch"></td>
11393
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11394
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_3] = (unsigned char) (coarseTime);</pre></td>
11395
    </tr>
11396

    
11397
    <tr>
11398
    <td align="right" class="lineno"><pre>1586</pre></td>
11399
    <td align="right" class="linebranch"></td>
11400
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11401
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_4] = (unsigned char) (fineTime >> SHIFT_1_BYTE);</pre></td>
11402
    </tr>
11403

    
11404
    <tr>
11405
    <td align="right" class="lineno"><pre>1587</pre></td>
11406
    <td align="right" class="linebranch"></td>
11407
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11408
    <td align="left" class="src coveredLine"><pre>        header->time[BYTE_5] = (unsigned char) (fineTime);</pre></td>
11409
    </tr>
11410

    
11411
    <tr>
11412
    <td align="right" class="lineno"><pre>1588</pre></td>
11413
    <td align="right" class="linebranch"></td>
11414
    <td align="right" class="linecount "><pre></pre></td>
11415
    <td align="left" class="src "><pre>        //</pre></td>
11416
    </tr>
11417

    
11418
    <tr>
11419
    <td align="right" class="lineno"><pre>1589</pre></td>
11420
    <td align="right" class="linebranch"></td>
11421
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11422
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_0] = header->time[BYTE_0];</pre></td>
11423
    </tr>
11424

    
11425
    <tr>
11426
    <td align="right" class="lineno"><pre>1590</pre></td>
11427
    <td align="right" class="linebranch"></td>
11428
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11429
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_1] = header->time[BYTE_1];</pre></td>
11430
    </tr>
11431

    
11432
    <tr>
11433
    <td align="right" class="lineno"><pre>1591</pre></td>
11434
    <td align="right" class="linebranch"></td>
11435
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11436
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_2] = header->time[BYTE_2];</pre></td>
11437
    </tr>
11438

    
11439
    <tr>
11440
    <td align="right" class="lineno"><pre>1592</pre></td>
11441
    <td align="right" class="linebranch"></td>
11442
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11443
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_3] = header->time[BYTE_3];</pre></td>
11444
    </tr>
11445

    
11446
    <tr>
11447
    <td align="right" class="lineno"><pre>1593</pre></td>
11448
    <td align="right" class="linebranch"></td>
11449
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11450
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_4] = header->time[BYTE_4];</pre></td>
11451
    </tr>
11452

    
11453
    <tr>
11454
    <td align="right" class="lineno"><pre>1594</pre></td>
11455
    <td align="right" class="linebranch"></td>
11456
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11457
    <td align="left" class="src coveredLine"><pre>        header->acquisitionTime[BYTE_5] = header->time[BYTE_5];</pre></td>
11458
    </tr>
11459

    
11460
    <tr>
11461
    <td align="right" class="lineno"><pre>1595</pre></td>
11462
    <td align="right" class="linebranch"></td>
11463
    <td align="right" class="linecount "><pre></pre></td>
11464
    <td align="left" class="src "><pre></pre></td>
11465
    </tr>
11466

    
11467
    <tr>
11468
    <td align="right" class="lineno"><pre>1596</pre></td>
11469
    <td align="right" class="linebranch"></td>
11470
    <td align="right" class="linecount "><pre></pre></td>
11471
    <td align="left" class="src "><pre>        // (4) SEND PACKET</pre></td>
11472
    </tr>
11473

    
11474
    <tr>
11475
    <td align="right" class="lineno"><pre>1597</pre></td>
11476
    <td align="right" class="linebranch"></td>
11477
    <td align="right" class="linecount coveredLine"><pre>48300</pre></td>
11478
    <td align="left" class="src coveredLine"><pre>        status = ioctl( fdSPW, SPACEWIRE_IOCTRL_SEND, &amp;spw_ioctl_send_ASM );</pre></td>
11479
    </tr>
11480

    
11481
    <tr>
11482
    <td align="right" class="lineno"><pre>1598</pre></td>
11483
    <td align="right" class="linebranch"></td>
11484
    <td align="right" class="linecount "><pre></pre></td>
11485
    <td align="left" class="src "><pre>        if (status != RTEMS_SUCCESSFUL) {</pre></td>
11486
    </tr>
11487

    
11488
    <tr>
11489
    <td align="right" class="lineno"><pre>1599</pre></td>
11490
    <td align="right" class="linebranch"></td>
11491
    <td align="right" class="linecount "><pre></pre></td>
11492
    <td align="left" class="src "><pre>            PRINTF1("in ASM_send *** ERR %d\n", (int) status)</pre></td>
11493
    </tr>
11494

    
11495
    <tr>
11496
    <td align="right" class="lineno"><pre>1600</pre></td>
11497
    <td align="right" class="linebranch"></td>
11498
    <td align="right" class="linecount "><pre></pre></td>
11499
    <td align="left" class="src "><pre>        }</pre></td>
11500
    </tr>
11501

    
11502
    <tr>
11503
    <td align="right" class="lineno"><pre>1601</pre></td>
11504
    <td align="right" class="linebranch"></td>
11505
    <td align="right" class="linecount "><pre></pre></td>
11506
    <td align="left" class="src "><pre>    }</pre></td>
11507
    </tr>
11508

    
11509
    <tr>
11510
    <td align="right" class="lineno"><pre>1602</pre></td>
11511
    <td align="right" class="linebranch"></td>
11512
    <td align="right" class="linecount coveredLine"><pre>16100</pre></td>
11513
    <td align="left" class="src coveredLine"><pre>}</pre></td>
11514
    </tr>
11515

    
11516
    <tr>
11517
    <td align="right" class="lineno"><pre>1603</pre></td>
11518
    <td align="right" class="linebranch"></td>
11519
    <td align="right" class="linecount "><pre></pre></td>
11520
    <td align="left" class="src "><pre></pre></td>
11521
    </tr>
11522

    
11523
    <tr>
11524
    <td align="right" class="lineno"><pre>1604</pre></td>
11525
    <td align="right" class="linebranch"></td>
11526
    <td align="right" class="linecount "><pre></pre></td>
11527
    <td align="left" class="src "><pre>/**</pre></td>
11528
    </tr>
11529

    
11530
    <tr>
11531
    <td align="right" class="lineno"><pre>1605</pre></td>
11532
    <td align="right" class="linebranch"></td>
11533
    <td align="right" class="linecount "><pre></pre></td>
11534
    <td align="left" class="src "><pre> * @brief spw_send_k_dump Sends k coefficients dump packet over spacewire</pre></td>
11535
    </tr>
11536

    
11537
    <tr>
11538
    <td align="right" class="lineno"><pre>1606</pre></td>
11539
    <td align="right" class="linebranch"></td>
11540
    <td align="right" class="linecount "><pre></pre></td>
11541
    <td align="left" class="src "><pre> * @param ring_node_to_send node pointing to the actual buffer to send</pre></td>
11542
    </tr>
11543

    
11544
    <tr>
11545
    <td align="right" class="lineno"><pre>1607</pre></td>
11546
    <td align="right" class="linebranch"></td>
11547
    <td align="right" class="linecount "><pre></pre></td>
11548
    <td align="left" class="src "><pre> */</pre></td>
11549
    </tr>
11550

    
11551
    <tr>
11552
    <td align="right" class="lineno"><pre>1608</pre></td>
11553
    <td align="right" class="linebranch"></td>
11554
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
11555
    <td align="left" class="src coveredLine"><pre>void spw_send_k_dump( ring_node *ring_node_to_send )</pre></td>
11556
    </tr>
11557

    
11558
    <tr>
11559
    <td align="right" class="lineno"><pre>1609</pre></td>
11560
    <td align="right" class="linebranch"></td>
11561
    <td align="right" class="linecount "><pre></pre></td>
11562
    <td align="left" class="src "><pre>{</pre></td>
11563
    </tr>
11564

    
11565
    <tr>
11566
    <td align="right" class="lineno"><pre>1610</pre></td>
11567
    <td align="right" class="linebranch"></td>
11568
    <td align="right" class="linecount "><pre></pre></td>
11569
    <td align="left" class="src "><pre>    rtems_status_code status;</pre></td>
11570
    </tr>
11571

    
11572
    <tr>
11573
    <td align="right" class="lineno"><pre>1611</pre></td>
11574
    <td align="right" class="linebranch"></td>
11575
    <td align="right" class="linecount "><pre></pre></td>
11576
    <td align="left" class="src "><pre>    Packet_TM_LFR_KCOEFFICIENTS_DUMP_t *kcoefficients_dump;</pre></td>
11577
    </tr>
11578

    
11579
    <tr>
11580
    <td align="right" class="lineno"><pre>1612</pre></td>
11581
    <td align="right" class="linebranch"></td>
11582
    <td align="right" class="linecount "><pre></pre></td>
11583
    <td align="left" class="src "><pre>    unsigned int packetLength;</pre></td>
11584
    </tr>
11585

    
11586
    <tr>
11587
    <td align="right" class="lineno"><pre>1613</pre></td>
11588
    <td align="right" class="linebranch"></td>
11589
    <td align="right" class="linecount "><pre></pre></td>
11590
    <td align="left" class="src "><pre>    unsigned int size;</pre></td>
11591
    </tr>
11592

    
11593
    <tr>
11594
    <td align="right" class="lineno"><pre>1614</pre></td>
11595
    <td align="right" class="linebranch"></td>
11596
    <td align="right" class="linecount "><pre></pre></td>
11597
    <td align="left" class="src "><pre></pre></td>
11598
    </tr>
11599

    
11600
    <tr>
11601
    <td align="right" class="lineno"><pre>1615</pre></td>
11602
    <td align="right" class="linebranch"></td>
11603
    <td align="right" class="linecount "><pre></pre></td>
11604
    <td align="left" class="src "><pre>    PRINTF("spw_send_k_dump\n")</pre></td>
11605
    </tr>
11606

    
11607
    <tr>
11608
    <td align="right" class="lineno"><pre>1616</pre></td>
11609
    <td align="right" class="linebranch"></td>
11610
    <td align="right" class="linecount "><pre></pre></td>
11611
    <td align="left" class="src "><pre></pre></td>
11612
    </tr>
11613

    
11614
    <tr>
11615
    <td align="right" class="lineno"><pre>1617</pre></td>
11616
    <td align="right" class="linebranch"></td>
11617
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
11618
    <td align="left" class="src coveredLine"><pre>    kcoefficients_dump = (Packet_TM_LFR_KCOEFFICIENTS_DUMP_t *) ring_node_to_send->buffer_address;</pre></td>
11619
    </tr>
11620

    
11621
    <tr>
11622
    <td align="right" class="lineno"><pre>1618</pre></td>
11623
    <td align="right" class="linebranch"></td>
11624
    <td align="right" class="linecount "><pre></pre></td>
11625
    <td align="left" class="src "><pre></pre></td>
11626
    </tr>
11627

    
11628
    <tr>
11629
    <td align="right" class="lineno"><pre>1619</pre></td>
11630
    <td align="right" class="linebranch"></td>
11631
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
11632
    <td align="left" class="src coveredLine"><pre>    packetLength = (kcoefficients_dump->packetLength[0] * CONST_256) + kcoefficients_dump->packetLength[1];</pre></td>
11633
    </tr>
11634

    
11635
    <tr>
11636
    <td align="right" class="lineno"><pre>1620</pre></td>
11637
    <td align="right" class="linebranch"></td>
11638
    <td align="right" class="linecount "><pre></pre></td>
11639
    <td align="left" class="src "><pre></pre></td>
11640
    </tr>
11641

    
11642
    <tr>
11643
    <td align="right" class="lineno"><pre>1621</pre></td>
11644
    <td align="right" class="linebranch"></td>
11645
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
11646
    <td align="left" class="src coveredLine"><pre>    size = packetLength + CCSDS_TC_TM_PACKET_OFFSET + CCSDS_PROTOCOLE_EXTRA_BYTES;</pre></td>
11647
    </tr>
11648

    
11649
    <tr>
11650
    <td align="right" class="lineno"><pre>1622</pre></td>
11651
    <td align="right" class="linebranch"></td>
11652
    <td align="right" class="linecount "><pre></pre></td>
11653
    <td align="left" class="src "><pre></pre></td>
11654
    </tr>
11655

    
11656
    <tr>
11657
    <td align="right" class="lineno"><pre>1623</pre></td>
11658
    <td align="right" class="linebranch"></td>
11659
    <td align="right" class="linecount "><pre></pre></td>
11660
    <td align="left" class="src "><pre>    PRINTF2("packetLength %d, size %d\n", packetLength, size )</pre></td>
11661
    </tr>
11662

    
11663
    <tr>
11664
    <td align="right" class="lineno"><pre>1624</pre></td>
11665
    <td align="right" class="linebranch"></td>
11666
    <td align="right" class="linecount "><pre></pre></td>
11667
    <td align="left" class="src "><pre></pre></td>
11668
    </tr>
11669

    
11670
    <tr>
11671
    <td align="right" class="lineno"><pre>1625</pre></td>
11672
    <td align="right" class="linebranch"></td>
11673
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
11674
    <td align="left" class="src coveredLine"><pre>    status = write( fdSPW, (char *) ring_node_to_send->buffer_address, size );</pre></td>
11675
    </tr>
11676

    
11677
    <tr>
11678
    <td align="right" class="lineno"><pre>1626</pre></td>
11679
    <td align="right" class="linebranch"></td>
11680
    <td align="right" class="linecount "><pre></pre></td>
11681
    <td align="left" class="src "><pre></pre></td>
11682
    </tr>
11683

    
11684
    <tr>
11685
    <td align="right" class="lineno"><pre>1627</pre></td>
11686
    <td align="right" class="linebranch"></td>
11687
    <td align="right" class="linecount "><pre></pre></td>
11688
    <td align="left" class="src "><pre>    if (status == -1){</pre></td>
11689
    </tr>
11690

    
11691
    <tr>
11692
    <td align="right" class="lineno"><pre>1628</pre></td>
11693
    <td align="right" class="linebranch"></td>
11694
    <td align="right" class="linecount "><pre></pre></td>
11695
    <td align="left" class="src "><pre>        PRINTF2("in SEND *** (2.a) ERRNO = %d, size = %d\n", errno, size)</pre></td>
11696
    </tr>
11697

    
11698
    <tr>
11699
    <td align="right" class="lineno"><pre>1629</pre></td>
11700
    <td align="right" class="linebranch"></td>
11701
    <td align="right" class="linecount "><pre></pre></td>
11702
    <td align="left" class="src "><pre>    }</pre></td>
11703
    </tr>
11704

    
11705
    <tr>
11706
    <td align="right" class="lineno"><pre>1630</pre></td>
11707
    <td align="right" class="linebranch"></td>
11708
    <td align="right" class="linecount "><pre></pre></td>
11709
    <td align="left" class="src "><pre></pre></td>
11710
    </tr>
11711

    
11712
    <tr>
11713
    <td align="right" class="lineno"><pre>1631</pre></td>
11714
    <td align="right" class="linebranch"></td>
11715
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
11716
    <td align="left" class="src coveredLine"><pre>    ring_node_to_send->status = INIT_CHAR;</pre></td>
11717
    </tr>
11718

    
11719
    <tr>
11720
    <td align="right" class="lineno"><pre>1632</pre></td>
11721
    <td align="right" class="linebranch"></td>
11722
    <td align="right" class="linecount coveredLine"><pre>3050</pre></td>
11723
    <td align="left" class="src coveredLine"><pre>}</pre></td>
11724
    </tr>
11725

    
11726
  </table>
11727
  <br>
11728

    
11729
  <table width="100%" border="0" cellspacing="0" cellpadding="0">
11730
    <tr><td class="hr"><td></tr>
11731
    <tr><td class="footer">Generated by: <a href="http://gcovr.com">GCOVR (Version 4.1)</a></td></tr>
11732
  </table>
11733
  <br>
11734

    
11735
</body>
11736

    
11737
</html>
11738

    
(2-2/18)