Scene commands get lost in OH4

In OH3 I had a rule that looked like this:

// Triggers:
// - When TwoButtonSwitch was updated to 2.1
// - When TwoButtonSwitch was updated to 1.1

// context: default-7
WorkbenchPower.sendCommand("ON")

And when I pressed the button I could see the TwoButtonSwitch sending the Scene command and the rule fired. In OH4, the scene commend does not appear in the log but is clearly sent if I turn on debug. Is there something I need to do to make this work again?

Or am I doing this completely wrong.

Hard to judge. If I get it right, under oh4 you see the button event fired but dependent switch is not switched on.

Just a (stupid) guess. If the rule is created by your own and not generated, try to remove the quotes (“…“).

Otherwise, please try to give some more infos. E.g. what have you tried? What do see in the log?

Cheers Thefechner

It was in fact my rule. Removing the quotes had no effect as the rule is still not triggering. THis is the Zwave data that show in debug when I press the button on the scene controller.

2023-07-28 21:11:42.812 [DEBUG] [WaveSerialHandler$ZWaveReceiveThread] - Receive Message = 01 18 00 49 84 29 12 04 18 01 5E 86 72 5B 85 59 73 70 80 84 5A 7A EF 5B 20 92 
2023-07-28 21:11:42.817 [DEBUG] [nal.protocol.ZWaveTransactionManager] - processReceiveMessage input 0<>128 : Message: class=ApplicationUpdate[73], type=Request[0], dest=41, callback=132, payload=84 29 12 04 18 01 5E 86 72 5B 85 59 73 70 80 84 5A 7A EF 5B 20 
2023-07-28 21:11:42.820 [DEBUG] [nal.protocol.ZWaveTransactionManager] - Received msg (0): Message: class=ApplicationUpdate[73], type=Request[0], dest=41, callback=132, payload=84 29 12 04 18 01 5E 86 72 5B 85 59 73 70 80 84 5A 7A EF 5B 20 
2023-07-28 21:11:42.822 [DEBUG] [nal.protocol.ZWaveTransactionManager] - lastTransaction null
2023-07-28 21:11:42.822 [DEBUG] [WaveSerialHandler$ZWaveReceiveThread] - Receive Message = 01 0B 00 04 00 29 05 5B 03 FC 00 01 79 
2023-07-28 21:11:42.823 [DEBUG] [nal.protocol.ZWaveTransactionManager] - Checking outstanding transactions: 0
2023-07-28 21:11:42.825 [DEBUG] [nal.protocol.ZWaveTransactionManager] - processReceiveMessage input 0<>128 : Message: class=ApplicationCommandHandler[4], type=Request[0], dest=41, callback=0, payload=00 29 05 5B 03 FC 00 01 
2023-07-28 21:11:42.825 [DEBUG] [nal.protocol.ZWaveTransactionManager] - Last transaction: null
2023-07-28 21:11:42.827 [DEBUG] [ve.internal.protocol.ZWaveController] - Incoming Message: Message: class=ApplicationUpdate[73], type=Request[0], dest=41, callback=132, payload=84 29 12 04 18 01 5E 86 72 5B 85 59 73 70 80 84 5A 7A EF 5B 20 
2023-07-28 21:11:42.829 [DEBUG] [essage.ApplicationUpdateMessageClass] - NODE 41: Application update request. Node information received. Transaction null
2023-07-28 21:11:42.831 [DEBUG] [ng.zwave.internal.protocol.ZWaveNode] - NODE 41: resetResendCount initComplete=true isDead=false
2023-07-28 21:11:42.832 [DEBUG] [essage.ApplicationUpdateMessageClass] - NODE 41: Application update - no transaction.
2023-07-28 21:11:42.834 [DEBUG] [nal.protocol.ZWaveTransactionManager] - Received msg (0): Message: class=ApplicationCommandHandler[4], type=Request[0], dest=41, callback=0, payload=00 29 05 5B 03 FC 00 01 
2023-07-28 21:11:42.836 [DEBUG] [nal.protocol.ZWaveTransactionManager] - lastTransaction null
2023-07-28 21:11:42.837 [DEBUG] [nal.protocol.ZWaveTransactionManager] - NODE 41: Application Command Request (ALIVE:DONE)
2023-07-28 21:11:42.838 [DEBUG] [ng.zwave.internal.protocol.ZWaveNode] - NODE 41: resetResendCount initComplete=true isDead=false
2023-07-28 21:11:42.839 [DEBUG] [ng.zwave.internal.protocol.ZWaveNode] - NODE 41: Incoming command class COMMAND_CLASS_CENTRAL_SCENE, endpoint 0
2023-07-28 21:11:42.840 [DEBUG] [ng.zwave.internal.protocol.ZWaveNode] - NODE 41: SECURITY not supported
2023-07-28 21:11:42.842 [DEBUG] [tocol.commandclass.ZWaveCommandClass] - NODE 41: Received COMMAND_CLASS_CENTRAL_SCENE V2 CENTRAL_SCENE_NOTIFICATION
2023-07-28 21:11:42.843 [DEBUG] [dclass.ZWaveCentralSceneCommandClass] - NODE 41: Received scene 1 at key 0 [Single Press]
2023-07-28 21:11:42.845 [DEBUG] [ding.zwave.handler.ZWaveThingHandler] - NODE 41: Got an event from Z-Wave network: ZWaveCommandClassValueEvent
2023-07-28 21:11:42.846 [DEBUG] [ding.zwave.handler.ZWaveThingHandler] - NODE 41: Got a value event from Z-Wave network, endpoint=0, command class=COMMAND_CLASS_CENTRAL_SCENE, value=1.0
2023-07-28 21:11:42.848 [DEBUG] [ding.zwave.handler.ZWaveThingHandler] - NODE 41: Updating channel state zwave:device:cf6f19314a:node41:scene_number to 1.0 [DecimalType]
2023-07-28 21:11:42.849 [DEBUG] [nal.protocol.ZWaveTransactionManager] - NODE 41: Commands processed 1.
2023-07-28 21:11:42.856 [DEBUG] [nal.protocol.ZWaveTransactionManager] - NODE 41: Checking command org.openhab.binding.zwave.internal.protocol.ZWaveCommandClassPayload@137697a.
2023-07-28 21:11:42.857 [DEBUG] [nal.protocol.ZWaveTransactionManager] - Transaction completed - outstandingTransactions 0
2023-07-28 21:11:42.859 [DEBUG] [nal.protocol.ZWaveTransactionManager] - Transaction completed - outstandingTransactions 0
2023-07-28 21:11:42.861 [DEBUG] [nal.protocol.ZWaveTransactionManager] - ZWaveReceiveThread queue empty
2023-07-28 21:11:42.864 [DEBUG] [nal.protocol.ZWaveTransactionManager] - Transaction SendNextMessage 0 out at start. Holdoff false.

Maybe I missed it because I just read with my mobile phone. As far i can see the log shows your scene/button is changed to 1.0. But your rule is waiting for 2.1 and 1.1.

Upfront: when asking for help, please don’t expect anyone to know about your system. So describe it comprehensively. How is the WorkbenchPower item defined ? What’s a “TwoButtonSwitch” and why is that of relevance ?

Speaking generally, you don’t actively send SCENE zwave command. Actuators do so when you push the button and the device is configured to send a SCENE then but you don’t.

Finally, OH3->4 should not have changed behavior here. As you said yourself, it’s probably that your rule isn’t executed.
Enable debugging to see if triggers match and interactively run it from the GUI.

Sorry, when I installed these scene controllers in V3 I had no idea how to use them but when I pressed a button, a line appeared in the log that said something to the effect of “Scene changed to X.X.” In V4 I do not get that line and I didn’t understand why as I thought I’d changed nothing. Apparently I had as recreating the item and re-linking it to the scene property of the switch made if work now. I’d guess I misspelled something as the upgrade did not go well and I had to move everything to a fresh install. Thanks to everyone who tried to hep as without your admonishments I would likely not have gotten there.