CN118041717A - CAN communication module and method for double-path backup - Google Patents

CAN communication module and method for double-path backup Download PDF

Info

Publication number
CN118041717A
CN118041717A CN202311830277.2A CN202311830277A CN118041717A CN 118041717 A CN118041717 A CN 118041717A CN 202311830277 A CN202311830277 A CN 202311830277A CN 118041717 A CN118041717 A CN 118041717A
Authority
CN
China
Prior art keywords
signal
signals
communication
backup
received
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311830277.2A
Other languages
Chinese (zh)
Inventor
骆福勇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Wuhan Shengxiang Electronic Technology Co ltd
Original Assignee
Wuhan Shengxiang Electronic Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Wuhan Shengxiang Electronic Technology Co ltd filed Critical Wuhan Shengxiang Electronic Technology Co ltd
Priority to CN202311830277.2A priority Critical patent/CN118041717A/en
Publication of CN118041717A publication Critical patent/CN118041717A/en
Pending legal-status Critical Current

Links

Landscapes

  • Small-Scale Networks (AREA)

Abstract

The invention belongs to the field of communication, and relates to a CAN communication module and method for double-path backup. The discharge tube is connected in parallel with the CAN signal line, the CANL signal line and the CANH signal line are respectively connected in series with the common mode inductor, and are connected with the external isolation transceiver after being connected through the common mode inductor, and the indication lamp circuit adopts independent IO control, so that the module fault location is facilitated. The dual-backup system of the invention not only has higher reliability, but also has higher safety, thus being widely applicable in the automation field.

Description

