Communication module debugging method and device, equipment, storage medium and program product
By establishing a mapping relationship between user identity information and communication module identification code in the server, remote debugging of cellular network communication modules was realized, solving the problem of low efficiency in local debugging and improving debugging efficiency.
Patent Information
- Application Number
- CN202511705072.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-18
- Publication Date
- 2026-01-13
AI Technical Summary
The existing local debugging method for cellular network communication modules requires completion after manufacturing, resulting in a long debugging cycle and low efficiency.
By pre-storing the mapping relationship between user identity information and communication module identification code in the server, remote debugging is achieved, avoiding the need for users to make printed circuit boards and directly sending debugging commands to the target communication module.
It improves debugging efficiency, enabling users to remotely debug the communication module through the terminal, reducing debugging time and resource waste.
Smart Images

Figure CN121334129A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of Internet of Things (IoT) technology, and in particular relates to a method, apparatus, device, storage medium, and program product for debugging a communication module. Background Technology
[0002] A cellular network communication module is a hardware component specifically designed for data transmission within cellular mobile networks. Cellular network communication modules support various network protocols and functions, enabling devices to communicate wirelessly over cellular networks.
[0003] Before being put into use, cellular network communication modules need to be debugged. Currently, the main method for debugging cellular network communication modules is local debugging. Local debugging refers to the user purchasing the cellular network communication module, microcontroller unit (MCU), and sensors, then fabricating a printed circuit board (PCB) of the cellular network communication module, MCU, and sensors according to a pre-designed circuit schematic, and finally debugging the cellular network communication module by controlling the MCU.
[0004] However, the above-mentioned local debugging method requires users to perform debugging after completing the fabrication of the cellular network communication module. This results in a long debugging cycle and low efficiency for the cellular network communication module. Summary of the Invention
[0005] This application provides a method, apparatus, device, storage medium, and program product for debugging communication modules, which supports users in remotely debugging communication modules and improves debugging efficiency.
[0006] In a first aspect, embodiments of this application provide a method for debugging a communication module, applied to a server, the method comprising: Receive debugging commands sent by the terminal; Based on the mapping relationship between user identity information and communication module identification code, determine the first communication module identification code corresponding to the first user identity information carried in the debugging instruction; Send the debugging command to the communication module corresponding to the first communication module identification code.
[0007] In one possible implementation, prior to the debugging instructions sent by the receiving terminal, the method further includes: Receive the registration request sent by the communication module and the connection establishment request sent by the terminal; After the communication module is authenticated according to the first communication module identification code carried in the registration request, a connection channel between the server and the communication module is established. After the terminal is authenticated based on the first user identity information carried in the connection establishment request, a connection channel between the server and the terminal is established. Construct a mapping relationship between the first user identity information and the first communication module identification code.
[0008] In one possible implementation, constructing the mapping relationship between the first user identity information and the first communication module identification code includes: Obtain the availability status of the communication module, whereby the availability status indicates whether a mapping relationship has been established for the communication module; When the available state is the first value, a mapping relationship is constructed between the first user identity information and the first communication module identification code.
[0009] In one possible implementation, after the communication module is authenticated based on the first communication module identification code carried in the registration request, a connection channel is established between the server and the communication module, including: After the communication module is authenticated according to the first communication module identification code carried in the registration request, a first long connection channel is established between the server and the communication module. If the first communication port accessed by the communication module is detected, the second communication module identification code of the communication module is obtained through the first communication port; If the second communication module identification code and the first communication module identification code are the same, a binding relationship is established between the first communication port and the first long connection channel.
[0010] In one possible implementation, sending the debugging command to the communication module corresponding to the first communication module identification code includes: Determine the first communication port corresponding to the first communication module identification code; If the first communication port is disconnected, the debugging command is sent through the first long connection channel.
[0011] In one possible implementation, after the terminal is authenticated based on the first user identity information carried in the connection establishment request, establishing a connection channel between the server and the terminal includes: After the terminal is authenticated based on the first user identity information carried in the connection establishment request, a second long connection channel is established between the server and the terminal. If the second communication port accessed by the terminal is detected, the second user identity information of the terminal is obtained through the second communication port; If the first user identity information and the second user identity information are the same, a binding relationship is established between the second communication port and the second long connection channel.
[0012] In one possible implementation, the debugging instructions sent by the receiving terminal include: The debugging command is sent through the second long connection channel when the second communication port is disconnected.
[0013] Secondly, embodiments of this application provide a method for debugging a communication module, applied to a communication module, the method comprising: The server receives a debugging instruction sent by the terminal; the debugging instruction is determined by the server after receiving the debugging instruction sent by the terminal, based on the mapping relationship between user identity information and communication module identification code, and the server determines the first communication module identification code corresponding to the first user identity information carried in the debugging instruction; the server then sends the debugging instruction to the communication module corresponding to the first communication module identification code.
[0014] In one possible implementation, the communication module includes a cellular module, a power supply circuit, and a hardware watchdog circuit; The cellular module is used to execute the debugging instructions; The cellular module is also used to send pulse signals to the hardware watchdog circuit at preset intervals. The hardware watchdog circuit is used to control the power supply circuit to cut off power if the pulse signal is not received within the preset time period.
[0015] Thirdly, embodiments of this application provide a communication module debugging apparatus, applied to a server, the apparatus comprising: The receiving module is used to receive debugging commands sent by the terminal; The determination module is used to determine the first communication module identification code corresponding to the first user identity information carried in the debugging instruction according to the mapping relationship between user identity information and communication module identification code; The sending module is used to send the debugging command to the communication module corresponding to the first communication module identification code.
[0016] Fourthly, embodiments of this application provide a communication module debugging apparatus, applied to a communication module, the apparatus comprising: The receiving module is used to receive debugging instructions sent by the server; the debugging instructions are determined by the server after receiving the debugging instructions sent by the terminal, according to the mapping relationship between user identity information and communication module identification code, and the first communication module identification code corresponding to the first user identity information carried in the debugging instructions is determined; the debugging instructions are sent to the communication module corresponding to the first communication module identification code.
[0017] Fifthly, embodiments of this application provide an electronic device, which includes: a processor and a memory storing computer program instructions; The processor executes computer program instructions to implement either the method for debugging the communication module as described in the first aspect, or the method for debugging the communication module as described in the second aspect.
[0018] Sixthly, embodiments of this application provide a computer storage medium storing computer program instructions, which, when executed by a processor, implement the communication module debugging method as described in the first aspect, or the communication module debugging method as described in the second aspect.
[0019] In a seventh aspect, embodiments of this application provide a computer program product in which instructions, when executed by a processor of an electronic device, cause the electronic device to perform a communication module debugging method as described in the first aspect, or to implement a communication module debugging method as described in the second aspect.
[0020] This application provides a method, apparatus, device, storage medium, and program product for debugging a communication module. After receiving a debugging command from a terminal, the server, based on the first user identity information carried in the debugging command, searches for the first communication module identification code corresponding to the first user identity information in a locally stored mapping relationship between user identity information and communication module identification codes. The first communication module identification code accurately locates the communication module corresponding to the debugging command. Therefore, the server can send the debugging command to the communication module corresponding to the first communication module identification code. In this way, by pre-storing the mapping relationship between user identity information and communication module identification codes in the server, the correspondence between communication modules and users can be pre-built, enabling users to remotely debug communication modules through terminals. This avoids the need for users to manufacture PCB boards for cellular network communication modules, improving debugging efficiency. Attached Figure Description
[0021] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0022] Figure 1 This is a schematic diagram of the framework structure for implementing a method for debugging a communication module provided in the embodiments of this application; Figure 2 This is a flowchart illustrating a method for debugging a communication module applied to a server, as provided in an embodiment of this application. Figure 3This is a flowchart illustrating a mapping relationship construction method provided in an embodiment of this application; Figure 4 This is an exemplary schematic diagram of a connection channel construction method provided in an embodiment of this application; Figure 5 This is an exemplary schematic diagram of a local debugging method provided in an embodiment of this application; Figure 6 This is an exemplary schematic diagram of a remote debugging method provided in an embodiment of this application; Figure 7 This is a flowchart illustrating a method for debugging a communication module, as provided in an embodiment of this application. Figure 8 This is an exemplary schematic diagram of a communication module structure provided in an embodiment of this application; Figure 9 This is a flowchart illustrating a method for debugging a communication module provided in an embodiment of this application; Figure 10 This is a schematic diagram of the structure of the device for debugging the communication module of a server provided in an embodiment of this application; Figure 11 This is a schematic diagram of the structure of the device for debugging a communication module provided in the embodiments of this application; Figure 12 This is a schematic diagram of the structure of the terminal device provided in the embodiments of this application. Detailed Implementation
[0023] The features and exemplary embodiments of various aspects of this application will be described in detail below. To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain this application and not to limit it. For those skilled in the art, this application can be implemented without some of these specific details. The following description of the embodiments is merely to provide a better understanding of this application by illustrating examples.
[0024] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus that includes the element.
[0025] To address the problems of existing technologies, embodiments of this application provide a method, apparatus, device, and computer storage medium for debugging communication modules. The following first illustrates a system framework for applying the communication module debugging method provided in this application. Figure 1 As shown, the system includes a software client, a server, and a communication module.
[0026] The software client is installed on a terminal, which supports Windows, Linux, or Mac systems.
[0027] The server includes an authentication management module, a connection management module, and a data pass-through module. The authentication management module is used to authenticate the software client and the communication module; the connection management module is used to establish connection channels between the server and the software client, as well as between the server and the communication module; and the data pass-through module is used to transmit data through the connection channels.
[0028] The communication module includes a cellular network communication module and peripheral devices, such as antenna devices, power supplies, etc.
[0029] Data transmission occurs between the server and the software client via a network connection, and between the server and the communication module via a network connection or a communication port connection.
[0030] Figure 2 A flowchart illustrating a method for debugging a communication module according to an embodiment of this application is shown. This method for debugging a communication module can be applied to servers, such as... Figure 2 As shown, the method includes: S201, Receive debugging commands sent by the terminal.
[0031] In this process, the user enters their identity information on the terminal to log in to the software client. The terminal responds to the user's debugging action by generating debugging instructions and sending the instructions to the server.
[0032] Specifically, debugging commands are transmitted through a connection channel between the server and the terminal. This connection channel can be a Transmission Control Protocol (TCP) connection. This application does not impose specific limitations on the connection channel.
[0033] S202. Based on the mapping relationship between user identity information and communication module identification code, determine the first communication module identification code corresponding to the first user identity information carried in the debugging instruction.
[0034] Each user identity information can correspond to multiple communication module identification codes, meaning each user identity information can be mapped to multiple communication modules. The communication module identification code is a unique identifier for the communication module, specifically the International Mobile Equipment Identity (IMEI).
[0035] S203. Send a debugging command to the communication module corresponding to the first communication module identification code.
[0036] Using the above method, after receiving the debugging command from the terminal, the server, based on the first user identity information carried in the debugging command, searches for the first communication module identification code corresponding to the first user identity information in the locally stored mapping relationship between user identity information and communication module identification codes. The first communication module identification code accurately locates the communication module corresponding to the debugging command. Therefore, the server can send the debugging command to the communication module corresponding to the first communication module identification code. In this way, by pre-storing the mapping relationship between user identity information and communication module identification codes in the server, the correspondence between communication modules and users can be pre-built, enabling users to remotely debug communication modules through terminals. This avoids the need for users to manufacture PCB boards for cellular network communication modules, improving debugging efficiency.
[0037] The following combination Figure 3 This describes the process of establishing connection channels between the terminal and the communication module and the server, such as... Figure 3 As shown, before receiving the debugging command sent by the terminal in S201, the method further includes: S301, Receive the registration request sent by the communication module and the connection establishment request sent by the terminal.
[0038] The registration request is used to complete the registration of the communication module and establish a connection channel between the communication module and the server.
[0039] S302. After the communication module is authenticated based on the first communication module identification code carried in the registration request, a connection channel between the server and the communication module is established.
[0040] Specifically, this application does not impose any specific restrictions on the authentication method.
[0041] S303. After the terminal is authenticated based on the first user identity information carried in the connection establishment request, a connection channel between the server and the terminal is established.
[0042] The connection channel can be either a network connection or a physical connection; this application does not impose any restrictions on this.
[0043] S304. Construct a mapping relationship between the first user identity information and the first communication module identification code.
[0044] Using the method provided in this application, upon receiving a registration request and a connection establishment request, the server authenticates both the communication module and the terminal. If authentication is successful, connection channels are established between the server and the terminal, and between the server and the communication module. This facilitates subsequent remote debugging via these connection channels. Finally, a mapping relationship is constructed between the first user identity information and the first communication module identification code, allowing the server to accurately send debugging commands based on this mapping, thereby enabling remote debugging of the communication module and improving debugging efficiency.
[0045] In some embodiments of this application, the process of establishing a connection channel between the server and the terminal, and the process of establishing a connection channel between the server and the communication module are described respectively.
[0046] Regarding the process of establishing a connection channel between the server and the terminal, S302 above, after authenticating the communication module based on the first communication module identification code carried in the registration request, establishes a connection channel between the server and the communication module, which can be specifically implemented as follows: Step 1: After the communication module is authenticated based on the first communication module identification code carried in the registration request, a first long connection channel is established between the server and the communication module.
[0047] The first long connection channel is a network connection, specifically a TCP connection.
[0048] Step 2: If the first communication port connected to the communication module is detected, obtain the second communication module identification code of the communication module through the first communication port.
[0049] The first communication port is a physical connection port, which can be a serial communication port (ComponentObject Model Port, COM).
[0050] Step 3: If the second communication module identification code and the first communication module identification code are the same, establish the binding relationship between the first communication port and the first long connection channel.
[0051] It is understandable that if the second communication module identification code and the first communication module identification code are the same, it means that the first long connection channel and the first communication port are used for data transmission of the same communication module. Therefore, the first communication port and the first long connection channel are bound together.
[0052] It should be noted that, based on the above-mentioned binding relationship between the first communication port and the first long connection channel, data transmission is preferentially performed through the first communication port. Specifically, S203, sending debugging commands to the communication module corresponding to the first communication module identification code, can be implemented as follows: Determine the first communication port corresponding to the first communication module identification code; if the first communication port is disconnected, send debugging commands through the first long connection channel.
[0053] Understandably, if the first communication port is not disconnected, the server will prioritize data transmission and sending debugging commands through the first communication port.
[0054] Using the method provided in this application embodiment, after the communication module is authenticated, a network connection, i.e., a first long-term connection channel, is first established between the server and the communication module. Furthermore, upon detecting that the communication module is connected to the first communication port, a second communication module identification code is obtained through the first communication port. Thus, the first communication port and the first long-term connection channel can be bound based on the obtained second communication module identification code, avoiding duplicate data transmission. Moreover, during data transmission, the first communication port is preferentially used for data transmission; as a physical connection, the first communication port ensures data transmission stability.
[0055] The following combination Figure 4 Introducing two connection methods for the communication module, such as Figure 4 As shown, the method includes: S401, The communication module sends a TCP connection request to the server.
[0056] The TCP connection request is the registration request in the above embodiment.
[0057] S402, The server sends an acknowledgment request to the communication module.
[0058] After the server completes the authentication of the communication module, it sends an confirmation request to the communication module.
[0059] S403, the communication module sends the International Mobile Equipment Identity Code to the server.
[0060] The International Mobile Equipment Identity Code (IMICO) is the communication module identification code in the above embodiments.
[0061] S404. The server assigns a connection port based on the International Mobile Equipment Identity (IMEI).
[0062] The process of allocating connection ports is the same as the process of establishing the first connection channel in the above embodiments.
[0063] S405, communication module and server establish serial port USB connection.
[0064] In this embodiment, the serial USB port is the first communication port.
[0065] S406. The server requests the International Mobile Equipment Identity Code from the communication module.
[0066] S407, communication modules and servers report International Mobile Equipment Identity Code.
[0067] The S408, server, and communication module prioritize the use of serial communication ports, with TCP connections as a backup.
[0068] Using the method provided in this application embodiment, after the communication module is authenticated, a network connection is first established between the server and the communication module, i.e., a connection port is allocated. Furthermore, when a serial USB connection is detected on the communication module side, the communication module identification code is obtained through the serial USB connection. Thus, the first communication port and the first long-term connection channel can be bound based on the obtained communication module identification code, avoiding duplicate data transmission. Moreover, during data transmission, the communication port is preferentially used for data transmission; since the communication port is a physical connection, data transmission stability can be guaranteed.
[0069] Regarding the process of establishing a connection channel between the server and the communication module, S303 above, after authenticating the terminal based on the first user identity information carried in the connection establishment request, establishes a connection channel between the server and the terminal, which can be specifically implemented as follows: Step A: After the terminal is authenticated based on the first user identity information carried in the connection establishment request, a second long connection channel is established between the server and the terminal.
[0070] The second long connection channel is a network connection, specifically a TCP connection.
[0071] Step B: If the second communication port accessed by the terminal is detected, obtain the second user identity information of the terminal through the second communication port.
[0072] It should be noted that MCUs are typically used to control communication modules and peripheral devices of the communication modules. In this embodiment, the MCU is located on the terminal side and is connected to the terminal via a serial-to-USB adapter. The terminal connects the second communication port of the MCU to the server.
[0073] Step C: If the first user identity information and the second user identity information are the same, establish the binding relationship between the second communication port and the second long connection channel.
[0074] It should be noted that, based on the aforementioned binding relationship between the second communication port and the second long-term connection channel, data transmission is preferentially performed through the second communication port. Specifically, the aforementioned S201, receiving the debugging command sent by the terminal, can be implemented as follows: Debugging commands are sent via the second long connection channel when the second communication port is disconnected.
[0075] Using the method provided in this application embodiment, after successful terminal authentication, a network connection, namely a second long-lived connection channel, is first established between the server and the terminal. Furthermore, upon detecting that the terminal has accessed the second communication port, the second user identity information of the terminal is obtained through the second communication port. In this way, the second communication port and the second long-lived connection channel can be bound based on the obtained second user identity information, avoiding duplicate data transmission. Moreover, during data transmission, the second communication port is preferentially used for data transmission; as a physical connection, the second communication port ensures data transmission stability.
[0076] For local debugging of traditional communication modules, the MCU and cellular network communication module are usually integrated onto a single PCB board, such as... Figure 5 As shown, the user programs and debugs the MCU via a physical interface using a personal computer (PC). The MCU communicates with the cellular network communication module through the physical interface. The cellular network communication module communicates with the developer server through various communication protocols. The developer server communicates with the developer application client via the Internet. In this way, the user can further debug the cellular network communication module based on the communication performance between the developer server and the developer application client to improve the communication quality between them.
[0077] In this embodiment, the communication module is debugged via a remote system. For example... Figure 6As shown, the MCU connects to the software client via a serial-to-USB adapter, with the software client deployed on the terminal. The software client connects to the server via Internet Protocol (IP). The server includes an authentication management module, a connection management module, and a data pass-through module. The server establishes an Internet connection and a physical connection interface (USB port) with the cellular network communication module. The cellular network communication module communicates with the developer server via various communication protocols, and the developer server communicates with the developer application client via the Internet. In this way, users can further debug the cellular network communication module remotely based on the communication performance between the developer server and the developer application client to improve the communication quality between them.
[0078] In some embodiments of this application, the mapping relationship between the first user identity information and the first communication module identification code in step S304 can be specifically implemented as follows: Obtain the availability status of the communication module, which indicates whether a mapping relationship has been established between the communication module and the first user identity information and the first communication module identification code when the availability status is the first value.
[0079] After the server completes the registration of the communication modules, it maintains the availability status of each communication module. When the availability status is the first value, it means that no mapping relationship has been established for the new communication module. When the availability status is the second value, it means that the communication module has established a mapping relationship.
[0080] Using the method provided in this application embodiment, the server maintains the status information corresponding to each communication module and determines whether a corresponding mapping relationship has been established for the communication modules accessing the server based on the availability status of the communication modules. When the availability status is a first value, a mapping relationship is constructed between the first user identity information and the first communication module identification code.
[0081] Based on the same concept, embodiments of this application provide a method for debugging a communication module, applied to a communication module, such as... Figure 7 As shown, the method includes: S701 receives debugging commands sent by the server.
[0082] Among them, the debugging command is the first communication module identification code corresponding to the first user identity information carried in the debugging command, which is determined by the server after receiving the debugging command sent by the terminal according to the mapping relationship between user identity information and communication module identification code; and the debugging command is sent to the communication module corresponding to the first communication module identification code.
[0083] Using the method provided in this application, after receiving a debugging command from a terminal, the server searches for the first communication module identification code corresponding to the first user identity information in the locally stored mapping relationship between user identity information and communication module identification codes, based on the first user identity information carried in the debugging command. The communication module corresponding to the debugging command can be accurately located using the first communication module identification code. Therefore, the server can send the debugging command to the communication module corresponding to the first communication module identification code. In this way, by pre-storing the mapping relationship between user identity information and communication module identification codes in the server, the correspondence between communication modules and users can be pre-built, enabling users to remotely debug communication modules through terminals. This avoids the need for users to manufacture PCB boards for cellular network communication modules, improving debugging efficiency.
[0084] In some embodiments of this application, the communication module includes a cellular module, a power supply circuit, and a hardware watchdog circuit; The cellular module is used to execute debugging commands. The cellular module is the cellular network communication module in the above embodiments.
[0085] The cellular module is also used to send pulse signals to the hardware watchdog circuit at preset intervals.
[0086] A hardware watchdog circuit is used to control the power supply circuit to shut off if no pulse signal is received within a preset time period.
[0087] In addition, such as Figure 8 As shown, the communication module also includes a SIM card module, an antenna module, and a serial port circuit. The serial port circuit includes a Universal Asynchronous Receiver (UART) and a UART-to-USB port module.
[0088] The following combination Figure 9 This application introduces a method for debugging a communication module, as described in its embodiments. Figure 9 As shown, the method includes: S901, the communication module sends a registration request to the server.
[0089] S902, The authentication management module in the server sends an access permission command to the connection management module.
[0090] The authentication management module's method for authenticating the communication module is described in the above embodiments and will not be repeated here.
[0091] S903, the connection management module and the communication module establish a long-term TCP connection.
[0092] In this context, the TCP long-term connection is the first connection channel in the above embodiments.
[0093] S904. The software client sends an establishment request to the authentication management module.
[0094] S905. The authentication management module sends a request to the connection management module to obtain available interfaces.
[0095] The server includes multiple interfaces. The server iterates through the availability status of each interface to obtain the available interfaces.
[0096] S906, The connection management module returns available interfaces to the software client.
[0097] The S907, software client, and communication module establish a data pass-through channel.
[0098] The S908, communication module, and software client perform data transparent transmission and interaction.
[0099] Using the method provided in this application embodiment, users can remotely debug the communication module through a pre-established data transparent transmission channel, avoiding the need for users to design and manufacture hardware, thereby improving debugging efficiency.
[0100] Based on the same concept, embodiments of this application provide a device for debugging a communication module, applied to a server, such as... Figure 10 As shown, the device includes: The receiving module 1001 is used to receive debugging commands sent by the terminal; The determining module 1002 is used to determine the first communication module identification code corresponding to the first user identity information carried in the debugging instruction according to the mapping relationship between user identity information and communication module identification code; The sending module 1003 is used to send the debugging command to the communication module corresponding to the first communication module identification code.
[0101] In one possible implementation, the device further includes, prior to the debugging instructions sent by the receiving terminal: The receiving module 1001 is used to receive the registration request sent by the communication module and the connection establishment request sent by the terminal; A module is established to establish a connection channel between the server and the communication module after the communication module has been authenticated according to the first communication module identification code carried in the registration request. The connection establishment module is used to establish a connection channel between the server and the terminal after the terminal has been authenticated based on the first user identity information carried in the connection establishment request. The construction module is used to construct the mapping relationship between the first user identity information and the first communication module identification code.
[0102] In one possible implementation, the building module is specifically used for: Obtain the availability status of the communication module, whereby the availability status indicates whether a mapping relationship has been established for the communication module; When the available state is the first value, a mapping relationship is constructed between the first user identity information and the first communication module identification code.
[0103] In one possible implementation, the building module is specifically used for: After the communication module is authenticated according to the first communication module identification code carried in the registration request, a first long connection channel is established between the server and the communication module. If the first communication port accessed by the communication module is detected, the second communication module identification code of the communication module is obtained through the first communication port; If the second communication module identification code and the first communication module identification code are the same, a binding relationship is established between the first communication port and the first long connection channel.
[0104] In one possible implementation, the sending module 1003 is specifically used for: Determine the first communication port corresponding to the first communication module identification code; If the first communication port is disconnected, the debugging command is sent through the first long connection channel.
[0105] In one possible implementation, the building module is specifically used for: After the terminal is authenticated based on the first user identity information carried in the connection establishment request, a second long connection channel is established between the server and the terminal. If the second communication port accessed by the terminal is detected, the second user identity information of the terminal is obtained through the second communication port; If the first user identity information and the second user identity information are the same, a binding relationship is established between the second communication port and the second long connection channel.
[0106] In one possible implementation, the receiving module 1001 is specifically used for: The debugging command is sent through the second long connection channel when the second communication port is disconnected.
[0107] It should be noted that the device for debugging the communication module is the same as the method for debugging the communication module applied to the server described above. All implementation methods in the above method embodiments are applicable to the embodiments of this device and can achieve the same technical effect.
[0108] Based on the same concept, embodiments of this application provide a device for debugging a communication module, applied to a communication module, such as... Figure 11 As shown, the device includes: The receiving module 1101 is used to receive the debugging instruction sent by the server; the debugging instruction is the first communication module identification code corresponding to the first user identity information carried in the debugging instruction, determined by the server after receiving the debugging instruction sent by the terminal according to the mapping relationship between user identity information and communication module identification code; and the debugging instruction is sent to the communication module corresponding to the first communication module identification code.
[0109] In one possible implementation, the communication module includes a cellular module, a power supply circuit, and a hardware watchdog circuit; The cellular module is used to execute the debugging instructions; The cellular module is also used to send pulse signals to the hardware watchdog circuit at preset intervals. The hardware watchdog circuit is used to control the power supply circuit to cut off power if the pulse signal is not received within the preset time period.
[0110] It should be noted that the device for debugging the communication module is the same as the method for debugging the communication module applied to the server described above. All implementation methods in the above method embodiments are applicable to the embodiments of this device and can achieve the same technical effect.
[0111] Figure 12 A schematic diagram of the hardware structure of the electronic device provided in an embodiment of this application is shown.
[0112] The terminal device may include a processor 1201 and a memory 1202 storing computer program instructions.
[0113] Specifically, the processor 1201 may include a central processing unit (CPU), an application-specific integrated circuit (ASIC), or one or more integrated circuits that can be configured to implement the embodiments of this application.
[0114] Memory 1202 may include mass storage for data or instructions. For example, and not limitingly, memory 1202 may include a hard disk drive (HDD), floppy disk drive, flash memory, optical disk, magneto-optical disk, magnetic tape, or Universal Serial Bus (USB) drive, or a combination of two or more of these. Where appropriate, memory 1202 may include removable or non-removable (or fixed) media. Where appropriate, memory 1202 may be internal or external to the integrated gateway disaster recovery device. In a particular embodiment, memory 1202 is non-volatile solid-state memory.
[0115] In certain embodiments, memory 1202 may include read-only memory (ROM), random access memory (RAM), disk storage media device, optical storage media device, flash memory device, electrical, optical, or other physical / tangible memory storage device. Thus, generally, memory includes one or more tangible (non-transitory) computer-readable storage media (e.g., memory devices) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described with reference to the methods according to one aspect of this disclosure.
[0116] The processor 1201 reads and executes computer program instructions stored in the memory 1202 to implement any of the communication module debugging methods in the above embodiments.
[0117] In one example, the terminal device may also include a communication interface 1203 and a bus 1204. Wherein, for example... Figure 12 As shown, the processor 1201, memory 1202, and communication interface 1203 are connected through bus 1204 and complete communication with each other.
[0118] The communication interface 1203 is mainly used to realize communication between various modules, devices, units and / or equipment in the embodiments of this application.
[0119] Bus 1204 includes hardware, software, or both, that couples components of an electronic device together. For example, and not limitingly, the bus may include an Accelerated Graphics Port (AGP) or other graphics bus, an Enhanced Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), HyperTransport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an Infinite Bandwidth Interconnect, a Low Pin Count (LPC) bus, a memory bus, a Microchannel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local (VLB) bus, or other suitable buses, or combinations of two or more of these. Where appropriate, bus 1204 may include one or more buses. Although specific buses are described and illustrated in embodiments of this application, any suitable bus or interconnect is contemplated herein.
[0120] Furthermore, in conjunction with the communication module debugging methods in the above embodiments, this application embodiment can provide a computer storage medium for implementation. The computer storage medium stores computer program instructions; when these computer program instructions are executed by a processor, they implement any of the communication module debugging methods in the above embodiments.
[0121] This application also provides a computer program product, including a computer program, which, when executed, implements any of the communication module debugging methods described in the above embodiments.
[0122] It should be clarified that this application is not limited to the specific configurations and processes described above and shown in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of this application is not limited to the specific steps described and shown. Those skilled in the art can make various changes, modifications, and additions, or change the order of steps, after understanding the spirit of this application.
[0123] The functional blocks shown in the above block diagram can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, they can be, for example, electronic circuits, application-specific integrated circuits (ASICs), appropriate firmware, plug-ins, function cards, etc. When implemented in software, the elements of this application are programs or code segments used to perform the required tasks. Programs or code segments can be stored on a machine-readable medium or transmitted over a transmission medium or communication link via data signals carried on a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, fiber optic media, radio frequency (RF) links, etc. Code segments can be downloaded via computer networks such as the Internet, intranets, etc.
[0124] It should also be noted that the exemplary embodiments mentioned in this application describe methods or systems based on a series of steps or apparatus. However, this application is not limited to the order of the above steps; that is, the steps can be performed in the order mentioned in the embodiments, or in a different order, or several steps can be performed simultaneously.
[0125] The aspects of this disclosure have been described above with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this disclosure. It should be understood that each block in the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus to produce a machine such that these instructions, executable via the processor of the computer or other programmable data processing apparatus, enable the implementation of the functions / actions specified in one or more blocks of the flowchart illustrations and / or block diagrams. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field-programmable logic circuit. It is also understood that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can also be implemented by special-purpose hardware performing the specified functions or actions, or can be implemented by a combination of special-purpose hardware and computer instructions.
[0126] The above are merely specific embodiments of this application. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, modules, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. It should be understood that the protection scope of this application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and these modifications or substitutions should all be covered within the protection scope of this application.
Claims
1. A method for debugging a communication module, characterized in that, Applied to a server, the method includes: Receive debugging commands sent by the terminal; Based on the mapping relationship between user identity information and communication module identification code, determine the first communication module identification code corresponding to the first user identity information carried in the debugging instruction; Send the debugging command to the communication module corresponding to the first communication module identification code.
2. The method according to claim 1, characterized in that, Before the debugging command sent by the receiving terminal, the method further includes: Receive the registration request sent by the communication module and the connection establishment request sent by the terminal; After the communication module is authenticated according to the first communication module identification code carried in the registration request, a connection channel between the server and the communication module is established. After the terminal is authenticated based on the first user identity information carried in the connection establishment request, a connection channel between the server and the terminal is established. Construct a mapping relationship between the first user identity information and the first communication module identification code.
3. The method according to claim 2, characterized in that, The step of constructing the mapping relationship between the first user identity information and the first communication module identification code includes: Obtain the availability status of the communication module, whereby the availability status indicates whether a mapping relationship has been established for the communication module; When the available state is the first value, a mapping relationship is constructed between the first user identity information and the first communication module identification code.
4. The method according to claim 2, characterized in that, After the communication module is authenticated according to the first communication module identification code carried in the registration request, a connection channel is established between the server and the communication module, including: After the communication module is authenticated according to the first communication module identification code carried in the registration request, a first long connection channel is established between the server and the communication module. If the first communication port accessed by the communication module is detected, the second communication module identification code of the communication module is obtained through the first communication port; If the second communication module identification code and the first communication module identification code are the same, a binding relationship is established between the first communication port and the first long connection channel.
5. The method according to claim 4, characterized in that, Sending the debugging command to the communication module corresponding to the first communication module identification code includes: Determine the first communication port corresponding to the first communication module identification code; If the first communication port is disconnected, the debugging command is sent through the first long connection channel.
6. The method according to claim 2, characterized in that, After authenticating the terminal based on the first user identity information carried in the connection establishment request, a connection channel is established between the server and the terminal, including: After the terminal is authenticated based on the first user identity information carried in the connection establishment request, a second long connection channel is established between the server and the terminal. If the second communication port accessed by the terminal is detected, the second user identity information of the terminal is obtained through the second communication port; If the first user identity information and the second user identity information are the same, a binding relationship is established between the second communication port and the second long connection channel.
7. The method according to claim 6, characterized in that, The debugging instructions sent by the receiving terminal include: The debugging command is sent through the second long connection channel when the second communication port is disconnected.
8. A method for debugging a communication module, characterized in that, Applied to a communication module, the method includes: The server receives a debugging instruction from the terminal; the debugging instruction is determined by the server after receiving the debugging instruction from the terminal, based on the mapping relationship between user identity information and communication module identification code, and the server determines the first communication module identification code corresponding to the first user identity information carried in the debugging instruction; the server then sends the debugging instruction to the communication module corresponding to the first communication module identification code.
9. The method according to claim 8, characterized in that, The communication module includes a cellular module, a power supply circuit, and a hardware watchdog circuit; The cellular module is used to execute the debugging instructions; The cellular module is also used to send pulse signals to the hardware watchdog circuit at preset intervals. The hardware watchdog circuit is used to control the power supply circuit to cut off power if the pulse signal is not received within the preset time period.
10. A device for debugging a communication module, characterized in that, Applied to a server, the device includes: The receiving module is used to receive debugging commands sent by the terminal; The determination module is used to determine the first communication module identification code corresponding to the first user identity information carried in the debugging instruction according to the mapping relationship between user identity information and communication module identification code; The sending module is used to send the debugging command to the communication module corresponding to the first communication module identification code.
11. A device for debugging a communication module, characterized in that, The device, applied to a communication module, includes: A receiving module is used to receive debugging instructions sent by a server. The debugging instructions are generated by the server after receiving the debugging instructions sent by the terminal, determining the first communication module identification code corresponding to the first user identity information carried in the debugging instructions according to the mapping relationship between user identity information and communication module identification code, and sending the debugging instructions to the communication module corresponding to the first communication module identification code.
12. An electronic device, characterized in that, The device includes: a processor and a memory storing computer program instructions; When the processor executes the computer program instructions, it implements the communication module debugging method as described in any one of claims 1-4, or the communication module debugging method as described in any one of claims 8-9.
13. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer program instructions, which, when executed by a processor, implement the communication module debugging method as described in any one of claims 1-4, or the communication module debugging method as described in any one of claims 8-9.
14. A computer program product, characterized in that, When the instructions in the computer program product are executed by the processor of the electronic device, the electronic device performs the communication module debugging method as described in any one of claims 1-4, or implements the communication module debugging method as described in any one of claims 8-9.