Fix Bug to show all available toggle options

Fix Bug to show all available toggle options
This commit is contained in:
Adrian Scillato 2018-04-29 03:44:01 -03:00 committed by GitHub
parent bbf9b8432a
commit c8a2494631
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 1 deletions

View File

@ -741,9 +741,15 @@ void HandleKNXConfiguration()
page.replace(F("GAarea"), F("CB_AREA"));
page.replace(F("GAfdef"), F("CB_FDEF"));
page += FPSTR(HTTP_FORM_KNX4);
byte j;
for (byte i = 0; i < KNX_MAX_device_param ; i++)
{
if ( device_param[i].show )
// Check How many Relays are available and add: RelayX and TogleRelayX
if ( (i > 8) && (i < 16) ) { j=i-8; } else { j=i; }
if ( i == 8 ) { j = 0; }
if ( device_param[j].show )
{
page += FPSTR(HTTP_FORM_KNX_OPT);
page.replace(F("{vop}"), String(device_param[i].type));