[SOLVED] Fritz!dect/Comet!dect no success writing temperature values

environment is Raspi3+, Fritz!Box 7590, OS 7.01, OpenHAB 2.4, AVM FRITZ! Binding

I want to rise or reduce temperature settings of fritz!dect 301 and/or comet!dect regulator.
Here is my item:

Number fritzDect_Bad1OG_comfort_temp { channel="avmfritz:FRITZ_DECT_301:x_x_x_x:ain:comfort_temp" }

It works. I can read temperature and log it.
I made a pushbutton switch to trigger an event.
The button works too. The event is triggered and the rule runs.
The rule shall rise temperatur for 1°C

    rule "Testschalter"
        when Item Testschalter received update
            var Number nSoll = fritzDect_Bad1OG_comfort_temp.state
            //fritzDect_Bad1OG_comfort_temp.postUpdate(nSoll + 1)
            fritzDect_Bad1OG_comfort_temp.sendCommand(nSoll + 1)

I tried sendCommand and postUpdate. Both the same result.
The log shows what happens:

2019-03-16 16:49:44.019 [ome.event.ItemCommandEvent] - Item 'fritzDect_Bad1OG_comfort_temp' received command 24.5

2019-03-16 16:49:44.029 [nt.ItemStatePredictedEvent] - fritzDect_Bad1OG_comfort_temp predicted to become 24.5

2019-03-16 16:49:44.037 [vent.ItemStateChangedEvent] - fritzDect_Bad1OG_comfort_temp changed from 23.5 to 24.5

2019-03-16 16:49:57.148 [vent.ItemStateChangedEvent] - fritzDect_Bad1OG_comfort_temp changed from 24.5 to 23.5

Temperature rises for a short time and is reset to the previous value then. I think the reset happens exactly when the 15sec. polltime of the dect components are over and the value is fetched back from the Fritz!Box.

So something works wrong. I have no idea. The Fritz!Box and all other things are included via inbox. I can log any changes on the regulators/valves. But no writing possible. Must I manually create instances or variables of the things which hold the value after change? I did not code any thing manually. All things discovered by inbox and listed in PaperUI.

I do not know exactly, but I think that the “Comfort-Item/Channel” is read-only. So what you can do is to send the result of your calculation to your “Set-Point-Item”.