CAN communication module and method for double-path backup
Technical Field
The invention belongs to the field of communication, and relates to a CAN communication module and method for double-path backup.
Technical Field
With the development of electronic information industry, electronic equipment suitable for different working environments is endlessly layered, and the high performance and reliability of the CAN bus are recognized and widely applied to the aspects of industrial automation, ships, medical equipment, industrial equipment and the like. Fieldbus is one of the hot spots in the technical development of the automation field today, and is known as a computer local area network in the automation field. The method provides powerful technical support for the distributed control system to realize real-time and reliable data communication among the nodes.
Along with the continuous deep application of powerful single chip microcomputer in the control field, fault-tolerant control systems are also continuously developed, and in some specific occasions, such as important departments of aerospace, military, railway, petroleum, chemical industry, electric power and the like and computer control systems working in severe working environments, the requirements on system safety, reliability and usability are higher.
Disclosure of Invention
Aiming at the defects of the prior art, the invention provides a CAN communication module and a method for double-path backup. The invention uses a node (station) in CAN communication to broadcast data to all nodes in the network in the form of message. Each node receives data, whether or not it is addressed to itself. The invention is characterized in that two modules of the dual backup system simultaneously execute the same operation, and when one module fails, the switching can be automatically judged and judged so as to ensure the stable, reliable and uninterrupted operation of the system. The dual-backup system has high reliability and high safety, so that the dual-backup system can be widely applied in the field of automation.
The technical scheme of the invention is as follows: a CAN communication method of double-path backup is characterized in that: the method comprises the following steps:
step one, when in operation, the first CAN signal and the second CAN signal simultaneously receive signals,
Setting maximum signal silence time, wherein the external data equipment transmits communication signals in a time-sharing difference manner in the maximum signal silence time, and other external equipment transmits the communication signals in a time-sharing manner at the last moment of the maximum signal silence time;
Step three, judging whether the first CAN signal and the second CAN signal are abnormal or not, wherein the specific method comprises the following steps: in the maximum signal silence time, two CAN signals CAN be received normally, the system is judged to work normally, the CAN signals which are received normally are used as receiving and transmitting signals, and the other CAN signals only receive signals;
If only one CAN signal is normally received in the maximum signal silencing time, judging that the other CAN signal is abnormal, taking the received normal CAN signal as a receiving and transmitting CAN signal, and suspending the other CAN signal;
In the maximum signal silence time, if the two CAN signals CAN not be normally received, the two CAN signals inside send information to each other, and the information CAN be mutually received, and then an alarm prompt that an external connection system has errors is sent; if the internal transmission information can not be received, an alarm prompt that the internal connection is wrong is sent.
The CAN communication method for the double-path backup is characterized by comprising the following steps of: the external data is 8 paths, the maximum signal silence time is 1 minute, and when the external communication signal is not available, the 8 paths of external data equipment peripheral devices send communication signals at intervals of 100ms after 59 seconds.
The CAN communication method for the double-path backup is characterized by comprising the following steps of: when both CAN signals CAN be received normally, comparing the two CAN signal receiving information according to a certain rule.
The invention also discloses a double-path backup CAN communication module, which comprises a microcontroller, wherein the microcontroller is respectively connected with the first CAN signal path and the isolation, the second CAN signal path and the isolation, the nixie tube display circuit, the dial switch circuit and the indicator light circuit, and is characterized in that: the microcontroller is a GD32F407VET6 chip, the first CAN signal path and the isolation are the same as the second CAN signal path and the isolation circuit, the first CAN signal path and the isolation comprise a common-mode inductor, a transient suppression diode, two unidirectional diodes and a discharge tube, wherein the transient suppression diode is connected with the two unidirectional diodes in series and then connected with the CAN signal line in parallel, the discharge tube is connected with the CAN signal line in parallel, the CANL signal line and the CANH signal line are respectively connected with the common-mode inductor in series and then connected with an external isolation transceiver through the common-mode inductor, and the indicator lamp circuit adopts independent IO control, so that the fault location of a module is facilitated; the dial switch circuit adopts a dial switch to calibrate the equipment ID for the module; and the nixie tube display circuit displays the ID number of the current equipment.
The CAN communication module for dual-path backup is characterized in that: an LDO voltage reducing circuit is adopted to provide an input power supply for the module.
The CAN communication module for dual-path backup is characterized in that: when one node on the CAN bus transmits data, the data is broadcasted to all nodes in the network in the form of a message.
The beneficial effects of the invention are as follows: the purpose of this transmission is to provide a double-circuit backup CAN communication module for the instability of the traditional CAN bus network in the automation field application. The module is strong in universality, wide in application range, adjustable and controllable in checking mechanism and detailed in test data, labor cost is effectively reduced, and consistency of products and test data are effectively ensured.
Drawings
Fig. 1 is a schematic diagram of the present invention.
Fig. 2 is a schematic diagram of an isolated portion of the present invention.
Fig. 3 is a schematic diagram of a portion of a microcontroller according to the present invention.
Fig. 4 is a schematic diagram of a key portion of the present invention.
Fig. 5 is a software implementation framework.
Fig. 6 software implementation framework.
Detailed Description
The technical scheme of the invention is further described below with reference to the accompanying drawings.
As shown in fig. 1 to 4, the two-way backup CAN communication module of the present invention CAN automatically monitor data parameters, and is used for two-way backup of CAN communication equipment. The double-path backup CAN communication module comprises a microcontroller which is respectively connected with a first CAN signal path and an isolation, a second CAN signal path and an isolation, nixie tube display circuit, a dial switch circuit and an indicator light circuit. The hardware circuit of the invention can adopt an LDO voltage reduction circuit, namely, receives external DC24V, inputs and reduces voltage, and provides input power for the module, thus guaranteeing the stability of the module to the greatest extent, and the power input end adopts surge protection measures composed of GDT and TVS, thus greatly improving the reliability of the device.
As shown in fig. 1 to 4, the microcontroller of the invention is a GD32F407VET6 chip, two CAN bus modules are integrated in the GD32F407VET6 chip, and active and passive versions of a CAN protocol are supported, so that the GD32F407VET6 is suitable for hardware design of a double-path backup CAN module, and the microcontroller is a logic control core of the module and is used for CAN data communication, analysis of functional failure of an indicator light module and calibration of an equipment ID. The first CAN signal path and the isolation are the same as the second CAN signal path and the isolation circuit, the first CAN signal path and the isolation comprise a common mode inductance (SDCW and 3216), a transient suppression diode (SMBJ 15 CA) and two unidirectional diodes, a discharge tube (SC 3E590 LSMD), wherein the transient suppression diode is connected with the two unidirectional diodes in series and then connected on a CAN signal line in parallel, the discharge tube is connected on the CAN signal line in parallel, the CANL signal line and the CANH signal line are respectively connected on the common mode inductance in series, and the common mode inductance is connected and then connected with an external isolation transceiver (CTD 331 and SCANH), and the isolation treatment CAN prevent the damage of high current voltage to a communication interface and provide protection measures for an internal circuit.
As shown in fig. 1 to 4, the indicator light circuit of the invention adopts independent IO control, which is convenient for module fault location, namely, indicating each functional state of the module. The dial switch circuit adopts a dial switch, namely, a module equipment ID number is set, equipment ID is calibrated for a module, and the dial switch circuit has stable performance and is convenient to operate; and the nixie tube display circuit displays the ID number of the current equipment. The invention can also provide a key configuration and nixie tube display panel, which is convenient for visual operation and verification of the inspection target parameters; providing an operation self-checking mode, ensuring the reliability of CAN communication, and backing up data after the self-checking meets the requirement; providing status indicator lamp display, and improving module fault analysis efficiency; CAN isolation is provided, and the stability of CAN data in a CAN communication environment is ensured. The invention ensures the reliability of the CAN communication system, reduces the cost of manual participation detection and improves the consistency of products.
According to the invention, the reliability of equipment communication is ensured by automatically monitoring CAN equipment data, the cost of manual participation detection is reduced, and the consistency of products is improved.
According to the characteristics of CAN communication, when one node (station) on the CAN bus transmits data, the data is broadcasted to all nodes in the network in the form of a message. Each node receives data, whether or not it is addressed to itself. The two-way CAN modules described above perform the same operations simultaneously. When communication fails, the microcontroller judges the data state of the link to determine whether the link is a bus transmission end failure or a self receiving end failure. The identification flow is as follows:
As shown in fig. 6, the two-way backup CAN communication method of the present invention includes the following steps:
step one, when in operation, the first CAN signal and the second CAN signal simultaneously receive signals,
Setting maximum signal silence time, and sending communication link signals by external data equipment in a time-sharing difference mode in the maximum signal silence time, wherein the communication link signals are generally sent in a time-sharing mode by other external equipment at the last moment of the maximum signal silence time. If 8 external data devices exist, if the delay of the first CAN signal and the second CAN signal is set to be more than 1 minute, if the first CAN signal and the second CAN signal are not received, the sending data is considered to be abnormal, and if the external communication signals are not available, the external data devices of the 8 external data devices are sequentially provided with sending communication signals at intervals after 59 seconds, for example, the sending communication signals are respectively sent at intervals of 100 ms;
step three, judging whether the first CAN signal and the second CAN signal are abnormal or not, wherein the specific method comprises the following steps:
And in the maximum signal silence time, two CAN signals CAN be received normally, the system is judged to work normally, the CAN signals which are received normally are used as receiving and transmitting signals, and the other CAN signals only receive signals. The invention CAN compare two CAN signal receiving information according to a certain rule, such as complete data comparison or data extraction of every ten data for comparison, so as to ensure the accuracy of the received data.
If only one CAN signal is normally received in the maximum signal silencing time, the condition that the other CAN signal is abnormal is judged, the received normal CAN signal is used as a receiving and transmitting CAN signal, the other CAN signal stops working, an alarm prompt is sent, and the problem of the system is possibly caused.
In the maximum signal silence time, if the two CAN signals CAN not be normally received, the two CAN signals inside send information to each other, and the information CAN be mutually received, and then an alarm prompt that an external connection system has errors is sent; if the internal transmission information can not be received, an alarm prompt that the internal connection is wrong is sent.

