29.01.2015 Views

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

RM0008<br />

Controller area network (bxCAN)<br />

22.7.2 Time triggered communication mode<br />

In this mode, the internal counter of the CAN hardware is activated <strong>and</strong> used to generate the<br />

Time Stamp value stored in the CAN_RDTxR/CAN_TDTxR registers, respectively (for Rx<br />

<strong>and</strong> Tx mailboxes). The internal counter is incremented each CAN bit time (refer to<br />

Section 22.7.7: Bit timing). The internal counter is captured on the sample point of the Start<br />

Of Frame bit in both reception <strong>and</strong> transmission.<br />

22.7.3 Reception h<strong>and</strong>ling<br />

For the reception of CAN messages, three mailboxes organized as a FIFO are provided. In<br />

order to save CPU load, simplify the software <strong>and</strong> guarantee data consistency, the FIFO is<br />

managed completely by hardware. The application accesses the messages stored in the<br />

FIFO through the FIFO output mailbox.<br />

Valid message<br />

A received message is considered as valid when it has been received correctly according to<br />

the CAN protocol (no error until the last but one bit of the EOF field) <strong>and</strong> It passed through<br />

the identifier filtering successfully, see Section 22.7.4: Identifier filtering.<br />

Figure 199. Receive FIFO states<br />

EMPTY<br />

FMP=0x00<br />

FOVR=0<br />

Valid Message<br />

Received<br />

Release<br />

Mailbox<br />

PENDING_1<br />

FMP=0x01<br />

FOVR=0<br />

Release<br />

Mailbox<br />

RFOM=1<br />

Valid Message<br />

Received<br />

PENDING_2<br />

FMP=0x10<br />

FOVR=0<br />

Release<br />

Mailbox<br />

RFOM=1<br />

Valid Message<br />

Received<br />

PENDING_3<br />

FMP=0x11<br />

FOVR=0<br />

Valid Message<br />

Received<br />

Release<br />

Mailbox<br />

RFOM=1<br />

OVERRUN<br />

FMP=0x11<br />

FOVR=1<br />

Valid Message<br />

Received<br />

Doc ID 13902 Rev 9 551/995

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

Saved successfully!

Ooh no, something went wrong!