Browse Source

Merge pull request #859 from mcspr/hass-no-device-class

Don't send device_class for Home Assistant sensor
rfm69
Xose Pérez 6 years ago
committed by GitHub
parent
commit
35cb015023
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 1 deletions
  1. +0
    -1
      code/espurna/homeassistant.ino

+ 0
- 1
code/espurna/homeassistant.ino View File

@ -24,7 +24,6 @@ void _haSendMagnitude(unsigned char i, JsonObject& config) {
unsigned char type = magnitudeType(i); unsigned char type = magnitudeType(i);
config["name"] = getSetting("hostname") + String(" ") + magnitudeTopic(type); config["name"] = getSetting("hostname") + String(" ") + magnitudeTopic(type);
config.set("platform", "mqtt"); config.set("platform", "mqtt");
config.set("device_class", "sensor");
config["state_topic"] = mqttTopic(magnitudeTopicIndex(i).c_str(), false); config["state_topic"] = mqttTopic(magnitudeTopicIndex(i).c_str(), false);
config["unit_of_measurement"] = magnitudeUnits(type); config["unit_of_measurement"] = magnitudeUnits(type);


Loading…
Cancel
Save