mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-03 23:06:37 +00:00
36_Shelly.pm: Neue Version 1.40
git-svn-id: https://svn.fhem.de/fhem/trunk@17546 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
caa017497d
commit
d12941e60f
@ -38,7 +38,7 @@ use vars qw{%attr %defs};
|
||||
sub Log($$);
|
||||
|
||||
#-- globals on start
|
||||
my $version = "1.36";
|
||||
my $version = "1.40";
|
||||
|
||||
#-- these we may get on request
|
||||
my %gets = (
|
||||
@ -374,11 +374,8 @@ sub Shelly_Set ($@) {
|
||||
if( $cmd =~ /^((on)|(off)).*/ ){
|
||||
$channel = $value;
|
||||
if( $cmd =~ /(.*)-for-timer/ ){
|
||||
$time = shift @a;
|
||||
if( !defined($time) ){
|
||||
$time = $value;
|
||||
$channel = undef;
|
||||
}
|
||||
$time = $value;
|
||||
$channel = shift @a;
|
||||
}
|
||||
if( $shelly_models{$model}[0] == 1){
|
||||
$channel = 0
|
||||
@ -996,6 +993,7 @@ sub Shelly_Set ($@) {
|
||||
=begin html
|
||||
|
||||
<a name="Shelly"></a>
|
||||
<h3>Shelly</h3>
|
||||
<ul>
|
||||
<p> FHEM module to communicate with a Shelly switch/roller actuator</p>
|
||||
<a name="Shellydefine"></a>
|
||||
@ -1018,11 +1016,11 @@ sub Shelly_Set ($@) {
|
||||
For Shelly switching devices (mode=relay for model=shelly2, standard for all other models)
|
||||
<ul>
|
||||
<li><a name="shelly_onoff"></a>
|
||||
<code>set <name> on|off <channel> </code>
|
||||
<br />switches channel <channel> on or off.</li>
|
||||
<code>set <name> on|off [<channel>] </code>
|
||||
<br />switches channel <channel> on or off. Only if model=shelly2/4: If the channel parameter is omitted, the module will switch the channel defined in the defchannel attribute.</li>
|
||||
<li><a name="shelly_onofftimer"></a>
|
||||
<code>set <name> on-for-timer|off-for-timer <channel> <time></code>
|
||||
<br />switches <channel> on or off for <time> seconds.</li>
|
||||
<code>set <name> on-for-timer|off-for-timer <time> [<channel>] </code>
|
||||
<br />switches <channel> on or off for <time> seconds. Only if model=shelly2/4: If the channel parameter is omitted, the module will switch the channel defined in the defchannel attribute.</li>
|
||||
</ul>
|
||||
<br/>For Shelly roller blind devices (mode=roller for model=shelly2)
|
||||
<ul>
|
||||
@ -1063,7 +1061,7 @@ sub Shelly_Set ($@) {
|
||||
<br/>For Shelly switching devices (mode=relay for model=shelly2, standard for all other models)
|
||||
<ul>
|
||||
<li><a name="shelly_defchannel"><code>attr <name> defchannel <integer> (only for model=shelly2|shelly4)</code></a>
|
||||
<br />for multi-channel switches: Which channel will be switched, if a simple on|off command is received without channel number</li>
|
||||
<br />for multi-channel switches: Which channel will be switched, if a command is received without channel number</li>
|
||||
</ul>
|
||||
<br/>For Shelly roller blind devices (mode=roller for model=shelly2)
|
||||
<ul>
|
||||
|
Loading…
x
Reference in New Issue
Block a user