From 1d73180f9c09b9b9b06b9adf0fbd157d0ae15ab0 Mon Sep 17 00:00:00 2001 From: Marko Oldenburg Date: Sun, 10 May 2020 19:40:59 +0200 Subject: [PATCH] add special thanks to Holger S --- 74_XiaomiBTLESens.pm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/74_XiaomiBTLESens.pm b/74_XiaomiBTLESens.pm index 7bb263d..7106868 100644 --- a/74_XiaomiBTLESens.pm +++ b/74_XiaomiBTLESens.pm @@ -7,6 +7,7 @@ # # Special thanks goes to: # - Charlie71: add special patch +# - Holger S: patch to support Mijia LYWSD03MMC devices # # # This script is free software; you can redistribute it and/or modify @@ -669,7 +670,7 @@ sub CreateParamGatttool { } sub Gatttool_executeCommand { - my $command = join( ' ', @_ ); + my $command = join q{ }, @_; return ( $_ = qx{$command 2>&1}, $? >> 8 ); } @@ -758,7 +759,7 @@ qx(ssh $sshHost '$psCommand | grep -E "$gatttoolCmdlineStaticEscaped"') Log3( $name, 5, "XiaomiBTLESens ($name) - ExecGatttool_Run: gatttool loop result " - . join( ',', @gtResult ) ); + . join q{,}, @gtResult ); $returnCode = 2 if ( !defined( $gtResult[0] ) ); @@ -771,7 +772,7 @@ qx(ssh $sshHost '$psCommand | grep -E "$gatttoolCmdlineStaticEscaped"') Log3( $name, 4, "XiaomiBTLESens ($name) - ExecGatttool_Run: gatttool result " - . join( ",", @gtResult ) ); + . join q{,}, @gtResult ); $handle = '0x35' if ( $sshHost ne 'none'