29.01.2015 Views

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

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.

RM0008<br />

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

OTG_FS reset register (OTG_FS_GRSTCTL)<br />

Address offset: 0x10<br />

Reset value: 0x2000 0000<br />

The application uses this register to reset various hardware features inside the core.<br />

31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0<br />

AHBIDL<br />

TXFNUM<br />

Reserved<br />

TXFFLSH<br />

RXFFLSH<br />

Reserved<br />

FCRST<br />

HSRST<br />

CSRST<br />

r rw rs rs rs rs rs<br />

Bit 31 AHBIDL: AHB master idle<br />

Indicates that the AHB master state machine is in the Idle condition.<br />

Note: Accessible in both Device <strong>and</strong> Host modes.<br />

Bits 30:11 Reserved<br />

Bits 10:6 TXFNUM: TxFIFO number<br />

This is the FIFO number that must be flushed using the TxFIFO Flush bit. This field must not be<br />

changed until the core clears the TxFIFO Flush bit.<br />

● 00000:<br />

– Non-periodic TxFIFO flush in Host mode<br />

– Tx FIFO 0 flush in Device mode<br />

● 00001:<br />

– Periodic TxFIFO flush in Host mode<br />

– TXFIFO 1 flush in device mode<br />

● 00010: TXFIFO 2 flush in device mode<br />

...<br />

● 00101: TXFIFO 15 flush in device mode<br />

● 10000: Flush all the transmit FIFOs in device or host mode.<br />

Note: Accessible in both Device <strong>and</strong> Host modes.<br />

Bit 5 TXFFLSH: TxFIFO flush<br />

This bit selectively flushes a single or all transmit FIFOs, but cannot do so if the core is in the<br />

midst of a transaction.<br />

The application must write this bit only after checking that the core is neither writing to the<br />

TxFIFO nor reading from the TxFIFO. Verify using these registers:<br />

Read—NAK Effective Interrupt ensures the core is not reading from the FIFO<br />

Write—AHBIDL bit in OTG_FS_GRSTCTL ensures the core is not writing anything to the<br />

FIFO.<br />

Note: Accessible in both Device <strong>and</strong> Host modes.<br />

Bit 4 RXFFLSH: RxFIFO flush<br />

The application can flush the entire RxFIFO using this bit, but must first ensure that the core is<br />

not in the middle of a transaction.<br />

The application must only write to this bit after checking that the core is neither reading from the<br />

RxFIFO nor writing to the RxFIFO.<br />

The application must wait until the bit is cleared before performing any other operations. This bit<br />

requires 8 clocks (slowest of PHY or AHB clock) to clear.<br />

Note: Accessible in both Device <strong>and</strong> Host modes.<br />

Doc ID 13902 Rev 9 729/995

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

Saved successfully!

Ooh no, something went wrong!