Skip to content

Commit

Permalink
Merge pull request #33 from chillfig/inc
Browse files Browse the repository at this point in the history
Fix #32, Moves interface definition files to inc
  • Loading branch information
dzbaker authored Dec 22, 2022
2 parents 61eea35 + 762cbeb commit bba2146
Show file tree
Hide file tree
Showing 12 changed files with 48 additions and 18 deletions.
7 changes: 3 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
project(CFS_HK C)

include_directories(fsw/src)
include_directories(fsw/mission_inc)
include_directories(fsw/platform_inc)

set(APP_SRC_FILES
fsw/src/hk_app.c
fsw/src/hk_utils.c
Expand All @@ -12,6 +8,9 @@ set(APP_SRC_FILES
# Create the app module
add_cfe_app(hk ${APP_SRC_FILES})

# This permits direct access to public headers in the fsw/inc directory
target_include_directories(hk PUBLIC fsw/inc)

set(APP_TABLE_FILES
fsw/tables/hk_cpy_tbl.c
)
Expand Down
File renamed without changes.
40 changes: 40 additions & 0 deletions fsw/inc/hk_extern_typedefs.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/************************************************************************
* NASA Docket No. GSC-18,447-1, and identified as “CFS CFDP (CF)
* Application version 3.0.0”
*
* Copyright (c) 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
*
* Declarations and prototypes for hk_extern_typedefs module
*/

#ifndef HK_EXTERN_TYPEDEFS_H
#define HK_EXTERN_TYPEDEFS_H

/**
* \brief Maximum Number of HK Copy Table Entries
*
* \par Description:
* Dictates the number of elements in the hk copy table.
*
* \par Limits
* The maximum size of this paramater is 8192
*/
#define HK_COPY_TABLE_ENTRIES 128

#endif /* HK_EXTERN_TYPEDEFS_H */
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
11 changes: 0 additions & 11 deletions fsw/platform_inc/hk_platform_cfg.h → fsw/inc/hk_platform_cfg.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,6 @@
*/
#define HK_DISCARD_INCOMPLETE_COMBO 0

/**
* \brief Maximum Number of HK Copy Table Entries
*
* \par Description:
* Dictates the number of elements in the hk copy table.
*
* \par Limits
* The maximum size of this paramater is 8192
*/
#define HK_COPY_TABLE_ENTRIES 128

/**
* \brief Number of bytes in the HK Memory Pool
*
Expand Down
File renamed without changes.
1 change: 1 addition & 0 deletions fsw/src/hk_app.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
#include "hk_msg.h"
#include "hk_utils.h"
#include "hk_platform_cfg.h"
#include "hk_extern_typedefs.h"

/*************************************************************************
* Macro definitions
Expand Down
3 changes: 1 addition & 2 deletions fsw/tables/hk_cpy_tbl.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@
*************************************************************************/
#include "cfe.h"
#include "cfe_msgids.h"
#include "hk_utils.h"
#include "hk_app.h"
#include "hk_extern_typedefs.h"
#include "hk_msgids.h"
#include "hk_tbldefs.h"
#include "cfe_tbl_filedef.h"
Expand Down
4 changes: 3 additions & 1 deletion unit-test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,10 @@ add_cfe_coverage_stubs("hk_internal"
# Link with the cfe core stubs and unit test assert libs
target_link_libraries(coverage-hk_internal-stubs ut_core_api_stubs ut_assert)

# Include and expose unit test utilities includes
# Include and expose unit test utilities, fsw/inc, and fsw/src includes
target_include_directories(coverage-hk_internal-stubs PUBLIC utilities)
target_include_directories(coverage-hk_internal-stubs PUBLIC ../fsw/inc)
target_include_directories(coverage-hk_internal-stubs PUBLIC ../fsw/src)

# Generate a dedicated "testrunner" executable for each test file
# Accomplish this by cycling through all the app's source files, there must be
Expand Down

0 comments on commit bba2146

Please sign in to comment.