Skip to content

Commit

Permalink
#315 Corrected logging of useful data rate
Browse files Browse the repository at this point in the history
  • Loading branch information
krichardsson committed May 11, 2018
1 parent 1a08af4 commit 3aba2d5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/deck/drivers/src/lpsTdoa3Tag.c
Original file line number Diff line number Diff line change
Expand Up @@ -548,7 +548,6 @@ static bool findSuitableAnchor(anchorInfo_t** otherAnchorCtx, const anchorInfo_t
if (candidateAnchorCtx) {
if (seqNr[i] == historyGetSeqNr(candidateAnchorCtx) && historyGetTimeOfFlight(anchorCtx, candidateAnchorId)) {
*otherAnchorCtx = candidateAnchorCtx;
stats.suitableDataFound++;
return true;
}
}
Expand Down Expand Up @@ -608,6 +607,7 @@ static bool rxcallback(dwDevice_t *dev) {

anchorInfo_t* otherAnchorCtx = 0;
if (findSuitableAnchor(&otherAnchorCtx, anchorCtx)) {
stats.suitableDataFound++;
float tdoaDistDiff = calcDistanceDiff(otherAnchorCtx, anchorCtx, packet, &arrival);
enqueueTDOA(otherAnchorCtx, anchorCtx, tdoaDistDiff);
}
Expand Down Expand Up @@ -700,13 +700,13 @@ uwbAlgorithm_t uwbTdoa3TagAlgorithm = {
LOG_GROUP_START(tdoa3)
LOG_ADD(LOG_UINT16, stRx, &stats.packetsReceivedRate)
LOG_ADD(LOG_UINT16, stEst, &stats.packetsToEstimatorRate)
LOG_ADD(LOG_UINT16, stFound, &stats.suitableDataFoundRate)

LOG_ADD(LOG_UINT16, stCc, &stats.clockCorrectionRate)

LOG_ADD(LOG_UINT16, stHit, &stats.contextHitRate)
LOG_ADD(LOG_UINT16, stMiss, &stats.contextMissRate)

LOG_ADD(LOG_UINT16, stFound, &stats.suitableDataFound)

LOG_ADD(LOG_FLOAT, cc, &stats.clockCorrection)
LOG_ADD(LOG_UINT16, tof, &stats.tof)

Expand Down

0 comments on commit 3aba2d5

Please sign in to comment.