title: Independently selecting input and output audio paths
body: <p>I'm willing to make an app for iPad that does the following:</p>
  
  <p>When the headset and a 30 pin connector speaker/mic are plugged in at the same time the user has the ability to choose the both input and output path independently for real time audio streaming.</p>
  
  <p>Example:<br>
  User selects via touch events the input device as the headset mic and selects the output device as the internal speakers. The user can then speak into the headset mic and in real time hear their voice on the internal speakers.</p>
  
  <p>Then the user selects the 30-pin mic as the input and the headset speakers as the output.  And similarly, speaks into the 30-pin mic and hears the output on the headset speakers.</p>
  
  <p>Calls like the following do not work because it automatically changes the input or output to the same peripheral. </p>
  
  <pre><code>CFStringRef audioInputOverride = kAudioSessionInputRoute_HeadsetMic;
  
  AudioSessionSetProperty (kAudioSessionProperty_InputSource, sizeof(audioInputOverride), &amp;audioInputOverride);
  
  CFStringRef audioOutputOverride = kAudioSessionOutputRoute_USBAudio;
  
  AudioSessionSetProperty (kAudioSessionProperty_OutputDestination, sizeof(audioOutputOverride),&amp;audioOutputOverride);
  </code></pre>
  
  <p>Can I independently choose input/output in real time audio streaming?</p>