From 9aeb80d8d06cb6bbe3e06cb8747f0cb7531df233 Mon Sep 17 00:00:00 2001 From: alanbjohnston Date: Tue, 6 Dec 2022 10:16:35 -0500 Subject: [PATCH] changed if to while in Handler0 --- cubesatsim/cubesatsim.ino | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/cubesatsim/cubesatsim.ino b/cubesatsim/cubesatsim.ino index c7f8c8be..ca668058 100644 --- a/cubesatsim/cubesatsim.ino +++ b/cubesatsim/cubesatsim.ino @@ -3658,11 +3658,12 @@ bool TimerHandler0(struct repeating_timer *t) { digitalWrite(BPSK_CONTROL_A, HIGH); // Serial.print("-"); if (mode == FSK) { - if (!i2c_busy_now2) { +// if (!i2c_busy_now2) { + while (i2c_busy_now2) { } i2c_busy_now = true; clockgen.enableOutputOnly(1); i2c_busy_now = false; - } else +// } else ;// Serial.print("-"); } } else { @@ -3672,11 +3673,12 @@ bool TimerHandler0(struct repeating_timer *t) { digitalWrite(BPSK_CONTROL_B, HIGH); // Serial.print("_"); if (mode == FSK) { - if (!i2c_busy_now2) { +// if (!i2c_busy_now2) { + while (i2c_busy_now2) { } i2c_busy_now = true; clockgen.enableOutputOnly(0); i2c_busy_now = false; - } else +// } else ;// Serial.print("-"); } }