00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00040 enum DBG_DISP_ENUM
00041 {
00042 ALLOC_DBG = 1,
00043 DEALLOC_DBG = 2,
00044 REALLOC_DBG = 4,
00045 TRAN_LOOKING_DBG = 8,
00046 STATE_WORK_DBG = 16,
00047 STATE_OPT_DBG = 32,
00048 STATE_E_WORK_DBG = 64
00049 };
00050
00058 typedef struct {} StateMachine;
00066 typedef struct {} State;
00074 typedef struct {} ParallelState;
00075
00090 State* allocateState(void* parent, const char* name, StateMachine* stateMachine);
00102 StateMachine* allocStateMachine(const char* name, const char* dbgPref);
00115 ParallelState* allocateParallelState(void* parent, unsigned short int nbChildStates, StateMachine* stateMachine, const char* name);
00121 void freeStateMachine(StateMachine* stateMachine);
00133 void makeDefault1(State* state);
00142 unsigned char makeHistoryStateDefault(State* state, State* initialChild);
00152 void setEntryWork(State* state, void (*onEnter) (void));
00162 void setExitWork(State* state, void (*onExit) (void));
00178 void allocateSpaceForStates(void* ptr, unsigned short int nbStates);
00194 void allocateSpaceForTransitions(State* state, unsigned short int nbTransition);
00208 unsigned char addTransition(State *from, void *to, short int eventNum, unsigned char useHistory);
00220 unsigned char startStateMachine(StateMachine* stateMachine);
00229 void sendEvent(StateMachine* stateMachine, short int event);
00242 void setDbgParam(StateMachine* stateMachine, unsigned short int verboseFlag);
00250 void rmDbgParam(StateMachine* stateMachine, unsigned short int verboseFlag);
00260 void displayStateMachine1(StateMachine* stateMachine);
00270 void displayStateMachine2(StateMachine* stateMachine);
00278 short int isConnected(State* from, State* to);
00287 void displayCurrStateName(StateMachine* stateMachine);