Skip to content

Commit

Permalink
Fix #262, Update inaccurate event ID name
Browse files Browse the repository at this point in the history
  • Loading branch information
thnkslprpt committed Jan 14, 2024
1 parent ab17422 commit 28f3925
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion fsw/inc/cf_events.h
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@
*
* Invalid message ID received on the software bus pipe
*/
#define CF_EID_ERR_INVALID_MID (28)
#define CF_MID_ERR_EID (28)

/**
* \brief CF SB Receive Buffer Failed Event ID
Expand Down
1 change: 0 additions & 1 deletion fsw/src/cf_cfdp_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,6 @@ typedef enum

/* keep last */
CF_TxnStatus_MAX = 22

} CF_TxnStatus_t;

/**
Expand Down
2 changes: 1 addition & 1 deletion fsw/src/cf_dispatch.c
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ void CF_AppPipe(const CFE_SB_Buffer_t *msg)

default:
++CF_AppData.hk.Payload.counters.err;
CFE_EVS_SendEvent(CF_EID_ERR_INVALID_MID, CFE_EVS_EventType_ERROR, "CF: invalid command packet id=0x%lx",
CFE_EVS_SendEvent(CF_MID_ERR_EID, CFE_EVS_EventType_ERROR, "CF: invalid command packet id=0x%lx",
(unsigned long)CFE_SB_MsgIdToValue(msg_id));
break;
}
Expand Down
2 changes: 1 addition & 1 deletion unit-test/cf_dispatch_tests.c
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ void Test_CF_AppPipe_UnrecognizedCommandEnterDefaultPath(void)
/* Assert */
UtAssert_UINT32_EQ(CF_AppData.hk.Payload.counters.err, 1);
UtAssert_STUB_COUNT(CFE_EVS_SendEvent, 1);
UT_CF_AssertEventID(CF_EID_ERR_INVALID_MID);
UT_CF_AssertEventID(CF_MID_ERR_EID);
}

void add_CF_ProcessGroundCommand_tests(void)
Expand Down

0 comments on commit 28f3925

Please sign in to comment.