Skip to content

Wrong temperature unit for autodiscovery in ble-pasv-mqtt-gw.shelly.js, no temperature sensor in Home Assistant #188

@soubinet

Description

@soubinet

Hello

In script example : " ble/ble-pasv-mqtt-gw.shelly.js", the unit for temperature is incorrect to be able to be understand by Home Assistant. Temperature value is ignored by HA with this bug.

function autodiscovery, line 224 :
pload["unit_of_meas"] = "C";
Should be replace by :
pload["unit_of_meas"] = "°C";

Work fine after correction.

Extract from HA doc :
https://www.home-assistant.io/integrations/sensor/#device-class
temperature: Temperature in °C, °F or K

Thanks !

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions