Log transmission method, communication module, and device and readable storage medium

By introducing a merged transmission mechanism into the Wi-Fi and WWAN communication modules, the problem of insufficient robustness in log data collection is solved, and reliable log transmission is achieved under fault or bandwidth-limited conditions, thereby improving the robustness of log collection and development and maintenance efficiency.

WO2026233198A1PCT designated stage Publication Date: 2026-11-12FIBOCOM WIRELESS
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2026/093842
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2025-05-09
Filing Date
2026-04-29
Publication Date
2026-11-12

AI Technical Summary

Technical Problem

In existing Wi-Fi and WWAN combined communication modules, log data collection robustness is insufficient, and independent output mechanisms lead to information loss and dispersion.

Method used

By introducing a merged transmission mechanism in the communication module, the local log data of the chip to be transferred is encapsulated into log data packets using the communication channel between the first chip and the second chip, and then sent to the host through the direct transmission chip, thus realizing the merged transmission of log data.

Benefits of technology

It improves the robustness of log collection, ensuring reliable transmission of log data even in the event of channel failure or bandwidth limitations, avoiding information loss and dispersion, simplifying the log acquisition and parsing process, and improving development and maintenance efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2026093842_12112026_PF_FP_ABST
    Figure CN2026093842_12112026_PF_FP_ABST
Patent Text Reader

Abstract

Disclosed are a log transmission method, a communication module, and a device and a readable storage medium. The log transmission method is applied to a communication module, and the communication module comprises a first chip supporting a first communication mode and a second chip supporting a second communication mode. The method comprises: using a first chip to generate local log data corresponding to a first communication mode, and using a second chip to generate local log data corresponding to a second communication mode; when determining to perform combined transmission, determining a forwarding chip and a direct sending chip from the first chip and the second chip; encapsulating the local log data of the forwarding chip into a log data packet, and using a communication channel between the first chip and the second chip to send the log data packet to the direct sending chip; and using a log channel of the direct sending chip to send the log data packet and local log data of the direct transmitting chip to a host side.
Need to check novelty before this filing date? Find Prior Art

Description

Log transmission method, communication module, device and readable storage medium

[0001] Citation of relevant applications

[0002] This disclosure claims the entire benefits of Chinese Patent Application No. 202510596388.4, filed on May 9, 2025 with the State Intellectual Property Office of the People's Republic of China, entitled "A Log Transmission Method, Communication Module, Device and Readable Storage Medium", the entire contents of which are incorporated herein by reference.

[0003] field

[0004] This disclosure generally relates to the field of communication technology, and more specifically to log transmission methods, communication modules, devices, and readable storage media.

[0005] background

[0006] The Wi-Fi (Wireless Fidelity) and WWAN (Wireless Wide Area Network) integrated communication module can provide both Wi-Fi and WWAN interfaces to the host simultaneously, and the host or module can independently decide the Internet access method, greatly improving the flexibility and adaptability of network access.

[0007] In a dual-function module, both the Wi-Fi chip and the WWAN chip generate a large amount of log data during operation. This log data records the operational status of the communication protocol stack, the interaction of hardware interfaces, and potential abnormal events. This log data is typically output through independent mechanisms for the Wi-Fi and WWAN chips. While these mechanisms generally meet the log acquisition needs, the independent output mechanisms also introduce problems such as insufficient robustness in log collection.

[0008] Overview

[0009] On one hand, this disclosure relates to a log transmission method applied to a communication module, the communication module including a first chip supporting a first communication mode and a second chip supporting a second communication mode, the method comprising:

[0010] The first chip is used to generate local log data corresponding to the first communication mode, and the second chip is used to generate local log data corresponding to the second communication mode.

[0011] If it is determined that a merged transmission will be performed, the chip to be transferred and the chip to be directly transmitted are determined from the first chip and the second chip;

[0012] The local log data of the chip to be converted is encapsulated into a log data packet, and the log data packet is sent to the direct-transmission chip using the communication channel between the first chip and the second chip; and

[0013] The log data packet and the local log data of the direct-transmission chip are sent to the host using the log channel of the direct-transmission chip.

[0014] In some implementations, the local log data of the chip to be transferred is encapsulated into a log data packet, including:

[0015] A timestamp and the chip's identifier are added to the local log data of the chip to be transferred, so that the host can use the timestamp and the identifier to determine the source of the log data; and

[0016] After the completion time and identifier are added, the local log data of the chip to be transferred is encapsulated into the log data packet.

[0017] In some implementations, the log data packets are sent to the direct-transmission chip using the communication channel between the first chip and the second chip, including:

[0018] The log data packet is sent to the direct-transmission chip using the serial bus between the first chip and the second chip.

