Unify Framework Lib 1.6.0
uic_main.c File Reference
#include <stdbool.h>
#include "sl_log.h"
#include "uic_main.h"
#include "uic_init.h"
#include "uic_main_loop.h"
#include "uic_component_fixtures_internal.h"

Macros

#define LOG_TAG   "uic_main"
 

Functions

int uic_stdin_teardown ()
 
int uic_main (const uic_fixt_setup_step_t *fixt_app_setup, const uic_fixt_shutdown_step_t *fixt_app_shutdown, int argc, char **argv, const char *version)
 Run Unify/Contiki Main loop. More...
 

Macro Definition Documentation

◆ LOG_TAG

#define LOG_TAG   "uic_main"

Function Documentation

◆ uic_main()

int uic_main ( const uic_fixt_setup_step_t fixt_setup,
const uic_fixt_shutdown_step_t fixt_shutdown,
int  argc,
char **  argv,
const char *  version 
)

Run Unify/Contiki Main loop.

This function will initialize Contiki OS and loop until the program exits. It has following stages: 1) Initialize Contiki OS (Timers, Process list etc.) 2) Call all setup fixtures (loop over fixt_setup) 3) Run Contiki main loop 4) Upon shutdown call all shutdown fixtures (loop over fixt_shutdown)

Parameters
fixt_setupArray of setup fixtures to be called during init
fixt_shutdownArray of shutdown fixtures to be called on shutdown
argccommand line arguments count
argvcommand line arguments
versionVersion string to print on "--version" argument
Returns
int 0 on success, other for error

◆ uic_stdin_teardown()

int uic_stdin_teardown ( )