Industrial application multi-protocol transceiver circuit and industrial control equipment

By designing a multi-protocol transceiver circuit, using RS232, RS485 and RS422 chips and trigger units, multi-protocol adaptation of industrial control equipment is achieved, the problems of waste of resources and large size are solved, and a smaller and more concentrated device design is achieved.

CN119135203APending Publication Date: 2024-12-13CHINA POWER IND INTERNET CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411202755.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-29
Publication Date
2024-12-13

AI Technical Summary

Technical Problem

The transceiver interface of existing industrial control equipment can only support one protocol type, resulting in waste of resources and large equipment size, making it difficult to achieve multi-protocol type adaptation.

Method used

Design a multi-protocol transceiver circuit for industrial applications, including RS232 interface chip, RS485/RS422 transmitting chip, RS485/RS422 receiving chip, monostable trigger unit, bistable trigger unit and AC coupling unit, which is realized through mode switching level The adaptation of RS232, RS485 and RS422 protocols uses a monostable trigger unit to perform automatic data transmission direction control, and combines a bistable trigger unit and an AC coupling unit to realize data transmission in the full baud rate range.

Benefits of technology

It realizes a more streamlined external interface, saves main controller resources, reduces the number of external interfaces of the transceiver circuit, makes the industrial control equipment smaller, has more concentrated functions, and can work stably under different protocol types.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119135203A_ABST
    Figure CN119135203A_ABST
Patent Text Reader

Abstract

The invention relates to an industrial application multi-protocol transceiver circuit and industrial control equipment, designs a transceiver circuit composed of an RS232 interface chip, an RS485 / RS422 sending chip, an RS485 / RS422 receiving chip, a monostable trigger unit, a bistable trigger unit and two alternating current coupling units, provides a four-wire interface to the outside, realizes two paths of RS232 communication and one path of half-duplex or full-duplex RS485 communication, and provides a four-wire interface to the outside. According to the multi-protocol type adaptive transceiver for RS422 communication, which interface protocol mode the transceiver circuit works in can be controlled through a mode switching level, automatic data transmission direction control is carried out through a monostable trigger unit, and reconstruction of data receiving is realized through a bistable trigger unit. The self-adaption of RS232, RS485 and RS422 protocol types is effectively realized, and the system resources of the main controller are saved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of transceiver circuit design, and relates to an industrial application multi-protocol transceiver circuit and industrial control equipment. Background Art

[0002] At present, the transceiver interface of industrial control equipment for industrial applications can only support one protocol type. When the number or location of external interfaces is limited, or when the resources of the main controller are limited, it is not enough to support multi-protocol applications. In addition, when working in RS485 mode, if the main controller does not have high real-time operation, it will become difficult to control the direction of RS485, and the delay between the main controller setting the sending switch to the receiving state is difficult to control. At this time, an auxiliary circuit that automatically determines the transmission direction is needed to realize the self-transmitting and receiving function of the RS485 transceiver. The auxiliary circuit currently used is a transistor reverse automatic switching circuit. The existing industrial control equipment interfaces need to lead out different interfaces according to RS232, RS485 and RS422 protocol types. In the actual application of industrial control equipment, not all interfaces are often used, which will lead to a waste of resources, and the size and weight of the industrial control equipment will become larger; at the same time, when designing a simplified main control system, the number of interfaces is often limited, and it is difficult to provide a large number of interface outputs of various protocol types. Therefore, how to achieve the self-adaptation of multiple protocol types has become a technical problem to be solved at present. Summary of the invention

[0003] In view of the problems existing in the above-mentioned traditional methods, the present invention proposes an industrial application multi-protocol transceiver circuit and an industrial control device, which can effectively realize the adaptation of multiple protocol types and save the main control system resources.

[0004] In order to achieve the above objectives, the embodiments of the present invention adopt the following technical solutions:

[0005] On the one hand, a multi-protocol transceiver circuit for industrial applications is provided, comprising an RS232 interface chip, an RS485 / RS422 transmission chip, an RS485 / RS422 receiving chip, a monostable trigger unit, a bistable trigger unit, a first AC coupling unit, and a second AC coupling unit;

[0006] The first input pin and the second input pin of the transmitting end of the RS232 interface chip are respectively used to connect the universal transmitting pin of the main control unit and the RS232 dedicated transmitting pin, the first output pin and the second output pin of the receiving end of the RS232 interface chip are respectively used to connect the universal receiving pin of the main control unit and the RS232 dedicated receiving pin, the first output pin and the second output pin of the transmitting end of the RS232 interface chip, and the first input pin and the second input pin of the receiving end are respectively led out and used to connect to an external device;

