CN112491657B - Communication connection method, device and storage medium based on serial port communication - Google Patents

Communication connection method, device and storage medium based on serial port communication Download PDF

Info

Publication number
CN112491657B
CN112491657B CN202011361619.7A CN202011361619A CN112491657B CN 112491657 B CN112491657 B CN 112491657B CN 202011361619 A CN202011361619 A CN 202011361619A CN 112491657 B CN112491657 B CN 112491657B
Authority
CN
China
Prior art keywords
equipment
communication
data
address
same
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.)
Active
Application number
CN202011361619.7A
Other languages
Chinese (zh)
Other versions
CN112491657A (en
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.)
Gree Electric Appliances Inc of Zhuhai
Original Assignee
Gree Electric Appliances Inc of Zhuhai
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 Gree Electric Appliances Inc of Zhuhai filed Critical Gree Electric Appliances Inc of Zhuhai
Priority to CN202011361619.7A priority Critical patent/CN112491657B/en
Publication of CN112491657A publication Critical patent/CN112491657A/en
Application granted granted Critical
Publication of CN112491657B publication Critical patent/CN112491657B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0805Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
    • H04L43/0811Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking connectivity
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • G06F13/4282Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • H04L67/025Protocols based on web technology, e.g. hypertext transfer protocol [HTTP] for remote control or remote monitoring of applications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/03Protocol definition or specification 

Abstract

The invention provides a communication connection method, a device and a storage medium based on serial communication, wherein a communication network comprises more than two equipment systems, and each equipment system comprises more than two different types of equipment; the device addresses of the two or more different types of devices in each device system are the same; all the devices in the communication network are connected to a communication bus; the device types of the devices included in each of the device systems are the same; the equipment in the communication network communicates based on the equipment address; no communication is made between the two systems of devices. The scheme provided by the invention CAN solve the problem of data interaction handshake among a plurality of devices, and CAN replace a CAN communication data interaction mode.

Description

