forked from nasa/elf2cfetbl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
SampleTblImg.c
50 lines (46 loc) · 1.74 KB
/
SampleTblImg.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
/*
**
** GSC-18128-1, "Core Flight Executive Version 6.7"
**
** Copyright (c) 2006-2019 United States Government as represented by
** the Administrator of the National Aeronautics and Space Administration.
** All Rights Reserved.
**
** Licensed under the Apache License, Version 2.0 (the "License");
** you may not use this file except in compliance with the License.
** You may obtain a copy of the License at
**
** http://www.apache.org/licenses/LICENSE-2.0
**
** Unless required by applicable law or agreed to in writing, software
** distributed under the License is distributed on an "AS IS" BASIS,
** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
** See the License for the specific language governing permissions and
** limitations under the License.
**
*/
#include "cfe_tbl_filedef.h" /* Required to obtain the CFE_TBL_FILEDEF macro definition */
/*
** The following is an example of a data structure the application may have declared
** as the format of their table.
*/
typedef struct
{
int Int1;
int Int2;
int Int3;
char Char1;
} MyTblStruct_t;
/*
** The following is an example of the declaration statement that defines the desired
** contents of the table image.
*/
MyTblStruct_t MyTblStruct = {0x01020304, 0x05060708, 0x090A0B0C, 0x0D};
/*
** The macro below identifies:
** 1) the data structure type to use as the table image format
** 2) the name of the table to be placed into the cFE Table File Header
** 3) a brief description of the contents of the file image
** 4) the desired name of the table image binary file that is cFE compatible
*/
CFE_TBL_FILEDEF(MyTblStruct, MyApp.TableName, Table Utility Test Table, MyTblDefault.bin)