[0007] The input pin of the transmitting end of the RS485 / RS422 transmitting chip is used to connect to the universal transmitting pin of the main control unit, the output pin of the transmitting end and the input pin of the receiving end of the RS485 / RS422 transmitting chip are respectively connected to the first output pin of the transmitting end and the first input pin of the receiving end of the RS232 interface chip through the first AC coupling unit, and the enable pin of the RS485 / RS422 transmitting chip is connected to the output end of the monostable trigger unit;

[0008] The output pin of the receiving end of the RS485 / RS422 receiving chip is connected to the clock input end of the bistable trigger unit, the output pin of the transmitting end of the RS485 / RS422 receiving chip is connected to the output pin of the transmitting end of the RS485 / RS422 transmitting chip and is connected to the second output pin of the transmitting end of the RS232 interface chip through the second AC coupling unit, the input pin of the receiving end of the RS485 / RS422 receiving chip is connected to the input pin of the receiving end of the RS485 / RS422 transmitting chip and is connected to the second input pin of the receiving end of the RS232 interface chip through the second AC coupling unit, and the enable pin of the RS485 / RS422 receiving chip is connected to the output end of the monostable trigger unit;

[0009] The output end of the bistable trigger unit is used to connect to the universal receiving pin of the main control unit, the reset pin of the bistable trigger unit is connected to the output end of the monostable trigger unit through a logic NOT gate, the trigger end of the monostable trigger unit is used to connect to the universal sending pin of the main control unit, the reset pin of the monostable trigger unit and the enable pin of the RS232 interface chip are used to receive the mode switching level; the mode switching level is a high level or a low level, which is used to control the industrial application multi-protocol transceiver circuit to work in RS232 mode or RS485 / 422 mode respectively.

[0010] On the other hand, an industrial control device is also provided, comprising a main control unit and the above-mentioned industrial application multi-protocol transceiver circuit.

[0011] One of the above technical solutions has the following advantages and beneficial effects:

[0012] The above-mentioned industrial application multi-protocol transceiver circuit and industrial control equipment, by designing a transceiver circuit composed of an RS232 interface chip, an RS485 / RS422 transmission chip, an RS485 / RS422 receiving chip, a monostable trigger unit, a bistable trigger unit, a first AC coupling unit and a second AC coupling unit, provides a four-wire interface to the outside to realize a multi-protocol type adaptive transceiver circuit with two RS232 communications, one half-duplex or full-duplex RS485 communication, and one RS422 communication. The interface protocol mode in which the transceiver circuit works can be controlled by a mode switching level, and the data transmission direction is automatically controlled by the monostable trigger unit. At the same time, the reconstruction of data reception is realized by the bistable trigger unit. In conjunction with the application of two AC coupling units, AC-coupled data transmission under the full baud rate range is realized.

[0013] Compared with traditional technologies, the use of more streamlined external interfaces effectively realizes the adaptation of RS232, RS485 and RS422 protocol types, thereby saving system resources of the main controller, and also reducing the number of external interfaces of the transceiver circuit, making the overall industrial control equipment of the application smaller in size and more functionally focused. BRIEF DESCRIPTION OF THE DRAWINGS

[0014] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the conventional technology, the drawings required for use in the embodiments or the conventional technology descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0015] Figure 1 This is a schematic diagram of a triode reverse automatic direction switching RS485 circuit;

[0016] Figure 2 A schematic diagram of the structure of a multi-protocol transceiver circuit for industrial applications in one embodiment;

[0017] Figure 3 FIG. 1 is a schematic diagram of the structural principle of a multi-protocol transceiver circuit for industrial applications in another embodiment. DETAILED DESCRIPTION

[0018] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0019] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application.

[0020] It should be noted that the reference to "embodiment" in this article means that the specific features, structures or characteristics described in conjunction with the embodiment may be included in at least one embodiment of the present invention. The presentation of this phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It will be understood by those skilled in the art that the embodiments described herein may be combined with other embodiments. The term "and / or" used in the specification of the present invention and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, and includes these combinations. "Connection" can be a direct connection between two devices, or it can be an indirect connection between two devices through other devices.

[0021] The following will describe the implementation of the present invention in detail with reference to the accompanying drawings in the embodiment diagram of the present invention.

[0022] The traditional transistor reverse automatic switching circuit is implemented by using the serial port transmission signal TX as the base drive signal of the NPN transistor, the transistor gate (i.e. base) output as the receiving and transmitting control, the transistor emitter output as the sending data pin, and adding a pull-up resistor (R03) / pull-down resistor (R01) at the A / B output end of the RS485 transceiver, such as Figure 1 In the idle state (receiving state), the serial port's sending signal TX is high level, and the gate output of the transistor is low level, making the RS485 chip (i.e. Figure 1 When sending data, the low-level bit of the transmission signal TX enables the RS485 chip to enter the transmission state and send out the low bit; when the transmission signal TX sends a high-level bit, the RS485 chip is enabled to be in the receiving mode. However, since the pull-up / pull-down resistors are added to the A / B bus, the bus is in the state of A high and B low, which is equivalent to sending a high-level bit, thus realizing the automatic transceiver function of the RS485 transceiver.

[0023] However, this circuit has obvious disadvantages. First, the pull-up and pull-down resistors of the A / B bus cannot be too small, otherwise it will affect the normal data level. However, adding larger pull-up and pull-down resistors will significantly affect the driving ability of the bus. When driving multiple slave devices, the driving force is insufficient, and due to the weak driving ability, the transmission distance will also be shortened. In addition, the timing requires the direction pin (RE / DE) to be earlier than the data pin (RO / DI), that is, the direction needs to be switched in advance before data transmission. However, since the direction pin of this circuit is controlled by the data pin after passing through the transistor, the direction signal must be later than the data signal, so the packet loss is serious under high speed conditions, and the application baud rate of the RS485 receiver is limited and cannot reach the maximum speed.

[0024] To avoid the above problems, the present invention will provide a new type of multi-protocol transceiver circuit for industrial applications, which relates to the field of industrial applications and is suitable for the connection of RS232 / RS485 / RS422 communication equipment, such as sensor equipment, electric meter networks, power inverters, terminal equipment, etc., and is suitable for applications in the fields of intelligent manufacturing, smart factories, smart transportation, smart water conservancy, smart circuits and field big data.

[0025] At present, the external communication interfaces provided by industrial control equipment are concentrated in the RS232 interface, RS485 interface, RS422 interface and CAN interface. Generally, industrial control equipment will lead out communication interfaces of different protocol types according to the interface type. However, the RS232 interface, RS485 interface and RS422 interface are all serial port types corresponding to the main controller side, which provides a new idea for the research and development of the invention, that is, whether it is possible to use only one external interface to achieve protocol adaptation of RS232, RS485 and RS422 serial port types when the main control resources are limited or the external interface is limited?

[0026] Based on this background, a new type of multi-protocol transceiver circuit for industrial applications is proposed, and the application topology and implementation method of the new circuit are given. The system of the main controller uses a software-determined combined data bus for communication, and realizes the combination of two RS232 communications, one RS485 communication and one RS422 communication with a 4-wire connection interface, without the need to separately wire and set up interfaces for each interface. The data line can be shared between different types of transceivers, and the main control chip only needs a single control signal to determine which protocol to use. At the same time, a new type of auxiliary circuit that automatically determines the transmission direction is designed in the circuit, and an AC coupling mode under RS485 / RS422 transmission status is set to optimize the transmission performance of the transceiver. No matter which type of protocol interface the external device is connected to, the system will not be unable to recognize or lose control due to bus level problems. This is an innovative and streamlined interface solution.

[0027] In one embodiment, Figure 2 As shown, a multi-protocol transceiver circuit 100 for industrial applications is provided, which may include an RS232 interface chip, an RS485 / RS422 transmitting chip, an RS485 / RS422 receiving chip, a monostable trigger unit, a bistable trigger unit, a first AC coupling unit, and a second AC coupling unit. The first input pin (i.e., DI1) and the second input pin (i.e., DI2) of the transmitting end of the RS232 interface chip are respectively used to connect the universal transmitting pin (i.e., TX) of the main control unit and the RS232 dedicated transmitting pin (i.e., TX_232). The first output pin (i.e., RO1) and the second output pin (i.e., RO2) of the receiving end of the RS232 interface chip are respectively used to connect the universal receiving pin (i.e., RX) of the main control unit and the RS232 dedicated receiving pin (i.e., RX_232). The first output pin (i.e. DO1) and the second output pin (i.e. DO2) of the transmitting end of the RS232 interface chip, as well as the first input pin (i.e. RI1) and the second input pin (i.e. RI2) of the receiving end are respectively led out and used to connect external devices, and the corresponding lead lines can be recorded as TX1, RX1, TX2 and RX2.

