Skip if datastring is to short
git-svn-id: https://fhem.svn.sourceforge.net/svnroot/fhem/trunk/fhem@1664 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
@@ -103,10 +103,14 @@ VantagePro2_GetStatus($)
|
|||||||
$tel->print("TEST");
|
$tel->print("TEST");
|
||||||
$answer=$tel->get();
|
$answer=$tel->get();
|
||||||
$tel->print("LOOP 1");
|
$tel->print("LOOP 1");
|
||||||
|
sleep(1);
|
||||||
$answer=$tel->get();
|
$answer=$tel->get();
|
||||||
$tel->close();
|
$tel->close();
|
||||||
|
|
||||||
|
# print "Debug:".length($answer)."\n";
|
||||||
|
|
||||||
|
if(length($answer)>=63)
|
||||||
|
{
|
||||||
my $offset=1;
|
my $offset=1;
|
||||||
my $t;
|
my $t;
|
||||||
my $btrend="";
|
my $btrend="";
|
||||||
@@ -326,6 +330,7 @@ VantagePro2_GetStatus($)
|
|||||||
}
|
}
|
||||||
$hash->{STATE} = $text;
|
$hash->{STATE} = $text;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return($text);
|
return($text);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user