Hello there!
See my code below. I compiled it with IDE 1.8.0.
The problem is, that it likes to lock up/freeze the microcontroller. I could not find the specific circumstances when it happens, but generally it happens when cruiseOn is true, and the difference between speed and seedSet is greater then 10 (so the PID would have to correct the the difference).
What I've tried up to this point:
- Not using Strings - Doesn't make a difference
- Not using Serial and Strings - doesn't make a difference
- qualifying as Volatile those variables which are modified inside the interrupt routines - Doens't work
- using the watchdog to reset - works, still not a solution
- using IDE 1.6.9 to compile - works
Any ideas what might be causing the problem with 1.8.0?
Thanks!
jan-7.ino (6.83 KB)