Communication connection method, device and storage medium based on serial port communication
Technical Field
The invention relates to the field of control, in particular to a communication connection method and device based on serial port communication and a storage medium.
Background
In order to meet different requirements, the controller in the air conditioning system adopts a modular design, and performs data interaction through communication networking, as shown in fig. 1. In the communication network, equipment is more, CAN communication is adopted as an optimal scheme according to the traditional design experience, and no scheme capable of replacing CAN communication exists at present.
Disclosure of Invention
The main purpose of the present invention is to overcome the above-mentioned defects in the prior art, and to provide a communication connection method, device and storage medium based on serial communication, so as to solve the problem that no solution capable of replacing CAN communication exists in the prior art.
The invention provides a communication connection method based on serial communication on one hand, the communication network includes more than two equipment systems, each equipment system includes more than two different types of equipment; the device addresses of the two or more different types of devices in each device system are the same; all the devices in the communication network are connected to a communication bus; the device types of the devices included in each of the device systems are the same; the equipment in the communication network communicates based on the equipment address; no communication is carried out between the two equipment systems; the communication connection method comprises the following steps: after the device is powered on, acquiring the device address of the device; the device is any one of more than two devices with different types in any device system; transmitting a data frame to a device having the same device address as the device to which the data frame belongs; the data frame carries the device type of the device; judging whether a response frame returned by equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is received; if the response frame is received, determining that the equipment which has the same equipment address as the equipment and is different in equipment type is successfully connected in a communication mode; and if the response frame returned by the equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is not received, determining that the communication fault occurs.
Optionally, the method further comprises: the method comprises the steps of continuously judging whether data sent to equipment to which the communication bus belongs exist or not within preset time; if the data sent to the equipment is judged not to exist, the communication fault is determined to occur; if the data sent to the equipment is judged, judging the data source of the data; and determining whether the communication connection between the equipment and other equipment is successful according to the data source.
Optionally, determining whether the communication connection between the device and the other device is successful according to the data source includes: if the data are from the equipment with the same type as the equipment, determining that a communication fault occurs; and if the data is from equipment of which the type is different from that of the equipment, determining that the communication connection with the data source equipment is successful.
Optionally, the communication network comprises an air conditioning system communication network; each of the two or more equipment systems includes a display panel and an internal machine main board.
The invention provides a communication connecting device based on serial port communication, which belongs to a communication network comprising more than two equipment systems, wherein each equipment system comprises more than two different types of equipment; the device addresses of the two or more different types of devices in each device system are the same; all the devices in the communication network are connected to a communication bus; the device types of the devices included in each of the device systems are the same; the equipment in the communication network communicates based on the equipment address; no communication is carried out between the two equipment systems; the communication connecting device comprises: the device comprises an acquisition unit, a processing unit and a control unit, wherein the acquisition unit is used for acquiring the self device address of the device after the device is powered on; the device is any one of more than two devices with different types in any device system; a transmitting unit, configured to transmit a data frame to a device having the same device address as a device to which the data frame belongs; the data frame carries the device type of the device; the first judgment unit is used for judging whether a response frame returned by equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is received; the first determining unit is used for determining that the equipment which has the same address as the equipment and has different equipment types is successfully communicated if the response frame is received; and if the response frame returned by the equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is not received, determining that the communication fault occurs.
Optionally, the method further comprises: the second judgment unit is used for continuously judging whether data sent to the equipment to which the communication bus belongs exist or not within preset time; a second determining unit, configured to determine that a communication fault occurs if the second determining unit determines that data that is not sent to the device to which the second determining unit belongs is not received; the second determining unit is further configured to: if the data sent to the equipment is judged, judging the data source of the data; the second determining unit is further configured to: and determining whether the communication connection between the equipment and other equipment is successful according to the data source.
Optionally, the determining, by the second determining unit, whether the communication connection between the device and the other device is successful according to the data source includes: if the data are from the equipment with the same type as the equipment, determining that a communication fault occurs; and if the data is from equipment of which the type is different from that of the equipment, determining that the communication connection with the data source equipment is successful.
Optionally, the communication network comprises an air conditioning system communication network; each of the two or more appliance systems includes a display panel and an internal unit main board.
A further aspect of the invention provides a storage medium having stored thereon a computer program which, when executed by a processor, carries out the steps of any of the methods described above.
According to the technical scheme of the invention, based on serial communication and self-defined protocol communication, the problem of data interaction handshake among a plurality of devices in serial communication CAN be solved, and a CAN communication data interaction mode CAN be replaced.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this specification, illustrate embodiments of the invention and together with the description serve to explain the invention and not to limit the invention. In the drawings:
FIG. 1 is a communication network topology diagram of an air conditioning system;
FIG. 2 is a diagram of a network of communication nodes, as an example of a display panel;
FIG. 3 is a schematic method diagram of an embodiment of a serial communication-based communication connection method according to the present invention;
FIG. 4 is a schematic diagram of a communication connection method based on serial communication according to another embodiment of the present invention;
FIG. 5 is a schematic diagram of a communication connection method based on serial communication according to an embodiment of the present invention;
FIG. 6 is a block diagram of an embodiment of a serial communication based communication connection device according to the present invention;
fig. 7 is a block diagram of another embodiment of a serial communication-based communication connection device according to the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be clearly and completely described below with reference to the specific embodiments of the present invention and the accompanying drawings. It is to be understood that the described embodiments are merely exemplary of the invention, and not restrictive of the full scope of the invention. All other embodiments, which can be obtained by a person skilled in the art without making any creative effort based on the embodiments in the present invention, belong to the protection scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Moreover, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The invention provides a communication connection method and device based on serial port communication. The method can be used in a communication network of a plurality of devices. The communication network comprises more than two equipment systems, and each equipment system comprises more than two different types of equipment; the device addresses of the two or more different types of devices in each of the device systems are the same. All the devices in the communication network are connected to a communication bus; the types of devices included in the respective device systems of the two or more device systems are the same. And data interaction is not carried out between the two equipment systems.
For example, the communication connection method may be used for an air conditioning system communication network. The air conditioning system communication network comprises; more than two equipment systems, wherein each equipment system comprises a display panel and an internal machine mainboard; the display board in each system is the same as the equipment address of the internal machine mainboard.
Fig. 1 is a communication network topology diagram illustrating an air conditioning system. As shown in fig. 1, taking the communication network of the air conditioning system as an example, the communication network adopts serial communication. There are 6 devices in this communication network, wherein display panel 1, internal machine mainboard 1 constitute system 1, display panel 2, internal machine mainboard 2 constitute system 2, the data interactive relation between each device is as follows:
the outer machine mainboard needs to perform data interaction with the display panel 1, the inner machine mainboard 1, the display panel 2, the inner machine mainboard 2 and the debugger. The display panel 1 needs to perform data interaction with the external machine mainboard and the internal machine mainboard 1. The internal machine mainboard 1 needs to perform data interaction with the external machine mainboard, the display panel 1 and the debugger. The display panel 2 needs to perform data interaction with the external machine mainboard and the internal machine mainboard 1. The internal machine mainboard 2 needs to perform data interaction with the external machine mainboard, the display panel 1 and the debugger. The debugger needs to perform data interaction with the external machine mainboard, the internal machine mainboard 1 and the internal machine mainboard 2. The data interaction adopts serial port communication.
Fig. 2 is a diagram of a network of communication nodes, using a display panel as an example. As shown in fig. 2, the display panel needs to interact with the external and internal motherboard. The invention utilizes the equipment address to carry out data interaction, for example, an external machine mainboard and a debugger are unique in the network, and the addresses are fixed as ID1 and ID 2; the display panel and the internal machine mainboard are repeated by the same equipment and need to be provided with addresses, the display panel is arranged through the operation window, and the internal machine mainboard is arranged through dialing.
The devices in the communication network communicate based on device addresses. Specifically, when the data sending end device sends out data, the receiving end device is designated, and the address information of the receiving end device is informed. The data receiving end equipment receives the data appointed to be received by the data receiving end equipment on the communication bus, and informs the opposite side of successful data reception in the same form after successful data reception (after the receiving equipment successfully receives the data, the data receiving end equipment sends a frame of data to the data sending end and informs the opposite side of successful data reception). In the communication network, if the equipment type is unique and the equipment address is fixed, the communication has no problem; if more than two devices with the same device type are needed to be set with addresses, communication failure between the devices can be caused after the addresses of the devices are changed. For example, referring to the communication network diagram shown in fig. 1, the display panel or the internal motherboard needs to set an apparatus address to ensure uniqueness within the network, so that the display panel or the internal motherboard does not know where to send its data when serving as a data sending end apparatus after the apparatus address is changed.
According to the technical scheme of the invention, data interaction cannot occur between any two equipment systems. For example, referring to fig. 1, system 1 and system 2 do not have data interaction, and thus the device address of the display panel and the device address of the internal unit main board are set to the same device address.
Fig. 3 is a schematic method diagram of an embodiment of a serial communication-based communication connection method provided by the present invention.
As shown in fig. 3, according to an embodiment of the present invention, the communication connection method at least includes step S110, step S120, step S130, step S140 and step S150.
Step S110, after the device is powered on, the device address of the device itself is obtained.
The device is any one of more than two different types of devices included in any one of the device systems.
Step S120, sending the data frame to the device with the same device address as the device to which the data frame belongs.
The data frame carries the device type of the device.
Step S130, determining whether a response frame returned by a device with the same device address and a different device type as the device to which the device belongs is received.
Step S140, if the response frame is received, it is determined that the device communication connection is successful, where the device address is the same as the device address of the device to which the device belongs and the device type is different.
Step S150, if a response frame returned by a device having the same device address as the device to which the device belongs and a different device type is not received, it is determined that a communication failure occurs.
Specifically, the device address of the device itself is read, and the data frame carrying the device type of the device is sent to the device having the same device address as the device. If a response frame returned by equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is received, determining that the equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is in communication connection successfully; and if the response frame returned by the equipment with the same equipment address and different equipment types as the affiliated equipment is not received, determining that the communication fault occurs.
Fig. 4 is a schematic method diagram of another embodiment of a serial communication-based communication connection method provided in the present invention.
As shown in fig. 4, according to another embodiment of the present invention, the communication method further includes step S160, step S170, step S180, and step S190.
Step S160, determining whether there is data to be sent to the device on the communication bus for a preset time.
And step S170, if the data sent to the equipment is judged not to exist, the communication fault is determined to occur.
For example, it is determined whether the bus has data to send to the device for T seconds. If not, the communication line is not connected or the equipment is not connected to the network, and the communication fault is determined to occur. Optionally, the display panel reports a communication failure.
And step S180, if the data sent to the equipment is judged, judging the data source of the data.
And step S190, determining whether the communication connection between the equipment and other equipment is successful according to the data source.
Specifically, the source of the data may be determined by the device address or the device type. For example, the device addresses of the main board and the debugger of the air conditioner outdoor unit are fixed, and the device type of the opposite side can be known by judging the device address of the data source without further judgment. If the device is a display panel or an internal machine mainboard, the type of the device carried in the data can be judged.
If the data is from the equipment with the same type as the equipment of the equipment, determining that a communication fault occurs; and if the data is from equipment of which the type is different from that of the equipment, determining that the communication connection with the data source equipment is successful.
Because the same type of equipment is in different equipment systems, the two equipment systems do not communicate with each other; and the equipment in the equipment system can send data frames to equipment with the same address and different data types as the equipment address, so that the equipment does not receive the data sent by the equipment with the same type, if the data source has the data sent by the equipment with the same type to the equipment, the equipment address of the equipment is not set or the setting is failed, the equipment needs to be reset, and the display board reports the communication failure. If no equipment of the same type sends data to the equipment in the data source, the equipment address is successfully set, the communication connection with the equipment of the data source is successful, and a response frame of successful communication is sent to the equipment.
For clearly explaining the technical solution of the present invention, the following describes an execution flow of the serial communication based communication connection method provided by the present invention with a specific embodiment.
Fig. 5 is a schematic method diagram of a serial communication-based communication connection method according to an embodiment of the present invention. As shown in fig. 5, the address of the predetermined display panel is the same as the address of the internal device main board. After the display panel or the internal machine mainboard is powered on, the own device address N is firstly acquired, and then a data frame is tried to be sent to the device with the same address as the own device address, wherein the data frame carries the own device type. And (4) judging whether data sent to the bus exist on the bus or not for T seconds, if not, indicating that the communication line is not connected or the equipment is not connected to the network, and displaying the communication fault on a display board. If yes, further judging the data source. Because the equipment addresses of the external machine mainboard and the debugger are fixed, the type of the equipment of the opposite side can be known by judging the source address of the data. If the data source has data sent by the same type of equipment to the equipment, the address of the equipment is not set, or the equipment needs to be reset after the setting is failed, if the data source has no data sent by the same type of equipment to the equipment, the address of the equipment is successfully set, and a response frame of successful communication is sent. Further judging whether the equipment needing to communicate with the equipment sends response frames or not, if not, indicating that the communication exceeds T seconds or the communication line is disconnected, and displaying the communication fault on a display board; if yes, the address is set according to the specification, normal communication can be carried out, and communication handshake is successful.
The invention also provides a communication connecting device based on serial port communication.
Fig. 6 is a block diagram of a serial communication connection device according to an embodiment of the present invention. As shown in fig. 6, the communication connection device 100 includes: an acquisition unit 110, a transmission unit 120, a first judgment unit 130 and a first determination unit 140.
The obtaining unit 110 is configured to obtain a device address of the device after the device is powered on; the device is any one of more than two different types of devices included in any one of the device systems. The sending unit 120 is configured to send a data frame to a device having the same device address as the device to which the data frame belongs; the data frame carries the device type of the device. The first judging unit 130 is configured to judge whether a response frame returned by a device having the same device address as the device to which the first judging unit belongs and a different device type is received; the first determining unit 140 is configured to determine that the communication connection with the device having the same device address and the different device type is successful if the response frame is received; and if the response frame returned by the equipment with the same equipment address and different equipment types as the affiliated equipment is not received, determining that the communication fault occurs.
The device is any one of more than two different types of devices included in any one of the device systems. The data frame carries the device type of the device. Specifically, the obtaining unit 110 reads the device address of the device itself, and the sending unit 120 sends the data frame carrying the device type of the device to the device having the same device address as the device. The first determining unit 130 determines whether a response frame returned by a device having the same device address as the device to which the first determining unit belongs and having a different device type is received, and if a response frame returned by a device having the same device address as the device to which the first determining unit 140 determines that the communication connection of the device having the same device address as the device to which the first determining unit belongs and having a different device type is successful; if a response frame returned by a device having the same device address as the device to which the device belongs and a different device type is not received, the first determining unit 140 determines that a communication failure occurs.
Fig. 7 is a block diagram of another embodiment of a serial communication connection device according to the present invention. As shown in fig. 7, the communication connection device 100 further includes a second determination unit 150 and a second determination unit 160.
The second judging unit 150 is configured to continuously judge whether there is data sent to the device on the communication bus for a preset time; the second determining unit 160 is configured to determine that a communication failure occurs if the second determining unit determines that there is no data sent to the device to which the second determining unit belongs.
For example, it is determined whether the bus has data to send to the device for T seconds. If not, the communication line is not connected or the equipment is not connected to the network, and the communication fault is determined to occur. Optionally, the display panel reports communication failures.
The second determining unit 150 is further configured to: if the data sent to the equipment is judged, judging the data source of the data; the second determining unit 160 is further configured to: and determining whether the communication connection between the equipment and other equipment is successful according to the data source.
Specifically, the second determining unit 150 may determine the data source according to a device address or a device type. For example, the device addresses of the main board and the debugger of the air conditioner outdoor unit are fixed, and the device type of the opposite side can be known by judging the device address of the data source without further judgment. If the device type is the display panel or the internal machine mainboard, the device type carried in the data can be judged.
The second determining unit 160 determines whether the communication connection between the device and the other device is successful according to the data source, which specifically includes: if the data is from the equipment with the same type as the equipment of which the data belongs, determining that a communication fault occurs; and if the data is from equipment of which the type is different from that of the equipment, determining that the communication connection with the data source equipment is successful.
Because the same type of equipment is in different equipment systems, the two equipment systems do not communicate with each other; and the equipment in the equipment system can send data frames to the equipment with the same address and different data types as the equipment address, so the equipment does not receive the data sent by the equipment with the same type as the equipment, if the data source has the data sent by the equipment with the same type to the equipment, the equipment address of the equipment is not set or the setting is failed, the equipment needs to be reset, and the display board reports the communication failure. If no equipment of the same type sends data to the equipment in the data source, the equipment address is successfully set, the communication connection with the equipment of the data source is successful, and a response frame of successful communication is sent to the equipment.
In the communication network, if the equipment type is unique and the equipment address is fixed, the communication has no problem; if the types of the devices are repeated, the addresses need to be set, and communication failure between the devices can be caused after the addresses of the devices are changed. As shown in the communication network topology diagram of fig. 1, the external unit motherboard and the debugger are unique in the network, and the addresses are fixed as ID1 and ID 2; the display panel and the internal machine mainboard have the same type of equipment repetition, the address needs to be set, and the data communication failure between the display panel and the mainboard can be caused due to the change of the display panel or the mainboard address. For example, data communication is performed between the display panel 1, the internal machine main board 1, the display panel 2, and the internal machine main board 2, the default address of the display panel 1, 2 is 0X40, the default address of the internal machine main board 1, 2 is 0X01, and the display panel 1 needs to perform data communication with the internal machine main board 1 and the external machine main board; display panel 2 needs to carry out data communication with interior mainboard 2, outer quick-witted mainboard, and display panel 1, interior mainboard 1, display panel 2, interior mainboard 2, outer quick-witted mainboard are on same bus, and when display panel 1 sent communication data for interior mainboard 1, if the address of interior mainboard 2 does not set up, display panel 1 will all be received to interior mainboard 1, interior mainboard 2 data, and interior mainboard 2 is actually the data that need not receive display panel 1. After the address of the internal machine mainboard 2 is set, the problem can be solved,
the invention also provides a storage medium corresponding to the communication connection method based on serial port communication, wherein a computer program is stored on the storage medium, and the computer program is used for realizing the steps of any one of the methods when being executed by a processor.
Therefore, the scheme provided by the invention is based on serial port communication, CAN solve the problem of data interaction handshake among a plurality of devices, and CAN replace a CAN communication data interaction mode.
The functions described herein may be implemented in hardware, software executed by a processor, firmware, or any combination thereof. If implemented in software executed by a processor, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Other examples and implementations are within the scope and spirit of the invention and the following claims. For example, due to the nature of software, the functions described above may be implemented using software executed by a processor, hardware, firmware, hardwiring, or a combination of any of these. In addition, each functional unit may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
In the embodiments provided in the present application, it should be understood that the disclosed technical content can be implemented in other manners. The above-described apparatus embodiments are merely illustrative, and for example, the division of the units may be a logical division, and in actual implementation, there may be another division, for example, multiple units or components may be combined or may be integrated into another system, or some features may be omitted, or may not be executed. In addition, the shown or discussed coupling or direct coupling or communication connection between each other may be an indirect coupling or communication connection through some interfaces, units or modules, and may be electrical or in other forms.
The units described as separate parts may or may not be physically separate, and the parts serving as the control device may or may not be physical units, may be located in one place, or may be distributed on a plurality of units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk, and various media capable of storing program codes.
The above description is only an example of the present invention, and is not intended to limit the present invention, and it is obvious to those skilled in the art that various modifications and variations can be made in the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the scope of the claims of the present invention.

