From 2b79243b11eb8f55b88c8a6b0da0cc4c4209738c Mon Sep 17 00:00:00 2001 From: Jacob Hageman Date: Mon, 9 May 2022 15:29:26 -0600 Subject: [PATCH] Fix #24, Resolve strict cppcheck style warnings --- fsw/src/sc_atsrq.h | 28 ++++++++++++++-------------- fsw/src/sc_cmds.h | 20 ++++++++++---------- fsw/src/sc_loads.h | 8 ++++---- 3 files changed, 28 insertions(+), 28 deletions(-) diff --git a/fsw/src/sc_atsrq.h b/fsw/src/sc_atsrq.h index 9369566..3bec7c1 100644 --- a/fsw/src/sc_atsrq.h +++ b/fsw/src/sc_atsrq.h @@ -37,14 +37,14 @@ * \par Assumptions, External Events, and Notes: * None * - * \param[in] AtsId The Ats to begin + * \param[in] AtsIndex The Ats to begin * \param[in] TimeOffset Where to start in the ATS * * \return Boolean execution status * \retval true ATS was started * \retval false ATS was NOT started */ -bool SC_BeginAts(uint16 AtsId, uint16 TimeOffset); +bool SC_BeginAts(uint16 AtsIndex, uint16 TimeOffset); /** * \brief Start an ATS Command @@ -59,11 +59,11 @@ bool SC_BeginAts(uint16 AtsId, uint16 TimeOffset); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_START_ATS_CC */ -void SC_StartAtsCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_StartAtsCmd(const CFE_SB_Buffer_t *BufPtr); /** * \brief Stop the executing ATS Command @@ -76,11 +76,11 @@ void SC_StartAtsCmd(const CFE_SB_Buffer_t *CmdPacket); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_STOP_ATS_CC */ -void SC_StopAtsCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_StopAtsCmd(const CFE_SB_Buffer_t *BufPtr); /** * \brief Stops an ATS & clears out data @@ -110,11 +110,11 @@ void SC_KillAts(void); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_SWITCH_ATS_CC */ -void SC_GroundSwitchCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_GroundSwitchCmd(const CFE_SB_Buffer_t *BufPtr); /** * \brief @@ -180,11 +180,11 @@ void SC_ServiceSwitchPend(void); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_JUMP_ATS_CC */ -void SC_JumpAtsCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_JumpAtsCmd(const CFE_SB_Buffer_t *BufPtr); /** * \brief Lets an ATS continue if a command failed the checksum @@ -196,11 +196,11 @@ void SC_JumpAtsCmd(const CFE_SB_Buffer_t *CmdPacket); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_CONTINUE_ATS_ON_FAILURE_CC */ -void SC_ContinueAtsOnFailureCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_ContinueAtsOnFailureCmd(const CFE_SB_Buffer_t *BufPtr); /** * \brief Append to an ATS Command @@ -215,10 +215,10 @@ void SC_ContinueAtsOnFailureCmd(const CFE_SB_Buffer_t *CmdPacket); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_APPEND_ATS_CC */ -void SC_AppendAtsCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_AppendAtsCmd(const CFE_SB_Buffer_t *BufPtr); #endif diff --git a/fsw/src/sc_cmds.h b/fsw/src/sc_cmds.h index 3b14751..ad8be14 100644 --- a/fsw/src/sc_cmds.h +++ b/fsw/src/sc_cmds.h @@ -40,11 +40,11 @@ * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_MANAGE_TABLE_CC */ -void SC_TableManageCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_TableManageCmd(const CFE_SB_Buffer_t *BufPtr); /** * \brief Manage pending update to an RTS table @@ -112,9 +112,9 @@ void SC_ManageAppendTable(void); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer */ -void SC_ProcessRequest(const CFE_SB_Buffer_t *CmdPacket); +void SC_ProcessRequest(const CFE_SB_Buffer_t *BufPtr); /** * \brief Processes commands @@ -126,9 +126,9 @@ void SC_ProcessRequest(const CFE_SB_Buffer_t *CmdPacket); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer */ -void SC_ProcessCommand(const CFE_SB_Buffer_t *CmdPacket); +void SC_ProcessCommand(const CFE_SB_Buffer_t *BufPtr); /** * \brief Sends out an Event message @@ -139,11 +139,11 @@ void SC_ProcessCommand(const CFE_SB_Buffer_t *CmdPacket); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_NOOP_CC */ -void SC_NoOpCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_NoOpCmd(const CFE_SB_Buffer_t *BufPtr); /** * \brief Reset Counters Command @@ -154,11 +154,11 @@ void SC_NoOpCmd(const CFE_SB_Buffer_t *CmdPacket); * \par Assumptions, External Events, and Notes: * None * - * \param[in] CmdPacket Pointer to Software Bus buffer + * \param[in] BufPtr Pointer to Software Bus buffer * * \sa #SC_RESET_COUNTERS_CC */ -void SC_ResetCountersCmd(const CFE_SB_Buffer_t *CmdPacket); +void SC_ResetCountersCmd(const CFE_SB_Buffer_t *BufPtr); /** * \brief Send Hk Packet to the ground diff --git a/fsw/src/sc_loads.h b/fsw/src/sc_loads.h index a4d1940..fc7db56 100644 --- a/fsw/src/sc_loads.h +++ b/fsw/src/sc_loads.h @@ -38,13 +38,13 @@ * \par Assumptions, External Events, and Notes: * None * - * \param [in] Buffer A pointer to the area to validate + * \param [in] Buffer32 Pointer to the area to validate * * \return Boolean RTS valid status * \retval true RTS was valid * \retval false RTS was NOT valid */ -bool SC_ParseRts(uint32 Buffer[]); +bool SC_ParseRts(uint32 Buffer32[]); /** * \brief Buids the Time index buffer for the ATS @@ -107,7 +107,7 @@ void SC_InitAtsTables(uint16 AtsIndex); * \retval #CFE_SUCCESS Table validation success * \retval #SC_ERROR Table not valid */ -int32 SC_VerifyAtsTable(uint32 *Buffer, int32 BufferWords); +int32 SC_VerifyAtsTable(uint32 *Buffer32, int32 BufferWords); /** * \brief Validation function for a single ATS or Append ATS table entry @@ -123,7 +123,7 @@ int32 SC_VerifyAtsTable(uint32 *Buffer, int32 BufferWords); * \retval #CFE_SUCCESS Empty entry * \retval #SC_ERROR Entry is invalid */ -int32 SC_VerifyAtsEntry(uint32 *Buffer, int32 EntryIndex, int32 BufferWords); +int32 SC_VerifyAtsEntry(uint32 *Buffer32, int32 EntryIndex, int32 BufferWords); /** * \brief Loads an ATS into the data structures in SC