fix scripter USE_SCRIPT_GLOBVARS without USE_DEVICE_GROUPS

This commit is contained in:
gemu2015 2020-06-29 10:48:24 +02:00
parent 04dca1e61f
commit bc1f91041c
1 changed files with 8 additions and 0 deletions

View File

@ -383,6 +383,14 @@ struct SCRIPT_MEM {
#ifdef USE_SCRIPT_GLOBVARS
IPAddress last_udp_ip;
WiFiUDP Script_PortUdp;
#ifndef USE_DEVICE_GROUPS
char * IPAddressToString(const IPAddress& ip_address) {
static char buffer[16];
sprintf_P(buffer, PSTR("%u.%u.%u.%u"), ip_address[0], ip_address[1], ip_address[2], ip_address[3]);
return buffer;
}
#endif
#endif
int16_t last_findex;