OpenHAB Text-To-Speech Script

I have a dehumidifier in my workshop, set to 50% humidity.

With the doors and windows closed, this can maintain the humidity at 50% very well. Although it will fill its reservoir every day or 2 depending on the local weather. Once this occurs, the dehumidifier automatically turns off and workshop humidity increases to match the outside levels.

I also have OpenHAB running, and a humidity sensor reading the workshop humidity levels.

This page details how OpenHAB can read the workshop humidity and play a prompt on Google Home Mini speakers.

 

  1. Install Tasmota on a ESP32, and connect a DHT22 (see also https://lekelectronics.com/blog/uncategorized/connecting-ccs811-co2-sensor-and-max7219-to-tasmota/).
    Catch the humidity value in OpenHAB .
  2. Set the Google Home Mini network IP address to a fixed value.
  3. Install Chromecast Binding in OpenHAB.
  4. Install VoiceRSS Text-To-Speech other add-on (Settings -> Add-ons -> Other Ad-ons).
  5. Register a free account with VoiceRSS: https://www.voicerss.org/registration.aspx
    Copy the API Key from the account profile: https://www.voicerss.org/personel/
  6. Configure OpenHAB:
    1.  Settings -> Voice
      Default Text-To-Speech should appear as VoiceRSS
    2. Set Default Audio Sink as the Google Home speaker:
    3. Paste the VoiceRSS API Key copied in step 5 here, into the Settings -> Other Services -> VoiceRSS Text-to-Speech.
  7. Create a rule to read the humidity:
    1. Trigger every hour between 1pm and 8pm, Monday to Friday. This time suits my needs. On each trigger, execute a script.
    2. Create the script with Blockly:

 

With this setup, every weekday hour between 1pm and 8pm, if the humidity is greater than 60% then the Google Home Mini speaker will play a message alerting to check the dehumidifier.

← All posts
← Asus VP276H 27” Monitor Repair Gitlab CE Self Hosted Backups →