mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-07 22:29:19 +00:00
ENIGMA2: add TYPE and attr{model}
git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@4621 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
8b6c1a7c06
commit
0100157fa5
@ -24,7 +24,7 @@
|
||||
# along with fhem. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
#
|
||||
# Version: 1.2.5
|
||||
# Version: 1.2.6
|
||||
#
|
||||
# Major Version History:
|
||||
# - 1.2.0 - 2013-12-21
|
||||
@ -72,7 +72,7 @@ sub ENIGMA2_Initialize($) {
|
||||
$hash->{UndefFn} = "ENIGMA2_Undefine";
|
||||
|
||||
$hash->{AttrList} =
|
||||
"https:0,1 http-method:GET,POST disable:0,1 bouquet-tv bouquet-radio timeout "
|
||||
"https:0,1 http-method:GET,POST disable:0,1 bouquet-tv bouquet-radio timeout model "
|
||||
. $readingFnAttributes;
|
||||
|
||||
$data{RC_layout}{ENIGMA2_DreamMultimedia_DM500_DM800_SVG} =
|
||||
@ -206,6 +206,7 @@ sub ENIGMA2_GetStatus($;$) {
|
||||
)
|
||||
{
|
||||
my $i = 0;
|
||||
|
||||
# TODO this loop is >5.012 only
|
||||
for ( keys @{ $services_list->{e2service} } ) {
|
||||
my $channel =
|
||||
@ -406,7 +407,19 @@ sub ENIGMA2_GetStatus($;$) {
|
||||
$boxinfo->{e2about}{$e2reading} );
|
||||
}
|
||||
}
|
||||
|
||||
# model attribute
|
||||
if ( $reading eq "model" ) {
|
||||
my $model = $boxinfo->{e2about}{$e2reading};
|
||||
$model =~ s/\s/_/g;
|
||||
if ( !exists( $attr{$name}{model} )
|
||||
|| $attr{$name}{model} ne $model )
|
||||
{
|
||||
$attr{$name}{model} = $model;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
else {
|
||||
if ( !defined( $hash->{READINGS}{$reading}{VAL} )
|
||||
|| $hash->{READINGS}{$reading}{VAL} ne "-" )
|
||||
@ -1551,6 +1564,8 @@ sub ENIGMA2_Define($$) {
|
||||
return $msg;
|
||||
}
|
||||
|
||||
$hash->{TYPE} = "ENIGMA2";
|
||||
|
||||
my $address = $a[2];
|
||||
$hash->{helper}{ADDRESS} = $address;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user