Closed lewie closed 3 years ago
Can confirm the problem for controlling my heating (get values from 0.0 to 1.0 instead of 0.0 - 100.0 [%]). I thought with the new UoM system that could be solved but it couldn't.
After some testing I can add the following observations:
Stopping and starting OH2 alone has no effect in these cases. I have run These Tests on a RPi 3b+ as well as on a Ubuntu VM (18.04 LTS Server) on my Qnap Intel NAS.
Now this is where it gets REALLY weird. The above stated problem with the DPT types behaves DIFFERENTLY on an RPi as it does on my Ubuntu VM:
Both installations run the same 2.4 snapshot and have been installed using the OPENHABIAN.iso (RPi) and the repository to install on Ubuntu respectively.
@zaphood1967, I think "this very same configuration" of Items and Things is not exactly the same? I have tested now on a RPI on a standard Debian and Windows. I get exactly same behavior. If configuration is dimmer/dimmer (which is the correct configuration) there where no problems at all!
I suspect another error somewhere in your Item/Tings configuration.
@bjoernbrings, Items AND Things both have to be configured as Dimmer not as Number!! Then it works.
Dimmer Heizung_Stellwert_EG_Flur "Heizung Stellwert EG Flur [%d %%]" (EG_Flur, Temperatur, Temperatur_EG) {channel="knx:device:MDTBridge:MDT_AKH_EG:Kanal_C_stell"}
Dimmer Heizung_Stellwert_EG_Flur_test "Heizung Test Stellwert EG Flur [%d %%]" (EG_Flur, Temperatur, Temperatur_EG) {channel="knx:device:MDTBridge:MDT_AKH_EG:Kanal_C_stell"}
and in things file use like: (Type dimmer!)
Type dimmer :Kanal_C_stell "Kanal_C_stell" [ position="<0/2/22" ] // 1 byte K L - U - Prozent (0..100%)
Thanks for the hint will give it a try.
Anyways it sounds very unintuitive to me having to configure a heating as dimmer to get correct values.
In fact, I copied the entire config-files from the RPi over to the VM (only changing the KNX HW adress of the machine in the knx.things file). So I would consider this as much identical as it can get between two slightly different OS environments?
Additionally, on the VM I was unable to receive just any data for 3 additional GA which did not work even after several reboots, leaving me somewhat puzzled.
Not sure what makes this Binding kind of tick differently here.
@bjoernbrings, knx2 is relatively new, we have to improve it bit by bit. @zaphood1967, currently I can not come up with a solution or reproduce the behavior. But I will keep your observation in mind.
Nothing more than a "me too" from my side. I would expect 48 (%) here but get 0.48 instead:
2018-11-09 00:05:26.296 [vent.ItemStateChangedEvent] - Heating_Rez_SalleDeBainParents_Status changed from 0.49000000 to 0.48000000
I'm currently migrating my OpenHAB 1.8 installation to 2.4.0-M5, redoing my KNX config (well, using Python to automate most of the things).
I have channels defined as numbers:
Type number : Heating_SS_Disponible_Status "Disponible [%d %%]" [ ga="5.001:<5/2/20" ]
Number Heating_SS_Disponible_Status "Disponible [%d %%]" <heating> (Heating) { channel="knx:device:bridge:generic:Heating_SS_Disponible_Status" }
See updated comment here https://github.com/openhab/openhab2-addons/issues/4146#issuecomment-439604804
Another "me too" from my side. On openHAB Version 2.3, the workaround described by @lewie and @zaphood1967 in (https://github.com/openhab/openhab2-addons/issues/4146) works for me with Channel configured as Number and Item configured as Dimmmer: knx.things:
Thing device foo [
...
] {
Type number: ActuatingValue [ ga="5.001:<4/5/40" ]
...
}
knx.items:
Dimmer HVAC_AV_A "ActuatingValue [%d %%]" <heating> {channel="knx:device:bridge:foo:ActuatingValue"}
closed due to inactivity
Tested on a 2.4.0-SNAPSHOT Build #1401 on Windows, with only KNX2 binding installed.
Expected Behavior
Current Behavior
DTP 5.001 correctly configured to get percent value: KNX Thing in ./conf/things/*.thing: it normally has to be Type dimmer
KNX Item in ./conf/items/*.item: it normally has to be Dimmer Item
Log output: Use dimmer thing as Dimmer Item:
Use dimmer thing as Number Item:
When I switch my thing to Type number or Item AND Thing to number, I get no update from the KNX bus anymore. It does not matter if i have defined my thing with or without DTP definition
position="5.001:<0/2/42"
.It would be desirable if we could define DTP 5.001 alternatively as a number in the Things. It seems to me at least not logical because this behavior leads to confusion.
The loosing of the KNX packets is not correct. In addition, the KNX binding does not even raise a warning for this case.
Originally we discussed here: https://github.com/openhab/openhab2-addons/issues/4146