[0019] In some implementations, the log data packets are sent to the direct-transmission chip using the communication channel between the first chip and the second chip, including:

[0020] A communication channel is established between the first chip and the second chip using shared memory; and

[0021] The log data packet is sent to the direct-transmission chip using the communication channel.

[0022] In some implementations, determining whether to perform a merged transmission includes:

[0023] The log channels of the first chip and the second chip are inspected;

[0024] If there is a log channel failure in the first chip or the second chip, then merged transmission will be performed.

[0025] Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including:

[0026] The chip with a log channel fault in the first chip and the second chip is identified as the chip to be transferred; and

[0027] The chip with a normal log channel among the first chip and the second chip is identified as the direct-transmission chip.

[0028] In some implementations, determining whether to perform a merged transmission includes:

[0029] Monitor the communication data transmission volume corresponding to the first chip and the second chip respectively;

[0030] If the communication transmission volume of the first chip or the second chip exceeds the threshold, it is determined to merge the transmission.

[0031] Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including:

[0032] The chip in the first chip and the second chip whose communication data transmission volume exceeds the threshold is identified as a chip to be converted; and

[0033] The chip whose communication data transmission volume does not exceed the threshold in the first chip and the second chip is identified as the direct-transmission chip.

[0034] In some implementations, determining whether to perform a merged transmission includes:

[0035] Get the current log transmission mode;

[0036] If the log transmission mode is the merge transmission mode, then merge transmission will be performed.

[0037] Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including:

[0038] According to the chip transmission settings corresponding to the merged transmission mode, the chip to be transferred and the chip to be directly transmitted are determined from the first chip and the second chip.

[0039] On the other hand, this disclosure relates to a communication module, including: a first chip supporting a first communication mode and a second chip supporting a second communication mode;

[0040] The log collection unit is configured to generate local log data corresponding to the first communication mode using the first chip, and to generate local log data corresponding to the second communication mode using the second chip.

[0041] The transmission determination unit is configured to determine the chip to be transferred and the direct transmission chip from the first chip and the second chip when it is determined that a merged transmission will be performed;

[0042] An inter-chip transmission unit is configured to encapsulate the local log data of the chip to be transferred into a log data packet, and send the log data packet to the direct-transmission chip using the communication channel between the first chip and the second chip; and

[0043] The log output unit is configured to use the log channel of the direct-transmission chip to send the log data packet and the local log data of the direct-transmission chip to the host.

[0044] In another aspect, this disclosure relates to electronic devices, including:

[0045] Memory, configured to store computer programs; and

[0046] A processor configured to implement the log transmission method described herein when executing the computer program.

[0047] In another aspect, this disclosure relates to a readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the log transmission method described in this disclosure.

[0048] In some implementations, a communication module supporting two communication modes includes a first chip and a second chip. The first and second chips generate local log data corresponding to their respective supported communication modes. When merged transmission is required, a chip to be transferred and a direct-transmission chip can be identified from the first and second chips. For the chip to be transferred, its corresponding local log data is encapsulated into log data and sent to the direct-transmission chip via the communication channel between the first and second chips. For the direct-transmission chip, it sends its own local log data to the host along with the received log data packets. In other words, in this disclosure, for communication modules supporting communication modes, the log outputs of the first and second chips are no longer completely independent; they can internally transfer log data and achieve merged transmission of log data. Thus, in situations such as log channel failure or bandwidth limitations, log data can continue to be transmitted to the host through merged transmission, improving the robustness of log collection.

[0049] Accordingly, this disclosure also provides a log transmission communication module, device, and readable storage medium corresponding to the above-described log transmission method, which have the above-described technical effects, and will not be repeated here.

[0050] Brief description of the attached figures

[0051] To more clearly illustrate the technical solutions in the embodiments or related technologies of this disclosure, the accompanying drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this disclosure. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0052] Figure 1 shows a flowchart of the implementation of the log transmission method in one embodiment of the present disclosure;

[0053] Figure 2 shows a system architecture diagram of a communication module according to an embodiment of the present disclosure;

[0054] Figure 3 shows a flowchart of the fault switching implementation of the log transmission method in one embodiment of the present disclosure;

[0055] Figure 4 shows a flowchart of the merged output implementation of the log transmission method in one embodiment of this disclosure;

[0056] Figure 5 shows a schematic diagram of a communication module according to an embodiment of the present disclosure;

[0057] Figure 6 shows a schematic diagram of the structure of an electronic device according to an embodiment of the present disclosure; and

[0058] Figure 7 shows a schematic diagram of the specific structure of an electronic device according to an embodiment of the present disclosure.

[0059] Detailed Explanation

