F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
Main.cpp File Reference
#include <Ref/Top/RefTopology.hpp>
#include <signal.h>
#include <getopt.h>
#include <cstdlib>
#include <Os/Os.hpp>
#include <Fw/Logger/Logger.hpp>

Go to the source code of this file.

Functions

void print_usage (const char *app)
 print commandline help message More...
 
static void signalHandler (int signum)
 shutdown topology cycling on signal More...
 
int main (int argc, char *argv[])
 execute the program More...
 

Function Documentation

◆ main()

int main ( int  argc,
char *  argv[] 
)

execute the program

This F´ program is designed to run in standard environments (e.g. Linux/macOs running on a laptop). Thus it uses command line inputs to specify how to connect.

Parameters
argcargument count supplied to program
argvargument values supplied to program
Returns
: 0 on success, something else on failure

Definition at line 57 of file Main.cpp.

◆ print_usage()

void print_usage ( const char *  app)

print commandline help message

This will print a command line help message including the available command line arguments.

Parameters
appname of application

Definition at line 31 of file Main.cpp.

◆ signalHandler()

static void signalHandler ( int  signum)
static

shutdown topology cycling on signal

The reference topology allows for a simulated cycling of the rate groups. This simulated cycling needs to be stopped in order for the program to shutdown. This is done via handling signals such that it is performed via Ctrl-C

Parameters
signum

Definition at line 43 of file Main.cpp.