Fritzbox DECT - Han Fun integration

Hi Guys,

wie the newer Fritz OS release, its possible to add third party Smart Home tools via DECT.
You can add Gadgets like this door contact:


It would be awesome if somebody can implement this.

Regards,
Dissi

with some help from your side I could do that…

What I need is the output form the query of your fritzbox. You have to use the fritzhome CLI tool from the python-ipmi project and dump your list with vebose output (option -v).

With that output it should be easy to do … maybe you should open an issue on the project github side: https://github.com/hthiery/python-fritzhome

1 Like

Hi,

thats no problem:

–>
##############################
name=Haustür Kontakt
ain=11934 0257995-1
id=2000
productname=HAN-FUN
manufacturer=0x0feb
present=True
##############################
name=Steckdose_Wohnwand
ain=08761 0375925
id=17
productname=FRITZ!DECT 200
manufacturer=AVM
present=True
Switch:
switch_state=False
Powermeter:
switch_power=0
switch_energy=12556
Temperature:
temperature=19.5
offset=0.0
##############################
name=Thermostat_Esszimmer
ain=09995 0004236
id=18
productname=FRITZ!DECT 301
manufacturer=AVM
present=True
Temperature:
temperature=22.0
offset=0.0
Thermostat:
battery_low=False
actual=22.0
target=22.0
comfort=22.0
eco=16.0
##############################
name=Thermostat_Wohnzimmer
ain=09995 0012259
id=20
productname=FRITZ!DECT 301
manufacturer=AVM
present=True
Temperature:
temperature=22.5
offset=0.0
Thermostat:
battery_low=False
actual=22.5
target=22.0
comfort=22.0
eco=16.0
##############################
name=Haustür
** ain=11934 0257995**
** id=408**
** productname=HAN-FUN**
** manufacturer=0x0feb**
** present=True**
##############################
name=FRITZ!DECT Repeater 100_Esszimmer
ain=11657 0183011
id=21
productname=FRITZ!DECT Repeater 100
manufacturer=AVM
present=True
Temperature:
temperature=19.5
offset=0.0
##############################
name=Thermostat_Bad
ain=09995 0029678
id=22
productname=FRITZ!DECT 301
manufacturer=AVM
present=True
Temperature:
temperature=22.0
offset=0.0
Thermostat:
battery_low=False
actual=22.0
target=18.0
comfort=24.0
eco=18.0
##############################
name=Thermostat_Clara
ain=09995 0031380
id=23
productname=FRITZ!DECT 301
manufacturer=AVM
present=True
Temperature:
temperature=22.5
offset=0.0
Thermostat:
battery_low=False
actual=22.5
target=18.0
comfort=22.0
eco=18.0
<–

An other feature request will be, the Fritz Dect 100 Repeater have a temp sensore. It would be great if the fritzhome can use that sensor as well.

Is there something else what i could do?

Regards,
Dissi

Thanks … Could you please give the output with -v Option. So the RAW XML is displayed.

Here it comes:

INFO:pyfritzhome.fritzhome:<xml.dom.minidom.Document object at 0x7ff047e1e108>
DEBUG:pyfritzhome.fritzhome:<device functionbitmask="8208" fwversion="0.0" id="2000" identifier="11934 0257995-1" manufacturer="0x0feb" productname="HAN-FUN">
    <present>1</present>
    <name>Haustür Kontakt</name>
    <etsiunitinfo>
        <etsideviceid>408</etsideviceid>
        <unittype>514</unittype>
        <interfaces>256</interfaces>
    </etsiunitinfo>
    <alert>
        <state>0</state>
    </alert>
</device>

DEBUG:pyfritzhome.fritzhome:<device functionbitmask="2944" fwversion="04.09" id="17" identifier="08761 0375925" manufacturer="AVM" productname="FRITZ!DECT 200">
    <present>1</present>
    <name>Steckdose_Wohnwand</name>
    <switch>
        <state>0</state>
        <mode>manuell</mode>
        <lock>0</lock>
        <devicelock>0</devicelock>
    </switch>
    <powermeter>
        <voltage>222095</voltage>
        <power>0</power>
        <energy>12556</energy>
    </powermeter>
    <temperature>
        <celsius>195</celsius>
        <offset>0</offset>
    </temperature>