[0028] The input pin (i.e., D) of the transmitting end of the RS485 / RS422 transmitting chip is used to connect the universal transmitting pin of the main control unit. The output pin (i.e., A) of the transmitting end and the input pin (i.e., B) of the receiving end of the RS485 / RS422 transmitting chip are respectively connected to the first output pin of the transmitting end and the first input pin of the receiving end of the RS232 interface chip through the first AC coupling unit (i.e., AC coupling 1). The enable pin (i.e., DE) of the RS485 / RS422 transmitting chip is connected to the output end (i.e., OUT) of the monostable trigger unit. The output pin of the receiving end of the RS485 / RS422 receiving chip is connected to the clock input end (i.e., CP) of the bistable trigger unit. The output pin of the transmitting end of the RS485 / RS422 receiving chip is connected to the output pin of the transmitting end of the RS485 / RS422 transmitting chip and is connected to the second output pin of the transmitting end of the RS232 interface chip through the second AC coupling unit (i.e., AC coupling 2). The input pin of the receiving end of the RS485 / RS422 receiving chip is connected to the input pin of the receiving end of the RS485 / RS422 transmitting chip and connected to the second input pin of the receiving end of the RS232 interface chip through the second AC coupling unit. The enable (i.e. / RE) pin of the RS485 / RS422 receiving chip is connected to the output end of the monostable trigger unit.

[0029] The output end (i.e., Q) of the bistable trigger unit is used to connect to the universal receiving pin of the main control unit. The reset pin (i.e., / R) of the bistable trigger unit is connected to the output end of the monostable trigger unit through a logic NOT gate, and the trigger end (i.e., Trigger) of the monostable trigger unit is used to connect to the universal sending pin of the main control unit. The reset pin (i.e., RESET) of the monostable trigger unit and the enable pin (i.e., / EN) of the RS232 interface chip are used to receive the mode switching level; the mode switching level is a high level or a low level, which is used to control the industrial application multi-protocol transceiver circuit to work in RS232 mode or RS485 / 422 mode respectively.

[0030] It can be understood that for each interface chip, among the other pins clearly defined above, except for some pins such as power pins used to connect the power supply of the chip and the ground pins of the chip for grounding, the remaining pins can be wired or left floating according to the inherent wiring specifications of the chip in order to ensure its normal operation in this embodiment.

[0031] Specifically, the industrial application multi-protocol transceiver circuit 100 provides a four-wire interface (including the GND connection line in the interface, which is a five-wire system) to realize the combination of two RS232 communications, one half-duplex or full-duplex RS485 communication, and one RS422 communication, without the need to separately wire and set up each interface. The data line can be shared between different types of transceivers, and the main control chip only needs a single control signal to determine which specific protocol to use in the current application scenario. At the same time, a new type of auxiliary circuit that automatically determines the transmission direction is designed in the circuit, and an AC coupling mode under the RS485 / RS422 transmission state is set to optimize the transceiver transmission performance, so that no matter which type of protocol the external device is connected to, the system will not be unable to recognize or lose control due to bus level problems.

[0032] Among them, the RS232 interface chip, RS485 / RS422 transmission chip and RS485 / RS422 receiving chip can all use existing interface chips in the art, and the specific models and specifications can be selected according to the working needs of the transceiver in the specific industrial application scenario. The monostable trigger unit is a circuit that will change from a stable state to another transient state under the action of a trigger signal, and automatically return to the original stable state after a certain period of time. It is used in this embodiment to automatically control the data transmission direction of the industrial application multi-protocol transceiver circuit 100, such as the data transmission direction control of data transmission and data reception. It can be but not limited to a monostable trigger configured with a 555 timer, a monostable trigger constructed by combining a logic gate (such as a NAND gate, a NOR gate, etc.) with a capacitor and a resistor, a monostable trigger function module implemented by a programmable logic device (PLD) or FPGA through programming, and a monostable trigger function module implemented by a microcontroller or a single-chip microcomputer through software programming.

[0033] The bistable trigger unit is a component of the data signal reconstruction circuit that cooperates with the RS485 / 422 receiving chip and the AC coupling unit, and is used to convert the jump edge of the received signal into a reconstructed data signal. It can be, but is not limited to, a bistable trigger circuit constructed using a D flip-flop (data trigger) and some logic gates (such as an AND gate, an OR gate), a bistable trigger circuit that feeds back the output of the D flip-flop to its input to realize its function, a bistable trigger circuit that connects two T flip-flops in series or adds appropriate control logic to a T flip-flop, a bistable trigger circuit that uses a basic RS flip-flop (composed of an NAND gate or a NOR gate) and adds some logic gates to build a bistable trigger circuit, or a bistable trigger circuit that uses a programmable logic device (PLD) or FPGA to realize its function in a programmable manner. The AC coupling unit can use various types of RC coupling circuits commonly seen in the field of electronic circuits.

