Skip to content

Commit

Permalink
Merge pull request #154 from nasa/integration-candidate
Browse files Browse the repository at this point in the history
to_lab Integration candidate: Caelum-rc4+dev46
  • Loading branch information
dzbaker authored Apr 13, 2023
2 parents 41516d4 + 932d445 commit 81d85da
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 22 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## Development Build: v2.5.0-rc4+dev45
- adjust subscription table based on apps present
- See <https://github.com/nasa/to_lab/pull/153>

## Development Build: v2.5.0-rc4+dev41
- update cmake recipe
- See <https://github.com/nasa/to_lab/pull/150>
Expand Down
17 changes: 12 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,13 +1,20 @@
cmake_minimum_required(VERSION 3.5)
project(CFS_TO_LAB C)

set(TO_TABLE_COMPILE_DEFS)

# These references are specifically needed for the table build
# it is easiest to add them as directory properties so they won't
# be considered include directories for TO_LAB itself.
include_directories(
$<TARGET_PROPERTY:ci_lab,INTERFACE_INCLUDE_DIRECTORIES>
$<TARGET_PROPERTY:sample_app,INTERFACE_INCLUDE_DIRECTORIES>
)
# be considered include directories for TO_LAB itself. Each one
# gets a macro for conditional inclusion in the subscription table.
foreach(EXT_APP ci_lab sample_app hs fm ds sc lc)
list (FIND TGTSYS_${SYSVAR}_APPS ${EXT_APP} HAVE_APP)
if (HAVE_APP GREATER_EQUAL 0)
include_directories($<TARGET_PROPERTY:${EXT_APP},INTERFACE_INCLUDE_DIRECTORIES>)
string(TOUPPER "HAVE_${EXT_APP}" APP_MACRO)
add_definitions(-D${APP_MACRO})
endif()
endforeach()

set(APP_SRC_FILES
fsw/src/to_lab_app.c
Expand Down
2 changes: 1 addition & 1 deletion fsw/src/to_lab_version.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#define TO_LAB_VERSION_H

/* Development Build Macro Definitions */
#define TO_LAB_BUILD_NUMBER 41 /*!< Development Build: Number of commits since baseline */
#define TO_LAB_BUILD_NUMBER 45 /*!< Development Build: Number of commits since baseline */
#define TO_LAB_BUILD_BASELINE \
"v2.5.0-rc4" /*!< Development Build: git tag that is the base for the current development */

Expand Down
56 changes: 40 additions & 16 deletions fsw/tables/to_lab_sub.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,37 +28,39 @@
/*
** Add the proper include file for the message IDs below
*/

/*
** Common CFS app includes below are commented out
*/
#include "to_lab_msgids.h"

#ifdef HAVE_CI_LAB
#include "ci_lab_msgids.h"
#endif

#ifdef HAVE_SAMPLE_APP
#include "sample_app_msgids.h"
#endif

#if 0
#ifdef HAVE_HS_APP
#include "hs_msgids.h"
#endif

#ifdef HAVE_FM_APP
#include "fm_msgids.h"
#endif

#ifdef HAVE_SC_APP
#include "sc_msgids.h"
#endif

#ifdef HAVE_DS_APP
#include "ds_msgids.h"
#endif

#ifdef HAVE_LC_APP
#include "lc_msgids.h"
#endif

TO_LAB_Subs_t TO_LAB_Subs = {.Subs = {/* CFS App Subscriptions */
{CFE_SB_MSGID_WRAP_VALUE(TO_LAB_HK_TLM_MID), {0, 0}, 4},
{CFE_SB_MSGID_WRAP_VALUE(TO_LAB_DATA_TYPES_MID), {0, 0}, 4},
{CFE_SB_MSGID_WRAP_VALUE(CI_LAB_HK_TLM_MID), {0, 0}, 4},
{CFE_SB_MSGID_WRAP_VALUE(SAMPLE_APP_HK_TLM_MID), {0, 0}, 4},

#if 0
/* Add these if needed */
{CFE_SB_MSGID_WRAP_VALUE(HS_HK_TLM_MID), {0,0}, 4},
{CFE_SB_MSGID_WRAP_VALUE(FM_HK_TLM_MID), {0,0}, 4},
{CFE_SB_MSGID_WRAP_VALUE(SC_HK_TLM_MID), {0,0}, 4},
{CFE_SB_MSGID_WRAP_VALUE(DS_HK_TLM_MID), {0,0}, 4},
{CFE_SB_MSGID_WRAP_VALUE(LC_HK_TLM_MID), {0,0}, 4},
#endif

/* cFE Core subscriptions */
{CFE_SB_MSGID_WRAP_VALUE(CFE_ES_HK_TLM_MID), {0, 0}, 4},
Expand All @@ -74,6 +76,28 @@ TO_LAB_Subs_t TO_LAB_Subs = {.Subs = {/* CFS App Subscriptions */
{CFE_SB_MSGID_WRAP_VALUE(CFE_ES_APP_TLM_MID), {0, 0}, 4},
{CFE_SB_MSGID_WRAP_VALUE(CFE_ES_MEMSTATS_TLM_MID), {0, 0}, 4},

#ifdef HAVE_CI_LAB
{CFE_SB_MSGID_WRAP_VALUE(CI_LAB_HK_TLM_MID), {0, 0}, 4},
#endif
#ifdef HAVE_SAMPLE_APP
{CFE_SB_MSGID_WRAP_VALUE(SAMPLE_APP_HK_TLM_MID), {0, 0}, 4},
#endif
#ifdef HAVE_HS_APP
{CFE_SB_MSGID_WRAP_VALUE(HS_HK_TLM_MID), {0, 0}, 4},
#endif
#ifdef HAVE_HS_APP
{CFE_SB_MSGID_WRAP_VALUE(FM_HK_TLM_MID), {0, 0}, 4},
#endif
#ifdef HAVE_HS_APP
{CFE_SB_MSGID_WRAP_VALUE(SC_HK_TLM_MID), {0, 0}, 4},
#endif
#ifdef HAVE_HS_APP
{CFE_SB_MSGID_WRAP_VALUE(DS_HK_TLM_MID), {0, 0}, 4},
#endif
#ifdef HAVE_HS_APP
{CFE_SB_MSGID_WRAP_VALUE(LC_HK_TLM_MID), {0, 0}, 4},
#endif

/* CFE_SB_MSGID_RESERVED entry to mark the end of valid MsgIds */
{CFE_SB_MSGID_RESERVED, {0, 0}, 0}}};

Expand Down

0 comments on commit 81d85da

Please sign in to comment.