Claims (7)

1. A CAN communication method of double-path backup is characterized in that: the method comprises the following steps:
step one, when in operation, the first CAN signal and the second CAN signal simultaneously receive signals,
Setting maximum signal silence time, wherein the external data equipment transmits communication signals in a time-sharing difference manner in the maximum signal silence time, and other external equipment transmits the communication signals in a time-sharing manner at the last moment of the maximum signal silence time;
Step three, judging whether the first CAN signal and the second CAN signal are abnormal or not, wherein the specific method comprises the following steps: in the maximum signal silence time, two CAN signals CAN be received normally, the system is judged to work normally, the CAN signals which are received normally are used as receiving and transmitting signals, and the other CAN signals only receive signals;
If only one CAN signal is normally received in the maximum signal silencing time, judging that the other CAN signal is abnormal, taking the received normal CAN signal as a receiving and transmitting CAN signal, and suspending the other CAN signal;
In the maximum signal silence time, if the two CAN signals CAN not be normally received, the two CAN signals inside send information to each other, and the information CAN be mutually received, and then an alarm prompt that an external connection system has errors is sent; if the internal transmission information can not be received, an alarm prompt that the internal connection is wrong is sent.
2. The two-way backup CAN communication method of claim 1, wherein: the external data is 8 paths, the maximum signal silence time is 1 minute, and when the external communication signal is not available, the 8 paths of external data equipment peripheral devices send communication signals at intervals of 100ms after 59 seconds.
3. The two-way backup CAN communication method of claim 1, wherein: when both CAN signals CAN be received normally, comparing the two CAN signal receiving information according to a certain rule.
4. The utility model provides a CAN communication module of double-circuit backup, includes microcontroller, microcontroller respectively with first CAN signal path and isolation, second CAN signal path and isolation, charactron display circuit, dial switch circuit, pilot lamp circuit connection, its characterized in that: the microcontroller is a GD32F407VET6 chip, the first CAN signal path and the isolation are the same as the second CAN signal path and the isolation circuit, the first CAN signal path and the isolation comprise a common-mode inductor, a transient suppression diode, two unidirectional diodes and a discharge tube, wherein the transient suppression diode is connected with the two unidirectional diodes in series and then connected with the CAN signal line in parallel, the discharge tube is connected with the CAN signal line in parallel, the CANL signal line and the CANH signal line are respectively connected with the common-mode inductor in series and then connected with an external isolation transceiver through the common-mode inductor, and the indicator lamp circuit adopts independent IO control, so that the fault location of a module is facilitated; the dial switch circuit adopts a dial switch to calibrate the equipment ID for the module; and the nixie tube display circuit displays the ID number of the current equipment.
5. The two-way backup CAN communication module of claim 4, wherein: an LDO voltage reducing circuit is adopted to provide an input power supply for the module.
6. The two-way backup CAN communication module of claim 4, wherein: when one node on the CAN bus transmits data, the data is broadcasted to all nodes in the network in the form of a message.
7. The two-way backup CAN communication module of claim 4, wherein: communication state identification is carried out by adopting the CAN communication method of the two-way backup of the claims 1 to 3.
CN202311830277.2A 2023-12-28 2023-12-28 CAN communication module and method for double-path backup Pending CN118041717A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311830277.2A CN118041717A (en) 2023-12-28 2023-12-28 CAN communication module and method for double-path backup

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311830277.2A CN118041717A (en) 2023-12-28 2023-12-28 CAN communication module and method for double-path backup

