Author Topic: lja's special echo thread  (Read 5994 times)

0 Members and 1 Guest are viewing this topic.

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
lja's special echo thread
« on: April 03, 2017, 05:36:38 PM »
I have been trying to set this up and have received the following:

Error: Please make sure that "Alexa Skills Kit" is selected for the event source type of arn:aws:lambda:us-east-1:386167780127:function:AlexaSkillsKit

Please help. Thanks.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #1 on: April 03, 2017, 05:47:24 PM »
At what point do you receive this error?  Did you follow step 17 of the instructions in the first post of this thread by Dave?

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #2 on: April 03, 2017, 06:25:57 PM »
At what point do you receive this error?  Did you follow step 17 of the instructions in the first post of this thread by Dave?

@jitterjames
Thanks. I rechecked step 17 and the info did not take so I repeated the step. The error no longer appears.

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #3 on: April 03, 2017, 10:45:56 PM »
I  have text setting (service simulator) working with history visible in Vox. However the test with echoism does not produce a response. Is there a specific area I can check to determine the error I made?

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #4 on: April 04, 2017, 07:48:50 AM »
Did you enable the skill on the echosim device?

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #5 on: April 05, 2017, 11:35:02 AM »
Did you enable the skill on the echosim device?

Could not get echosim to respond so I tried it with my echo and now it all works. Next will attempt to upgrade.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #6 on: April 05, 2017, 11:47:02 AM »
LOL.  Why use echosim if you have a real one?  I only used it in my original tutorial because I did not have my Dot yet.  :biglaugh

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #7 on: April 05, 2017, 12:34:08 PM »
Need help with upgrade.
1. Step 5. An image of the location would help me.
2. Do the variables require var like those already there?
3. Are new commands required to achieve the actions as in the video?
Thanks.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #8 on: April 05, 2017, 12:42:53 PM »
1) The location of what?  Where you put the code?  The code goes in the same place as the code went before.  See  step 19 of Dave's tutorial.

2) Not sure what you mean.  For the environment variables I posted an image of what that should look like:

When you are editing the lambda code, the environment variables are on the same web page, just further down.

3) Again, not sure what you are asking.  See step 6 of my post?

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #9 on: April 05, 2017, 12:43:47 PM »
LOL.  Why use echosim if you have a real one?  I only used it in my original tutorial because I did not have my Dot yet.  :biglaugh

Wanted to see how it works. ^-^

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #10 on: April 05, 2017, 01:26:30 PM »
1) The location of what?  Where you put the code?  The code goes in the same place as the code went before.  See  step 19 of Dave's tutorial.

2) Not sure what you mean.  For the environment variables I posted an image of what that should look like:

When you are editing the lambda code, the environment variables are on the same web page, just further down.

3) Again, not sure what you are asking.  See step 6 of my post?
Thanks.
1) Sorry but I can't locate how to get back to the step 19 area
2) I refer to the "var" in red before the variables. I did see the image you posted.
3) With reference to step 6, would that new group provide the info necessary to issue the commands as per video.

nime5ter

  • Administrator
  • Hero Member
  • *****
  • Posts: 2012
  • Karma: 61
    • View Profile
    • Getting Started with VoxCommando
Re: lja's special echo thread
« Reply #11 on: April 05, 2017, 09:21:06 PM »
Quote from: lja  date=1491409590
1) Sorry but I can't locate how to get back to the step 19 area

Try going back to Step 11. Of course, instead of creating a new Lamda function, just click your existing function and it will take you directly to the code editor and environment variables page.

Quote
2) I refer to the "var" in red before the variables. I did see the image you posted.

Once you're on the correct web page, I think it will make more sense. Environment variables are not added to the code in the script editor. You add them lower down on that web page. In the first video James made, at about 13 minutes and 20 seconds, he says "We don't need environment variables..." and his mouse cursor indicates that part of the page.



Now, however, you do want to edit the environment variable fields so that they look as James posted in his screenshot.

Quote
3) With reference to step 6, would that new group provide the info necessary to issue the commands as per video.

It depends what you mean.  In terms of how VC is interacting with Alexa, absolutely. All the steps of the instructions must be followed.
« Last Edit: April 06, 2017, 10:17:03 AM by jitterjames »
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)

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #12 on: April 06, 2017, 04:17:13 PM »
@nime5ter

Thanks. OK. I can say "tell jarvis to open kodi" and Kodi is opened. However "tell jarvis to close kodi" does not close Kodi.

