2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-02-07 23:09:26 +00:00

98_GAEBUS.pm : fix handle broadcast in periodic update of readings (fix from Tomy)

git-svn-id: https://svn.fhem.de/fhem/trunk@21206 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
jamesgo 2020-02-16 09:58:49 +00:00
parent 07288c391d
commit 7f87c2dd44

View File

@ -54,6 +54,7 @@
# 09.01.2020 : A.Goebel : fix handling for valueFormat, give exact number of parameters to sprintf and shift all of them
# 16.01.2020 : A.Goebel : add ignore error messages returned by ebusd
# 05.02.2020 : A.Goebel : change substitute tilde by slash in attribute names (delimiter)
# 16.02.2020 : A.Goebel : fix also request broadcast messages periodic call (fix from Tomy)
package main;
@ -268,8 +269,9 @@ GAEBUS_Set($@)
my $type = shift @a;
my $arg = join(" ", @a);
$type =~ s,\xe2\x88\xbc,$delimiter,g;
$arg =~ s,\xe2\x88\xbc,$delimiter,g;
# UTF-8 tilde replacement
#$type =~ s,\xe2\x88\xbc,$delimiter,g;
#$arg =~ s,\xe2\x88\xbc,$delimiter,g;
#return "No $a[1] for dummies" if(IsDummy($name));
@ -547,8 +549,9 @@ GAEBUS_Get($@)
# other read commands
if (defined($a[1])) { $a[1] =~ s,\xe2\x88\xbc,$delimiter,g };
if (defined($a[2])) { $a[2] =~ s,\xe2\x88\xbc,$delimiter,g };
# UTF-8 tilde replacement
#if (defined($a[1])) { $a[1] =~ s,\xe2\x88\xbc,$delimiter,g };
#if (defined($a[2])) { $a[2] =~ s,\xe2\x88\xbc,$delimiter,g };
if ($a[1] =~ /^[ru]$delimiter/ )
{
@ -1208,8 +1211,8 @@ GAEBUS_GetUpdatesDoit($)
foreach my $oneattr (keys %{$attr{$name}})
{
# only for "r" commands
if ($oneattr =~ /^r$delimiter[^$delimiter]{1,}$delimiter.*/)
# only for "r" commands and broadcasts ("u")
if ($oneattr =~ /^[ru]$delimiter[^$delimiter]{1,}$delimiter.*/)
{
my ($readingnameX, $cmdaddon) = split (" ", $attr{$name}{$oneattr}, 2);