Audio stopped playing in latest version of our app on some iPads

Hi,

Bit of a weird one…

Since the latest release of our app, I’ve had several customers on older iPads (one on a 2012 4th Gen iPad and one on an iPad Air 2) mention that the audio in our app has stopped playing.

We changed nothing to do with audio playback on the latest version - I made one small change to something totally unrelated and that was it - just a minor bug fix.

I can’t replicate it at all (and I even have an iPad Air 2) with any version of iOS or on any of the 4 or 5 Apple devices we’ve tested on. All audio plays perfectly for me on every device I’ve tried it on (various iPads and an iPhone).

It’s definitely an issue though - several customers downloaded our update and suddenly it stopped working. The only common thread is they have reasonably old iPads.

The code I’m using to play audio is below:

local playbackSoundHandle = audio.loadStream( "soundeffect.aif", system.DocumentsDirectory ); audio.play( playbackSoundHandle, { onComplete=nil } );

Is there any reason why this should suddenly be happening? The version of iOS doesn’t seem to make any difference - it’s happening before and after update to the latest iOS.

The app was published with Corona daily build number 2017.3080.

Thanks,

Ian

What sample rate are you using?  44k 22k 11k … ?

If you’re using a non-standard rate to save space you may find that some devices won’t play the sounds.  Why this would suddenly start happening sounds like a driver (or the equivalent) update/change in iOS support on those devices.

Note: This is all guessing, but I have encountered such issues long ago and tracked it to me being too clever with sample rates for my own good.

You have ruled out  mute being an issue?

Hi - thanks for the replies.

Yes - ruled out mute. It’s 3 people suddenly having the issue at the same time having updated our apps to recently released versions and asked all 3 about mute and all say other apps (the ones mentioned as working I’m fairly sure are non Corona) work and mute definitely not on. Have also ruled out sticky tape over the speakers (we’ve had that one before).

Sample rate is the default - haven’t messed with it at all. 44.1K. All clips are 44.1K and build.settings:

audioPlayFrequency = 44100

I have tried changing loadStream to loadSound but that makes no difference to anyone apparently. Still doesn’t play.

The folks experiencing the problem have said our other apps also have the same sound playing issue since the last updates we released. In none of those apps did we make any changes to anything even remotely linked to audio.

Have also checked case sensitivity of all audio files and they all match exactly what I’m asking the code to play.

It’s looking like something to do with apps published using more recent versions of Corona aren’t playing sound on a small proportion of older iPads (2012 - 2014). Those are the only common factors I can find.

Frustratingly, I have the same iPad model as one of the people who have mentioned the problem and every app works fine on my version of that iPad on both versions of iOS I ran it on. Also works fine on the other iPads we have and several iPhones I’ve tested on too.

Incredibly frustrating one to try and solve as can’t replicate and nothing looks amiss in the code.

The app isn’t crashing for these people - it’s just silent.

Is anyone aware of anything either Corona or Apple have done that may have affected how audio is played recently?

Thanks,

Ian

I don’t know what your install base is like but 3 seems far too low to be anything other that something local to those devices.

I have an ancient iPad I could try for you… send me a link to one of your affected apps.  If it is paid then a promo code too.

Hi there,

Thanks for the response and offer of help. Really appreciate you taking the time.

Around 50,000 people have upgraded to the latest version of the app in the last couple of days and those are the only ones I’ve heard from. Even gone to the point of ordering an old iPad that matches the exact spec of one of those affected. It just arrived and the app works fine! I also have an ancient iPad from 2011 and that also works fine. Had various friends / family test it and they’re fine too.

It’s just weird that it’s suddenly happened recently to folks who have always been able to hear the audio and now they can’t. All claim to have done nothing different to their devices recently except upgrade our app. They update to the latest version of our app and suddenly no audio, but other apps are playing sound fine apparently.

Just heard from another one as I’m typing this, so that’s now 4.

Thanks for the offer of testing - much appreciated. Promo code is: E9P63K6RW37R

The app is an educational app for kids to help them with their spellings and it’s called Squeebles Spelling Test.

To test the issue:

  • Tap the “Parent / Teacher Zone” button
  • Tap the orange “KeyStageFun Tests” button
  • Tap the “Downloadable Tests” tab
  • Go into one of the categories by tapping the “View Tests” button and tick the box next to one or more tests to select them.
  • Tap the “Download selected” button.
  • Once downloaded, a popup will appear. Tap the “Okay, thanks” option and you’ll be taken to a list of tests you’ve now downloaded and have accessible on the device.
  • Tap the green “Words” button next to the first / only test on the list.
  • Tap the green “Listen” button. The audio should now play for that word and you should hear it spoken by a woman’s voice.

As well as being able to hear the words spoken, can you hear the general sound effects (i.e. try tapping the character on the home screen to make it bounce - do you hear a bouncing sound?)

Really appreciate you taking the time to help with this. It’s a massive help - hate problems like this where you can’t replicate it!!

Thanks,

Ian

Hold your horses!!!

Turns out it was the mute button issue after all.

I’d asked everyone whether the devices were muted and got a no from all of them, but their reasoning was that other apps were working so therefore their device couldn’t be muted.

Turns out that our previous use of this code for older versions of iOS then wasn’t running with the new iOS and therefore the mute switch wasn’t being overriden:

if audio.supportsSessionProperty then        audio.setSessionProperty(audio.MixMode, audio.MediaPlaybackMixMode); end

Hugely sorry for wasting anyone’s time on here - I had asked the question of every person who reported the problem and that wasn’t my intention. Been banging my head against a brick wall for 2 days now, so very pleased to have solved the issue.

There’s a plugin that allows you to check if a device is muted which I’ll add in so I can alert people if they’ve left it off on older iPads.

Once again - apologies for wasting time - hopefully this thread can help someone else if they’re in the same situation.

Thanks,

Ian

It had to be really and happy to help…

FYI, after a bit of lunch I tested your app on my iPad 2 Wi-Fi 16GB and sounds work fine.

Thanks for all your help - really appreciated.

Am now in conversation with one more customer who swears it isn’t the mute issue but I think they’re not seeing the option of muting via the Control Centre - i.e. their device has no physical mute button so they assume it isn’t the problem.

It’s an interesting usability / ethics dilemma - the above code allows you to (unsupported I know) bypass the mute button, but in my mind, if someone has muted their device that’s because they WANT their device muted.

Overriding it seems wrong, but in our app the audio is actually essential (i.e. not just sound effects to enhance experience but actually a main feature, without which you couldn’t use the app). Not really sure where I stand on it, but I’m going with the logic that if someone is trying to take a spelling test on our app that they know is meant to involve audio being spoken, they’re probably happy at that stage for us to override the mute button!

Thanks again for the help (and sorry for wasting your time).

All the best,

Ian

In your case I would say sound is core to the UX for the speech part.  Perhaps if they are muted then ONLY sound out words but suppress sound FX?

