Skip to content

Home Assistant use an entity's attribute as a new sensor helper

License

Notifications You must be signed in to change notification settings

gjohansson-ST/attribute_as_sensor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

hacs_badge size_badge version_badge download_badge

Home Assistant create an entities attribute as it's own sensor


Title: "Attribute as Sensor"

Description: "Create an entity from another entities attribute."

Version: 1.4

Date created: 2023-11-19

Last update: 2024-07-26

Join the Discussion on Development: https://discord.gg/qyBhBArwHN


Configuration Options

Set once

  • Name: Name of the new entity
  • Entity: From which entity you want to get the attribute
  • Attribute: Which attribute you want as it's own sensor

Options that you can change at any time

  • Value template: Use a template to manipulate the retrieved attribute from the source entity
  • Icon: Icon to use in frontend
  • Device class: Device class (select from list)
  • State class: State class (select from list)
  • Unit of measurement: UoM to use in frontend (select from list, only temperature, or write your own)

Installation

Option 1 (preferred)

Use HACS to install Add as custom repository to HACS

Option 2

  1. Below config-folder create a new folder calledcustom_components if not already exist.
  2. Below new custom_components folder create a new folder called attribute_as_sensor
  3. Upload the files/folders in custom_components/attribute_as_sensor directory to the newly created folder.
  4. Restart before proceeding

Activate integration in HA

Add integrations

After installation go to "Devices & services" and then "helper" page in HA, press "+ Create helper" and find "Attribute as Sensor" Follow onscreen information for the required information No restart needed