Erick / Mbed 2 deprecated ICE_BLE_TEST

Dependencies:   NaturalTinyShell_ice libmDot-12Sept mbed-rtos mbed

Fork of ICE by Erick

inc/global.h

Committer:
jmarkel44
Date:
2016-09-01
Revision:
2:da28f21b72a1
Parent:
0:65cfa4873284
Child:
3:8ea4db957749

File content as of revision 2:da28f21b72a1:

/******************************************************************************
 * 
 * File:                global.h
 * Desciption:          global data 
 *
 *****************************************************************************/
#ifndef GLOBAL_H
#define GLOBAL_H

#include "mbed.h"
#include "rtos.h"
#include "ntshell.h"

//#define SUPPRESS_OUTPUT 

extern int sig_continue;

typedef enum action_tag {
    ACTION_CREATE,
    ACTION_MODIFY,
    ACTION_DESTROY
} Action_t;

typedef enum control_tag {
    CONTROL_TIMER       = 0,
    CONTROL_PID         = 1,
    CONTROL_SETPOINT    = 2,
    CONTROL_COMPOSITE   = 3,
    CONTROL_MANUAL      = 4
} Control_t;


// message data type
typedef struct message_tag {
    Action_t        action;
    Control_t       control;
    char            controlFile[32];
} Message_t;

extern Mail<Message_t, 16> MailBox;

extern ntshell_t ntshell;

extern int  func_read(char *buf, int cnt);
extern int  func_write(const char *buf, int cnt);
extern int  func_cb_ntshell(const char *text);
extern void func_cb_ntopt(int argc, char **argv);

#endif