<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forums.obdev.at/app.php/feed/topic/6199" />

	<title>Objective Development Forums</title>
	
	<link href="https://forums.obdev.at/index.php" />
	<updated>2011-11-15T14:41:12+02:00</updated>

	<author><name><![CDATA[Objective Development Forums]]></name></author>
	<id>https://forums.obdev.at/app.php/feed/topic/6199</id>

		<entry>
		<author><name><![CDATA[Daid]]></name></author>
		<updated>2011-11-15T14:41:12+02:00</updated>

		<published>2011-11-15T14:41:12+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=6199&amp;p=20194#p20194</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=6199&amp;p=20194#p20194"/>
		<title type="html"><![CDATA[Re: USB pins: INPUT or OUTPUT?]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=6199&amp;p=20194#p20194"><![CDATA[
Both. The USB pins are bi-directional. I think the USB code configures them anyhow, for bi-directional ports you need to change both the DDR and PORT register.<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=5154">Daid</a> — Tue Nov 15, 2011 2:41 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[TheDude]]></name></author>
		<updated>2011-11-15T00:11:29+02:00</updated>

		<published>2011-11-15T00:11:29+02:00</published>
		<id>https://forums.obdev.at/viewtopic.php?t=6199&amp;p=20185#p20185</id>
		<link href="https://forums.obdev.at/viewtopic.php?t=6199&amp;p=20185#p20185"/>
		<title type="html"><![CDATA[USB pins: INPUT or OUTPUT?]]></title>

		
		<content type="html" xml:base="https://forums.obdev.at/viewtopic.php?t=6199&amp;p=20185#p20185"><![CDATA[
Hi all,<br /><br /><div class="codebox"><p>Code: </p><pre><code>DDRD = ~(1 &lt;&lt; 2);   /* all outputs except PD2 = INT0 */<br />DDRB = ~USBMASK;    /* set all pins as outputs except USB */<br /></code></pre></div><br />form the PowerSwitch example project<br />so USB is input<br /><br /><br /><div class="codebox"><p>Code: </p><pre><code>DDRD = 7;    /* 0000 0111 bin: all pins input except USB (-&gt; USB reset) */<br /></code></pre></div><br />from HIDKeys example project<br />so USB is output<br /><br />what now, input or output?<br /> <img class="smilies" src="./../../../images/smilies/icon_question.gif" alt=":?:" title="Question" /> <br /><br /><br />thx<p>Statistics: Posted by <a href="https://forums.obdev.at/memberlist.php?mode=viewprofile&amp;u=6021">TheDude</a> — Tue Nov 15, 2011 12:11 am</p><hr />
]]></content>
	</entry>
	</feed>
