Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Function prototypes can be moved out of to_lab_app.c #157

Closed
2 tasks done
thnkslprpt opened this issue May 2, 2023 · 0 comments · Fixed by #158
Closed
2 tasks done

Function prototypes can be moved out of to_lab_app.c #157

thnkslprpt opened this issue May 2, 2023 · 0 comments · Fixed by #158

Comments

@thnkslprpt
Copy link
Contributor

Checklist

  • I reviewed the Contributing Guide.
  • I performed a cursory search to see if the bug report is relevant, not redundant, nor in conflict with other tickets.

Describe the bug
These prototypes can/should be moved out of to_lab_app.c into the header file, along with the global data struct definition.

Code snips

typedef struct
{
CFE_SB_PipeId_t Tlm_pipe;
CFE_SB_PipeId_t Cmd_pipe;
osal_id_t TLMsockid;
bool downlink_on;
char tlm_dest_IP[17];
bool suppress_sendto;
TO_LAB_HkTlm_t HkTlm;
TO_LAB_DataTypesTlm_t DataTypesTlm;
} TO_LAB_GlobalData_t;
TO_LAB_GlobalData_t TO_LAB_Global;
TO_LAB_Subs_t * TO_LAB_Subs;
CFE_TBL_Handle_t TO_SubTblHandle;
/*
** Prototypes Section
*/
void TO_LAB_openTLM(void);
int32 TO_LAB_init(void);
void TO_LAB_exec_local_command(CFE_SB_Buffer_t *SBBufPtr);
void TO_LAB_process_commands(void);
void TO_LAB_forward_telemetry(void);
/*
* Individual Command Handler prototypes
*/
int32 TO_LAB_AddPacket(const TO_LAB_AddPacketCmd_t *data);
int32 TO_LAB_Noop(const TO_LAB_NoopCmd_t *data);
int32 TO_LAB_EnableOutput(const TO_LAB_EnableOutputCmd_t *data);
int32 TO_LAB_RemoveAll(const TO_LAB_RemoveAllCmd_t *data);
int32 TO_LAB_RemovePacket(const TO_LAB_RemovePacketCmd_t *data);
int32 TO_LAB_ResetCounters(const TO_LAB_ResetCountersCmd_t *data);
int32 TO_LAB_SendDataTypes(const TO_LAB_SendDataTypesCmd_t *data);
int32 TO_LAB_SendHousekeeping(const CFE_MSG_CommandHeader_t *data);

Expected behavior
Consistent content of implementation/header files across cFS.

Reporter Info
Avi Weiss @thnkslprpt

dzbaker added a commit that referenced this issue Nov 13, 2023
…ader-file

Fix #157, Move function prototypes to header file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant