2

I face one issue during recording is on going, if i press home button, i noticed " Red banner comes and disappear suddenly" and AVAudioRecorder can not create file properly. Please help what is this ?. is it something like network connectivity related ?

Red banner comes and disappear suddenly when press home button during recording on going

Please help.

Hardik Darji
  • 3,633
  • 1
  • 30
  • 30

1 Answers1

2

The "red banner" indicates that your application is currently using the microphone hardware. It is shown by applications that have active control over the main recording context, and hides when your application releases it's hold on the recording context (such as when the home button is pressed). Because you cannot predict when the home button will be pressed to exit your application, you will need to either support background recording to persist the banner (then gracefully release your context after a second or two to have the status bar animate back to black), or somehow terminate your context before the application closes.

CodaFi
  • 43,043
  • 8
  • 107
  • 153
  • Hey I have one more question, if i handle background process, and make pause a recording and again make continues recording when app come back in foreground, is it possibility for FAIL RECORDING...? or it create corrupted file (file created with 48k) ? As i found it happen in sometime... Please help.. – Hardik Darji Nov 12 '12 at 07:43
  • 2
    Hello please help me for below point. I did all coding for recording, start, pause, stop and play. when i start recording with AVAudioRecorder, "RED BANNER" comes and suddenly goes out like fade,i stayed in app (not goes to background like). And same file is created by recorder is corrupted. please help, Thanks in advance. – Hardik Darji Nov 12 '12 at 13:28
  • is it possible, "RED BANNER" comes when network connectivity is change ? – Hardik Darji Nov 19 '12 at 09:49
  • 1
    No. When network connectivity changes, either the network indicator changes, or the Wi-Fi indicator changes, never the status bar itself. – CodaFi Nov 19 '12 at 14:59
  • Thanks for reply. but, I can not find exact reason, why does this happen, RED BANNER comes and disappear during recording. please help. – Hardik Darji Nov 21 '12 at 09:32
  • You just found your reason: when a recording context enters the background, the springboard shows a red banner. It's so that if hackers gain access to the recording hardware, or an app runs a little long with it's context, that at least the users knows which one it is, and can kill it. – CodaFi Nov 21 '12 at 15:21
  • 2
    I understand, when app goes in background mode, springboard display red banner. But when a recording context is in foreground, still it display red double size status bar, and suddenly disappear. it happen some time, and recording file is corrupted when it appears. Please help.Thanks. – Hardik Darji Nov 22 '12 at 06:41