I want to ask a question regarding the following code:
ack_tx_ts = get_tx_timestamp_u64(); // ACK transmission timestamp
uint32_t tx_time1 = dwt_readsystimestamphi32();
tx_time1 += (RX_TIMEOUT_MS * UUS_TO_DWT_TIME);
dwt_setdelayedtrxtime(tx_time1);
In my project, the total number of nodes is 4. If any one device does not respond, the system correctly shows the distances for the remaining 3 devices.
However, if 2 devices fail to respond, the distance output becomes corrupted — I suspect it may be due to a timestamp issue.
Example output:
322 ms 18 0.000 m22 0.000 m26 0.000 m 30 145470.302 m
In this case, only one device (ID: 30) was active, but the result is clearly incorrect.