Are there additional commands I have to enter?
« Last Edit: April 06, 2017, 05:59:06 PM by lja »

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #13 on: April 06, 2017, 04:31:53 PM »
No. All of your normal voice commands should work now. I mentioned in the video that the spelling has to match so look in your history to see what Amazon is sending and compare it to your phrases.

Using VoxCommando directly is always going to be a better, faster, more reliable, more private and more accurate experience with the possible exception of open dictation for web searches and things of that nature.

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #14 on: April 06, 2017, 09:54:50 PM »
@jitterjames

Thanks. To close Kodi I could not get it to work with the words "close" or "Exit". "Cancel" worked. So far I have checked the different command phrases but no other commands are working.Would the attached image from Lambda have any impact?

https://www.dropbox.com/s/o1jjkasmx5bnpoj/awslambda.jpg?dl=0

nime5ter

  • Administrator
  • Hero Member
  • *****
  • Posts: 2012
  • Karma: 61
    • View Profile
    • Getting Started with VoxCommando
Re: lja's special echo thread
« Reply #15 on: April 06, 2017, 10:17:25 PM »
Above James suggested that you follow the standard VC problem-solving procedure of reviewing your VC history window to diagnose what is happening after you give a voice command to Alexa. What do you see in that history log?

You should be able to see exactly what commands VC has received from the Echo (if it has indeed received any). Do you see any sign of Alexa activity in the history window? If so, do the command strings that appear in that history match the command phrases in your command tree? You don't confirm or address this in your post.

The steps for helping to resolve this problem are the same as always. As a reminder:

http://voxcommando.com/mediawiki/index.php?title=Getting_support

At the very least we'd need to see your VoxCommando log capturing your attempts to issue multiple commands, so that we can see what is or is not happening.

Without really knowing enough to say anything concrete, to me it doesn't sound like any commands are working. If you followed James's instructions exactly, then telling Alexa to "Cancel" is most likely instructing the Echo device to stop sending messages to VoxCommando entirely.

The environment variable phrases for canceling a command that he posted were "cancel", "stop", or "shut up":




What microphone do you typically use when issuing VC voice commands? Is it possible that some other microphone is also enabled and it heard you first issue the "open Kodi" command, and that's why that first command worked?



« Last Edit: April 06, 2017, 10:21:51 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)

nime5ter

  • Administrator
  • Hero Member
  • *****
  • Posts: 2012
  • Karma: 61
    • View Profile
    • Getting Started with VoxCommando
Re: lja's special echo thread
« Reply #16 on: April 07, 2017, 07:37:34 AM »
The most efficient starting point for trying to resolve the problem at this point is to review each of James's instructional steps again to make sure each has been properly implemented.

His instructions are here: http://voxcommando.com/forum/index.php?topic=2682.msg23144#msg23144

These included:

2. Have VC version 2.2.3.4 or later installed.

3. Create the  environment variables, as described, by re-accessing the web page for the "Jarvis" function that you initially created in the AWS console.

4. Make sure the username and password used in your environment variables matches the username and password you created in VoxCommando's TCP plugin settings.

5.  On the same web page in the AWS console, replace the entire Node.js lambda code that Dave originally provided with the code that James attached to his post (link above). *important* you must change one line at the beginning of James's code near line 5:

Code: [Select]
edit one line in that script  var Echo_App_ID = "amzn1.ask.skill...." to use your own App ID.
Make sure your App ID has quotation marks around it, as in the example provided.

6. In VoxCommando, delete the old command group from Dave's original instructions and replace it with the VC command XML in James's post.
« Last Edit: April 07, 2017, 07:41:10 AM 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)

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #17 on: April 07, 2017, 01:17:25 PM »
You may also see useful troubleshooting information in the Amazon app itself.

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #18 on: April 07, 2017, 01:46:23 PM »
@nime5ter
@jitterjames

Thanks. However it looks like I also have another challenge to solve first.

https://www.dropbox.com/s/d2xgd18dvktvwmn/json.jpg?dl=0
« Last Edit: April 07, 2017, 01:52:54 PM by lja »

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #19 on: April 07, 2017, 01:57:19 PM »
Good luck with that.  ;)

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #20 on: April 09, 2017, 06:36:50 PM »
Good luck with that.  ;)

Thanks. An update. Making some progress.Some movies play. Seems to be an understanding issue with the title. The history sometimes shows the title correctly but the movie does not play. However I am presently trouble shooting. Will post again with any discovery.

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2319
  • Karma: 47
    • View Profile
Re: lja's special echo thread
« Reply #21 on: April 10, 2017, 04:09:11 AM »
Hi lja,

