Powercalc - Virtual power sensors

Your Hue or other zigbee integration reports this bulbs as respectively 8718696598283 and 7146060PH.
These are not known in the supported models list yet.
We can add these model id’s as aliases for LLC020 and LTW013 but need to be 100% sure it’s exactly the same bulb and not some other generation of the bulb having other power characteristics.

Could you please create an issue on github for this? Also would be nice if you could include some references which indicates these are indeed the same bulbs.

Hi - something went wrong with my home assistant and I had to remove the powercalc integration, with a view to reinstalling it.

However - after removing it (through HACS) I am left with lots of “switchname_energy” and “switchname_energy_daily” entities which I cannot remove (They can’t be deleted via the GUI as they have no unique ID).

Any advice appreciated!

Thanks!

Refresh your browser and have another look, if they are really still there.

now I feel stupid!

Thanks!

Is anyone able to advise on how to use PowerCalc to correct the kWh being reported wrong with a specific device type?

I think, you should describe more, what you want to achieve, what is reported “wrong” and how and should be “corrected” in which way?

Plug reports every now and then a -21,000 kwh reading, normal wattage and ampage records fine.
Trying to work out if PowerCalc can be used to resolve that issue.

If wattage is reported and is correct, just use (only) this as input for Powercalc. It will calculate the rest, e.g. the clean kwh, etc.

BTW If it is a on/off-plug with high jumps, use integration method left. See docs.

Powercalc logs errors after updating in HACS.
Any idea what happened here?

Logger: homeassistant.setup
Source: setup.py:339
First occurred: 10:18:10 PM (35 occurrences)
Last logged: 10:18:13 PM

Unable to prepare setup for platform powercalc.sensor: Unable to set up component.

Thanks, but I’m not sure some of what you are referencing here as a solution.
Would be useful to know ‘how’ it calculates the rest, as in, what we’d need to do to actually have it calculate, what inputs, what formula, where in its config, etc.

Nm for this though, at this point, I’m gonna give up and send the plug back.

You should read the documentation, if you don’t know what poercalc is (for). If you have the wattage, it is fine and enough to setup a powercalc sensor. It will create the needed sensors, an energy meter (the correct kwh) and utility meters, if you want. Done. All described (with examples) in the doc. rtm

1 Like

As @arganto correctly indicates powercalc main purpose is to provide virtual power sensors for devices which don’t have a built-in meter. Besides that it can create energy sensors (riemann integration sensor) and utility meters, but these are just the same as the core components which you also can create with the helpers section in Home Assistant.
It has no tools to auto correct errors provided by some watt sensor of an other integration. This should really be solved by the integration of that smart plug or the firmware of it.

I would enable debug logging for Powercalc https://github.com/bramstroker/homeassistant-powercalc#debug-logging. Then check the full log when you restart HA. It will likely show what powercalc is failing on.

I was having the same error, after checking the log I could see that the auto-discovery was failing on a Tasmota bulb I have that did not have a model/name set in it’s Template. Look like powercalc expects that. I will actually log a powercalc bug report on that. I may need to break my config to collect that info.

You may have a completely different issue but the debug log will give you more information.

So i cant get this to auto detect my localtuya integration based arlec gridconnect globes.

They’re a supported model (GLD130P3HA gridconnect globes) but the debug mode reports there’s no correct model detected (example this is in the log: Auto discovered model (manufacturer=Tuya, model=bf495627b5078df453etvp - instead of GLD130P3HA)

Problem is powercalc detects the unique identifier for the light provided by Tuyas cloud via localtuya (so every light is a different model code). I tried “customizing” the entity with the model number and it does add it too the lights details but again doesn’t detect that.

I guess i need to add the sensors manually then? or is there some other way of getting powercalc to correct ID the globes

I don’t know localtuya, maybe other can help with that. Powercalc only reads the manufacturer and model known in HA, the correct information needs to be there for auto discovery to work.
You could just set them up manually with the GUI config flow or YAML.

Hi guys!
I have added some IKEA bulbs (both supported and not yet supported bulbs) The supported ones do get their entities created automatically, but even for supported bulbs it says that power meter isn’t available. I have toggled the bulb on/off (when off it actually displays the standby power, see pic) What do I need to do?

When turned off it displays the standby power:

Dont worry, this solved itself during the day!

Hi,
having a question regarding “sensor.dummy”

I have tried something like this

- entity_id: sensor.dummy
  name: FritzBox Plug
  fixed:
     power: 8.4

and thought I would get an power and energy sensor but it didn’t show up.
Did I do something wrong?

Thank you!

Where is the platform in this case/example?

It is only a part of my configuration. the configuration it self works where I great groups and other stuff

it is something like that (in short)

- platform: powercalc
  create_group: Gruppe 
  entities:
    - entity_id: sensor.dummy
      name: FritzBox Plug
      fixed:
         power: 8.4