Fix LED driver update, so it'll keep working after initialization.

This commit is contained in:
László Monda
2017-07-14 17:40:41 +02:00
parent 3730733b73
commit 282c77c850
3 changed files with 3 additions and 3 deletions

View File

@@ -97,7 +97,7 @@ void LedSlaveDriver_Update(uint8_t ledDriverId) {
I2cAsyncWrite(ledDriverAddress, updatePwmRegistersBuffer, PWM_REGISTER_BUFFER_LENGTH); I2cAsyncWrite(ledDriverAddress, updatePwmRegistersBuffer, PWM_REGISTER_BUFFER_LENGTH);
*ledIndex += PMW_REGISTER_UPDATE_CHUNK_SIZE; *ledIndex += PMW_REGISTER_UPDATE_CHUNK_SIZE;
if (*ledIndex >= LED_DRIVER_LED_COUNT) { if (*ledIndex >= LED_DRIVER_LED_COUNT) {
ledIndex = 0; *ledIndex = 0;
} }
break; break;
} }