I'm not sure if you use the "echosim" or the real Amazon Echo/Dot, but in the Amazon App you will find a history in settings what "Alexa" has understand. The most issue with Alex is how they spelling words - here an example from my side:

I have a command in VC which switch LEDs on, so my command was: "Alexa, tell Voxcommando to switch LED ON" which doesn't work. After a look in the VC history, I noticed that "Alexa" recognized and interpreted the word LED as  l. e. d.
So I can only repeat what James suggest before - get sure that the command what "Alexa" has recognized hit EXACTLY the command what you use in Voxcommando.

"Alexa" is a funny toy to play with, but you will never reach the flexibility of the speech recognition as it possesses VoxCommando.
***********  get excited and make things  **********

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #22 on: April 10, 2017, 12:54:02 PM »
@Kalle

Thanks. Actually, that is the process I am going through.  I am using my Echo Dot.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #23 on: April 11, 2017, 09:16:00 AM »
If you still need help with this I think it will be easier to help you one on one using TeamViewer. Contact me privately to set that up if you are interested.

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #24 on: April 11, 2017, 12:39:50 PM »
If you still need help with this I think it will be easier to help you one on one using TeamViewer. Contact me privately to set that up if you are interested.

Thanks. Interested. Sent a test PM.

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #25 on: April 12, 2017, 09:00:33 PM »
@jitterjames

Thanks. All working good so far. During the testing we set VC to off. Should VC be on as usual?

nime5ter

  • Administrator
  • Hero Member
  • *****
  • Posts: 2012
  • Karma: 61
    • View Profile
    • Getting Started with VoxCommando
Re: lja's special echo thread
« Reply #26 on: April 12, 2017, 10:21:15 PM »
James turned VC off to ensure that only Alexa was listening and responding to voice commands while you were running your tests, rather than any other microphone input that may have been plugged into your computer.

If you plan to only use Alexa, then keeping VC in off mode is the safe option. But any time you want to use a proper microphone input to talk directly to VC then you'll have to turn VC back on (or use it in standby mode, depending on your preference).
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)

lja

  • Sr. Member
  • ****
  • Posts: 145
  • Karma: 5
    • View Profile
Re: lja's special echo thread
« Reply #27 on: April 12, 2017, 11:32:58 PM »

Thanks.
« Last Edit: April 13, 2017, 08:34:14 AM by jitterjames »

horstdog

  • Jr. Member
  • **
  • Posts: 6
  • Karma: 1
    • View Profile
    • 1Home1PC
Re: lja's special echo thread
« Reply #28 on: February 11, 2018, 10:20:34 AM »
Hi Guys
I know this is an old thread but thought it would be best to have this quote for reference.

