Giter Site home page Giter Site logo

Comments (21)

J-N-K avatar J-N-K commented on July 25, 2024

SmartHome/J is compatible with openHAB 3. Just install the Repomanager and you can install the TCP binding in your openHAB installation.

If you need assistance, please ask.

from addons.

sercasyr avatar sercasyr commented on July 25, 2024

Great!
It seems really easy to install. Thank you.
However, my question is about whether it will be included in the next official release of OH3.

Is it possible to get a .jar file (without having to compile it) instead of using the repomanager ? I like to keep my OH installation in "manual" mode (with the .jar files and the config files) so I can move it and update/change the addons manually.

Thanks again for the project.

from addons.

J-N-K avatar J-N-K commented on July 25, 2024

You can download the .jar for the binding and it’s dependency from maven central

https://mvnrepository.com/artifact/org.smarthomej.addons.bundles/org.smarthomej.binding.tcpudp/3.1.1

https://mvnrepository.com/artifact/org.smarthomej.addons.bundles/org.smarthomej.commons/3.1.1

and drop them into your addons folder.

And no, they will not be part of the next openHAB release and most probably not of any future „official“ release. There is a reason why this is published here.

from addons.

WiredLife avatar WiredLife commented on July 25, 2024

@J-N-K
Wieso wird es nie in die offiziellen Addons mit einfließen?
Gibt es irgendwo eine Anleitung wie ich die .things und items für das TCP UDP Binding anlegen muss?

from addons.

J-N-K avatar J-N-K commented on July 25, 2024

The cofiguration is very similar to that of the http binding. You can have a look here.

The main difference is, that the thing is names client instead of url. All parameters are described here: https://github.com/smarthomej/addons/tree/main/bundles/org.smarthomej.binding.tcpudp The required parameters are host, portandprotocol`.

The main difference for channels is that there is no stateExtension and commandExtension because that does make no sense for this binding. You must configure stateContent which is what the binding sends to request the state from the remote system.

I do recommend configuring via UI though, it's much less error prone than textal configuration. It also makes sure that all required parameters are set.

from addons.

WiredLife avatar WiredLife commented on July 25, 2024

uh, i come from openhab 2 and was forced to upgrade to oh3 because of missing addons because of offline bintray
i dont know much about these gui stuff, i did all the configuration with files
the jar installation was successful but can you help me to add the thing?
i need something like this in oh2
String Fenster_Schlafzimmer_R {udp="<[192.168.179.31:*:]"}
the port is 17236

from addons.

J-N-K avatar J-N-K commented on July 25, 2024

I don‘t know much about the „old binding“ and it‘s configuration. Please explain what you want to do, then I can probably help you.

from addons.

WiredLife avatar WiredLife commented on July 25, 2024

i have an esp8266 which sends a string (1 or 0) via udp port 17236 to openhab and a rule which looks if its value is 1 or 0 and then do something
i need a receiver thing which listen on udp port 17236 and give the send string to the "String Fenster_Schlafzimmer_R" item

from addons.

J-N-K avatar J-N-K commented on July 25, 2024

Receiving is not yet implemented, only sending and requesting. It‘s on my list though. You could open an issue for that as feature request, so you‘ll be notified when everything is ready.

from addons.

sercasyr avatar sercasyr commented on July 25, 2024

You can download the .jar for the binding and it’s dependency from maven central

https://mvnrepository.com/artifact/org.smarthomej.addons.bundles/org.smarthomej.binding.tcpudp/3.1.1

https://mvnrepository.com/artifact/org.smarthomej.addons.bundles/org.smarthomej.commons/3.1.1

and drop them into your addons folder.

I have successfully installed and configure the binding in OH3. It's fairly easy.
Unfortunately my device acts as a client, so it needs openHAB to be the server.
I will have to wait until the receiving feature is implemented.

And no, they will not be part of the next openHAB release and most probably not of any future „official“ release. There is a >reason why this is published here.

I guess there is a reason for that, but it is not published (at least that I can see).

Thanks again!

from addons.

ianjenn avatar ianjenn commented on July 25, 2024