[0034] The above-mentioned industrial application multi-protocol transceiver circuit 100, by designing a transceiver circuit composed of an RS232 interface chip, an RS485 / RS422 transmitting chip, an RS485 / RS422 receiving chip, a monostable trigger unit, a bistable trigger unit, a first AC coupling unit and a second AC coupling unit, provides a four-wire interface to the outside to realize a multi-protocol type adaptive transceiver circuit with two RS232 communications, one half-duplex or full-duplex RS485 communication, and one RS422 communication. The interface protocol mode in which the transceiver circuit works can be controlled by a mode switching level, and the data transmission direction is automatically controlled by the monostable trigger unit. At the same time, the reconstruction of data reception is realized by the bistable trigger unit. In combination with the application of two AC coupling units, AC-coupled data transmission under the full baud rate range is realized.

[0035] Compared with traditional technologies, the use of more streamlined external interfaces effectively realizes the adaptation of RS232, RS485 and RS422 protocol types, thereby saving system resources of the main controller, and also reducing the number of external interfaces of the transceiver circuit, making the overall industrial control equipment of the application smaller in size and more functionally focused.

[0036] For further information, see Figure 2 , the implementation idea of ​​this embodiment is analyzed based on the composition block diagram:

[0037] First, when the circuit works in RS232 mode: the RS232 interface chip provides two RS232 interfaces for the main control unit (also known as the main controller), corresponding to TX / RX and TX_232 / RX_232 respectively (where TX_232 / RX_232 is a definite RS232 interface function for the main control unit, while TX / RX can be compatible as an RS485 interface function or an RS422 interface function, which will be explained later). Optionally, the level of the mode switching pin MODE is high or low, which is used to control the circuit to work in RS232 mode or in RS485 / RS422 mode respectively. Therefore, an independent level input method can be used to control the level of the mode switching pin MODE, such as but not limited to a push button switch, a dip switch or a jumper, etc., or the main control unit can directly control the level of the mode switching pin MODE, which can be flexibly selected according to application needs. It can be understood that Figure 2 Of the two RS485 / RS422 interface chips used, one RS485 / RS422 interface chip directly connected to a monostable trigger is used as an RS485 / RS422 transmitting chip, and one RS485 / RS422 interface chip directly connected to a JK trigger is used as an RS485 / RS422 receiving chip.

[0038] In one embodiment, the bistable trigger unit is a JK trigger. It can be understood that in this embodiment, the JK trigger can be directly used as the above-mentioned bistable trigger unit, and the concise circuit structure of the JK trigger can be used to further simplify the circuit of the above-mentioned industrial application multi-protocol transceiver circuit 100, while improving its circuit reliability.

[0039] In one embodiment, the reset pin of the monostable trigger unit and the enable pin of the RS232 interface chip are respectively used to connect to the mode switching pin MODE of the main control unit.

[0040] It can be understood that in the present embodiment, preferably, the main control unit can also provide a GPIO pin as a mode switching pin MODE. When the industrial application multi-protocol transceiver circuit 100 works in the RS232 mode, the mode switching pin MODE is low level, at this time the RS232 interface chip is enabled, and the monostable trigger is reset, and its output pin OUT outputs a low level. At this time, if the RS232 interface chip is in the sending state, the RS485 / RS422 sending chip sets the data output end of the sending chip to a high impedance state because its pin DE is not enabled, so it will not affect the normal sending data in the RS232 mode. If the RS232 interface chip is in the receiving state, the RS485 / 422 receiving chip monitors synchronously, but because the mode switching pin MODE is connected to the / R pin of the JK trigger, the JK trigger is reset, so that the output pin Q of the JK trigger is low level, and the receiving data of the RS232 interface chip will not be changed. Therefore, the RS232 mode can operate normally.

[0041] Second, when the industrial application multi-protocol transceiver circuit 100 works in RS485 half-duplex mode: the RS485 / 422 interface chip provides a RS485 interface for the main control unit, corresponding to TX / RX. At this time, the mode switching pin MODE of the main control unit should output a high level, and the RS232 interface chip is not enabled and the output is all in a high-impedance state, which will not affect the data input and output of the RS485 / 422 interface chip. At this time, the reset pin RESET of the monostable trigger is high, and it can function normally. The trigger state pin Trigger is determined by the transmitted data TX. When the transmitted data TX is high, the monostable trigger detects the transition edge and sets the output pin OUT to a high level. The RS485 / 422 transmitting chip is in an enabled state and sends the data. At this time, the RS485 / 422 receiving chip is not enabled.

