*add service data logging
This commit is contained in:
@@ -141,6 +141,9 @@ static int32_t Service_Packing(L2_INST *instPtr, L2_FRAME_TYPE type, uint8_t dst
|
|||||||
DBG_ERROR("Fail to append CRC...\n");
|
DBG_ERROR("Fail to append CRC...\n");
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
memcpy(instPtr->serviceFSM->txLog.data, buff, L2_SVC_PACK_LEN);
|
||||||
|
instPtr->serviceFSM->txLog.dataId = dataId;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
@@ -294,6 +297,10 @@ int32_t L2_Service_PktHandler(L2_INST *instPtr, uint8_t *msg)
|
|||||||
SysMonitor_UpdateRecvPayloadRaw(msg+L2_MSG_SVC_PAYLOAD, PAYLOAD_LEN_LJ_RX);
|
SysMonitor_UpdateRecvPayloadRaw(msg+L2_MSG_SVC_PAYLOAD, PAYLOAD_LEN_LJ_RX);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Logging
|
||||||
|
memcpy(instPtr->serviceFSM->rxLog.data, msg, L2_SVC_PACK_LEN);
|
||||||
|
instPtr->serviceFSM->rxLog.dataId = dataId;
|
||||||
|
|
||||||
#ifdef DATALINK_ENABLE_AUTOTIMESYNC
|
#ifdef DATALINK_ENABLE_AUTOTIMESYNC
|
||||||
// Implement a auto time sync.
|
// Implement a auto time sync.
|
||||||
|
|||||||
Reference in New Issue
Block a user