corona wav files do not work on iphone

I have been having this issue for a while. This game that I am building used to work fine with audio files and then it stopped. Not sure what happened as this has been a weekend project for several months. Iphone4s, build 2012.843, I’ve tried audio.play() and media.playEventSound(). Both work flawlessly on the simulator but do not work on the iphone. All wav files (that used to work) - 96000 sample rate, 16 bit, stereo, uncompressed.

Any ideas? [import]uid: 13726 topic_id: 29929 reply_id: 329929[/import]

OOI, have you tested on more than one iDevice? I would be happy to test this Monday, currently traveling and without my cable today but until then any additional info would be useful :slight_smile: [import]uid: 52491 topic_id: 29929 reply_id: 120017[/import]

As a tip only:

Be sure to not call the [lua]audio.stop()[/lua] API passing any handle of your loaded audio file as it will cause you an error with the recent daily-builds. (recent because before it used to work like that)

So, you now call it as: [lua]audio.stop( [channel] )[/lua] and if you do not pass any channel, so all the channels are stopped.

I know that maybe what am telling you isn`t related to your own specific problem right now, but any way, this caused me trouble today when getting some built apps of the past and seeing they stopped working because of me passing the handle to [lua]audio.stop()[/lua] instead passing the channel only.

So, it is more like an advice for you and all other Corona Devs that used to work with this API by the other way.
Luck,
Cheers,
Rodrigo.

[import]uid: 89165 topic_id: 29929 reply_id: 120020[/import]

OOI, have you tested on more than one iDevice? I would be happy to test this Monday, currently traveling and without my cable today but until then any additional info would be useful :slight_smile: [import]uid: 52491 topic_id: 29929 reply_id: 120017[/import]

As a tip only:

Be sure to not call the [lua]audio.stop()[/lua] API passing any handle of your loaded audio file as it will cause you an error with the recent daily-builds. (recent because before it used to work like that)

So, you now call it as: [lua]audio.stop( [channel] )[/lua] and if you do not pass any channel, so all the channels are stopped.

I know that maybe what am telling you isn`t related to your own specific problem right now, but any way, this caused me trouble today when getting some built apps of the past and seeing they stopped working because of me passing the handle to [lua]audio.stop()[/lua] instead passing the channel only.

So, it is more like an advice for you and all other Corona Devs that used to work with this API by the other way.
Luck,
Cheers,
Rodrigo.

[import]uid: 89165 topic_id: 29929 reply_id: 120020[/import]

The sound works on my ipad! So how can I tell why it doesn’t work on my iPhone? [import]uid: 13726 topic_id: 29929 reply_id: 121585[/import]

96000 Hz is an unusual number and awfully high. It might be that your iPhone hardware can’t handle it. Try one of the big 3 instead:
11025 Hz
22050 Hz
44100 Hz
We don’t guarantee other sample rates will work.
[import]uid: 7563 topic_id: 29929 reply_id: 121595[/import]

The sound works on my ipad! So how can I tell why it doesn’t work on my iPhone? [import]uid: 13726 topic_id: 29929 reply_id: 121585[/import]

96000 Hz is an unusual number and awfully high. It might be that your iPhone hardware can’t handle it. Try one of the big 3 instead:
11025 Hz
22050 Hz
44100 Hz
We don’t guarantee other sample rates will work.
[import]uid: 7563 topic_id: 29929 reply_id: 121595[/import]