I am really struggling with this and it is frustrating as it is the last part that I need to move from OH2.5
I need to replicate this item which turns a IP relay on and off
Switch Solar_switch "wall plug" (All) { udp=">[ON:192.168.1.100:6723:12] >[OFF:192.168.1.100:6723:22]" }

I have added the jar files, created thing from the binding and added a channel. but it doesn't initialize and just doesnt work. Ideally I want to link to my items file in some way
this is what I have so far. Any thoughts would be greatly appreciated
`UID: tcpudp:client:91607768db
label: TCP/UDP Client
thingTypeUID: tcpudp:client
configuration:
protocol: UDP
delay: 0
port: 6723
host: 192.168.1.101
refresh: 30
timeout: 3000
bufferSize: 2048
channels:

  • id: thisrelay
    channelTypeUID: tcpudp:switch
    label: thisrelay
    description:
    configuration:
    onValue: "21"
    offValue: "22"`

from addons.

J-N-K avatar J-N-K commented on July 25, 2024

Looks good. But in your "original" configuration the "ON"-value is 12, in your "new" configuration it is 21. Is that correct?

Which version are you using? And you should select "WRITE ONLY" as mode (under advanced). Otherwise the channel will be ignored because of the missing stateContent.

from addons.

ianjenn avatar ianjenn commented on July 25, 2024

the relay is dual relay and so 11 and 12 is on off for one and 21 and 22 for the other so yes, was playing with both.
The thing doesnt move to online. It stays at initializing, so something is wrong somewhere

from addons.

J-N-K avatar J-N-K commented on July 25, 2024
UID: tcpudp:client:02856999bd
label: TCP/UDP Client
thingTypeUID: tcpudp:client
configuration:
  protocol: UDP
  delay: 0
  port: 4402
  host: localhost
  refresh: 30
  timeout: 3000
  bufferSize: 2048
channels:
  - id: switch
    channelTypeUID: tcpudp:switch
    label: Switch Test Channel
    description: ""
    configuration:
      mode: WRITEONLY
      onValue: "12"
      offValue: "22"

Works for me and sends 12 if the linked item receives an ON and 22 if the linked item receives an OFF. The thing goes to UNKNOWN immediately after I click on "Save" and turns ONLINE once the first command is send. If it stays in INITIALIZING there is something wrong. Please check the log.

Which version of openHAB are you suing and which version if the addon?

from addons.

ianjenn avatar ianjenn commented on July 25, 2024

thanks for replying, really appreciate that.
will have a look at the logs. I am on OH 3.1.0 and JAR 3.1.1
is that my proble, do I need oh 3.1.1 too

from addons.

J-N-K avatar J-N-K commented on July 25, 2024

Which OH 3.1.0? M1, M2, M3, M4 or SNAPSHOT? There is no release of OH 3.1 at the moment.

from addons.

ianjenn avatar ianjenn commented on July 25, 2024

snapshot Build #2366 but I tried a few different through versions through openhabian and no difference

from addons.

J-N-K avatar J-N-K commented on July 25, 2024

You need the addon-version 3.2.0-SNAPSHOT. Addon Version 3.1.x is only compatible for openHAB 3.0.x, 3.1.0 Milestones 1-3 and snapshort <2305 (see matrix here: https://github.com/smarthomej/addons).

You could download 3.2.0-SNAPSHOT here:

org.smarthomej.commons-3.2.0-SNAPSHOT.jar
org.smarthomej.binding.tcpudp-3.2.0-SNAPSHOT.jar

I would recommend to wait until tomorrow though, because I merged a bugfix in tcpudp today.

from addons.

ianjenn avatar ianjenn commented on July 25, 2024

whooop whoop. thanks J-N-K the updated jar worked perfectly. you are a star!

from addons.

Krobar avatar Krobar commented on July 25, 2024

Receiving is not yet implemented, only sending and requesting. It‘s on my list though. You could open an issue for that as feature request, so you‘ll be notified when everything is ready.

Is receiving supported yet? Also is there any support for different character sets per connection with this new version?

from addons.

J-N-K avatar J-N-K commented on July 25, 2024

Receiving is supported since version 3.2.3, see https://docs.smarthomej.org/3.2.8/org.smarthomej.binding.tcpudp.html

What do you mean by "character set"? Please open a new issue if this is independent from the receiver.

from addons.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.