question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Automatic Power Sensor Configuration Not Working

See original GitHub issue

I had no luck with this integration in the past and decided to start from scratch today. After reinstalling powrcalc, I noticed all of the lights being auto discovered in the logs, but the automatic power sensor function has never worked on old or new versions of the integration. I did noticed an error on a single light about setting up the power sensor, and I am wondering if the code is failing when it finds the first automatic power sensor setup failure.

Power sensor setup failure: 2022-05-08 00:50:46 ERROR (MainThread) [custom_components.powercalc.sensors.power] Skipping sensor setup light.living_room_light: ('No lookup file found for mode', 'color_temp')

Full Log:

2022-05-08 00:50:24 WARNING (SyncWorker_2) [homeassistant.loader] We found a custom integration powercalc which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] Start auto discovering entities
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.living_room_light: Auto discovered model (manufacturer=LIFX, model=LIFX Mini Color)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.light_model] Loading /config/custom_components/powercalc/data/lifx/LIFX Mini Color/model.json
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.wled_light: Auto discovered model (manufacturer=WLED, model=FOSS)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.wled_light: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.entry_light: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LWB014)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.entry_light: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.kitchen_center_right: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LCA003)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.kitchen_center_right: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.kitchen_center_left: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LCA003)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.kitchen_center_left: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.kitchen_left: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LCA003)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.kitchen_left: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.kitchen_right: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LCT014)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.kitchen_right: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.laundry: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LWB014)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.laundry: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.plate01_backlight_2: Auto discovered model (manufacturer=HASwitchPlate, model=HASPone v1.0.0)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.plate01_backlight_2: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.plate01_selected_foreground_color: Auto discovered model (manufacturer=HASwitchPlate, model=HASPone v1.0.0)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.plate01_selected_foreground_color: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.plate01_selected_background_color: Auto discovered model (manufacturer=HASwitchPlate, model=HASPone v1.0.0)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.plate01_selected_background_color: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.plate01_unselected_foreground_color: Auto discovered model (manufacturer=HASwitchPlate, model=HASPone v1.0.0)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.plate01_unselected_foreground_color: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.plate01_unselected_background_color: Auto discovered model (manufacturer=HASwitchPlate, model=HASPone v1.0.0)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.plate01_unselected_background_color: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.light_panels_58_24_c5: Auto discovered model (manufacturer=Nanoleaf, model=NL22)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.light_panels_58_24_c5: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.fridge: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LCA002)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.fridge: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.bedroom_austin: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LCA003)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.bedroom_austin: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.bedroom_tv: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LCA003)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.bedroom_tv: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.bedroom_eric: Auto discovered model (manufacturer=Signify Netherlands B.V., model=LCA003)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.bedroom_eric: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc.model_discovery] light.tv_lights: Auto discovered model (manufacturer=Govee, model=H6199)
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] light.tv_lights: Model not found in library, skipping auto configuration
2022-05-08 00:50:45 DEBUG (MainThread) [custom_components.powercalc] Done auto discovering entities
2022-05-08 00:50:46 ERROR (MainThread) [custom_components.powercalc.sensors.power] Skipping sensor setup light.living_room_light: ('No lookup file found for mode', 'color_temp')

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
bramstrokercommented, May 8, 2022

It works as follows. Powercalc tries to find all light entities in your installation and their respective manufacturer and models. This is the log line starting with “Auto discovered model”. Next it tries to find the corresponding LUT file in the library. When the model is not supported it will say “Model not found in library”, which is the case for almost all your lights. When your light is supported you’ll see “Loading xxxxx.json” in the logs. So you should have a power sensor for your LIFX mini. You can see the supported lights here. LCA002, LCA003, LCT014 and LWB014 are not on the list yet unfortunately. You could have a look into providing measurements for these lights yourself (https://github.com/bramstroker/homeassistant-powercalc/wiki/Contributing-new-lights). Or wait till someone else provides it.

0reactions
bramstrokercommented, May 20, 2022

Thanks for fixing @jacobdonenfeld

Read more comments on GitHub >

github_iconTop Results From Across the Web

Automating Power Sensor within Time Frame - Configuration
My problem is I can't add a “for” attribute into the automation because the platform is of type “template”. If I'm understanding this...
Read more >
Troubleshooting Sensor Modules - MOBOTIX Community
This could be due to the Automatic Sensor Configuration is not set properly or there is a defective sensor or cable.
Read more >
Stages Support: I can't get my power meter to pair or connect
The power meter can only be paired through the StagesPower app (or another compatible mobile app) and not through your device's settings. It ......
Read more >
My Tailwind Vehicle Sensor / Vehicle Bluetooth auto-open ...
My Tailwind Vehicle Sensor / Vehicle Bluetooth auto-open / auto-close is not working ; Open the Tailwind app. Go to the door control...
Read more >
How to change default DHCP IP address of LAN power sensor ...
One method that works is to enter the existing IP address into a web browser (e.g. Google Chrome) and modify the LAN Power...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found