2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-01-31 06:39:11 +00:00

14_SD_UT: new models rc

git-svn-id: https://svn.fhem.de/fhem/trunk@26396 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
HomeAuto_User 2022-09-12 14:41:16 +00:00
parent fab7e15e94
commit c17768496d
2 changed files with 234 additions and 48 deletions

View File

@ -1,5 +1,6 @@
# 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: 14_SD_UT: new rc models´
- feature: 51_MOBILEALERTS: Add MA 10860
- change: 93_DbRep: NOTE: !! syntax of set ... changeValue" is changed !!
- feature: 10_RHASSPY: new module for Rhasspy integration (from contrib)

View File

@ -21,6 +21,9 @@
#{ FORUM: https://forum.fhem.de/index.php/topic,58397.960.html | https://forum.fhem.de/index.php/topic,53282.30.html
# Adresse e | 1110 (off|off|off|on): fan_off | get sduino_dummy raw MU;;P0=250;;P1=-492;;P2=166;;P3=-255;;P4=491;;P5=-8588;;D=052121212121234121212121234521212121212341212121212345212121212123412121212123452121212121234121212121234;;CP=0;;
#} Adresse e | 1110 (off|off|off|on): fan low speed | get sduino_dummy raw MU;;P0=-32001;;P1=224;;P2=-255;;P3=478;;P4=-508;;P6=152;;P7=-8598;;D=01234141414641414141414123712341414141414141414141237123414141414141414141412371234141414141414141414123712341414141414141414141237123414141414141414141412371234141414141414141414123712341414141414141414141237123414141414141414141412371234141414141414141;;CP=1;;R=108;;O;;
# - Westinghouse Deckenventilator (Typ HT12E | remote with 6 buttons, with light dimmer | Buttons_six - 7787800) [Protocol 29] (start -35) (1 = off | 0 = on)
#{ FORUM: https://forum.fhem.de/index.php/topic,53282.msg1229192.html#msg1229192
#} Adresse E | 1110 (off|off|off|on): light_dimm | get sduino_dummy rawmsg MU;P0=24164;P1=-495;P2=191;P3=-271;P4=415;P5=-8052;D=01212341212121212121212345212123412121212121212123452121234121212121212121234521212341212121212121212345212123412121212121212123452121234121212121212121234521212341212121212121212345212123412121212121212123452121234121212121212121234521212341212121212121;CP=2;R=52;O;
####################################################################################################################################
# - Westinghouse Deckenventilator (Typ [M1EN compatible HT12E] example Delancey | remote RH787T with 9 buttons + SET) [Protocol 83] and [additionally Protocol 30] (sync -36) (1 = off | 0 = on)
#{ Adresse 0 | 0000 (on|on|on|on): I - fan minimum speed | get sduino_dummy raw MU;;P0=388;;P1=-112;;P2=267;;P3=-378;;P5=585;;P6=-693;;P7=-11234;;D=0123035353535356262623562626272353535353562626235626262723535353535626262356262627235353535356262623562626272353535353562626235626262723535353535626262356262627235353535356262623562626272353535353562626235626262723535353535626262356262627235353535356262;;CP=2;;R=43;;O;;
@ -371,6 +374,23 @@
# TR401_0_2 on MU;P0=-14148;P1=-23738;P2=607;P3=-737;P4=1298;P5=-1419;P6=340;P7=134;CP=2;R=236;D=12343452523434345252525252161712343452523434345252525252160;p;
#}
###############################################################################################################################################################################
# - Remote controls Meikee [Protocol 118]
#{ elektron-bbs 2022-02-13
# https://forum.fhem.de/index.php/topic,126110.0.html @ Sepp 2022-02-09
# Meikee_24 - remote control with 24 buttons
# Meikee_24_20D3 on MU;P0=506;P1=-1015;P2=1008;P3=-523;P4=-12696;D=01012301040101230101010101232301230101232301010101010123010;CP=0;R=49;
# Meikee_24_20D3 off MU;P0=-516;P1=518;P2=-1015;P3=1000;P4=-12712;D=01230121230301212121212121230141212301212121212303012301212303012121212121212301;CP=1;R=35;
# Meikee_24_20D3 learn MU;P0=-509;P1=513;P2=-999;P3=1027;P4=-12704;D=01230121230301212121212121212141212301212121212303012301212303012121212121212121;CP=1;R=77;
# Meikee_21 - remote control with 21 buttons
# Same codes as Meikee_24, but different key assignments.
#}
###############################################################################################################################################################################
# - Remote control Busch-Transcontrol HF - Handsender 6861 [Protocol 121]
#{ elektron-bbs 2022-05-25
# TC6861_3DC_1 OFF MU;P0=28479;P1=-692;P2=260;P3=574;P4=-371;D=0121212121212134343434213434342121213434343434342;CP=2;R=41;
# TC6861_3DC_1 ON MU;P0=4372;P1=-689;P2=254;P3=575;P4=-368;D=0121213434212134343434213434342121213434343434342;CP=2;R=59;
#}
###############################################################################################################################################################################
# !!! ToDo´s !!!
# - LED lights, counter battery-h reading --> commandref hour_counter module
# -
@ -382,7 +402,7 @@ use strict;
use warnings;
no warnings 'portable'; # Support for 64-bit ints required
our $VERSION = '2021-08-05';
our $VERSION = '2022-07-27';
sub SD_UT_bin2tristate;
sub SD_UT_tristate2bin;
@ -399,6 +419,16 @@ my %models = (
Protocol => 'P29',
Typ => 'remote'
},
'Buttons_six' => { '011111' => '1_fan_low_speed',
'111011' => '2_fan_medium_speed',
'111101' => '3_fan_high_speed',
'111110' => 'fan_off',
'101111' => 'light_on_off',
'110111' => 'light_dimm',
hex_length => [3],
Protocol => 'P29',
Typ => 'remote'
},
'CAME_TOP_432EV' => { '1110' => 'left_button',
'1101' => 'right_button',
hex_length => [3],
@ -808,6 +838,75 @@ my %models = (
Protocol => 'P114',
Typ => 'remote'
},
'TC6861' => { '0000' => 'off',
'0011' => 'on',
'ch' => {
'01111110' => '1',
'01111111' => '2',
'10000000' => '3',
'1' => '01111110',
'2' => '01111111',
'3' => '10000000',
},
hex_length => [6],
Protocol => 'P121',
Typ => 'remote'
},
'Meikee_24' => { '00000000' => 'learn', # 0x00
'00000001' => 'off', # 0x01
'00000010' => 'on', # 0x02
'00000011' => 'mode_flash', # 0x03
'00000100' => 'brightness/speed_up', # 0x04
'00000101' => 'brightness/speed_down', # 0x05
'00000110' => 'mode_strobe', # 0x06
'00000111' => 'static_2000K', # 0x07
'00001000' => 'static_4500K', # 0x08
'00001001' => 'mode_fade', # 0x09
'00001010' => 'switch_4500K/2000K', # 0x0A
'00001011' => 'static_mixed_white', # 0x0B
'00001100' => 'mode_smooth', # 0x0C
'00001101' => 'time_4h', # 0x0D
'00001110' => 'time_6h', # 0x0E
'00001111' => 'time_12h', # 0x0F
'00010000' => 'static_red', # 0x10
'00010001' => 'static_green', # 0x11
'00010010' => 'static_blue', # 0x12
'00010011' => 'mixed_red', # 0x13
'00010100' => 'mixed_cyan', # 0x14
'00010101' => 'mixed_orange', # 0x15
'00010110' => 'mixed_yellow', # 0x16
'00010111' => 'mixed_green', # 0x17
'00011000' => 'mixed_purple', # 0x18
hex_length => [6,7],
Protocol => 'P118',
Typ => 'remote'
},
'Meikee_21' => { '00000000' => 'learn', # 0x00
'00000001' => 'on', # 0x01
'00000010' => 'brightness_down', # 0x02
'00000011' => 'brightness_up', # 0x03
'00000100' => 'off', # 0x04
'00000101' => 'mode_flash', # 0x05
'00000110' => 'mode_smooth', # 0x06
'00000111' => 'time_2h', # 0x07
'00001000' => 'time_4h', # 0x08
'00001001' => 'time_6h', # 0x09
'00001010' => 'static_red', # 0x0A
'00001011' => 'static_green', # 0x0B
'00001100' => 'static_blue', # 0x0C
'00001101' => 'mixed_red', # 0x0D
'00001110' => 'static_mixed_white', # 0x0E
'00001111' => 'mixed_blue', # 0x0F
'00010000' => 'mixed_orange', # 0x10
'00010001' => 'mixed_light_blue', # 0x11
'00010010' => 'mixed_dark_blue', # 0x12
'00010011' => 'mixed_yellow', # 0x13
'00010100' => 'mixed_turquoise', # 0x14
'00010101' => 'mixed_purple', # 0x15
hex_length => [6,7],
Protocol => 'P118',
Typ => 'remote'
},
'unknown' => { Protocol => 'any',
hex_length => [],
Typ => 'not_exist'
@ -817,12 +916,12 @@ my %models = (
#############################
sub SD_UT_Initialize {
my ($hash) = @_;
$hash->{Match} = '^P(?:14|20|24|26|29|30|34|46|68|69|76|78|81|83|86|90|91|91.1|92|93|95|97|99|104|105|114)#.*';
$hash->{DefFn} = 'SD_UT_Define';
$hash->{UndefFn} = 'SD_UT_Undef';
$hash->{ParseFn} = 'SD_UT_Parse';
$hash->{SetFn} = 'SD_UT_Set';
$hash->{AttrFn} = 'SD_UT_Attr';
$hash->{Match} = '^P(?:14|20|24|26|29|30|34|46|56|68|69|76|78|81|83|86|90|91|91\.1|92|93|95|97|99|104|105|114|118|121)#.*';
$hash->{DefFn} = \&SD_UT_Define;
$hash->{UndefFn} = \&SD_UT_Undef;
$hash->{ParseFn} = \&SD_UT_Parse;
$hash->{SetFn} = \&SD_UT_Set;
$hash->{AttrFn} = \&SD_UT_Attr;
$hash->{AttrList} = 'repeats:1,2,3,4,5,6,7,8,9,12,15 IODev do_not_notify:1,0 '.
'ignore:0,1 showtime:1,0 model:'.join(',', sort keys %models).
" $readingFnAttributes UTclock UTfrequency";
@ -836,6 +935,7 @@ sub SD_UT_Initialize {
'Momento.*' => {ATTR => 'model:Momento', FILTER => '%NAME', autocreateThreshold => '3:180', GPLOT => q{}},
'OR28V.*' => {ATTR => 'model:OR28V', FILTER => '%NAME', autocreateThreshold => '3:180', GPLOT => q{}},
'RCnoName20.*' => {ATTR => 'model:RCnoName20', FILTER => '%NAME', autocreateThreshold => '3:180', GPLOT => q{}},
'TC6861.*' => {ATTR => 'model:TR401', FILTER => '%NAME', autocreateThreshold => '3:180', GPLOT => q{}},
'TR401.*' => {ATTR => 'model:TR401', FILTER => '%NAME', autocreateThreshold => '3:180', GPLOT => q{}},
'Techmar.*' => {ATTR => 'model:Techmar', FILTER => '%NAME', autocreateThreshold => '3:180', GPLOT => q{}},
'Visivo.*' => {ATTR => 'model:Visivo', FILTER => '%NAME', autocreateThreshold => '3:180', GPLOT => q{}},
@ -858,8 +958,8 @@ sub SD_UT_Define {
### checks unknown ###
return "wrong define: <model> $a[2] need no HEX-Value to define!" if($a[2] eq 'unknown' && $a[3] && length($a[3]) >= 1);
### checks Westinghouse_Delancey RH787T & WestinghouseButtons_five & TR60C-1 ###
if ($a[2] eq 'RH787T' || $a[2] eq 'Buttons_five' || $a[2] eq 'TR60C1') {
### checks Westinghouse_Delancey RH787T & Westinghouse Buttons_five & Buttons_six & TR60C-1 ###
if ($a[2] eq 'RH787T' || $a[2] eq 'Buttons_five' || $a[2] eq 'Buttons_six' || $a[2] eq 'TR60C1') {
if (length($a[3]) > 1) {
return "wrong HEX-Value! $a[2] must have one HEX-Value";
}
@ -886,8 +986,8 @@ sub SD_UT_Define {
if (($a[2] eq 'SA_434_1_mini' || $a[2] eq 'QUIGG_DMV' || $a[2] eq 'TR_502MSV' || $a[2] eq 'BeSmart_S4') && not $a[3] =~ /^[0-9a-fA-F]{3}/xms) {
return "wrong HEX-Value! ($a[3]) $a[2] HEX-Value to short or long (must be 3 chars) or not HEX (0-9 | a-f | A-F){3}";
}
### [4 nibble] checks Neff SF01_01319004 & BOSCH SF01_01319004_Typ2 & Chilitec_22640 & ESTO KL_RF01 & RCnoName20 & xavax & BF_301###
if (($a[2] eq 'SF01_01319004' || $a[2] eq 'SF01_01319004_Typ2' || $a[2] eq 'Chilitec_22640' || $a[2] eq 'KL_RF01' || $a[2] eq 'RCnoName20' || $a[2] eq 'xavax' || $a[2] eq 'BF_301') && not $a[3] =~ /^[0-9a-fA-F]{4}/xms) {
### [4 nibble] checks Neff SF01_01319004 & BOSCH SF01_01319004_Typ2 & Chilitec_22640 & ESTO KL_RF01 & RCnoName20 & xavax & BF_301 & Meikee_xx ###
if (($a[2] eq 'SF01_01319004' || $a[2] eq 'SF01_01319004_Typ2' || $a[2] eq 'Chilitec_22640' || $a[2] eq 'KL_RF01' || $a[2] eq 'RCnoName20' || $a[2] eq 'xavax' || $a[2] eq 'BF_301' || $a[2] eq 'Meikee_21' || $a[2] eq 'Meikee_24') && not $a[3] =~ /^[0-9a-fA-F]{4}/xms) {
return "Wrong HEX-Value! ($a[3]) $a[2] Hex-value to short or long (must be 4 chars) or not hex (0-9 | a-f | A-F) {4}";
}
### [6] checks Manax | mumbi ###
@ -921,6 +1021,11 @@ sub SD_UT_Define {
return "wrong devicecode! ($a[3]) $a[2] must be [0-9]_[1-4]";
}
### [3] checks TC6861 (Busch-Transcontrol HF) [P121] ###
if ($a[2] eq 'TC6861' && not $a[3] =~ /^[0-9A-F]{3}_[1-3]$/xms) {
return "SD_UT model $a[2] wrong devicecode: ($a[3]) - must be 3 digit house code (hex 0-9 A-F) _ 1 digit channel (dec 1-3) - e.g. 3DC_1";
}
$hash->{versionModule} = $VERSION;
$hash->{lastMSG} = 'no data';
$hash->{bitMSG} = 'no data';
@ -985,8 +1090,8 @@ sub SD_UT_Set {
}
}
$msgEnd = '#R' . $repeats;
############ Westinghouse Buttons_five ############
} elsif ($model eq 'Buttons_five') {
############ Westinghouse Buttons_five / Buttons_six ############
} elsif ($model eq 'Buttons_five' || $model eq 'Buttons_six') {
my $adr = sprintf( "%04b", hex($definition[1])); # argument 1 - adress to binary with 4 digits
$msg = $models{$model}{Protocol} . '#';
$msgEnd .= '11'.$adr.'#R' . $repeats;
@ -1144,6 +1249,15 @@ sub SD_UT_Set {
} elsif ($model eq 'TR401') {
$msg = $models{$model}{Protocol} . q{#};
$msgEnd = '#R' . $repeats;
############ TC6861 (Busch-Transcontrol HF) [P121] ############
} elsif ($model eq 'TC6861') {
$msg = $models{$model}{Protocol} . q{#P};
$msgEnd = '#R' . $repeats;
############ Meikee ############
} elsif ($model eq 'Meikee_21' || $model eq 'Meikee_24') {
my $adr = sprintf '%016b' , hex $definition[1]; # argument 1 - adress to binary with 16 bits
$msg = $models{$model}{Protocol} . q{#} . $adr;
$msgEnd = '#R' . $repeats;
}
}
@ -1244,6 +1358,13 @@ sub SD_UT_Set {
$msg .= $save . $models{$model}{ch}{$ch};
$msg .= sprintf('%03b', $housecode);
$msg .= '11111' . $msgEnd;
############ TC6861 (Busch-Transcontrol HF) [P121] ############
} elsif ($model eq 'TC6861') {
my ($housecode, $ch) = split('_', $definition[1]);
$msg .= $save; # on/off
$msg .= sprintf('%012b', hex $housecode);
$msg .= $models{$model}{ch}{$ch} . $msgEnd;
# $msg .= $models{$model}{ch}{$ch} . 'P' . $msgEnd;
} else {
$msg .= $save.$msgEnd;
}
@ -1330,6 +1451,12 @@ sub SD_UT_Parse {
$devicedef = 'Buttons_five ' . $deviceCode;
$def = $modules{SD_UT}{defptr}{$devicedef};
}
### Westinghouse Buttons_six [P29] ###
if (!$def && ($protocol == 29 || $protocol == 30)) {
$deviceCode = substr($rawData,2,1);
$devicedef = 'Buttons_six ' . $deviceCode;
$def = $modules{SD_UT}{defptr}{$devicedef};
}
### Unitec_47031 [P30] ###
if (!$def && ($protocol == 30 || $protocol == 83)) {
$deviceCode = substr($rawData,0,2);
@ -1467,6 +1594,33 @@ sub SD_UT_Parse {
$devicedef = 'Navaris ' . $deviceCode;
$def = $modules{SD_UT}{defptr}{$devicedef};
}
### TC6861 (Busch-Transcontrol HF) [P121] ###
if (!$def && $protocol == 121) {
$model = 'TC6861';
my $housecode = substr($rawData,1,3);
my $ch = substr($bitData,16,8);
if ( exists $models{$model}{ch}{$ch} ) {
$ch = $models{$model}{ch}{$ch};
$deviceCode = $housecode .'_'. $ch;
$devicedef = $model .' '. $deviceCode;
$def = $modules{SD_UT}{defptr}{$devicedef};
$name = $model .'_'. $deviceCode;
Log3 $iohash, 5, "$ioname: SD_UT_Parse device TC6861 - housecode=$housecode ch=$ch";
} else {
return '';
}
}
}
if ($hlen == 6 || $hlen == 7) {
### Remote control Meikee [P118] ###
if (!$def && $protocol == 118) {
$deviceCode = substr($rawData,0,4);
$devicedef = 'Meikee_21 ' . $deviceCode if (!$def);
$def = $modules{SD_UT}{defptr}{$devicedef} if (!$def);
$devicedef = 'Meikee_24 ' . $deviceCode if (!$def);
$def = $modules{SD_UT}{defptr}{$devicedef} if (!$def);
}
}
if ($hlen == 8) {
@ -1526,10 +1680,11 @@ sub SD_UT_Parse {
### Manax MX-RCS250 | mumbi [P90] ###
if (!$def && $protocol == 90) {
my $button = $models{RC_10}{buttons}{substr($bitData,20,3)};
if (!defined $button) {return ''}
$deviceCode = substr($rawData,0,4);
my $button = $models{RC_10}{buttons}{substr($bitData,20,3)};
$devicedef = 'RC_10 '.$deviceCode.'_'.$button;
$def = $modules{SD_UT}{defptr}{$devicedef};
$devicedef = 'RC_10 '.$deviceCode.'_'.$button;
$def = $modules{SD_UT}{defptr}{$devicedef};
if ($button ne 'all') {
$state = substr($bitData,23,1) eq '1' ? 'on' : 'off'
@ -1544,7 +1699,7 @@ sub SD_UT_Parse {
$def = undef;
}
### if received data from device _all, set cannels A | B | C | D to state and trigger event ###
### if received data from device _all, set channels A | B | C | D to state and trigger event ###
for ( 'A' .. 'D' ) {
my $defPtr = $modules{SD_UT}{defptr}{'RC_10 '.$deviceCode."_$_"};
if (defined $defPtr) {
@ -1726,8 +1881,8 @@ sub SD_UT_Parse {
$deviceCodeUser = substr($deviceCodeUser, 0 , length($deviceCodeUser)-1);
$deviceCode = $deviceCode." ($deviceCodeUser)";
############ Westinghouse Buttons_five ############ Protocol 29 or 30 ############
} elsif ($model eq 'Buttons_five' && ($protocol == 29 || $protocol == 30)) {
############ Westinghouse Buttons_five / Buttons_six############ Protocol 29 or 30 ############
} elsif (($model eq 'Buttons_five' || $model eq 'Buttons_six') && ($protocol == 29 || $protocol == 30)) {
$state = substr($bitData,0,6);
$deviceCode = substr($bitData,8,4);
@ -1944,12 +2099,20 @@ sub SD_UT_Parse {
} elsif ($model eq 'TR401') {
$state = substr($bitData,0,1);
$deviceCode = substr($rawData,1,1) >> 1;
############ TC6861 (Busch-Transcontrol HF) [P121] ############
} elsif ($model eq 'TC6861') {
$state = substr($bitData,0,4);
$deviceCode = substr($rawData,1,3);
############ Meikee [P118] ############
} elsif (($model eq 'Meikee_21' || $model eq 'Meikee_24') && $protocol == 118) {
$state = substr $bitData,16,8;
$deviceCode = substr $rawData,0,4;
############ unknown ############
} else {
readingsBulkUpdate($hash, 'state', '???');
readingsBulkUpdate($hash, 'unknownMSG', $bitData.' (protocol: '.$protocol.')') if (AttrVal($name, 'model', 'unknown') eq 'unknown');
Log3 $name, 3, "$ioname: SD_UT Please define your model of Device $name in Attributes!" if (AttrVal($name, 'model', 'unknown') eq 'unknown');
Log3 $name, 5, "$ioname: SD_UT Please define your model of Device $name in Attributes!" if (AttrVal($name, 'model', 'unknown') eq 'unknown');
Log3 $name, 5, "$ioname: SD_UT_Parse devicedef=$devicedef attr_model=$model protocol=$protocol rawData=$rawData, bitData=$bitData";
}
@ -2005,12 +2168,9 @@ sub SD_UT_Attr {
my $hex_length = length(InternalVal($name, 'lastMSG', '0'));
if ($cmd eq 'set') {
if ($attrName eq 'repeats' && $attrValue !~ m/^[1-9]$/xms) {
return "$name: Unallowed value $attrValue for the attribute repetition (must be 1 - 9)!";
}
if ($attrName eq 'UTfrequency' && ($attrValue !~ m/^[1-9]{1}[0-9]{0,2}\.?[0-9]*$/xms || $attrValue >= 1000.0)) {
return "$name: Invalid value $attrValue for the UTfrequency attribute. Values such as: 433.92 are permitted.";
}
return qq[$name: Unallowed value $attrValue for the attribute repetition (must be 1 - 99)!] if ($attrName eq q[repeats] && $attrValue !~ m/^[1-9]{1}[0-9]{0,1}$/xms);
return qq[$name: Invalid value $attrValue for the UTfrequency attribute. Values such as: 433.92 (300.00-999.99 MHz) are permitted.] if ($attrName eq q[UTfrequency] && ($attrValue !~ m/^[3-9]{1}[\d]{2}$|^[3-9]{1}[\d]{2}\.{1}[\d]*$/xms));
############ change device models ############
if ($attrName eq 'model' && $attrValue ne $oldmodel) {
@ -2053,6 +2213,11 @@ sub SD_UT_Attr {
$deviceCode = substr($bitData,8,4);
$deviceCode = sprintf("%X", oct( "0b$deviceCode" ) );
$devicename = $devicemodel.'_'.$deviceCode;
############ Westinghouse Buttons_six ############
} elsif ($attrValue eq 'Buttons_six') {
$deviceCode = substr($bitData,8,4);
$deviceCode = sprintf("%X", oct( "0b$deviceCode" ) );
$devicename = $devicemodel.'_'.$deviceCode;
############ SA_434_1_mini ############
} elsif ($attrValue eq 'SA_434_1_mini') {
$deviceCode = sprintf("%03X", oct( "0b$bitData" ) );
@ -2153,6 +2318,11 @@ sub SD_UT_Attr {
$deviceCode = substr $bitData,8,24;
$deviceCode = sprintf("%06X", oct( "0b$bitData" ) );
$devicename = $devicemodel.'_'.$deviceCode;
############ Meikee ############
} elsif ($attrValue eq 'Meikee_21' || $attrValue eq 'Meikee_24') {
$deviceCode = substr($bitData,0,16);
$deviceCode = sprintf("%04X", oct( "0b$deviceCode" ) );
$devicename = $devicemodel.'_'.$deviceCode;
############ unknown ############
} else {
$devicename = 'unknown_please_select_model';
@ -2177,8 +2347,7 @@ sub SD_UT_Attr {
}
}
}
if ($cmd eq 'del' && $attrName eq 'model') { ### delete readings
elsif ($cmd eq 'del' && $attrName eq 'model') { ### delete readings
for my $readingname (qw/Button deviceCode LastAction state unknownMSG/) {
readingsDelete($hash,$readingname);
}
@ -2245,11 +2414,12 @@ sub SD_UT_tristate2bin {
<u>The following devices are supported:</u><br>
<ul>
<li>AC114-01 remote control&nbsp;&nbsp;&nbsp;<small>(module model: AC114_01, protocol 56)</small></li>
<li>BeSmart S4 remote control&nbsp;&nbsp;&nbsp;<small>(module model: BeSmart_S4, protocol 78)</small></li>
<li>Atlantic Security sensors&nbsp;&nbsp;&nbsp;<small>(module model: MD-2003R, MD-2018R,MD-210R, protocol 91|91.1)</small><br>
<code>&nbsp;&nbsp;&nbsp;Note: The model MD_230R (water) is recognized as MD-2018R due to the same hardware ID!</code></li>
<li>BeSmart S4 remote control&nbsp;&nbsp;&nbsp;<small>(module model: BeSmart_S4, protocol 78)</small></li>
<li>BF-301 remote control&nbsp;&nbsp;&nbsp;<small>(module model: BF_301, protocol 105)</small></li>
<li>BOSCH ceiling fan&nbsp;&nbsp;&nbsp;<small>(module model: SF01_01319004_Typ2, protocol 86)</small></li>
<li>Busch-Transcontrol HF - remote control 6861&nbsp;&nbsp;&nbsp;<small>(module model: TC6861, protocol 121)</small></li>
<li>CAME swing gate drive&nbsp;&nbsp;&nbsp;<small>(module model: CAME_TOP_432EV, protocol 86)</small></li>
<li>ChiliTec LED X-Mas light&nbsp;&nbsp;&nbsp;<small>(module model: Chilitec_22640, protocol 14)</small></li>
<li>ESTO ceiling lamp&nbsp;&nbsp;&nbsp;<small>(module model: KL_RF01, protocol 93)</small></li>
@ -2262,6 +2432,11 @@ sub SD_UT_tristate2bin {
<li>TR-502MSV (LIDL, LIBRA, MANDOLYN, QUIGG), compatible GT-7008BS, GT-FSI-04, DMV-7008S, Powerfix RCB-I 3600&nbsp;&nbsp;&nbsp;<small>(module model: TR_502MSV, protocol 34)</small></li>
<li>Manax RCS250&nbsp;&nbsp;&nbsp;<small>(module model: RC_10, protocol 90)</small></li>
<li>Medion OR28V&nbsp;&nbsp;&nbsp;<small>(module model: OR28V, protocol 68)</small></li>
<li>Meikee remote controls <small>(Protokoll 118)</small>
<ul><small>
<li>Meikee, 21 buttons, e.g. for Solar Flood Lights - module model: Meikee_21</li>
<li>Meikee, 24 buttons, e.g. for RGB LED Wallwasher Light - module model: Meikee_24</li>
</small></ul></li>
<li>mumbi AFS300-s (remote control RC-10, wireless socket RCS-22GS)&nbsp;&nbsp;&nbsp;<small>(module model: RC_10, protocol 90)</small></li>
<li>Momento (remote control for wireless digital picture frame)&nbsp;&nbsp;&nbsp;<small>(module model: Momento, protocol 97)</small></li>
<li>NAVARIS touch light switch Model No.: 44344.04&nbsp;&nbsp;&nbsp;<small>(module model: Navaris, protocol 99)</small></li>
@ -2279,8 +2454,9 @@ sub SD_UT_tristate2bin {
<li>SKX6xx, 6 button (GEIGER_GF0x03) - module model: Tedsen_SKX6xx</li>
</small></ul></li>
<li>unitec magnetic contact 47031 (for alarm systems Unitec 47121, Unitec 47125, Friedland)&nbsp;&nbsp;&nbsp;<small>(module model: Unitec_47031, protocol 30)</small></li>
<li>Visivo remote control for motorized screen&nbsp;&nbsp;&nbsp;<small>(module model: Visivo, Protokoll 24)</small></li>
<li>Visivo remote control for motorized screen&nbsp;&nbsp;&nbsp;<small>(module model: Visivo, protocol 24)</small></li>
<li>Westinghouse ceiling fan (remote control, 5 buttons without SET)&nbsp;&nbsp;&nbsp;<small>(module model: Buttons_five, protocol 29)</small></li>
<li>Westinghouse ceiling fan (remote control, 6 buttons with light dimmer)&nbsp;&nbsp;&nbsp;<small>(module model: Buttons_six, protocol 29)</small></li>
<li>Westinghouse Delancey ceiling fan (remote control, 9 buttons with SET)&nbsp;&nbsp;&nbsp;<small>(module model: RH787T, protocol 83)</small></li>
<li>Westinghouse ceiling fan Bendan (remote control TR60C-1, touch screen)&nbsp;&nbsp;&nbsp;<small>(module model: TR60C1, protocol 104)</small></li>
<li>xavax 00111939 (remote control, 10 button)&nbsp;&nbsp;&nbsp;<small>(module model: xavax, protocol 26)</small></li>
@ -2363,11 +2539,12 @@ sub SD_UT_tristate2bin {
<u>Westinghouse ceiling fan (Remote control with 5 button)</u>
<ul>
<a name="1_fan_low_speed"></a><li>1_fan_low_speed: button LOW on the remote</li>
<a name="2_fan_medium_speed"></a><li>2_fan_medium_speed: button MED on the remote</li>
<a name="3_fan_high_speed"></a><li>3_fan_high_speed: button HI on the remote</li>
<a name="light_on_off"></a><li>light_on_off: switch light on or off</li>
<a name="1_fan_low_speed"></a><li>1_fan_low_speed: button 1/LOW on the remote</li>
<a name="2_fan_medium_speed"></a><li>2_fan_medium_speed: button 2/MED on the remote</li>
<a name="3_fan_high_speed"></a><li>3_fan_high_speed: button 3/HI on the remote</li>
<a name="fan_off"></a><li>fan_off: turns off the fan</li>
<a name="light_on_off"></a><li>light_on_off: switch light on or off</li>
<a name="light_dimm"></a><li>light_dimm: light dimm</li>
</ul><br>
<u>Westinghouse Delancey ceiling fan (Remote control RH787T with 9 button + SET)</u>
@ -2396,25 +2573,25 @@ sub SD_UT_tristate2bin {
<li><a href="#ignore">ignore</a></li>
<li><a href="#IODev">IODev</a></li>
<li><a name="model"></a>model<br>
The attribute indicates the model type of your device (AC114_01B, BeSmart_S4, Buttons_five, CAME_TOP_432EV, Chilitec_22640, KL_RF01, HS1-868-BS, HSM4, QUIGG_DMV, LED_XM21_0, Momento, Navaris, Novy_840029, Novy_840039, OR28V, RC_10, RH787T, SA_434_1_mini, SF01_01319004, TR60C1, Tedsen_SKX1xx, Tedsen_SKX2xx, Tedsen_SKX4xx, Tedsen_SKX6xx, TR_502MSV, Unitec_47031, unknown).
The attribute indicates the model type of your device (AC114_01B, BeSmart_S4, Buttons_five, Buttons_six, CAME_TOP_432EV, Chilitec_22640, KL_RF01, HS1-868-BS, HSM4, QUIGG_DMV, LED_XM21_0, Meikee_21, Meikee_24, Momento, Navaris, Novy_840029, Novy_840039, OR28V, RC_10, RH787T, SA_434_1_mini, SF01_01319004, TC6861, TR60C1, Tedsen_SKX1xx, Tedsen_SKX2xx, Tedsen_SKX4xx, Tedsen_SKX6xx, TR_502MSV, Unitec_47031, unknown).
If the attribute is changed, a new device is created using <a href="#autocreate">autocreate</a>. Autocreate must be activated for this.
</li>
<li><a name="repeats"></a>repeats<br>
This attribute can be used to adjust how many repetitions are sent. Default is 5.
This attribute can be used to adjust how many repetitions are sent. Default is 5. Valid values are 1-99.
</li>
<li><a name="UTclock"></a>UTclock<br>
This attribute set the base clock when sending. There is no standard value.<br>
Exception: The model Novy_840039 has a preset base clock of 375. You can manually adjust this individually with this attribute.
</li>
<li><a name="UTfrequency"></a>UTfrequency<br>
An individual transmission frequency can be set with this attribute. If this attribute is not set, the transmission frequency of the IO device (e.g. Signalduino) is used.
An individual transmission frequency can be set with this attribute. If this attribute is not set, the transmission frequency of the IO device (e.g. Signalduino) is used. Valid values 300.00-999.99 Mhz.
</li>
</ul>
<br><br>
<b>Generated readings of the models</b><br>
<ul>
<u>AC114-01, Buttons_five, CAME_TOP_432EV, Chilitec_22640, HSM4, KL_RF01, LED_XM21_0, Momento, Novy_840029, Novy_840039, OR28V, QUIGG_DMV, RC_10, RH787T, SF01_01319004, SF01_01319004_Typ2, TR401, TR_502MSV, Visivo</u>
<u>AC114-01, Buttons_five, Buttons_six, CAME_TOP_432EV, Chilitec_22640, HSM4, KL_RF01, LED_XM21_0, Meikee_xx, Momento, Novy_840029, Novy_840039, OR28V, QUIGG_DMV, RC_10, RH787T, SF01_01319004, SF01_01319004_Typ2, TR401, TR_502MSV, Visivo</u>
<ul>
<li>deviceCode: Device code of the system</li>
<li>LastAction: Last executed action of the device (<code>receive</code> for command received | <code>send</code> for command send).</li>
@ -2462,11 +2639,12 @@ sub SD_UT_tristate2bin {
<u>Es werden bisher folgende Ger&auml;te unterst&uuml;tzt:</u><br>
<ul>
<li>AC114-01 Fernbedienung&nbsp;&nbsp;&nbsp;<small>(Modulmodel: AC114_01, Protokoll 56)</small></li>
<li>BeSmart S4 Fernbedienung&nbsp;&nbsp;&nbsp;<small>(Modulmodel: BeSmart_S4, Protokoll 78)</small></li>
<li>Atlantic Security Sensoren&nbsp;&nbsp;&nbsp;<small>(Modulmodel: MD-2003R, MD-2018R,MD-210R, Protokoll 91|91.1)</small><br>
<code>&nbsp;&nbsp;&nbsp;Hinweis: Das Model MD_230R (water) wird aufgrund gleicher Hardwarekennung als MD-2018R erkannt!</code></li>
<li>BeSmart S4 Fernbedienung&nbsp;&nbsp;&nbsp;<small>(Modulmodel: BeSmart_S4, Protokoll 78)</small></li>
<li>BF-301 Fernbedienung&nbsp;&nbsp;&nbsp;<small>(Modulmodel: BF_301, Protokoll 105)</small></li>
<li>BOSCH Deckenl&uuml;fter&nbsp;&nbsp;&nbsp;<small>(Modulmodel: SF01_01319004_Typ2, Protokoll 86)</small></li>
<li>Busch-Transcontrol HF - Handsender 6861&nbsp;&nbsp;&nbsp;<small>(Modulmodel: TC6861, Protokoll 121)</small></li>
<li>CAME Drehtor Antrieb&nbsp;&nbsp;&nbsp;<small>(Modulmodel: CAME_TOP_432EV, Protokoll 86)</small></li>
<li>ChiliTec LED Christbaumkerzen&nbsp;&nbsp;&nbsp;<small>(Modulmodel: Chilitec_22640, Protokoll 14)</small></li>
<li>ESTO Deckenlampe&nbsp;&nbsp;&nbsp;<small>(Modulmodel: KL_RF01, Protokoll 93)</small></li>
@ -2479,6 +2657,11 @@ sub SD_UT_tristate2bin {
<li>TR401 (Well-Light, Fernbedienung 4 Tasten)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: TR401, Protokoll 114)</small></li>
<li>Manax RCS250&nbsp;&nbsp;&nbsp;<small>(Modulmodel: RC_10, Protokoll 90)</small></li>
<li>Medion OR28V&nbsp;&nbsp;&nbsp;<small>(Modulmodel: OR28V, Protokoll 68)</small></li>
<li>Meikee Fernbedienungen <small>(Protokoll 118)</small>
<ul><small>
<li>Meikee, 21 Tasten, z.B. für Solar Flood Lights - Modulmodel: Meikee_21</li>
<li>Meikee, 24 Tasten, z.B. für RGB LED Wallwasher Light - Modulmodel: Meikee_24</li>
</small></ul></li>
<li>mumbi AFS300-s (Fernbedienung RC-10, Funksteckdose RCS-22GS)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: RC_10, Protokoll 90)</small></li>
<li>Momento (Fernbedienung f&uuml;r digitalen Bilderrahmen)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: Momento, Protokoll 97)</small></li>
<li>NAVARIS Funk-Licht-Schalter Model No.: 44344.04&nbsp;&nbsp;&nbsp;<small>(Modulmodel: Navaris, Protokoll 99)</small></li>
@ -2498,6 +2681,7 @@ sub SD_UT_tristate2bin {
<li>unitec Magnetkontakt 47031 (f&uuml;r Alarmanlagen Unitec 47121, Unitec 47125, Friedland)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: Unitec_47031, Protokoll 30)</small></li>
<li>Visivo Fernbedienung f&uuml;r Motorleinwand&nbsp;&nbsp;&nbsp;<small>(Modulmodel: Visivo, Protokoll 24)</small></li>
<li>Westinghouse Deckenventilator (Fernbedienung, 5 Tasten ohne SET)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: Buttons_five, Protokoll 29)</small></li>
<li>Westinghouse Deckenventilator (Fernbedienung, 6 Tasten mit Dimmer)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: Buttons_six, Protokoll 29)</small></li>
<li>Westinghouse Delancey Deckenventilator (Fernbedienung, 9 Tasten mit SET)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: RH787T, Protokoll 83)</small></li>
<li>Westinghouse Deckenventilator Bendan (Fernbedienung TR60C-1, Touch screen)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: TR60C1, Protokoll 104)</small></li>
<li>xavax 00111939 (Fernbedienung, 10 Tasten)&nbsp;&nbsp;&nbsp;<small>(Modulmodel: xavax, Protokoll 26)</small></li>
@ -2578,13 +2762,14 @@ sub SD_UT_tristate2bin {
<li>All_on / All_off: Alle Gruppen ein / aus</li>
</ul><br>
<u>Westinghouse Deckenventilator (Fernbedienung mit 5 Tasten)</u>
<u>Westinghouse Deckenventilator (Fernbedienung mit 5 oder 6 Tasten)</u>
<ul>
<a name="1_fan_low_speed"></a><li>1_fan_low_speed: Taste LOW auf der Fernbedienung</li>
<a name="2_fan_medium_speed"></a><li>2_fan_medium_speed: Taste MED auf der Fernbedienung</li>
<a name="3_fan_high_speed"></a><li>3_fan_high_speed: Taste HI auf der Fernbedienung</li>
<a name="light_on_off"></a><li>light_on_off: Licht ein-/ausschalten</li>
<a name="1_fan_low_speed"></a><li>1_fan_low_speed: Taste 1/LOW auf der Fernbedienung</li>
<a name="2_fan_medium_speed"></a><li>2_fan_medium_speed: Taste 2/MED auf der Fernbedienung</li>
<a name="3_fan_high_speed"></a><li>3_fan_high_speed: Taste 3/HI auf der Fernbedienung</li>
<a name="fan_off"></a><li>fan_off: Ventilator ausschalten</li>
<a name="light_on_off"></a><li>light_on_off: Licht ein-/ausschalten</li>
<a name="light_dimm"></a><li>light_dimm: Licht dimmen</li>
</ul><br>
<u>Westinghouse Delancey Deckenventilator (Fernbedienung RH787T mit 9 Tasten + SET)</u>
@ -2613,25 +2798,25 @@ sub SD_UT_tristate2bin {
<li><a href="#ignore">ignore</a></li>
<li><a href="#IODev">IODev</a></li>
<li><a name="model"></a>model<br>
Diese Attribut bezeichnet den Modelltyp Ihres Ger&auml;tes (AC114_01B, BeSmart_S4, Buttons_five, CAME_TOP_432EV, Chilitec_22640, KL_RF01, HS1-868-BS, HSM4, QUIGG_DMV, LED_XM21_0, Momento, Navaris, Novy_840029, Novy_840039, OR28V, RC_10, RH787T, SA_434_1_mini, SF01_01319004, TR60C1, Tedsen_SKX1xx, Tedsen_SKX2xx, Tedsen_SKX4xx, Tedsen_SKX6xx, TR_502MSV, Unitec_47031, unknown).
Diese Attribut bezeichnet den Modelltyp Ihres Ger&auml;tes (AC114_01B, BeSmart_S4, Buttons_five, Buttons_six, CAME_TOP_432EV, Chilitec_22640, KL_RF01, HS1-868-BS, HSM4, QUIGG_DMV, LED_XM21_0, Meikee_21, Meikee_24, Momento, Navaris, Novy_840029, Novy_840039, OR28V, RC_10, RH787T, SA_434_1_mini, SF01_01319004, TC6861, TR60C1, Tedsen_SKX1xx, Tedsen_SKX2xx, Tedsen_SKX4xx, Tedsen_SKX6xx, TR_502MSV, Unitec_47031, unknown).
Bei &Auml;nderung des Attributes wird ein neues Gerät mittels <a href="#autocreate">autocreate</a> erzeugt. Autocreate muss dazu aktiviert sein.
</li>
<li><a name="repeats"></a>repeats<br>
Mit diesem Attribut kann angepasst werden, wie viele Wiederholungen gesendet werden. Standard ist 5.
Mit diesem Attribut kann angepasst werden, wie viele Wiederholungen gesendet werden. Standard ist 5. Erlaubte Werte 1-99.
</li>
<li><a name="UTclock"></a>UTclock<br>
Mit diesem Attribut kann der Basistakt beim Senden eingestellt werden. Einen Standardwert gibt es nicht.<br>
Ausnahme: Das Model Novy_840039 hat einen voreingestellten Basistakt von 375. Auch diesen kann man mit dem Attribut individuell anpassen.
</li>
<li><a name="UTfrequency"></a>UTfrequency<br>
Mit diesem Attribut kann eine individuelle Sendefrequenz eingestellt werden. Ist dieses Attribut nicht gesetzt, wird die Sendefrequenz des IO Devices (z.B. Signalduino) verwendet.
Mit diesem Attribut kann eine individuelle Sendefrequenz eingestellt werden. Ist dieses Attribut nicht gesetzt, wird die Sendefrequenz des IO Devices (z.B. Signalduino) verwendet. Erlaubte Werte 300.00-999.99 Mhz.
</li>
</ul>
<br><br>
<b>Generierte Readings der Modelle</b><br>
<ul>
<u>AC114-01, BeSmart_S4, Buttons_five, CAME_TOP_432EV, Chilitec_22640, HSM4, KL_RF01, LED_XM21_0, Momento, Novy_840029, Novy_840039, OR28V, QUIGG_DMV, RC_10, RH787T, SF01_01319004, SF01_01319004_Typ2, TR401, TR_502MSV, Visivo</u>
<u>AC114-01, BeSmart_S4, Buttons_five, Buttons_six, CAME_TOP_432EV, Chilitec_22640, HSM4, KL_RF01, LED_XM21_0, Meikee_xx, Momento, Novy_840029, Novy_840039, OR28V, QUIGG_DMV, RC_10, RH787T, SF01_01319004, SF01_01319004_Typ2, TR401, TR_502MSV, Visivo</u>
<ul>
<li>deviceCode: Ger&auml;teCode des Systemes</li>
<li>LastAction: Zuletzt ausgef&uuml;hrte Aktion des Ger&auml;tes (<code>receive</code> f&uuml;r Kommando empfangen, <code>send</code> f&uuml;r Kommando gesendet).</li>