General communication circuit for CAN and CANFD
By designing common communication circuits for CAN and CANFD, using level generation and arbitration circuits, photoelectric interconversion circuits, and fiber optic connections, the problems of insufficient stability and high cost of existing equipment under harsh electromagnetic environment conditions have been solved, and the problem has been achieved. Stable communication and cost reduction effects.
Patent Information
- Application Number
- CN202410794825.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-19
- Publication Date
- 2024-08-23
AI Technical Summary
Existing CAN or CANFD equipment has insufficient stability under harsh electromagnetic environment conditions, and the cost of hardware to improve stability is high.
A communication circuit common to CAN and CANFD is designed, including level generation and arbitration circuits, and photoelectric interconversion circuits. Each node device constitutes a point structural unit and is connected through optical fiber, eliminating the need for CAN or CANFD transceivers and simplifying the circuit. structure, reducing costs.
It realizes stable communication of CAN or CANFD devices, reduces hardware costs, meets the multi-host arbitration mechanism, does not need to consider the impedance matching problem of differential lines, and improves anti-interference performance.
Smart Images

Figure CN118540180A
Abstract
Description
Background Art
[0002] CAN and CANFD buses are multi-master bus systems with the characteristics of high speed and high reliability. They are widely used in automotive electronics, industrial control and other fields.
[0003] Conventional CAN or CANFD bus network is composed of multiple devices with CAN or CANFD, which are networked through twisted pair shielded cables. The MCU used in the device has its own CAN or CANFD controller, and an external CAN or CANFD transceiver can convert the TTL level to the CAN or CANFD bus level. In order to improve the stability of the bus, the terminal impedance matching of the CAN or CANFD network is required. However, in places with harsh electromagnetic environments, such as industrial places with high-power generators or motors, the CAN or CANFD bus is more susceptible to interference. In order to improve the anti-interference of the bus, the CAN or CAN bus network needs to be processed, such as adding digital isolators or optocouplers to the TX and RX pins between the CAN or CANFD transceiver and the CAN or CANFD control of the MCU, isolating the power supply and ground between the CAN or CANFD transceiver and the MCU; adding common mode inductors, Y capacitors, TVS diodes, etc. to the CANH / CANL or CANFDH / CANFDL signal links of the CAN or CANFD output for electromagnetic compatibility processing. This method can improve the stability of CAN or CANFD communication, but it also increases the hardware cost.
[0004] Optical fiber has great advantages in increasing communication distance, blocking common-mode interference loops, and improving anti-interference performance. In order to improve the anti-interference performance of CAN communication and increase the communication distance at the same time, CAN or CANFD to optical fiber products have appeared on the market. This type of product has a built-in CAN or CANFD transceiver, which converts the CAN or CANFD signal sent by the source device into a TTL signal. The CAN or CANFD controller built into the MCU analyzes and processes the data, and then communicates the data with the CAN or CANFD to optical fiber product located at the target device through the optical fiber transceiver. The target device and the CAN or CANFD to optical fiber product equipped with it perform the reverse conversion process of the source device. Although this solution can increase the communication distance and improve anti-interference performance, the communication process goes through multiple levels of conversion, which increases the cost. Summary of the invention
[0005] In order to solve the above-mentioned problems in the prior art, namely, the insufficiency of the stability of the existing CAN or CANFD devices and the high hardware cost for maintaining the stability, the present invention provides a communication circuit common to CAN and CANFD, the communication circuit comprising:
[0006] Level generation and arbitration circuit, photoelectric conversion circuit;
[0007] Each node device is connected in turn with the corresponding level generation and arbitration circuit, and the photoelectric conversion circuit to form a point structure unit;
[0008] The level generation and arbitration circuit includes a diode D and a pull-up resistor; the node between the diode D and the pull-up resistor is recorded as a first common node;
[0009] The photoelectric conversion circuit includes an optical fiber transmitter TX, an optical fiber receiver RX, a driver ST and a buffer SR, and is connected to the level generation and arbitration circuit through a first common node;
[0010] The point structure units are connected through optical fibers between the photoelectric conversion circuits.
[0011] Furthermore, the level generating and arbitration circuit specifically comprises:
[0012] The transmitting end of the node device is connected to the cathode of the diode D;
[0013] The anode of the diode D is connected to the first common node;
[0014] The first common node is connected to a first digital source via the pull-up resistor;
[0015] The first public node is also connected to the receiving end of the node device.
[0016] Furthermore, the photoelectric conversion circuit is specifically:
[0017] The first common node is connected to the input terminal of the driver ST and the output terminal of the buffer SR;
[0018] The output end of the driver ST is connected to the cathode of the optical fiber transmitter TX, and the anode of the optical fiber transmitter TX is connected to the second digital power supply;
[0019] The input end of the buffer SR is connected to the output end of the optical fiber receiver RX.
[0020] Furthermore, a current limiting resistor R is further provided between the output end of the driver ST and the cathode of the optical fiber transmitter TX.
[0021] Furthermore, the third digital power source connected to the optical fiber receiver RX has the same value as the second digital power source.
[0022] Furthermore, the point structure units are connected via optical fibers between the photoelectric conversion circuits, specifically:
[0023] The optical fiber transmitter TX corresponding to each node device is connected to the optical fiber receiver RX corresponding to another power-saving device through an optical fiber.
[0024] Furthermore, all node devices do not share a common ground.
[0025] Furthermore, a multi-node networking connection method is also included: multiple point structure units are connected to a central hub via optical fibers.
[0026] Furthermore, the central hub includes: n optical fiber receivers RX, n optical fiber transmitters TX, n buffers SR and n drivers ST; n represents the number of access point structural units.
[0027] Furthermore, the central hub is specifically:
[0028] The hub optical fiber receiver HUB_RX is connected to the input end of the hub buffer S_HUB_R;
[0029] The hub optical fiber transmitter HUB_TX is connected to the output end of the hub driver S_HUB_T;
[0030] The output terminals of all hub buffers S_HUB_R are connected to the input terminals of all hub drivers S_HUB_T.
[0031] Furthermore, the central hub is independently powered and does not share a common ground with all node devices.
[0032] Beneficial effects of the present invention:
[0033] (1) The communication circuit provided by the present invention is a full hardware circuit, but does not involve the conversion of the communication protocol, and can achieve stable communication of CAN or CANFD devices without additional software development.
[0034] (2) The communication circuit provided by the present invention does not have a CAN or CANFD transceiver, which simplifies the circuit structure, reduces the cost and satisfies the multi-host arbitration mechanism.
[0035] (3) Since the communication circuit provided by the present invention does not have a CAN or CAN FD transceiver, the physical layer is completely different from the traditional structure based on differential line pairs, and stability can be achieved without considering the impedance matching problem of the differential line. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Other features, objects and advantages of the present application will become more apparent by reading the detailed description of non-limiting embodiments made with reference to the following drawings:
[0037] Figure 1 It is a structural block diagram of a communication circuit common to CAN and CANFD in an embodiment of the present invention;
[0038] Figure 2 is a circuit diagram of a communication circuit common to CAN and CANFD in an embodiment of the present invention;
[0039] Figure 3 It is a structural block diagram of a communication circuit common to CAN and CANFD for network communication in an embodiment of the present invention;
[0040] Figure 4 It is a circuit diagram of a communication circuit common to CAN and CANFD for network communication in an embodiment of the present invention. DETAILED DESCRIPTION
[0041] The present application will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the relevant invention, rather than to limit the invention. It is also necessary to explain that, for ease of description, only the parts related to the relevant invention are shown in the accompanying drawings.
[0042] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.
[0043] The present invention provides a communication circuit common to CAN and CANFD, the communication circuit comprising:
[0044] Level generation and arbitration circuit, photoelectric conversion circuit;
[0045] Each node device is connected in turn with the corresponding level generation and arbitration circuit, and the photoelectric conversion circuit to form a point structure unit;
[0046] The level generation and arbitration circuit includes a diode D and a pull-up resistor; the node between the diode D and the pull-up resistor is recorded as a first common node;
[0047] The photoelectric conversion circuit includes an optical fiber transmitter TX, an optical fiber receiver RX, a driver ST and a buffer SR, and is connected to the level generation and arbitration circuit through a first common node;
[0048] The point structure units are connected through optical fibers between the photoelectric conversion circuits.
[0049] The communication circuit provided by the present invention is a full hardware circuit, which saves software development costs and can achieve stable communication of CAN or CANFD devices.
[0050] In order to more clearly explain the communication circuit common to CAN and CANFD of the present invention, the following is combined with Figure 1 The components of each circuit in the embodiment of the present invention are described in detail.
[0051] A communication circuit common to CAN and CANFD in the first embodiment of the present invention is applied to point-to-point communication. The communication circuit includes a level generation and arbitration circuit and a photoelectric conversion circuit. Each step is described in detail as follows:
[0052] Level generation and arbitration circuit, photoelectric conversion circuit;
[0053] Each node device is connected in turn with the corresponding level generation and arbitration circuit, and photoelectric conversion circuit to form a point structure unit; taking CAN or CANFD as an example of the node device, the level generation and arbitration circuit, and the photoelectric conversion circuit are integrated on each CAN or CANFD, and share the same ground with the MCU where the CAN controller or CANFD controller on the node device is located.
[0054] All node devices do not share the same ground.
[0055] The level generation and arbitration circuit includes a diode D and a pull-up resistor; the node between the diode D and the pull-up resistor is recorded as a first common node;
[0056] In this embodiment, the level generating and arbitration circuit specifically includes:
[0057] The transmitting end of the node device is connected to the cathode of the diode D;
[0058] The anode of the diode D is connected to the first common node;
[0059] The first common node is connected to a first digital source via the pull-up resistor;
[0060] The first public node is also connected to the receiving end of the node device.
[0061] Reference Figure 2 , the cathode of diode D is connected to the transmitting end of the node device, i.e., CAN_TX or CANFD_TX pin; and the anode of the fast recovery diode is connected to the first common node, which is connected to the receiving end of the node device, i.e., CAN_RX or CANFD_RX; at the same time, the first common node is connected to the digital power supply of the MCU, i.e., the first digital power supply, through a pull-up resistor. The pull-up resistor pulls up the digital power supply of the MCU to obtain a recessive level logic 1. When the transmitting end of the node device, i.e., CAN_TX or CANFD_TX pin, outputs a dominant level, i.e., logic 0, the levels at various locations in the communication circuit are dominant levels;
[0062] The diode D is used to prevent the transmitting end of the power-saving device, i.e., the CAN_TX or CANFD_TX pin, from short-circuiting the dominant level on the line during multi-host arbitration. The dominant level is logic 0, which is equivalent to the reference ground. When the line shows a dominant level, if there is no diode, when the CAN_TX or CANFD_TX pin of any node actively changes to a recessive level, i.e., logic 1, a short circuit to the reference ground will occur. In this embodiment, the diode D is preferably a fast recovery diode. The fast recovery diode is a type of diode and belongs to the industry terminology. In circuit design, a fast recovery diode or a diode with higher performance, such as a Schottky diode, can be used.
[0063] The photoelectric conversion circuit includes an optical fiber transmitter TX, an optical fiber receiver RX, a driver ST and a buffer SR, and is connected to the level generation and arbitration circuit through a first common node;
[0064] In this embodiment, a current limiting resistor R is further provided between the output end of the driver ST and the cathode of the optical fiber transmitter TX.
[0065] In this embodiment, the photoelectric conversion circuit is specifically:
[0066] The first common node is connected to the input terminal of the driver ST and the output terminal of the buffer SR;
[0067] The output end of the driver ST is connected to the cathode of the optical fiber transmitter TX through a current limiting resistor R, and the anode of the optical fiber transmitter TX is connected to the second digital power supply;
[0068] The input end of the buffer SR is connected to the optical fiber receiver RX.
[0069] Reference Figure 2 , the connection relationship between the optical fiber transmitter TX and the optical fiber receiver RX can also be expressed as the anode of the diode in the level conversion circuit is connected to the input of the driver, and the output of the driver is connected to the input of the optical fiber transmitter through a current limiting resistor. The anode of the diode in the level conversion circuit is connected to the output of the buffer, and the input of the buffer is connected to the output of the optical fiber receiver.
[0070] In this embodiment, the third digital power source connected to the optical fiber receiver RX has the same value as the second digital power source.
[0071] The point structure units are connected through optical fibers between the photoelectric conversion circuits.
[0072] In this embodiment, the optical fiber transmitter TX corresponding to each node device is connected to the optical fiber receiver RX corresponding to another power-saving device through an optical fiber.
[0073] In the optical fiber-based CAN or CANFD communication circuit of this embodiment, in the electrical→optical→electrical path consisting of a driver→current limiting resistor→optical fiber transmitter→optical fiber receiver→buffer, it is necessary to ensure that the input end of the driver and the output end of the buffer maintain the same polarity, that is, when the input end of the driver inputs a dominant level, the output end of the buffer outputs a dominant level, and when the input end of the driver inputs a recessive level, the output end of the buffer outputs a recessive level. There is no requirement for the internal circuit logic of the electrical→optical→electrical path.
[0074] In this embodiment, the level generation and arbitration circuit, the photoelectric conversion circuit are integrated with the circuit board in the node device, and an MCU such as ARM and DSP is selected for implementation. The first digital power supply is 3.3V. The second digital power supply and the third digital power supply are +5V. The diode is CDBU0530, and the pull-up resistor is 3.3kΩ / 0.125W. The optical fiber transmitter can use HFBR-1414TZ, the optical fiber receiver can use AFBR-2418TZ, the buffer can use SN74LVC1G125DCKT, the actuator can use SN75451B (only one channel of SN75451B is used, and the two input ends of the channel are short-circuited as a single input end), and the current limiting resistor is 78.6Ω / 0.25W.
[0075] The second embodiment of the present invention provides a circuit for networking a communication circuit common to CAN and CANFD, specifically: a plurality of point structure units are connected to a central hub through optical fibers; the connection of the communication circuit common to CAN and CANFD for networking is as follows: Figure 3 and Figure 4 shown.
[0076] Reference Figure 4 The central hub includes: n optical fiber receivers RX, n optical fiber transmitters TX, n buffers SR and n drivers ST; n represents the number of access point structural units.
[0077] The central hub is specifically:
[0078] The hub optical fiber receiver HUB_RX is connected to the input end of the hub buffer S_HUB_R;
[0079] The hub optical fiber transmitter HUB_TX is connected to the output end of the hub driver S_HUB_T; a hub current limiting resistor HUB_R may also be included between the hub optical fiber transmitter HUB_TX and the output end of the hub driver S_HUB_T;
[0080] The output terminals of all hub buffers S_HUB_R are connected to the input terminals of all hub drivers S_HUB_T.
[0081] In this embodiment, the position where the output ends of the n hub buffers S_HUB_R are connected together is recorded as point A, and the position where the input ends of the n hub drivers S_HUB_T are connected together is recorded as point B, and point A and point B are connected.
[0082] Figure 4 The correspondence between the central hub and the point structure unit is only an example. Any one of the hub fiber optic receivers and any one of the hub fiber optic transmitters in the central hub circuit can form a CAN or CANFD interface, and a total of n CAN or CANFD interfaces can be formed, which are connected to n CAN or CANFD nodes through optical fibers to realize CAN or CANFD communication.
[0083] The central hub is independently powered and does not share the same ground with all node devices. The photoelectric conversion circuit of each node device exchanges data with the central hub through optical fiber, achieving electrical isolation. The n optical fiber receivers RX, n optical fiber transmitters TX, and n buffers SR in the central hub share the same power supply and ground.
[0084] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process and related instructions of the system described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0085] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process and related instructions of the storage device and processing device described above can refer to the corresponding process in the aforementioned method embodiment and will not be repeated here.
[0086] Those skilled in the art should be able to appreciate that the modules and method steps of each example described in conjunction with the embodiments disclosed herein can be implemented with electronic hardware, computer software or a combination of the two, and the programs corresponding to the software modules and method steps can be placed in random access memory (RAM), internal memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disks, removable disks, CD-ROMs, or any other form of storage medium known in the technical field. In order to clearly illustrate the interchangeability of electronic hardware and software, the composition and steps of each example have been generally described in the above description according to the function. Whether these functions are performed in electronic hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present invention.
[0087] The terms "first", "second", etc. are used to distinguish similar objects rather than to describe or indicate a particular order or sequence.
[0088] The term "comprise" or any other similar term is intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus / device that includes a list of elements includes not only those elements but also other elements not expressly listed, or also includes elements inherent to such process, method, article, or apparatus / device.
[0089] So far, the technical solutions of the present invention have been described in conjunction with the preferred embodiments shown in the accompanying drawings. However, it is easy for those skilled in the art to understand that the protection scope of the present invention is obviously not limited to these specific embodiments. Without departing from the principle of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will fall within the protection scope of the present invention.
Claims
1. A communication circuit common to CAN and CANFD, characterized in that: The communication circuit comprises: Level generation and arbitration circuit, photoelectric conversion circuit; Each node device is connected in turn with the corresponding level generation and arbitration circuit, and the photoelectric conversion circuit to form a point structure unit; The level generation and arbitration circuit includes a diode D and a pull-up resistor; the node between the diode D and the pull-up resistor is recorded as a first common node; The photoelectric conversion circuit includes an optical fiber transmitter TX, an optical fiber receiver RX, a driver ST, and a buffer SR, and is connected to the level generation and arbitration circuit through a first common node; The point structure units are connected through optical fibers between the photoelectric conversion circuits.
2. The communication circuit common to CAN and CANFD according to claim 1, characterized in that: The level generating and arbitration circuit specifically comprises: The transmitting end of the node device is connected to the cathode of the diode D; The anode of the diode D is connected to the first common node; The first common node is connected to a first digital source via the pull-up resistor; The first public node is also connected to the receiving end of the node device.
3. The communication circuit common to CAN and CANFD according to claim 1, characterized in that: The photoelectric conversion circuit is specifically: The first common node is connected to the input terminal of the driver ST and the output terminal of the buffer SR; The output end of the driver ST is connected to the cathode of the optical fiber transmitter TX, and the anode of the optical fiber transmitter TX is connected to the second digital power supply; The input end of the buffer SR is connected to the output end of the optical fiber receiver RX.
4. The communication circuit common to CAN and CANFD according to claim 3, characterized in that: A current limiting resistor R is also included between the output end of the driver ST and the cathode of the optical fiber transmitter TX.
5. The communication circuit common to CAN and CANFD according to claim 1, characterized in that: The point structure units are connected via optical fibers between the photoelectric conversion circuits, specifically: The optical fiber transmitter TX corresponding to each node device is connected to the optical fiber receiver RX corresponding to another power-saving device through an optical fiber.
6. The communication circuit common to CAN and CANFD according to claim 1, characterized in that: All node devices do not share the same ground.
7. The communication circuit common to CAN and CANFD according to claim 1, characterized in that: It also includes a multi-node networking connection method: multiple point structure units are connected to a central hub via optical fibers.
8. The communication circuit common to CAN and CANFD according to claim 7, characterized in that: The central hub includes: n optical fiber receivers RX, n optical fiber transmitters TX, n buffers SR and n drivers ST; n represents the number of access point structural units.
9. The communication circuit common to CAN and CANFD according to claim 7, characterized in that: The central hub is specifically: The hub optical fiber receiver HUB_RX is connected to the input end of the hub buffer S_HUB_R; The hub optical fiber transmitter HUB_TX is connected to the output end of the hub driver S_HUB_T; The output terminals of all hub buffers S_HUB_R are connected to the input terminals of all hub drivers S_HUB_T.
10. The communication circuit common to CAN and CANFD according to claim 7, characterized in that: The central hub is independently powered and does not share a common ground with all node devices.
