[SOLVED] Heatit z-trm2 anyone tried it in OH2?

@chris
just tested the change. It is throwing an exception now.

2018-07-24 20:20:56.234 [ome.event.ItemCommandEvent] - Item 'spHeatRoomSensor2' received command 12 °C

==> /var/log/openhab2/openhab.log <==

2018-07-24 20:20:56.247 [ERROR] [nal.common.AbstractInvocationHandler] - An error occurred while calling method 'ThingHandler.handleCommand()' on 'org.openhab.binding.zwave.handler.ZWaveThingHandler@16dfc00': org.eclipse.smarthome.core.library.types.QuantityType cannot be cast to org.eclipse.smarthome.core.library.types.DecimalType

java.lang.ClassCastException: org.eclipse.smarthome.core.library.types.QuantityType cannot be cast to org.eclipse.smarthome.core.library.types.DecimalType

	at org.openhab.binding.zwave.internal.converter.ZWaveThermostatSetpointConverter.receiveCommand(ZWaveThermostatSetpointConverter.java:133) [239:org.openhab.binding.zwave:2.4.0.201807241749]

	at org.openhab.binding.zwave.handler.ZWaveThingHandler.handleCommand(ZWaveThingHandler.java:1078) [239:org.openhab.binding.zwave:2.4.0.201807241749]

	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]

	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:?]

	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]

	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:?]

	at org.eclipse.smarthome.core.internal.common.AbstractInvocationHandler.invokeDirect(AbstractInvocationHandler.java:153) [94:org.eclipse.smarthome.core:0.10.0.201807081340]

	at org.eclipse.smarthome.core.internal.common.InvocationHandlerSync.invoke(InvocationHandlerSync.java:59) [94:org.eclipse.smarthome.core:0.10.0.201807081340]

	at com.sun.proxy.$Proxy182.handleCommand(Unknown Source) [239:org.openhab.binding.zwave:2.4.0.201807241749]

	at org.eclipse.smarthome.core.thing.internal.profiles.ProfileCallbackImpl.handleCommand(ProfileCallbackImpl.java:75) [101:org.eclipse.smarthome.core.thing:0.10.0.201807081340]

	at org.eclipse.smarthome.core.thing.internal.profiles.SystemDefaultProfile.onCommandFromItem(SystemDefaultProfile.java:49) [101:org.eclipse.smarthome.core.thing:0.10.0.201807081340]

	at sun.reflect.GeneratedMethodAccessor81.invoke(Unknown Source) ~[?:?]

	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]

	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:?]

	at org.eclipse.smarthome.core.internal.common.AbstractInvocationHandler.invokeDirect(AbstractInvocationHandler.java:153) [94:org.eclipse.smarthome.core:0.10.0.201807081340]

	at org.eclipse.smarthome.core.internal.common.Invocation.call(Invocation.java:53) [94:org.eclipse.smarthome.core:0.10.0.201807081340]

	at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]

	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]

	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]

	at java.lang.Thread.run(Thread.java:748) [?:?] 

I will test your binding tomorrow early and give you feedback.
Cheers

@chris: I believe it is solved now with this simple change

cheers

Ok, I’ll check this to see if how this is different to what’s in the binding at the moment. From a quick look, it looks similar, but I’ll check when I get a chance.

Thanks
Chris

I checcked the current binding and I think it’s pretty similar -:

        BigDecimal value;
        if (command instanceof QuantityType) {
            QuantityType<?> quantity = (QuantityType<?>) command;
            if (quantity.getUnit() == SIUnits.CELSIUS) {
                scale = 0;
            } else if (quantity.getUnit() == ImperialUnits.FAHRENHEIT) {
                scale = 1;
            }
            value = quantity.toBigDecimal();
        } else if (command instanceof DecimalType) {
            value = ((DecimalType) command).toBigDecimal();
        } else {
            logger.debug("NODE {}: Thermostat command received with unsupported type {}", node.getNodeId(),
                    command.getClass().getSimpleName());

            return null;
        }

Do you want to try this code in your version, or try the latest development version to see if it is working?

Online User Manual now available:

