09.12.2012 Views

RM0090: Reference manual - STMicroelectronics

RM0090: Reference manual - STMicroelectronics

RM0090: Reference manual - STMicroelectronics

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>RM0090</strong> USB on-the-go full-speed (OTG_FS)<br />

FIFO and queue status register (HNPTXSTS) are read-only registers which can be used by<br />

the application to read the status of each request queue. They contain:<br />

● The number of free entries currently available in the periodic (nonperiodic) request<br />

queue (8 max)<br />

● Free space currently available in the periodic (nonperiodic) Tx-FIFO (out-transactions)<br />

● IN/OUT token, host channel number and other status information.<br />

As request queues can hold a maximum of 8 entries each, the application can push to<br />

schedule host transactions in advance with respect to the moment they physically reach the<br />

SB for a maximum of 8 pending periodic transactions plus 8 pending nonperiodic<br />

transactions.<br />

To post a transaction request to the host scheduler (queue) the application must check that<br />

there is at least 1 entry available in the periodic (nonperiodic) request queue by reading the<br />

PTXQSAV bits in the OTG_FS_HNPTXSTS register or NPTQXSAV bits in the<br />

OTG_FS_HNPTXSTS register.<br />

30.7 SOF trigger<br />

Figure 360. SOF connectivity<br />

The OTG FS core provides means to monitor, track and configure SOF framing in the host<br />

and peripheral, as well as an SOF pulse output connectivity feature.<br />

Such utilities are especially useful for adaptive audio clock generation techniques, where the<br />

audio peripheral needs to synchronize to the isochronous stream provided by the PC, or the<br />

host needs to trim its framing rate according to the requirements of the audio peripheral.<br />

30.7.1 Host SOFs<br />

STM32F4xx<br />

STM32F4xx<br />

TIM2<br />

ITR1 SOF<br />

pulse<br />

SOFgen<br />

PA8<br />

PA9<br />

PA11<br />

PA12<br />

PA10<br />

SOF pulse output, to<br />

external audio control<br />

In host mode the number of PHY clocks occurring between the generation of two<br />

consecutive SOF (FS) or Keep-alive (LS) tokens is programmable in the host frame interval<br />

register (HFIR), thus providing application control over the SOF framing period. An interrupt<br />

is generated at any start of frame (SOF bit in OTH_FS_GINTSTS). The current frame<br />

VBUS<br />

Doc ID 018909 Rev 3 1032/1416<br />

D -<br />

D +<br />

ID<br />

V SS<br />

USB mic ro-AB connector<br />

MS19907V2

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

Saved successfully!

Ooh no, something went wrong!