Teonet library  0.4.7
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
teoackm.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "ev_mgr.h"
#include "tr-udp_stat.h"

Macros

#define TACKM_VERSION   "0.0.2"
 
#define CMD_U_STAT   "stat"
 
#define CMD_U_RESET   "reset"
 
#define CMD_U_DATA_OR_STAT   "data_or_stat"
 
#define SERVER_NAME   "none"
 

Enumerations

enum  { STATE_NONE, STATE_WAIT_KEY, STATE_WAIT_STRING }
 Application states. More...
 

Functions

void event_cb (ksnetEvMgrClass *ke, ksnetEvMgrEvents event, void *data, size_t data_len, void *user_data)
 Teonet Events callback. More...
 
int main (int argc, char **argv)
 Main Teoackm application function. More...
 

Variables

const char * PRESS_A = "(Press A to return to main application menu)"
 
int show_data_or_statistic_at_server = 1
 
enum { ... }  state
 Application states. More...
 
int app_state = STATE_NONE
 Application state. More...
 

Detailed Description

Macro Definition Documentation

#define CMD_U_DATA_OR_STAT   "data_or_stat"
Examples:
teoackm.c.

Referenced by event_cb().

#define CMD_U_RESET   "reset"
#define CMD_U_STAT   "stat"
Examples:
teoackm.c.

Referenced by event_cb().

#define SERVER_NAME   "none"
Examples:
teoackm.c.

Referenced by event_cb().

#define TACKM_VERSION   "0.0.2"
Examples:
teoackm.c.

Referenced by main().

Enumeration Type Documentation

anonymous enum

Application states.

Enumerator
STATE_NONE 
STATE_WAIT_KEY 
STATE_WAIT_STRING 

Function Documentation

int main ( int  argc,
char **  argv 
)

Main Teoackm application function.

Parameters
argcNumber of parameters
argvParameters array
Returns
EXIT_SUCCESS
Examples:
teoackm.c.

References ksnetEvMgrAppParam::app_argc, ksnetEvMgrAppParam::app_argv, ksnetEvMgrAppParam::app_descr, APP_PARAM, event_cb(), ke, ksnetAllowAckEvent(), ksnetEvMgrInitPort(), ksnetEvMgrRun(), ksnetEvMgrSetCustomTimer(), READ_CONFIGURATION, READ_OPTIONS, TACKM_VERSION, and VERSION.

Variable Documentation

int app_state = STATE_NONE

Application state.

Examples:
teoackm.c.

Referenced by event_cb().

const char* PRESS_A = "(Press A to return to main application menu)"
Examples:
teoackm.c.

Referenced by event_cb().

int show_data_or_statistic_at_server = 1
Examples:
teoackm.c.

Referenced by event_cb().

enum { ... } state