Saturday, February 4th, 2012

Protocol

The prevalent communications protocol for automotive control applications still is CAN, the Controller Area Network. The future, however, is FlexRay. Technically, FlexRay is a real-time communications system combining a static and a dynamic part. It is based on an extended TDMA (time-division multiple access) media access strategy. A communication cycle has to be set up and the duration has to be defined when the network is configured. This fundamental element of the media access scheme consists of a mandatory static segment, an optional dynamic segment and two protocol segments called symbol window (optional) and network idle time (mandatory). One or more communication cycles form application cycles which are executed from start-up of the network until its shutdown.

Static segments


In the fixed-length static segment, deterministic communication timing takes care of important requirements like latency and jitter. Since FlexRay adheres to a TDMA pattern with equally sized slots, the point of time is exactly known when a frame is transmitted on the channel. Furthermore, each ECU has their own exclusive slot ensuring the transmission of their data. The configuration parameters of the FlexRay controllers determine the number and the duration of the slots and thus constitute a stringent framework. Since the slot assignment and the scheduling are done off-line during the system planning, on-line competition for the communication medium is excluded. This planning work is essential for the successfully setting up a FlexRay system and totally differs from the planning requirements of CAN. Introducing FlexRay into the design process therefore means introducing a new design paradigm.

Dynamic segment


Event-driven communication needs, e.g. for diagnosis data, are taken care of in the dynamic segment which consists of one slot of fixed duration. This segment follows a dynamic minislotting scheme, generally referred to as FTDMA (FlexRay time-division multiple access) and a demand driven access pattern in order to use the bandwidth for dynamic communication. If the controller sends a message, the minislot expands into a message transmission. If there is no message to be sent, the minislot elapses unused as a short idle period. All controllers in the FlexRay network therefore maintain a consistent view about the active minislot. Since the dynamic segment and the minislots are globally configured, it is again extremely important to plan off-line in order to ensure the best mix between flexibility and performance.

The FlexRay communication cylcle

Symbol windows and network idle time (NIT)


Apart from the static and dynamic segments, a FlexRay communication cycle consists of an optional symbol window and a network idle time. The purpose of the symbol window is to send special symbols, e.g., wakeup, startup, and alarm symbols. The configurable NIT concludes the communication cycle and is basically communication-free. The NIT is required for protocol specific communication such as synchronization of common time base. The configuration has to guarantee that the remaining length of the NIT is sufficient for the execution of computations of, e.g., calculation of clock correction values, error handling, update of error indicators, and counters).

Combining the segments


A static segment and a network idle time are mandatory for each communication cycle whereas dynamic segments and symbol window are optional. In principle, this setup allows three configurations:

  • A pure static configuration containing only static slots for transmission.

  • A mixed configuration consisting of a static and a dynamic segment with a varying between static bandwidth and dynamic bandwidth.

  • A pure dynamic configuration with all bandwidth assigned to dynamic communication.