[0060] To enable those skilled in the art to better understand the solutions of this disclosure, the following detailed description is provided in conjunction with the accompanying drawings and specific embodiments. Obviously, the described embodiments are merely some embodiments of this disclosure, and not all embodiments. Based on the embodiments of this disclosure, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this disclosure.

[0061] Please refer to Figure 1, which is a flowchart of a log transmission method according to an embodiment of this disclosure. The method is applied to a communication module, which includes a first chip supporting a first communication mode and a second chip supporting a second communication mode. The method includes the following steps:

[0062] S101. Use the first chip to generate local log data corresponding to the first communication mode, and use the second chip to generate local log data corresponding to the second communication mode.

[0063] S102. If it is determined that a merged transmission will be performed, the chip to be transferred and the direct transmission chip are determined from the first chip and the second chip.

[0064] S103. Encapsulate the local log data of the chip to be converted into a log data packet, and send the log data packet to the direct-transmission chip using the communication channel between the first chip and the second chip; and

[0065] S104. Using the log channel of the direct-transmission chip, send log data packets and local log data of the direct-transmission chip to the host.

[0066] In some implementations, the first chip and the second chip can be chips that support different communication modes. In some implementations, the first chip can be a Wi-Fi chip or a WWAN chip. In some implementations, if the first chip is a Wi-Fi chip, then the second chip can be a WWAN chip. Accordingly, the first communication mode is to achieve communication transmission by accessing a local area network via Wi-Fi, and the second communication mode is to achieve data transmission by accessing a mobile network via WWAN.

[0067] It should be noted that in this disclosure, "first" and "second" are used only to indicate the existence of two different chips or communication modes, and not to limit the order, importance, etc.

[0068] Both the first and second chips generate local log data during operation to record the running status of the communication protocol stack, the interaction of hardware interfaces, and possible abnormal events.

[0069] In this embodiment, there are no limitations on the content, format, or quantity of the local log data generated by the first chip and the second chip respectively.

[0070] It should be noted that, generally speaking, log collection for communication chips that support different communication modes is often performed independently.

[0071] In some implementations, in order to improve the robustness of log data collection corresponding to communication in the communication module, when it is determined to perform merged transmission, the log outputs of the first chip and the second chip are no longer independent of each other, but can be forwarded on behalf of each other. That is, the first chip can help the second chip transmit log data, and the second chip can also assist the first chip in transmitting log data.

[0072] In some implementations, when it is determined that the transmission needs to be merged, it is first necessary to determine which chip is the direct transmission chip and which chip is the chip to be transferred.

[0073] In some implementation schemes, trigger conditions for merging transmissions can be preset. When the trigger conditions are met, it can be determined that merging transmissions are necessary. The trigger conditions can be set and adjusted according to the actual situation.

[0074] In some implementations, the direct-transmit chip, i.e., the local log data it generates, is still transmitted externally by itself. In addition, it needs to assist the chip to be transferred in sending log data externally; the chip to be transferred, i.e., the local log data it generates, is to be sent out by the direct-transmit chip.

[0075] In some implementations, the first chip can be either a chip to be converted or a direct-transmission chip. In some implementations, if the first chip is a chip to be converted, then the second chip is a direct-transmission chip; if the first chip is a direct-transmission chip, then the second chip is a chip to be converted.

[0076] In some implementations, determining whether to perform a merged transmission includes:

[0077] The log channels of the first and second chips are inspected;

[0078] If the log channel of the first chip or the second chip fails, then merged transmission will be performed.

[0079] Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including:

[0080] The chip with a log channel fault in the first and second chips was identified as the chip to be transferred; and

[0081] The chip with a normal log channel in the first and second chips is identified as the direct transmission chip.

[0082] For ease of description, the above steps will be combined below.

[0083] In some implementations, merged transmission can be performed in the event of a log channel failure in either the first or second chip. The chip whose log channel fails is designated as the chip to be transferred, while the chip whose log channel is functioning normally is designated as the chip for direct transmission.

[0084] In some implementations, if the first chip is a Wi-Fi chip and the second chip is a WWAN chip, by detecting the log channels of the Wi-Fi chip and the WWAN chip, if it is found that the log channel of the Wi-Fi chip is faulty and unavailable, while the log channel of the WWAN chip is normal and available, then it can be determined to merge the transmission, and the Wi-Fi chip is identified as the chip to be transferred, and the WWAN chip is identified as the direct transmission chip.

[0085] In some implementations, determining whether to perform a merged transmission includes:

[0086] Monitor the communication data transmission volume corresponding to the first chip and the second chip respectively;

[0087] If the communication transmission volume of the first chip or the second chip exceeds the threshold, it is determined to merge the transmission.

[0088] Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including:

[0089] The chip whose communication data transmission volume exceeds the threshold in the first and second chips is identified as the chip to be transferred; and

