Skip to main content
5-Regular Member
May 29, 2017 9:38 AM UTC
Question

Can Cortana speak the work instructions that you have created?

Sure it can. 🙂

On the current implementation of Hololens you can let cortana speak e.g. your work instructions:

You can call a function from your application parameters (e.g. the parameter where you start the sequence with) in this example by:

read();

and in the home.js apply:

$scope.app.read = function() {

$scope.app.speech.say($scope.app.view.wdg['3DLabel-1'].text);

}

of course you can do more advanced things with it ...e.g. if you dont want to say the stepnames (1/8; 2/8; etc) and filter the text that is spoken:

$scope.app.read = function() {

var labelText = $scope.view.wdg['3DLabel-1'].text;

var spokenText = labelText.substr(labelText.indexOf(" ") + 1); // converts "1/8 Whatever text" to "Whatever text"

$scope.app.speech.say(spokenText);

}

Have fun

Martin

10 replies

12-Amethyst
May 31, 2017 10:27 PM UTC

Thanks .. just added it to my demo

Translate
12-Amethyst
Jun 10, 2017 10:49 PM UTC

It does not seem to work anymore in the latest version of Studio ...

Translate
mwassmann5-Regular MemberAuthor
5-Regular Member
Jun 12, 2017 9:07 AM UTC

Can't test it currently as I lent my hololens to a colleague.

@the devs Pam Vermeer​   Is there a full changelog available for us internally so we can check up ourselves why things aren't working / or working differently in new releases?

Thanks

Martin

Translate
7-Bedrock
Jun 27, 2017 12:39 PM UTC

This is great! I have it working, just needs some adjustment to get the timing right with my sequence now.

Is there a way using a similar method to do this for handheld devices, Android and iOS?

Translate
mwassmann5-Regular MemberAuthor
5-Regular Member
Jun 28, 2017 7:01 AM UTC

Hej Ross,

i just made a short test.

On an Ipad / Ios device it works like this:

$scope.speak = function(){

var msg = new SpeechSynthesisUtterance('Hello World');

window.speechSynthesis.speak(msg);

}

martin

Translate
7-Bedrock
Jun 28, 2017 7:19 AM UTC

Great thanks Matrin, I look forward to trying it out.

Translate