[knx2] Issue with Scene Number

How does your .things file look like?
In your things file your can assign a specific datatype to you group address, like this for example:

        Type number        : sceneKeuken            "Scene keuken"             [ ga="17.001:3/0/4" ]

That is the correct behavior. Please keep in mind, that although knx Scenes are numbered from 1 to 64, it‘s encoded from 0 to 63 . In fact, bits 0 to 5 are the scene Number ( minus 1) and bit 7 is read or write. Bit 6 is reserved and must be 0.

1 Like

Hello,

I forgot to mention this.
My channel is configured this way using the paperui

image

As I did not mention this in my last posting…

Knx Scene 1 is openHAB Scene 0. openHAB does the Scene numbering from 0 to 63, where knx does it from 1 to 64, but as said before, 0 to 63 is the data representation on the knx bus, only ETS is translating the numbers, and that is the meaning of $01 | 2 (the hex value $01 represents the human readable value 2)

1 Like

Ok, so then the problem is : how can I make this work then?

In the DALI gateway I can define scenes starting from 1

Also in the DALI gateway I can link KNX scenes 1 to 64 to dali scenes 1 to 16 (my DALI gateway supports only 16 scenes)

Do I need some sort of conversion?
Or do I need rules?

At the moment I don’t see the solution.
Any help is greatly appreciated!

greetings,
Ruben

This info got me thinking…

From OH I sent the (decimal) values 1, 2 or 3 because these values are defined in the mappings.

Selection item=ScenesLivingKeuken label="Scenes gelijkvloers" mappings=[1="1 TV kijken", 2="2 koken", 3="3 beneden alle licht uit"]

Let’s say I send 2 (= koken)

image

In the logging of OH I get this : the 2 gets written to the GA with a DPT of 17.001

Wrote value ‘2’ to datapoint ‘command DP 1/7/0 ‘knx:ip:2fe6cbfa’, DPT id 17.001, low priority’ (0. attempt).

still good here

But in OH i get this : $02 wich is HEX02.
HEX02 = decimal 2 in my opinion (@Udo_Hartmann : and not decimal 3 I think?) so we’re still good actually

But then the use of DPT17.001 “converts” this to 3 because it assumes (I’m guessing here) that 2 is the third element in a 0-based array [0,1,2,3,4,…,63] and so the scene to select should be 3

Please feel free to attack my theorie and think with me for a solution

greetings,
Ruben

yes, OH writes 2 as scene number on the bus because you assigned the value 2 in your sitemap mapping.
The scene number 2 on the bus will be translated/displayed in ETS as scene number 3.

So to fix this change your sitemap:

Selection item=ScenesLivingKeuken label="Scenes gelijkvloers" mappings=[0="1 TV kijken", 1="2 koken", 2="3 beneden alle licht uit"]
1 Like

ok, this works!
1 problem that eludes me.
If I select a scene the scene is immediately executed by the DALI devices so that’s ok but the user interface in ios (using the openhab app) only gets updated with the new scene after 30 seconds.
So the scene “1 TV kijken” is selected, then I select “2 koken”, the “2 koken” scene is executed and the lights are switched but only after 30 seconds the app gets updated and changes from “1 TV kijken” to “2 koken”.

In the basicui this is not a problem.

Can something be done about that?