Skip to content

Commit db23aa0

Browse files
committed
Remove TX duration debug logging
_tx_start_ms and TX duration logging were added for 4-second airtime verification and are no longer needed.
1 parent 4867d36 commit db23aa0

2 files changed

Lines changed: 1 addition & 4 deletions

File tree

src/helpers/radiolib/RadioLibWrappers.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,6 @@ uint32_t RadioLibWrapper::getEstAirtimeFor(int len_bytes) {
145145

146146
bool RadioLibWrapper::startSendRaw(const uint8_t* bytes, int len) {
147147
_board->onBeforeTransmit();
148-
_tx_start_ms = millis(); // recording TX time
149148
int err = _radio->startTransmit((uint8_t *) bytes, len);
150149
if (err == RADIOLIB_ERR_NONE) {
151150
state = STATE_TX_WAIT;
@@ -161,8 +160,6 @@ bool RadioLibWrapper::isSendComplete() {
161160
if (state & STATE_INT_READY) {
162161
state = STATE_IDLE;
163162
n_sent++;
164-
uint32_t tx_duration = millis() - _tx_start_ms;
165-
MESH_DEBUG_PRINTLN("TX duration: %lu ms (len=%d)", tx_duration);
166163
return true;
167164
}
168165
return false;

src/helpers/radiolib/RadioLibWrappers.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class RadioLibWrapper : public mesh::Radio {
77
protected:
88
PhysicalLayer* _radio;
99
mesh::MainBoard* _board;
10-
uint32_t n_recv, n_sent, n_recv_errors, _tx_start_ms;
10+
uint32_t n_recv, n_sent, n_recv_errors;
1111
int16_t _noise_floor, _threshold;
1212
uint8_t _busy_count; // consecutive busy detections for exponential backoff
1313
uint16_t _num_floor_samples;

0 commit comments

Comments
 (0)