Controller area network bus network access unit and related network, method, and apparatus
A CAN bus network access unit with multiple ports and transceivers standardizes electrical control networks in conveyor lines, reducing time delays and costs, thereby improving conveyor line operations.
Patent Information
- Application Number
- JP2025161440
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2020-03-16
- Filing Date
- 2025-09-29
- Publication Date
- 2026-01-08
AI Technical Summary
Conveyor lines in logistics require standardized electrical control parts to reduce time delays and network wiring and device management costs, with existing technologies like 485 serial port communication and RJ45 Ethernet being inefficient.
Implementing a CAN bus network access unit with multiple ports and transceivers to facilitate communication between controller area networks (CANs), allowing for standardized electrical control networks with reduced time delays and costs.
The solution provides a standardized electrical control network with reduced time delays and lower network wiring and device management costs, enhancing efficiency in conveyor line operations.
Smart Images

Figure 2026002865000001_ABST
Abstract
Description
[Technical Field]
[0001]
[0001] This disclosure claims the benefit of priority to Chinese Patent Application No. 202010182567.0, filed on March 16, 2020, entitled "Controller Area Network Bus Network Access Unit and Related Network, Method, Apparatus," the entire contents of which are incorporated herein by reference.
[0002] The present disclosure relates to the field of automatic control, and more particularly to controller area network (CAN) bus network access units and related networks, related methods, and related apparatus. [Background technology]
[0003]
[0003] Conveyor line products are commonly used in the back-end logistics sorting and shipping of modern logistics companies. A conveyor line is a collection of all conveying devices, such as conveyor belts and conveyors, for carrying out the transportation of goods. In the fields surrounding warehouses, production workshops, and packaging workshops, conveyor chains formed by many belt conveyors, roller conveyors, etc. are installed. These conveyor chains are connected end to end to form a continuous conveyor line. Because a conveyor line not only requires physical devices used for actual transportation, but also electrical control signals for controlling transportation on the conveyor line, the conveyor line further requires control components and a control bus. The control components are distributed across multiple parts of the conveyor line, and the interaction of the electrical control signals is implemented through a unified control bus.
[0004]
[0004] Because conveyance lines contain many devices and the various line connections of the control components and control buses are complex, field engineers must perform extensive debugging of signal point positions and coordination relationships. In addition, there are significant differences in the actual on-site configurations of every store. As a result, the construction process cannot be standardized, and the debugging process is very long. In existing technologies, 485 serial port communication technology or RJ45 Ethernet technology is mainly adopted to standardize the electrical control parts in conveyance lines. The time delay of 485 serial port communication technology is relatively large. The time delay is controlled in RJ45 Ethernet. However, because each device is connected to the same network switch device, the network wiring and device management costs are relatively high. Currently, there is no technology that can standardize the electrical control parts used in conveyance lines and take into account both the time delay and the costs of network wiring and device management. Summary of the Invention [Problem to be solved by the invention]
[0005]
[0005] In light of this, the present disclosure aims to provide a technique for standardizing electrical control parts used within conveying lines in order to reduce time delays and costs of network wiring and device management. [Means for solving the problem]
[0006]
[0006] According to some embodiments of the present disclosure, there is provided a CAN bus network access unit comprising: a first CAN bus, a second CAN bus, a first CAN bus transceiver, a second CAN bus transceiver, a first port connected to the first CAN bus, and a plurality of variable connection ports, at least one of the plurality of variable connection ports being connected to one of the first CAN bus and the second CAN bus or being connected to neither the first CAN bus nor the second CAN bus, wherein the first CAN bus transceiver and the second CAN bus transceiver are connected to the first CAN bus and the second CAN bus, respectively, and are configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, respectively.
[0007] Optionally, the plurality of variable connection ports includes a second port, a third port, and a fourth port.
[0008]
[0008] Optionally, the third port is connected to a second CAN bus, and either the second port or the fourth port is connected to neither the first CAN bus nor the second CAN bus.
[0009]
[0009] Optionally, the CAN bus network access unit is a CAN bus network access unit located only within the CAN, and none of the second port, the third port, and the fourth port are connected to a second CAN bus.
[0010]
[0010] Optionally, the CAN bus network access unit is a CAN bus network access unit that is located not only within the CAN but also within another CAN, and at least one of the second port, the third port, and the fourth port is connected to a second CAN bus.
[0011]
[0011] Optionally, the CAN bus network access unit is a CAN bus network access unit of an electrical control network within a logistics transport line, and the first port and at least one of the plurality of variable connection ports are connected to a control component configured to control logistics transport within the logistics transport line.
[0012]
[0012] Optionally, the CAN bus network access unit is a CAN bus network access unit of an electrical control network in a product production line, and the first port and at least one of the plurality of variable connection ports are connected to a control component configured to control product production in the product production line.
[0013]
[0013] Optionally, the CAN bus network access unit is a CAN bus network access unit for an IOT (Internet of Things), and the first port and at least one of the multiple variable connection ports are connected to an IOT device that accesses the IOT.
[0014]
[0014] According to some embodiments of the present disclosure, there is provided an electrical control network including a first controller area network (CAN) and a second CAN, the first CAN and the second CAN having a common routing CAN bus network access unit, at least one of the first CAN and the second CAN having an internal CAN bus network access unit in addition to the routing CAN bus network access unit, each of the routing CAN bus network access unit and the internal CAN bus network access unit having a first CAN bus, a second CAN bus, a first port, a second port, a third port, and a fourth port, within the internal CAN bus network access unit, the first port is connected to the first CAN bus, and none of the second port, the third port, and the fourth port is connected to the second CAN bus, and within the routing CAN bus network access unit, the first port is connected to the first CAN bus, and at least one of the second port, the third port, and the fourth port is connected to the second CAN bus.
[0015]
[0015] Optionally, the routing CAN bus network access unit or the internal CAN bus network access unit further comprises a first CAN bus transceiver and a second CAN bus transceiver, the first CAN bus transceiver and the second CAN bus transceiver being connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, respectively.
[0016]
[0016] Optionally, the internal CAN bus network access unit of the first CAN includes a message sending CAN bus network access unit and a message receiving CAN bus network access unit, wherein a first CAN bus transceiver of the message sending CAN bus network access unit is configured to broadcast a direct message to another CAN bus network access unit in the first CAN, wherein the direct message includes an identifier of the message receiving CAN bus network access unit, wherein the message receiving CAN bus network access unit is configured, after receiving the direct message, to determine that the identifier of the message receiving CAN bus network access unit included in the direct message matches its own identifier and to store the direct message, wherein another internal CAN bus network access unit other than the message receiving CAN bus network access unit is configured, after receiving the direct message, to determine that the identifier of the message receiving CAN bus network access unit included in the direct message does not match its own identifier and to discard the direct message, and wherein the routing CAN bus network access unit is configured, after receiving the direct message, to determine that the identifier of the message receiving CAN bus network access unit included in the direct message is in the first CAN bus network access unit identifier list and to discard the direct message.
[0017]
[0017] Optionally, the internal CAN bus network access unit of the first CAN includes a message sending CAN bus network access unit, and the internal CAN bus network access unit of the second CAN includes a message receiving CAN bus network access unit, a first CAN bus transceiver of the message sending CAN bus network access unit is configured to broadcast a direct message to another CAN bus network access unit in the first CAN, the direct message including an identifier of the message receiving CAN bus network access unit, and the other internal CAN bus network access unit is configured, after receiving the direct message, to determine that the identifier of the message receiving CAN bus network access unit included in the direct message does not match its own identifier and to discard the direct message, and the routing CAN bus network access unit, after receiving the direct message, to the direct message is configured to determine that the identifier of the message-receiving CAN bus network access unit included in the direct message is not in the first CAN bus network access unit identifier list, and broadcast the direct message to an internal CAN bus network access unit in the second CAN through a second CAN bus transceiver, wherein the message-receiving CAN bus network access unit in the second CAN, after receiving the direct message, determines that the identifier of the message-receiving CAN bus network access unit included in the direct message matches its own identifier, and stores the direct message, and another internal CAN bus network access unit other than the message-receiving CAN bus network access unit in the second CAN, after receiving the direct message, determines that the identifier of the message-receiving CAN bus network access unit included in the direct message does not match its own identifier;It is configured to discard direct messages.
[0018]
[0018] Optionally, the electrical control network is an electrical control network within a logistics transport line, and the first port and at least one of the plurality of variable connection ports are connected to a control component configured to control logistics transport within the logistics transport line.
[0019]
[0019] Optionally, the electrical control network is an electrical control network within a product manufacturing line, and the first port and at least one of the plurality of variable connection ports are connected to a control component configured to control product production within the product manufacturing line.
[0020]
[0020] Optionally, the electrical control network is an Internet of Things (IOT), and at least one of the first port and the plurality of variable connection ports is connected to an IOT device that accesses the IOT.
[0021]
[0021] According to some embodiments of the present disclosure, there is provided a method for direct message processing in an electrical control network, the electrical control network being formed by a plurality of controller area networks (CANs) connected in series, wherein two adjacent CANs of the plurality of serially connected CANs have a common routing CAN bus network access unit, and at least one of the plurality of CANs has an internal CAN bus network access unit in addition to the routing CAN bus network access unit, the method being performed by a current CAN bus network access unit receiving a direct message in the electrical control network, the direct message including an identifier of the message-receiving CAN bus network access unit, the method comprising: determining whether the current CAN bus network access unit is an internal CAN bus network access unit or a routing CAN bus network access unit; if so, determining whether an identifier of the message-receiving CAN bus network access unit contained in the direct message matches an identifier of the current CAN bus network access unit itself; storing the direct message if the identifier of the message-receiving CAN bus network access unit contained in the direct message matches an identifier of the current CAN bus network access unit itself, or discarding the direct message if the identifier of the message-receiving CAN bus network access unit contained in the direct message does not match an identifier of the current CAN bus network access unit itself; if the current CAN bus network access unit is a routing CAN bus network access unit, determining whether an identifier of the message-receiving CAN bus network access unit contained in the direct message is in a CAN bus network access unit identifier list of one CAN upstream from the routing CAN bus network access unit;A method for processing a direct message is provided, comprising: discarding the direct message if an identifier of a message-receiving CAN bus network access unit contained in the direct message is in a CAN bus network access unit identifier list of one CAN upstream from the routing CAN bus network access unit; or broadcasting the direct message from the routing CAN bus network access unit to downstream CAN bus network access units if an identifier of a message-receiving CAN bus network access unit contained in the direct message is not in a CAN bus network access unit identifier list of one CAN upstream from the routing CAN bus network access unit.
[0022]
[0022] According to some embodiments of the present disclosure, there is provided a status notification method for a CAN bus network access unit, the CAN bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit; a first port connected to the first CAN bus, a second port, a third port, and a fourth port; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units; the third port of the straight CAN bus network access unit is connected to the second CAN bus; any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus; and any one of the first and fourth ports is connectable to a first CAN bus or a second CAN bus, and the method includes determining whether the CAN bus network access unit is a straight CAN bus network access unit or a transplanter CAN bus network access unit; if the CAN bus network access unit is a straight CAN bus network access unit, connecting the first port to the first CAN bus and connecting the third port to the second CAN bus in successive first, second, third, and fourth scan periods; if the CAN bus network access unit is a transplanter CAN bus network access unit, connecting the first port to the first CAN bus and connecting the second, third, and fourth ports to the second CAN bus in the first scan period;and a fourth port connected to a first CAN bus and a third port connected to a second CAN bus; during a fourth scanning period, connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus; and transmitting a message by using the first CAN bus transceiver and the second CAN bus transceiver to notify, through the ports connected to the first CAN bus transceiver and the second CAN bus transceiver, an identifier of the CAN bus network access unit, a bus number corresponding to the transceiver, and a port number of the port connected to the bus.
[0023]
[0023] Optionally, before connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during consecutive first, second, third, and fourth scan periods, the method further includes connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during a first silent period before the first scan period, and after connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during consecutive first, second, third, and fourth scan periods, the method further includes connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during a second silent period before the fourth scan period.
[0024]
[0024] Optionally, before connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus in the first scanning period, the method further includes connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus in a first silent period before the first scanning period, and after connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus in the fourth scanning period, the method further includes connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus in a second silent period after the fourth scanning period.
[0025]
[0025] Optionally, before determining whether the CAN bus network access unit is a straight CAN bus network access unit or a transplanter CAN bus network access unit, the method further includes receiving a CAN control message of a scan start subtype sent by the detection start CAN bus network access unit.
[0026]
[0026] Optionally, a CAN control message of the scan start subtype is broadcast by the detection start CAN bus network access unit in the CAN in which the detection start CAN bus network access unit is located, and broadcast to a CAN bus network access unit in another CAN by a routing CAN bus network access unit between the CAN and another CAN.
[0027]
[0027] Optionally, for a linear CAN bus network access unit, transmitting a message by using a first CAN bus transceiver and a second CAN bus transceiver, and informing, through ports connected to the first CAN bus transceiver and the second CAN bus transceiver, an identifier of the CAN bus network access unit, a bus number corresponding to the transceiver, and a port number of the port connected to the bus; for a linear CAN bus network access unit, transmitting a message by using a first CAN bus transceiver, and informing, through a first port connected to the first CAN bus transceiver, an identifier of the CAN bus network access unit, bus number 1, and port number 1; and for a linear CAN bus network access unit, transmitting a message by using a second CAN bus transceiver, and informing, through a third port connected to the second CAN bus transceiver, and for the transplanter CAN bus network access unit, transmitting a message by using a first CAN bus transceiver through a port connected to the first CAN bus transceiver, an identifier of the CAN bus network access unit, bus number 1, and a particular flag bit, and responding in response to receiving the port query request with the port number to which the first CAN bus is connected; and transmitting a message by using a second CAN bus transceiver through a port connected to the second CAN bus transceiver, an identifier of the CAN bus network access unit, bus number 2, and a particular flag bit, and responding in response to receiving the port query request with the port number of the port to which the first CAN bus is connected.
[0028]
[0028] According to some embodiments of the present disclosure, there is provided a connection status detection method for a CAN bus network access unit, the CAN bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit; a first port connected to the first CAN bus, a second port, a third port, and a fourth port; the CAN bus network access units are classified into a straight CAN bus network access unit and a transplanter CAN bus network access unit; the third port of the straight CAN bus network access unit is connected to the second CAN bus; and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus, and the method includes determining, for a detected port of the CAN bus network access unit, that the detected port is connected to the linear CAN bus network access unit if the detected port receives messages informing the identifier of the CAN bus network access unit, bus number 1, and port number 1 during consecutive first, second, third, and fourth scan periods, and recording the identifier of the CAN bus network access unit, wherein the detected port is connected to the first port of the linear CAN bus network access unit and the first port is a logical inlet.determining that the detected port is connected to a straight CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives a message notifying an identifier of the CAN bus network access unit, a bus number 2, and a port number 3 during the first scan period, the second scan period, the third scan period, and the fourth scan period, which are consecutive; and determining that the detected port is connected to a third port of the straight CAN bus network access unit, and recording the identifier of the CAN bus network access unit if the detected port receives a message notifying an identifier of the CAN bus network access unit, a bus number 2, and a port number 3 during the first scan period, the second scan period, the third scan period, and the fourth scan period, which are consecutive;and if the detected port receives a message in a first scanning period notifying an identifier of the CAN bus network access unit, a bus number 1, and a specific flag bit, determining that the detected port is connected to a transplanter CAN bus network access unit and recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical inlet; and if the detected port receives a message in a second scanning period notifying an identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit, and receives a port number 2 after sending a port query request, recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet; If the port receives a message in a third scanning period notifying an identifier of the CAN bus network access unit, a bus number 1 or 2, and a particular flag bit, and receives a port number 3 after sending a port query request, recording an identifier of the CAN bus network access unit, where the detected port is connected to a third port of the straight CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet; and if the detected port receives a message in a fourth scanning period notifying an identifier of the CAN bus network access unit, a bus number 1 or 2, and a particular flag bit, and receives a port number 4 after sending a port query request, recording an identifier of the CAN bus network access unit, where the detected port is connected to a fourth port of the straight CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet.
[0029]
[0029] Optionally, after the step corresponding to the detected port receiving a message in the fourth scanning period notifying the identifier of the CAN bus network access unit, bus number 1 or 2, and a specific flag bit, and receiving port number 4 after sending a port query request, recording the identifier of the CAN bus network access unit, where the detected port is connected to the fourth port of the straight CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical entrance, the method includes generating, for each detected port of each CAN bus network access unit in the electrical control network, a port connection diagram of the electrical control network according to the recorded identifier of the connected CAN bus network access unit, the port number of the connected CAN bus network access unit, and whether the connected port is a logical entrance or a logical exit.
[0030]
[0030] According to some embodiments of the present disclosure, there is provided a status notification device for a CAN bus network access unit, the CAN bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit; a first port connected to the first CAN bus, a second port, a third port, and a fourth port; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units; the third port of the straight CAN bus network access unit is connected to the second CAN bus; any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus; and a fourth port, any one of which is connectable to a first CAN bus or a second CAN bus, and the status notification device is configured to determine whether the CAN bus network access unit is a straight CAN bus network access unit or a transplanter CAN bus network access unit; a first connection setting module configured, if the CAN bus network access unit is a straight CAN bus network access unit, to connect the first port to the first CAN bus and the third port to the second CAN bus in successive first scanning periods, second scanning periods, third scanning periods, and fourth scanning periods; and, if the CAN bus network access unit is a transplanter CAN bus network access unit, to connect the first port to the first CAN bus and the second, third, and fourth ports to the second CAN bus in the first scanning period, and to connect the first, third, and fourth ports to the first CAN bus in the second scanning period;A status notification device is provided, comprising: a second connection setting module configured to connect the second port to a second CAN bus, and in a third scanning period, connect the first port, the second port, and a fourth port to the first CAN bus and connect the third port to the second CAN bus, and in a fourth scanning period, connect the first port, the second port, and the third port to the first CAN bus and connect the fourth port to the second CAN bus; and a status notification module configured to send a message by using the first CAN bus transceiver and the second CAN bus transceiver, and notify an identifier of a CAN bus network access unit, a bus number corresponding to the transceiver, and a port number of a port connected to the bus, through ports connected to the first CAN bus transceiver and the second CAN bus transceiver.
[0031]
[0031] According to some embodiments of the present disclosure, there is provided a connection status detection device for a CAN bus network access unit, the CAN bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, a first port connected to the first CAN bus, a second port, a third port, and a fourth port;
[0032] The CAN bus network access unit is classified into a straight CAN bus network access unit and a transplanter CAN bus network access unit, the third port of the straight CAN bus network access unit is connected to a second CAN bus, any one of the second port and the fourth port is not connected to either the first CAN bus or the second CAN bus, and any one of the second port, the third port and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus;
[0033] a connection status detection device,
[0034] a first recording module configured to determine, for a detected port of the CAN bus network access unit, that the detected port is connected to the linear CAN bus network access unit if the detected port receives messages notifying an identifier of the CAN bus network access unit, a bus number 1, and a port number 1 during consecutive first, second, third, and fourth scanning periods, and to record the identifier of the CAN bus network access unit, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical entry;
[0035] a second recording module configured to determine that the detected port is connected to the linear CAN bus network access unit and record the identifier of the CAN bus network access unit when the detected port receives messages notifying an identifier of the CAN bus network access unit, a bus number 2, and a port number 3 during consecutive first, second, third, and fourth scanning periods, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and the third port is a logical outlet;
[0036] a third recording module configured to determine that the detected port is connected to the transplanter CAN bus network access unit and record the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, bus number 1, and a specific flag bit during the first scanning period, where the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical inlet;
[0037] a fourth recording module configured to record the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the second scanning period, and receives port number 2 after sending a port query request, wherein the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet;
[0038] a fifth recording module configured to record the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the third scanning period, and receives a port number 3 after sending a port query request, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet;
[0039] and a sixth recording module configured to record the identifier of the CAN bus network access unit if the detected port receives a message notifying an identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during a fourth scanning period, and receives port number 4 after sending a port query request, wherein the detected port is connected to a fourth port of the linear CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet.
[0032]
[0040] According to some embodiments of the present disclosure, a CAN bus network access unit includes: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver coupled to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, a first port coupled to the first CAN bus, a second port, a third port, and a fourth port; a memory; and processing logic.
[0041] The CAN bus network access unit is classified into a straight CAN bus network access unit and a transplanter CAN bus network access unit, the third port of the straight CAN bus network access unit is connected to a second CAN bus, any one of the second port and the fourth port is not connected to either the first CAN bus or the second CAN bus, and any one of the second port, the third port and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus;
[0042] a memory configured to store control instructions;
[0043] Processing logic reads control instructions stored in memory to:
[0044] determining whether the CAN bus network access unit is a linear CAN bus network access unit or a transplanter CAN bus network access unit;
[0045] If the CAN bus network access unit is a linear CAN bus network access unit, connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during consecutive first, second, third, and fourth scanning periods;
[0046] If the CAN bus network access unit is a transplanter CAN bus network access unit, during a first scanning period, connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus; during a second scanning period, connecting the first port, the third port, and the fourth port to the first CAN bus and connecting the second port to the second CAN bus; during a third scanning period, connecting the first port, the second port, and the fourth port to the first CAN bus and connecting the third port to the second CAN bus; and during a fourth scanning period, connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus.
[0047] A CAN bus network access unit is provided that is configured to transmit messages by using a first CAN bus transceiver and a second CAN bus transceiver, and to advertise, through ports connected to the first CAN bus transceiver and the second CAN bus transceiver, an identifier of the CAN bus network access unit, a bus number corresponding to the transceiver, and a port number connected to the bus.
[0033]
[0048] According to some embodiments of the present disclosure, a CAN bus network access unit includes: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver coupled to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, a first port coupled to the first CAN bus, a second port, a third port, and a fourth port; a memory; and processing logic.
[0049] The CAN bus network access unit is classified into a straight CAN bus network access unit and a transplanter CAN bus network access unit, the third port of the straight CAN bus network access unit is connected to a second CAN bus, any one of the second port and the fourth port is not connected to either the first CAN bus or the second CAN bus, and any one of the second port, the third port and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus;
[0050] a memory configured to store control instructions;
[0051] Processing logic reads control instructions stored in memory to:
[0052] For a detected port of the CAN bus network access unit, if the detected port receives messages informing the identifier of the CAN bus network access unit, bus number 1, and port number 1 during the first scanning period, the second scanning period, the third scanning period, and the fourth scanning period, the detected port is determined to be connected to the straight CAN bus network access unit, and record the identifier of the CAN bus network access unit, wherein the detected port is connected to a first port of the straight CAN bus network access unit, and the first port is a logical entry;
[0053] determining that the detected port is connected to the linear CAN bus network access unit and recording the identifier of the CAN bus network access unit when the detected port receives messages notifying the identifier of the CAN bus network access unit, the bus number 2, and the port number 3 during the consecutive first, second, third, and fourth scan periods, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and the third port is a logical outlet;
[0054] If the detected port receives a message in a first scanning period indicating an identifier of the CAN bus network access unit, a bus number 1, and a specific flag bit, determining that the detected port is connected to a transplanter CAN bus network access unit and recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical inlet;
[0055] If the detected port receives a message in the second scanning period notifying an identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit, and receives a port number 2 after sending a port query request, record the identifier of the CAN bus network access unit, where the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet;
[0056] If the detected port receives a message in a third scanning period notifying an identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit, and receives a port number 3 after sending a port query request, record the identifier of the CAN bus network access unit, where the detected port is connected to a third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet;
[0057] A CAN bus network access unit is provided that is configured to record the identifier of the CAN bus network access unit if the detected port receives, during a fourth scanning period, a message notifying the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit, and receives port number 4 after sending a port query request, wherein the detected port is connected to a fourth port of the linear CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet.
[0034]
[0058] According to some embodiments of the present disclosure, there is provided a computer-readable medium storing control instructions configured to be executed by processing logic of a CAN bus network access unit, wherein in addition to the processing logic, the CAN bus network access unit further includes: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver coupled to the first CAN bus and the second CAN bus, respectively, configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit; a first port coupled to the first CAN bus, a second port, a third port, and a fourth port;
[0059] The CAN bus network access unit is classified into a straight CAN bus network access unit and a transplanter CAN bus network access unit, the third port of the straight CAN bus network access unit is connected to a second CAN bus, any one of the second port and the fourth port is not connected to either the first CAN bus or the second CAN bus, and any one of the second port, the third port and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus;
[0060] The control instruction is executed by the processing logic of the CAN bus network access unit to cause the CAN bus network access unit to:
[0061] determining whether the CAN bus network access unit is a linear CAN bus network access unit or a transplanter CAN bus network access unit;
[0062] If the CAN bus network access unit is a linear CAN bus network access unit, connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during consecutive first, second, third, and fourth scanning periods;
[0063] If the CAN bus network access unit is a transplanter CAN bus network access unit, during a first scanning period, connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus; during a second scanning period, connecting the first port, the third port, and the fourth port to the first CAN bus and connecting the second port to the second CAN bus; during a third scanning period, connecting the first port, the second port, and the fourth port to the first CAN bus and connecting the third port to the second CAN bus; and during a fourth scanning period, connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus.
[0064] A computer-readable medium is provided for causing a device to transmit a message using a first CAN bus transceiver and a second CAN bus transceiver, and advertising, through ports connected to the first CAN bus transceiver and the second CAN bus transceiver, an identifier of a CAN bus network access unit, a bus number corresponding to the transceiver, and a port number of a port connected to the bus.
[0035]
[0065] According to some embodiments of the present disclosure, there is provided a computer-readable medium storing control instructions configured to be executed by processing logic of a CAN bus network access unit, wherein in addition to the processing logic, the CAN bus network access unit further includes: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver coupled to the first CAN bus and the second CAN bus, respectively, configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit; a first port coupled to the first CAN bus, a second port, a third port, and a fourth port;
[0066] The CAN bus network access unit is classified into a straight CAN bus network access unit and a transplanter CAN bus network access unit, the third port of the straight CAN bus network access unit is connected to a second CAN bus, any one of the second port and the fourth port is not connected to either the first CAN bus or the second CAN bus, and any one of the second port, the third port and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus;
[0067] The control instruction is executed by the processing logic of the CAN bus network access unit to cause the CAN bus network access unit to:
[0068] For a detected port of the CAN bus network access unit, if the detected port receives messages informing the identifier of the CAN bus network access unit, bus number 1, and port number 1 during the first scanning period, the second scanning period, the third scanning period, and the fourth scanning period, the detected port is determined to be connected to the straight CAN bus network access unit, and record the identifier of the CAN bus network access unit, wherein the detected port is connected to a first port of the straight CAN bus network access unit, and the first port is a logical entry;
[0069] determining that the detected port is connected to the linear CAN bus network access unit and recording the identifier of the CAN bus network access unit when the detected port receives messages notifying the identifier of the CAN bus network access unit, the bus number 2, and the port number 3 during the consecutive first, second, third, and fourth scan periods, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and the third port is a logical outlet;
[0070] If the detected port receives a message in a first scanning period indicating an identifier of the CAN bus network access unit, a bus number 1, and a specific flag bit, determining that the detected port is connected to a transplanter CAN bus network access unit and recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical inlet;
[0071] If the detected port receives a message in the second scanning period notifying an identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit, and receives a port number 2 after sending a port query request, record the identifier of the CAN bus network access unit, where the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet;
[0072] If the detected port receives a message in a third scanning period notifying an identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit, and receives a port number 3 after sending a port query request, record the identifier of the CAN bus network access unit, where the detected port is connected to a third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet;
[0073] A computer-readable medium is provided for performing the following: if a detected port receives a message in a fourth scanning period notifying an identifier of a CAN bus network access unit, a bus number 1 or 2, and a specific flag bit, and receives port number 4 after sending a port query request, recording the identifier of the CAN bus network access unit; the detected port is connected to a fourth port of a straight CAN bus network access unit; if the bus number is 1, the fourth port is a logical outlet; and if the bus number is 2, the fourth port is a logical inlet.
[0036]
[0074] To standardize the electrical control network used within the carrier line of the present disclosure, the carrier line is divided into multiple sections of the carrier line. In each carrier line section, one or more control components within the carrier line section control various operations within the section. The electrical control section is realized in the form of multiple CANs connected in series, with multiple CAN bus network access units connected in series within each CAN, each CAN bus network access unit corresponding to a carrier line section and connected to a control component within the carrier line section. In this manner, the carrier line and the electrical control network within the carrier line are divided into multiple sections similar to a building block, and the CAN bus network access units within each section have a similar structure. That is, each CAN bus network access unit includes a first CAN bus and a second CAN bus, and a first CAN bus transceiver and a second CAN bus transceiver that communicate with another first CAN bus and another second CAN bus within another CAN bus network access unit, respectively. The first CAN bus transceiver and the second CAN bus transceiver enable the CAN bus network access units within the section to communicate with each other to be continuously connected to form a CAN. The CAN bus network access unit includes a first port and a plurality of variable connection ports, the first port being connected to a first CAN bus, and at least one of the plurality of variable connection ports being connected to one of the first CAN bus and the second CAN bus. Therefore, when the at least one variable connection port is connected to the second CAN bus, a continuous connection to an adjacent CAN is achieved. Through this CAN bus network access unit structure with dual CAN buses, communication interconnections between CAN bus network access units and interconnections between adjacent CANs are achieved, thereby allowing the entire electrical control network to be constructed like a building block and standardizing the electrical control parts used in the conveying line. Because this standardization method uses a distributed control structure, centralized polling is not required, thereby ensuring real-time implementation.This technology does not use network switches, reducing the costs of network cabling and device management.
[0037]
[0075] Embodiments and various aspects of the present disclosure are illustrated in the following detailed description and the accompanying drawings, in which the various features illustrated are not drawn to scale. [Brief explanation of the drawings]
[0038] [Figure 1]
[0076] FIG. 1 is a schematic diagram illustrating a conveying line and collation electrical control network according to some embodiments of the present disclosure. [Figure 2A]
[0077] FIG. 2 is a physical structural diagram of a CAN bus network access unit according to some embodiments of the present disclosure. [Figure 2B]
[0078] FIG. 2 is a logical structural diagram of a CAN bus network access unit according to some embodiments of the present disclosure. [Figure 3A]
[0079] FIG. 2 illustrates a connection relationship between a linear CAN bus network access unit and surrounding CAN bus network access units according to some embodiments of the present disclosure. [Figure 3B]
[0080] FIG. 2 illustrates a connection relationship between a transplanter CAN bus network access unit and surrounding CAN bus network access units, according to some embodiments of the present disclosure. [Figure 4A]
[0081] FIG. 2 is a schematic diagram illustrating a message-sending CAN bus network access unit and a message-receiving CAN bus network access unit within the same CAN, according to some embodiments of the present disclosure. [Figure 4B]
[0082] 1 is a schematic diagram illustrating a message-sending CAN bus network access unit and a message-receiving CAN bus network access unit in different CANs, according to some embodiments of the present disclosure. [Figure 5]
[0083] 1 is a flowchart of a method for processing direct messages in an electrical control network, according to some embodiments of the present disclosure. [Figure 6]
[0084] 1 is a flowchart of a status notification method for a CAN bus network access unit according to some embodiments of the present disclosure. [Figure 7]
[0085] 1 is a flowchart of a connection status detection method for a CAN bus network, according to some embodiments of the present disclosure. [Figure 8]
[0086] 1 is a block diagram illustrating a status notification device for a CAN bus network access unit, according to some embodiments of the present disclosure. [Figure 9]
[0087] 1 is a block diagram illustrating a connection status detection apparatus for a CAN bus network access unit according to some embodiments of the present disclosure. [Figure 10]
[0088] 1 is a specific structural diagram of a CAN bus network access unit according to some embodiments of the present disclosure. DETAILED DESCRIPTION OF THE INVENTION
[0039]
[0089] The following describes the present disclosure based on embodiments, but the present disclosure is not limited to these embodiments. The following description refers to the accompanying drawings, in which the same reference numerals in different drawings represent the same or similar elements unless otherwise stated. The implementations described in the following description of exemplary embodiments do not represent all implementations consistent with the present invention. Instead, they are merely examples of devices and methods consistent with aspects related to the present invention as set forth in the appended claims. Certain aspects of the present disclosure are described in detail below. Those skilled in the art will also be able to fully understand the present disclosure without these detailed descriptions. Well-known methods, procedures, and processes will not be described in detail to avoid obscuring the essence of the present disclosure.
[0040]
[0090] Conveyor line products are commonly used in modern logistics companies' back-end logistics sorting and shipping. A conveyor line is a system formed by connecting various belt conveyors, roller conveyors, etc. These belt conveyors, roller conveyors, etc. are deployed end-to-end in sites surrounding warehouses, production work areas, and packaging work areas. A conveyor line includes a physical part and a control part. The physical part includes physical devices such as belt conveyors and roller conveyors within the conveyor line. To control these physical devices to operate normally, scattered control components for controlling these parts must be distributed along the conveyor line. These control components are connected to each other and communicate with each other through a control bus to form the control part. Because a conveyor line includes many devices and the various line connections of the control components and control bus are complex, field engineers must perform extensive debugging of signal point positions and coordination relationships. In addition, there are significant differences between the actual site configurations of each store. As a result, the construction process cannot be standardized.
[0041]
[0091] In the existing technology, 485 serial port communication technology or RJ45 Ethernet technology is mainly adopted to standardize the electrical control part in the conveying line.
[0042]
[0092] In 485 serial port communication, all communication devices need to be connected in series in the network and interact with each other in a host-polling manner. As the scale of the physical network expands, the host's polling from the first device to the last device takes a lot of time because communication between each device and the host requires time. Therefore, this method has an inevitable drawback: each device can only communicate with the host after polling. As a result, it becomes difficult to implement in real time and it becomes impossible to plan different communication priorities for each device. When the scale expands to a certain extent, the communication time delay becomes completely unacceptable.
[0043]
[0093] When RJ45 Ethernet is used for communication, each device is connected to the same network switch device. In theory, the processing time delay is controlled compared to 485 serial port communication. However, a single network switch device is very expensive, and when there are more than thousands of nodes, the costs of network wiring and device management will increase significantly.
[0044]
[0094] In an embodiment of the present disclosure, a carrier line is divided into multiple sections of the carrier line. In each carrier line section, a control component within the carrier line section controls various operations within the section. The electrical control portion is realized in the form of multiple CANs connected in series. Within each CAN, multiple CAN bus network access units exist. Each CAN bus network access unit corresponds to a carrier line section and is connected to the control component within the carrier line section. In this manner, the carrier line and the electrical control network within the carrier line are divided into multiple sections similar to a building block, and the CAN bus network access units within each section have a similar structure. Each CAN bus network access unit can be communicatively connected to another CAN bus network access unit within its CAN through an internal bus transceiver, thereby connecting to form a control network. Furthermore, each CAN bus network access unit includes a structure with dual CAN buses, with a first port connected to the first CAN bus. Depending on whether the variable connection port other than the first port is connected to a first CAN bus or a second CAN bus, the CAN bus network access unit is determined to be a CAN bus network access unit within that CAN bus or a CAN bus network access unit within a CAN that is serially connected to a CAN bus network access unit within another CAN bus. Through this structure, serial communication between multiple CAN buses is implemented. Therefore, regardless of the length of the conveying line, the entire electrical control network can be constructed like a block building, thereby standardizing the electrical control parts used within the conveying line.
[0045]
[0095] In this standardized method, control components within the conveying line area access the bus through standard CAN bus network access units, and the distributed control structure eliminates the need for centralized polling, thereby ensuring real-time implementation and reducing time delays. In a CAN bus network, communication between control components can be instantaneous, with a time delay of less than 2 ms. Serial port communication modes require host polling. The time delay for medium-sized networks is less than 100 ms, while the time delay for large networks (e.g., with 10,000 nodes) can exceed 1,000 ms.
[0046]
[0096] In addition, the cost of the CAN bus transceiver in the above technology is comparable to that of an Ethernet chip, but since no network switch is required, the cost of network wiring and device management is greatly reduced.
[0047]
[0097] A conveying line 100 and its electrical control network according to some embodiments of the present disclosure are described below with reference to FIG.
[0048]
[0098] The conveying line 100 is a collection of all conveying devices, such as conveyor belts and conveyors, used to transport goods. In current logistics storage and distribution, the conveying line 100 can span hundreds or even thousands of meters. Therefore, in conventional conveying devices, it is impractical for a single electrical control component to control the operation of the entire conveying device. The conveying line 100 must be divided into multiple sections, each section being a conveying line region 102. In each conveying line region 102, one or more control components 113 control the operation of the conveying devices within the region 102, and these control components communicate with each other through an electrical control network 119. For example, in a 100-meter conveying line, there is one conveying line region 102 every five meters, and one or more control components 113 are located in each conveying line region 102 to control the operation of the devices within the conveying line region 102.
[0049]
[0099] A CAN bus network access unit 110 is disposed in each conveying line area 102 and serves to connect the control components 113 to an electrical control network 119 in the conveying line area 102. Control signals of the control components 113 passing through the CAN bus network access unit 110 are transferred to control components 113 connected to other CAN bus network access units 110 on the electrical control network 119 to implement intercommunication between the control components 113. These CAN bus network access units 110 connected in series form the electrical control network 119.
[0050]
[0100] The electrical control network 119 in the conveying line 100 of Figure 1 includes a plurality of CANs 114. Each CAN 114 is shown within an oval portion within a bold box in Figure 1. While Figure 1 shows a first CAN 1141, a second CAN 1142, and a third CAN 1143, those skilled in the art will understand that the electrical control network 119 may alternatively include another amount of CANs, such as two, four, or five.
[0051]
[0101] CAN stands for Controller Area Network and is one of the on-site buses that are relatively widely adopted internationally. In a CAN, messages from a node are broadcast to all other nodes within that CAN. Therefore, it is conceivable that each message within a CAN is transmitted to all nodes within the CAN through the same CAN bus. Messages within different CANs are transmitted by using different CAN buses. A transmission line may be several kilometers long and may include thousands or even tens of thousands of CAN bus network access units 110. Because the coverage distance of a CAN cannot cover such a length, a form of multiple CANs 114 connected in series is used in the embodiment of the present disclosure. A routing CAN bus network access unit 112 is connected between two adjacent CANs 114. The routing CAN bus network access unit 112 belongs to both of the two adjacent CANs 114 and is responsible for forwarding (broadcasting) messages from one CAN 114 to the other CAN 114. Because the two CANs 114 transmit messages by using different CAN buses, it is usually required that the routing CAN bus network access unit 112 can connect to both of the two CAN buses at the same time and forward messages on one CAN bus to another CAN bus. The routing CAN bus network access units 112 shown in FIG. 1 include C4, C8, and C11, where CX is the identifier of the Xth CAN bus network access unit in the drawing.
[0052]
[0102] In addition to the routing CAN bus network access unit 112, another type of CAN bus network access unit 110 is an internal CAN bus network access unit 111, i.e., a CAN bus network access unit other than the routing CAN bus network access unit 112, located within a CAN 114. Messages are transmitted within a CAN 114 by using the same CAN bus, so a message on one CAN 114 does not need to be forwarded to another CAN 114. The internal CAN bus network access units 111 shown in FIG. 1 include C1, C2, C3, C5, C6, C7, C9, and C10.
[0053]
[0103] A specific structure of the CAN bus network access unit 110 according to some embodiments of the present disclosure is described in detail below with reference to FIG. 2A . As mentioned above, the CAN bus network access unit 110 refers to a component responsible for connecting the control component 113 to the electrical control network 119, where the control component 113 is within a carrier line region 102 of the carrier line 100. The control component 113 refers to a component that can monitor bus messages within the carrier line region 102 and send bus messages at the appropriate time to communicate with a control component 113 within another carrier line region 102. The electrical control network 119 refers to the electrical control portion of the carrier line 100 and is configured to transmit control signals for the physical carrier devices within the carrier line 100.
[0054]
[0104] As shown in FIG. 2A , the CAN bus network access unit 110 includes a first CAN bus 121, a second CAN bus 122, a first CAN bus transceiver 123, a second CAN bus transceiver 124, and a plurality of variable connection ports 130 including a first port 131, a second port 132, a third port 133, and a fourth port 134. At least one of the plurality of variable connection ports 130 may be connected to any of the first CAN bus 121 and the second CAN bus 122, or alternatively, may not be connected to either of the two buses. As described above, when the CAN bus network access unit 110 is used as a routing CAN bus network access unit 112, different CAN buses need to be connected consecutively. In this case, one of the second port 132, the third port 133, and the fourth port 134 may be connected to the second CAN bus 122. Since the first port 131 is always connected to the first CAN bus 121, multiple different CAN buses that are continuously connected are realized. When the CAN bus network access unit 110 is used as an internal CAN bus network access unit 111, the same CAN bus needs to be continuously connected. In this case, the second port 132, the third port 133, and the fourth port 134 can be connected to the first CAN bus 121. Since the first port 131 is always connected to the first CAN bus 121, the same CAN bus that is continuously connected is realized.
[0055]
[0105] Although a plurality of variable connection ports 130 including a second port 132, a third port 133, and a fourth port 134 is exemplarily described above, the plurality of variable connection ports may actually alternatively include a different amount of ports, for example, may further include a fifth port and a sixth port as needed, or alternatively may include only the second port 132 and the third port 133.
[0056]
[0106] The first CAN bus transceiver 123 is connected to the first CAN bus 121 and configured to communicate with a first CAN bus transceiver 123 of another CAN bus network access unit 110 in the electrical control network 119, thereby establishing a first CAN communication. The second CAN bus transceiver 124 is connected to the second CAN bus 122 and configured to communicate with a second CAN bus transceiver 124 of another CAN bus network access unit 110 in the electrical control network 119. 1 shows multiple CAN bus network access units 110 connected sequentially within each CAN (e.g., CAN bus network access unit C1 is connected to CAN bus network access unit C2, which is connected to CAN bus network access unit C3), it should be noted that in practice, after a CAN bus network access unit 110 transmits a message through its first CAN bus transceiver 123 or second CAN bus transceiver 124, the first CAN bus transceiver 123 or second CAN bus transceiver 124 of another CAN bus network access unit 110 connected to the first bus or the second bus may receive the message. As long as CAN bus network access units 110 are connected to the bus, the transmission of the message can be considered a kind of broadcast. Thus, in FIG. 1, when CAN bus network access unit C2 sends a message, since CAN bus network access units C1, C3, and C4 are all connected to the first CAN bus 121, all of CAN bus network access units C1, C3, and C4 receive the message, i.e., the message is broadcast to CAN bus network access units C1, C3, and C4.
[0057]
[0107] 2A, the first port 131 is connected to the first CAN bus 121. At least one of the multiple variable connection ports 130 is connected to one of the first CAN bus 121 and the second CAN bus 122, or is connected to neither the first CAN bus 121 nor the second CAN bus 122. Therefore, the CAN bus network access unit 110 can be of different types according to different connections, namely, a straight CAN bus network access unit or a transplanter CAN bus network access unit, which will be described in detail later.
[0058]
[0108] 2A can be applied to a logistics scenario and is used as a network access unit of an electrical control network 119 in a conveying line 100. A first port 131 and at least one of a plurality of variable connection ports 130 are connected to a control component 113 configured to control logistics conveyance in the conveying line 100.
[0059]
[0109] Furthermore, the CAN bus network access unit 110 shown in FIG. 2A can be applied to a manufacturing line scenario and is used as a network access unit of an electrical control network within a product manufacturing line. The first port 131 and at least one of the multiple variable connection ports 130 are connected to a control component 113 configured to control product manufacturing within the product manufacturing line. There are links along the product manufacturing line, such as raw material supply, mixing, stirring, baking, drying, and packaging. Within each link, scattered control components are required to control the mechanical operations of these links, and these control components are connected to each other and communicate with each other through a control bus. Thus, the control components and the control bus form an electrical control network within the product manufacturing line. If the manufacturing line is sufficiently long, the manufacturing line needs to be divided into multiple sections of manufacturing line areas. In each manufacturing line area, one or more corresponding control components control various operations within the manufacturing line area. The electrical control network is realized in the form of multiple CANs connected in series. Each CAN includes multiple CAN bus network access units, and each CAN bus network access unit corresponds to a manufacturing line area and is connected to a control component within the manufacturing line area. In this way, the production line and the electrical control network within the production line are divided into multiple sections similar to a block building, and the CAN bus network access units within each section have the same structure.
[0060]
[0110] 2A can be applied to an Internet of Things (IOT) scenario, where the CAN bus network access unit 110 is a network access unit within the IOT. At least one of the first port 131 and the multiple variable connection ports 130 is connected to an IOT device for accessing the IOT, such as a traffic light, a camera, a road horizontal bar control device, or a transportation control node. The entire IOT is divided into multiple IOT domains, and the IOT devices within the IOT domain are connected to a CAN bus through the CAN bus network access unit 110. The CAN bus within the IOT domain and connected to the IOT devices is generally considered to be a CAN.
[0061]
[0111] FIG. 2B is a logical structure diagram of the CAN bus network access unit 110 according to some embodiments of the present disclosure. This logical structure diagram obscures the internal connections within the CAN bus network access unit 110 of FIG. 2A. The internal connections are considered a black box, and the CAN bus network access unit 110 is considered simply as a box containing four logical ports 131-134. The connections between each of the logical ports 131-134 and the first CAN bus 121 or the second CAN bus 122 are hidden. The logical ports 131-134 may be logical inlets or, alternatively, logical outlets. A logical inlet means that a port is a logical inlet if it is connected to the first CAN bus 121 or the second CAN bus 122 and an input signal is provided to the CAN bus. A logical outlet means that a port is a logical outlet if it is connected to the first CAN bus 121 or the second CAN bus 122 and a signal is output from the CAN bus to the port. The first port 131 can only be a logical inlet because it is permanently connected to the first CAN bus 121. The second port 132, the third port 133, and the fourth port 134 may be connected to the first CAN bus 121 or, alternatively, to the second CAN bus 122. When a port is connected to the first CAN bus 121, it forms an outlet for signals from the logical inlet of the first port 131, i.e., a logical outlet. When a port is connected to the second CAN bus 122, it is connected to a new CAN bus and inputs signals to the new CAN bus, and therefore is a logical inlet.
[0062]
[0112] The linear CAN bus network access unit and the transplanter CAN bus network access unit are described in more detail below.
[0063]
[0113] The CAN bus network access unit 110 shown in FIG. 2B is a straight CAN bus network access unit when only the first port 131 and the third port 133 are used and the second port 132 and the fourth port 134 are unused (the second port 132 and the fourth port 134 are shielded by a physical device, for example, by using a cover plate). In this case, the first port 131 is permanently connected to the first CAN bus 121 and is necessarily a logical inlet. The third port 133 can only be connected to the first CAN bus 121 and is used as a logical outlet. When the third port 133 is connected to the second CAN bus 122, signals coming in from the first port 131 cannot go out. Therefore, the third port 133 can only be used as a logical outlet for signals coming in from the first port 131 and is connected to the first CAN bus 121. Either the second port 132 or the fourth port 134 is connected to neither the first CAN bus 121 nor the second CAN bus 122 .
[0064]
[0114] 2B is a transplanter CAN bus network access unit if first port 131, second port 132, third port 133, and fourth port 134 can all be used. In this case, first port 131 is permanently connected to first CAN bus 121 and is always a logical inlet. Second port 132, third port 133, and fourth port 134 may be connected to first CAN bus 121 and used as a logical outlet, or may be connected to second CAN bus 122 and used as a logical inlet.
[0065]
[0115] The routing CAN bus network access unit 112 is necessarily a transplanter CAN bus network access unit because, in order for the routing CAN bus network access unit to forward messages from the first CAN bus 121 to the second CAN bus 122, the second port 132, the third port 133, and the fourth port 134 must be connected to the second CAN bus 122. The internal CAN bus network access unit 111 can be a straight CAN bus network access unit or a transplanter CAN bus network access unit. Each internal CAN bus network access unit 111 in the electrical control network shown in FIG. 1 is a straight CAN bus network access unit. In the CAN bus network access unit interconnection structure of FIG. 3A, only the first port 131 and the third port 133 are used for each of the three internal CAN bus network access units 111 (e.g., CAN bus network access units A, B, and C). Therefore, all three internal CAN bus network access units 111 (e.g., CAN bus network access units A, B, and C) are straight CAN bus network access units. However, in the CAN bus network access unit interconnection structure of FIG. 3B , among the four internal CAN bus network access units 111 (e.g., CAN bus network access units A, B, C, and D), the first port 131, the third port 133, and the fourth port 134 of CAN bus network access unit B are all used, and the fourth port 134 of CAN bus network access unit B is connected to the first port 131 of CAN bus network access unit D. In this case, CAN bus network access unit B is not a routing CAN bus network access unit 112, but can use a transplanter CAN bus network access unit.
[0066]
[0116] Additionally, a linear CAN bus network access unit (e.g., CAN bus network access units A-C shown in FIG. 3A) may be connected to a linear CAN bus network access unit, and a linear CAN bus network access unit (e.g., CAN bus network access units A, C, and D shown in FIG. 3B) may alternatively be connected to a transplanter CAN bus network access unit, while a transplanter CAN bus network access unit (e.g., CAN bus network access unit B shown in FIG. 3B) can only be connected to a linear CAN bus network access unit.
[0067]
[0117] To more typically illustrate how messages are transferred by CAN bus network access units 110 in different CANs, Figure 4 shows an electrical control network that includes only a first CAN 1141 and a second CAN 1142. Because the electrical control network includes only two CANs, it can better illustrate message transfers between CAN bus network access units 110 in different CANs.
[0068]
[0118] As shown in FIG. 4, the first CAN 1141 and the second CAN 1142 share a common routing CAN bus network access unit 112, i.e., C4. In addition to the routing CAN bus network access unit 112, the first CAN 1141 further includes three internal CAN bus network access units 111, i.e., C1 to C3. In addition to the routing CAN bus network access unit 112, the second CAN 1142 further includes three internal CAN bus network access units 111, i.e., C5 to C7. Each of these CAN bus network access units has the structure shown in FIGS. 2A and 2B. Each of the internal CAN bus network access units C1 to C3 can be a straight CAN bus network access unit, i.e., the first port 131 and the third port 133 are connected to the first CAN bus 121, and the remaining ports are unused. Each of the internal CAN bus network access units C1-C3 may alternatively be a transplanter CAN bus network access unit, i.e., the first port 131 is connected to the first CAN bus 121, and the second port 132, the third port 133, and the fourth port 134 may be connected to either the first CAN bus 121 or the second CAN bus 122. However, in practice, the second port 132, the third port 133, and the fourth port 134 are only allowed to connect to the first CAN bus 121. The internal CAN bus network access units C5-C7 have a similar structure. The routing CAN bus network access unit C4 is in the form of a transplanter CAN bus network access unit, i.e., the first port 131 is connected to the first CAN bus 121, and at least one of the second port 132, the third port 133, and the fourth port 134 is connected to the second CAN bus 122.
[0069]
[0119] Transmitting messages within an electrical control network includes two cases: one case is when messages are transmitted between CAN bus network access units 110 of the same CAN, and the other case is when messages are transmitted between CAN bus network access units 110 of multiple different CANs.
[0070]
[0120] For the case where messages are transmitted between CAN bus network access units of the same CAN, as shown in FIG. 4A , the message sending CAN bus network access unit 117 is C1 and the message receiving CAN bus network access unit 118 is C3. The message sending CAN bus network access unit 117 refers to a CAN bus network access unit for sending control messages to the electrical control network and forwarding the control messages to another CAN bus network access unit on the electrical control network. The message receiving CAN bus network access unit 118 refers to a CAN bus network access unit for receiving the control messages being sent by the message sending CAN bus network access unit 117. The message sending CAN bus network access unit 117 and the message receiving CAN bus network access unit 118 are both located in the first CAN 1141.
[0071]
[0121] The message-sending CAN bus network access unit 117 sends a direct message that needs to reach the message-receiving CAN bus network access unit 118. A direct message refers to a message that needs to be sent only to a specific target (e.g., the message-receiving CAN bus network access unit), and the remaining message-receiving CAN bus network access units may discard the message after receiving it. The direct message includes an identifier (e.g., C3) of the message-receiving CAN bus network access unit 118 that the message needs to reach and the message content. During transmission, the message-sending CAN bus network access unit 117 first broadcasts a direct message through its transceiver to all other CAN bus network access units in the first CAN 1141, and the direct message carries the identifier of the message-receiving CAN bus network access unit 118 that the direct message needs to reach. If the CAN bus network access unit 110 that receives the direct message is the internal CAN bus network access unit 111, the CAN bus network access unit determines whether the identifier of the message-receiving CAN bus network access unit included in the message matches its own identifier. If the message-receiving CAN bus network access unit identifier included in the message matches the identifier of the internal CAN bus network access unit, this indicates that the internal CAN bus network access unit is the message-receiving CAN bus network access unit 118 where the direct message should reach, and the internal CAN bus network access unit stores the direct message. If the message-receiving CAN bus network access unit identifier included in the message does not match the identifier of the internal CAN bus network access unit, the internal CAN bus network access unit discards the message.If the CAN bus network access unit 110 receiving the direct message is the routing CAN bus network access unit 112 and it is determined that the identifier of the message-receiving CAN bus network access unit included in the message is in the first CAN bus network access unit identifier list, this indicates that the message has been received by a CAN bus network access unit in the first CAN 1141, and the direct message is discarded.
[0072]
[0122] 4A, the message-sending CAN bus network access unit C1 broadcasts a direct message to the CAN bus network access units C2 and C3 in the first CAN 101. After receiving the direct message, the CAN bus network access unit C2 compares the identifier of the message-receiving CAN bus network access unit 118 (i.e., C3) in the message with its own identifier C2. If the identifier C2 does not match the identifier of the message-receiving CAN bus network access unit 118 (i.e., C3), the CAN bus network access unit C2 discards the message. After receiving the direct message, the CAN bus network access unit C3 compares the identifier of the message-receiving CAN bus network access unit 118 (i.e., C3) in the direct message with its own identifier C3. If the CAN bus network access unit C3 recognizes that it is the message-receiving CAN bus network access unit 118, it saves the message.
[0073]
[0123] For the case where messages are transmitted between CAN bus network access units 110 of different CANs, as shown in Figure 4B, the message-sending CAN bus network access unit 117 is C1 located in the first CAN 1141. The message-sending CAN bus network access unit 118 is C6 located in the second CAN 1142.
[0074]
[0124] The message-sending CAN bus network access unit 117 broadcasts a direct message to another CAN bus network access unit 110 in the first CAN 1141 through the first CAN transceiver 123, and the direct message includes an identifier of the message-receiving CAN bus network access unit 118. After receiving the direct message, the internal CAN bus network access unit 111 receiving the direct message in the first CAN 1141 determines that the identifier of the message-receiving CAN bus network access unit 118 in the message does not match its own identifier and discards the message. After the message is received, the routing CAN bus network access unit 112 between the first CAN 1141 and the second CAN 1142 determines that the identifier of the message-receiving CAN bus network access unit 118 included in the message is not in the first CAN bus network access unit identifier list and broadcasts the direct message to all CAN bus network access units in the second CAN 1142 through the second CAN transceiver 124. A CAN bus network access unit 110 receiving the direct message in the second CAN 1142 determines whether the included identifier of the message-receiving CAN bus network access unit 118 matches its own identifier. If the identifier of the message-receiving CAN bus network access unit included in the message matches the identifier of the CAN bus network access unit 110, this indicates that the internal CAN bus network access unit 110 is the message-receiving CAN bus network access unit 118, and the internal CAN bus network access unit stores the direct message. If the identifier of the message-receiving CAN bus network access unit included in the message does not match the identifier of the internal CAN bus network access unit, the internal CAN bus network access unit discards the message.
[0075]
[0125] 4B, the message-sending CAN bus network access unit C1 broadcasts a direct message to CAN bus network access units C2 and C3 in the first CAN 1141 through the first CAN transceiver 123. CAN bus network access unit C2 compares the identifier C6 of the message-receiving CAN bus network access unit 118 in the direct message with its own identifier C2. If the identifiers do not match, this indicates that CAN bus network access unit C2 is not the message-receiving CAN bus network access unit 118, and CAN bus network access unit C2 discards the message. CAN bus network access unit C3 compares the identifier C6 of the message-receiving CAN bus network access unit 118 in the direct message with its own identifier C3. If the identifiers do not match, CAN bus network access unit C3 discards the message. CAN bus network access unit C4 is the routing CAN bus network access unit 112. In this case, the routing CAN bus network access unit 112 compares the identifier C6 of the message-receiving CAN bus network access unit 118 contained in the message with the first CAN bus network access unit identifier list and finds that the identifier is not in the first CAN bus network access unit identifier list, which means that the message-receiving CAN bus network access unit 118 is not in the first CAN 1141. Therefore, the routing CAN bus network access unit 112 should broadcast the direct message in the second CAN 1142 through the second CAN transceiver 124 to the CAN bus network access units C5 to C7 in the second CAN 1142.CAN bus network access unit C5 determines that the identifier C6 of the message-receiving CAN bus network access unit 118 included in the message does not match its own identifier C5, indicating that CAN bus network access unit C5 itself is not the message-receiving CAN bus network access unit 118, and therefore discards the message. CAN bus network access unit C6 determines that the identifier C6 of the message-receiving CAN bus network access unit 118 included in the message matches its own identifier C6, indicating that CAN bus network access unit C6 itself is the message-receiving CAN bus network access unit 118, and therefore saves the direct message. CAN bus network access unit C7 determines that the identifier C6 of the message-receiving CAN bus network access unit 118 included in the message does not match its own identifier C7, indicating that CAN bus network access unit C7 itself is not the message-receiving CAN bus network access unit 118, and therefore discards the message.
[0076]
[0126] If there are three or more CANs, it is possible that the message-receiving CAN bus network access unit 118 still cannot be found in the second CAN 1142, and therefore the message may be forwarded to another CAN by the routing CAN bus network access unit 112 between the second CAN 1142 and another CAN until the message-receiving CAN bus network access unit 118 is found. For example, in FIG. 1, in addition to the first CAN 1141 and the second CAN 1142, there is also a third CAN 1143. It is assumed that the message-sending CAN bus network access unit is C1 and the message-receiving CAN bus network access unit is C10. In this case, the CAN bus network access unit C8 between the second CAN 1142 and the third CAN 1143 can also receive the message. The routing CAN bus network access unit C8 compares the identifier C10 of the message-receiving CAN bus network access unit 118 included in the message with the second CAN bus network access unit identifier list, and finds that the identifier C10 is not in the second CAN bus network access unit identifier list, which means that the message-receiving CAN bus network access unit C10 is not in the second CAN 1142, and broadcasts a direct message to the CAN bus network access units C9-C11 in the third CAN 1143. The CAN bus network access unit C9 determines that the identifier C10 of the message-receiving CAN bus network access unit 118 included in the message does not match its own identifier C9, which indicates that the CAN bus network access unit C9 itself is not the message-receiving CAN bus network access unit 118, and therefore discards the message. C10 determines that the identifier C10 of the message-receiving CAN bus network access unit 118 included in the message matches its own identifier C10, which indicates that the CAN bus network access unit itself is the message-receiving CAN bus network access unit 118, and therefore stores the direct message.The CAN bus network access unit C11 determines that the identifier C10 of the message-receiving CAN bus network access unit 118 included in the message does not match its own identifier C11, which indicates that the CAN bus network access unit C11 itself is not the message-receiving CAN bus network access unit 118, and therefore discards the message.
[0077]
[0127] 5, a method for processing a direct message in an electrical control network 119 is provided. The method is performed by a current CAN bus network access unit receiving a direct message in the electrical control network. The method includes steps 510 to 530.
[0078]
[0128] In step 510, it is determined whether the current CAN bus network access unit is an internal CAN bus network access unit or a routing CAN bus network access unit.
[0079]
[0129] In step 520, if the current CAN bus network access unit is an internal CAN bus network access unit, it is determined whether the identifier of the message-receiving CAN bus network access unit included in the direct message matches the identifier of the current CAN bus network access unit. If the identifiers match, the current CAN bus network access unit stores the direct message. If the identifiers do not match, the current CAN bus network access unit discards the direct message.
[0080]
[0130] In step 530, if the current CAN bus network access unit is a routing CAN bus network access unit, it is determined whether the identifier of the message-receiving CAN bus network access unit included in the direct message is in the CAN bus network access unit identifier list of the one CAN upstream from the routing CAN bus network access unit. If the identifier of the message-receiving CAN bus network access unit included in the direct message is in the CAN bus network access unit identifier list of the one CAN upstream from the routing CAN bus network access unit, the current CAN bus network access unit discards the direct message. If the identifier of the message-receiving CAN bus network access unit included in the direct message is not in the CAN bus network access unit identifier list of the one CAN upstream from the routing CAN bus network access unit, the current CAN bus network access unit forwards the direct message from the routing CAN bus network access unit to the downstream CAN bus network access unit.
[0081]
[0131] The specific processes of the aforementioned method have in fact been described in detail above with reference to FIGS. 4A and 4B, so they will not be described in detail here.
[0082]
[0132] Through mechanisms for transferring messages between different CAN bus network access units 110 within the same CAN, and between CAN bus network access units 110 within multiple different CANs, expedited transfer of messages in the electrical control network 119 can be implemented. Because transfers are performed in a fully distributed manner among the CAN bus network access units 110, no centralized polling is required, thereby improving message transfer efficiency. Furthermore, because network switches are not required, costs for network cabling and device management are reduced.
[0083]
[0133] On the large-scale conveyance line 100, there are thousands of control components 113 and thousands of CAN bus network access units 110 to perform electronic control of devices on the entire large-scale conveyance line 100. These CAN bus network access units 110 include linear CAN bus network access units and transplanter CAN bus network access units. Furthermore, port connection patterns are diverse, and the port connection patterns for transplanters are particularly flexible. To discover the overall connection structure of the electrical control network 119, the connection conditions of the ports of each CAN bus network access unit 110 must be manually investigated one by one, which requires a large amount of manual effort. Some embodiments of the present disclosure further provide a method for automatically detecting the connection conditions of the ports of each CAN bus network access unit 110 in the electrical control network 119. In this method, multiple sequential scanning periods are set. In each scanning period, a connection relationship between each port in each CAN bus network access unit 110 and the first CAN bus 121 or the second CAN bus 122 is established. Each port transmits a message according to a predetermined rule, and the message indicates the port number and the connection relationship between the port and the first CAN bus 121 or the second CAN bus 122. When a port of another CAN bus network access unit 110 connected to a port receives the message, the other CAN bus network access unit 110 can recognize the connected CAN bus network access unit 110, the connected port number, whether the port is a logical inlet or outlet, and other information, thereby automatically obtaining the connection conditions of each port of the CAN bus network access unit 110. Therefore, manual troubleshooting is not required, and the efficiency of checking the connection conditions of each port of the CAN bus network access unit 110 is increased.
[0084]
[0134] From the above, in order to check the connection condition of each port of the CAN bus network access unit 110, in one aspect, each port of the CAN bus network access unit 110 connects to the first CAN bus 121 or the second CAN bus 122 in multiple sequential scanning periods and transmits a message, i.e., a status notification, according to a predetermined rule. In another aspect, the status notification message is received and then processed. In practice, each port of each CAN bus network access unit 110 not only performs the former but also the latter. The former is performed to allow adjacent CAN bus network access units 110 to find out the status of the current CAN bus network access unit, and the latter is performed to investigate the status of adjacent CAN bus network access units 110. The former and the latter complement each other. A status notification method for a CAN bus network access unit and a status detection method for a CAN bus network access unit will be described below, respectively.
[0085]
[0135] As shown in FIG. 6, a status notification method for a CAN bus network access unit according to some embodiments of the present disclosure includes steps 610 to 640.
[0086]
[0136] In step 610, it is determined whether the CAN bus network access unit is a straight CAN bus network access unit or a transplanter CAN bus network access unit.
[0087]
[0137] In step 620, if the CAN bus network access unit is a linear CAN bus network access unit, the first port is connected to the first CAN bus and the third port is connected to the second CAN bus during consecutive first, second, third, and fourth scan periods.
[0088]
[0138] In step 630, if the CAN bus network access unit is a transplanter CAN bus network access unit, during a first scanning period, the first port is connected to the first CAN bus, and the second port, the third port, and the fourth port are connected to the second CAN bus; during a second scanning period, the first port, the third port, and the fourth port are connected to the first CAN bus and the second port is connected to the second CAN bus; during a third scanning period, the first port, the second port, and the fourth port are connected to the first CAN bus and the third port is connected to the second CAN bus; and during a fourth scanning period, the first port, the second port, and the third port are connected to the first CAN bus and the fourth port is connected to the second CAN bus.
[0089]
[0139] In step 640, a message is sent using the first CAN bus transceiver and the second CAN bus transceiver to communicate an identifier of the CAN bus network access unit, the number of the bus corresponding to the transceiver, and the number of the port connected to the bus through the ports connected to the first CAN bus transceiver and the second CAN bus transceiver.
[0090]
[0140] The aforementioned process is described in further detail below.
[0091]
[0141] Prior to step 610, the method may further include receiving a CAN control message of a Start Scan subtype transmitted by a Start Detection CAN bus network access unit. This is the start step of connection status detection for the CAN bus network access unit. Status notification and status detection for all CAN bus network access units are initiated by the unified message. In some embodiments, the operation of CAN bus network access units 110 across the electrical control network 119 is coordinated to synchronize status notification and status detection (because coordinated operations can only be performed when one of two connected CAN bus network access units 110 performs status notification and the other performs status detection), and in another aspect, a unified time reference is provided for the first, second, third, and fourth scan periods mentioned below.
[0092]
[0142] The detection initiation CAN bus network access unit is a CAN bus network access unit 110 pre-configured in the electrical control network 119, which transmits a CAN control message of the scan initiation subtype throughout the network. After receiving the CAN control message, the CAN bus network access units 110 throughout the network begin to set the first, second, third, and fourth scan periods, which will be described below, based on the timestamps at the time of receiving the CAN control message or within the received CAN control message. The CAN bus network access unit 110 sets the connection status between different ports and the first CAN bus 121 or the second CAN bus 122, and transmits different messages during the first, second, third, and fourth scan periods. Another CAN bus network access unit 110 connected to a port of the CAN bus network access unit 110 receives the message and recognizes the connection status of the adjacent CAN bus network access unit 110 and the port based on the message.
[0093]
[0143] A CAN control message is a message that is pre-specified (e.g., specified through a protocol) and is used to transmit global control commands throughout the electrical control network 119. This global control command is not limited to scan initiation and can also implement other types of control, such as timing control. CAN control messages used for different types of control can be distinguished by using subtypes. In an embodiment of the present disclosure, a CAN control message used to initiate scan for connection status detection by a CAN bus network access unit belongs to the scan initiation subtype, and a CAN control message used for timing control belongs to the timing control subtype. The subtype can be embodied as a field in the CAN control message. After receiving a CAN control message, the CAN bus network access unit 110 checks the field indicating the subtype. If the field indicates the scan initiation subtype, the CAN bus network access unit 110 sets the connection status between multiple different ports and the first CAN bus 121 or the second CAN bus 122 and begins preparing to transmit different messages in the first scan period, the second scan period, the third scan period, and the fourth scan period, which will be described below.
[0094]
[0144] The detection initiating CAN bus network access unit can send a CAN control message of the scan initiation subtype to all CAN bus network access units 110 in the entire network as follows: The detection initiating CAN bus network access unit broadcasts the CAN control message to all other detection initiating CAN bus network access units in the CAN in which the detection initiating CAN bus network access unit is located. After receiving the CAN control message, a routing CAN bus network access unit between the CAN and another CAN recognizes that the CAN control message belongs to the scan initiation subtype and broadcasts the message to all other CAN bus network access units in the other CAN, and performs similar operations until all CAN bus network access units in all CANs in the electrical control network 119 receive the CAN control message.
[0095]
[0145] The electrical control network 119 in FIG. 1 is taken as an example. It is assumed that C2 is a scan-initiating CAN bus network access unit. Being located in the first CAN, C2 broadcasts a CAN control message to the other CAN bus network access units 110 in the first CAN 1141, i.e., C1, C3, and C4. The subtype field of the CAN control message indicates a scan-initiating subtype. After receiving the CAN control message, C4, a routing CAN bus network access unit between the first CAN 1141 and the second CAN 1142, recognizes that the subtype field of the CAN control message indicates a scan-initiating subtype and broadcasts the message to all other CAN bus network access units in the second CAN 1142, i.e., C5 to C8. After receiving the CAN control message, the routing CAN bus network access unit C8 between the second CAN 1142 and the second CAN 1143 recognizes that the subtype field of the CAN control message indicates a scan start subtype, and broadcasts the message to all other CAN bus network access units, i.e., C9 to C11, within the third CAN 1143. In this way, C1 to C11 all obtain the CAN control message, and thus subsequent first, second, third, and fourth scan periods can be set based on the time when the CAN control message is received or the timestamp within the CAN control message to perform subsequent status notification and status detection.
[0096]
[0146] Although the time at which the CAN bus network access unit in the electrical control network 119 receives the CAN control message is slightly different from the synchronization in the above process, the first, second, third, and fourth scan periods are usually about 5 seconds long. Therefore, the difference between the time at which the CAN control message is received is negligible compared to 5 seconds. Therefore, the subsequent first, second, third, and fourth scan periods can be set based on the time at which the CAN control message is received. Additionally, a timestamp may be set in the CAN control message. The timestamp is added when the CAN control message is generated and does not change even if the time at which the CAN bus network access unit receives the CAN control message is different. Therefore, if the subsequent first, second, third, and fourth scan periods are set based on the timestamp, the accuracy of setting the scan periods can be improved, thereby improving the detection effect.
[0097]
[0147] Additionally, a first silent period may be set before the first scan period, and a second silent period may be set after the fourth scan period. The first and second silent periods may be set to lengths substantially the same as the lengths of the first, second, third, and fourth scan periods, i.e., approximately 5 seconds. During the first silent period, the connection status between each port and the first CAN bus 121 or the second CAN bus 122 is the same as that during the first scan period, and the transmitted messages are also the same as those during the first scan period (the connection status and transmitted messages between each port and the first CAN bus 121 or the second CAN bus 122 during the first scan period will be described below). During the second silent period, the connection status between each port and the first CAN bus 121 or the second CAN bus 122 is the same as that during the fourth scanning period, and the transmitted messages are also the same as those during the fourth scanning period (the connection status and transmitted messages between each port and the first CAN bus 121 or the second CAN bus 122 during the fourth scanning period will be described later).
[0098]
[0148] Regarding the role of the first silent period in setting the first silent period, in some embodiments, it provides sufficient time for some CAN bus network access units 110 to prepare and change their status according to the rules for changing the connection status between the port and the CAN bus during the first, second, third, and fourth scan periods, and not to start transmitting messages. In subsequent connection status detection, only messages received during the first, second, third, and fourth scan periods (described in detail in the subsequent connection status detection section) are considered, and the first silent period is not considered. Thus, the first silent period serves a buffering role. In another aspect, the first silent period is set to an offset difference between the times when multiple CAN bus network access units 110 receive CAN control messages of the scan start subtype. In this way, even if there is a time difference, only the length of the first silent period is affected; the first, second, third, and fourth scan periods can still start and end synchronously.
[0099]
[0149] The role of the second silent period is the same as that of the first silent period. The status in the fourth scanning period is maintained in the second silent period, so the second silent period serves as a status buffer. Furthermore, the CAN bus network access unit 110 that could not be detected in the fourth scanning period can still be detected in this buffered status.
[0100]
[0150] In step 610, since each CAN bus network access unit 110 has its own configuration memory that stores its own configuration parameters, it can determine from these configuration parameters whether the CAN bus network access unit is a straight CAN bus network access unit or a transplanter CAN bus network access unit.
[0101]
[0151] In step 620, for the linear CAN bus network access unit, the first port 131 is connected to the first CAN bus 121 and the third port 133 is connected to the second CAN bus 122 during successive first, second, third, and fourth scanning periods.
[0102]
[0152] Additionally, during the first silent period before the first scanning period and during the second silent period after the fourth scanning period, the first port 131 is connected to the first CAN bus 121 and the third port 133 is connected to the second CAN bus 122.
[0103]
[0153] The reason for doing so is that for a linear CAN bus network access unit, only the first port 131 and the third port 133 are active during actual operation, and during normal operation, the first port 131 is connected to the first CAN bus 121, and the third port 133 is connected to the second CAN bus 122. In this way, as long as the connection relationship between the ports and the CAN buses is set according to actual use, whether the first port 131 or the third port 133 is connected to the other party can be clearly indicated to another CAN bus network access unit 110 connected to the port by the port number of the port connected to the bus in the notification message of step 640.
[0104]
[0154] In step 630, for the transplanter CAN bus network access unit, in a first scanning period, the first port 131 is connected to the first CAN bus 121, and the second port, the third port, and the fourth port 132-134 are connected to the second CAN bus 122, and in a second scanning period, the first port 131, the third port 133, and the fourth port 134 are connected to the first CAN bus 121, and the second port During a third scanning period, the first port 131, the second port 132, and the fourth port 134 are connected to the first CAN bus 121, and the third port 133 is connected to the second CAN bus 122; during a fourth scanning period, the first port 131, the second port 132, and the fourth port 134 are connected to the first CAN bus 121, and the fourth port 134 is connected to the second CAN bus 122.
[0105]
[0155] Additionally, in a first silent period before the first scanning period, similar to the first scanning period, the first port 131 is connected to the first CAN bus 121, and the second port, the third port, and the fourth port 132 to 134 are connected to the second CAN bus 122. In a second silent period after the fourth scanning period, similar to the fourth scanning period, the first port, the second port, and the third port 131 to 133 are connected to the first CAN bus 121, and the fourth port 134 is connected to the second CAN bus 122.
[0106]
[0156] The connection of the first port 131 to the first CAN bus 121 and the connection of the second, third, and fourth ports 132-134 to the second CAN bus 122 during the first scanning period means that, for the transplanter CAN bus network access unit, the first port 131 should be connected to the first CAN bus 121 during normal use. The first port 131 is connected to the first CAN bus 121, and the second, third, and fourth ports 132-134 are connected to the second CAN bus 122. In this way, in step 640, if the bus number corresponding to the transceiver in the notification message during the first scanning period is 1, the message was definitely sent by the first port 131, thereby clearly indicating to another CAN bus network access unit 110 connected to the port that the first port 131 is connected to it.
[0107]
[0157] If the fact that the first port 131 is connected to the first CAN bus 121 and the fact that the second port, the third port, and the fourth port 132 to 134 are all connected to the second CAN bus 122 during the first scanning period clearly indicates whether the first port 131 is connected to the first CAN bus 121, then the meaning of connecting the first port 131, the third port 133, and the fourth port 134 to the first CAN bus 121 and connecting the second port 132 to the second CAN bus 122 during the second scanning period clearly indicates whether the second port 132 is connected to the second CAN bus 122. In this case, only the second port 132 is connected to the second CAN bus 122 during the second scanning period. Therefore, if the CAN bus network access unit 110 receives a notification message in the second scanning period (in this case, the notification message indicates that the bus number is 2), it can clearly see that the second port 132 of another CAN bus network access unit 110 is connected to a second CAN bus.
[0108]
[0158] Similarly, in the third scanning period, the fact that the first port 131, the second port 132, and the fourth port 134 are connected to the first CAN bus 121 and the fact that the third port 133 is connected to the second CAN bus 122 clearly indicates whether the third port 133 is connected to the second CAN bus 122. In the fourth scanning period, the fact that the first port, the second port, and the third port 131-133 are connected to the first CAN bus 121 and the fact that the fourth port 134 is connected to the second CAN bus 122 clearly indicates whether the fourth port 134 is connected to the second CAN bus 122.
[0109]
[0159] In step 640, a message is sent using the first CAN bus transceiver and the second CAN bus transceiver, and an identifier of the CAN bus network access unit, a bus number corresponding to the transceiver, and a port number of a port connected to the bus are communicated through the ports connected to the first CAN bus transceiver and the second CAN bus transceiver.
[0110]
[0160] The CAN bus network access unit identifier is a unique flag assigned to a CAN bus network access unit, and can uniquely indicate "who" the CAN bus network access unit is. In this message, this identifier is used to notify another CAN bus network access unit 110 connected to the current CAN bus network access unit 110 of the CAN bus network access unit 110 to which its port is connected.
[0111]
[0161] The bus number corresponding to a transceiver refers to whether the transceiver is connected to the first CAN bus 121 or the second CAN bus 122. For example, the first CAN bus 121 may be represented by 1 and the second CAN bus 122 may be represented by 2.
[0112]
[0162] The port number of a port connected to a bus refers to one of the first port 131, second port 132, third port 133, and fourth port 134 to which the bus is connected. For example, the first port 131 may be represented by 1, the second port 132 may be represented by 2, the third port 133 may be represented by 3, and the fourth port 134 may be represented by 4.
[0113]
[0163] For the linear CAN bus network access unit, in step 620, the first port is connected to the first CAN bus and the third port is connected to the second CAN bus. Thus, a message is sent using the first CAN bus transceiver 123 to communicate the CAN bus network access unit's identifier, bus number 1 (because the first CAN bus 121 is connected to the first CAN bus transceiver 123), and port number 1 (because the first port 131 is connected to the first CAN bus 121), through the first port 131 connected to the first CAN bus transceiver 123. A message is sent using the second CAN bus transceiver 124 to communicate the CAN bus network access unit's identifier, bus number 2 (because the second CAN bus 122 is connected to the second CAN bus transceiver 124), and port number 3 (because the third port 133 is connected to the second CAN bus 122), through the third port 133 connected to the second CAN bus transceiver 124.
[0114]
[0164] For the transplanter CAN bus network access unit, in step 630, the connection relationships between the ports and the first CAN bus 121 or the second CAN bus 122 are all set differently in the first scan period, the second scan period, the third scan period, and the fourth scan period. In this case, it is relatively difficult to notify the port number in the message, so the bus number, i.e., whether the first CAN bus 121 or the second CAN bus 122 corresponds to the CAN bus transceiver, can be notified in the message. Then, the CAN bus network access unit 110 that receives the message sends a port query request to the current CAN bus network access unit 110, and the current CAN bus network access unit 110 responds to this request and indicates the port number of the port connected to the bus. Thus, when first CAN bus transceiver 123 transmits a message, the message includes a CAN bus network access unit identifier, bus number 1, and a particular flag bit, where bus number 1 indicates that first CAN bus transceiver 123 corresponds to first CAN bus 121, and the particular flag bit indicates that a transplanter CAN bus network access unit is transmitting the message (e.g., 0). When second CAN bus transceiver 124 transmits a message, the message includes a CAN bus network access unit identifier, bus number 2, and a particular flag bit, where bus number 2 indicates that second CAN bus transceiver 124 corresponds to second CAN bus 122.
[0115]
[0165] As shown in FIG. 7, a connection status detection method for a CAN bus network access unit according to some embodiments of the present disclosure includes steps 710-760.
[0116]
[0166] In step 710, for a detected port of the CAN bus network access unit, if the detected port receives messages informing the identifier of the CAN bus network access unit, bus number 1, and port number 1 of the CAN bus network access unit in consecutive first scan period, second scan period, third scan period, and fourth scan period, the detected port is determined to be connected to a straight CAN bus network access unit and the identifier of the CAN bus network access unit is recorded. The detected port is connected to a first port of the straight CAN bus network access unit, and the first port is a logical inlet.
[0117]
[0167] In step 720, if the detected port receives messages informing the identifier of the CAN bus network access unit, bus number 2, and port number 3 during consecutive first, second, third, and fourth scan periods, it is determined that the detected port is connected to a straight CAN bus network access unit and the identifier of the CAN bus network access unit is recorded. The detected port is connected to a third port of the straight CAN bus network access unit, and the third port is a logical outlet.
[0118]
[0168] In step 730, if the detected port receives a message in the first scanning period notifying the CAN bus network access unit's identifier, bus number 1, and a specific flag bit, it is determined that the detected port is connected to a transplanter CAN bus network access unit, and the CAN bus network access unit's identifier is recorded. The detected port is connected to a first port of a linear CAN bus network access unit, and the first port is a logical inlet.
[0119]
[0169] In step 740, if the detected port receives a message informing the identifier of the CAN bus network access unit, bus number 1 or 2, and a specific flag bit during the second scanning period, and receives port number 2 after sending a port query request, the identifier of the CAN bus network access unit is recorded. The detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet.
[0120]
[0170] In step 750, if the detected port receives a message informing the identifier of the CAN bus network access unit, bus number 1 or 2, and a specific flag bit during the third scanning period, and receives port number 3 after sending a port query request, the identifier of the CAN bus network access unit is recorded. The detected port is connected to the third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet.
[0121]
[0171] In step 760, if the detected port receives a message in the fourth scanning period notifying the identifier of the CAN bus network access unit, bus number 1 or 2, and a specific flag bit, and receives port number 4 after sending a port query request, the identifier of the CAN bus network access unit is recorded. The detected port is connected to the fourth port of the linear CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet.
[0122]
[0172] In the above-described status notification method of the embodiment of the present disclosure, for a straight CAN bus network access unit, the message notified by the CAN bus network access unit includes an identifier of the CAN bus network access unit, a bus number 1 or 2 corresponding to the transceiver, and a port number 1 or 2 to which the bus is connected, but does not include a specific flag bit (e.g., 0). For a transplanter CAN bus network access unit, the message notified includes an identifier of the CAN bus network access unit, a bus number 1 or 2 corresponding to the transceiver, and a specific flag bit. Therefore, whether the port to be detected is connected to a straight CAN bus network access unit or a transplanter CAN bus network access unit can be determined according to whether the specific flag bit exists in the message.
[0123]
[0173] If the specific flag bit is not present, the detected port is connected to a linear CAN bus network access unit, and steps 710 and 720 can further determine which port of the linear CAN bus network access unit is connected and whether the port is a logical inlet or a logical outlet. Specifically, if a message including a linear CAN bus network access unit identifier, bus number 1, and port number 1 is received, it can be determined that the first port 131 of the linear CAN bus network access unit is connected according to port number 1. Because it is connected to the first CAN bus 121, the first port 131 serves as a logical inlet and is a logical inlet. Because the detected port is connected to a logical inlet of the linear CAN bus network access unit, the detected port itself should be a logical outlet of the current CAN bus network access unit. Specifically, if a message including a linear CAN bus network access unit identifier, bus number 2, and port number 3 is received, it can be determined that the third port 133 of the linear CAN bus network access unit is connected according to port number 3. The third port 133 plays the role of a logical exit because it is connected to the second CAN bus 122. The detected port is connected to the logical exit of the linear CAN bus network access unit, so the detected port itself should be the logical entrance of the current CAN bus network access unit.
[0124]
[0174] The connection status between the port of the linear CAN bus network access unit and the CAN bus is the same during the first scan period, the second scan period, the third scan period, and the fourth scan period. Therefore, the above process can be performed at any time during the first scan period, the second scan period, the third scan period, and the fourth scan period. However, in some embodiments, it may be specified that the above process is performed only during the first scan period, or that the above process is performed during any other scan period.
[0125]
[0175] If the specific flag bit is present, the port to be detected is connected to the transplanter CAN bus network access unit. Steps 730-760 determine which port of the transplanter CAN bus network access unit is connected and whether the port is a logical inlet or a logical outlet by referring to the four scan periods. As described above, during the first scan period, the first port 131 is connected to the first CAN bus 121, and the second, third, and fourth ports 132-134 are connected to the second CAN bus 122. The fact that the first port 131 is connected differently from the other ports primarily indicates whether the first port 131 is connected and whether it serves as a logical inlet or a logical outlet. During the second scan period, the first port 131, the third port 133, and the fourth port 134 are connected to the first CAN bus 121, and the second port 132 is connected to the second CAN bus 122. The connection of the second port 132 being set differently from the other ports primarily indicates whether the second port 132 is connected and whether the second port 132 serves as a logical entry or a logical exit. During the third scan period, the connection of the first port 131, the second port 132, and the fourth port 134 to the first CAN bus 121 and the connection of the third port 133 to the second CAN bus 122 primarily indicates whether the third port 133 is connected and whether the third port 133 serves as a logical entry or a logical exit. During the fourth scanning period, the first, second, and third ports 131-133 being connected to the first CAN bus 121 and the fourth port 134 being connected to the second CAN bus 122 mainly indicate whether the fourth port 134 is connected and whether the fourth port 134 serves as a logical inlet or a logical outlet.Therefore, whether the first port 131, the second port 132, the third port 133, and the fourth port 134 are connected and the logical characteristics of these ports are determined in the first scanning period, the second scanning period, the third scanning period, and the fourth scanning period, respectively.
[0126]
[0176] In step 730, it is primarily determined whether the detected port is connected to the first port 131 of the transplanter CAN bus network access unit. If the detected port receives a message in the first scanning period indicating the CAN bus network access unit's identifier, bus number 1, and a specific flag bit, the first CAN bus 121 is permanently connected to the first port 131, so that the detected port is directly connected to the first port 131 of the linear CAN bus network access unit without sending a query request. Moreover, because the first port 131 is connected to the first CAN bus 121, it serves as a logical inlet and is a logical inlet. Since the detected port is connected to the logical inlet of the linear CAN bus network access unit, the detected port itself should be a logical outlet of the current CAN bus network access unit.
[0127]
[0177] In step 740, it is primarily determined whether the detected port is connected to the second port 132 of the transplanter CAN bus network access unit. If the detected port receives a message in the second scanning period indicating the CAN bus network access unit's identifier, bus number 1 or 2, and a specific flag bit, and receives port number 2 after sending a port query request, it can be determined that the detected port is connected to the second port 132 of the linear CAN bus network access unit. If the bus number is 1, the second port 132 is connected to the first CAN bus 121, which indicates that the second port is a logical exit and the detected port itself should be a logical entrance of the current CAN bus network access unit. If the bus number is 2, it indicates that the second port is a logical entrance and the detected port itself should be a logical exit of the current CAN bus network access unit.
[0128]
[0178] In step 750, it is primarily determined whether the detected port is connected to the third port 133 of the transplanter CAN bus network access unit. If the detected port receives a message informing the CAN bus network access unit of its identifier, bus number 1 or 2, and a specific flag bit during the third scanning period, and receives port number 3 after sending a port query request, it can be determined that the detected port is connected to the third port 133 of the linear CAN bus network access unit. If the bus number is 1, the third port 133 is connected to the first CAN bus 121, which indicates that the third port is a logical exit and the detected port itself should be a logical entrance of the current CAN bus network access unit. If the bus number is 2, it indicates that the third port is a logical entrance and the detected port itself should be a logical exit of the current CAN bus network access unit.
[0129]
[0179] In step 760, it is primarily determined whether the detected port is connected to the fourth port 134 of the transplanter CAN bus network access unit. If the detected port receives a message in the fourth scanning period indicating the CAN bus network access unit's identifier, bus number 1 or 2, and a specific flag bit, and receives port number 4 after sending a port query request, it can be determined that the detected port is connected to the fourth port 134 of the linear CAN bus network access unit. If the bus number is 1, the fourth port 134 is connected to the first CAN bus 121, which indicates that the fourth port is a logical exit and the detected port itself should be a logical entrance of the current CAN bus network access unit. If the bus number is 2, it indicates that the fourth port is a logical entrance and the detected port itself should be a logical exit of the current CAN bus network access unit.
[0130]
[0180] The above describes the process of performing connection status detection for the detected ports of the CAN bus network access unit 110. After connection status detection is performed for each detected port of the CAN bus network access unit 110, the identifier of the CAN bus network access unit 110 connected to each detected port, the port number of the CAN bus network access unit 110 connected, the logical type of the connected port, and the logical characteristics of the detected port can be recorded.
[0131]
[0181] For example, the recording results of the linear CAN bus network access unit C2 are as follows:
[0132] [Table 1]
[0133]
[0182] The recording results of the Transplanter CAN bus network access unit C2 are as follows:
[0134] [Table 2]
[0135]
[0183] As shown in Tables 1 and 2, for each CAN bus network access unit 110 in the electrical control network, the recorded identifier of the CAN bus network access unit 110 connected to each of its target ports, the port number of the connected CAN bus network access unit 110, and whether the connected port is a logical inlet or a logical outlet are recorded, and then a diagram of the port connection relationships between the CAN bus network access units 110 in the electrical control network can be automatically machine-generated.
[0136]
[0184] Through the above solution, in dual CAN network mode, the port connection status between the linear CAN bus network access unit and the transponder CAN bus network access unit can be intelligently detected and completely detected by the device through automatic scanning. This eliminates the need for manual configuration during engineering operation and maintenance, significantly reducing on-site implementation costs (device debugging time and labor costs). Therefore, this solution is simple, convenient, and error-free, boasting industry-leading advantages.
[0137]
[0185] 8 , some embodiments of the present disclosure provide a status notification device 800 for a CAN bus network access unit 110. The CAN bus network access unit 110 includes a first CAN bus 121 and a second CAN bus 122, a first CAN bus transceiver 123 and a second CAN bus transceiver 124 connected to the first CAN bus 121 and the second CAN bus 122, respectively, and configured to communicate with the first CAN bus 121 and the second CAN bus 122 in another CAN bus network access unit 110, a first port 131 connected to the first CAN bus 121, and second, third, and fourth ports 132 to 134. are classified into a straight CAN bus network access unit and a transplanter CAN bus network access unit, the third port 133 of the straight CAN bus network access unit is connected to the second CAN bus 122, and either one of the second port 132 and the fourth port 134 is connected to neither the first CAN bus 121 nor the second CAN bus 122, and either one of the second port 132, the third port 133, and the fourth port 134 of the transplanter CAN bus network access unit is connectable to the first CAN bus 121 or the second CAN bus 122.
[0186] a type determination module 810 configured to determine whether the CAN bus network access unit 110 is a linear CAN bus network access unit or a transplanter CAN bus network access unit;
[0187] a first connection setting module 820 configured to connect the first port 131 to the first CAN bus 121 and the third port 133 to the second CAN bus 122 during successive first, second, third, and fourth scanning periods when the CAN bus network access unit 110 is a linear CAN bus network access unit;
[0188] When the CAN bus network access unit 110 is a transplanter CAN bus network access unit, in a first scanning period, the first port 131 is connected to the first CAN bus 121, and the second port, the third port, and the fourth port 132 to 134 are connected to the second CAN bus 122, and in a second scanning period, the first port 131, the third port 133, and the fourth port 134 are connected to the first CAN bus 121, and the second port 132 is connected to the second a second connection setting module 830 configured to connect the first port 131, the second port 132, and the fourth port 134 to the first CAN bus 121 and the third port 133 to the second CAN bus 122 in a third scanning period, and to connect the first port 131, the second port 132, and the third port 133 to the first CAN bus 121 and the fourth port 134 to the second CAN bus 122 in a fourth scanning period;
[0189] and a status notification module 830 configured to send a message by using the first CAN bus transceiver 123 and the second CAN bus transceiver 124, and notify, through the ports connected to the first CAN bus transceiver 123 and the second CAN bus transceiver 124, an identifier of the CAN bus network access unit 110, a bus number corresponding to the transceiver, and a port number of the port connected to the bus.
[0138]
[0190] The specific implementation of the modules within the status notification device 800 is described in the detailed description of the method flowchart with reference to FIG. 6 and therefore will not be described in detail.
[0139]
[0191] 9 , some embodiments of the present disclosure provide a connection status detection device 900 for a CAN bus network access unit 110. The CAN bus network access unit 110 includes a first CAN bus 121, a second CAN bus 122, a first CAN bus transceiver 123 and a second CAN bus transceiver 124 connected to the first CAN bus 121 and the second CAN bus 122, respectively, and configured to communicate with the first CAN bus 121 and the second CAN bus 122 in another CAN bus network access unit 110, a first port 131 connected to the first CAN bus 121, and second, third, and fourth ports 132-134. The connection status detection device 900 is classified into a straight CAN bus network access unit and a transplanter CAN bus network access unit, the third port 133 of the straight CAN bus network access unit is connected to the second CAN bus 122, and either one of the second port 132 and the fourth port 134 is connected to neither the first CAN bus 121 nor the second CAN bus 122, and either one of the second port, the third port, and the fourth port 132 to 134 of the transplanter CAN bus network access unit is connectable to the first CAN bus 121 or the second CAN bus 122.
[0192] a first recording module 910 configured to, for a detected port of the CAN bus network access unit, determine that the detected port is connected to the straight CAN bus network access unit and record an identifier of the CAN bus network access unit if the detected port receives messages notifying the CAN bus network access unit, bus number 1, and port number 1 in consecutive first, second, third, and fourth scan periods, where the detected port is connected to a first port of the straight CAN bus network access unit, and the first port is a logical entry;
[0193] a second recording module 920 configured to determine that the detected port is connected to the straight CAN bus network access unit and record the identifier of the CAN bus network access unit if the detected port receives messages notifying an identifier of the CAN bus network access unit, a bus number 2, and a port number 3 during the first scanning period, the second scanning period, the third scanning period, and the fourth scanning period, consecutively, wherein the detected port is connected to a third port of the straight CAN bus network access unit, and the third port is a logical outlet;
[0194] a third recording module 930 configured to determine that the detected port is connected to a transplanter CAN bus network access unit and record an identifier of the CAN bus network access unit if the detected port receives a message informing the CAN bus network access unit, bus number 1, and a specific flag bit during a first scanning period, where the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical inlet;
[0195] a fourth recording module 940 configured to record an identifier of the CAN bus network access unit if the detected port receives a message informing the CAN bus network access unit, bus number 1 or 2, and a specific flag bit during the second scanning period, and receives port number 2 after sending a port query request, where the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet;
[0196] a fifth recording module 950 configured to record the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the third scanning period, and receives a port number 3 after sending a port query request, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet;
[0197] and a sixth recording module 960 configured to record the identifier of the CAN bus network access unit if the detected port receives a message notifying the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the fourth scanning period, and receives port number 4 after sending a port query request, wherein the detected port is connected to a fourth port of the straight CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet.
[0140]
[0198] The specific implementation of the modules in the connection status detection device 900 has been described in the detailed description of the method flowchart with reference to FIG. 7, and therefore will not be described in detail.
[0141]
[0199] FIG. 10 is a specific structural diagram of a CAN bus network access unit 110 according to some embodiments of the present disclosure. Compared with FIG. 2B, FIG. 10 further illustrates a control portion of the CAN bus network access unit 110, namely, memory 192 and processing logic 191, configured to implement the status notification method shown in FIG. 6 and the connection status detection method shown in FIG. 7. The processing logic 191 may be a processor or, alternatively, a logic circuit configured to perform processing. The memory 192 is configured to store control instructions. The processing logic 191 is coupled to the memory 192 and configured to read the control instructions stored in the memory 192 to implement the status notification method shown in FIG. 6 and the connection status detection method shown in FIG. 7.
[0142]
[0200] All embodiments in this specification are described in a progressive manner, and the same or similar parts of the present embodiment are referred to in these embodiments, and the description of each embodiment focuses on the differences from other embodiments. In particular, the device embodiment is basically the same as the method described in the method embodiment, and therefore will be briefly described. For related parts, reference will be made to the partial descriptions in other embodiments.
[0143]
[0201] It should be understood that specific embodiments of the present specification have been described above. Other embodiments are within the scope of the claims. In some embodiments, the actions or steps of the claims may be performed in a different order than that of the embodiments and still achieve the expected results. In addition, the processes depicted in the accompanying figures do not necessarily require a particular order of automaticity or order for performing the expected results. In some embodiments, multitasking and parallel processing may be possible or advantageous.
[0144]
[0202] An element described in the singular herein or shown in the accompanying drawings as only one element does not represent that element being limited to one. Additionally, modules or elements described or shown herein as being separately may be combined into a single module or element, and modules or elements described or shown herein as being a single module or element may be divided into multiple modules or elements.
[0145]
[0203] It should also be understood that the terms and modes of expression used herein are merely for the purpose of explanation, and that one or more embodiments of the present specification should not be limited to these terms and expressions. The use of these terms and expressions is not intended to exclude any equivalent features of the illustrations and descriptions (or portions thereof), and it should also be understood that various modifications that may exist are to be included within the scope of the claims. Other modifications, variations, and substitutions may also exist. The claims should therefore be considered to cover all such equivalents.
Claims
1. 1. A controller area network (CAN) bus network access unit, comprising: a first CAN bus; and a second CAN bus; and a first CAN bus transceiver; a second CAN bus transceiver; a first port connected to the first CAN bus; a plurality of variable connection ports, at least one of which is connected to one of the first CAN bus and the second CAN bus, or is connected to neither the first CAN bus nor the second CAN bus; Equipped with a CAN bus network access unit, wherein the first CAN bus transceiver and the second CAN bus transceiver are connected to the first CAN bus and the second CAN bus, respectively, and are configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, respectively.
2. The CAN bus network access unit of claim 1 , wherein the plurality of variable connection ports includes a second port, a third port, and a fourth port.
3. 3. The CAN bus network access unit of claim 2, wherein the third port is connected to the second CAN bus, and either the second port or the fourth port is connected to neither the first CAN bus nor the second CAN bus.
4. 3. The CAN bus network access unit of claim 2, wherein the CAN bus network access unit is a CAN bus network access unit disposed solely within the CAN, and none of the second port, the third port, and the fourth port is connected to the second CAN bus.
5. 3. The CAN bus network access unit of claim 2, wherein the CAN bus network access unit is a CAN bus network access unit that is disposed not only in the CAN but also in another CAN, and at least one of the second port, the third port, and the fourth port is connected to the second CAN bus.
6. 2. The CAN bus network access unit of claim 1, wherein the CAN bus network access unit is a CAN bus network access unit of an electrical control network in a logistics transport line, and the first port and at least one of the plurality of variable connection ports are connected to a control component configured to control logistics transport in the logistics transport line.
7. 2. The CAN bus network access unit of claim 1, wherein the CAN bus network access unit is a CAN bus network access unit of an electrical control network in a product manufacturing line, and the first port and at least one of the plurality of variable connection ports are connected to a control component configured to control product production in the product manufacturing line.
8. 2. The CAN bus network access unit of claim 1, wherein the CAN bus network access unit is an Internet of Things (IOT) CAN bus network access unit, and the first port and at least one of the plurality of variable connection ports are connected to an IOT device that accesses the IOT.
9. an electrical control network including a first controller area network (CAN) and a second CAN, the first CAN and the second CAN having a common routing CAN bus network access unit, and at least one of the first CAN and the second CAN further having an internal CAN bus network access unit in addition to the routing CAN bus network access unit; each of the routing CAN bus network access unit and the internal CAN bus network access unit comprises a first CAN bus, a second CAN bus, a first port, a second port, a third port, and a fourth port; within the internal CAN bus network access unit, the first port is connected to the first CAN bus, and none of the second port, the third port, and the fourth port is connected to the second CAN bus; and wherein, within the routing CAN bus network access unit, the first port is connected to the first CAN bus, and at least one of the second port, the third port, and the fourth port is connected to the second CAN bus.
10. 10. The electrical control network of claim 9, wherein the routing CAN bus network access unit or the internal CAN bus network access unit further comprises a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, respectively.
11. the internal CAN bus network access unit of the first CAN includes a message sending CAN bus network access unit and a message receiving CAN bus network access unit; the first CAN bus transceiver of the message sending CAN bus network access unit is configured to broadcast a direct message to another CAN bus network access unit in the first CAN, the direct message including an identifier of the message receiving CAN bus network access unit; the message receiving CAN bus network access unit is configured, after receiving the direct message, to determine that the identifier of the included message receiving CAN bus network access unit matches its own identifier, and to store the direct message; another internal CAN bus network access unit other than the message receiving CAN bus network access unit is configured to, after receiving the direct message, determine that the identifier of the message receiving CAN bus network access unit included in the direct message does not match its own identifier, and discard the direct message; 11. The electrical control network of claim 10, wherein the routing CAN bus network access unit is configured, after receiving the direct message, to determine that the identifier of the message-receiving CAN bus network access unit included in the direct message is in a first CAN bus network access unit identifier list and to discard the direct message.
12. the internal CAN bus network access unit of the first CAN includes a message sending CAN bus network access unit, and the internal CAN bus network access unit of the second CAN includes a message receiving CAN bus network access unit; the first CAN bus transceiver of the message sending CAN bus network access unit is configured to broadcast a direct message to another CAN bus network access unit in the first CAN, the direct message including an identifier of the message receiving CAN bus network access unit; another internal CAN bus network access unit is configured, after receiving the direct message, to determine that the identifier of the message-receiving CAN bus network access unit included in the direct message does not match its own identifier, and to discard the direct message; the routing CAN bus network access unit is configured, after receiving the direct message, to determine that the identifier of the message receiving CAN bus network access unit included in the direct message is not in a first CAN bus network access unit identifier list, and to broadcast the direct message to the internal CAN bus network access units in the second CAN bus via the second CAN bus transceiver; 11. The electrical control network of claim 10, wherein the message receiving CAN bus network access unit in the second CAN is configured, after receiving the direct message, to determine that the identifier of the message receiving CAN bus network access unit included in the direct message matches its own identifier and to store the direct message; and wherein another internal CAN bus network access unit other than the message receiving CAN bus network access unit in the second CAN is configured, after receiving the direct message, to determine that the identifier of the message receiving CAN bus network access unit included in the direct message does not match its own identifier and to discard the direct message.
13. 10. The electrical control network of claim 9, wherein the electrical control network is an electrical control network within a logistics transport line, and the first port and at least one of the plurality of variable connection ports are connected to a control component configured to control logistics transport within the logistics transport line.
14. 10. The electrical control network of claim 9, wherein the electrical control network is an electrical control network in a product manufacturing line, and the first port and at least one of the plurality of variable connection ports are connected to a control component configured to control product production in the product manufacturing line.
15. 10. The electrical control network of claim 9, wherein the electrical control network is an Internet of Things (IOT), and the first port and at least one of the plurality of variable connection ports are connected to an IOT device that accesses the IOT.
16. 1. A method for processing a direct message in an electrical control network, the electrical control network being formed by a plurality of controller area networks (CANs) connected in series, wherein two adjacent CANs of the plurality of CANs have a common routing CAN bus network access unit, and at least one of the plurality of CANs further has an internal CAN bus network access unit in addition to the routing CAN bus network access unit, the method being implemented by a current CAN bus network access unit receiving a direct message in the electrical control network, the direct message including an identifier of a message-receiving CAN bus network access unit, the method comprising: determining whether the current CAN bus network access unit is the internal CAN bus network access unit or the routing CAN bus network access unit; if the current CAN bus network access unit is the internal CAN bus network access unit, determining whether the identifier of the message receiving CAN bus network access unit included in the direct message matches an identifier of the current CAN bus network access unit itself; storing the direct message if the identifier of the message-receiving CAN bus network access unit contained in the direct message matches the identifier of the current CAN bus network access unit itself; or discarding the direct message if the identifier of the message-receiving CAN bus network access unit contained in the direct message does not match the identifier of the current CAN bus network access unit itself; if the current CAN bus network access unit is the routing CAN bus network access unit, determining whether the identifier of the message receiving CAN bus network access unit included in the direct message is in a CAN bus network access unit identifier list of one CAN upstream from the routing CAN bus network access unit; discarding the direct message if the identifier of the message-receiving CAN bus network access unit contained in the direct message is in the CAN bus network access unit identifier list of one CAN upstream from the routing CAN bus network access unit; or broadcasting the direct message from the routing CAN bus network access unit to downstream CAN bus network access units if the identifier of the message receiving CAN bus network access unit contained in the direct message is not in the CAN bus network access unit identifier list of one CAN upstream from the routing CAN bus network access unit; A method for processing a direct message, comprising:
17. 1. A status notification method for a Controller Area Network (CAN) bus network access unit, the CAN bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, and a first port, a second port, a third port, and a fourth port connected to the first CAN bus; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units, the third port of the straight CAN bus network access unit is connected to the second CAN bus, any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus, and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus; The method comprises: determining whether the CAN bus network access unit is the linear CAN bus network access unit or the transplanter CAN bus network access unit; if the CAN bus network access unit is the linear CAN bus network access unit, connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during consecutive first, second, third, and fourth scan periods; or When the CAN bus network access unit is the transplanter CAN bus network access unit, during the first scanning period, connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus; during the second scanning period, connecting the first port, the third port, and the fourth port to the first CAN bus and connecting the second port to the second CAN bus; during the third scanning period, connecting the first port, the second port, and the fourth port to the first CAN bus and connecting the third port to the second CAN bus; during the fourth scanning period, connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus; transmitting a message by using the first CAN bus transceiver and the second CAN bus transceiver, and advertising, through ports connected to the first CAN bus transceiver and the second CAN bus transceiver, an identifier of the CAN bus network access unit, a bus number corresponding to the transceiver, and a port number of a port connected to the bus; A status notification method, including:
18. before connecting the first port to the first CAN bus and the third port to the second CAN bus during the consecutive first scan period, the second scan period, the third scan period, and the fourth scan period, the method further includes connecting the first port to the first CAN bus and the third port to the second CAN bus during a first silent period before the first scan period; 18. The method of claim 17, after connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during consecutive first, second, third, and fourth scan periods, the method further comprising connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during a second silent period before the fourth scan period.
19. prior to connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus during the first scanning period, the method further includes connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus during a first silent period before the first scanning period; 18. The method of claim 17, wherein after connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus during the fourth scan period, the method further comprises connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus during a second silent period after the fourth scan period.
20. Prior to determining whether the CAN bus network access unit is the linear CAN bus network access unit or the transplanter CAN bus network access unit, the method further comprises:
20. The method of claim 17, further comprising receiving a CAN control message of a Start Scan subtype transmitted by a Start Detection CAN bus network access unit.
21. 21. The method of claim 20, wherein the CAN control message of the scan start subtype is broadcast by a detection initiating CAN bus network access unit in a CAN in which the detection initiating CAN bus network access unit is located, and is broadcast to a CAN bus network access unit in the other CAN by a routing CAN bus network access unit between the CAN and another CAN.
22. transmitting a message by using the first CAN bus transceiver and the second CAN bus transceiver, and advertising the identifier of the CAN bus network access unit, the bus number corresponding to the transceiver, and the port number of the port connected to the bus through ports connected to the first CAN bus transceiver and the second CAN bus transceiver; For the linear CAN bus network access unit: transmitting a message by using the first CAN bus transceiver to announce the identifier of the CAN bus network access unit, bus number 1, and port number 1 through the first port connected to the first CAN bus transceiver; transmitting a message by using the second CAN bus transceiver to announce the identifier, bus number 2, and port number 3 of the CAN bus network access unit through the third port connected to the second CAN bus transceiver; Regarding the transplanter CAN bus network access unit, transmitting a message by using the first CAN bus transceiver, through a port connected to the first CAN bus transceiver, advertising the identifier of the CAN bus network access unit, bus number 1, and certain flag bits, and responding with a port number of the port connected to the first CAN bus in response to receiving a port query request; transmitting a message by using the second CAN bus transceiver, through a port connected to the second CAN bus transceiver, advertising the identifier of the CAN bus network access unit, bus number 2, and certain flag bits, and responding with a port number of the port connected to the first CAN bus in response to receiving a port query request; 18. The method of claim 17, comprising:
23. 1. A connection status detection method for a Controller Area Network (CAN) bus network access unit, the CAN bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, and a first port, a second port, a third port, and a fourth port connected to the first CAN bus; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units, the third port of the straight CAN bus network access unit is connected to the second CAN bus, any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus, and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus; The method comprises: for a detected port of the CAN bus network access unit, determining that the detected port is connected to a linear CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives messages notifying an identifier of the CAN bus network access unit, a bus number 1, and a port number 1 during consecutive first, second, third, and fourth scan periods, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical entry; determining that the detected port is connected to a linear CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives a message notifying the identifier, bus number 2, and port number 3 of the CAN bus network access unit during the first scanning period, the second scanning period, the third scanning period, and the fourth scanning period, which are consecutive; determining that the detected port is connected to a transplanter CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, bus number 1, and a specific flag bit during the first scanning period, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical inlet; recording the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the second scanning period, and receives a port number 2 after sending a port query request, wherein the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet; and recording the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the third scanning period, and receives a port number 3 after sending a port query request, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet; If the detected port receives a message notifying the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the fourth scanning period, and receives a port number 4 after sending a port query request, recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a fourth port of the linear CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet. A connection status detection method, including:
24. If the detected port receives a message informing the identifier of the CAN bus network access unit, a bus number 1 or 2, and the specific flag bit during the fourth scanning period, and receives port number 4 after sending a port query request, the detected port is connected to a fourth port of the linear CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet, the method further comprises:
24. The method of claim 23, comprising generating a port connection diagram of the electrical control network according to, for each detected port of each CAN bus network access unit in the electrical control network, a recorded identifier of the connected CAN bus network access unit, a port number of the connected CAN bus network access unit, and whether the connected port is a logical inlet or a logical outlet.
25. 1. A status notification device for a Controller Area Network (CAN) bus network access unit, the CAN bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, respectively; and a first port connected to the first CAN bus, a second port, a third port, and a fourth port; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units, the third port of the straight CAN bus network access unit is connected to the second CAN bus, any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus, and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus; The status notification device a type determination module configured to determine whether the CAN bus network access unit is the linear CAN bus network access unit or the transplanter CAN bus network access unit; a first connection setting module configured to connect the first port to the first CAN bus and connect the third port to the second CAN bus during consecutive first, second, third, and fourth scanning periods when the CAN bus network access unit is the linear CAN bus network access unit; a second connection setting module configured to, when the CAN bus network access unit is the transplanter CAN bus network access unit, connect the first port to the first CAN bus and connect the second port, the third port, and the fourth port to the second CAN bus during the first scanning period; connect the first port, the third port, and the fourth port to the first CAN bus and connect the second port to the second CAN bus during the second scanning period; connect the first port, the second port, and the fourth port to the first CAN bus and connect the third port to the second CAN bus during the third scanning period; and connect the first port, the second port, and the third port to the first CAN bus and connect the fourth port to the second CAN bus during the fourth scanning period; a status notification module configured to send a message by using the first CAN bus transceiver and the second CAN bus transceiver to notify, through ports connected to the first CAN bus transceiver and the second CAN bus transceiver, an identifier of the CAN bus network access unit, a bus number corresponding to the transceiver, and a port number of the port connected to the bus; A status notification device comprising:
26. 1. A connection status detection device for a Controller Area Network (CAN) bus network access unit, the CAN bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, and a first port, a second port, a third port, and a fourth port connected to the first CAN bus; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units, the third port of the straight CAN bus network access unit is connected to the second CAN bus, any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus, and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus; The connection status detection device a first recording module configured to determine, for a detected port of the CAN bus network access unit, that the detected port is connected to a linear CAN bus network access unit if the detected port receives messages notifying an identifier of the CAN bus network access unit, a bus number 1, and a port number 1 during consecutive first, second, third, and fourth scanning periods, and to record the identifier of the CAN bus network access unit, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical entry; a second recording module configured to determine that the detected port is connected to a linear CAN bus network access unit and record the identifier of the CAN bus network access unit if the detected port receives messages notifying the identifier, bus number 2, and port number 3 of the CAN bus network access unit during the first scanning period, the second scanning period, the third scanning period, and the fourth scanning period, which are consecutive, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and the third port is a logical outlet; a third recording module configured to determine that the detected port is connected to a transplanter CAN bus network access unit and record the identifier of the CAN bus network access unit if the detected port receives a message notifying the identifier of the CAN bus network access unit, the bus number 1, and a specific flag bit during the first scanning period, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical entry; a fourth recording module configured to record the identifier of the CAN bus network access unit if the detected port receives a message notifying the identifier of the CAN bus network access unit, the bus number 1 or 2, and a specific flag bit during the second scanning period, and receives port number 2 after sending a port query request, wherein the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet; and a fifth recording module configured to record the identifier of the CAN bus network access unit if the detected port receives a message notifying the identifier of the CAN bus network access unit, the bus number 1 or 2, and a specific flag bit during the third scanning period, and receives a port number 3 after sending a port query request, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet; and a sixth recording module configured to record the identifier of the CAN bus network access unit if the detected port receives a message notifying the identifier of the CAN bus network access unit, the bus number 1 or 2, and a specific flag bit during the fourth scanning period, and receives port number 4 after sending a port query request, wherein the detected port is connected to a fourth port of the linear CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet; and A connection status detection device comprising:
27. a controller area network (CAN) bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, a first port, a second port, a third port, and a fourth port connected to the first CAN bus; a memory; and processing logic; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units, the third port of the straight CAN bus network access unit is connected to the second CAN bus, any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus, and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus; the memory is configured to store control instructions; The processing logic reads the control instructions stored in the memory to: determining whether the CAN bus network access unit is the linear CAN bus network access unit or the transplanter CAN bus network access unit; if the CAN bus network access unit is the linear CAN bus network access unit, connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during consecutive first, second, third, and fourth scan periods; When the CAN bus network access unit is the transplanter CAN bus network access unit, during the first scanning period, connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus; during the second scanning period, connecting the first port, the third port, and the fourth port to the first CAN bus and connecting the second port to the second CAN bus; during the third scanning period, connecting the first port, the second port, and the fourth port to the first CAN bus and connecting the third port to the second CAN bus; during the fourth scanning period, connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus; transmitting a message by using the first CAN bus transceiver and the second CAN bus transceiver, and advertising an identifier of the CAN bus network access unit, a number of the bus corresponding to the transceiver, and a number of the port connected to the bus through ports connected to the first CAN bus transceiver and the second CAN bus transceiver; 1. A CAN bus network access unit configured to:
28. a controller area network (CAN) bus network access unit comprising: a first CAN bus and a second CAN bus; a first CAN bus transceiver and a second CAN bus transceiver connected to the first CAN bus and the second CAN bus, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit, a first port, a second port, a third port, and a fourth port connected to the first CAN bus; a memory; and processing logic; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units, the third port of the straight CAN bus network access unit is connected to the second CAN bus, any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus, and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus; the memory is configured to store control instructions; The processing logic reads the control instructions stored in the memory to: for a detected port of the CAN bus network access unit, determining that the detected port is connected to a linear CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives messages notifying an identifier of the CAN bus network access unit, a bus number 1, and a port number 1 during consecutive first, second, third, and fourth scan periods, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical entry; determining that the detected port is connected to a linear CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives messages notifying the identifier, bus number 2, and port number 3 of the CAN bus network access unit during the consecutive first scanning period, the second scanning period, the third scanning period, and the fourth scanning period; and recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and the third port is a logical outlet; determining that the detected port is connected to a transplanter CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, the bus number 1, and a specific flag bit during the first scanning period, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical inlet; recording the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the second scanning period, and receives a port number 2 after sending a port query request, wherein the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet; and recording the identifier of the CAN bus network access unit if the detected port receives a message notifying the identifier of the CAN bus network access unit, the bus number 1 or 2, and a specific flag bit during the third scanning period, and receives a port number 3 after sending a port query request, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet; If the detected port receives a message notifying the identifier of the CAN bus network access unit, a bus number 1 or 2, and a specific flag bit during the fourth scanning period, and receives a port number 4 after sending a port query request, recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a fourth port of the linear CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet.
1. A CAN bus network access unit configured to implement:
29. 1. A computer-readable medium storing control instructions configured to be executed by processing logic of a Controller Area Network (CAN) bus network access unit, wherein in addition to the processing logic, the CAN bus network access unit further comprises: a first CAN bus and a second CAN bus; first and second CAN bus transceivers coupled to the first and second CAN buses, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit; and a first port, a second port, a third port, and a fourth port coupled to the first CAN bus; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units, the third port of the straight CAN bus network access unit is connected to the second CAN bus, any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus, and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus; The control instructions are executed by the processing logic of the CAN bus network access unit to cause the CAN bus network access unit to: determining whether the CAN bus network access unit is the linear CAN bus network access unit or the transplanter CAN bus network access unit; if the CAN bus network access unit is the linear CAN bus network access unit, connecting the first port to the first CAN bus and connecting the third port to the second CAN bus during consecutive first, second, third, and fourth scan periods; When the CAN bus network access unit is the transplanter CAN bus network access unit, during the first scanning period, connecting the first port to the first CAN bus and connecting the second port, the third port, and the fourth port to the second CAN bus; during the second scanning period, connecting the first port, the third port, and the fourth port to the first CAN bus and connecting the second port to the second CAN bus; during the third scanning period, connecting the first port, the second port, and the fourth port to the first CAN bus and connecting the third port to the second CAN bus; during the fourth scanning period, connecting the first port, the second port, and the third port to the first CAN bus and connecting the fourth port to the second CAN bus; transmitting a message by using the first CAN bus transceiver and the second CAN bus transceiver, and advertising, through ports connected to the first CAN bus transceiver and the second CAN bus transceiver, an identifier of the CAN bus network access unit, a bus number corresponding to the transceiver, and a port number of a port connected to the bus; A computer-readable medium for implementing the above.
30. 1. A computer-readable medium storing control instructions configured to be executed by processing logic of a Controller Area Network (CAN) bus network access unit, wherein in addition to the processing logic, the CAN bus network access unit further comprises: a first CAN bus and a second CAN bus; first and second CAN bus transceivers coupled to the first and second CAN buses, respectively, and configured to communicate with another first CAN bus and another second CAN bus in another CAN bus network access unit; and a first port, a second port, a third port, and a fourth port coupled to the first CAN bus; the CAN bus network access units are classified into straight CAN bus network access units and transplanter CAN bus network access units, the third port of the straight CAN bus network access unit is connected to the second CAN bus, any one of the second port and the fourth port is connected to neither the first CAN bus nor the second CAN bus, and any one of the second port, the third port, and the fourth port of the transplanter CAN bus network access unit is connectable to the first CAN bus or the second CAN bus; The control instructions are executed by the processing logic of the CAN bus network access unit to cause the CAN bus network access unit to: for a detected port of the CAN bus network access unit, determining that the detected port is connected to a linear CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives messages notifying an identifier of the CAN bus network access unit, a bus number 1, and a port number 1 during consecutive first, second, third, and fourth scan periods, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical entry; determining that the detected port is connected to a linear CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives messages notifying the identifier, bus number 2, and port number 3 of the CAN bus network access unit during the consecutive first scanning period, the second scanning period, the third scanning period, and the fourth scanning period; and recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and the third port is a logical outlet; determining that the detected port is connected to a transplanter CAN bus network access unit and recording the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, the bus number 1, and a specific flag bit during the first scanning period, wherein the detected port is connected to a first port of the linear CAN bus network access unit, and the first port is a logical inlet; and recording the identifier of the CAN bus network access unit if the detected port receives a message informing the identifier of the CAN bus network access unit, the bus number 1 or 2, and a specific flag bit during the second scanning period, and receives a port number 2 after sending a port query request, wherein the detected port is connected to a second port of the linear CAN bus network access unit, and if the bus number is 1, the second port is a logical outlet, and if the bus number is 2, the second port is a logical inlet; and recording the identifier of the CAN bus network access unit if the detected port receives a message notifying the identifier of the CAN bus network access unit, the bus number 1 or 2, and a specific flag bit during the third scanning period, and receives a port number 3 after sending a port query request, wherein the detected port is connected to a third port of the linear CAN bus network access unit, and if the bus number is 1, the third port is a logical outlet, and if the bus number is 2, the third port is a logical inlet; If the detected port receives a message notifying the identifier of the CAN bus network access unit, the bus number 1 or 2, and a specific flag bit during the fourth scanning period, and receives port number 4 after sending a port query request, recording the identifier of the CAN bus network access unit, wherein the detected port is connected to a fourth port of the linear CAN bus network access unit, and if the bus number is 1, the fourth port is a logical outlet, and if the bus number is 2, the fourth port is a logical inlet. A computer-readable medium for implementing the above.