FSM/vscode/FSM_OOP/baseFSM/FSM_private_vars.h

64 lines
1.6 KiB
C
Raw Normal View History

/**
* @file FSM_private.h
* @author (dalaoshi@stu.xjtu.edu.cn)
* @brief 使
* @details 访
* @version 2.1
* @date 2024-05-07
*
* @copyright 2024
*
*/
#ifndef __FSM_PRIVATE_VARS_H_
#define __FSM_PRIVATE_VARS_H_
#include "FSM_protected.h"
typedef struct FSMHandler FSMHandler;
typedef struct FSM FSM;
typedef struct FSMSignals FSMSignals;
/* -------------------------------------------------------------------------- */
/* private数据类型 */
/* -------------------------------------------------------------------------- */
/**
* @brief
* @deprecated
*
*/
typedef struct FSMDataLoader
{
void *shadowData;
int isReady;
int isOverflow;
unsigned long long size;
}FSMDataLoader;
/**
* @brief 访
*
*/
typedef struct FSMPrivateVars
{
int numState; /**< 状态数量 */
int defaultState; /**< Idle状态不能停留必须指定一个初始状态 */
int curState; /**< 当前状态 */
int nextState; /**< nextState为Idle代表状态机不发生变化 */
int index; /**< 状态转移函数表对应的标号 */
FSMHandler fcns; /**< 状态函数表 */
// FSM *childFSM; /**< 限定只能有一个子状态机 */
FSM **childFSMTable; /**< 每个状态都可配置一个子状态机 */
FSMDataLoader preloader; /**< @deprecated 弃用 */
}FSMPrivateVars;
#endif