wizard97 / ArduinoProcessScheduler

An Arduino object oriented process scheduler designed to replace them all
46 stars 16 forks source link

_period variable an unsigned int instead of uint32_t #18

Closed carmex closed 3 years ago

carmex commented 3 years ago

In Process.h, _period is defined as an unsigned int (line 326), and getPeriod() also returns an unsigned int (line 71). It should be a uint32_t, as that's what's taken in by setPeriod. On a lot of platforms an unsigned int is only going to be 16 bits and even going to a period of SERVICE_HOURLY results in an overflow so the process runs much more often than expected.

wizard97 commented 3 years ago

Thanks for pointing this out. Feel free to submit a pull request if you were able to fix this.

thijstriemstra commented 3 years ago

@carmex and @wizard97 see #20