编辑/config/configuration.yaml
sensor:
- platform: hp_ilo
host: # IP地址
username: # 账号
password: # 密码
monitored_variables:
- name: '风扇转速'
sensor_type: server_health
unit_of_measurement: '%'
value_template: '{{ilo_data.fans["Fan 1"].speed[0]}}'
- name: '环境温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["01-Inlet Ambient"].currentreading[0] }}'
- name: 'CPU1温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["02-CPU 1"].currentreading[0] }}'
- name: 'CPU2温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["03-CPU 2"].currentreading[0] }}'
- name: 'CPU1内存1-6温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["04-P1 DIMM 1-6"].currentreading[0] }}'
- name: 'CPU1内存7-12温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["05-P1 DIMM 7-12"].currentreading[0] }}'
- name: 'CPU2内存1-6温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["06-P2 DIMM 1-6"].currentreading[0] }}'
- name: 'CPU2内存7-12温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["07-P2 DIMM 7-12"].currentreading[0] }}'
- name: 'P1 Mem Zone温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["08-P1 Mem Zone"].currentreading[0] }}'
- name: 'P1 Mem Zone温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["09-P1 Mem Zone"].currentreading[0] }}'
- name: 'P2 Mem Zone1温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["10-P2 Mem Zone"].currentreading[0] }}'
- name: 'P2 Mem Zone2温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["11-P2 Mem Zone"].currentreading[0] }}'
- name: '芯片组温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["13-Chipset 1"].currentreading[0] }}'
- name: '芯片组区域温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["14-Chipset1 Zone"].currentreading[0] }}'
- name: 'P/S 1 Inlet温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["15-P/S 1 Inlet"].currentreading[0] }}'
- name: 'P/S 1区域温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["16-P/S 1 Zone"].currentreading[0] }}'
- name: 'P/S 2区域温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["18-P/S 2 Zone"].currentreading[0] }}'
- name: 'VR P1温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["21-VR P1"].currentreading[0] }}'
- name: 'VR P2温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["22-VR P2"].currentreading[0] }}'
- name: 'VR P1 Mem温度1'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["23-VR P1 Mem"].currentreading[0] }}'
- name: 'VR P1 Mem温度2'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["24-VR P1 Mem"].currentreading[0] }}'
- name: 'VR P2 Mem温度1'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["25-VR P2 Mem"].currentreading[0] }}'
- name: 'VR P2 Mem温度2'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["26-VR P2 Mem"].currentreading[0] }}'
- name: 'VR P1Mem Zone温度1'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["27-VR P1Mem Zone"].currentreading[0] }}'
- name: 'VR P1Mem Zone温度2'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["28-VR P1Mem Zone"].currentreading[0] }}'
- name: 'VR P2Mem Zone温度1'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["29-VR P2Mem Zone"].currentreading[0] }}'
- name: 'VR P2Mem Zone温度2'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["30-VR P2Mem Zone"].currentreading[0] }}'
- name: '硬盘控制器温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["31-HD Controller"].currentreading[0] }}'
- name: 'HD Cntlr区域温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["32-HD Cntlr Zone"].currentreading[0] }}'
- name: 'PCI 1区域温度1'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["33-PCI 1 Zone"].currentreading[0] }}'
- name: 'PCI 1区域温度2'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["34-PCI 1 Zone"].currentreading[0] }}'
- name: 'PCI 2区域温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["36-PCI 2 Zone"].currentreading[0] }}'
- name: '主板温度1'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["37-System Board"].currentreading[0] }}'
- name: '主板温度2'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["38-System Board"].currentreading[0] }}'
- name: 'Sys Exhaust1温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["39-Sys Exhaust"].currentreading[0] }}'
- name: 'Sys Exhaust2温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["40-Sys Exhaust"].currentreading[0] }}'
- name: 'Sys Exhaust3温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["41-Sys Exhaust"].currentreading[0] }}'
- name: 'SuperCAP Max温度'
sensor_type: server_health
unit_of_measurement: '°C'
value_template: '{{ ilo_data.temperature["42-SuperCAP Max"].currentreading[0] }}'
重启homeassistant后即可看到刚才添加的传感器
效果图:
Comments NOTHING