Erika Ishikawa
Erika Ishikawa

Reputation: 21

Voice Command without Pressing a Button on iOS

Currently, I am working on developing the iOS App that triggers an event upon voice command.

I saw a camera app, where a user says "start recording," then the camera starts to the recording mode.

This is an in-app voice control capability, so I am thinking it is different from SiriKit or SpeechRecognizer, which I have already implemented.

How would I achieve it?

My question is NOT the voice dictation where a user has to press a button to start dictation.

App needs to passively wait for a keyword, or intent, which is something like "myApp, start recording" or "myApp, stop recording", then the app starts/stop that event function accordingly.

Thanks.

Upvotes: 2

Views: 3631

Answers (2)

XLE_22
XLE_22

Reputation: 5671

How would I achieve it?

There's an iOS 13 new feature called Voice Control that will allow you to reach your goal. enter image description here

You can find useful information in the Customize Commands section where all the vocal commands are available (you can create a custom one as well): enter image description here

For the example of the camera you mentioned, everything can be done vocally as follows: enter image description here I showed the items names to understand the vocal commands I used but they can be hidden if you prefer (hide names).

Voice Control is a built-in feature you can use inside your apps as well.

The only thing to do as a developer is eventually adapting the accessibilityUserInputLabels properties if you need specific names to be displayed for some items in your apps.

If you're looking for a voice command without pressing a button on iOS, the Voice Control is THE perfect candidate.

Upvotes: 2

Sommm
Sommm

Reputation: 531

OpenEars : Free speech recognition and speech synthesis for the iPhone.

OpenEars makes it simple for you to add offline speech recognition in many languages and synthesized speech/TTS to your iPhone app quickly and easily. It lets everyone get the great results of using advanced speech app interface concepts. Check out this link. http://www.politepix.com/openears/ or

Building an iOS App like Siri https://www.raywenderlich.com/60870/building-ios-app-like-siri

Thank you.

Upvotes: 1

Related Questions