-
Notifications
You must be signed in to change notification settings - Fork 207
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
1,563 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
/* | ||
** 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. | ||
*/ | ||
|
||
/** | ||
* @file | ||
* | ||
* Purpose: cFE header file | ||
* | ||
* Author: David Kobe, the Hammers Company, Inc. | ||
* | ||
* Notes: This header file centralizes the includes for all cFE | ||
* Applications. It includes all header files necessary | ||
* to completely define the cFE interface. | ||
* | ||
*/ | ||
|
||
#ifndef CFE_H | ||
#define CFE_H | ||
|
||
#include "common_types.h" /* Define basic data types */ | ||
|
||
#include "osapi.h" /* Define OS API function prototypes */ | ||
|
||
#include "cfe_mission_cfg.h" /* Define mission configuration parameters */ | ||
|
||
#include "cfe_error.h" /* Define common cFE error codes */ | ||
|
||
#include "cfe_es.h" /* Define Executive Service API */ | ||
#include "cfe_evs.h" /* Define Event Service API */ | ||
#include "cfe_fs.h" /* Define File Service API */ | ||
#include "cfe_sb.h" /* Define Software Bus API */ | ||
#include "cfe_time.h" /* Define Time Service API */ | ||
#include "cfe_tbl.h" /* Define Table Service API */ | ||
|
||
#include "cfe_msg.h" /* Define Message API */ | ||
#include "cfe_resourceid.h" /* Define ResourceID API */ | ||
|
||
#include "cfe_psp.h" /* Define Platform Support Package API */ | ||
|
||
#endif /* CFE_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
/* | ||
** 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. | ||
*/ | ||
|
||
/** | ||
* @file | ||
* | ||
* Purpose: | ||
* Define macros to enforce big-endian/network byte order for 16 and 32 bit integers | ||
* | ||
*/ | ||
|
||
#ifndef CFE_ENDIAN_H | ||
#define CFE_ENDIAN_H | ||
|
||
/* | ||
** Include Files | ||
*/ | ||
#include "common_types.h" | ||
|
||
/* | ||
* SOFTWARE_BIG/LITTLE_BIT_ORDER COMPATIBILITY MACRO - | ||
* | ||
* This is provided only for backward compatibilty. Do not write any new code that | ||
* uses this macro. | ||
*/ | ||
#if !defined(SOFTWARE_BIG_BIT_ORDER) && !defined(SOFTWARE_LITTLE_BIT_ORDER) | ||
|
||
#if defined(__BYTE_ORDER) && __BYTE_ORDER == __BIG_ENDIAN || defined(__BIG_ENDIAN__) || defined(__ARMEB__) || \ | ||
defined(__THUMBEB__) || defined(__AARCH64EB__) || defined(_MIBSEB) || defined(__MIBSEB) || defined(__MIBSEB__) | ||
/* It is a big-endian target architecture */ | ||
#define SOFTWARE_BIG_BIT_ORDER | ||
#elif defined(__BYTE_ORDER) && __BYTE_ORDER == __LITTLE_ENDIAN || defined(__LITTLE_ENDIAN__) || defined(__ARMEL__) || \ | ||
defined(__THUMBEL__) || defined(__AARCH64EL__) || defined(_MIPSEL) || defined(__MIPSEL) || defined(__MIPSEL__) || \ | ||
defined(__i386) || defined(__i386__) || defined(__i686) || defined(__i686__) || defined(__x86_64) || \ | ||
defined(__x86_64__) | ||
/* It is a little-endian target architecture */ | ||
#define SOFTWARE_LITTLE_BIT_ORDER | ||
#else | ||
#error Unknown byte order on this platform | ||
#endif | ||
|
||
#endif /* !defined(SOFTWARE_BIG_BIT_ORDER) && !defined(SOFTWARE_LITTLE_BIT_ORDER) */ | ||
|
||
/* Macro to convert 16/32 bit types from platform "endianness" to Big Endian */ | ||
#ifdef SOFTWARE_BIG_BIT_ORDER | ||
#define CFE_MAKE_BIG16(n) (n) | ||
#define CFE_MAKE_BIG32(n) (n) | ||
#else | ||
#define CFE_MAKE_BIG16(n) ((((n) << 8) & 0xFF00) | (((n) >> 8) & 0x00FF)) | ||
#define CFE_MAKE_BIG32(n) \ | ||
((((n) << 24) & 0xFF000000) | (((n) << 8) & 0x00FF0000) | (((n) >> 8) & 0x0000FF00) | (((n) >> 24) & 0x000000FF)) | ||
#endif | ||
|
||
#endif /* CFE_ENDIAN_H */ |
Oops, something went wrong.