Automotive Ethernet-FlexRay

Summary:

What exactly is FlexRay?

1. What is FlexRay?

So what exactly is FlexRay? To put it simply, it is a combination of CAN bus and LIN bus to arrange a schedule, increase speed and add redundancy. Based on TDMA like LIN, it increases the complexity of the protocol, with static and dynamic parts. The dynamic part is similar to the CAN bus and is sent based on events and priorities. In this way, with the complexity of the protocol, through flexible configuration, a more secure, reliable, and real-time vehicle communication system can be designed to meet new technical requirements.

The function is powerful and the configuration is more flexible, but the cost has also gone up. Not only the hardware cost, but configuring FlexRay is much more complicated than its sibling bus, which requires more manpower and time. For a technology, if its cost threshold is high, it will hinder the large-scale output and promotion of this technology. Without large-scale application, the relative chip cost will be difficult to further reduce, which is a bit like the Matthew effect, which is also predicted in the above figure. One of the reasons why FlexRay can't get out of the 2020s. But whether the Ethernet 10BaseT1s that is getting more and more popular can really replace these traditional vehicle buses.

2. How does FlexRay realize the function

FlexRay has a redundant design for dual-channel communication. The bandwidth of each channel is 10Mbps, and it can be flexibly set so that the two channels are mutually backup and redundant at the same time point; you can also choose dual channels to send different information to achieve a bandwidth of 20Mbps. In this way, FlexRay fits higher-level application scenarios that are safety and time-critical, and can also be applied in powertrain and body control. Neither the CAN bus nor the LIN bus can do the job in these scenarios. Regarding the bus size and node capacity of FlexRay, some say 24 meters and some say 22 meters. There is no need to dig into it. Generally, this length cannot be reached.

The static and dynamic parts can be further divided to get smaller time cake slots, which are the FlexRay data frames. FlexRay consists of 5Bytes frame header, 0 to 254Bytes Payload and 3Bytes tail.

Static data blocks are divided into a series of Slots and distributed to different nodes, and the same node can be assigned multiple Slots. But the same Slot can only be assigned to one node. When the corresponding moment on the time axis arrives, if the node is ready for the corresponding data frame, it sends a data frame, if not, it sends an empty frame, or repeats. The static part is fixedly allocated, just like the timetable for classes during the day, which ensures that nodes assigned to time resources always have the opportunity to send data. The Dynamic part is dynamic, a bit like evening self-study, and it is an evening self-study with unfixed class hours, and students can match it semi-freely.

The dynamic part is the Event Triggered part mentioned earlier in FlexRay. The dynamic part is usually used to transmit diagnostic information. Each node sends information according to the configured Frame ID. The dynamic partial sending mechanism is quite interesting, based on the concept of Minislots. When there is no information to send, each node counts the time block Minislots and accumulates its own index. There is a one-to-one correspondence between the message ID to be sent and the slot, and if they match, the corresponding node has the right to send the message. When a message is sent, the indexes of all nodes are frozen, and after the message is sent, everyone continues to accumulate the index together. In this way, conflicts are avoided, but the time length of the dynamic part is limited, so if there are many messages in the front, the later messages may not be assigned the slot of the sending time, and the sending can only be given up. This is a bit like the CAN bus, but the mechanism is not exactly the same. The CAN bus determines the priority by comparing the size of the ID. The dynamic part of FlexRay gives the opportunity to send the information with the smaller ID first, and sends them in order. There is a good demonstration animation in EB's "FlexRay: A first glance", you can go and see it. The Minislots of the two channels of FlexRay are aligned, but when information is sent, they are independent of each other, do not interfere with each other and are not aligned. After the last chance time point latest dynamic transmission start, no node is allowed to send new frames.

Source|  Master of Electric Control Technology

Guess you like

Origin blog.csdn.net/yessunday/article/details/130755343