[0042] When in idle state, the monostable trigger returns to the initial state, the output pin OUT is low, the RS485 / 422 receiving chip is in receiving state, and after monitoring the signals on the TX1 and RX1 buses, the received signal is output by the pin R of the RS485 / 422 receiving chip. At the same time, since the output pin OUT of the monostable trigger is low, after passing through the logic NOT gate, the pin / R of the JK trigger is high, the JK trigger is enabled and works in the flip mode, and the signal received by the pin R of the RS485 / 422 receiving chip is reset and sent to the receiving pin RX of the main control unit.

[0043] The JK trigger is set here because when performing AC (AC) coupling mode, the AC coupling of the data link introduces the capacitor and terminal resistance of the high-pass filter effect. Usually, when working in the high baud rate mode, it can not be affected by the filtering effect. If a low transmission rate is used or the data link is allowed to maintain a constant horizontal protocol for a long time, the AC coupling capacitor must be increased to reduce the cut-off frequency, so that the AC coupling circuit can work normally, but the selection range of the AC coupling capacitor is always limited, so the circuit proposed in the present embodiment is selected, that is, the reset of the receiving waveform using the JK trigger can solve this problem. The receiving circuit is composed of RS485 / 422 receiving chip + JK trigger, and the jump edge of the received signal is converted into a reconstructed data signal. This method is used to remove the restriction on the transmission speed. Under a relatively small capacitance, any low transmission rate can be reconstructed by judging the edge peak of the capacitor charge and discharge, and even long period static (constant) data, so that the RS485 / 422 interface chip can work under the full baud rate mode and can work under the multi-protocol content.

[0044] Third, when working in RS422 full-duplex mode: the output of the mode switching pin MODE is also high level, and the RS232 interface chip is still in the disabled state. At this time, the sending and receiving states of the circuit are still controlled by the monostable trigger. The working principle is the same as the second point. The RS485 / 422 interface chip works in full-duplex mode, such as Figure 3 In the schematic diagram of the multi-protocol transceiver circuit for industrial applications shown in FIG, the A / B pins of the RS485 / 422 transmitting chip correspond to the output signal T+_422 / T-_422, and the A / B pins of the RS485 / 422 receiving chip correspond to the input signal R+_422 / R-_422.

[0045] In one embodiment, Figure 3 As shown, U1 is a JK trigger, U2 is a RS485 / 422 receiving chip, U3 is a monostable trigger constructed by a 555 timer, U4 is a RS485 / 422 sending chip, and U5 is a RS232 interface chip. The following is a principle description:

[0046] (1) By default, the J and K pins of the JK trigger U1 are connected to the working power supply VCC to pull up the potential. When the output pin OUT of the monostable trigger U3 is at a high level, the pins of the JK trigger U1 are When the output pin OUT of the monostable trigger U3 is at a low level, the pin of the JK trigger U1 is reset to the initial state. The output pin Q of JK trigger U1 is high level, and the working mode is trigger mode. The negative transition edge of the pin flips. The source is the data receiving pin RO of the RS485 / 422 receiving chip U2.

[0047] For example, when the transmission rate is very low and the protocol data sent is a string of 1s, the data bus of the RS485 / 422 receiving chip U2 will always be in the state of A high and B low. After isolation by the AC coupling capacitor (i.e., capacitor C3, capacitor C4, capacitor C5, and capacitor C6), the subsequent part of the 1 data will be lost due to filtering out the DC component in the received data. However, after using the reconstruction circuit of the JK trigger U1 in this embodiment, when the output pin Q of the JK trigger U1 outputs the first bit of 1 data, it detects the level conversion on the data bus of the RS485 / 422 receiving chip U2, and the output pin Q completes the flip. When the next jump edge appears (i.e., the protocol transmission of 1 data is completed and becomes 0 data), the next flip will occur, thereby realizing the reconstruction of the received data, so that it can run at any baud rate.

[0048] (2) The monostable trigger U3 is used to realize the automatic transmission direction control in RS485 mode and RS422 mode. The start frame of the data sent by the main control unit (such as MCU) is used as the trigger source. Since the monostable trigger U3 is edge-triggered, the response speed will be faster than the commonly used transistor automatic direction control circuit. Therefore, it can provide the automatic adaptation function of the transmission direction at full baud rate when applied here. The monostable trigger time is determined by the external resistor R1 and capacitor C1. The parameters of these two passive components can be adjusted to meet the data transmission requirements at full baud rate.

