Skip to content

A Custom component for Home-Assistant that checks if your Raspberry Pi power supply is giving enough voltage from the kernel.

License

Notifications You must be signed in to change notification settings

rdbahm/sensor.rpi_power

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

89 Commits
 
 
 
 
 
 

Repository files navigation

Raspberry Pi Power Supply Checker

Version mantained maintainer forum
A sensor that checks your Raspberry Pi charger so its not giving you undervoltage.

To get started put /custom_components/sensor/rpi_power.py here:
<config directory>/custom_components/rpi_power/ and rename it to sensor.py

Example configuration.yaml:

sensor:
  platform: rpi_power

Optional config options:

key required default description
text_state no false Sets the description as the state if true.

⚠️ This requires Kernel 4.14 or higher.

Here is some more information about how to improve your Raspberry Pi power situation.

https://github.com/superjamie/lazyweb/wiki/Raspberry-Pi-Power

Here is a simple automation example that will notify you if the psu is failing

- id: 'rpi_power_issue'
  alias: Power Problem Notification
  trigger:
  - platform: numeric_state
    entity_id: sensor.rpi_power_status
    above: 0
    for:
      minutes: 1
  condition:
  action:
    service: persistent_notification.create
    data:
      message: "Charger reported {{ states.sensor.rpi_power_status.state }}"
      title: "RPI Power Issue"

Due to how custom_components are loaded, it is normal to see a ModuleNotFoundError error on first boot after adding this, to resolve it, restart Home-Assistant.

Licensed under: Creative Commons Attribution-ShareAlike 4.0 International License

About

A Custom component for Home-Assistant that checks if your Raspberry Pi power supply is giving enough voltage from the kernel.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%