</device>

DEBUG:pyfritzhome.fritzhome:<device functionbitmask="320" fwversion="04.70" id="18" identifier="09995 0004236" manufacturer="AVM" productname="FRITZ!DECT 301">
    <present>1</present>
    <name>Thermostat_Esszimmer</name>
    <temperature>
        <celsius>220</celsius>
        <offset>0</offset>
    </temperature>
    <hkr>
        <tist>44</tist>
        <tsoll>44</tsoll>
        <absenk>32</absenk>
        <komfort>44</komfort>
        <lock>0</lock>
        <devicelock>1</devicelock>
        <errorcode>0</errorcode>
        <batterylow>0</batterylow>
        <windowopenactiv>0</windowopenactiv>
        <battery>40</battery>
        <nextchange>
            <endperiod>1538244000</endperiod>
            <tchange>32</tchange>
        </nextchange>
        <summeractive>0</summeractive>
        <holidayactive>0</holidayactive>
    </hkr>
</device>
DEBUG:pyfritzhome.fritzhome:<device functionbitmask="320" fwversion="04.70" id="20" identifier="09995 0012259" manufacturer="AVM" productname="FRITZ!DECT 301">
    <present>1</present>
    <name>Thermostat_Wohnzimmer</name>
    <temperature>
        <celsius>215</celsius>
        <offset>0</offset>
    </temperature>
    <hkr>
        <tist>43</tist>
        <tsoll>44</tsoll>
        <absenk>32</absenk>
        <komfort>44</komfort>
        <lock>0</lock>
        <devicelock>0</devicelock>
        <errorcode>0</errorcode>
        <batterylow>0</batterylow>
        <windowopenactiv>0</windowopenactiv>
        <battery>50</battery>
        <nextchange>
            <endperiod>1538251200</endperiod>
            <tchange>32</tchange>
        </nextchange>
        <summeractive>0</summeractive>
        <holidayactive>0</holidayactive>
    </hkr>
</device>

DEBUG:pyfritzhome.fritzhome:<device functionbitmask="1" fwversion="00.00" id="408" identifier="11934 0257995" manufacturer="0x0feb" productname="HAN-FUN">
    <present>1</present>
    <name>Haustür</name>
</device>

DEBUG:pyfritzhome.fritzhome:<device functionbitmask="1280" fwversion="04.09" id="21" identifier="11657 0183011" manufacturer="AVM" productname="FRITZ!DECT Repeater 100">
    <present>1</present>
    <name>FRITZ!DECT Repeater 100_Esszimmer</name>
    <temperature>
        <celsius>190</celsius>
        <offset>0</offset>
    </temperature>
</device>
DEBUG:pyfritzhome.fritzhome:<device functionbitmask="320" fwversion="04.70" id="22" identifier="09995 0029678" manufacturer="AVM" productname="FRITZ!DECT 301">
    <present>1</present>
    <name>Thermostat_Bad</name>
    <temperature>
        <celsius>225</celsius>
        <offset>0</offset>
    </temperature>
    <hkr>
        <tist>45</tist>
        <tsoll>48</tsoll>
        <absenk>36</absenk>
        <komfort>48</komfort>
        <lock>0</lock>
        <devicelock>0</devicelock>
        <errorcode>0</errorcode>
        <batterylow>0</batterylow>
        <windowopenactiv>0</windowopenactiv>
        <battery>100</battery>
        <nextchange>
            <endperiod>1538245800</endperiod>
            <tchange>36</tchange>
        </nextchange>
        <summeractive>0</summeractive>
        <holidayactive>0</holidayactive>
    </hkr>
</device>