Number:Temperature            radiator_valve_01_Set             "Thermostat Büro Richtwert [%.1f %unit%]"                             <heating1>        (EG_Buro,gRFritz_01,gRtSoll)                      { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119601003400:set_temp" }
Number:Temperature            radiator_valve_01_Eco             "Thermostat Büro Richtwert Eco [%.1f %unit%]"                         <dect301>         (EG_Buro,gRFritz_01)                              { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119601003400:eco_temp" }
Number:Temperature            radiator_valve_01_Comfort         "Thermostat Büro Richtwert Komfort [%.1f %unit%]"                     <dect301>         (EG_Buro,gRFritz_01)                              { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119601003400:comfort_temp" }

and your Rule should look like (I used my set-Up):

   rule "Testschalter"
        when Item Testschalter received update
            var Number nSoll = radiator_valve_01_Comfort.state
            //radiator_valve_01_Comfort.postUpdate(nSoll + 1)
            radiator_valve_01_Set.sendCommand(nSoll + 1)

But what if you want to expand or reduce it around 2 or 3,5 degrees ? Every Time changing your rule ?
I think there are easier ways.

My Sitemap looks like this

And this is the Frame which i’m usingh in my Sitemap

  Frame label="Heizkörpersteuerung" icon="heating"
      //Image url="" // Test with local images via http from the icon(s)-folder
      Group item=gRtIstI
      Group item=gRtSoll
      Setpoint item=radiator_valve_01_Set minValue=16.0 maxValue=25.0 step=0.5
      Selection item=radiator_valve_01_Mode mappings=["ON"="ON", "OFF"="OFF", "COMFORT"="COMFORT", "ECO"="ECO", "BOOST"="BOOST", "WINDOW_OPEN"="Fenster offen"] icon="heating"
      Setpoint item=radiator_valve_02_Set minValue=16.0 maxValue=25.0 step=0.5
      Selection item=radiator_valve_02_Mode mappings=["ON"="ON", "OFF"="OFF", "COMFORT"="COMFORT", "ECO"="ECO", "BOOST"="BOOST", "WINDOW_OPEN"="Fenster offen"] icon="heating"
      Setpoint item=radiator_valve_04_Set minValue=16.0 maxValue=25.0 step=0.5
      Selection item=radiator_valve_04_Mode mappings=["ON"="ON", "OFF"="OFF", "COMFORT"="COMFORT", "ECO"="ECO", "BOOST"="BOOST", "WINDOW_OPEN"="Fenster offen"] icon="heating"
      Setpoint item=radiator_valve_03_Set minValue=16.0 maxValue=25.0 step=0.5
      Selection item=radiator_valve_03_Mode mappings=["ON"="ON", "OFF"="OFF", "COMFORT"="COMFORT", "ECO"="ECO", "BOOST"="BOOST", "WINDOW_OPEN"="Fenster offen"] icon="heating"
      Setpoint item=radiator_valve_05_Set minValue=16.0 maxValue=25.0 step=0.5
      Selection item=radiator_valve_05_Mode mappings=["ON"="ON", "OFF"="OFF", "COMFORT"="COMFORT", "ECO"="ECO", "BOOST"="BOOST", "WINDOW_OPEN"="Fenster offen"] icon="heating"
      Setpoint item=radiator_valve_06_Set minValue=16.0 maxValue=25.0 step=0.5
      Selection item=radiator_valve_06_Mode mappings=["ON"="ON", "OFF"="OFF", "COMFORT"="COMFORT", "ECO"="ECO", "BOOST"="BOOST", "WINDOW_OPEN"="Fenster offen"] icon="heating"
  } //  Ende "Heizkörpersteuerung"  

Just using the Set and Mode- Items with the Setpoint and the Selection-Widgets in the Sitemap.

Try it.


1 Like

Thank you Peter,

for your advice. I will try it out.

Background of my efforts ist that I have 4 Lacrosse temperature sensors, connected with a Jeelink-USB-Stick to my Raspi. I read the room termperature, calculate the offset to the valves temperature und get a setpoint which I write to the valvs set_temp.
I tried to write set_temp, comfort_temp and to change radiator_mode to MANUAL. Always the same effect. The values I write are resetted to the original value before.

But you have a solution that works an I will adapt my attempts and try if it will work for me.

As you see above in the extract of my .items-File, that i’m using the UoM. So i tinkered a bit with your Rule and the measurement (Suffix/Pattern/Formatter e.g. km/h or °C). Often problems come up, when calculating or comparing values. But i got it work for me.

rule "Testschalter"
        when Item Dummy4 changed to ON
            var Number nSoll = (radiator_valve_01_Comfort.state as Number).floatValue
            logInfo("Test AVM Temp","Neue SollTemperatur ist: " + nSoll)
            nSoll = nSoll + 1
            logInfo("Test AVM Temp","Neue SollTemperatur ist: " + nSoll + " Radiator:" + radiator_valve_01_Set)

I think this will work and the State of your Mode-Item will change to “ON” and stay there :wink:. But as I said above, there is no chance to change the modes of the Fritz/Comet-Thermostates as they are read-only.
(So in your case you will read the actual temp of your valve and compare it against your sensor and if there’s a difference --> set Temp, or something like that :thinking:)


Hope this can help you.

1 Like


I tried around with the setpoint in your first post but same result as befor. Values do reset. It seems like there is a write protection on the Fritzbox.
Maybe there is trouble with the types. But setpoint bypasses the rule and writes directly to the item and the log shows that the value is written to the OpenHAB item. So the number type shoult be ok.

I now removed all dect items, the Fritzbox and the binding. I did a complete restart and will go on tomorrow.

Thank you.

I reinstalled the binding and one Comet dect valve for testing.
Changing set_temp values by rule or directly via setpoint in the sitemap works now.
Other values seem to be read only.
PostUpdate in the rule does not work. SendCommand does.
Changed values are applied to the Fritzbox and transfered to the valve later.
So everything is ok an works as it should do. Now I can access the temperature from the Lacrosse sensors and the :temperature values of the valves and calculate the set_temp value for the valves.
Thank you for your support Peter.
Have a nice sunday!

I’m happy, hearing everything’s fine now.
The Set-Up for the Comet is the same as for the Dect301.Here an example:

//Thermostat im Kinderzimmer 2 (Comet Dect)         
Group                         gRFritz_02                        "Thermostat Fritz RF02 Gast"                                          <dect301>         (gFritz)                                          // RF stands for Radiator-Fritz
Number:Temperature            radiator_valve_02                 "Temp. Gast aktuell[%.1f %unit%]"                                     <heating1>        (EG_Kind2,gRFritz_02,gRtIstI)                     { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:actual_temp" }
Number:Temperature            radiator_valve_02_Set             "Thermostat Gast Richtwert [%.1f %unit%]"                             <heating1>        (EG_Kind2,gRFritz_02,gRtSoll)                     { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:set_temp" }
Number:Temperature            radiator_valve_02_Eco             "Thermostat Gast Richtwert Eco [%.1f %unit%]"                         <dect301>         (EG_Kind2,gRFritz_02)                             { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:eco_temp" }
Number:Temperature            radiator_valve_02_Comfort         "Thermostat Gast Richtwert Komfort [%.1f %unit%]"                     <dect301>         (EG_Kind2,gRFritz_02)                             { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:comfort_temp" }
String                        radiator_valve_02_ModeX           "Heizkörper Gast Modus 02 [%s]"                                       <dect301>         (EG_Kind2,gRFritz_02)                             { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:mode" }
String                        radiator_valve_02_Mode            "Heizkörper Gast Modus [%s]"                                          <dect301>         (EG_Kind2,gRFritz_02)                             { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:radiator_mode" }
Switch                        radiator_valve_02_Battery         "Batterie Gast Zustand [MAP(battery.map):%s]"                         <lowbattery>      (EG_Kind2,gRFritz_02,gWart)                       { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:battery_low" }
Number                        radiator_valve_02_Battery_Level   "Batterie Gast Level [%d %%]"                                         <batterylevel>    (EG_Kind2,gRFritz_02,gBattLevel)                  { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:battery_level" }
Contact                       radiator_valve_02_locked          "Thermostat Gast Sperre extern [MAP(fritz.map):%s]"                   <lock>            (EG_Kind2,gRFritz_02)                             { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:locked" }
Contact                       radiator_valve_02_dev_locked      "Thermostat Gast Sperre intern [MAP(fritz.map):%s]"                   <lock>            (EG_Kind2,gRFritz_02)                             { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:device_locked" }
DateTime                      radiator_valve_02_next_change     "Umschalt-Zeitpunkt Gast [%1$tH:%1$tM]"                               <time>            (EG_Kind2,gRFritz_02)                             { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:next_change" }
Number:Temperature            radiator_valve_02_next_temp       "Umschalt-Temperatur Gast [%.1f %unit%]"                              <temperature>     (EG_Kind2,gRFritz_02)                             { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:next_temp" }
//Number:Temperature            radiator_valve_02_Temp            "Thermostat Gast Temperatur [%.1f %unit%]"                            <temperature>     (EG_Kind2,gRFritz_02,gRtSoll)                     { channel="avmfritz:Comet_DECT:Fritz-Box-7490:119600949320:temperature" }
//Thermostat ELW Wohnzimmer - ain 09995 0077350         
Group                         gRFritz_03                        "Thermostat Fritz RF03 ELW Wohnen"                                    <dect301>         (gFritz)                                          // RF stands for Radiator-Fritz
Number:Temperature            radiator_valve_03                 "Temp. ELW Wohnen aktuell[%.1f %unit%]"                               <heating1>        (UG_WohnenEssen,gRFritz_03,gRtIstI)               { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:actual_temp" }
Number:Temperature            radiator_valve_03_Set             "Thermostat ELW Wohnen Richtwert [%.1f %unit%]"                       <heating1>        (UG_WohnenEssen,gRFritz_03,gRtSoll)               { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:set_temp" }
Number:Temperature            radiator_valve_03_Eco             "Thermostat ELW Wohnen Richtwert Eco [%.1f %unit%]"                   <dect301>         (UG_WohnenEssen,gRFritz_03)                       { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:eco_temp" }
Number:Temperature            radiator_valve_03_Comfort         "Thermostat ELW Wohnen Richtwert Komfort [%.1f %unit%]"               <dect301>         (UG_WohnenEssen,gRFritz_03)                       { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:comfort_temp" }
String                        radiator_valve_03_ModeX           "Heizkörper ELW Wohnen Modus 03 [%s]"                                 <temperature>     (UG_WohnenEssen,gRFritz_03)                       { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:mode" }
String                        radiator_valve_03_Mode            "Heizkörper ELW Wohnen Modus [%s]"                                    <temperature>     (UG_WohnenEssen,gRFritz_03)                       { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:radiator_mode" }
Switch                        radiator_valve_03_Battery         "Batterie ELW Wohnen Zustand [MAP(battery.map):%s]"                   <lowbattery>      (UG_WohnenEssen,gRFritz_03,gWart)                 { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:battery_low" }
Number                        radiator_valve_03_Battery_Level   "Batterie ELW Wohnen Level [%d %%]"                                   <batterylevel>    (UG_WohnenEssen,gRFritz_03,gBattLevel)            { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:battery_level" }
Contact                       radiator_valve_03_locked          "Thermostat ELW Wohnen Sperre extern [MAP(fritz.map):%s]"             <lock>            (UG_WohnenEssen,gRFritz_03)                       { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:locked" }
Contact                       radiator_valve_03_dev_locked      "Thermostat ELW Wohnen Sperre intern [MAP(fritz.map):%s]"             <lock>            (UG_WohnenEssen,gRFritz_03)                       { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:device_locked" }
DateTime                      radiator_valve_03_next_change     "Umschalt-Zeitpunkt ELW Wohnen [%1$tH:%1$tM]"                         <time>            (UG_WohnenEssen,gRFritz_03)                       { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:next_change" }
Number:Temperature            radiator_valve_03_next_temp       "Umschalt-Temperatur ELW Wohnen [%.1f %unit%]"                        <temperature>     (UG_WohnenEssen,gRFritz_03)                       { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:next_temp" }
//Number:Temperature            radiator_valve_03_Temp            "Thermostat ELW Wohnen Temperatur [%.1f %unit%]"                      <temperature>     (UG_WohnenEssen,gRFritz_03,gRtSoll)               { channel="avmfritz:FRITZ_DECT_301:Fritz-Box-7490:099950077350:temperature" }

You have to know that commands, sent by OH2 can take up to 15 Minutes, until the valve will react (that’s what AVM says). But under normal circumstances it will take a minute +/-.

For the Difference between postUpdate and sendCommand pls. have a look here in the Docs how to manipulate Item States

Thank you for further instructions.
I think 15 minutes is true. Nothing is send to the valves. So they do not have to receive and save energy. They connect every 15 minutes to the Fritzbox and load values. Then they react. I do confirm this.