[SOLVED] OWFS Onewire bridge switch IO input or output or both?

Am I understanding this right? If I want feed back from a DS2413 (2 channels) I have to set one channel as input and one as output and have them wired to the same thing.
I have an led setup on each channel, from the owfs web server I can set each one on or off either physically using a wire or using the web server and see the result on the webpage.
In Openhab
I can turn led’s on or off if it set to output, but not read the state.
or can read the state but not turn them on or off.
so I need to use both channels to to run and verify one relay.
Is that true, or am I missing something?

I don‘t understand what you want to achieve. If you use a channel as output, you can read the state of that channel. So if you wire the output to a relais coil and set it to ON you should be able to read that from the channel. But: this only tells you what the DS2413 sets on it‘s output. If you want an independent confirmation that the relais really switched, you need to wire another (Input) channel to the output of the relais.

You might check out MQTTany, it doesn’t support OWFS yet but I plan to include support, I also haven’t written a device profile for the DS2413. If you felt like adding them it wouldn’t be terribly difficult as the OneWire module is modular so you need to add a class to interface with OWFS and a device class to control the DS2413. If you don’t want to or don’t have the knowledge then I can do it, but it won’t be quick, probably over a month before I get to it as I’m already working on a couple other modules for it.

Yes, I think you have confirmed what I was thinking.
rephrasing my original statement/question. I am testing with led’s. the DS2413 pulls down the voltage to drive the led (or relay) it all works well in openhab, (on/off as they should). but if I take a wire and physically pull down the DS2413 output voltage, I can only find out about that by setting it to input rather than output.
off topic: I’m new, is relais a type of relay, a brand, something else?

I don’t have the knowledge yet, It does sound interesting, also I’m moving slow, a month sounds quick to me! I’ll be watching.

It’s simple wrong spelling. “Relais” is the german word for “relay”. :grinning:

What would be the benefit over using openHAB’s onewire directly?

That is the only way to do that. Any pin on any device can only be used as either an input or output, never both at once. It is possible to switch the pin to an input and read, then back to an output, but that means the pin will not be controlling the load during the switch over, which may cause strange behaviour in your load device.


Open an issue to add the device so I don’t forget.


In the case of OWFS, probably not much, though I don’t know much about the function of the OneWire binding.

I don’t think I know enough yet to try to answer the benefits?
I’m not sure if I should put this here or where, but here is what I’m trying to do, comments?
Not knowing openhab well yet, I think eventually, maybe sooner, I end up doing this project with my own Python? program/module/script? run by Openhab. It’s for air conditioning, my compressor died, so I run my well water through the old condenser, it comes out of the ground at 48 deg F. I have a motorized ball valve that turns on and off with the fan when cooling is needed. right now I restrict the flow (so I don’t wast too much water but still get enough) with a manual ball valve, but want to control the flow with motorized valve. It takes it several seconds to open or close, so I will just run it for a fraction of a second, get feed back and decide if I should open it more or close it more or leave it. But since I’m talking fractions of seconds I’m thinking it should be a python program that just takes commands from and reports back to OpenHab.

That would be your best option yes, OpenHab is not real-time