From 2f66deb7edbca2181580ebda6059fcad0c4e3cb0 Mon Sep 17 00:00:00 2001 From: Ruige Lee Date: Mon, 26 May 2025 19:05:15 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=8C=E6=AD=A5=E5=8C=85=E6=9B=B4=E6=96=B0?= =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E8=AE=A1=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../scala/backBoard/shin/SlaveParser.scala | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/main/scala/backBoard/shin/SlaveParser.scala b/src/main/scala/backBoard/shin/SlaveParser.scala index 20ed09a..d9964f8 100644 --- a/src/main/scala/backBoard/shin/SlaveParser.scala +++ b/src/main/scala/backBoard/shin/SlaveParser.scala @@ -593,6 +593,24 @@ trait SlaveParserRW{ this: SlaveParserBase => trait SlaveParserSync{ this: SlaveParserBase => + //下行接收 + when( downRecParser.io.subMsgReq.fire ){ + when( isDownRecPing ){ + //override + when( downRecParser.io.subMsgReq.bits.operator === SUBMSG_OPERATOR_SYNC ) { //同步包 + downSubMsgInfo(0).workCnt := downRecParser.io.subMsgReq.bits.workCnt + 1.U + } + + } .otherwise{ //pong + //override + when( downRecParser.io.subMsgReq.bits.operator === SUBMSG_OPERATOR_SYNC ) { //同步包 ) + downSubMsgInfo(1).workCnt := downRecParser.io.subMsgReq.bits.workCnt + 1.U + } + } + } + + + val downTimeStamp = Reg(UInt(64.W)) //下行本地时间戳寄存器 val upTimeStamp = Reg(UInt(64.W)) //上行本地时间戳寄存器 val mstTimeStamp = Reg(UInt(64.W)) //主站时间戳