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 />

on which the transfer is not completed in the current frame. This interrupt is<br />

asserted along with the end of periodic frame interrupt<br />

(OTG_FS_GINTSTS/EOPF).<br />

● 3 OUT endpoints<br />

– Each of them can be configured to support the isochronous, bulk or interrupt<br />

transfer type<br />

– Each of them has a proper control (OTG_FS_DOEPCTLx), transfer configuration<br />

(OTG_FS_DOEPTSIZx) and status-interrupt (OTG_FS_DOEPINTx) register<br />

– Device Out endpoints common interrupt mask register (OTG_FS_DOEPMSK) is<br />

available to enable/disable a single kind of endpoint interrupt source on all of the<br />

OUT endpoints (EP0 included)<br />

– Support for incomplete isochronous OUT transfer interrupt (INCOMPISOOUT bit<br />

in OTG_FS_GINTSTS), asserted when there is at least one isochronous OUT<br />

endpoint on which the transfer is not completed in the current frame. This interrupt<br />

is asserted along with the end of periodic frame interrupt<br />

(OTG_FS_GINTSTS/EOPF).<br />

Endpoint control<br />

● The following endpoint controls are available to the application through the device<br />

endpoint-x IN/OUT control register (DIEPCTLx/DOEPCTLx):<br />

– Endpoint enable/disable<br />

– Endpoint activate in current configuration<br />

– Program USB transfer type (isochronous, bulk, interrupt)<br />

– Program supported packet size<br />

– Program Tx-FIFO number associated with the IN endpoint<br />

– Program the expected or transmitted data0/data1 PID (bulk/interrupt only)<br />

– Program the even/odd frame during which the transaction is received or<br />

transmitted (isochronous only)<br />

– Optionally program the NAK bit to always negative-acknowledge the host<br />

regardless of the FIFO status<br />

– Optionally program the STALL bit to always stall host tokens to that endpoint<br />

– Optionally program the SNOOP mode for OUT endpoint not to check the CRC<br />

field of received data<br />

Endpoint transfer<br />

The device endpoint-x transfer size registers (DIEPTSIZx/DOEPTSIZx) allow the application<br />

to program the transfer size parameters and read the transfer status. Programming must be<br />

done before setting the endpoint enable bit in the endpoint control register. Once the<br />

endpoint is enabled, these fields are read-only as the OTG FS core updates them with the<br />

current transfer status.<br />

The following transfer parameters can be programmed:<br />

● Transfer size in bytes<br />

● Number of packets that constitute the overall transfer size<br />

Doc ID 018909 Rev 3 1026/1416

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

Saved successfully!

Ooh no, something went wrong!