Closed p-jean closed 10 months ago
This isn't an issue.
Hi @PaulWieland Although probably not hit, his (base-)point is still valid. That is: millis() returns an "unsigned long" which is 32 bits (definitely is on Arduinos) while uint8_t is an unsigned 8-bit integer.
It's not a bad idea to define txDelayLen (and any other variable that is working with/against millis() as "unsigned long" similar to this recent commit in the homekit firmware.
In transmit(), if millis() is nearly the same as lastRX, then the value of txDelayLen will be smaller than expected due to wrap-around with the uint8_t type.