Udp connection to server

hi all,

Been searching for a day now to get the udp connection working but no luck and can’t figure it out where i’m wrong. I have OH2 installed on a Synology NAS and have a samsung tv addon working.

my item:
Switch GF_LivingDining_Light “Light” (GF_LivingDining, gLight) [“Lighting”] {udp=">[‘REGEX(.*)’]"}

my sitemap:
Switch item=GF_LivingDining_Light label=“Living & Dining Room” mappings=[“d15”=“ON”, “d15”=“OFF”]

my map:

When i push the switch on the habpanel it needs to send the string “d15=1\x03d15=0\x03” to ip adress on port 8150 through the UDP protocol

I had a lot of errors in the beginning but my latest one is:
there is no channel that services [itemName:GF_LivingDining_Light, command ON]
all udp examples are without channels so i’m a bit confused

Thanks in advance
kind regards

You need to tell is what text to send. Right now you are sending the state of the Switch so ON or OFF. You also need to tell it whether to send the string on the ON command or OFF command. The following sends the string on the ON command.

{ udp=">[ON:\x03d15=0\x03]" }

You may need to double escape those \x (i.e. \x)

When in doubt look at the examples in the binding README.


thx for the answer
I indeed had to double escape those backslashes
but i still get the error “there is no channel that services [itemName=GF_LivingDinning_Lightc command ON]”

the string i have in my items file is
Switch GF_LivingDining_Light “Light” (GF_LivingDining, gLight) [“Lighting”] { udp=">[ON:\x03d15=0\x03]" }

kind regards

The binding is for sure installed?

i installed this one

TCP/UDP Binding
binding-tcp1 - 1.11.0

Well, I don’t use this binding so I’m out of ideas.

What about checking the correct use of quotation marks in your item definition?

It doesn’t say LivingDinning in your files does it?

I’m attempting to use the TCP/UDP binding and am getting the same error as well:

[g.tcp.AbstractDatagramChannelBinding] - There is no channel that services [itemName=Send_UDP, command=ON]

Got it! copy services/tcp.cfg to services/udp.cfg

already did that

just going to uninstall it all and run it on a pi, maybe i did something wrong in the installation

open up udp.cfg and uncomment some lines… i uncommented the following:


See if that helps, thats all i had and when i copied tcp.cfg to udp.cfg it got rid of that error… i just need to successful send a udp packet now.

Did you check your item definition after my post. You should change to "

Switch	GF_LivingDining_Light "Light" (GF_LivingDining, gLight) ["Lighting"] { udp=">[ON:\x03d15=0\x03]" }