ChristophCaina / Tinkerforge_MQTT

script that send tinkerforge sensor data in HomeAssistants AutoDiscovery Format to an MQTT Broker
0 stars 0 forks source link

Temperature IR Bricklet - nur Sensor für Ambiente-Temperatur verfügbar #3

Open ChristophCaina opened 2 years ago

ChristophCaina commented 2 years ago

nach der Initialisierung und auch nach einem erneuten Reset des MasterBricks ist nur der Sensor für die Umgebungstemperatur verfügbar. Der Sensor für die Objekt-Temperatur (welchen wir primär haben wollen) wird nicht angelegt.

ChristophCaina commented 2 years ago

Object_Temperature (zY2) (sensor.object_temperature_zy2) MQTT discovery data:

- homeassistant/sensor/Tinkerforge/Object_Temperature_6qCxXx_zY2/config 

Payload:

availability_topic: homeassistant/sensor/Tinkerforge/Object_Temperature_6qCxXx_zY2/availability
icon: mdi:thermometer
unique_id: Object_Temperature_6qCxXx_zY2
unit_of_measurement: °C
device_class: temperature
device:
  identifiers: zY2
  manufacturer: Tinkerforge.com
  model: Temperature IR Bricklet
  name: Temperature IR Bricklet (6qCxXx_zY2)
  sw_version: 2.0.4
  hw_version: 1.1.0
name: Object_Temperature (zY2)
state_topic: homeassistant/sensor/Tinkerforge/Object_Temperature_6qCxXx_zY2/state
platform: mqtt

Subscribed topics:

- homeassistant/sensor/Tinkerforge/Object_Temperature_6qCxXx_zY2/availability

Payload:

Received 12:04:50

    QoS: 0
    Payload: online
- homeassistant/sensor/Tinkerforge/Object_Temperature_6qCxXx_zY2/state

Payload:

Received 12:04:04

    QoS: 0
    Payload: 21.5

Received 12:04:50

    QoS: 0
    Payload: 21.7
ChristophCaina commented 2 years ago

adding a short delay in between the init-code for the sensor values seems to solve the issue (when the device is already connected)...

ChristophCaina commented 2 years ago

after smaller code changes for testing, only the object temperatur sensor was created. So ... it seems to be a somekind random behave, which sensor will be discovered.

At the moment, not reliable!

ChristophCaina commented 2 years ago

sensor state does not update