CAN-BUS Node Configuration Method
This article explains the configuration method of CAN bus nodes, the functional positioning of nodes as transceivers, the design significance of using node IDs instead of addresses, as well as the process of implementing selective data reception through dedicated initialization commands.
How to Configure the CAN-BUS Node
This section will detail how to configure the CAN-BUS Node
CAN-BUS Node (Device)
What is CAN-BUS Node? The CAN-bus is a local area network control protocol. In a local area network there are multiple devices connected. Each device is called "Node". There is a CAN-bus protocol controller on each node (control chip). Refer to CAN-BUS WIKIPEDIA
-
CAN-BUS nodes can be used as a data receiver or data transmitter. So we call the CAN-bus node a "transceiver"
-
There is no concept of "Address" in CAN-BUS protocol, instead each device is distinguished by an "ID". Every device has a special ID in the node.
-
The CAN-BUS node relies on its hardware proof function to implement a selective receipt of Data frame from special ID at initialization time. We can call the following command to configure the special ID: init_Mask(Masker_t Masker_num, INT8U ext, INT32U ulData) and init_Filter(Filter_t Filter_num, INT8U ext, INT32U Data)
-
The data sent by any node in the network can be selectively received by the other nodes. This node can also selectively receive data sent by other ones.
The following is a simple scenario to demonstrate how it works:
There are 5 nodes in the network; A, B, C, D and E. If Node B can only receive data from ID 0x06, when Node A wants to send "Hello world" to Node B, you can call sendMsgBuf(0x06, 0, 12, "hello world") function to implement this process.
Meanwhile, what about the other nodes circumstance?
Assumption:
Node B data frame receiving ID: 0x06
Node C data frame receiving ID: 0x06 and 0x08
Node D data frame receiving ID: 0x07
Node E data frame receiving ID: Anyone
Then,
When Node A send data frame to ID 0x06, the available Node: B, C, E
When Node A send data frame to ID 0x07, the available Node: D, E
When Node A send data frame to ID 0x08, the available Node: C, E
When Node A send data frame to ID 0x12, the available Node: E
Was this article helpful?
