From 75b715f8af127a95a79f7ecc9d19b93dd2527ba0 Mon Sep 17 00:00:00 2001 From: TMRh20 Date: Sat, 2 Mar 2024 10:11:21 -0600 Subject: [PATCH 1/2] Add delay to example #949 - Add delay to relax how often available() is called to let the radio internally do its thing --- examples/ManualAcknowledgements/ManualAcknowledgements.ino | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/ManualAcknowledgements/ManualAcknowledgements.ino b/examples/ManualAcknowledgements/ManualAcknowledgements.ino index c91017fc..148ffecb 100644 --- a/examples/ManualAcknowledgements/ManualAcknowledgements.ino +++ b/examples/ManualAcknowledgements/ManualAcknowledgements.ino @@ -129,6 +129,7 @@ void loop() { while (!radio.available()) { // wait for response if (millis() - start_timeout > 200) // only wait 200 ms break; + delayMicroseconds(200); // relax probing of available() } unsigned long end_timer = micros(); // end the timer radio.stopListening(); // put back in TX mode From 49775c26bd3029304bf8a14f0d14d1582de054bc Mon Sep 17 00:00:00 2001 From: TMRh20 Date: Sat, 2 Mar 2024 10:15:02 -0600 Subject: [PATCH 2/2] Update examples/ManualAcknowledgements/ManualAcknowledgements.ino Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- examples/ManualAcknowledgements/ManualAcknowledgements.ino | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/ManualAcknowledgements/ManualAcknowledgements.ino b/examples/ManualAcknowledgements/ManualAcknowledgements.ino index 148ffecb..90612a8c 100644 --- a/examples/ManualAcknowledgements/ManualAcknowledgements.ino +++ b/examples/ManualAcknowledgements/ManualAcknowledgements.ino @@ -129,7 +129,7 @@ void loop() { while (!radio.available()) { // wait for response if (millis() - start_timeout > 200) // only wait 200 ms break; - delayMicroseconds(200); // relax probing of available() + delayMicroseconds(200); // relax probing of available() } unsigned long end_timer = micros(); // end the timer radio.stopListening(); // put back in TX mode