CTS-SAT-1-OBC-Firmware
Loading...
Searching...
No Matches
testing_telecommand_defs.c File Reference
#include "telecommand_exec/telecommand_definitions.h"
#include "telecommand_exec/telecommand_args_helpers.h"
#include "telecommands/testing_telecommand_defs.h"
#include "debug_tools/debug_uart.h"
#include "unit_tests/unit_test_executor.h"
#include <stdio.h>
#include <inttypes.h>
#include <string.h>
Include dependency graph for testing_telecommand_defs.c:

Functions

uint8_t TCMDEXEC_echo_back_args (const char *args_str, char *response_output_buf, uint16_t response_output_buf_len)
 A demo telecommand that echoes back the argument it received.
 
uint8_t TCMDEXEC_echo_back_uint32_args (const char *args_str, char *response_output_buf, uint16_t response_output_buf_len)
 A demo telecommand that echoes back each integer argument it received.
 
uint8_t TCMDEXEC_run_all_unit_tests (const char *args_str, char *response_output_buf, uint16_t response_output_buf_len)
 
uint8_t TCMDEXEC_demo_blocking_delay (const char *args_str, char *response_output_buf, uint16_t response_output_buf_len)
 Delay for a specified number of milliseconds, for testing purposes.
 

Function Documentation

◆ TCMDEXEC_demo_blocking_delay()

uint8_t TCMDEXEC_demo_blocking_delay ( const char * args_str,
char * response_output_buf,
uint16_t response_output_buf_len )

Delay for a specified number of milliseconds, for testing purposes.

Parameters
args_str1 argument: delay_ms (uint64_t)
  • Arg 0: delay_ms (uint64_t) - The number of milliseconds to delay for. <=300_000ms.
Returns
0 on success, 1 on error
Note
This is most useful for testing/triggering the watchdog timer.
Here is the call graph for this function:

◆ TCMDEXEC_echo_back_args()

uint8_t TCMDEXEC_echo_back_args ( const char * args_str,
char * response_output_buf,
uint16_t response_output_buf_len )

A demo telecommand that echoes back the argument it received.

Parameters
args_str
  • Arg 0: The string to echo back.

◆ TCMDEXEC_echo_back_uint32_args()

uint8_t TCMDEXEC_echo_back_uint32_args ( const char * args_str,
char * response_output_buf,
uint16_t response_output_buf_len )

A demo telecommand that echoes back each integer argument it received.

Parameters
args_str3 integer arguments to echo back.
  • Arg 0: The first integer to echo back.
  • Arg 1: The second integer to echo back.
  • Arg 2: The third integer to echo back.
Returns
0 if all ints are parsed successfully, otherwise the error code of the first failed parse.
Here is the call graph for this function:

◆ TCMDEXEC_run_all_unit_tests()

uint8_t TCMDEXEC_run_all_unit_tests ( const char * args_str,
char * response_output_buf,
uint16_t response_output_buf_len )
Here is the call graph for this function: