<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.2.3" -->
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>
<channel>
	<title>Comments on: iPhone input</title>
	<link>http://variogram.com/latest/?p=27</link>
	<description></description>
	<pubDate>Mon, 06 Sep 2010 22:48:35 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.2.3</generator>

	<item>
		<title>By: J.L. Allen</title>
		<link>http://variogram.com/latest/?p=27#comment-409</link>
		<dc:creator>J.L. Allen</dc:creator>
		<pubDate>Tue, 05 Feb 2008 05:36:40 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-409</guid>
		<description>The VoIP program for the iPod Touch uses default routes, so it doesn't need to route...the microphone is external, and apparently the default input is LineIn.  And I believe they kill the mediaserverd process.

For Funiculus, I use the approach where you start up an input audio queue and then call [AVRecorder activate], which does the microphone routing for me.  

The error you speak of (I think) is the device-not-ready error.  I found I was able to "rehabilitate" this by starting an AudioOutputQueue (letting the system do the thread), and then destroying it by calling AudioQueueDispose(false...etc).  And then I start another input queue with the AVRecorder trick.
 
We used to have a lot of this info on a wiki page on fiveforty.net before it shut down...I may revive that page on my own site.  I've currently posted some stuff about routing on http://www.iphonedevdocs.com/forum/showthread.php?t=411 .

As far as the commands needed to route the audio, I ran into an error message that someone posted on the blog that seemed to detail a series of commands about routing.  I've posted it on the iphonedevdocs forum page...</description>
		<content:encoded><![CDATA[<p>The VoIP program for the iPod Touch uses default routes, so it doesn&#8217;t need to route&#8230;the microphone is external, and apparently the default input is LineIn.  And I believe they kill the mediaserverd process.</p>
<p>For Funiculus, I use the approach where you start up an input audio queue and then call [AVRecorder activate], which does the microphone routing for me.  </p>
<p>The error you speak of (I think) is the device-not-ready error.  I found I was able to &#8220;rehabilitate&#8221; this by starting an AudioOutputQueue (letting the system do the thread), and then destroying it by calling AudioQueueDispose(false&#8230;etc).  And then I start another input queue with the AVRecorder trick.</p>
<p>We used to have a lot of this info on a wiki page on fiveforty.net before it shut down&#8230;I may revive that page on my own site.  I&#8217;ve currently posted some stuff about routing on <a href="http://www.iphonedevdocs.com/forum/showthread.php?t=411" rel="nofollow">http://www.iphonedevdocs.com/forum/showthread.php?t=411</a> .</p>
<p>As far as the commands needed to route the audio, I ran into an error message that someone posted on the blog that seemed to detail a series of commands about routing.  I&#8217;ve posted it on the iphonedevdocs forum page&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jo</title>
		<link>http://variogram.com/latest/?p=27#comment-408</link>
		<dc:creator>Jo</dc:creator>
		<pubDate>Sat, 26 Jan 2008 04:05:58 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-408</guid>
		<description>There is already a SIP app out for iPod touch -- check out http://touchmods.wordpress.com/</description>
		<content:encoded><![CDATA[<p>There is already a SIP app out for iPod touch &#8212; check out <a href="http://touchmods.wordpress.com/" rel="nofollow">http://touchmods.wordpress.com/</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ruslan Zalata</title>
		<link>http://variogram.com/latest/?p=27#comment-407</link>
		<dc:creator>Ruslan Zalata</dc:creator>
		<pubDate>Tue, 22 Jan 2008 22:11:47 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-407</guid>
		<description>I was able to successfully call to MeCCA_AudioRoutingPolicy::setRoutingPolicy("record.standard", "record.standard", "record.standard") after which getRoutingPolicy() returns "record.standard" as a result ad also getAudioInputDeviceUID() returns "device.microphone". But, I still receiving blank frames which means settng up audio routing is not the final problem to solve before we get mic recoding working :-(
 

Another problem I discovered is that if you try to connect a headset, the whole AudioQueue algorithm stops working, AudioQueueStart() returns error -536870184, which is odd. Unplugging headset "fixes" makes it working again. Does anybody else faced the same efect with headsets ?</description>
		<content:encoded><![CDATA[<p>I was able to successfully call to MeCCA_AudioRoutingPolicy::setRoutingPolicy(&#8221;record.standard&#8221;, &#8220;record.standard&#8221;, &#8220;record.standard&#8221;) after which getRoutingPolicy() returns &#8220;record.standard&#8221; as a result ad also getAudioInputDeviceUID() returns &#8220;device.microphone&#8221;. But, I still receiving blank frames which means settng up audio routing is not the final problem to solve before we get mic recoding working <img src='http://variogram.com/latest/wp-includes/images/smilies/icon_sad.gif' alt=':-(' class='wp-smiley' /> </p>
<p>Another problem I discovered is that if you try to connect a headset, the whole AudioQueue algorithm stops working, AudioQueueStart() returns error -536870184, which is odd. Unplugging headset &#8220;fixes&#8221; makes it working again. Does anybody else faced the same efect with headsets ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Peter</title>
		<link>http://variogram.com/latest/?p=27#comment-403</link>
		<dc:creator>Peter</dc:creator>
		<pubDate>Sun, 16 Dec 2007 13:17:52 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-403</guid>
		<description>Christian,
How did you called the MeCCA_AudioRoutingPolicy::setRoutingPolicy(char const*) method ?</description>
		<content:encoded><![CDATA[<p>Christian,<br />
How did you called the MeCCA_AudioRoutingPolicy::setRoutingPolicy(char const*) method ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christian Beer</title>
		<link>http://variogram.com/latest/?p=27#comment-402</link>
		<dc:creator>Christian Beer</dc:creator>
		<pubDate>Thu, 13 Dec 2007 09:48:50 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-402</guid>
		<description>J.L. Allen, did you use the Celestial Tip or the MeCCA-Tip? Tried both but non works for me. What Version of iPhone do you have? I have got 1.1.1.</description>
		<content:encoded><![CDATA[<p>J.L. Allen, did you use the Celestial Tip or the MeCCA-Tip? Tried both but non works for me. What Version of iPhone do you have? I have got 1.1.1.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: J.L. Allen</title>
		<link>http://variogram.com/latest/?p=27#comment-401</link>
		<dc:creator>J.L. Allen</dc:creator>
		<pubDate>Wed, 12 Dec 2007 00:12:31 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-401</guid>
		<description>I've been able to get non-blank buffers thanks to iFunk's advice.  Check the iPhone dev wiki--article is AudioQueue.  It's still screwy, but it works.</description>
		<content:encoded><![CDATA[<p>I&#8217;ve been able to get non-blank buffers thanks to iFunk&#8217;s advice.  Check the iPhone dev wiki&#8211;article is AudioQueue.  It&#8217;s still screwy, but it works.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christian Beer</title>
		<link>http://variogram.com/latest/?p=27#comment-400</link>
		<dc:creator>Christian Beer</dc:creator>
		<pubDate>Sun, 09 Dec 2007 22:00:51 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-400</guid>
		<description>"My first Test-Programm works though. Don’t know where the difference is. Checked all line of code twice." ... with "works" I mean: "doesn't give that error but only gives empty data"</description>
		<content:encoded><![CDATA[<p>&#8220;My first Test-Programm works though. Don’t know where the difference is. Checked all line of code twice.&#8221; &#8230; with &#8220;works&#8221; I mean: &#8220;doesn&#8217;t give that error but only gives empty data&#8221;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christian Beer</title>
		<link>http://variogram.com/latest/?p=27#comment-399</link>
		<dc:creator>Christian Beer</dc:creator>
		<pubDate>Sun, 09 Dec 2007 22:00:01 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-399</guid>
		<description>I've got the same problem, too. I always got the error "Error: AudioQueueStart failed (-536870184)". My fierst Test-Programm works though. Don't know where the difference is. Checked all line of code twice.

I've only got the sample code from the apple page. There is a sample called aqrecord.c.Checked against that code twice, too. 

I think they locked the microphone input.</description>
		<content:encoded><![CDATA[<p>I&#8217;ve got the same problem, too. I always got the error &#8220;Error: AudioQueueStart failed (-536870184)&#8221;. My fierst Test-Programm works though. Don&#8217;t know where the difference is. Checked all line of code twice.</p>
<p>I&#8217;ve only got the sample code from the apple page. There is a sample called aqrecord.c.Checked against that code twice, too. </p>
<p>I think they locked the microphone input.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: J.L.Allen</title>
		<link>http://variogram.com/latest/?p=27#comment-390</link>
		<dc:creator>J.L.Allen</dc:creator>
		<pubDate>Wed, 05 Dec 2007 01:38:48 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-390</guid>
		<description>I've been fooling with input, but I usually can't even get the AudioQueueStart to execute without an error.  Is there perhaps some sample code available?  (Including how to access these MeCCA methods...where are the headers for these?)  thanks, JLA</description>
		<content:encoded><![CDATA[<p>I&#8217;ve been fooling with input, but I usually can&#8217;t even get the AudioQueueStart to execute without an error.  Is there perhaps some sample code available?  (Including how to access these MeCCA methods&#8230;where are the headers for these?)  thanks, JLA</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christian Beer</title>
		<link>http://variogram.com/latest/?p=27#comment-374</link>
		<dc:creator>Christian Beer</dc:creator>
		<pubDate>Mon, 03 Dec 2007 00:31:29 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-374</guid>
		<description>Okay. Found out how to call C++ methods. Now as I call that method. How do I know if it worked? It doesn't seem to change anything... Do you have some other tips?</description>
		<content:encoded><![CDATA[<p>Okay. Found out how to call C++ methods. Now as I call that method. How do I know if it worked? It doesn&#8217;t seem to change anything&#8230; Do you have some other tips?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christian Beer</title>
		<link>http://variogram.com/latest/?p=27#comment-344</link>
		<dc:creator>Christian Beer</dc:creator>
		<pubDate>Wed, 28 Nov 2007 16:27:52 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-344</guid>
		<description>Please be patient if this sounds dumb: how can I call MeCCA_AudioRoutingPolicy::setRoutingPolicy(char const*)?
I am not a good C/obj-C coder so I don't know... Maybe you could give a hint or help me with this?
Does it help you to get mic input?

Thanks,
Christian</description>
		<content:encoded><![CDATA[<p>Please be patient if this sounds dumb: how can I call MeCCA_AudioRoutingPolicy::setRoutingPolicy(char const*)?<br />
I am not a good C/obj-C coder so I don&#8217;t know&#8230; Maybe you could give a hint or help me with this?<br />
Does it help you to get mic input?</p>
<p>Thanks,<br />
Christian</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christian Beer</title>
		<link>http://variogram.com/latest/?p=27#comment-166</link>
		<dc:creator>Christian Beer</dc:creator>
		<pubDate>Wed, 14 Nov 2007 15:06:04 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-166</guid>
		<description>Hello Mr. Whitman,

while trying to get the iphone audio with AudioQueue working I found your interersting site. It helped me quite a lot, thanks.

Did you find something new about iphone audio input? I tried quite a lot but I always got the same problem you've got with empty buffers.

If you have a tip or even a solution, that would help me immensely.


Thanks in advance,
Christian Beer</description>
		<content:encoded><![CDATA[<p>Hello Mr. Whitman,</p>
<p>while trying to get the iphone audio with AudioQueue working I found your interersting site. It helped me quite a lot, thanks.</p>
<p>Did you find something new about iphone audio input? I tried quite a lot but I always got the same problem you&#8217;ve got with empty buffers.</p>
<p>If you have a tip or even a solution, that would help me immensely.</p>
<p>Thanks in advance,<br />
Christian Beer</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: iFunk</title>
		<link>http://variogram.com/latest/?p=27#comment-4</link>
		<dc:creator>iFunk</dc:creator>
		<pubDate>Fri, 05 Oct 2007 17:13:16 +0000</pubDate>
		<guid>http://variogram.com/latest/?p=27#comment-4</guid>
		<description>Went deeper with using AudioQueue, and what happens is that you need to set the Infineon device routing properly. All multimedia handling is done through that device.

By default, the RoutingCategory is "playback.audiovideo", which only does a "AudioQueue"=&#62;OutputDevice routing, which is why AudioQueueOutput works perfectly fine, but AudioQueueInput does not, since there's not Something=&#62;AudioQueue routing being set up.

One the other hand, if you the AVRecord features of Celestial framework, it will internally set the RoutingCategory to "record.standard" which does a micrphone/HeadsetBT=&#62;"AudioQueue" routing, and if you run your AudioQueueInput code sample  while AVRecord is being used... you will actually get VALID samples from your microphone :)

By intercepting the Calls to MeCCA.Framework done by mediaserverd... it clearly calls MeCCA_AudioRoutingPolicy::setRoutingPolicy(char const*). Hope this help</description>
		<content:encoded><![CDATA[<p>Went deeper with using AudioQueue, and what happens is that you need to set the Infineon device routing properly. All multimedia handling is done through that device.</p>
<p>By default, the RoutingCategory is &#8220;playback.audiovideo&#8221;, which only does a &#8220;AudioQueue&#8221;=&gt;OutputDevice routing, which is why AudioQueueOutput works perfectly fine, but AudioQueueInput does not, since there&#8217;s not Something=&gt;AudioQueue routing being set up.</p>
<p>One the other hand, if you the AVRecord features of Celestial framework, it will internally set the RoutingCategory to &#8220;record.standard&#8221; which does a micrphone/HeadsetBT=&gt;&#8221;AudioQueue&#8221; routing, and if you run your AudioQueueInput code sample  while AVRecord is being used&#8230; you will actually get VALID samples from your microphone <img src='http://variogram.com/latest/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>By intercepting the Calls to MeCCA.Framework done by mediaserverd&#8230; it clearly calls MeCCA_AudioRoutingPolicy::setRoutingPolicy(char const*). Hope this help</p>
]]></content:encoded>
	</item>
</channel>
</rss>
