Add HM330x Particle Sensor Support #5

Merged
seiichiro merged 5 commits from hm330x into master 2021-05-02 15:11:49 +00:00
Showing only changes of commit 6c67032ef2 - Show all commits

View file

@ -80,7 +80,7 @@ bool HM330x::sendCmd(uint8_t cmd) {
// Calculate CRC8
uint8_t HM330x::calcSum(uint8_t bytes[]) {
uint8_t crc8;
uint8_t crc8 = 0;
for (int i = 0; i < HM330x_DATA_LEN - 1; i++) {
crc8 += bytes[i];
}