There they boast a 2.9 firmware. My device has 2.6.
@chris what is the best Firmware upgrade route do you think? Any plans to support OTA in OH2?

IC.
I have also contacted the manufacturer for advice.
Will report back when they reply.

The situation is pretty much as the post @sihui linked to. There are currently no known manufacturers who supply the updates - once a few start to release the binary files, then I’m happy to look at OTA in the binding (I’ve already implemented it in ZigBee where suppliers are more open to providing the binaries).

Jury is still out regarding the firmware file.
In the mean time, my local z-wave pusher had a 18% discount on the z-trm2 so I bought a few more :slight_smile:

Two of my thermostats are mounted as Power regulators (1-10 setting ON/OFF duty), mounted in another room.
The z-trm2 also supports this mode, but only as parameter 12 (even though doc states it does not)
image

Since I’m planning on monitoring the temperature using Aeon multisensor6 in the actual rooms I will need to set this parameter from a rule.

@chris Is it possible to make parameter 12 available via a channel, or is it possible to send new parameter values from a rule?

Yes, I will add this.

Unfortunately ESH doesn’t provide this feature (at the moment at least).

Nice.
While you’re at it:
image

Will make it possible to turn off display in bedroom at night :slight_smile:

Done…

I’ll do a binding update tonight or tomorrow…

1 Like

Did the new channels make it to?:

Should be included - the database was updated at the time I created.

I will test it. Could be a few days though …

Looking good:

Thanks!

1 Like

Looks like thermo-floor is OK with OTA update.
They sent me this file:Z-Therm2_EU_2_11.otz

@chris, time to try a OTA?

Hi Ole

I have the ztrm2 and i talked to heait a couple of days ago, they will publish firmware files soon. You only have the otz file, you need the bootloader also. I bought the sw cable that sells on elektroimportøren. As this was the easiet method to update them. Just take the zwave module out, and plug it into the computer and update firmware & bootloader.


Im thinking of changing gateways. Regarding z-therm2. (I dont have a floor sensor). So i need to the included room sensor in ztherm2 or use P mode. The internal sensor is garbage, and i want to use a multisensor 6 in the same room as ztherm2. Can openhab get data from that sensor and turn ztherm2 on and off based on that from that device? Then i need to set ztherm2 in P mode. Also what does the Parameter 12 do, does it specifiy how long it will be on before turning on, i see you use both value 2 and 5. Just curious what they do.

I was just thinking doing a rule that if temp < 20 degree -> turn on ztherm2. but only if people are home.
if no people are (at work or night mode) then if temp < 18 degrees -> turn on zhterm2. Else turn off

Im not so familiar with openhab so i dont know if they have home/night/away modes or if its easy to setup.

Have you actually done this?
The product manager over at Multireg says that you cannot use that plug with the z-trm2.
I also checked and it seems to be no connectors on the PCB, but there are 6 holes in the black cover.
Read more here.

The P setting for P mode, param12, made a channel by Chris resently in the development version of the z-wave binding, makes the z-trm2 work just as a power-regulator with settings 0-10, where 0 is always off, and 10 always on, and the rest is on/off dutycycles. 5 is 50%on 50%off.
One of my z-trm2 is placed in another room than the actual floor-heating I’m controlling, and I have also put a Multisensor 6 in the actual room and are planning on setting the P setting using a rule reading the Multisensor 6 temperature. I have not started on that rule yet, but it should be quite simple using the expire binding and check the temperature every 2-3 hrs or so.

Now the reason I want to use the P mode instead of direct on/off control, is that if OH goes down for some reason, the floor heating will not be stuck on ON, as that will turn my basement into a sauna :slight_smile:

As for your question of direct association between the z-trm2 and the ms6, I simply don’t know. Haven’t played with any kind of associations other than Lifeline.

No i havnt actually just read on “hjemmeautomasjon.no” that people did this trough homeseer or z-way with the provided .otz file you also had, but they have problems because the bootloader wasnt updated. If this is true i need to cancel my order to elektroimportøren.

Maybe i misread and people did the fw update on the old z-trm1. Will check and call heatit on monday

Sorry about that