Claims (5)

1. A communication connection method based on serial communication is characterized in that a communication network comprises more than two equipment systems, and each equipment system comprises more than two different types of equipment; the device addresses of the two or more different types of devices in each device system are the same; all the devices in the communication network are connected to a communication bus; the device types of the devices included in each of the device systems are the same; the equipment in the communication network communicates based on the equipment address; no communication is carried out between the two equipment systems;
the communication connection method comprises the following steps:
after the device is powered on, acquiring the device address of the device; the equipment is any one of more than two different types of equipment in any equipment system;
sending a data frame to a device with the same address as the device to which the data frame belongs; the data frame carries the device type of the device;
judging whether a response frame returned by equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is received;
if the response frame is received, determining that the equipment which has the same equipment address as the equipment and is different in equipment type is successfully connected in a communication mode;
if a response frame returned by equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is not received, determining that a communication fault occurs;
the preset time is continued to judge whether data sent to the equipment is available on the communication bus or not;
if the data sent to the equipment is judged not to exist, the communication fault is determined to occur;
if the data sent to the equipment is judged, judging the data source of the data;
determining whether the communication connection between the equipment and other equipment is successful according to the data source, including:
if the data are from the equipment with the same type as the equipment, determining that a communication fault occurs;
and if the data are sourced from equipment of which the equipment type is different from that of the equipment, determining that the communication connection with the data source equipment is successful.
2. The method of claim 1, wherein the communication network comprises an air conditioning system communication network; each of the two or more appliance systems includes a display panel and an internal unit main board.
3. A communication connecting device based on serial port communication is characterized in that a communication network comprises more than two equipment systems, and each equipment system comprises more than two different types of equipment; the device addresses of the two or more different types of devices in each device system are the same; all the devices in the communication network are connected to a communication bus; the device types of the devices included in each of the device systems are the same; the equipment in the communication network communicates based on the equipment address; no communication is carried out between the two equipment systems;
the communication connecting device comprises:
the device comprises an acquisition unit, a processing unit and a control unit, wherein the acquisition unit is used for acquiring the self device address of the device after the device is powered on; the equipment is any one of more than two different types of equipment in any equipment system;
a transmitting unit, configured to transmit a data frame to a device having the same device address as a device to which the data frame belongs; the data frame carries the device type of the device;
the first judging unit is used for judging whether a response frame returned by equipment with the same address and different types as the equipment to which the equipment belongs is received;
a first determining unit, configured to determine that the communication connection with the device having the same address and a different device type is successful if the response frame is received;
if a response frame returned by equipment with the same equipment address and different equipment types as the equipment to which the equipment belongs is not received, determining that a communication fault occurs;
the second judgment unit is used for continuously judging whether data sent to the equipment to which the communication bus belongs exist or not within preset time;
a second determining unit, configured to determine that a communication failure occurs if the second determining unit determines that there is no data sent to the device to which the second determining unit belongs;
the second determining unit is further configured to: if the data sent to the equipment is judged, judging the data source of the data;
the second determining unit is further configured to: determining whether the communication connection between the equipment and other equipment is successful according to the data source, including:
if the data is from the equipment with the same type as the equipment of which the data belongs, determining that a communication fault occurs;
and if the data are sourced from equipment of which the equipment type is different from that of the equipment, determining that the communication connection with the data source equipment is successful.
4. The apparatus of claim 3, wherein the communication network comprises an air conditioning system communication network; each of the two or more equipment systems includes a display panel and an internal machine main board.
5. A storage medium, having stored thereon a computer program which, when being executed by a processor, carries out the steps of the method of any one of claims 1-2.
CN202011361619.7A 2020-11-27 2020-11-27 Communication connection method, device and storage medium based on serial port communication Active CN112491657B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011361619.7A CN112491657B (en) 2020-11-27 2020-11-27 Communication connection method, device and storage medium based on serial port communication

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011361619.7A CN112491657B (en) 2020-11-27 2020-11-27 Communication connection method, device and storage medium based on serial port communication

