Added Support for ButtonN and SwitchN

This commit is contained in:
Adrian Scillato 2018-12-01 16:26:15 -03:00 committed by GitHub
parent 2367834a64
commit 98a2e6e175
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 0 deletions

View File

@ -483,6 +483,14 @@ void KNX_INIT(void)
{
if (GetUsedInModule(i, my_module.gp.io)) { device_param[i - GPIO_KEY1 + 8].show = true; }
}
for (int i = GPIO_SWT1_NP; i < GPIO_SWT4_NP + 1; ++i)
{
if (GetUsedInModule(i, my_module.gp.io)) { device_param[i - GPIO_SWT1_NP + 8].show = true; }
}
for (int i = GPIO_KEY1_NP; i < GPIO_KEY4_NP + 1; ++i)
{
if (GetUsedInModule(i, my_module.gp.io)) { device_param[i - GPIO_KEY1_NP + 8].show = true; }
}
if (GetUsedInModule(GPIO_DHT11, my_module.gp.io)) { device_param[KNX_TEMPERATURE-1].show = true; }
if (GetUsedInModule(GPIO_DHT22, my_module.gp.io)) { device_param[KNX_TEMPERATURE-1].show = true; }
if (GetUsedInModule(GPIO_SI7021, my_module.gp.io)) { device_param[KNX_TEMPERATURE-1].show = true; }