forked from gatsby/df_datalink
fix: 根据第一次测试结果修改
增加节点默认速率, 接收端聆听模式写入Key, 根据PL物理层控制模块修改POLL模式控制字
This commit is contained in:
@@ -80,6 +80,7 @@ struct callback_desc apptimer_callback_desc = {
|
|||||||
// .myId = 1,
|
// .myId = 1,
|
||||||
// .headId = 1,
|
// .headId = 1,
|
||||||
// .netScale = 3,
|
// .netScale = 3,
|
||||||
|
// .serviceRate = L2_SVC_512K,
|
||||||
// .phyInstPtr = NULL, // physical layer reference
|
// .phyInstPtr = NULL, // physical layer reference
|
||||||
// .tmcInstPtr = NULL
|
// .tmcInstPtr = NULL
|
||||||
//};
|
//};
|
||||||
@@ -90,6 +91,7 @@ L2_CONFIG linkConfig = {
|
|||||||
.myId = 2,
|
.myId = 2,
|
||||||
.headId = 1,
|
.headId = 1,
|
||||||
.netScale = 10,
|
.netScale = 10,
|
||||||
|
.serviceRate = L2_SVC_512K,
|
||||||
.phyInstPtr = NULL, // physical layer reference
|
.phyInstPtr = NULL, // physical layer reference
|
||||||
.tmcInstPtr = NULL
|
.tmcInstPtr = NULL
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1120,6 +1120,10 @@ int32_t Linklayer_Proc(L2_INST *instPtr)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
Phy_SetMode(phyRef, PHY_MODE_LISTEN);
|
Phy_SetMode(phyRef, PHY_MODE_LISTEN);
|
||||||
|
|
||||||
|
// Trigger physical configuration.
|
||||||
|
// Indicate physical layer that all the configurations were done.
|
||||||
|
PhyWrite(phyRef, SLOT_CMD, SLOT_CMD_KEY);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -26,6 +26,7 @@
|
|||||||
#include "node_list.h"
|
#include "node_list.h"
|
||||||
#include "circ_queue.h"
|
#include "circ_queue.h"
|
||||||
#include "../phy_layer/phy_layer.h"
|
#include "../phy_layer/phy_layer.h"
|
||||||
|
#include "../phy_layer/phy_reg.h"
|
||||||
#include "../../system_monitor.h"
|
#include "../../system_monitor.h"
|
||||||
/************************** Constant Definitions *****************************/
|
/************************** Constant Definitions *****************************/
|
||||||
/***************** Macros (Inline Functions) Definitions *********************/
|
/***************** Macros (Inline Functions) Definitions *********************/
|
||||||
|
|||||||
@@ -48,7 +48,8 @@
|
|||||||
#define PHY_MAIN_CTRL_EN_DSBL 0x00000000U
|
#define PHY_MAIN_CTRL_EN_DSBL 0x00000000U
|
||||||
#define PHY_MAIN_CTRL_MODE_NONE 0x00000000U
|
#define PHY_MAIN_CTRL_MODE_NONE 0x00000000U
|
||||||
#define PHY_MAIN_CTRL_MODE_LISTEN 0x00000100U
|
#define PHY_MAIN_CTRL_MODE_LISTEN 0x00000100U
|
||||||
#define PHY_MAIN_CTRL_MODE_POLL 0x00000200U
|
#define PHY_MAIN_CTRL_MODE_SCHEDULE 0x00000200U // not used
|
||||||
|
#define PHY_MAIN_CTRL_MODE_POLL 0x00000300U
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Register: TXRX_CTRL
|
* Register: TXRX_CTRL
|
||||||
|
|||||||
Reference in New Issue
Block a user