Browse Source

lights: fix my92xx channel setup

mcspr-patch-1
Maxim Prokhorov 3 years ago
parent
commit
1fa10cd7cf
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      code/espurna/light.cpp

+ 3
- 1
code/espurna/light.cpp View File

@ -1950,7 +1950,9 @@ void lightSetup() {
#if LIGHT_PROVIDER == LIGHT_PROVIDER_MY92XX #if LIGHT_PROVIDER == LIGHT_PROVIDER_MY92XX
_my92xx = new my92xx(MY92XX_MODEL, MY92XX_CHIPS, MY92XX_DI_PIN, MY92XX_DCKI_PIN, MY92XX_COMMAND); _my92xx = new my92xx(MY92XX_MODEL, MY92XX_CHIPS, MY92XX_DI_PIN, MY92XX_DCKI_PIN, MY92XX_COMMAND);
_light_channels.resize(std::min(Light::Channels, Light::ChannelsMax));
for (unsigned char index = 0; index < Light::Channels; ++index) {
_light_channels.emplace_back(GPIO_NONE, getSetting({"ltMy92xxInv", index}, _lightInverse(index)));
}
#elif LIGHT_PROVIDER == LIGHT_PROVIDER_DIMMER #elif LIGHT_PROVIDER == LIGHT_PROVIDER_DIMMER


Loading…
Cancel
Save