Geekzone: technology news, blogs, forums
Guest
Welcome Guest.
You haven't logged in yet. If you don't have an account you can register now.


freitasm

BDFL - Memuneh
79298 posts

Uber Geek

Administrator
ID Verified
Trusted
Geekzone
Lifetime subscriber

#301895 13-Oct-2022 08:04
Send private message

I am trying to get temperature and humidity information into Home Assistant so that I can integrate with Alexa.

 

Components:

 

  • Three Xiaomi temperature sensors flashed with custom firmware
  • ESP32 running Tasmota
  • Mosquitto MQTT as a Docker on Synology NAS
  • Home Assistant as a Docker on Synology NAS

Home Assistant can see Tasmota and load its data but it does not recognise the temperature sensors:

 

 

Tasmota seeing the Xiaomi sensors:

 

 

I feel something else is missing here. Any tips please?





Please support Geekzone by subscribing, or using one of our referral links: Quic Broadband (free setup code: R587125ERQ6VE) | Samsung | AliExpress | Wise | Sharesies | Hatch | GoodSync 


View this topic in a long page with up to 500 replies per page Create new topic

This is a filtered page: currently showing replies marked as answers. Click here to see full discussion.

freitasm

BDFL - Memuneh
79298 posts

Uber Geek

Administrator
ID Verified
Trusted
Geekzone
Lifetime subscriber

  #3205855 12-Mar-2024 21:47
Send private message

Ok, I'm updating this to have it documented. After a few months I've decided to give it another try.

 

I have Home Assistant running as a docker instance on my Synology NAS.

 

I have Mosquitto running as a docker instance on my Synology NAS.

 

I have Tasmota Bluetooth running on a MH-ET ESP32 kit.

 

I have three Xiaomi sensors flashed with atc1441/ATC_MiThermometer: Custom firmware for the Xiaomi Thermometer LYWSD03MMC and Telink Flasher via USB to Serial converter (github.com).

 

I have housed the MH-ET ESP32 on a 3D printed case MH-ET LIVE D1 ESP32 mini kit Slim Case by ShadowEcho - Thingiverse

 

Tasmota configuration:

 

 

I've used the Tasmota terminal to issue the command SetOptions19 1 to enable auto-discovery.

 

 

I've added Tasmota to Home Assistant but it did not find the thermometers, so after confirming that the messages were actually going from Tasmota to MQTT, @davidcole suggested a snippet to manually add the sensors. It worked so I replicated for the other ones.

 

In the configuration, ATCd69715 means the ATC sensor with the MAC Address ending in d69715. Note it's case sensitive, so what Tasmota shows on the page is not exactly what it sends in the MQTT topic - make sure it matches.

 

This is the configuration added:

 

 

mqtt:    
  sensor:
    - name: "Tasmota Lounge Temperature"
      state_topic: "tele/tasmota_12B560/SENSOR"
      value_template: "{{ value_json['ATCd69715'].Temperature }}"
      unit_of_measurement: "°C"  # "F" if using Fahrenheit
      device_class: temperature

 

    - name: "Tasmota Lounge Humidity"
      state_topic: "tele/tasmota_12B560/SENSOR"
      value_template: "{{ value_json['ATCd69715'].Humidity }}"
      unit_of_measurement: "%"  # "F" if using Fahrenheit
      device_class: humidity

 

    - name: "Tasmota Bella Room Temperature"
      state_topic: "tele/tasmota_12B560/SENSOR"
      value_template: "{{ value_json['ATC66cdb5'].Temperature }}"
      unit_of_measurement: "°C"  # "F" if using Fahrenheit
      device_class: temperature

 

    - name: "Tasmota Bella Room Humidity"
      state_topic: "tele/tasmota_12B560/SENSOR"
      value_template: "{{ value_json['ATC66cdb5'].Humidity }}"
      unit_of_measurement: "%"  # "F" if using Fahrenheit
      device_class: humidity

 

    - name: "Tasmota Bedroom Temperature"
      state_topic: "tele/tasmota_12B560/SENSOR"
      value_template: "{{ value_json['ATCfac2fa'].Temperature }}"
      unit_of_measurement: "°C"  # "F" if using Fahrenheit
      device_class: temperature

 


    - name: "Tasmota Bedroom Humidity"
      state_topic: "tele/tasmota_12B560/SENSOR"
      value_template: "{{ value_json['ATCfac2fa'].Humidity }}"
      unit_of_measurement: "%"  # "F" if using Fahrenheit
      device_class: humidity

 

 

 

 The result:

 

 

I have Alexa connected to Home Assistant, and each sensor is assigned to a room, so now I can say, "Alexa, what is the temperature in the Bedroom" and she'll say "The bedroom temperature is ... degrees"

 

Unfortunately, it is not possible to use these in Alexa routines as I wanted. You need a sensor that can fire events that are then used to trigger the routines, and these sensors only report temperature and humidity but can't be set to fire events.

 

To that end I might have to get an Amazon Echo Dot 5th Gen with built-in temperature sensor, which does work for routines.

 

 

 

 

 

Other people who helped me here: @bartender and @michaelmurfy - thank you folks.

 

To others in this thread, thanks for your suggestions.





Please support Geekzone by subscribing, or using one of our referral links: Quic Broadband (free setup code: R587125ERQ6VE) | Samsung | AliExpress | Wise | Sharesies | Hatch | GoodSync 


View this topic in a long page with up to 500 replies per page Create new topic





News and reviews »

Air New Zealand Starts AI adoption with OpenAI
Posted 24-Jul-2025 16:00


eero Pro 7 Review
Posted 23-Jul-2025 12:07


BeeStation Plus Review
Posted 21-Jul-2025 14:21


eero Unveils New Wi-Fi 7 Products in New Zealand
Posted 21-Jul-2025 00:01


WiZ Introduces HDMI Sync Box and other Light Devices
Posted 20-Jul-2025 17:32


RedShield Enhances DDoS and Bot Attack Protection
Posted 20-Jul-2025 17:26


Seagate Ships 30TB Drives
Posted 17-Jul-2025 11:24


Oclean AirPump A10 Water Flosser Review
Posted 13-Jul-2025 11:05


Samsung Galaxy Z Fold7: Raising the Bar for Smartphones
Posted 10-Jul-2025 02:01


Samsung Galaxy Z Flip7 Brings New Edge-To-Edge FlexWindow
Posted 10-Jul-2025 02:01


Epson Launches New AM-C550Z WorkForce Enterprise printer
Posted 9-Jul-2025 18:22


Samsung Releases Smart Monitor M9
Posted 9-Jul-2025 17:46


Nearly Half of Older Kiwis Still Write their Passwords on Paper
Posted 9-Jul-2025 08:42


D-Link 4G+ Cat6 Wi-Fi 6 DWR-933M Mobile Hotspot Review
Posted 1-Jul-2025 11:34


Oppo A5 Series Launches With New Levels of Durability
Posted 30-Jun-2025 10:15



Geekzone Live »

Try automatic live updates from Geekzone directly in your browser, without refreshing the page, with Geekzone Live now.



Are you subscribed to our RSS feed? You can download the latest headlines and summaries from our stories directly to your computer or smartphone by using a feed reader.