Mesh communication gateway, system, and communication method
Through the first and second gateway devices in the Mesh communication gateway, unified control and data interaction with multiple peripheral devices are realized, the problem of small application scope of gateway devices is solved, and multiple communication protocols are supported, which is suitable for logistics and industrial controller scenarios.
Patent Information
- Application Number
- PCT/CN2024/126785
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-01-09
- Filing Date
- 2024-10-23
- Publication Date
- 2025-07-17
AI Technical Summary
In the prior art, gateway devices can only communicate and interact with one peripheral device, and the scope of application is small.
A Mesh communication gateway is provided, including a first gateway device and a second gateway device. It is connected through a UART communication. The first gateway device receives control or query commands of the external communication device and converts or transmits it to the second gateway device. The second gateway device communicates with multiple Mesh communication peripheral devices to realize unified control and data interaction.
The Mesh communication gateway is implemented to serve multiple peripheral devices at the same time, improve the scope of application, and supports external communication equipment with different communication protocols, and is suitable for scenarios such as logistics terminal equipment and industrial controllers.
Smart Images

Figure CN2024126785_17072025_PF_FP_ABST
Abstract
Description
Mesh communication gateway, system and communication method
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS
[0002] This application is based on the Chinese patent application with application number "202410034052.4" and application date of January 9, 2024, and claims the priority of the above-mentioned Chinese patent application. The entire content of the above-mentioned Chinese patent application is hereby incorporated into this application by introduction. Technical Field
[0003] The embodiments of the present application relate to the field of communication application layer, and in particular to a Mesh communication gateway, system and communication method. Background Art
[0004] A communication network is a link that physically connects isolated devices and enables information exchange between them, thereby achieving resource sharing and communication. As the number of devices in a communication network increases, network control becomes increasingly difficult. Mesh networks, or wireless mesh networks, with their multi-hop interconnection and mesh topology, have evolved into an effective solution for a variety of wireless access networks, including broadband home networks, community networks, enterprise networks, and metropolitan area networks.
[0005] In the prior art, an external device can only communicate and interact with one peripheral device through a gateway. In this technology, the gateway can only serve one peripheral device, and the gateway has a technical problem of a small scope of application.
[0006] Summary of the Invention
[0007] The purpose of the embodiments of the present application is to provide a Mesh communication gateway, system and communication method, so that the Mesh communication gateway can serve multiple peripheral devices through Mesh communication.
[0008] To solve the above technical problems, an embodiment of the present application provides a Mesh communication gateway, comprising: a first gateway device, a second gateway device communicatively connected to the first gateway device via universal asynchronous receiver and transmitter (UART);
[0009] The first gateway device is connected to an external communication device, and is used to receive a control command for a Mesh communication peripheral device sent by the external communication device, and send the control command to the second gateway device in a UART format;
[0010] The second gateway device is connected to the Mesh communication peripheral device, and the second gateway device is used to perform control operations on the Mesh communication peripheral device according to the control command received in the UART form to obtain response data of the Mesh communication peripheral device, and return the response data to the external communication device through the first gateway device.
[0011] An embodiment of the present application further provides a Mesh communication gateway, wherein the first gateway device is configured to receive a query command sent by the external communication device and send the query command to the second gateway device in a UART format;
[0012] The second gateway device is used to determine response data according to the query command received in the UART format and the locally stored data, and return the response data to the external communication device through the first gateway device.
[0013] An embodiment of the present application further provides a Mesh communication gateway, wherein the external communication device is a user terminal device, and the first gateway device is connected to the user terminal device via low-energy Bluetooth BLE communication;
[0014] The external communication device is an industrial controller, and the first gateway device is connected to the user terminal device via UART communication.
[0015] An embodiment of the present application also provides a Mesh communication gateway, which is a logistics terminal device; the Mesh communication peripheral device is set on the logistics items, and the Mesh communication peripheral device on each of the logistics items is communicatively connected to the second gateway device.
[0016] An embodiment of the present application further provides a Mesh communication gateway, wherein the Mesh communication peripheral device includes: a Mesh communication chip and an indicator.
[0017] An embodiment of the present application further provides a Mesh communication gateway, wherein the external communication device is a user terminal device, the logistics terminal device receives a BLE control command sent by the user terminal device, converts the BLE control command into a BLE to UART format, and obtains a UART control command, so as to control the indicator in the Mesh communication peripheral device to indicate according to the UART control command;
[0018] The external communication device is an industrial controller, and the logistics terminal device receives the UART control command sent by the industrial controller, and controls the indicator in the Mesh peripheral device to perform indication according to the UART control command.
[0019] The embodiments of the present application further provide a Mesh communication system, comprising: a Mesh communication gateway, a Mesh communication peripheral device, and an external communication device;
[0020] The Mesh communication gateway is connected to an external communication device, and the Mesh communication gateway is used to receive a control command or a query command sent by the external communication device;
[0021] The Mesh communication gateway is connected to the Mesh communication peripheral device. If the Mesh communication gateway receives a control command sent by the external communication device, the Mesh communication gateway is used to perform a control operation on the Mesh communication peripheral device according to the control command to obtain response data of the Mesh communication peripheral device; if the Mesh communication gateway receives a query command sent by the external communication device, the Mesh communication gateway is used to determine the response data based on the query command and locally stored data, and return the response data to the external communication device.
[0022] An embodiment of the present application further provides a Mesh communication method, which is applied to the above-mentioned Mesh communication gateway, and the method includes:
[0023] The first gateway device in the Mesh communication gateway receives a control command for a Mesh communication peripheral device sent by an external communication device;
[0024] The first gateway device sends the control command to the second gateway device in the Mesh communication gateway in UART form;
[0025] The second gateway device performs a control operation on the Mesh communication peripheral device according to the control command to obtain response data from the Mesh communication peripheral device;
[0026] The second gateway device sends the response data to the first gateway device;
[0027] The first gateway device sends the response data to the external communication device.
[0028] An embodiment of the present application further provides a Mesh communication method, wherein the Mesh communication peripheral device includes: a Mesh communication chip and an indicator; the second gateway device performs a control operation on the Mesh communication peripheral device according to the control command to obtain response data from the Mesh communication peripheral device, including:
[0029] The second gateway device determines at least one controlled Mesh communication peripheral device according to the control command;
[0030] The second gateway device sends the control command to the Mesh communication chip of the at least one controlled Mesh communication peripheral device, so that each Mesh communication chip controls the corresponding indicator to indicate, and the second gateway device receives response data returned by each Mesh communication chip.
[0031] An embodiment of the present application further provides a Mesh communication method, wherein the first gateway device sends the response data to the external communication device, including:
[0032] If the external communication device is a user terminal device, the first gateway device sends the response data to the external communication device in BLE format;
[0033] If the external communication device is an industrial controller, the first gateway device sends the response data to the external communication device in UART format.
[0034] In an embodiment of the present application, the Mesh communication gateway includes: a first gateway device, a second gateway device connected to the first gateway device via universal asynchronous receiver and transmitter (UART) communication, the first gateway device being connected to an external communication device, the first gateway device being used to receive control commands sent by the external communication device for the Mesh communication peripheral device, and sending the control commands to the second gateway device in UART form; the second gateway device being connected to the Mesh communication peripheral device, the second gateway device being used to perform control operations on the Mesh communication peripheral device according to the received control commands in UART form to obtain response data of the Mesh communication peripheral device, and returning the response data to the external communication device through the first gateway device. The present application communicates and interacts with the external communication device through the first gateway device in the Mesh communication gateway, and forms a Mesh network with the Mesh communication peripheral device through the second gateway device in the Mesh communication gateway, that is, unified control interaction between the Mesh network and the external communication device is realized through the Mesh communication gateway, wherein the Mesh network contains multiple Mesh communication peripheral devices, so that the Mesh communication gateway can serve multiple Mesh communication peripheral devices at the same time, thereby improving the scope of application of the Mesh communication gateway. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] One or more embodiments are exemplarily described by the figures in the corresponding drawings, and these exemplified descriptions do not constitute limitations on the embodiments.
[0036] FIG1 is a schematic diagram of the structure of a first Mesh communication gateway provided in an embodiment of the present application;
[0037] FIG2 is a schematic diagram of the structure of a second Mesh communication gateway provided in an embodiment of the present application;
[0038] FIG3 is a schematic diagram of the structure of a third Mesh communication gateway provided in an embodiment of the present application;
[0039] FIG4 is a schematic structural diagram of a Mesh communication system provided in an embodiment of the present application;
[0040] FIG5 is a flowchart of a Mesh communication method provided in an embodiment of the present application;
[0041] FIG6 is a flowchart of another Mesh communication method provided in an embodiment of the present application. DETAILED DESCRIPTION
[0042] In order to make the purpose, technical solutions and advantages of the embodiments of the present application clearer, each embodiment of the present application will be described in detail below with reference to the accompanying drawings. However, it will be understood by those skilled in the art that in each embodiment of the present application, many technical details are proposed to enable the reader to better understand the present application. However, even without these technical details and various changes and modifications based on the following embodiments, the technical solutions claimed in the present application can be implemented. The division of the following embodiments is for convenience of description and should not constitute any limitation on the specific implementation of the present application. The various embodiments can be combined and referenced with each other under the premise of no contradiction.
[0043] An embodiment of the present application relates to a Mesh communication gateway. As shown in Figure 1, the Mesh communication gateway 10 includes: a first gateway device 101, and a second gateway device 102 that is communicatively connected to the first gateway device 101 via Universal Asynchronous Receiver / Transmitter (UART) communication, that is, the first gateway device 101 and the second gateway device 102 communicate data through a unified UART communication protocol.
[0044] The first gateway device 101 is connected to the external communication device 20 and is configured to receive a control command from the external communication device 20. This command is a control command from the external communication device 20 directed to a Mesh communication peripheral device. This control command can be used to set data for a specific Mesh peripheral device address. After receiving the control command, the first gateway device 101 needs to send the control command to the second gateway device 102 in UART format, as the first gateway device 101 and the second gateway device 102 communicate via the UART communication protocol.
[0045] In one exemplary implementation, if the control command is not a UART-formatted command, the first gateway device 101 needs to convert it into a command corresponding to the UART protocol format and then send the command to the second gateway device 102. If the control command is a UART-formatted command, the first gateway device 101 can directly send the control command to the second gateway device 102 without conversion.
[0046] The second gateway device 102 is connected to the Mesh communication peripheral device 30. In the embodiment of the present application, the second gateway device 102 and the Mesh communication peripheral device 30 are connected through Mesh (multi-hop, wireless mesh network) communication, and the second gateway device 102 can be communicatively connected with multiple Mesh communication peripheral devices 30 through Mesh communication.
[0047] After the second gateway device 102 receives the control command in UART format sent by the first gateway device 101, it performs a control operation on at least one Mesh communication peripheral device 30 corresponding to the control command to obtain response data from at least one Mesh communication peripheral device. After receiving the response data, the second gateway device 102 returns the response data to the external communication device 20 through the first gateway device 101, that is, the second gateway device 102 sends the received response data to the first gateway device 101, so that the first gateway device 101 returns the response data to the external communication device 20 in response to the control command sent by the external communication device 20.
[0048] In the embodiment of the present application, a first gateway device in the Mesh communication gateway communicates and interacts with an external communication device, and a second gateway device in the Mesh communication gateway communicates with a Mesh communication peripheral device. The second gateway device and the Mesh communication peripheral device form a Mesh network, that is, the Mesh communication gateway realizes unified control interaction between the Mesh network and the external communication device, wherein the Mesh network includes multiple Mesh communication peripheral devices, so that the Mesh communication gateway can serve multiple Mesh communication peripheral devices at the same time, thereby improving the applicability of the Mesh communication gateway.
[0049] Based on the Mesh communication gateway shown in Figure 1 above, an embodiment of the present application also provides another Mesh communication gateway. Specifically, the first gateway device 101 is used to receive a query command sent by an external communication device 20, and send the query command to the second gateway device in UART form.
[0050] The query command may be for obtaining network information, etc., wherein the obtained network information is stored in the local storage data of the second gateway device 102. Therefore, the second gateway device 102 is used to determine the response data based on the received query command in UART format and the local storage data, that is, the second gateway device 102 retrieves the retrieval data corresponding to the query command from the local storage data according to the query command, and the retrieval data is the response data.
[0051] After determining the response data, the second gateway device 102 returns the response data to the external communication device 20 through the first gateway device 101 to respond to the query command of the external communication device 20 .
[0052] The embodiment of the present application determines the response data corresponding to the query command through the second gateway device in the Mesh communication gateway and the locally stored data, thereby realizing the communication interaction between the Mesh communication gateway and the external communication device.
[0053] Based on the Mesh communication gateway shown in Figure 1 above, an embodiment of the present application also provides another Mesh communication gateway. For example, as shown in Figure 2, the external communication device 20 is a user terminal device, and the first gateway device 101 is connected to the user terminal device via low-energy Bluetooth BLE (Bluetooth Low Energy) communication.
[0054] When the external communication device 20 is a user terminal device, the user terminal device may be a mobile phone terminal, and of course may also be other devices with BLE communication function, which is not specifically limited in the embodiment of the present application.
[0055] When the external communication device 20 is a user terminal device, the user terminal device will send a BLE control command to the first gateway device 101. The first gateway device 101 converts the BLE control command from BLE to UART to obtain a UART control command. The first gateway device 101 sends the UART control command to the second gateway device 102, so that the second gateway device 102 controls the corresponding Mesh communication peripheral device according to the UART control command and obtains response data. The second gateway device 102 sends the response data to the first gateway device 101 in UART form. The first gateway device 101 converts the UART response data into BLE response data and sends it to the user terminal device.
[0056] When the external communication device 20 is a user terminal device, the user terminal device will send a BLE query command to the first gateway device 101. The first gateway device 101 converts the BLE query command from BLE to UART to obtain a UART query command. The first gateway device 101 sends the UART query command to the second gateway device 102, so that the second gateway device 102 determines the response data based on the UART query command and the locally stored data. The second gateway device 102 sends the response data to the first gateway device 101 in UART form. The first gateway device 101 converts the UART response data into BLE response data and sends it to the user terminal device.
[0057] As shown in FIG3 , when the external communication device 20 is an industrial controller, the first gateway device 101 is connected to the user terminal device via UART communication.
[0058] When the external communication device 20 is an industrial controller, the industrial controller will send a UART control command to the first gateway device 101, and the first gateway device 101 will transparently transmit the UART control command to the second gateway device 102, so that the second gateway device 102 controls the corresponding Mesh communication peripheral device according to the UART control command and obtains response data. The second gateway device 102 sends the response data to the first gateway device 101 in UART form, and the first gateway device 101 sends the UART response data directly to the industrial controller.
[0059] When the external communication device 20 is an industrial controller, the user terminal device will send a UART query command to the first gateway device 101, and the first gateway device 101 will transparently transmit the UART query command to the second gateway device 102, so that the second gateway device 102 determines the response data based on the UART query command and the locally stored data. The second gateway device 102 sends the response data to the first gateway device 101 in UART form, and the first gateway device 101 sends the UART response data directly to the industrial controller.
[0060] The embodiments of the present application specifically illustrate the communication interaction methods between external communication devices with different communication protocols and the gateway device 10 and Mesh communication peripheral devices. It can be understood that the external communication device can also be a communication device with other communication protocols, and the corresponding communication method is similar to the above method, which is not elaborated in detail here. Therefore, the Mesh communication gateway can be applicable to external communication devices with different communication protocols and has a wide range of applications.
[0061] Based on the mesh communication gateway described in the above embodiment, another embodiment of the present application provides a mesh communication gateway. For example, in a logistics station application scenario, the mesh communication gateway 10 is a logistics terminal device, such as a handheld terminal device used by a courier. Correspondingly, the mesh communication peripherals may include a mesh communication chip and an indicator, and a mesh communication chip connection indicator. Mesh communication peripherals 30 may be installed on logistics items, such as user packages placed in a courier station. Each mesh communication peripheral 30 on each logistics item is communicatively connected to a second gateway device 102. Correspondingly, the external communication device 20 may be a user's mobile phone.
[0062] In the application scenario of the logistics station, in one case, when the user clicks on the mobile phone to obtain one or more of his or her packages, the logistics terminal device conducts mesh communication with the corresponding Mesh communication peripheral device 30, so that the Mesh communication chip in the Mesh communication peripheral device 30 controls the corresponding indicator to indicate, and the Mesh communication peripheral device 30 sends the indicated response data to the user's mobile phone through the logistics terminal device; in another case, when the user clicks on the mobile phone to query the number of his or her packages, the logistics terminal device determines the number of the user's packages based on the locally stored data, and then sends the number of packages to the user's mobile phone for the user to view.
[0063] For example, the indicator may be an indicator light, which may illuminate.
[0064] The embodiments of the present application illustrate the solution of the present application through the specific application scenario of the logistics station. Of course, the solution of the present application can also be applied to other scenarios, which are not specifically limited in the embodiments of the present application.
[0065] Based on the Mesh communication gateway of the above embodiment, the embodiment of the present application also provides another Mesh communication gateway. In the application scenario of the logistics station, when the external communication device 20 is a user terminal device, the user terminal device is connected to the logistics terminal device via BLE communication. Therefore, after the logistics terminal device receives the BLE control command sent by the user terminal device, it is necessary to convert the BLE control command into UART format to obtain a UART control command, so as to control the indicator in the corresponding Mesh communication peripheral device to indicate according to the UART control command; after the logistics terminal device receives the BLE query command sent by the user terminal device, it is necessary to convert the BLE query command into UART format to obtain a UART query command, so as to determine the response data according to the UART query command and the locally stored data.
[0066] When the external communication device 20 is an industrial controller, the industrial controller is connected to the logistics terminal device via UART communication. Therefore, after receiving a UART control command from the industrial controller, the logistics terminal device can directly control the corresponding indicator in the Mesh peripheral device according to the UART control command. After receiving a UART query command from the user terminal device, the logistics terminal device can directly determine the response data based on the UART query command and locally stored data.
[0067] Based on the Mesh communication gateway in the above embodiment, the embodiment of the present application further provides a Mesh communication system. As shown in FIG4 , the Mesh communication system includes: a Mesh communication gateway 10 , a Mesh communication peripheral device 30 , and an external communication device 20 .
[0068] The Mesh communication gateway 10 is connected to the external communication device 20 , and the Mesh communication gateway 10 is connected to the Mesh communication peripheral device 30 .
[0069] The mesh communication gateway 10 is configured to receive control commands or query commands sent by an external communication device 20. If the mesh communication gateway 10 receives a control command from an external communication device 20, it is configured to perform a control operation on at least one mesh communication peripheral device corresponding to the control command in accordance with the control command to obtain response data from the mesh communication peripheral device. If the mesh communication gateway 10 receives a query command from an external communication device 20, it is configured to determine response data based on the query command and locally stored data. After obtaining the response data, the mesh communication gateway 10 returns the response data to the external communication device 20 in response to the command issued by the external communication device 20.
[0070] The specific communication methods of the Mesh communication gateway 10, the Mesh communication peripheral device 30 and the external communication device 20 are specifically described in the above-mentioned embodiment of the Mesh communication gateway and will not be elaborated here.
[0071] The embodiment of the present application realizes unified control interaction between the Mesh network and external communication devices through the Mesh communication gateway, wherein the Mesh network includes multiple Mesh communication peripheral devices, so that the Mesh communication gateway can serve multiple Mesh communication peripheral devices at the same time, thereby improving the applicability of the Mesh communication gateway.
[0072] Based on the Mesh communication gateway in the above embodiment, the embodiment of the present application further provides a Mesh communication method, which is applied to any of the above-mentioned Mesh communication gateways. As shown in Figure 5, the application specifically includes the following steps.
[0073] Step 501: A first gateway device in a Mesh communication gateway receives a control command for a Mesh communication peripheral device sent by an external communication device.
[0074] In the data path of this application, the format of a control command consists of an opcode, a length, and a data field. The opcode represents the control type, the length indicates the length of the data field, and the data field contains the data content of the message. In one example implementation, the opcode may be used to set data for a specific Mesh communication peripheral device address. The data field may include: the target device address, a data handle, and a data value. The data handle refers to the data address.
[0075] In addition, the first gateway device in the Mesh communication gateway can also receive query commands sent by external communication devices.
[0076] In step 502 , the first gateway device sends the control command to the second gateway device in the Mesh communication gateway in UART format.
[0077] For example, if the control command is in UART format, the first gateway device directly sends the control command to the second gateway device in the Mesh communication gateway; if the control command is in BLE format, the first gateway device needs to convert BLE into UART format and send it to the second gateway device in the Mesh communication gateway. Of course, if the control command is in other formats, the first gateway device needs to convert other formats into UART format and send it to the second gateway device in the Mesh communication gateway.
[0078] In addition, when the first gateway device in the Mesh communication gateway receives a query command sent by the external communication device, the first gateway device sends the query command to the second gateway device in the Mesh communication gateway in UART format.
[0079] Step 503: The second gateway device performs a control operation on the Mesh communication peripheral device according to the control command to obtain response data from the Mesh communication peripheral device.
[0080] In an embodiment of the present application, after the second gateway device obtains the control command, it parses the control command to obtain the operation code, length, and data field, and then performs corresponding operations based on the operation code. For example, the controlled Mesh communication peripheral device can be determined based on the target device address in the data field, thereby enabling the second gateway device to perform single-point data transmission with the controlled Mesh communication peripheral device, and the second gateway device obtains the response data of the controlled Mesh communication peripheral device.
[0081] In addition, when the first gateway device in the Mesh communication gateway receives a query command sent by an external communication device, the first gateway device sends the query command to the second gateway device in the Mesh communication gateway in UART format, and the second gateway device determines the response data based on the query command and locally stored data.
[0082] Step 504: The second gateway device sends the response data to the first gateway device.
[0083] Specifically, the second gateway device sends the response data to the first gateway device in the form of a response message via UART communication, wherein the format of the response message is the same as the format of the control command.
[0084] Step 505: The first gateway device sends the response data to the external communication device.
[0085] Specifically, the first gateway device sends the response data to the external communication device in the form of a response message, and the form of the response message is based on the communication mode of the external communication device.
[0086] The embodiments of the present application describe the data path of the Mesh communication gateway during communication to achieve unified control interaction between the Mesh communication gateway and Mesh communication peripheral devices and external communication devices.
[0087] Based on the Mesh communication method shown in Figure 5 above, an embodiment of the present application also provides a Mesh communication method, as shown in Figure 6, the Mesh communication peripheral device includes: a Mesh communication chip and an indicator. In the above step 503, the second gateway device performs a control operation on the Mesh communication peripheral device according to the control command to obtain response data from the Mesh communication peripheral device, which specifically includes the following steps.
[0088] Step 601: The second gateway device determines at least one controlled Mesh communication peripheral device according to a control command.
[0089] After receiving the control command, the second gateway device parses the control command and obtains three parts of the control command: operation code, length, and data field. The data field includes the address of at least one controlled Mesh communication peripheral device. Therefore, the second gateway device can determine at least one controlled Mesh communication peripheral device based on the data field in the control command.
[0090] In step 602 , the second gateway device sends a control command to the Mesh communication chip of at least one controlled Mesh communication peripheral device, and receives response data returned by each Mesh communication chip.
[0091] After the second gateway device determines at least one controlled Mesh communication peripheral device, it sends a control command to the Mesh communication chip in the at least one controlled Mesh communication peripheral device. If the operation code in the control command indicates the indication status of the indicator in the Mesh communication peripheral device, the Mesh communication chip in each controlled Mesh communication peripheral device controls the indication status of the corresponding connected indicator. For example, when the indicator is an indicator light, the indicator light lights up, and each Mesh communication chip sends the indicator indication status as response data to the second gateway device, and the second gateway device receives the response data returned by each Mesh communication chip.
[0092] The embodiment of the present application realizes the control interaction between the second gateway device and the Mesh communication peripheral device in a specific scenario through the specific composition of the Mesh communication peripheral device in the specific scenario.
[0093] Based on the Mesh communication method shown in FIG5 , an embodiment of the present application further provides a Mesh communication method. In the above step 505 , the first gateway device sends the response data to the external communication device, which specifically includes the following steps.
[0094] If the external communication device is a user terminal device, the first gateway device sends the response data to the external communication device in BLE format. The second gateway device sends the response data to the first gateway device in UART format. If the external communication device is a user terminal device, the user terminal device only supports BLE communication. Therefore, the first gateway device needs to convert the UART response data into BLE format so that the user terminal device can receive the response data.
[0095] If the external communication device is an industrial controller, the first gateway device sends the response data to the external communication device in UART format. The second gateway device sends the response data to the first gateway device in UART format. If the external communication device is an industrial controller, the industrial controller only supports UART communication. Therefore, the first gateway device can directly transmit the UART response data to the external communication device, so that the user terminal device receives the response data.
[0096] The embodiment of the present application performs different form conversions on different external communication devices, so that the first gateway device can perform normal communication interaction with the external communication device.
[0097] The steps of the various methods above are divided only for the purpose of clear description. During implementation, they can be combined into one step or some steps can be split and decomposed into multiple steps. As long as they include the same logical relationship, they are all within the scope of protection of this patent. Adding insignificant modifications or introducing insignificant designs to the algorithm or process without changing the core design of the algorithm and process are all within the scope of protection of this patent.
[0098] Those skilled in the art will appreciate that the above embodiments are specific embodiments for implementing the present application, and that in actual applications, various changes may be made thereto in form and detail without departing from the spirit and scope of the present application.
Claims
1. A Mesh communication gateway, characterized in that, The Mesh communication gateway includes: a first gateway device and a second gateway device communicatively connected to the first gateway device through Universal Asynchronous Receiver / Transmitter (UART) communication; The first gateway device is connected to an external communication device. The first gateway device is configured to receive a control command for a Mesh communication peripheral device sent by the external communication device and send the control command to the second gateway device in the form of UART; The second gateway device is connected to the Mesh communication peripheral device. The second gateway device is configured to perform a control operation on the Mesh communication peripheral device according to the received control command in the form of UART to obtain response data of the Mesh communication peripheral device and return the response data to the external communication device through the first gateway device.
2. The Mesh communication gateway according to claim 1, wherein The first gateway device is configured to receive a query command sent by the external communication device and send the query command to the second gateway device in the form of UART; The second gateway device is configured to determine response data according to the received query command in the form of UART and local stored data and return the response data to the external communication device through the first gateway device.
3. The Mesh communication gateway according to claim 1, wherein The external communication device is a user terminal device. The first gateway device is communicatively connected to the user terminal device through Bluetooth Low Energy (BLE) communication; The external communication device is an industrial controller. The first gateway device is communicatively connected to the user terminal device through UART communication.
4. The Mesh communication gateway according to any one of claims 1 to 3, characterized in that, The Mesh communication gateway is a logistics terminal device; the Mesh communication peripheral devices are arranged on logistics items, and each Mesh communication peripheral device on the logistics item is communicatively connected to the second gateway device.
5. The Mesh communication gateway according to claim 4, characterized in that, The Mesh communication peripheral device includes: a Mesh communication chip and an indicator.
6. The Mesh communication gateway according to claim 5, characterized in that, The external communication device is a user terminal device. The logistics terminal device receives a BLE control command sent by the user terminal device, performs a form conversion of BLE to UART on the BLE control command to obtain a UART control command, and controls the indicator in the Mesh communication peripheral device to give an indication according to the UART control command; The external communication device is an industrial controller. The logistics terminal device receives a UART control command sent by the industrial controller and controls the indicator in the Mesh peripheral device to give an indication according to the UART control command.
7. A Mesh communication system, characterized in that, The Mesh communication system includes: the Mesh communication gateway according to any one of claims 1-6 above, a Mesh communication peripheral device, and an external communication device; The Mesh communication gateway is connected to an external communication device. The Mesh communication gateway is configured to receive a control command or a query command sent by the external communication device; The Mesh communication gateway is connected to Mesh communication peripheral devices. If the Mesh communication gateway receives a control command sent by the external communication device, the Mesh communication gateway is used to perform a control operation on the Mesh communication peripheral devices according to the control command to obtain response data of the Mesh communication peripheral devices; if the Mesh communication gateway receives a query command sent by the external communication device, the Mesh communication gateway is used to determine response data according to the query command and locally stored data, and return the response data to the external communication device.
8. A Mesh communication method, characterized in that, Applied to the Mesh communication gateway described in any one of the above claims 1-6, the method includes: A first gateway device in the Mesh communication gateway receives a control command sent by an external communication device for a Mesh communication peripheral device; The first gateway device sends the control command to a second gateway device in the Mesh communication gateway in the form of UART; The second gateway device performs a control operation on the Mesh communication peripheral device according to the control command to obtain response data of the Mesh communication peripheral device; The second gateway device sends the response data to the first gateway device; The first gateway device sends the response data to the external communication device.
9. The Mesh communication gateway according to claim 8, wherein The Mesh communication peripheral device includes: a Mesh communication chip and an indicator; the second gateway device performing a control operation on the Mesh communication peripheral device according to the control command to obtain response data of the Mesh communication peripheral device includes: The second gateway device determines at least one controlled Mesh communication peripheral device according to the control command; The second gateway device sends the control command to the Mesh communication chips of the at least one controlled Mesh communication peripheral device, so that each Mesh communication chip controls the corresponding indicator to give an indication, and the second gateway device receives the response data returned by each Mesh communication chip.
10. The Mesh communication gateway according to claim 8, wherein The first gateway device sending the response data to the external communication device includes: If the external communication device is a user terminal device, the first gateway device sends the response data to the external communication device in the form of BLE; If the external communication device is an industrial controller, the first gateway device sends the response data in the form of UART to the external communication device.
Citation Information
Patent Citations
Data transmission method and apparatus
CN108833236A
Smart home system
CN109901412A
Communication method and device of smart home equipment, storage medium and gateway equipment
CN116668224A
Mesh communication gateway, system and communication method
CN117915277A
Gateway for internet of things and, internet of things system
KR1020180105868A