Publications (2)

Publication Number Publication Date
CN112491657A CN112491657A (en) 2021-03-12
CN112491657B true CN112491657B (en) 2022-07-15

Family

ID=74936544

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011361619.7A Active CN112491657B (en) 2020-11-27 2020-11-27 Communication connection method, device and storage medium based on serial port communication

Country Status (1)

Country Link
CN (1) CN112491657B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111586077A (en) * 2020-05-28 2020-08-25 珠海格力智能装备有限公司 Data interaction method and device and electronic equipment

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100542105C (en) * 2007-03-13 2009-09-16 杭州华三通信技术有限公司 Method that system mode is obtained in the multicomputer system and device
CN101498617A (en) * 2008-02-03 2009-08-05 华夏龙晖(北京)汽车电子科技有限公司 Function detection system and method for electric-controlled unit
CN101986738B (en) * 2010-11-09 2015-08-19 中兴通讯股份有限公司 The method of feedback reception end state, system and server
EP2515507A1 (en) * 2011-04-19 2012-10-24 Siemens Aktiengesellschaft Auto-configuration of network devices
CN102833732B (en) * 2012-07-25 2017-03-29 中兴通讯股份有限公司 System, data card and its implementation that a kind of IPv6 addresses stateless is automatically configured
US10691628B2 (en) * 2016-05-06 2020-06-23 Quanta Computer Inc. Systems and methods for flexible HDD/SSD storage support

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111586077A (en) * 2020-05-28 2020-08-25 珠海格力智能装备有限公司 Data interaction method and device and electronic equipment

