forked from gatsby/df_datalink
feat: 增加时隙表个数, 用于支持上位机配置切换
This commit is contained in:
@@ -890,8 +890,8 @@ int32_t Linklayer_EventHandler(L2_INST *instPtr, const L2_EVENT *l2Event)
|
|||||||
else if (instPtr->nextState == L2_NORMAL_STATE)
|
else if (instPtr->nextState == L2_NORMAL_STATE)
|
||||||
{
|
{
|
||||||
UpdateMainSate(instPtr, L2_NORMAL_STATE);
|
UpdateMainSate(instPtr, L2_NORMAL_STATE);
|
||||||
instPtr->rtneConfig.rtneTable = normalTable;
|
instPtr->rtneConfig.rtneTable = normalTable[L2_DEFAULT_NORMAL_TABLE];
|
||||||
instPtr->rtneConfig.rtnePrd = ARRAY_SIZE(normalTable);
|
instPtr->rtneConfig.rtnePrd = ARRAY_SIZE(normalTable[L2_DEFAULT_NORMAL_TABLE]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -129,7 +129,7 @@ typedef struct
|
|||||||
|
|
||||||
/************************** Variable Definitions *****************************/
|
/************************** Variable Definitions *****************************/
|
||||||
extern L2_RTNE_TABLE_ENTRY *initTable[L2_INIT_RTNE_PERIOD];
|
extern L2_RTNE_TABLE_ENTRY *initTable[L2_INIT_RTNE_PERIOD];
|
||||||
extern L2_RTNE_TABLE_ENTRY *normalTable[L2_NORMAL_RTNE_PERIOD];
|
extern L2_RTNE_TABLE_ENTRY *normalTable[L2_NORMAL_RTNE_PERIOD][L2_NORMAL_RTNE_NUM];
|
||||||
/************************** Function Prototypes ******************************/
|
/************************** Function Prototypes ******************************/
|
||||||
/**
|
/**
|
||||||
* @defgroup LinkLayer_Main
|
* @defgroup LinkLayer_Main
|
||||||
|
|||||||
@@ -41,6 +41,8 @@
|
|||||||
// Routine configure
|
// Routine configure
|
||||||
#define L2_INIT_RTNE_PERIOD 1
|
#define L2_INIT_RTNE_PERIOD 1
|
||||||
#define L2_NORMAL_RTNE_PERIOD 1
|
#define L2_NORMAL_RTNE_PERIOD 1
|
||||||
|
#define L2_NORMAL_RTNE_NUM 3
|
||||||
|
#define L2_DEFAULT_NORMAL_TABLE 0
|
||||||
|
|
||||||
// Common slot number definition
|
// Common slot number definition
|
||||||
#define L2_SLOTNO_NONE 0
|
#define L2_SLOTNO_NONE 0
|
||||||
|
|||||||
@@ -305,9 +305,9 @@ L2_RTNE_TABLE_ENTRY *initTable[L2_INIT_RTNE_PERIOD] =
|
|||||||
innerScanSubT
|
innerScanSubT
|
||||||
};
|
};
|
||||||
|
|
||||||
L2_RTNE_TABLE_ENTRY *normalTable[L2_NORMAL_RTNE_PERIOD] =
|
L2_RTNE_TABLE_ENTRY *normalTable[L2_NORMAL_RTNE_NUM][L2_NORMAL_RTNE_PERIOD] =
|
||||||
{
|
{
|
||||||
innerScanSubT
|
innerScanSubT, innerScanSubT, innerScanSubT
|
||||||
};
|
};
|
||||||
|
|
||||||
/** @} RoutineTable*/
|
/** @} RoutineTable*/
|
||||||
|
|||||||
Reference in New Issue
Block a user