[0090] The chip whose communication data transmission volume between the first chip and the second chip does not exceed the threshold is identified as the direct-transmission chip.

[0091] For ease of description, the above steps will be combined below.

[0092] When the communication modules are communicating, the first and second chips will generate not only log data, but also data for external communication. When the business volume is large, communication data and log data will compete for resources, resulting in reduced real-time performance of communication services and untimely or failed log data transmission.

[0093] Therefore, in some implementations, the communication transmission volume of the first chip and the second chip can be monitored. If the communication transmission volume of either the first chip or the second chip exceeds a threshold, it can be determined that a merged transmission will occur. In some implementations, the chip whose communication transmission volume exceeds the threshold is designated as the forwarding chip, and the other chip is designated as the direct transmission chip.

[0094] In some implementation schemes, when the first or second communication mode is currently being used, the chip corresponding to the current communication mode is often busy, while the other chip is relatively idle. In this case, by performing merged transmission, the bandwidth corresponding to the chip of the other communication mode that is not in use can be reasonably utilized.

[0095] In some implementations, if the first chip is a Wi-Fi chip and the second chip is a WWAN chip, the communication transmission volume of the Wi-Fi chip and the WWAN chip is detected. If the communication transmission volume of the WWAN chip exceeds the threshold, it can be determined to merge the transmission, and the WWAN chip is identified as the chip to be transferred, while the Wi-Fi chip is identified as the direct transmission chip.

[0096] In some implementations, determining whether to perform a merged transmission includes:

[0097] Get the current log transmission mode;

[0098] If the log transmission mode is merge transmission mode, then merge transmission will be performed.

[0099] Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including:

[0100] According to the chip transmission settings corresponding to the merged transmission mode, the chip to be transferred and the chip to be directly transmitted are determined from the first chip and the second chip.

[0101] For ease of description, the above steps will be combined below.

[0102] In some implementations, different log transmission modes can be pre-configured, such as independent transmission mode and merged transmission mode.

[0103] In some implementations, if the current log transmission model is determined to be a merged transmission mode, merged transmission can be directly determined. For merged transmission mode, chip transmission settings can be predefined. Once merged transmission mode is determined, the chips to be transferred and the chips to be directly transmitted can be determined directly based on the chip transmission settings.

[0104] In some implementations, the log transmission mode can be controllably selected between independent transmission mode and merged transmission mode, thereby enabling controllable adjustment of whether to enter merged transmission, and the log transmission roles of the first chip and the second chip respectively in merged transmission mode.

[0105] In some implementations, to easily distinguish it from the local log data of the direct-transmission chip, the local log data of the chip to be converted can be encapsulated into a log data packet. Then, based on the communication channel between the first chip and the second chip, the log data packet is sent to the direct-transmission chip.

[0106] In some implementations, the communication module can be designed as a multi-chip package (MCM / SiP), meaning that communication between the first chip and the second chip can be accomplished in a variety of ways.

[0107] In some implementations, the local log data of the chip to be transferred is encapsulated into a log data packet, including:

[0108] Add a timestamp and the chip's identifier to the local log data of the chip to be transferred, so that the host can use the timestamp and identifier to determine the source of the log data; and

[0109] After the completion time and identifier are added, the local log data of the chip to be transferred is encapsulated into a log data packet.

[0110] In some implementations, to enable the host to effectively distinguish log data from different chips, a timestamp and the chip's identifier can be added to the local log data of the chip to be transferred. The chip's identifier can be an identifier of the communication mode supported by the chip; for example, if the chip is a Wi-Fi chip, the identifier is 1, and if it is a WWAN chip, the identifier is 0. In other words, the chip's identifier can be information mutually agreed upon with the host to ensure the source of the log data is identifiable.

[0111] In some implementations, after adding timestamps and identifiers, the local log data of the chip to be transferred can be encapsulated into log data packets.

[0112] In some implementations, log data packets are sent to the direct-transmission chip using the communication channel between the first chip and the second chip, including: sending log data packets to the direct-transmission chip using the serial bus between the first chip and the second chip.

[0113] In some implementations, the first chip and the second chip can communicate with each other via a direct PCIe connection. In some implementations, within the communication module, the first chip and the second chip act as PCIe endpoints (EPs) and communicate with each other through an internal PCIe switch or a directly connected PCIe channel. In some implementations, when the first chip is a Wi-Fi chip and the second chip is a WWAN chip, the transmission of log data packets via the serial bus between the first and second chips can be as follows: the Wi-Fi chip sends the log data packets to the PCIe switch, and the PCIe switch then sends the log data packets to the WWAN chip; alternatively, the WWAN chip can send the log data packets to the PCIe switch, and the PCIe switch then sends the log data packets to the Wi-Fi chip.

