mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-03 04:36:36 +00:00
YAMAHA_AVR: new argument "toggle" for mute command
git-svn-id: https://svn.fhem.de/fhem/trunk@4328 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
c3ccf96365
commit
bb252130fc
@ -1,6 +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.
|
||||
- SVN
|
||||
- feature: YAMAHA_AVR: new argument "toggle" for mute command
|
||||
- feature: FB_CALLMONITOR: replace & to & at reverse search
|
||||
- feature: new module 33_readingsProxy to make (a subset of) a reading
|
||||
from one device available as a new device. can be used to
|
||||
|
@ -226,7 +226,7 @@ YAMAHA_AVR_Set($@)
|
||||
return "No Argument given" if(!defined($a[1]));
|
||||
|
||||
my $what = $a[1];
|
||||
my $usage = "Unknown argument $what, choose one of on:noArg off:noArg volumeStraight:slider,-80,1,16 volume:slider,0,1,100 volumeUp volumeDown input:".$inputs_comma." mute:on,off remoteControl:setup,up,down,left,right,return,option,display,tunerPresetUp,tunerPresetDown,enter ".(defined($hash->{helper}{SCENES})?"scene:".$scenes_comma." ":"")."statusRequest:noArg";
|
||||
my $usage = "Unknown argument $what, choose one of on:noArg off:noArg volumeStraight:slider,-80,1,16 volume:slider,0,1,100 volumeUp volumeDown input:".$inputs_comma." mute:on,off,toggle remoteControl:setup,up,down,left,right,return,option,display,tunerPresetUp,tunerPresetDown,enter ".(defined($hash->{helper}{SCENES})?"scene:".$scenes_comma." ":"")."statusRequest:noArg";
|
||||
|
||||
# Depending on the status response, use the short or long Volume command
|
||||
|
||||
@ -365,6 +365,17 @@ YAMAHA_AVR_Set($@)
|
||||
{
|
||||
$result = YAMAHA_AVR_SendCommand($hash, "<YAMAHA_AV cmd=\"PUT\"><$zone><$volume_cmd><Mute>Off</Mute></$volume_cmd></$zone></YAMAHA_AV>");
|
||||
}
|
||||
elsif($a[2] eq "toggle")
|
||||
{
|
||||
if(ReadingsVal($hash->{NAME}, "mute", "off") eq "on")
|
||||
{
|
||||
$result = YAMAHA_AVR_SendCommand($hash, "<YAMAHA_AV cmd=\"PUT\"><$zone><$volume_cmd><Mute>Off</Mute></$volume_cmd></$zone></YAMAHA_AV>");
|
||||
}
|
||||
else
|
||||
{
|
||||
$result = YAMAHA_AVR_SendCommand($hash, "<YAMAHA_AV cmd=\"PUT\"><$zone><$volume_cmd><Mute>On</Mute></$volume_cmd></$zone></YAMAHA_AV>");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return $usage;
|
||||
@ -1006,7 +1017,7 @@ sub YAMAHA_AVR_getInputs($)
|
||||
<li><b>volumeStraight</b> -80...15 - set the volume level in decibel</li>
|
||||
<li><b>volumeUp</b> [0-100] - increases the volume level by 5% or the value of attribute volumeSteps (optional the increasing level can be given as argument, which will be used instead)</li>
|
||||
<li><b>volumeDown</b> [0-100] - decreases the volume level by 5% or the value of attribute volumeSteps (optional the decreasing level can be given as argument, which will be used instead)</li>
|
||||
<li><b>mute</b> on|off - activates volume mute</li>
|
||||
<li><b>mute</b> on|off|toggle - activates volume mute</li>
|
||||
<li><b>statusRequest</b> - requests the current status of the device</li>
|
||||
<li><b>remoteControl</b> up,down,... - sends remote control commands as listed below</li>
|
||||
</ul>
|
||||
@ -1203,7 +1214,7 @@ output # only available in zones other than mainzone</code></ul><br><br>
|
||||
<li><b>volumeStraight</b> -87...15 - Setzt die Lautstärke in Dezibel (-80.5 bis 15.5 dB) so wie sie am Receiver auch verwendet wird.</li>
|
||||
<li><b>volumeUp</b> [0...100] - Erhöht die Lautstärke um 5% oder entsprechend dem Attribut volumeSteps (optional kann der Wert auch als Argument angehangen werden, dieser hat dann Vorang) </li>
|
||||
<li><b>volumeDown</b> [0...100] - Veringert die Lautstärke um 5% oder entsprechend dem Attribut volumeSteps (optional kann der Wert auch als Argument angehangen werden, dieser hat dann Vorang) </li>
|
||||
<li><b>mute</b> on|off - Schaltet den Receiver stumm</li>
|
||||
<li><b>mute</b> on|off|toggle - Schaltet den Receiver stumm</li>
|
||||
<li><b>statusRequest</b> - Fragt den aktuell Status des Receivers ab</li>
|
||||
<li><b>remoteControl</b> up,down,... - Sendet Fernbedienungsbefehle wie im nächsten Abschnitt beschrieben</li>
|
||||
</ul>
|
||||
|
Loading…
x
Reference in New Issue
Block a user