Author Topic: Hello! (and Nest Questions)  (Read 2169 times)

0 Members and 1 Guest are viewing this topic.

nick3young

  • Jr. Member
  • **
  • Posts: 2
  • Karma: 0
    • View Profile
Hello! (and Nest Questions)
« on: February 29, 2016, 12:18:35 PM »
First of all, hello everyone! 'Mr Wolf' recommended VoxCommando to me a while back and just recently, I've finally purchased it to integrate with my smart appliances. It really is an interesting and powerful application - great work by everyone involved.... I'm really enjoying using it!

For anyone interested, I'm running it from a 'Zotac Pico' mini computer which is connected to a SoundBlaster SBX10 speaker/microphone combo. I can really recommend the microphone. I have read through a lot of discussions on this forum about microphone options and have seen the 'Amazon Echo' mentioned a few times. It was the Echo which motivated me to purchase the SBX10 - it looks similar to the Echo with it's tube shape, has a built in speaker and an array-microphone. Only cost me £30 too.

I have my setup working smoothly now with my TV/Tivo/sound-bar (via the USB-UIRT), Philips Hue lightbulbs and Nest thermostat. I just have a couple of questions about my Nest though:

1. I am able to connect to the Nest and adjust the temperature, but when I ask for the current temperature, it always reports back 17.01 degrees. Any ideas on this?

2. Is it possible to request the 'target temperature'?

Thanks again
Nick

nime5ter

  • Administrator
  • Hero Member
  • *****
  • Posts: 1999
  • Karma: 61
    • View Profile
    • Getting Started with VoxCommando
Re: Hello! (and Nest Questions)
« Reply #1 on: February 29, 2016, 01:23:42 PM »
Hi Nick and welcome.

It's been a while since I looked at the Nest commands. It sounds like they need some fixing. I'll look into it, and will look at retrieving target temperature at the same time.

cheers.
TIPS: POST VC VERSION #. Explain what you want VC to do. Say what you've tried & what happened, or post a video demo. Attach VC log. Link to instructions followed.  Post your command (xml)

nime5ter

  • Administrator
  • Hero Member
  • *****
  • Posts: 1999
  • Karma: 61
    • View Profile
    • Getting Started with VoxCommando
Re: Hello! (and Nest Questions)
« Reply #2 on: February 29, 2016, 03:33:45 PM »
1. I am able to connect to the Nest and adjust the temperature, but when I ask for the current temperature, it always reports back 17.01 degrees. Any ideas on this?

It should work if you first say "Update Nest data".

You can also revise the existing "Get current temperature" command by adding an action at the beginning that will automatically refresh the Nest data. I have done this for your target temp command below. You can use the same VC.TriggerEvent action at the beginning of your "Get current temperature" command

2. Is it possible to request the 'target temperature'?

The existing "Show status of thermostat X" command does include target temperature. However, the command below should tell you just the target temp, without all the other stuff.

Code: [Select]
<?xml version="1.0" encoding="utf-16"?>
<!--VoxCommando 2.2.1.6-->
<command id="1279" name="Get target temperature of {1}" enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description="">
  <action>
    <cmdType>Results.SetVar</cmdType>
    <params>
      <param>dev</param>
      <param>{PF.1}</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>VC.TriggerEvent</cmdType>
    <params>
      <param>nestUpdate</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>File.Read</cmdType>
    <params>
      <param>Nest\Nest_dev_status.txt</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>Results.Replace</cmdType>
    <params>
      <param>_</param>
      <param><![CDATA[ ]]></param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>Results.RegEx</cmdType>
    <params>
      <param>shared".*?"{1}".*?timestamp":(.*?)}}}</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>Results.RegEx</cmdType>
    <params>
      <param>,"target.temperature":(.*?),</param>
      <param />
      <param>{Match.1}</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>OSD.ShowText</cmdType>
    <params>
      <param>The target temperature for {var.dev} is:</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>OSD.AddText</cmdType>
    <params>
      <param>{Match.1} degrees</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>TTS.Speak</cmdType>
    <params>
      <param>The target temperature for {var.dev} is: {Match.1} degrees</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <phrase>Get target temperature of</phrase>
  <payloadFromXML phraseOnly="False" use2partPhrase="False" phraseConnector="by" Phrase2wildcard="anyone" optional="False">Nest\thermoList.xml</payloadFromXML>
</command>

EDIT: I had to correct a problem with the xml above. Revised xml posted 2-March-2016.

I need to look again at the json feedback to see if there's a more elegant solution that can return low and high target temps for thermostats that are set to heat-cool mode, or just the one target temperature for those that are set to a solo (either heat or cool) mode. The above command assumes your thermostat has just one target temp.
« Last Edit: March 02, 2016, 03:32:26 PM by nime5ter »
TIPS: POST VC VERSION #. Explain what you want VC to do. Say what you've tried & what happened, or post a video demo. Attach VC log. Link to instructions followed.  Post your command (xml)

nick3young

  • Jr. Member
  • **
  • Posts: 2
  • Karma: 0
    • View Profile
Re: Hello! (and Nest Questions)
« Reply #3 on: February 29, 2016, 07:10:47 PM »
Thanks for the response nime5ter.

'Update Nest data' worked and I'm looking forward to adding the 'target' code tomorrow! Cheers!