Speech recognition not working on Hololens with Unity

Hi all, I'm trying to get speech recognition working on the Hololens with my Unity project.

Let me preface by saying that the "microphone" option in the UWP player settings is enabled, and "Hey Cortana" works on the Hololens.

At first, I wrote my own script using UnityEngine.Windows.Speech, keywordRecognizer, etc. (I presume this is how the HoloToolkit scripts do it?) Problem is, it worked fine in Unity, but was completely unresponsive on the Hololens.
So, I scrapped everything and set it back up using the official HoloToolkit scripts, "speechInputHandler" and "speechInputSource". Once again, it works perfectly in the Unity editor, but does nothing when deployed to the Hololens.

Seeing as I'm now using the scripts provided directly by Microsoft, yet still nothing is working, I'm at a complete loss. Any help would be greatly appreciated.

Tagged:

Answers

  • Are you trying to accept a pre-defined list of voice commands or free form text (like a dictation). For Keywords, I am using the KeywordRecognizer class and passing in a list of commands and an OnPhraseRecognized delegate which responds to them. For free form text I am using the SpeechRecognizer class.

  • kkalinakkalina
    edited December 7

    Thanks for the response; I'm using predefined keywords, with the KewordRecognizer class.

    I've actually solved the issue by switching to a different hololens. So this seems to be a device problem of some sort.

Sign In or Register to comment.