I just recently got an Amazon Echo dot and followed the recreated tutorial  ((http://voxcommando.com/forum/index.php?topic=2761.0) to get it working with VoxCommando. It works fine but after reading this threads and watching some other YouTube videos I'm now thinking the code from the recreated tutorial is not the new code James created but instead the original code Dave created.

If I'm correct can someone post the new code James created (Node.js lambda code + VC command XML)

My apologizes if this is found in another thread but i didn't see it.

Thank You


The most efficient starting point for trying to resolve the problem at this point is to review each of James's instructional steps again to make sure each has been properly implemented.

His instructions are here: http://voxcommando.com/forum/index.php?topic=2682.msg23144#msg23144

These included:

2. Have VC version 2.2.3.4 or later installed.

3. Create the  environment variables, as described, by re-accessing the web page for the "Jarvis" function that you initially created in the AWS console.

4. Make sure the username and password used in your environment variables matches the username and password you created in VoxCommando's TCP plugin settings.

5.  On the same web page in the AWS console, replace the entire Node.js lambda code that Dave originally provided with the code that James attached to his post (link above). *important* you must change one line at the beginning of James's code near line 5:

Code: [Select]
edit one line in that script  var Echo_App_ID = "amzn1.ask.skill...." to use your own App ID.
Make sure your App ID has quotation marks around it, as in the example provided.

6. In VoxCommando, delete the old command group from Dave's original instructions and replace it with the VC command XML in James's post.




jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #29 on: February 11, 2018, 11:47:27 AM »
Here is the lambda code but you need more than just the code so read my following posts.

Also remember to put your Echo_App_ID on line 5.

Code: [Select]
/*
****** Pulls speech input and passes on to Voxcommando for custom events *****
*/
var http = require('http');
var Echo_App_ID = "PUT.YOUR.OWN.ID.HERE"; 

exports.handler = function (event, context) {
    try {
        if (event.session.new) {
            onSessionStarted({requestId: event.request.requestId}, event.session);
        }
        if (event.request.type === "LaunchRequest") {
            onLaunch(event.request,
                     event.session,
                     function callback(sessionAttributes, speechletResponse) {
                        context.succeed(buildResponse(sessionAttributes, speechletResponse));
                     });
        }  else if (event.request.type === "IntentRequest") {
            onIntent(event.request,
                     event.session,
                     function callback(sessionAttributes, speechletResponse) {
                         context.succeed(buildResponse(sessionAttributes, speechletResponse));
                     });
        } else if (event.request.type === "SessionEndedRequest") {
            onSessionEnded(event.request, event.session);
            context.succeed();
        }
    } catch (e) {
        context.fail("Exception: " + e);
    }
};

/**
 * Called when the session starts.
 */
function onSessionStarted(sessionStartedRequest, session) {}

/**
 * Called when the user launches the skill without specifying what they want.
 */
function onLaunch(launchRequest, session, callback) {
    // Dispatch to your skill's launch.
    getWelcomeResponse(callback);
}

/**
 * Called when the user specifies an intent for this skill.
 */
function onIntent(intentRequest, session, callback) {
    var intent = intentRequest.intent,
    intentName = intentRequest.intent.name;
    callEchoToVC(intent, session, callback); // Whatever the Intent is, pass it straight through to VC
}

/**
 * Called when the user ends the session.
 * Is not called when the skill returns shouldEndSession=true.
 */
function onSessionEnded(sessionEndedRequest, session) {
}

// --------------- Main Intent Processing Function ----------------

function callEchoToVC(intent, session, callback)
{
    var sessionAttributes = "{}";
    var cardTitle = "VoxCommando";
    var shouldEndSession = false;

    var payload = "";
    var speechOutput = "OK";
    var repromptText = "...";
    var i = 0;
    var slots = intent.slots;
   
    //Pull the spoken text and format
    var actionSlot = intent.slots.Action;
    var setAction = actionSlot.value.toLowerCase();
   
    if (setAction.endsWith(" only"))
    {
        shouldEndSession=true;
        setAction = setAction.replace(" only","")
       
    }
   
    if(process.env.phrases_cancel.includes(setAction))
    {
        speechOutput ="Cancelling";
        shouldEndSession=true;
        callback(sessionAttributes, buildSpeechletResponse(cardTitle, speechOutput, repromptText, shouldEndSession));
        return;
    }
    else if (setAction.length<5)
    {
        speechOutput =process.env.tts_tooshort;
        shouldEndSession=false;
        callback(sessionAttributes, buildSpeechletResponse("Action string too short", speechOutput, repromptText, shouldEndSession));
        return;
    }
    setAction = setAction.replace("1st","first")
    .replace("2nd","second")
    .replace("3rd","third")
    .replace("4th","fourth")
    .replace("5st","fifth")
    .replace("6th","sixth")
    .replace("7th","seventh")
    .replace("8th","eighth")
    .replace("9th","nineth")
    .replace("10th","tenth")
    ;
   
    var setActionURI = require('querystring').escape(setAction);
    var VC_uri = '/api/VC.TriggerEvent&&EchoToVC&&' + setActionURI;
    var get_options = {
            host: process.env.ip,
            port: process.env.port,
            path: VC_uri
        };
    if (process.env.username !== '')
    {
        get_options = {
            host: process.env.ip,
            port: process.env.port,
            path: VC_uri,
            headers: {
                'Authorization': 'Basic ' + new Buffer(process.env.username + ':' + process.env.pwd).toString('base64')
            }
        };
    }
 
    // Set up the request
    var get_req = http.request(get_options, function(res) {
        var VC_results = "";
        res.setEncoding('utf8');
        res.on('data', function (chunk) {
            VC_results += chunk;
        });
       
        res.on('end', function () {
            //console.log(VC_results);
            cardTitle = VC_results;
            if (res.statusCode === 200) {
                //Parse the Body results from VC, if the command was unknown we will repromt
                if(VC_results.indexOf('<Success>False') > -1) {
                    cardTitle = "Vc error: ";
                    speechOutput = "VoxCommando API error: "+setAction;
                    repromptText = "Try again or say cancel.";
                    shouldEndSession=false;
                }
                else
                {
                    var regex = /<WebResponse>(.*?)</;
                    var reMatches = VC_results.match(regex);
        if (reMatches)
        {
        var speechOutput = reMatches[1];
        }
                    else speechOutput = "no matches";
                }
            }
            callback(sessionAttributes,
                buildSpeechletResponse(cardTitle, speechOutput, repromptText, shouldEndSession)); //Pass stingResult instead of speechOutput for debugging if needed
        });
    });
    get_req.on('error', function (e) {
        shouldEndSession=true;
        callback(sessionAttributes,
            buildSpeechletResponse(cardTitle, speechOutput, repromptText, shouldEndSession));
    });
    get_req.end();   
}

// --------------- WelcomResponse Function ----------------

function getWelcomeResponse(callback) {
    // If we wanted to initialize the session to have some attributes we could add those here.
    var sessionAttributes = {};
    var cardTitle = "Welcome to Echo To Voxcommando";
    var speechOutput = "You see a smaller Jarvis in there.";

    // If the user either does not reply to the welcome message or says something that is not
    // understood, they will be prompted again with this text.
    var repromptText = "Do you speak English?";
    var shouldEndSession = false;
    callback(sessionAttributes,
             buildSpeechletResponse(cardTitle, speechOutput, repromptText, shouldEndSession));
}

// --------------- Helper Functions ----------------

function buildSpeechletResponse(title, output, repromptText, shouldEndSession) {
    return {
        outputSpeech: {
            type: "PlainText",
            text: output
        },
        card: {
            type: "Simple",
            title: "EchoToVoxcommando - " + title,
            content: output
        },
        reprompt: {
            outputSpeech: {
                type: "PlainText",
                text: repromptText
            }
        },
        shouldEndSession: shouldEndSession
    };
}

function buildResponse(sessionAttributes, speechletResponse) {
    return {
        version: "1.0",
        sessionAttributes: sessionAttributes,
        response: speechletResponse
    };
}
« Last Edit: February 11, 2018, 12:01:07 PM by jitterjames »

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #30 on: February 11, 2018, 11:50:00 AM »
You will also need to set environment variables...

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: lja's special echo thread
« Reply #31 on: February 11, 2018, 11:52:35 AM »
And this is the XML I am using in VC.  You don't necessarily need to have it the same as this, I have some extra experimental stuff in there to treat movie commands differently.

Code: [Select]
<?xml version="1.0" encoding="utf-16"?>
<!--VoxCommando 2.2.4.1-->
<command id="47" name="event to voice command" enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description="">
  <if ifBlockDisabled="False" ifNot="False">
    <ifType>(A)Contains(B)</ifType>
    <ifParams>{1}&amp;&amp;play movie</ifParams>
    <then>
      <action>
        <cmdType>VC.TriggerEvent</cmdType>
        <params>
          <param>Play.Movie</param>
          <param>{1}</param>
        </params>
        <cmdRepeat>1</cmdRepeat>
      </action>
      <action>
        <cmdType>VC.StopMacro</cmdType>
        <params />
        <cmdRepeat>1</cmdRepeat>
      </action>
    </then>
    <else />
  </if>
  <action>
    <cmdType>TTS.Speak2Wav</cmdType>
    <params>
      <param>OK</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <action>
    <cmdType>VC.TellVox</cmdType>
    <params>
      <param>{1}</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <if ifBlockDisabled="False" ifNot="False">
    <ifType>LastActionSuccess</ifType>
    <ifParams>&amp;&amp;</ifParams>
    <then />
    <else>
      <action>
        <cmdType>TCP.WebServer.SetResponse</cmdType>
        <params>
          <param>Jarvis does not understand {1}</param>
        </params>
        <cmdRepeat>1</cmdRepeat>
      </action>
      <action>
        <cmdType>VC.StopMacro</cmdType>
        <params />
        <cmdRepeat>1</cmdRepeat>
      </action>
    </else>
  </if>
  <action>
    <cmdType>TTS.GetLastText</cmdType>
    <params />
    <cmdRepeat>1</cmdRepeat>
  </action>
  <if ifBlockDisabled="False" ifNot="False">
    <ifType>(A)==(B)</ifType>
    <ifParams>{LastResult}&amp;&amp;{Var.LastTTS}</ifParams>
    <then />
    <else>
      <action>
        <cmdType>TCP.WebServer.SetResponse</cmdType>
        <params>
          <param>{LastResult}</param>
        </params>
        <cmdRepeat>1</cmdRepeat>
      </action>
    </else>
  </if>
  <event>EchoToVC</event>
</command>

horstdog

  • Jr. Member
  • **
  • Posts: 6
  • Karma: 1
    • View Profile
    • 1Home1PC
Re: lja's special echo thread
« Reply #32 on: February 11, 2018, 02:42:38 PM »
James, This is great, Thank you so much.