Cordoba | Get live streaming from a microphone on iOS

I am trying to create a voice calendar application that should use a live microphone feed for speech recognition.

So, you have a button that starts listening to the microphone and automatically stops when the user stops talking.

I have already studied the Cordova Media API, which allows me to write data to a wav file. This works, but makes the process very slow, since I need to wait for the recording to complete.

I used https://api.ai as a starting point for creating the 1st version of the application, which works quite well. He took care of all the "listening" parts!

The next phase for me is integration with several different speech recognition APIs.

The main problem for me was the lack of development skills in my native language, so are there any cordova plugins that can help me?

Update 1 - April 1, 2016

Found this https://subvisual.co/blog/posts/39-tutorial-html-audio-capture-streaming-to-node-js-no-browser-extensions Will try to implement this in a cord through webrtc.


Update 2 - April 1, 2016

Installed https://github.com/eface2face/cordova-plugin-iosrtc to use webrtc


Update 3 - April 2, 2016

Getting stuck in AudioContext.createMediaStreamSource not an iOS feature! Alternative AudioContext.createMediaStreamSource for iOS?


April 4-6, 2016 Patch

Going Native - Time to Explore iOS Development!

+3
source share
1 answer

Sorry that you abandoned Cordoba, but if you are still interested: I created the cordova plugin for iOS and Android, which allows you to record microphone data and send it to the web level of your application. You can either use the web audio API to process incoming audio, or use any other way to encode and save the original audio data:

https://github.com/edimuj/cordova-plugin-audioinput

Usage example:

 function onAudioInput( evt ) { // 'evt.data' is an integer array containing raw audio data console.log( "Audio data received: " + evt.data.length + " samples" ); // ... do something with the evt.data array ... } // Listen to audioinput events window.addEventListener( "audioinput", onAudioInput, false ); // Start capturing audio from the microphone audioinput.start(); 
+7
source

Source: https://habr.com/ru/post/1235536/


All Articles