Closed mjb83 closed 1 year ago
It's a 2-step install...
Yep, super noob couldn't find it.
Thanks very much for taking the time to answer. Working great!
What about mapping the attributes so I can have each of them on their own entity card? Is this possible?
For instance, I have "sensor.alectra_utilities_corporation_brampton_rate_zone_residential_rate" currently set as a gauge card showing off_peak as 'green' zone, mid_peak as 'yellow' zone, and on_peak as 'red' zone. Is there a way for me to show the attribute 'active_peak' as its own entity so I can have it on its own entity card?
Been trying something like this is configuration.yaml but I can't seem to get it to map:
sensor:
platform: alectra_utilities
platform: template1 sensors: alectra_utilities_active_peak: value_template: "{{states.sensor.alectra_utilities_corporation_brampton_rate_zone_residential_rate.attributes.active_peak}}"
for your example try this.... be careful around spacing / indentation
1st line: start with dash
once your sensor is setup...you reference it as sensor.alectra_utilities_active peak in your Entities card.
drop the platform: alectra_utilities tag...
should be like this...seems the editor in this tool drops the spaces...
I feel like I need a line above - platform: template
Does the first line need to be the hacs install name? I tried sensor below but I'm getting an error for duplicate key.
sensor:
This should work:
sensor:
- platform: template
sensors:
alectra_utilities_active_peak:
value_template: "{{ state_attr('sensor.alectra_utilities_corporation_brampton_rate_zone_residential_rate', 'active_peak') }}"
friendly_name: Alectra Active Peak
Line 1 is if you're adding this to your configuration.yaml file directly, as opposed to using a separate YAML file for sensors. If that's the case, skip line 1. Line 4 is the ID of your new sensor. Make sure it's unique. Line 5 gets the active peak from the attribute of the OEB sensor. Make sure the sensor ID matches what you have. Line 6 is just the friendly name for the sensor, it can be anything.
It depends on whether this is the only sensor you have and where is the sensor stored (are your sensors in configuration.yaml or have you broken the sensors out into a separate file sensor.yaml)… Personally I have broken out my sensors into a separate sensor.yaml file with a reference to this file in configuration.yaml..there are plenty of examples like this..
On May 23, 2022, at 11:40 AM, mjb83 @.***> wrote:
I feel like I need a line above - platform: template
Does the first line need to be the hacs install name? I tried sensor below but I'm getting an error for duplicate key.
sensor:
— Reply to this email directly, view it on GitHubhttps://github.com/jrfernandes/ontario_energy_board/issues/8#issuecomment-1134833081, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ASPBD66Q72R4KRFZ4BJODQLVLORGVANCNFSM5WQXKIWA. You are receiving this because you commented.Message ID: @.***>
Sorry for incredible noob question, but I can't seem to find the entity for this once I've installed via HACS?
My assumption is that an entity is created when I install, but I'm not seeing anything related to Ontario energy when I scroll through my entities.