[0114] In some implementations, log data packets are sent to the direct-transmission chip using the communication channel between the first chip and the second chip, including:

[0115] Establish a communication channel between the first chip and the second chip using shared memory; and

[0116] Log data packets are sent to the direct-transmission chip via the communication channel.

[0117] For ease of description, the above steps will be combined below.

[0118] In some implementations, a communication channel between the first chip and the second chip can be established within the communication module via shared memory. Then, log data packets can be sent to the direct-transmission chip using this communication channel.

[0119] In some implementations, communication is based on shared memory: within the MCM / SiP module, Wi-Fi and WWAN share a high-speed cache or memory (SRAM / DDR) and exchange data through memory-mapped IO (MMIO), enabling the forwarding chip to send log data packets to the direct-transmitting chip. Specifically, the shared memory partitioning involves Wi-Fi and WWAN sharing a dedicated memory area for data exchange (e.g., shared RAM).

[0120] In some implementations, data read and write operations are controlled through the SoC's internal MMU (Memory Management Unit) or DMA to avoid data conflicts.

[0121] Data flow path (based on shared memory): The Wi-Fi chip writes log data packets to the TX buffer in shared memory, and the WWAN chip reads the TX buffer via PCIe to parse the data and send it to the cellular network; or, the WWAN chip writes log data packets to the RX buffer in shared memory, and then the Wi-Fi chip reads the RX buffer via PCIe to parse the data and finally sends the log data packets to the Wi-Fi end.

[0122] In some implementations, DMA can also be used for optimization to reduce CPU intervention.

[0123] In some implementations, communication between the first chip and the second chip can also be achieved based on DMA (Direct Memory Access) communication. In some implementations, based on a shared memory scheme, Wi-Fi and WWAN can directly transfer data through the DMA controller, avoiding CPU involvement and improving transmission efficiency.

[0124] Data flow path (DMA based), including:

[0125] The Wi-Fi chip sends log data packets, triggering DMA transfer, and the data is directly transferred to the WWAN device memory;

[0126] The WWAN chip sends log data packets, triggering DMA transfer, and directly transfers the data to the Wi-Fi device's memory.

[0127] This method can reduce CPU intervention and improve bandwidth utilization.

[0128] In some implementations, the direct-transmission chip can send log data packets and local log data of the direct-transmission chip to the host through its own log channel.

[0129] In some implementations, the direct-transmit chip not only transmits its own local log data to the host, but also forwards the log data packets from the forwarding chip to the host.

[0130] In some implementations, the host can obtain the local log data generated by the first chip and the local log data generated by the second chip by receiving the log data sent by the direct transmission chip.

[0131] In some implementations, a communication module supporting two communication modes includes a first chip and a second chip. The first and second chips generate local log data corresponding to their respective supported communication modes. When merged transmission is required, a chip to be transferred and a direct-transmission chip can be identified from the first and second chips. For the chip to be transferred, its corresponding local log data is encapsulated into log data and sent to the direct-transmission chip via the communication channel between the first and second chips. For the direct-transmission chip, it sends its own local log data to the host along with the received log data packets. In other words, in this disclosure, for communication modules supporting communication modes, the log outputs of the first and second chips are no longer completely independent; they can internally transfer log data and achieve merged transmission of log data. Thus, in situations such as log channel failure or bandwidth limitations, log data can continue to be transmitted to the host through merged transmission, improving the robustness of log collection.

[0132] To facilitate those skilled in the art to better understand and implement the log transmission method provided in the embodiments of this disclosure, the log transmission method will be described in detail below with reference to specific scenarios.

[0133] When the first and second chips correspond to the Wi-Fi chip and WWAN chip, respectively, and the communication module is a two-in-one module, the Wi-Fi chip and WWAN chip provide log output through their respective independent external interfaces (such as UART, USB, or PCIe). These interfaces are responsible for transmitting the module's internal operating information and diagnostic data to the host, providing crucial support for device development, debugging, and maintenance. To further enhance the module's log acquisition capabilities and improve log acquisition robustness, the two-in-one module can add an inter-chip data channel within the module between the Wi-Fi and WWAN chips. This data channel supports efficient data interaction between the two chips, allowing log data to be shared and transmitted within the module.

[0134] In practical implementation, each chip can be equipped with a built-in cross-channel log transmission mechanism to ensure reliable log transmission under both normal and abnormal conditions. When a chip's log output channel fails due to hardware failure, communication anomalies, or resource conflicts, the chip automatically switches to cross-channel transmission mode, encapsulates its generated log data, and outputs it to the host through another chip's external interface. This mechanism ensures the integrity and availability of log data, avoiding information loss caused by single-point failures in the log channel.

[0135] Furthermore, this architecture supports configuring the two chips in the integrated module to output logs from a single external interface under specific scenarios or special requirements. For example, in complex network switching or collaborative debugging scenarios, Wi-Fi and WWAN logs can be output to the host through a single high-bandwidth interface (such as PCIe), forming a unified log data source. This approach not only simplifies the log acquisition and parsing process but also significantly reduces the risk of information fragmentation caused by decentralized logging mechanisms, facilitating comprehensive analysis of cross-module correlation issues. Simultaneously, the flexibility of this design meets various debugging needs, enabling the module to adapt to diverse complex application scenarios and further improving development and maintenance efficiency.

[0136] Please refer to Figure 2, which is a system architecture diagram of the communication module in one embodiment of this disclosure. That is, the WI-FI and WWAN chips of the two-in-one module each provide external interfaces; the WI-FI and WWAN chips of the two-in-one module have their own storage chips; and there is a data channel between the WI-FI and WWAN chips.

[0137] Please refer to Figure 3, which is a flowchart illustrating the fault switching implementation of the log transmission method in one embodiment of this disclosure. In the design of the two-in-one module, the log fault switching mode ensures the log reliability of the Wi-Fi and WWAN modules. When a fault is detected in the log channel of a certain module (e.g., physical interface damage, transmission abnormality, or communication interruption), the log acquisition module immediately initiates the fault switching mechanism, encapsulates the log data generated by the current module, and sends it to the other module through its internal cross-module transmission channel. After receiving the log data, the other module transmits the encapsulated data to the host through its normally functioning log channel.

[0138] On the host side, the log management module decapsulates the received log data, restoring it to its original format. Based on the timestamps and module identifiers in the logs, it accurately classifies and stores the log data. Through this mechanism, even if the log channel of one module fails, the host can still reliably and completely obtain log data from both modules.

[0139] This mechanism not only ensures the availability of log data in fault scenarios, but also ensures accurate traceability and correlation analysis capabilities of log data through unified timestamps and module identifiers, thereby avoiding the problem of log loss due to single point of failure and improving the robustness and maintenance efficiency of the system.

[0140] Please refer to Figure 4, which is a flowchart illustrating the merged output implementation of the log transmission method in one embodiment of this disclosure. That is, through system configuration, under specific scenarios or special requirements, the logs from the Wi-Fi and WWAN chips in the dual-function module are uniformly output to the same external interface. In some implementations, when complex network switching or collaborative debugging is required, the logs from both chips can be centrally transmitted to the host via a high-bandwidth interface (such as PCIe), forming a unified log data source.

[0141] In some implementations, a cross-channel log transmission mechanism is provided: by implementing cross-channel data transmission between the WI-FI and WWAN chips in the two-in-one module, when the log channel of one chip fails, the transmission channel of the other module is automatically switched to forward logs, ensuring the integrity and availability of logs in the event of a failure.

[0142] In some implementations, a log fault switching function is provided: an intelligent log switching mechanism is designed so that when the log channel is abnormal (such as interface damage or communication interruption), the log data can be automatically forwarded to the host through the normal channel of another module, ensuring seamless transmission and recovery of log data.

[0143] In some implementations, unified log output is achieved: through system configuration, logs from Wi-Fi and WWAN chips can be uniformly output to a single interface (such as PCIe) under specific requirements, which simplifies the log capture and analysis process, avoids log fragmentation, and improves the efficiency of diagnosing and resolving cross-module related problems.

[0144] In some implementations, this disclosure not only improves the reliability and consistency of logs, but also enhances the module's adaptability in complex debugging and maintenance scenarios, greatly improving development and operation efficiency.

[0145] In other words, the cross-channel log acquisition mechanism provided in this disclosure realizes the sharing and transmission of Wi-Fi and WWAN logs in the two-in-one module, solving the problems of single-point failure and fragmentation of log channels, and providing a reliable log acquisition method for device development, debugging, and maintenance. Furthermore, it enables dynamic response and scheduling optimization: in the event of a single-point failure in a channel, it can trigger rapid log synchronization and transmission; it solves the problem of multi-module log sharing: it realizes bidirectional log transmission between the Wi-Fi and WWAN components in the two-in-one module, supporting dynamic synchronization and sharing; and it achieves unified log management: by configuring the two-in-one module, logs can be uniformly output through a single interface, effectively solving the problems of log fragmentation and improving log analysis efficiency in complex scenarios.

[0146] Corresponding to the above method embodiments, this disclosure also provides a communication module, which can be referred to in correspondence with the log transmission method described above.

[0147] As shown in Figure 5, the communication module includes a first chip supporting a first communication mode and a second chip supporting a second communication mode;