DEBUG:pyfritzhome.fritzhome:<device functionbitmask="320" fwversion="04.70" id="23" identifier="09995 0031380" manufacturer="AVM" productname="FRITZ!DECT 301">
    <present>1</present>
    <name>Thermostat_Clara</name>
    <temperature>
        <celsius>215</celsius>
        <offset>0</offset>
    </temperature>
    <hkr>
        <tist>43</tist>
        <tsoll>44</tsoll>
        <absenk>36</absenk>
        <komfort>44</komfort>
        <lock>0</lock>
        <devicelock>0</devicelock>
        <errorcode>0</errorcode>
        <batterylow>0</batterylow>
        <windowopenactiv>0</windowopenactiv>
        <battery>100</battery>
        <nextchange>
            <endperiod>1535691600</endperiod>
            <tchange>44</tchange>
        </nextchange>
        <summeractive>0</summeractive>
        <holidayactive>0</holidayactive>
    </hkr>
</device>

INFO:pyfritzhome.fritzhome:logout

PR is in progress … support for alarm modules should be available in next release.

But unfortunatly the update poll interval is ~30 seconds since there is no push support for fritzbox as far as I know

1 Like

great, special thanks.

did you also implement the temp sensor of the dect 100 repeaters?

at the moment only the binary sensor for the alarm window contact

The sensor works so far, but is there any chance to get a smaller intervall on that sensor. 30 seconds are a lot of time to open and close a door. in some cases home assisstant didn’t reconize the status change.

Hi,

my current understanding is that the only way to get the alarm state is to receive the whole devicelist (all attached devices at the fritzbox). Since this take some time (dont know the exact time … but I think it is about seconds) it is no good idea to decrease the poll interval.

For your desired application (monitoring door) this is for sure not sufficient.

Hi, im looking for a solution as well. The last weeks i set up Hass.io on a Pi2. Zigbee, HomeKit etc. are working fine. For my windows and doors are the sensors above in use. Now my problem… ím not very familiar with programming sensors and dońt know where i do need to put in the commands etc.

I saw your post above. I think to use the integration, the fritzbox integration is mendatory!? The integration is already working on my Hass.io, but sensors are not found :frowning: Might be you could explain how to implement the connected HAN FUN sensors into Hass.io for newbies :wink: Thank you in advance!

Hi ,

could you please try to integrate this device:
HAN-FAN an DECT-ULE button from D.Telekom 

DEBUG:pyfritzhome.fritzhome:<device functionbitmask="8200" fwversion="0.0" id="2000" identifier="11934 0097821-2" manufacturer="0x0feb" productname="HAN-FUN">
	<present>1</present>
	<txbusy>0</txbusy>
	<name>HAN-FUN #1 - F2</name>
	<etsiunitinfo>
		<etsideviceid>406</etsideviceid>
		<unittype>273</unittype>
		<interfaces>772</interfaces>
	</etsiunitinfo>
	<button>
		<lastpressedtimestamp>1578591021</lastpressedtimestamp>
	</button>
</device>

DEBUG:pyfritzhome.fritzhome:<device functionbitmask="8200" fwversion="0.0" id="2001" identifier="11934 0097821-1" manufacturer="0x0feb" productname="HAN-FUN">
	<present>1</present>
	<txbusy>0</txbusy>
	<name>HAN-FUN #1 - F1</name>
	<etsiunitinfo>
		<etsideviceid>406</etsideviceid>
		<unittype>273</unittype>
		<interfaces>772</interfaces>
	</etsiunitinfo>
	<button>
		<lastpressedtimestamp>1578591022</lastpressedtimestamp>
	</button>
</device>


DEBUG:pyfritzhome.fritzhome:<device functionbitmask="1" fwversion="31.20" id="406" identifier="11934 0097821" manufacturer="0x0feb" productname="HAN-FUN">
	<present>1</present>
	<txbusy>0</txbusy>
	<name>Taster1</name>
</device>

Hello,

I am also interested in being able to switch your socket. Is there a stage of development here? They are really good IP67 sockets.

Data:
Smart Home Device
ModelHAN-FUN
Actuator identification number (AIN)11324 0xyzxyz
Version 30.17.04.02.018

Thanks very much