[0049] (3) When operating in RS485 mode, the RS485 / 422 receiving chip U2 can directly monitor the A / B bus to obtain received data; when operating in RS422 mode, the RS485 / 422 receiving chip U2 can directly monitor the R+_422 / R-_422 bus to obtain received data. The RS485 / 422 transmitting chip U4 sends data to the A / B bus regardless of whether it is operating in RS485 mode or RS422 mode. The RS232 interface chip U5 is enabled to achieve the switching of different protocol operation modes as described above.

[0050] In one embodiment, Figure 3As shown, the first AC coupling unit includes a resistor R2, a capacitor C3 and a capacitor C4, and the second AC coupling unit includes a resistor R3, a capacitor C5 and a capacitor C6. One end of the capacitor C3 is connected to the first input pin of the receiving end of the RS232 interface chip, the other end of the capacitor C3 is connected to the other end of the capacitor C4 through the resistor R2, and one end of the capacitor C4 is connected to the second input pin of the receiving end of the RS232 interface chip. The output pins of the transmitting end of the RS485 / RS422 transmitting chip and the RS485 / RS422 receiving chip are connected between the capacitor C3 and the resistor R2. One end of the capacitor C5 is connected to the first output pin of the transmitting end of the RS232 interface chip, the other end of the capacitor C5 is connected to the other end of the capacitor C6 through the resistor R3, and one end of the capacitor C6 is connected to the second output pin of the transmitting end of the RS232 interface chip. The input pins of the receiving end of the RS485 / RS422 transmitting chip and the RS485 / RS422 receiving chip are connected between the capacitor C5 and the resistor R3.

[0051] (4), capacitors C3, C4, C5 and C6 are AC coupling capacitors. The use of the coupling capacitors can prevent the data bus voltage values ​​between different protocols from interfering with each other, thereby being able to adapt to a higher data bus voltage. In addition, thanks to the reconstruction of the JK flip-flop U1 in point (1), data transmission can be performed within the full baud rate range.

[0052] In one embodiment, the monostable trigger unit is a monostable trigger constructed by a 555 timer. It can be understood that in this embodiment, the monostable trigger circuit constructed by a 555 timer can be directly adopted, so that the circuit of the above-mentioned industrial application multi-protocol transceiver circuit 100 can be further simplified by means of the simple circuit structure and reliability of the monostable trigger, while improving its circuit reliability.

[0053] In one embodiment, an industrial control device is further provided, including a main control unit and the industrial application multi-protocol transceiver circuit 100 in any one of the above embodiments.

[0054] It can be understood that for the specific explanation of the industrial application multi-protocol transceiver circuit 100 in the industrial control equipment embodiment, reference can be made to the corresponding explanations of the various embodiments of the industrial application multi-protocol transceiver circuit 100 in the above text, and no further description is given here. In addition to the main control unit and the industrial application multi-protocol transceiver circuit 100, the above-mentioned industrial control equipment may also include other existing auxiliary modules in the art, which can be understood in the same way according to the existing structures of various types of industrial control equipment in the art.

[0055] The above-mentioned industrial control equipment, by applying the above-mentioned industrial application multi-protocol transceiver circuit 100, is designed with a transceiver circuit composed of an RS232 interface chip, an RS485 / RS422 transmission chip, an RS485 / RS422 receiving chip, a monostable trigger unit, a bistable trigger unit, a first AC coupling unit and a second AC coupling unit, and provides a four-wire interface to the outside to realize a multi-protocol type adaptive transceiver circuit with two RS232 communications, one half-duplex or full-duplex RS485 communication, and one RS422 communication. The interface protocol mode in which the transceiver circuit works can be controlled by a mode switching level, and the data transmission direction is automatically controlled by the monostable trigger unit. At the same time, the reconstruction of data reception is realized by the bistable trigger unit. In conjunction with the application of two AC coupling units, AC-coupled data transmission under the full baud rate range is realized.

[0056] Compared with traditional technologies, the use of more streamlined external interfaces effectively realizes the adaptation of RS232, RS485 and RS422 protocol types, thereby saving system resources of the main controller, and also reducing the number of external interfaces of the transceiver circuit, making the overall industrial control equipment of the application smaller in size and more functionally focused.

[0057] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0058] The above embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of protection of the invention. It should be pointed out that, for a person of ordinary skill in the art, several modifications and improvements can be made without departing from the concept of the present application, and all of them belong to the scope of protection of the present application. Therefore, the scope of protection of the present application shall be subject to the attached claims.

