From 64aa417d12e0a5ae46648b5b0118b4b66b8c52c0 Mon Sep 17 00:00:00 2001 From: Stanley Huang Date: Sun, 7 Sep 2014 23:23:51 +1000 Subject: minor fix --- megalogger/megalogger.ino | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/megalogger/megalogger.ino b/megalogger/megalogger.ino index 2570444..23dee8a 100644 --- a/megalogger/megalogger.ino +++ b/megalogger/megalogger.ino @@ -141,11 +141,11 @@ public: index = 0; if (index2 == TIER_NUM2) { index2 = 0; - if (isValidPID(pidTier3[index3])) + if (isValidPID(pidTier3[index3])) { logOBDData(pidTier3[index3]); + } index3 = (index3 + 1) % TIER_NUM3; if (index3 == 0) { - // get and display voltage int v = getVoltage(); lcd.setFontSize(FONT_SIZE_SMALL); lcd.setCursor(108, 12); @@ -155,8 +155,10 @@ public: logData(PID_VOLTAGE, v); } } else { - if (isValidPID(pidTier2[index2])) - logOBDData(pidTier2[index2++]); + if (isValidPID(pidTier2[index2])) { + logOBDData(pidTier2[index2]); + } + index2++; } } -- cgit v1.2.3