03.08.2013 Views

Configuring USB on i.MX 6 Series Processors - Freescale ...

Configuring USB on i.MX 6 Series Processors - Freescale ...

Configuring USB on i.MX 6 Series Processors - Freescale ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<str<strong>on</strong>g>C<strong>on</strong>figuring</str<strong>on</strong>g> <str<strong>on</strong>g>USB</str<strong>on</strong>g> <strong>on</strong> i.<strong>MX</strong> 6 <strong>Series</strong> <strong>Processors</strong>, Rev. 0<br />

<str<strong>on</strong>g>C<strong>on</strong>figuring</str<strong>on</strong>g> the system for <str<strong>on</strong>g>USB</str<strong>on</strong>g> operati<strong>on</strong><br />

Set the PHCD bit in the PORTSC register to place the PHY in low-power mode.<br />

Set PWD bits in <str<strong>on</strong>g>USB</str<strong>on</strong>g>PHY_PWD register.<br />

Set CLKGATE in <str<strong>on</strong>g>USB</str<strong>on</strong>g>PHY_CTRL register to stop the PHY clock.<br />

Set WKDC bit in PORTSC 300 μS after the bus becomes idle (J-state) to avoid a false disc<strong>on</strong>nect<br />

wakeup.<br />

For device mode:<br />

Wait for suspend interrupt from the <str<strong>on</strong>g>USB</str<strong>on</strong>g> c<strong>on</strong>troller.<br />

Set the PHCD bit in the PORTSC register.<br />

Set PWD bits in <str<strong>on</strong>g>USB</str<strong>on</strong>g>PHY_PWD register.<br />

Set CLKGATE in <str<strong>on</strong>g>USB</str<strong>on</strong>g>PHY_CTRL register to stop the PHY clock.<br />

4.3.2.2 Exiting low power mode<br />

Since software disables the clocks and forces power-down mode to enter low-power mode, software must<br />

also re-enable the clocks and clear the Power Down bits for the PHY to wake-up.<br />

To do so, the wakeup interrupt must be enabled after entering low-power mode. Up<strong>on</strong> detecti<strong>on</strong> of the<br />

wakeup interrupt, software must perform the following acti<strong>on</strong>s to resume from low-power suspend.<br />

Clear the WIE bit in the corresp<strong>on</strong>ding <str<strong>on</strong>g>USB</str<strong>on</strong>g>_<str<strong>on</strong>g>USB</str<strong>on</strong>g>_x_CTRL register to clear the interrupt request<br />

— PHCD, CLKGATE and PWD bits will be cleared automatically by the wakeup event<br />

To exit low power mode under CPU c<strong>on</strong>trol (no <str<strong>on</strong>g>USB</str<strong>on</strong>g> wakeup event)<br />

Clear PHCD bits in the PORTSC register<br />

— CLKGATE and PWD will auto clear<br />

Set FPR in PORTSC to force resume<br />

Wait for FPR to clear, then re-enable HS disc<strong>on</strong>nect detector<br />

4.3.3 Operati<strong>on</strong>al settings<br />

In general, it is expected that the PHY operates as a UTMI+ level 3 PHY. In this mode, the PHY will have<br />

all capabilities enabled. The <str<strong>on</strong>g>USB</str<strong>on</strong>g> c<strong>on</strong>troller will automatically select the appropriate PHY setting based<br />

<strong>on</strong> its operati<strong>on</strong>al mode.<br />

4.3.3.1 General c<strong>on</strong>trols—<str<strong>on</strong>g>USB</str<strong>on</strong>g>PHY_CTRL register<br />

The following settings are essential for basic <str<strong>on</strong>g>USB</str<strong>on</strong>g> operati<strong>on</strong>.<br />

ENUTMILEVEL3 and ENUTMILEVEL2 Bits<br />

To enable full <str<strong>on</strong>g>USB</str<strong>on</strong>g> support <strong>on</strong> the PHY, bits ENUTMILEVEL3 and ENUTMILEVEL2, in the<br />

<str<strong>on</strong>g>USB</str<strong>on</strong>g>PHY_CTRL register, must be set. UTMI+ Level 2 adds support for directly c<strong>on</strong>nected low-speed<br />

devices. This is needed when the c<strong>on</strong>troller operates in host mode for operati<strong>on</strong> with low-speed devices<br />

such as <str<strong>on</strong>g>USB</str<strong>on</strong>g> mice. UTMI+ Level 3 adds support for directly c<strong>on</strong>nected full-speed hubs that need to support<br />

low-speed devices.<br />

<strong>Freescale</strong> Semic<strong>on</strong>ductor 7

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!