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,
|
||||
// .headId = 1,
|
||||
// .netScale = 3,
|
||||
// .serviceRate = L2_SVC_512K,
|
||||
// .phyInstPtr = NULL, // physical layer reference
|
||||
// .tmcInstPtr = NULL
|
||||
//};
|
||||
@@ -90,6 +91,7 @@ L2_CONFIG linkConfig = {
|
||||
.myId = 2,
|
||||
.headId = 1,
|
||||
.netScale = 10,
|
||||
.serviceRate = L2_SVC_512K,
|
||||
.phyInstPtr = NULL, // physical layer reference
|
||||
.tmcInstPtr = NULL
|
||||
};
|
||||
|
||||
@@ -1120,6 +1120,10 @@ int32_t Linklayer_Proc(L2_INST *instPtr)
|
||||
else
|
||||
{
|
||||
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 "circ_queue.h"
|
||||
#include "../phy_layer/phy_layer.h"
|
||||
#include "../phy_layer/phy_reg.h"
|
||||
#include "../../system_monitor.h"
|
||||
/************************** Constant Definitions *****************************/
|
||||
/***************** Macros (Inline Functions) Definitions *********************/
|
||||
|
||||
@@ -48,7 +48,8 @@
|
||||
#define PHY_MAIN_CTRL_EN_DSBL 0x00000000U
|
||||
#define PHY_MAIN_CTRL_MODE_NONE 0x00000000U
|
||||
#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
|
||||
|
||||
Reference in New Issue
Block a user