[0148] Log collection unit 201 is configured to generate local log data corresponding to the first communication mode using the first chip and to generate local log data corresponding to the second communication mode using the second chip.

[0149] The transmission determination unit 202 is configured to determine the chip to be transferred and the direct transmission chip from the first chip and the second chip when it is determined that a merged transmission will be performed.

[0150] The inter-chip transmission unit 203 is configured to encapsulate the local log data of the chip to be transferred into a log data packet, and send the log data packet to the direct-transmission chip using the communication channel between the first chip and the second chip; and

[0151] Log output unit 204 is configured to use the log channel of the direct-transmission chip to send log data packets and local log data of the direct-transmission chip to the host.

[0152] In some implementations, a communication module supporting two communication modes includes a first chip and a second chip. The first and second chips generate local log data corresponding to their respective supported communication modes. When merged transmission is required, a chip to be transferred and a direct-transmission chip can be identified from the first and second chips. For the chip to be transferred, its corresponding local log data is encapsulated into log data and sent to the direct-transmission chip via the communication channel between the first and second chips. For the direct-transmission chip, it sends its own local log data to the host along with the received log data packets. In other words, in this disclosure, for communication modules supporting communication modes, the log outputs of the first and second chips are no longer completely independent; they can internally transfer log data and achieve merged transmission of log data. Thus, in situations such as log channel failure or bandwidth limitations, log data can continue to be transmitted to the host through merged transmission, improving the robustness of log collection.

[0153] In some implementations, the inter-chip transmission unit is configured to add a timestamp and the identifier of the chip to be transferred to the local log data of the chip to be transferred, so that the host can use the timestamp and the identifier to determine the source of the log data; after the timestamp and identifier are added, the local log data of the chip to be transferred is encapsulated into a log data packet.

[0154] In some implementations, the inter-chip transmission unit is configured to send log data packets to the direct-transmission chip using a serial bus between the first chip and the second chip.

[0155] In some implementations, the inter-chip transmission unit is configured to establish a communication channel between the first chip and the second chip using shared memory; and to send log data packets to the direct-transmission chip using the communication channel.

[0156] In some implementations, the transmission determination unit is configured to inspect the log channels of the first chip and the second chip; if a log channel failure exists in either the first chip or the second chip, it is determined to perform merged transmission; accordingly, the chip to be transferred and the chip to be directly transmitted are determined from the first chip and the second chip, including: determining the chip with a log channel failure in the first chip and the second chip as the chip to be transferred; and determining the chip with a normal log channel in the first chip and the second chip as the chip to be directly transmitted.

[0157] In some implementations, the transmission determination unit is configured to monitor the communication data transmission volume corresponding to the first chip and the second chip respectively; if the communication data transmission volume of the first chip or the second chip exceeds a threshold, it is determined to merge the transmission; accordingly, the chip to be transferred and the chip to be directly transmitted are determined from the first chip and the second chip, including: determining the chip in the first chip and the second chip whose communication data transmission volume exceeds the threshold as the chip to be transferred; and determining the chip in the first chip and the second chip whose communication data transmission volume does not exceed the threshold as the chip to be directly transmitted.

[0158] In some implementations, the transmission determination unit is configured to obtain the current log transmission mode; if the log transmission mode is a merge transmission mode, then determine to perform merge transmission; accordingly, determine the chip to be transferred and the chip to be directly transmitted from the first chip and the second chip, including: determining the chip to be transferred and the chip to be directly transmitted from the first chip and the second chip according to the chip transmission settings corresponding to the merge transmission mode.

[0159] Corresponding to the above method embodiments, this disclosure also provides an electronic device. The electronic device described below and the log transmission method described above can be referred to in correspondence.

[0160] As shown in Figure 6, the electronic device includes:

[0161] Memory 332 is configured to store computer programs;

[0162] Processor 322 is configured to implement the log transmission method described herein when executing a computer program.

[0163] Please refer to Figure 7, which is a schematic diagram of the specific structure of the electronic device provided in this embodiment. This electronic device can vary significantly due to differences in configuration or performance. It may include one or more central processing units (CPUs) (e.g., one or more processors) and a memory 332. The memory 332 stores one or more computer programs 342 or data 344. In some embodiments, the memory 332 may be temporary or persistent storage. The program stored in the memory 332 may include one or more modules (not shown in the figure), each module may include a series of instruction operations on the data processing device. Furthermore, the processor 322 may be configured to communicate with the memory 332 and execute the series of instruction operations stored in the memory 332 on the electronic device 301.

[0164] Electronic device 301 may also include one or more power supplies 326, one or more wired or wireless network interfaces 350, one or more input / output interfaces 358, and / or one or more operating systems 341.

