Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob

AURIX™ MCU: Usage of FlexRay channels - KBA236083

AURIX™ MCU: Usage of FlexRay channels - KBA236083

IFX_Publisher2
Community Manager
Community Manager
Community Manager
25 likes received 1000 replies posted First like given

Version: **

The FlexRay protocol described in the FlexRay protocol specification (irrespective of the version number), is a dual channel protocol (channel A and channel B). Usage of both channels is optional, so it is possible for the FlexRay devices to support a single channel. This may lead to an idea that the channels can be used interchangeably. This flexibility benefits the users in case of severe constraints on pin availability or if there are necessary changes to the PCB design late in the development. This document explains why FlexRay channels cannot be used interchangeably and also provides the recommendation on how to achieve certain level of flexibility in the channel selection.

The following figure shows the block diagram of the FlexRay protocol controller IP module called ERAY. Inside of the ERAY´s kernel there are two dedicated entities; one for channel A and another for channel B. The connection between each channel and the external world through the microcontroller port pins is achieved by using three signals: Transmit Data (TXD), Receive Data (RXD), and Transmit Data Enable Not (TXEN).

BinduPriya_G_0-1663570208775.png

 

In AURIX™ related documentation (for example, User Manual and Datasheet) there is always a suffix added to these signal names to define for which channel these signals are applicable. This implies to the user that these channels cannot be used interchangeable. However, there is a dedicated channel for these signals and their respective port pins.
The reason why the FlexRay channels cannot be interchanged is explained in the FlexRay frame CRC implementation.

FlexRay frame consists of two CRC fields: Header CRC that protects certain header segments and Frame CRC that is computed over header and payload segments. For Frame CRC field calculation, different initialization vectors are used for channel A and channel B defined by the FlexRay protocol specification as follows:

cCRCInit[A]

Initialization vector for the calculation of the frame CRC on channel A (hexadecimal)

0xFEDCBA

cCRCInit[B]

Initialization vector for the calculation of the frame CRC on channel B (hexadecimal)

0xABCDEF

 

This is the reason why channels cannot be used interchangeably; the transmission of FlexRay frames with the Frame CRC field value calculated for the channel A over channel B (or vice-versa) would lead to the CRC error.

To ease the development of the projects using FlexRay module and to allow greater flexibility in the FlexRay channel selection, AURIX™ devices provide a pin layout where the same pin functionality can be defined for both the channels. For example, AURIX™ TC39x device and the respective datasheet document, we can find the following definition for pin P14.0 (two relevant configurations for this document are marked in the figure below):

BinduPriya_G_1-1663570261053.png

 

This excerpt from the device datasheet can be understood as the pin P14.0 can be used as transmit data (TXD) pin for ERAY module 0, channel A or channel B depending on the pin alternate function configuration. Similar observation can be made for pins P14.1 and P14.9, where P14.1 can be used as receive data (RXD) pin for ERAY module 0, channel A or channel B and P14.9 can be used as transmit data enable not (TXEN) pin for ERAY module 0, channel A or channel B. With these three pins (P14.0, P14.1, and P14.9), the user has complete flexibility in the FlexRay channel selection.

For more details, see the “Pin Definition and Functions” section of the device datasheet document.

Note:  This KBA applies to the following series of AURIX™ MCUs:

  • AURIX™ TC2xx series
  • AURIX™ TC3xx series
0 Likes
587 Views