Publications (1)

Publication Number Publication Date
CN118041717A true CN118041717A (en) 2024-05-14

Family

ID=90984839

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311830277.2A Pending CN118041717A (en) 2023-12-28 2023-12-28 CAN communication module and method for double-path backup

Country Status (1)

Country Link
CN (1) CN118041717A (en)

Similar Documents

Publication Publication Date Title
CN101520744B (en) Self-checking serial communication system and self-checking method thereof
JPH10228426A (en) Bus system and operating method for bus system
CN105049311B (en) Two-bus communication and communication system
JP2013232886A (en) Communication device, method for detecting wiring state using communication device, and computer program
CN118041717A (en) CAN communication module and method for double-path backup
CA2818367C (en) Input/output unit and control system
CN101840740B (en) Automatic failure detection system and method for two channels
CN109361563B (en) Substation DNP protocol debugging method
CN214704621U (en) RS485 bus machine with self-detection function
CN113973025A (en) CAN bus-based satellite-borne computer communication reliability and fault tolerance design method
CN106161101A (en) Power station OnCall short message alarm system automatic detection device for coat working state
CN110165643B (en) Interconnected microcomputer protection method and system
CN113050475A (en) CAN and 1553b dual-redundancy architecture design method based on VPX
CN218499144U (en) Redundant backup device
CN112983932A (en) Hydraulic test bed equipment and data acquisition system, measurement and control system and measurement and control method thereof
CN109067567A (en) A kind of network communication method for diagnosing interruption
CN111740578A (en) Double-set redundancy switching method for valve control system
CN106873356B (en) Redundancy control system capable of automatically recovering redundancy and redundancy automatic recovery method thereof
CN105044552A (en) Fault diagnosis method, system and device for distribution network automation system
CN219627735U (en) Bus safety alarm system
CN115276923B (en) Redundant communication circuit and fault determination method
CN113655752B (en) Two-bus equipment, self-checking method thereof and building automatic control system
CN220455472U (en) Switch detection device and robot
CN203133819U (en) 1553B bus detection system
CN212781017U (en) Fire control transmission unit test fixture

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination