I’m trying to get my PSR04 dimming functionality working with OH2, but fail miserably. After reading this and other threads, I’ve gotten it to report ON/OFF (either 0 or 100), but not the dimming level in between. @TheNetStriker, in what file did you do the change to PercentType?
On a little off-topic note since we all seem to share the weirdness of the PSR04, what device do you use to dim lights?
Hi Henrik, the file you are looking for is compiled into the Z-Wave plugin. So there is no easy way to change this. You would have to download the whole sourcecode, change the file, compile the Z-Wave plugin and install this plugin on your Openhab device.
@chris I’ve just tried to add this change in the Z-Wave device list, but I didn’t figure out how to change that part using the web interface. The property name of the “switch_dimmer” channel should be changed from “binding::OnOffType" to "binding::PercentType”. Could you please change this in the Z-Wave database so the dimmer can be used as an actual dimmer and not just an on/off switch? I have the z-wave plugin with this change running for over a year and I never had any problems.
Alright, thanks David! I thought i did have the source code and build environment, but after looking around a bit more, I now understand that the Z-Wave binding for OH2 is in a separate git repository, https://github.com/openhab/org.openhab.binding.zwave. I’ll give it a go and see if I can get it to work on my end.
When I adjust the dimming level on the PSR04 in vertical mode, I get the following updates:
dimmerButton01 changed from 28 to 0
dimmerButton01Switch changed from ON to OFF
...
dimmerButton01 changed from 0 to 62
dimmerButton01Switch changed from OFF to ON
When using it in horizontal mode, I get the following updates:
dimmerButton01 changed from 0 to 100
dimmerButton01Switch changed from OFF to ON
...
dimmerButton01 changed from 100 to 0
dimmerButton01Switch changed from ON to OFF
I’m not sure how to handle the change in the git repo, but it would be nice to see it included there. Are the thing definition files automatically generated from the device database? Ping @chris, if you have the time.