How to use TCP binding for a trigger channel


I use TCP binding to get a trigger message from a T25 Mobotix towards Openhab.

The meaning of what I’m trying to do is really a trigger and there is no “state” associated to the message.

The only way I have found so far is to do it as below (I got the T25 to send a text message with ON inside (to explain the REGEX((ON)) part, but i really use it only a a trigger).

Switch RFIDorPINAccessOnT25 {tcp="<[ON:'REGEX((ON))']" }

rule "Test"
	Item RFIDorPINAccessOnT25 changed to ON
    RFIDorPINAccessOnT25 .postUpdate(OFF)
    // Here what I want to do...

I’m wondering if there is a cleaner way than going via an Item and resetting it inside a rule systematically after the trigger?


No, you did the right thing, this is actually quite clean

Great then. It took me longer than I initially thought it would, but at least the final thing is decently easy to maintain, so all good.

Thanks for the feedback.