[0165] The steps in the log transmission method described above can be implemented by the structure of an electronic device.

[0166] Corresponding to the above method embodiments, this disclosure also provides a readable storage medium. The readable storage medium described below can be referred to in conjunction with the log transmission method described above.

[0167] A readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the log transmission method described in this disclosure.

[0168] In some implementations, the readable storage medium can be a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, or any other readable storage medium capable of storing program code.

[0169] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the communication module disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to the method section.

[0170] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this disclosure.

[0171] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented directly by hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0172] Finally, it should be noted that in this document, relationships 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 "include," "contain," or any other variations 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.

[0173] This document uses specific examples to illustrate the principles and implementation methods of this disclosure. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this disclosure. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this disclosure. Therefore, the content of this specification should not be construed as a limitation of this disclosure.

Claims

1. A log transmission method, applied to a communication module, the communication module including a first chip supporting a first communication mode and a second chip supporting a second communication mode, the method comprising: The first chip is used to generate local log data corresponding to the first communication mode, and the second chip is used to generate local log data corresponding to the second communication mode. If it is determined that a merged transmission will be performed, the chip to be transferred and the chip to be directly transmitted are determined from the first chip and the second chip; The local log data of the chip to be transferred is encapsulated into a log data packet, and the log data packet is sent to the direct transmission chip using the communication channel between the first chip and the second chip; as well as The log data packet and the local log data of the direct-transmission chip are sent to the host using the log channel of the direct-transmission chip.

2. The log transmission method as described in claim 1, wherein encapsulating the local log data of the chip to be transferred into a log data packet includes: Add a timestamp and the identifier of the chip to be transferred to the local log data of the chip to be transferred, so that the host can use the timestamp and the identifier to determine the source of the log data; as well as After the completion time and identifier are added, the local log data of the chip to be transferred is encapsulated into the log data packet.

3. The log transmission method as described in claim 1 or 2, wherein sending the log data packet to the direct-transmission chip using the communication channel between the first chip and the second chip includes: The log data packet is sent to the direct-transmission chip using the serial bus between the first chip and the second chip.

4. The log transmission method according to any one of claims 1 to 3, wherein sending the log data packet to the direct-transmission chip using the communication channel between the first chip and the second chip includes: A communication channel is established between the first chip and the second chip using shared memory; as well as The log data packet is sent to the direct-transmission chip using the communication channel.

5. The log transmission method according to any one of claims 1 to 4, wherein determining whether to perform merged transmission includes: The log channels of the first chip and the second chip are inspected; If there is a log channel failure in the first chip or the second chip, then merged transmission will be performed. Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including: The chip with a log channel fault in the first chip and the second chip is identified as the chip to be transferred. as well as The chip with a normal log channel among the first chip and the second chip is identified as the direct-transmission chip.

6. The log transmission method according to any one of claims 1 to 4, wherein determining whether to perform merged transmission includes: Monitor the communication data transmission volume corresponding to the first chip and the second chip respectively; If the communication transmission volume of the first chip or the second chip exceeds the threshold, it is determined to merge the transmission. Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including: The chip in the first chip and the second chip whose communication data transmission volume exceeds the threshold is identified as the chip to be converted. as well as The chip whose communication data transmission volume does not exceed the threshold in the first chip and the second chip is identified as the direct-transmission chip.

7. The log transmission method according to any one of claims 1 to 4, wherein determining whether to perform merged transmission includes: Get the current log transmission mode; If the log transmission mode is the merge transmission mode, then merge transmission will be performed. Accordingly, the chip to be converted and the direct-transmission chip are determined from the first chip and the second chip, including: According to the chip transmission settings corresponding to the merged transmission mode, the chip to be transferred and the chip to be directly transmitted are determined from the first chip and the second chip.

8. A communication module, comprising: A first chip supporting a first communication mode and a second chip supporting a second communication mode; The log collection unit is configured to generate local log data corresponding to the first communication mode using the first chip, and to generate local log data corresponding to the second communication mode using the second chip. The transmission determination unit is configured to determine the chip to be transferred and the direct transmission chip from the first chip and the second chip when it is determined that a merged transmission will be performed; The inter-chip transmission unit is configured to encapsulate the local log data of the chip to be transferred into a log data packet, and send the log data packet to the direct-transmission chip using the communication channel between the first chip and the second chip; as well as The log output unit is configured to use the log channel of the direct-transmission chip to send the log data packet and the local log data of the direct-transmission chip to the host.

9. Electronic equipment, including: Memory, configured to store computer programs; as well as A processor configured to implement the log transmission method of any one of claims 1 to 7 when executing the computer program.

10. A readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the log transmission method of any one of claims 1 to 7.