TRIGGERcmd
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Have Alexa or Google Assistant say the result of a command

    Instructions
    1
    1
    833
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • RussR
      Russ
      last edited by Russ

      If your command has {{result}} in the Voice Reply field, then the voice assistant will wait a few seconds for a "result" of the command to be logged in the Runs list for that command, and will include that result in what it says back to you.

      So for example, you could have Alexa run a command on your Raspberry Pi that would take the temperature, and Alexa could tell you that temperature.

      As a test, I put this in my Voice Reply field of my "Results Test" command:

      Running {{trigger}} on {{computer}} with result {{result}}
      

      I put this in the Command field:

      %USERPROFILE%\.TRIGGERcmdData\sendresult.bat "My command result"
      

      NOTE: Use ~/.TRIGGERcmdData/sendresult.sh instead for Linux/Mac/Raspberry Pi.

      I said this:

      Hey Google, ask trigger CMD to run results test
      

      Google Assistant said this:

      Running results test on DS with result My command result
      

      You only have about 4-5 seconds to send a result via that SendResult script. If you take too long, it will say "no result" in the {{result}} placeholder.

      Russell VanderMey

      1 Reply Last reply Reply Quote 0
      • RussR Russ pinned this topic on
      • RussR Russ referenced this topic on
      • First post
        Last post