Sorry to bother you mates, but this seems to be the only related thread which is about ios devices audio playback issue. i have a question here and may i have your answer? I downloaded a AU audio file on the internet (about my own job) but it cannot be played on my Apple player and I do not know why. I download this audio conversion program as you can see (http://www.videoconverterfactory.com/tips/au-to-mp3.html) to convert this AU file. But just before conversion began, it required me to preset some sort of parameters, i know i should choose MP3. But how about the sample rate and bit rate, ? What are the meaning of these two parameters? What should i do, does any one know?

Hi @krpsowtf

Welcome to the Corona community forums.

These forums are for developers who use Corona, the 2D game and app making framework. This is not a forum to provide basic iPhone/iOS support. You likely won’t get the answer you’re looking for here.

Rob

What sample rate are you using?  44k 22k 11k … ?

If you’re using a non-standard rate to save space you may find that some devices won’t play the sounds.  Why this would suddenly start happening sounds like a driver (or the equivalent) update/change in iOS support on those devices.

Note: This is all guessing, but I have encountered such issues long ago and tracked it to me being too clever with sample rates for my own good.

You have ruled out  mute being an issue?

Hi - thanks for the replies.

Yes - ruled out mute. It’s 3 people suddenly having the issue at the same time having updated our apps to recently released versions and asked all 3 about mute and all say other apps (the ones mentioned as working I’m fairly sure are non Corona) work and mute definitely not on. Have also ruled out sticky tape over the speakers (we’ve had that one before).

Sample rate is the default - haven’t messed with it at all. 44.1K. All clips are 44.1K and build.settings:

audioPlayFrequency = 44100

I have tried changing loadStream to loadSound but that makes no difference to anyone apparently. Still doesn’t play.

The folks experiencing the problem have said our other apps also have the same sound playing issue since the last updates we released. In none of those apps did we make any changes to anything even remotely linked to audio.

Have also checked case sensitivity of all audio files and they all match exactly what I’m asking the code to play.

It’s looking like something to do with apps published using more recent versions of Corona aren’t playing sound on a small proportion of older iPads (2012 - 2014). Those are the only common factors I can find.

Frustratingly, I have the same iPad model as one of the people who have mentioned the problem and every app works fine on my version of that iPad on both versions of iOS I ran it on. Also works fine on the other iPads we have and several iPhones I’ve tested on too.

Incredibly frustrating one to try and solve as can’t replicate and nothing looks amiss in the code.

The app isn’t crashing for these people - it’s just silent.

Is anyone aware of anything either Corona or Apple have done that may have affected how audio is played recently?

Thanks,

Ian

I don’t know what your install base is like but 3 seems far too low to be anything other that something local to those devices.

I have an ancient iPad I could try for you… send me a link to one of your affected apps.  If it is paid then a promo code too.

Hi there,

Thanks for the response and offer of help. Really appreciate you taking the time.

Around 50,000 people have upgraded to the latest version of the app in the last couple of days and those are the only ones I’ve heard from. Even gone to the point of ordering an old iPad that matches the exact spec of one of those affected. It just arrived and the app works fine! I also have an ancient iPad from 2011 and that also works fine. Had various friends / family test it and they’re fine too.

It’s just weird that it’s suddenly happened recently to folks who have always been able to hear the audio and now they can’t. All claim to have done nothing different to their devices recently except upgrade our app. They update to the latest version of our app and suddenly no audio, but other apps are playing sound fine apparently.

Just heard from another one as I’m typing this, so that’s now 4.

Thanks for the offer of testing - much appreciated. Promo code is: E9P63K6RW37R

The app is an educational app for kids to help them with their spellings and it’s called Squeebles Spelling Test.

To test the issue:

  • Tap the “Parent / Teacher Zone” button
  • Tap the orange “KeyStageFun Tests” button
  • Tap the “Downloadable Tests” tab
  • Go into one of the categories by tapping the “View Tests” button and tick the box next to one or more tests to select them.
  • Tap the “Download selected” button.
  • Once downloaded, a popup will appear. Tap the “Okay, thanks” option and you’ll be taken to a list of tests you’ve now downloaded and have accessible on the device.
  • Tap the green “Words” button next to the first / only test on the list.
  • Tap the green “Listen” button. The audio should now play for that word and you should hear it spoken by a woman’s voice.

As well as being able to hear the words spoken, can you hear the general sound effects (i.e. try tapping the character on the home screen to make it bounce - do you hear a bouncing sound?)

Really appreciate you taking the time to help with this. It’s a massive help - hate problems like this where you can’t replicate it!!

Thanks,

Ian

Hold your horses!!!

Turns out it was the mute button issue after all.

I’d asked everyone whether the devices were muted and got a no from all of them, but their reasoning was that other apps were working so therefore their device couldn’t be muted.

Turns out that our previous use of this code for older versions of iOS then wasn’t running with the new iOS and therefore the mute switch wasn’t being overriden:

if audio.supportsSessionProperty then        audio.setSessionProperty(audio.MixMode, audio.MediaPlaybackMixMode); end

Hugely sorry for wasting anyone’s time on here - I had asked the question of every person who reported the problem and that wasn’t my intention. Been banging my head against a brick wall for 2 days now, so very pleased to have solved the issue.

There’s a plugin that allows you to check if a device is muted which I’ll add in so I can alert people if they’ve left it off on older iPads.

Once again - apologies for wasting time - hopefully this thread can help someone else if they’re in the same situation.

Thanks,

Ian

It had to be really and happy to help…

FYI, after a bit of lunch I tested your app on my iPad 2 Wi-Fi 16GB and sounds work fine.

Thanks for all your help - really appreciated.

Am now in conversation with one more customer who swears it isn’t the mute issue but I think they’re not seeing the option of muting via the Control Centre - i.e. their device has no physical mute button so they assume it isn’t the problem.

It’s an interesting usability / ethics dilemma - the above code allows you to (unsupported I know) bypass the mute button, but in my mind, if someone has muted their device that’s because they WANT their device muted.

Overriding it seems wrong, but in our app the audio is actually essential (i.e. not just sound effects to enhance experience but actually a main feature, without which you couldn’t use the app). Not really sure where I stand on it, but I’m going with the logic that if someone is trying to take a spelling test on our app that they know is meant to involve audio being spoken, they’re probably happy at that stage for us to override the mute button!

Thanks again for the help (and sorry for wasting your time).

All the best,

Ian