mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 06:39:11 +00:00
73_GardenaSmartBridge/Device: fix Undefined subroutine &GardenaSmartDevice
git-svn-id: https://svn.fhem.de/fhem/trunk@17555 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
b75fcb0018
commit
484e581c91
@ -1,5 +1,7 @@
|
||||
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
|
||||
# Do not insert empty lines here, update check depends on it.
|
||||
- bugfix: 73_GardenaSmartBridge/Device
|
||||
fix Undefined subroutine &GardenaSmartDevice
|
||||
- change: 93_DbLog: Log output of recuceLogNbl & use of charFilter enhanced
|
||||
- feature: 93_Log2Syslog: attribute sslCertPrefix added (Forum:#92030)
|
||||
- bugfix: 10_IT fix usage with multible io devices
|
||||
|
@ -60,26 +60,6 @@ use warnings;
|
||||
|
||||
my $version = "1.4.0";
|
||||
|
||||
# # Declare functions
|
||||
# sub Attr(@);
|
||||
# sub Define($$);
|
||||
# sub Initialize($);
|
||||
# sub Set($@);
|
||||
# sub Write($@);
|
||||
# sub Undef($$);
|
||||
# sub Delete($$);
|
||||
# sub ResponseProcessing($$);
|
||||
# sub ErrorHandling($$$);
|
||||
# sub WriteReadings($$);
|
||||
# sub ParseJSON($$);
|
||||
# sub getDevices($);
|
||||
# sub getToken($);
|
||||
# sub createHttpValueStrings($@);
|
||||
# sub Notify($$);
|
||||
# sub StorePassword($$);
|
||||
# sub ReadPassword($);
|
||||
# sub DeletePassword($);
|
||||
# sub Rename(@);
|
||||
|
||||
sub GardenaSmartBridge_Initialize($) {
|
||||
|
||||
@ -166,7 +146,7 @@ sub Define($$) {
|
||||
my @a = split( "[ \t][ \t]*", $def );
|
||||
|
||||
return "too few parameters: define <NAME> GardenaSmartBridge"
|
||||
if ( @a < 2 or @a > 4 );
|
||||
if ( @a != 2 );
|
||||
return
|
||||
"Cannot define Gardena Bridge device. Perl modul ${missingModul}is missing."
|
||||
if ($missingModul);
|
||||
@ -181,9 +161,6 @@ sub Define($$) {
|
||||
CommandAttr( undef, $name . ' room GardenaSmart' )
|
||||
if ( AttrVal( $name, 'room', 'none' ) eq 'none' );
|
||||
|
||||
CommandDefMod( undef, $name . ' ' . $hash->{TYPE} )
|
||||
if ( @a > 2 ); # fix new define
|
||||
|
||||
readingsSingleUpdate( $hash, 'token', 'none', 1 );
|
||||
readingsSingleUpdate( $hash, 'state', 'initialized', 1 );
|
||||
|
||||
@ -277,8 +254,6 @@ sub Notify($$) {
|
||||
my $events = deviceEvents( $dev, 1 );
|
||||
return if ( !$events );
|
||||
|
||||
#Log3 $name, 1, "GardenaSmartBridge ($name) - Im Notify: DEVTYPE: $devtype, DEVNAME: $devname EVENT: @{$events}";
|
||||
|
||||
getToken($hash)
|
||||
if (
|
||||
(
|
||||
@ -338,8 +313,6 @@ sub Set($@) {
|
||||
|
||||
my ( $hash, $name, $cmd, @args ) = @_;
|
||||
|
||||
#my ($arg, @params) = @args;
|
||||
|
||||
if ( lc $cmd eq 'getdevicesstate' ) {
|
||||
getDevices($hash);
|
||||
|
||||
@ -408,7 +381,6 @@ sub Write($@) {
|
||||
}
|
||||
);
|
||||
|
||||
#Log3 $name, 4, "GardenaSmartBridge ($name) - Send with URL: $hash->{URL}$uri, HEADER: $header, DATA: $payload, METHOD: $method";
|
||||
Log3 $name, 4,
|
||||
"GardenaSmartBridge ($name) - Send with URL: $hash->{URL}$uri, HEADER: secret!, DATA: secret!, METHOD: $method";
|
||||
}
|
||||
@ -1025,7 +997,6 @@ sub DeletePassword($) {
|
||||
|
||||
my $hash = shift;
|
||||
|
||||
#my $index = $hash->{TYPE}."_".$hash->{NAME}."_passwd";
|
||||
setKeyValue( $hash->{TYPE} . "_" . $hash->{NAME} . "_passwd", undef );
|
||||
|
||||
return undef;
|
||||
|
@ -58,19 +58,6 @@ package main;
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
# # Declare functions
|
||||
# sub GardenaSmartDevice_Attr(@);
|
||||
# sub GardenaSmartDevice_Define($$);
|
||||
# sub GardenaSmartDevice_Initialize($);
|
||||
# sub GardenaSmartDevice_Set($@);
|
||||
# sub GardenaSmartDevice_Undef($$);
|
||||
# sub GardenaSmartDevice_WriteReadings($$);
|
||||
# sub GardenaSmartDevice_Parse($$);
|
||||
# sub GardenaSmartDevice_ReadingLangGerman($$);
|
||||
# sub GardenaSmartDevice_RigRadingsValue($$);
|
||||
# sub GardenaSmartDevice_Zulu2LocalString($);
|
||||
# sub GardenaSmartDevice_SetPredefinedStartPoints($@);
|
||||
|
||||
my $version = "1.4.0";
|
||||
|
||||
sub GardenaSmartDevice_Initialize($) {
|
||||
@ -129,7 +116,8 @@ BEGIN {
|
||||
AssignIoPort
|
||||
modules
|
||||
IOWrite
|
||||
defs)
|
||||
defs
|
||||
makeDeviceName)
|
||||
);
|
||||
}
|
||||
|
||||
@ -179,11 +167,9 @@ sub Define($$) {
|
||||
and $d->{IODev} == $hash->{IODev}
|
||||
and $d->{NAME} ne $name );
|
||||
|
||||
#$attr{$name}{room} = "GardenaSmart" if( not defined( $attr{$name}{room} ) );
|
||||
CommandAttr( undef, $name . ' room GardenaSmart' )
|
||||
if ( AttrVal( $name, 'room', 'none' ) eq 'none' );
|
||||
|
||||
#$attr{$name}{model} = $category if( not defined( $attr{$name}{model} ) );
|
||||
CommandAttr( undef, $name . ' model ' . $category )
|
||||
if ( AttrVal( $name, 'model', 'none' ) eq 'none' );
|
||||
|
||||
@ -219,8 +205,6 @@ sub Set($@) {
|
||||
|
||||
my ( $hash, $name, $cmd, @args ) = @_;
|
||||
|
||||
#my ($arg, @params) = @args;
|
||||
|
||||
my $payload;
|
||||
my $abilities = '';
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user