moved temp sensor next to servers
This commit is contained in:
parent
795772909f
commit
a4893747bb
@ -17,7 +17,7 @@ auto gatewayDevice = &DeviceConfig::create(MAIN_DEVICE_ID).withName("RC Gateway"
|
||||
namespace OilTank {
|
||||
Sensor* buildRoomSensor(const char* id) {
|
||||
DeviceConfig* device = &DeviceConfig::create(id)
|
||||
.withName("Oil tank room")
|
||||
.withName("Servers room")
|
||||
.withManufacturer("Atmel")
|
||||
.withModel("AtTiny85")
|
||||
.withArea("Basement")
|
||||
@ -26,7 +26,7 @@ namespace OilTank {
|
||||
.asDevice(device)
|
||||
.withValueTemplate("{{ value_json.sensor.temperature }}")
|
||||
.asDiagnostic(new VoltageSensor{id, "Battery voltage", "{{ value_json.sensor.diagnostic.voltage }}"})
|
||||
.asDiagnostic(new BatterySensor{id, "Battery level", "{{ ((states('sensor.oil_tank_room_battery_voltage')|float-2.5)|round(2)*100/2)|int }}"})
|
||||
.asDiagnostic(new BatterySensor{id, "Battery level", "{{ ((states('sensor.servers_room_battery_voltage')|float-2.5)|round(2)*100/2)|int }}"})
|
||||
.build();
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user