Balaji
Balaji

Reputation: 11

Android + phonegap + capture.captureAudio

I am working on the Samsung S Plus phone.

Android version: 2.3.4 Phonegap version: 1.5.0

I am trying to record an audio bit and upload the same to the server.

I am using the Capture API, capture.captureAudio(). When the function is invoked, on the device I notice that the Voice Recorder application loads and asks for recording, which I am able to perform. But, after the voice is recorded, there is no way for me to select the recorded audio file and put into my HTML page or atleast I need to path of the file where its put on the device. I am unable to select any newly created recorded audio or the files already available in the library. Whenever I select any audio file, its plays, but i need that path to be returned to my application, so that I can do whatever I need to.

The same code works on iOS but not on Android.

The following code is used:

navigator.device.capture.captureAudio(captureSuccess, captureError, {limit : 1});

captureSuccess and captureError are some private functions.

Any ideas?

Thanks,

Upvotes: 1

Views: 2097

Answers (1)

codemonkey
codemonkey

Reputation: 5267

I assume you've looked at the docs here http://docs.phonegap.com/en/1.0.0/phonegap_media_capture_capture.md.html

Can you try and print out debug messages in your success and error callback methods to see what is going on?

Upvotes: 1

Related Questions