Also Published As

Publication number Publication date
CN112491657A (en) 2021-03-12

Similar Documents

Publication Publication Date Title
CN110762604B (en) Indoor unit, pairing method and device of indoor unit and wired controller, storage medium and air conditioner
CN105471678A (en) Method and system for detecting networking failure reason of household appliance and mobile terminal
CN111343019B (en) Reconnection method, reconnection device and storage medium
CN111211955B (en) Method for distributing slave node address and node management system
CN113746821A (en) Intelligent device control method and device, storage medium and electronic device
CN112491657B (en) Communication connection method, device and storage medium based on serial port communication
CN105553762A (en) Communication method and communication system between domestic appliance and mobile terminal and corresponding devices
CN108662722B (en) Signal transmission method, system, device, storage medium and electronic device
CN112178881B (en) Self-checking method and device of RS485 network
CN112460747B (en) Communication control method and device of split air conditioner, storage medium and lower computer
CN115733729B (en) Communication fault processing method, system and equipment
CN208015725U (en) Multi-line system
CN110687910A (en) Equipment control method and device, storage medium and lower computer
CN111431668B (en) Baud rate switching method based on multi-node UART communication, air conditioning system and processor
CN105333574A (en) Identification method for connection mode of base station air-conditioning system and base station air-conditioning system
CN108551414B (en) Networking method, device and system of air conditioning system, and signal transmission method and device
CN108141480B (en) Method and apparatus for addressing in a system of interconnected cells
CN112188319B (en) Data processing method of optical fiber distribution frame and back-end monitoring platform
CN109088753B (en) Circuit and method for automatically detecting RS485 communication fault
CN109408454B (en) Chip management method and related device
CN112134851A (en) Interface protocol generation method of train signal system
CN112882971A (en) Serial port communication system and method, storage medium and processor
CN113206767A (en) Communication network abnormal node identification device, method and storage medium
CN114097588B (en) Networking method and device of irrigation device
CN108307542A (en) The method and apparatus of the smart television company's of returning bluetooth peripheral hardware when replacing Bluetooth adapter

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
GR01 Patent grant
GR01 Patent grant