Home Assistant Community

Shelly Cloud - new Component? How to implement it? API is available

#131

The CE brandis something the manufacturer put on and by doing it the state that the product is compliant. No tests is needed. So not really worth much anyway

#132

Not totally true Yuran,

You can make any claim you want and stick a CE mark, just need to prove it:

Point is, just be extremely carefull on how you use ANY products when dealing with 230VAC and have questionable compliance.

Rob.

#133

This says it all…

#134

But that is tru for all products unfortunately

#135

Has anyone managed to set up Shelly RGBW2 over MQTT?

#136

Did you try using these settings?

#137

yes but can not get it to work, that is why I am asking if anyone managed to get it working, to share the config.

#138

Well start troubleshooting.

What is your MQTT broker seeing?

What exactly is your config?

#139

I don’t own the device but I have been helping devise the correct MQTT Light configuration for someone else. It would be helpful if you were to participate in the testing process. The latest iteration of the configuration can be found in this post.

1 Like
#140

Hi - is auto discovery for Shelly’s available? I have a batch of 2.5s coming soon :grin:

#141
#142

This is just to make you know that I started to develop a custom-component for Shelly Cloud devices.
My idea was to be as much conservative as possible.

I’m aware that Shelly devices are awesome: they support LAN discovery, provide local monitor and control (Mqtt, CoAP), etc. The problem is that I wanted a stand-alone custom-component, I wanted to maintain the Cloud service (you lose it activating Mqtt on the devices) and I needed to handle battery-enabled devices (that require a minimum amount of network interactions).

The only solution I found was to interact with the Shelly Cloud server to discover the devices, monitor their status and control the switching functionalities (on/off).

You can enjoy the custom-component here: https://github.com/vincenzosuraci/hassio_shelly_cloud.

In case of any issue, please, open a new issue directly on Github (follow the above mentioned link).

Regards,
Vincenzo

2 Likes
#144

Hello,
I am getting the following error after months without issues: “Integration shelly not found when trying to verify its switch platform.”
I am using this code:

  - platform: shelly
switches:
  shelly_switch:
    name: "Sala - Luzes"
    path: /relay/0 (optional, defaults to /relay/0)
    host: xxx.xxx.xxx.xxx
    username: xxxxxxx
    password: xxxxxxx

Anyone with this problem?

#145

No. No one can help you. Please read How to help us help you - or How to ask a good question.

#146

Thanks Vincenzo, I got your custom component installed last night on 0.91.3 and it’s working great (just needed a couple of restarts) :grinning:

#147

Hello everyone, just got a couple of Shelly 1pm and Shelly 2.5 and I’m wondering how you guys are you using those to measure energy consumption.

I’ve read that shellies report energy in Watt-Minute every 30s. Does anyone have a solution to convert it to kwh and keep a track of it with utility_meter?

Thank you all!

#148

Hi,

for shelly 2.5 you can check this out:

https://shelly-api-docs.shelly.cloud/#shelly2-5-mqtt

I can’t find anything for Shelly 1pm. I just bought 2 of them but I cannot measure power consumption. Any idea?
Thanks

#149

With this script energy sensor is in kWh. But Shellies reset this meter on every reboot. You can use power sensor, integration sensor and utility_meter:

sensor:
  - platform: integration
    source: sensor.shelly2_5b2604_power
    name: 'Shelly Energy'
    unit_prefix: k
    round: 2

utility_meter:
  energy_shelly2_monthly:
    source: sensor.shelly_energy
    cycle: monthly
#150

Hi gekomax,

Shelly 1pm works almost exactly as Shelly 2.5, follow my configs for both switch and sensors:

Closet AC Shelly Instant Power

- platform: mqtt
  name: "Closet AC Instant Power"
  state_topic: "shellies/shelly1pm-YOUSHELLYRID/relay/0/power"
  unit_of_measurement: "Watts"

Closet AC Shelly Instant Power

- platform: mqtt
  name: "Closet AC Energy"
  state_topic: "shellies/shelly1pm-YOUSHELLYRID/relay/0/energy"
  unit_of_measurement: "Wm"

Shelly 1PM AC Switch

  • platform: mqtt
    name: “Closet AC”
    state_topic: “shellies/shelly1pm-YOUSHELLYRID/relay/0”
    command_topic: “shellies/shelly1pm-YOUSHELLYRID/relay/0/command”
    qos: 1
    payload_on: “on”
    payload_off: “off”
    retain: true
#151

Thanks! :+1: