上行转发写入正确

This commit is contained in:
Ruige Lee
2025-04-14 17:53:04 +08:00
parent 95b7f7b476
commit 80739a1feb
2 changed files with 239 additions and 110 deletions

View File

@@ -329,10 +329,12 @@ abstract class SlaveParserBase extends Module{
io.sram_r.dataw := 0.U
io.sram_r.enr :=
upRecParser.io.stateNext === STATE_PAYLOAD_DATA
// ( isUpRecPing & upSubMsgInfo(0).devIndex === localDevIndex & (upSubMsgInfo(0).operator === 1.U | upSubMsgInfo(0).operator === 3.U)) |
// (~isUpRecPing & upSubMsgInfo(1).devIndex === localDevIndex & (upSubMsgInfo(1).operator === 1.U | upSubMsgInfo(1).operator === 3.U))
io.sram_r.addr := addrr
io.sram_r.addr := Mux1H(Seq(
( upRecParser.io.stateCurr === STATE_PAYLOAD_WORKCNT ) -> upRecParser.io.subMsgReq.bits.address,
( upRecParser.io.stateCurr === STATE_PAYLOAD_DATA ) -> addrr,
))
//子报文下行发送