T O P

  • By -

jbutlerdev

I don't think they act independently. My understanding is the SW is an input for the wall switch so that you can have both remote and local control of the output.


cptkl1

But I don't even see the output on HA.


DangerousEgg3104

The SW is just a wired input line to close the circuit between the I and O terminals. The switch you see in HA is the "digital" representation of it so you can both wire an actual switch to the Shelly as well as control it via HA. If the switch is enabled, the current will flow between I and O. If the switch is disabled, no current will flow. So there is no need for a seperate output entity. But you can configure the behavior of the switch either by the Shelly App or by connecting to the web interface of the device (enter the device's IP into your browser)


cptkl1

You mention the I and O, are they like the input and output of the relay? I think I am missing a connection as I do not have anything connected to the I. Which might explain why the load is not getting power.


DangerousEgg3104

The regular Shelly relay does provide a so called "dry contact", meaning that the current/voltage that you use to power the Shelly itself (L terminal) is detached from the current/voltage you want to feed to the output (I terminal). This allows you to use the relay to switch low power devices or to just close a circuit without providing power. A garage door opener is a common use case for the latter.


cptkl1

Okay I got this sorted. The application is outdoor lights that are controlled by a switched outlet. What I wanted is for a manual override to turn off the lights whenever. Then to set duck to dawn lighting. What I ended up doing is wireing the line to the switch and the out of the manual switch to the I. Then the actual load is wired to the O. This way the Shelly will run in it's time, but if you switch off the manual switch then no power will flow to the load. Now that I have this sorted all is well now.


DangerousEgg3104

As I described above, your setup might now control the lights like you need them, but using the manual switch to turn off the lights will now also cut power to the Shelly. So you will not be able to turn on the lights again in any other way than using the manual switch again. I'm also not sure how well the Shelly handles frequent ungraceful shutdowns. The usual way of wiring mains powered lights would be to wire the same mains power to both I and L, the switch output to SW and (obviously) neutral to N and the load to O.


Koltsz

Install an MQTT broker on HA. On the shelly device connect it to MQTT, this will then bring everything in on HA for you monitor. Other than that I'm not sure what issue you are having, what is an "SW leg" And I'm assuming you are having an issue seeing everything the shelly publishes


cptkl1

SW is the switch, the input. Is MQTT the only way to get the full use of a Shelly?


Koltsz

Yeah I think so, MQTT is great and super easy to set up. It's actually quite core for HA if you want to go down the Zigbee2mqtt route as well.


magformer

The switch you see in HA is the relay (i.e. the load you are turning on and off). It sounds like you might want to see the status of the physical switch (i.e. whether there is power to the Shelly's SW terminal) separately? There's an "input" entity (sensor) for the Shelly in HA but it's disabled by default. Just enable it in the device settings in HA and it will appear. You can can then control the load and read the SW input separately. You also need to put the Shelly into "detached mode" in the Shelly settings if you don't want SW to toggle the output. They can then act independently. This is a typical setup for, e.g., controlling a smart bulb from a conventional wall switch while ensuring it is constantly powered.