diff --git a/code.cpp b/code.cpp index 2911d13..7bfad5d 100644 --- a/code.cpp +++ b/code.cpp @@ -22,7 +22,7 @@ unsigned long lastUpdateTime = 0; /* * Amount of spark fires in a single interval */ -int sparkFireCount = 0; +volatile int sparkFireCount = 0; /* * Rpm value from last update @@ -123,4 +123,4 @@ void loop() { lastUpdateTime = millis(); lastRpmValue = currentRpm; } -} \ No newline at end of file +}