Claims

1. A multi-protocol transceiver circuit for industrial applications, characterized in that: It includes an RS232 interface chip, an RS485 / RS422 transmission chip, an RS485 / RS422 receiving chip, a monostable trigger unit, a bistable trigger unit, a first AC coupling unit and a second AC coupling unit; The first input pin and the second input pin of the transmitting end of the RS232 interface chip are respectively used to connect the universal transmitting pin of the main control unit and the RS232 dedicated transmitting pin, the first output pin and the second output pin of the receiving end of the RS232 interface chip are respectively used to connect the universal receiving pin of the main control unit and the RS232 dedicated receiving pin, the first output pin and the second output pin of the transmitting end of the RS232 interface chip, and the first input pin and the second input pin of the receiving end are respectively led out and used to connect an external device; The input pin of the transmitting end of the RS485 / RS422 transmitting chip is used to connect to the universal transmitting pin of the main control unit, the output pin of the transmitting end and the input pin of the receiving end of the RS485 / RS422 transmitting chip are respectively connected to the first output pin of the transmitting end and the first input pin of the receiving end of the RS232 interface chip through the first AC coupling unit, and the enable pin of the RS485 / RS422 transmitting chip is connected to the output end of the monostable trigger unit; The output pin of the receiving end of the RS485 / RS422 receiving chip is connected to the clock input end of the bistable trigger unit, the output pin of the transmitting end of the RS485 / RS422 receiving chip is connected to the output pin of the transmitting end of the RS485 / RS422 transmitting chip and is connected to the second output pin of the transmitting end of the RS232 interface chip through the second AC coupling unit, the input pin of the receiving end of the RS485 / RS422 receiving chip is connected to the input pin of the receiving end of the RS485 / RS422 transmitting chip and is connected to the second input pin of the receiving end of the RS232 interface chip through the second AC coupling unit, and the enable pin of the RS485 / RS422 receiving chip is connected to the output end of the monostable trigger unit; The output end of the bistable trigger unit is used to be connected to the universal receiving pin of the main control unit, the reset pin of the bistable trigger unit is connected to the output end of the monostable trigger unit through a logic NOT gate, the trigger end of the monostable trigger unit is used to be connected to the universal sending pin of the main control unit, the reset pin of the monostable trigger unit and the enable pin of the RS232 interface chip are used to receive the mode switching level; the mode switching level is a high level or a low level, which is used to control the industrial application multi-protocol transceiver circuit to work in RS232 mode or RS485 / 422 mode respectively.

2. The industrial application multi-protocol transceiver circuit according to claim 1, characterized in that: The bistable trigger unit is a JK trigger.

3. The industrial application multi-protocol transceiver circuit according to claim 1, characterized in that: The monostable trigger unit is a monostable trigger constructed by a 555 timer.

4. The industrial application multi-protocol transceiver circuit according to any one of claims 1 to 3, characterized in that: The reset pin of the monostable trigger unit and the enable pin of the RS232 interface chip are respectively used to connect to the mode switching pin of the main control unit.

5. The industrial application multi-protocol transceiver circuit according to claim 4, characterized in that: The first AC coupling unit includes a resistor R2, a capacitor C3 and a capacitor C4, and the second AC coupling unit includes a resistor R3, a capacitor C5 and a capacitor C6; One end of the capacitor C3 is connected to the first input pin of the receiving end of the RS232 interface chip, the other end of the capacitor C3 is connected to the other end of the capacitor C4 through the resistor R2, one end of the capacitor C4 is connected to the second input pin of the receiving end of the RS232 interface chip, and the output pins of the transmitting end of the RS485 / RS422 transmitting chip and the RS485 / RS422 receiving chip are connected between the capacitor C3 and the resistor R2; One end of the capacitor C5 is connected to the first output pin of the transmitting end of the RS232 interface chip, the other end of the capacitor C5 is connected to the other end of the capacitor C6 through the resistor R3, one end of the capacitor C6 is connected to the second output pin of the transmitting end of the RS232 interface chip, and the input pins of the receiving ends of the RS485 / RS422 transmitting chip and the RS485 / RS422 receiving chip are connected between the capacitor C5 and the resistor R3.

6. An industrial control device, characterized in that: The invention comprises a main control unit and the industrial application multi-protocol transceiver circuit according to any one of claims 1 to 5.

Citation Information

Cited By

  • On-off control method and device of alternating current solid state power controller

    CN120357879A