feat(plant): garage PDU current+power via librenms relay; garage dashboard cards [#344]
This commit is contained in:
+18
-2
@@ -18,7 +18,23 @@ views:
|
|||||||
entities:
|
entities:
|
||||||
- sensor.pfv_garage_temperature
|
- sensor.pfv_garage_temperature
|
||||||
hours_to_show: 24
|
hours_to_show: 24
|
||||||
|
- type: gauge
|
||||||
|
entity: sensor.pfv_garage_pdu_output_current
|
||||||
|
name: PDU output
|
||||||
|
unit: A
|
||||||
|
min: 0
|
||||||
|
max: 20
|
||||||
|
- type: entity
|
||||||
|
entity: sensor.pfv_garage_pdu_power
|
||||||
|
name: PDU power (est @120V)
|
||||||
|
icon: mdi:flash
|
||||||
|
- type: history-graph
|
||||||
|
title: PDU output (24h)
|
||||||
|
entities:
|
||||||
|
- sensor.pfv_garage_pdu_output_current
|
||||||
|
hours_to_show: 24
|
||||||
- type: markdown
|
- type: markdown
|
||||||
content: >
|
content: >
|
||||||
**Pending:** garage PDU power + temp (#374 outlet naming,
|
**Pending:** garage PDU outlet naming (#374), minisplit BTU
|
||||||
#351 network onboarding), minisplit BTU context (#614).
|
context (#614). Feed via tsys-librenms SNMP relay (AP7830 is
|
||||||
|
v1-only).
|
||||||
|
|||||||
@@ -312,3 +312,30 @@ sensor:
|
|||||||
value_template: >-
|
value_template: >-
|
||||||
{% set t = value | regex_findall('(?:^|\n)temp (\d+)') %}
|
{% set t = value | regex_findall('(?:^|\n)temp (\d+)') %}
|
||||||
{{ ((t[1] | float * 9 / 5) + 32) | round(1) if t | length > 1 }}
|
{{ ((t[1] | float * 9 / 5) + 32) | round(1) if t | length > 1 }}
|
||||||
|
|
||||||
|
# --- Garage PDU (APC AP7830 metered) via tsys-librenms relay [#344] ---
|
||||||
|
# Relay: old PDU speaks SNMPv1 only; tsys-librenms is the sanctioned vantage
|
||||||
|
# (dcinfra/sensors/pdu/garage-pdu-relay.sh in PFVCluster).
|
||||||
|
- platform: snmp
|
||||||
|
name: "PFV garage PDU output current"
|
||||||
|
host: tsys-librenms.knel.net
|
||||||
|
version: 2c
|
||||||
|
community: kn3lmgmt
|
||||||
|
baseoid: .1.3.6.1.4.1.8072.1.3.2.3.1.2.9.103.97.114.97.103.101.112.100.117
|
||||||
|
accept_errors: true
|
||||||
|
device_class: current
|
||||||
|
unit_of_measurement: "A"
|
||||||
|
unique_id: pfv_garage_pdu_amps
|
||||||
|
value_template: >-
|
||||||
|
{% set m = value | regex_findall('output_amps ([0-9.]+)') %}
|
||||||
|
{{ m[0] if m | length > 0 }}
|
||||||
|
|
||||||
|
template:
|
||||||
|
- sensor:
|
||||||
|
- name: "PFV garage PDU power"
|
||||||
|
unique_id: pfv_garage_pdu_watts
|
||||||
|
device_class: power
|
||||||
|
unit_of_measurement: "W"
|
||||||
|
state: >-
|
||||||
|
{% set a = states('sensor.pfv_garage_pdu_output_current') | float(-1) %}
|
||||||
|
{{ (a * 120) | round(0) if a >= 0 }}
|
||||||
|
|||||||
Reference in New Issue
Block a user