From 3c8c213ce33d9a5c542428a8b35dd7581730697a Mon Sep 17 00:00:00 2001 From: bsongis Date: Thu, 26 Jul 2012 08:44:48 +0000 Subject: [PATCH] Issue with looping mixes (thanks Gabriel for reporting it) --- src/open9x.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/open9x.cpp b/src/open9x.cpp index bb2edd267..c93356b45 100644 --- a/src/open9x.cpp +++ b/src/open9x.cpp @@ -2041,8 +2041,8 @@ void perOut(uint8_t tick10ms) if (swTog) { sDelay[i] = md->delayUp * 50; } - if (sDelay[i]) { // perform delay - if(tick10ms) sDelay[i]-=tick10ms; + if (sDelay[i] > 0) { // perform delay + if (tick10ms) sDelay[i]-=tick10ms; if (!md->swtch) { v = -1024; } @@ -2062,8 +2062,8 @@ void perOut(uint8_t tick10ms) if (swTog) { sDelay[i] = md->delayDown * 50; } - if (sDelay[i]) { // perform delay - if(tick10ms) sDelay[i]-=tick10ms; + if (sDelay[i] > 0) { // perform delay + if (tick10ms) sDelay[i]-=tick10ms; if (!md->swtch) v = +1024; has_delay = true; }