FHEM und FritzBox 7240

Aus FHEMWiki
Version vom 24. Januar 2017, 16:24 Uhr von Krikan (Diskussion | Beiträge) (FHEM(R))
(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)

Instructions and recommendations for running FHEM on a FritzBox 7240.


  • flash CUL_V3.hex (from Atmel page)
  • attach CUL to Fritz!Box (with a USB Hub to have USB-Memory stick and CUL running at the same time)

Note: to check if CUL works, in enable USB-Fernanschluss in Fritz!Box Settings (Heimnetz - USB-Geräte - USB-Fernanschluss). Now it gets recognized as CUL868 (see Heimnetz - USB-Geräte - Geräteübersicht). Remember to disable it again. The CUL should be recognized as Es handelt sich um ein nicht unterstütztes USB-Gerät. This is OK!

Fritz!Box 7240

  • Update Fritz!Box to Firmware-Version >= 73.05.05
  • download FHEM
  • unzip and store at root of your USB-Memory stick in the folder "fhem" (this will be /var/InternerSpeicher/<yourUsbStickName>/fhem/ on you Fritz!Box lateron.
  • in this folder, adapt the file "startfhem" if you use more than one storage device (e.g. USB memory stick and 1&1 Online Speicher") with hardcoded destination folder for your fhem path:
  • Alternatively, disable "1&1 Online Speicher" and use USB memory stick only. This way you don't have to adapt startfhem.
  • to use telnet, it needs to be enabled via phone by dialing #96*7*. To login, use the same password as for Fritz!Box webfrontend. Now you can edit all of your files using vi in telnet.
  • Now define your "fhem.cfg" to match your configuration, e.g. starting with your housecode:
    define myCUL CUL /dev/ttyACM0 1234
  • finally start fhem in telnet:
  • or use autostart (see "Autostart FHEM " for details)

Open issues

Daily resets with big log files

After 1 week running perfectly I was seeing regular/daily resets. The problem in my setting is that I am using several FS20-STR. These devices every 2-3 minutes send off-for-timer or on-for-timers signals. These events get logged in the monthly log file. After this log was bigger than 1MB I have seen these resets. After I emptied/deleted the file the box is running stable again.

After looking into the details, it seems that the 7240 gets a memory problem when log files get bigger than ~800KB. I changed the logging from monthly files to weekly files (using ./log/fhem-%Y-%m-%V.log). This way, files should no longer get that big. Since then, 7240 runs stable without any problems.