In a CAN network, all nodes share a bus for data transmission and reception. When faced with an unknown multi-node CAN bus network, how can we accurately analyze the communication protocol between nodes? 1. CAN bus communication mode Similar to 485, CAN-Bus also communicates in a bus mode, and all CAN nodes are connected to a pair of differential lines. However, there is no master-slave concept in the nodes of the CAN bus. When a node has data to upload, it can send it autonomously and instantly, and the advanced arbitration mechanism ensures that the data will not conflict.
Figure 1 CAN bus communication mode 2. CAN bus protocol analysis Compared with the standard seven-layer communication model, the CAN bus can be roughly divided into the physical layer, link layer, and application layer. The node ID number can be obtained by analyzing the link layer. If you want to analyze the link layer of an "unencrypted" CAN bus, you can use a CAN bus interface card (also known as a CAN box). This type of tool can convert CAN communication to USB, PCI and other communication methods, and is generally used with a computer. If you want to do a comprehensive analysis of the CAN bus, you need a professional bus analyzer. CANScope is a comprehensive instrument that integrates CAN node testing and calibration, CAN bus fault diagnosis and resolution. Figure 2 CAN bus packet capture tool and method 3. Application of Multi-channel CAN Card The bus protocol analysis mentioned above is performed under the premise that there are few bus nodes and the node ID is known. When facing a network with unknown protocol, many nodes and unknown node ID, the first thing to do is to extract the messages in each CAN channel and identify each node ID. Figure 3 Data separation and extraction If each node is taken out for testing separately, the original communication rules will inevitably be destroyed. How to figure out an unfamiliar transceiver protocol without destroying the original communication? As the saying goes, if you want to do your work well, you must first sharpen your tools. You need a CAN card that can send, receive and transfer multiple CAN data at the same time. USBCAN-8E-U is such a test tool. Figure 4 USBCAN-8E-U USBCAN-8E-U integrates 8 CAN-bus interfaces, and each channel can perform routing (forwarding) functions. When identifying the node ID, the node can be connected to 8 CAN interfaces at the same time, and then the 8-way CAN communication can be freely forwarded to ensure that the original network communication rules are not damaged. The powerful host computer software displays the CAN messages sent and received by each channel separately by channel, and the data analysis is clear at a glance. Figure 5 Multi-node CAN network analysis |
<<: No wonder your Wi-Fi is so slow if you place your router like this
[[383004]] This article is reprinted from the WeC...
Recently, a netizen asked, how long will it take ...
[51CTO.com original article] Recently, Riverbed l...
DediPath's Black Friday discounts this year a...
At present, countries around the world are accele...
September 1 news, at the main forum of the "...
Before the pandemic brought a shift in business o...
TTCLOUD is a relatively new foreign hosting sales...
Although 6G is not yet a viable technology, it wi...
[51CTO.com original article] On the afternoon of ...
Introduction ForceView ITAM (IT Asset Management)...
[51CTO.com original article] Bitcoin, as a "...
On April 21, according to foreign media reports, ...
DogYun (狗云) has launched a pre-sale activity for ...
Continuous delivery does not mean that every chan...