2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-03-09 20:57:11 +00:00

70_ENIGMA2: add remotecontrolChannel attribute to customize channelUp/channelDown remote control commands

git-svn-id: https://svn.fhem.de/fhem/trunk@18816 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
jpawlowski 2019-03-07 07:30:00 +00:00
parent 5e575ee74e
commit 3b4d52c996
2 changed files with 16 additions and 3 deletions

View File

@ -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.
- feature: 70_ENIGMA2: add remotecontrolChannel attribute to customize
channelUp/channelDown remote control commands
- feature: 50_MOBILEALERTSGW: attribut allowfrom added
- new: 71_YAMAHA_MC: initial release
- bugfix: 22_HOMEMODE: - fix illegal division by zero in HOMEMODE_Luminance

View File

@ -23,7 +23,7 @@ sub ENIGMA2_Initialize($) {
$hash->{parseParams} = 1;
$hash->{AttrList} =
"disable:1,0 disabledForIntervals do_not_notify:1,0 https:0,1 http-method:GET,POST http-noshutdown:1,0 disable:0,1 bouquet-tv bouquet-radio timeout remotecontrol:standard,advanced,keyboard lightMode:0,1 ignoreState:0,1 macaddr:textField model wakeupCmd:textField WOL_useUdpBroadcast WOL_port WOL_mode:EW,UDP,BOTH "
"disable:1,0 disabledForIntervals do_not_notify:1,0 https:0,1 http-method:GET,POST http-noshutdown:1,0 disable:0,1 bouquet-tv bouquet-radio timeout remotecontrol:standard,advanced,keyboard remotecontrolChannel:LEFT_RIGHT,CHANNELDOWN_CHANNELUP lightMode:0,1 ignoreState:0,1 macaddr:textField model wakeupCmd:textField WOL_useUdpBroadcast WOL_port WOL_mode:EW,UDP,BOTH "
. $readingFnAttributes;
$data{RC_layout}{ENIGMA2_DreamMultimedia_DM500_DM800_SVG} =
@ -662,10 +662,18 @@ sub ENIGMA2_Set($@) {
if ( $state eq "on" || $ignoreState ne "0" ) {
if ( lc($set) eq "channelup" ) {
$cmd = "command=" . ENIGMA2_GetRemotecontrolCommand("RIGHT");
$cmd =
"command="
. ENIGMA2_GetRemotecontrolCommand(
AttrVal( $name, 'remotecontrolChannel', 'LEFT_RIGHT' ) eq
'CHANNELDOWN_CHANNELUP' ? 'CHANNELUP' : 'RIGHT' );
}
else {
$cmd = "command=" . ENIGMA2_GetRemotecontrolCommand("LEFT");
$cmd =
"command="
. ENIGMA2_GetRemotecontrolCommand(
AttrVal( $name, 'remotecontrolChannel', 'LEFT_RIGHT' ) eq
'CHANNELDOWN_CHANNELUP' ? 'CHANNELDOWN' : 'LEFT' );
}
$result = ENIGMA2_SendCommand( $hash, "remotecontrol", $cmd );
}
@ -3040,6 +3048,9 @@ sub ENIGMA2_RClayout_VUplusDuo2() {
<li>
<b>remotecontrol</b> - Explicitly set specific remote control unit format. This will only be considered for set-command <strong>remoteControl</strong> as of now.
</li>
<li>
<b>remotecontrolChannel</b> - Switch between remote control commands used for set-commands <strong>channelUp</strong> and <strong>channelDown</strong>.
</li>
<li>
<b>timeout</b> - Set different polling timeout in seconds (default=6)
</li>