add check missing perl modul SSL
This commit is contained in:
parent
814361b318
commit
82c8667e2c
@ -61,10 +61,11 @@ use Data::Dumper; #debugging
|
||||
|
||||
eval "use Encode qw(encode encode_utf8 decode_utf8);1" or $missingModul .= "Encode ";
|
||||
eval "use JSON;1" or $missingModul .= "JSON ";
|
||||
eval "use IO::Socket::SSL;1" or $missingModul .= "IO::Socket::SSL ";
|
||||
###todo Hier fehlt noch Modulabfrage für ssl
|
||||
|
||||
|
||||
my $version = "0.0.29";
|
||||
my $version = "0.0.31";
|
||||
|
||||
|
||||
|
||||
@ -126,7 +127,7 @@ sub GardenaSmartBridge_Define($$) {
|
||||
|
||||
|
||||
return "too few parameters: define <NAME> GardenaSmartBridge <Email> <Passwort>" if( @a != 4 ) ;
|
||||
return "Cannot define Gardena Bridge device. Perl modul $missingModul is missing." if ( $missingModul );
|
||||
return "Cannot define Gardena Bridge device. Perl modul ${missingModul}is missing." if ( $missingModul );
|
||||
|
||||
my $name = $a[0];
|
||||
my $user = $a[2];
|
||||
|
@ -62,7 +62,7 @@ eval "use Encode qw(encode encode_utf8 decode_utf8);1" or $missingModul .= "Enco
|
||||
eval "use JSON;1" or $missingModul .= "JSON ";
|
||||
|
||||
|
||||
my $version = "0.0.29";
|
||||
my $version = "0.0.31";
|
||||
|
||||
|
||||
|
||||
@ -312,10 +312,10 @@ sub GardenaSmartDevice_WriteReadings($$) {
|
||||
} while ($abilities >= 0);
|
||||
|
||||
|
||||
readingsBulkUpdateIfChanged($hash,'state',ReadingsVal($name,'mower-status','readingsValError')) if( AttrVal($name,'model','unknown') eq 'mower' );
|
||||
readingsBulkUpdateIfChanged($hash,'state',(ReadingsVal($name,'outlet-valve_open','readingsValError') == 1 ? "open" : "closed")) if( AttrVal($name,'model','unknown') eq 'watering_computer' );
|
||||
readingsBulkUpdate($hash,'state',ReadingsVal($name,'mower-status','readingsValError')) if( AttrVal($name,'model','unknown') eq 'mower' );
|
||||
readingsBulkUpdate($hash,'state',(ReadingsVal($name,'outlet-valve_open','readingsValError') == 1 ? "open" : "closed")) if( AttrVal($name,'model','unknown') eq 'watering_computer' );
|
||||
|
||||
readingsBulkUpdateIfChanged($hash,'state','T: ' . ReadingsVal($name,'ambient_temperature-temperature','readingsValError') . '°C, H: ' . ReadingsVal($name,'humidity-humidity','readingsValError') . '%, Light: ' . ReadingsVal($name,'ambient_temperature-temperature','readingsValError') . 'lux') if( AttrVal($name,'model','unknown') eq 'sensor' );
|
||||
readingsBulkUpdate($hash,'state','T: ' . ReadingsVal($name,'ambient_temperature-temperature','readingsValError') . '°C, H: ' . ReadingsVal($name,'humidity-humidity','readingsValError') . '%, Light: ' . ReadingsVal($name,'ambient_temperature-temperature','readingsValError') . 'lux') if( AttrVal($name,'model','unknown') eq 'sensor' );
|
||||
|
||||
readingsEndUpdate( $hash, 1 );
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user