PowerBroker2 / ArduPID

PID library for Arduinos with greater accuracy than the legacy Arduino PID library
MIT License
85 stars 23 forks source link

Update ArduPID.cpp #14

Closed DinoMesina closed 1 year ago

DinoMesina commented 1 year ago

Corrected the calculation of kd when timer.timeDiff is zero Corrected and optimized the integral calculation.

DinoMesina commented 1 year ago

Please commit the changes and update the Arduino library

PowerBroker2 commented 1 year ago

Thanks for the catch!

One day I plan to really "robustify" this library, but I likely won't have time to do so for quite a while. That also means I don't have time to really dig into your second and third blocks of edits. In the interest of time, however, I'll trust your update and merge for now.

If you or anyone else finds issue with these updates, please submit a PR or issue.