Communication method, device, electronic device and readable storage medium for multi-mode chip

By determining the reference period and the period to be adjusted in a multimode chip, and adjusting the duration of the period to be adjusted to achieve synchronous wake-up and sleep, the problem of frequent wake-up of the multimode chip is solved, reducing power consumption and improving efficiency.

CN115551059BActive Publication Date: 2025-08-08BEIJING ESWIN COMPUTING TECH CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211211122.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-30
Publication Date
2025-08-08
Estimated Expiration
2042-09-30

AI Technical Summary

Technical Problem

When performing multi-communication tasks, the multi-mode chips have frequent wake-ups due to inconsistent with the wake-up period and the wake-up time, which leads to frequent wake-ups, increasing power consumption and inefficiency.

Method used

By determining the reference period and the period of the adjustment of multiple communication tasks, adjusting the duration of the adjustment period to synchronize it with the reference period, ensuring that multiple tasks wake up at the wake-up time of the reference period, and updating the scheduled time to achieve synchronous sleep.

Benefits of technology

It reduces the power consumption of multi-mode chips in concurrent scenarios of multi-communication tasks and improves work efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115551059B_ABST
    Figure CN115551059B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a communication method, device, electronic device and storage medium for a multi-mode chip, and relates to the field of communication technology. The method includes: starting to execute the current idle task, if it is determined that both communication tasks are in a sleep cycle, then determining the next wake-up time of the two communication tasks, the two communication tasks respectively corresponding to a communication mode; determining the reference period and the waiting period from the current sleep cycle of the two communication tasks, respectively, determining the first time interval between the current moment and the reference wake-up time corresponding to the reference period; instructing the communication task corresponding to the waiting period to wake up at the next wake-up time corresponding to the reference period, updating the duration of the waiting period to the duration of the reference period, and ending the execution of the current idle task. The embodiment of the present application realizes that the multi-mode chip reduces the power consumption of the multi-mode chip and improves the working efficiency of the multi-mode chip in a scenario where multiple communication tasks are working concurrently.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communication technology, and more specifically, to a communication method, device, electronic device, and readable storage medium for a multi-mode chip. Background Art

[0002] The existing multi-mode chip sleep and wake-up method when executing multiple communication tasks is to enter a sleep cycle when there is no communication task scheduled. Taking a dual-mode chip as an example, the sleep cycle and wake-up time of different communication tasks are different. Since the scheduling cycle and sleep cycle of the first communication task and the second communication task are different, and the dual-mode chip can only sleep when both communication tasks are in the sleep cycle, the dual-mode chip will be frequently woken up and cannot enter the sleep state, resulting in a significant shortening of the actual vacation cycle of the dual-mode chip when executing multiple communication tasks, resulting in a significant increase in power consumption and low efficiency of the dual-mode chip. Summary of the Invention

[0003] The present invention provides a communication method, apparatus, electronic device, and readable storage medium for a multi-mode chip. These methods can address the problem of low chip efficiency and high power consumption caused by frequent awakening of the multi-mode chip due to asynchronous sleep of multiple communication tasks when the multi-mode chip provides multiple communication tasks. The technical solution is as follows:

[0004] According to one aspect of an embodiment of the present application, a communication method for a multi-mode chip is provided, which starts executing a current idle task. If it is determined that multiple communication tasks are in a sleep cycle, the next wake-up time of the multiple communication tasks is determined, each communication task corresponding to a communication mode;

[0005] Determine a unique reference period from the current sleep periods of the plurality of communication tasks, use other current sleep periods other than the reference period as waiting periods, and determine a first time interval between the current moment and a reference wake-up moment corresponding to the reference period;

[0006] For each pending period, indicate the communication task corresponding to the pending period to be awakened at the next wake-up time corresponding to the reference period, update the duration of the pending period according to the duration of the reference period, determine the new scheduling duration, and end the execution of the current idle task;

[0007] The determining of the new scheduling duration includes: using the longest scheduling duration among the multiple communication tasks as the new scheduling duration of the multiple communication tasks.

[0008] As a possible implementation, updating the duration of the period to be adjusted according to the duration of the reference period includes:

[0009] For each waiting period, if it is determined that the first time interval is shorter than the length of the waiting period, and the length of the reference period is greater than the length of the waiting period, then at least one communication task corresponding to the waiting period is instructed to wake up at the next wake-up time corresponding to the reference period, and the length of at least one waiting period is updated to the length of the reference period.

[0010] As a possible implementation, updating the duration of the period to be adjusted according to the duration of the reference period further includes:

[0011] For each waiting period, if it is determined that the first time interval and the length of the reference period are both less than the length of the waiting period, then at least one communication task corresponding to the waiting period is instructed to wake up at the next wake-up time corresponding to the reference period, and the length a of at least one waiting period is updated to n times the length b of the reference period; where (n-1)*b <a<n*b。

[0012] As a possible implementation manner, determining the reference period and the period to be adjusted respectively from the current sleep period of at least one communication task further includes:

[0013] If it is determined that there is only one communication mode with an unadjustable sleep period among the multiple communication modes, the current sleep period of the communication task corresponding to the communication mode with the unadjustable sleep period is used as the reference period;

[0014] The current sleep cycle of the communication task corresponding to at least one of the remaining communication modes with adjustable sleep cycles is used as the cycle to be adjusted.

[0015] As a possible implementation, the reference period and the period to be adjusted are respectively determined from the current sleep period of at least one communication task, and the method also includes:

[0016] If it is determined that the sleep period can be adjusted for all of the multiple communication modes, the communication mode with the smallest range of current working period is used as the first communication task, and the current sleep period of the first communication task is used as the reference period.

[0017] As a possible implementation, the current idle task is started, and then the following steps are further included:

[0018] If it is determined that at least one communication task among the multiple communication tasks is in a scheduling period, the current idle task is terminated.

[0019] As a possible implementation method, it includes:

[0020] Any two of the above-mentioned multiple communication modes are different. For example, the multiple communication modes can be Bluetooth, WiFi, 3G, 4G, 5G or any different communication modes in future communication standards.

[0021] According to another aspect of an embodiment of the present application, a communication device applied to a multi-mode chip is provided. The multi-mode chip has the ability to communicate in at least two communication modes. The communication device includes:

[0022] Wake-up time determination module: starts executing the current idle task. If it is determined that multiple communication tasks are in a sleep cycle, the next wake-up time of the multiple communication tasks is determined. Each communication task corresponds to a communication mode.

[0023] The time interval determination module determines a unique reference period from the current sleep periods of multiple communication tasks, uses other current sleep periods other than the reference period as the adjustment period, and determines a first time interval between the current moment and the reference wake-up time corresponding to the reference period;

[0024] Period adjustment module: for each pending period, indicate the communication task corresponding to the pending period to be awakened at the next wake-up time corresponding to the reference period, update the duration of the pending period according to the duration of the reference period, determine the new scheduling duration, and end the execution of the current idle task; wherein, determining the new scheduling duration includes: using the longest scheduling duration among multiple communication tasks as the new scheduling duration of the multiple communication tasks.

[0025] According to another aspect of the embodiments of the present application, an electronic device is provided, including a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the communication method according to any one of claims 1 to 6.

[0026] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the communication method of the dual-mode chip of any one of claims 1 to 6 are implemented.

[0027] The beneficial effect of the technical solution provided in the embodiment of the present application is that when the multi-mode chip works concurrently with multiple communication tasks, the power consumption of the multi-mode chip in the concurrent scenario of multiple communication tasks is reduced and the working efficiency of the multi-mode chip is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for describing the embodiments of the present application.

[0029] Figure 1 A schematic diagram showing the time taken for a complete working cycle provided in an embodiment of the present application;

[0030] Figure 2 A schematic flow chart of a communication method for a multi-mode chip in the prior art provided in an embodiment of the present application;

[0031] Figure 3 A flow chart of a communication method for a multi-mode chip provided in an embodiment of the present application;

[0032] Figure 4 A schematic diagram of an application scenario of a communication method for a multi-mode chip provided in an embodiment of the present application;

[0033] Figure 5 A schematic diagram of an application scenario of a communication method for a multi-mode chip provided in an embodiment of the present application;

[0034] Figure 6 A schematic structural diagram of a multi-mode chip communication device provided in an embodiment of the present application;

[0035] Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0036] The following describes the embodiments of the present application in conjunction with the accompanying drawings. It should be understood that the embodiments described below in conjunction with the accompanying drawings are exemplary descriptions for explaining the technical solutions of the embodiments of the present application and do not constitute a limitation on the technical solutions of the embodiments of the present application.

[0037] Those skilled in the art will understand that, unless otherwise stated, the singular forms "a", "an" and "the" used herein may also include plural forms. It should be further understood that the terms "including" and "comprising" used in the embodiments of the present application mean that the corresponding features can be implemented as the presented features, information, data, steps, operations, elements and / or components, but do not exclude implementation as other features, information, data, steps, operations, elements, components and / or combinations thereof supported by the present technical field. It should be understood that when we say that an element is "connected" or "coupled" to another element, the element can be directly connected or coupled to the other element, or it can refer to the element and the other element establishing a connection relationship through an intermediate element. In addition, the "connection" or "coupling" used here can include wireless connection or wireless coupling. The term "and / or" used here indicates at least one of the items defined by the term, for example, "A and / or B" can be implemented as "A", or as "B", or as "A and B".

[0038] In order to make the objectives, technical solutions and advantages of this application clearer, the implementation methods of this application will be further described in detail below with reference to the accompanying drawings.

[0039] First, several terms involved in this application are introduced and explained:

[0040] 1) The multi-mode chip has the ability to communicate through multiple communication modes. The multi-mode chip communicates based on each communication mode, which is called scheduling. The multi-mode chip of the embodiment of the present application periodically schedules a communication mode; see Figure 1 , where the time period from time t1 to time t2 is one scheduling. Generally, the scheduling duration of a dual-mode chip defaults to a fixed value.

[0041] 2) The multi-mode chip does not communicate based on any communication mode, which is called sleep. Since scheduling is performed periodically, sleep is also performed periodically. See Figure 1 In the figure, the time period from time t2 to time t3 is a sleep cycle. It should be noted that the sleep cycles of some communication modes are fixed, while the sleep cycles of some communication modes are adjustable.

[0042] 3) Each communication mode has a corresponding working cycle. The time period from the start time of one scheduling to the start time of the next scheduling is called a working cycle. Figure 1 In the figure, the time period from time t1 to time t3 is a working cycle. It should be noted that the working cycles of some communication modes are fixed, while the working cycles of some communication modes are adjustable.

[0043] 4) The wake-up time is the time when scheduling starts, see Figure 1 , i.e., time t1 and time t3 in the figure, the wake-up time also corresponds to the communication mode, and the wake-up time of each communication mode is independent of each other.

[0044] See Figure 2 , which exemplarily shows a schematic diagram of the working cycle of a multi-mode chip communicating in multiple communication modes. The multi-mode chip described in the embodiment of the present application is introduced by taking a dual-mode chip as an example. It can be understood that the method of the described dual-mode chip can be applied to the multi-mode chip.

[0045] like Figure 1As shown in the figure, the time periods from t1 to t2 and t5 to t6 are the scheduling periods for the first communication task; the time periods from t3 to t4 and t7 to t8 are the scheduling periods for the second communication task; and the time periods from t2 to t3, t4 to t5, and t6 to t7, etc., are the sleep periods for the dual-mode chip. It can be seen that because the scheduling and sleep periods for the first and second communication tasks are different, and the dual-mode chip can only sleep when both communication tasks are in a sleep period, at the "X" mark in the figure, the dual-mode chip is frequently awakened, resulting in a short sleep time and inability to enter a sleep state. This significantly shortens the actual sleep period of the dual-mode chip when executing multiple communication tasks, and the dual-mode chip is frequently awakened, resulting in a significant increase in power consumption and low efficiency. This shows that current dual-mode chips suffer from the problem of frequent sleep and wake-up due to the inconsistent working cycles of the two channels, low sleep efficiency, and high power consumption.

[0046] The present application provides a communication method, device, and computer-readable storage medium for a multi-mode chip, which are intended to solve the above technical problems in the prior art.

[0047] The following describes several exemplary embodiments to illustrate the technical solutions of the embodiments of the present application and the technical effects produced by the technical solutions of the present application. It should be noted that the following embodiments can refer to, draw on, or combine with each other, and the same terms, similar features, and similar implementation steps in different embodiments will not be repeated.

[0048] The present application provides a communication method for a dual-mode chip. Figure 3 As shown, the method includes:

[0049] S110, starting to execute the current idle task, if it is determined that multiple communication tasks are in a sleep cycle, then determining the next wake-up time of the multiple communication tasks, each communication task corresponding to a communication mode;

[0050] The idle task in the embodiment of the present application is the idle process of the chip. In order to ensure the power consumption and efficiency of the dual-mode chip, a low-power design is usually performed during the execution of the idle task. After receiving the idle task sent by a device such as a processor, the dual-mode chip will temporarily stop scheduling. In the embodiment of the present application, when there is no schedulable communication task, the idle running state of the dual-mode chip can also be regarded as the moment to start executing the idle task, such as Figure 1 Any moment in the time period from time t2 to time t3 and any moment in the time period from time t4 to time t5 are the moments that can be regarded as starting to execute the idle task as mentioned above.

[0051] The first wake-up time in the embodiment of the present application is the next wake-up time of the first communication task, which can be determined based on the time when the first communication task last entered sleep mode and the current sleep cycle. For example, if the time when the first communication task last entered sleep mode is tc and the current sleep cycle of the first communication task is Δt1, the first wake-up time is tc + Δt1.

[0052] The second wake-up time is the next wake-up time of the second communication task, which can be determined based on the time when the second communication task last entered sleep mode and the current sleep cycle. For example, if the second communication task last entered sleep mode at time td and the current sleep cycle of the second communication task is Δt2, the second wake-up time is td + Δt2.

[0053] The first and second communication tasks are tasks executed in two different communication modes on the dual-mode chip. The communication modes supported by the dual-mode chip include Wi-Fi, BLE, ZigBee, and 3G / 4G / 5G cellular communication technologies supported by 3GPP. Because different communication tasks correspond to different communication modes, as the communication tasks execute, the first and second communication tasks can execute sequentially and then enter a dormant period separately, or they can execute simultaneously and then enter a dormant period simultaneously.

[0054] S120: determining a unique reference period from the current sleep periods of the plurality of communication tasks, using other current sleep periods other than the reference period as waiting periods, and determining a first time interval between the current moment and a reference wake-up moment corresponding to the reference period;

[0055] In the embodiment of the present application, any one of the two communication tasks can be used as the reference task, and the current sleep period of the reference task can be used as the reference period. Correspondingly, the other communication task other than the reference task can be used as the task to be adjusted, and the current sleep period of the task to be adjusted can be used as the period to be adjusted. The purpose of the embodiment of the present application is to keep the reference period unchanged and adjust the duration of the period to be adjusted.

[0056] In one embodiment, a communication task with a smaller duty cycle range is used as a benchmark task, and the duty cycle of the benchmark task is a fixed preset duration. Specifically, if the duty cycle of the benchmark task is 102ms, of which the scheduling duration (including wake-up overhead) is 7ms, the actual effective sleep time is 95ms. In this example, 95ms is the benchmark period.

[0057] In one embodiment, the period to be adjusted may be adjusted to be consistent with the reference period.

[0058] In one embodiment, the task to be scheduled may be a communication task with an adjustable sleep cycle range.

[0059] If the base wakeup time is defined as the next wakeup time of the base task, for example, the base task last entered sleep at time t3, and the base cycle duration is Δt3, then the base wakeup time is t3 + Δt3. If the current time is te, then the first time interval is the period from the current time to the base wakeup time, which is t3 + Δt3 - te.

[0060] S130: For each pending period, instruct the communication task corresponding to the pending period to be awakened at the next awakening time corresponding to the reference period, update the duration of the pending period according to the duration of the reference period, determine a new scheduling duration, and terminate execution of the current idle task;

[0061] The determining of the new scheduling duration includes: using the longest scheduling duration among the multiple communication tasks as the new scheduling duration of the multiple communication tasks.

[0062] S131. For each waiting period, if it is determined that the first time interval is shorter than the duration of the waiting period, and the duration of the reference period is greater than the duration of the waiting period, then instruct the communication task corresponding to the at least one waiting period to be adjusted to wake up at the next wake-up time corresponding to the reference period, and update the duration of the at least one waiting period to be adjusted to the duration of the reference period.

[0063] By determining that the reference period is smaller than the waiting period, the waiting period can be adjusted to achieve synchronization with the reference period, that is, the two communication tasks can enter the sleep period at the same time, and then ensure that the chip can be awakened by the sleep period of the reference working period when it is in sleep, so as to achieve the effect of minimizing the sleep conflict under multi-task concurrency while meeting the work of multiple task processes, and reducing chip power consumption and improving chip working efficiency.

[0064] In this scheme, the longer scheduling duration of the two communication tasks is used as the new scheduling duration of the two communication tasks. Instead of changing the scheduling period of the waiting period, when the communication task with the shorter scheduling duration completes the scheduling task, it pauses and waits for the communication task with the longer scheduling duration to complete the scheduling task, and then enters the sleep cycle at the same time.

[0065] This solution avoids the problems of asynchronous sleep and wake-up cycles among multiple task processes in existing chip power reduction schemes, resulting in low efficiency and high power consumption. This solution synchronizes the sleep cycles of multiple task processes by detecting that multiple task processes within the chip are in a sleep cycle, determining that other task processes can adjust their sleep cycles to a baseline sleep cycle, and then adjusting their sleep cycles. This reduces sleep conflicts among multiple concurrent task processes and improves chip efficiency.

[0066] like Figure 4As shown, the duration of the working cycle of the first communication task is 102 ms, the duration of the current sleep cycle at time t1 is 95 ms, and the duration of the scheduling cycle is 7 ms; the duration of the working cycle of the second communication task is 90 ms, the duration of the current sleep cycle at time t1 is 85 ms, and the duration of the scheduling cycle is 5 ms. In the initial stage of this embodiment, the second communication task enters the scheduling state later than the first communication task. It can be seen from the figure that the first two schedules of the first communication task are earlier than the first two schedules of the second communication task. In order to wake up the first communication task and the second communication task simultaneously when entering three working cycles, the sleep cycle of the second communication task is extended, and the first communication task is determined as the reference task and the second communication task is determined as the task to be adjusted.

[0067] Based on the above embodiments, as an optional embodiment, after the step of determining the reference cycle and the cycle to be adjusted respectively from the current sleep cycles of the two communication tasks and determining the first time interval between the current time and the reference wake-up time corresponding to the reference cycle, the following steps are further included:

[0068] S132. For each cycle to be adjusted, if it is determined that both the first time interval and the duration of the reference cycle are less than the duration of the cycle to be adjusted, then instruct the communication task corresponding to the at least one cycle to be adjusted to wake up at the next wake-up time corresponding to the reference cycle, and update the duration a of the at least one cycle to be adjusted to n times the duration b of the reference cycle; where, (n - 1)*b < a < n*b.

[0069] It is determined that the cycle to be adjusted is greater than the reference cycle. Since the reference cycle of the first communication task cannot be changed and the cycle to be adjusted of the second communication task cannot be shortened, it is impossible to achieve that each working cycle of the first communication task is synchronized with each working cycle of the second communication task. In order to achieve the technical effect of reducing the power consumption of the dual-mode chip, in this embodiment, after the first communication task goes through two working weeks, it is synchronized with one working cycle of the second communication task, avoiding the situation that the first communication task and the second communication task need to frequently wake up the dual-mode chip to execute their respective scheduling tasks due to different working cycles, resulting in the dual-mode chip being unable to enter the sleep cycle. By making (n - 1)*b < a < n*b, each working cycle of the second communication task is synchronized with the first communication task after n times of working cycles, and the scheduling tasks of the two communication tasks are executed alternately as little as possible. After adjusting the cycle to be adjusted, the cycle to be adjusted can be synchronized with n times of the reference cycle, that is, the two communication tasks can enter the sleep period and sleep simultaneously.

[0070] Among them, the embodiment of the present application can include communication modes other than WiFi / Bluetooth. Different communication modes have different working cycles, sleep cycles, and scheduling durations. After obtaining the data required for calculation such as the working cycles of different communication modes, the embodiment of the present application can select the working cycle regarded as the benchmark and the sleep cycle regarded as the benchmark according to the preset rules, and adjust the working cycles and sleep cycles of other communication modes to make the working cycles of communication tasks in multiple communication modes the same; when the scheduling duration cannot be adjusted, the communication tasks with shorter scheduling durations enter a waiting period until all communication tasks are scheduled, and then enter the sleep period to sleep at the same time to ensure that the dual-mode chip can maintain low power consumption.

[0071] like Figure 5 As shown, the working cycle of the first communication task is 102ms, the duration of the current sleep cycle at time t1 is 95ms, and the duration of the scheduling cycle is 7ms; the duration of the working cycle of the second communication task is 160ms, the duration of the current sleep cycle at time t1 is 155ms, and the duration of the scheduling cycle is 5ms. In the initial stage of this embodiment, the second communication task enters the scheduling state later than the first communication task. It can be found from the figure that the first two schedulings of the first communication task are earlier than the first two schedulings of the second communication task. In order to allow the first communication task and the second communication task to be awakened at the same time, the sleep cycle of the second communication task is extended, so that the second scheduling task of the second communication task and the third scheduling task of the first communication task are awakened at the same time, and the first communication task is determined to be the reference task and executed on the first channel; the second communication task is determined to be the task to be scheduled and executed on the second channel.

[0072] Based on the above embodiments, as an optional embodiment, the reference period and the period to be adjusted are respectively determined from the current sleep periods of the two communication tasks, further comprising:

[0073] If it is determined that among the two communication modes, only one communication mode has an adjustable sleep period, the current sleep period of the communication task corresponding to the communication mode with an unadjustable sleep period will be used as the reference period, and the current sleep period of the communication task corresponding to the communication mode with an adjustable sleep period will be used as the period to be adjusted.

[0074] For example, taking a dual-mode chip that can communicate in WiFi communication mode and Bluetooth communication mode as an example, since the WiFi communication mode cannot adjust the working cycle range, while the Bluetooth communication mode can adjust the working range, the current sleep cycle of the communication task corresponding to the WiFi communication mode is used as the benchmark cycle, and the current sleep cycle of the communication task corresponding to the Bluetooth communication mode is used as the waiting cycle.

[0075] Based on the above embodiments, as an optional embodiment, the reference period and the period to be adjusted are respectively determined from the current sleep periods of the two communication tasks, and the above also includes:

[0076] If it is determined that both communication modes can adjust their sleep cycles, the communication task corresponding to the communication mode with the smaller current operating cycle range is used as the reference communication task, and the communication task corresponding to the communication mode with the larger current operating cycle range is used as the communication task to be adjusted. The operating cycle includes the scheduling period and the sleep period. The operating mode with the larger operating cycle range is used as a reference for the operating mode with the smaller operating cycle range, ensuring that the adjusted operating cycle of the operating mode with the larger operating cycle range does not exceed the preset range of its operating cycle.

[0077] For example, taking the dual-mode chip that can communicate in 4G cellular network communication mode and Bluetooth communication mode as an example, since the working cycle range that can be adjusted in the 4G cellular network communication mode is 50-100ms, and the working cycle range that can be adjusted in the Bluetooth communication mode is 20ms-10.24s, the current sleep cycle of the communication task corresponding to the 4G cellular network communication mode is used as the reference cycle, and the current sleep cycle of the communication task corresponding to the Bluetooth communication mode is used as the waiting cycle.

[0078] Based on the above embodiments, as an optional embodiment, starting to execute the current idle task, and then further including:

[0079] If it is determined that at least one of the two communication tasks is in the scheduling period, the current idle task is terminated.

[0080] When the dual-mode chip detects that at least one of the two communication tasks is executing a scheduled task, the dual-mode chip cannot enter the sleep cycle to execute the idle task. In order to reduce the power consumption of the dual-mode chip, the dual-mode chip ends the current idle task.

[0081] After the dual-mode chip finishes the current idle task, it will re-enter the idle task after a preset time, and obtain the next wake-up time th1 of the reference cycle and the next wake-up time th2 of the cycle to be adjusted, and calculate the second time interval Δth, that is, the time period between the two wake-up times, based on the two wake-up times obtained, and compare the second time interval Δth with the preset interval tg. When the length of the second time interval Δth is shorter than the preset time interval tg, the current sleep cycle of the first communication task is used as the reference cycle; but when the length of the second time interval Δth is longer than the preset time interval tg, the idle task is re-executed.

[0082] The embodiment of the present application provides a communication device of a dual-mode chip, such as Figure 6As shown, the communication device of the dual-mode chip may include: a sleep cycle updating module 701, a scheduling duration updating module 702 and a wake-up time determining module 703, wherein:

[0083] The wake-up time determination module 701 is used to start executing the current idle task. If it is determined that both communication tasks are in the dormant period, the next wake-up time of the two communication tasks is determined. The two communication tasks correspond to a communication mode respectively.

[0084] The time interval determination module 702 is configured to determine a reference period and a waiting period from the current sleep periods of the two communication tasks, and determine a first time interval between the current moment and the reference wake-up moment corresponding to the reference period;

[0085] The period adjustment module 703 is configured to, if it is determined that the first time interval is shorter than the duration of the pending period and the duration of the reference period is longer than the duration of the pending period, instruct the communication task corresponding to the pending period to wake up at the next wake-up time corresponding to the reference period, update the duration of the pending period to the duration of the reference period, use the longer scheduling duration of the two communication tasks as the new scheduling duration of the two communication tasks, and terminate the current idle task;

[0086] The device of the embodiment of the present application can execute the method provided by the embodiment of the present application, and its implementation principle is similar. The actions performed by each module in the device of each embodiment of the present application correspond to the steps in the method of each embodiment of the present application. For the detailed functional description of each module of the device, please refer to the description in the corresponding method shown in the previous text, and will not be repeated here.

[0087] In an embodiment of the present application, an electronic device is provided, including a memory, a processor, and a computer program stored in the memory. The processor executes the above-mentioned computer program to implement the steps of the communication method of the dual-mode chip. Compared with the related art, it can achieve: when the dual-mode chip works concurrently with multiple communication tasks, the power consumption of the dual-mode chip in the concurrent scenario of multiple communication tasks is reduced and the working efficiency of the dual-mode chip is improved.

[0088] In an alternative embodiment, an electronic device is provided, such as Figure 7 As shown, Figure 7 The electronic device 4000 shown includes: a processor 4001 and a memory 4003. The processor 4001 and the memory 4003 are connected, for example, via a bus 4002. Optionally, the electronic device 4000 may further include a transceiver 4004, which may be used for data exchange between the electronic device and other electronic devices, such as data transmission and / or data reception. It should be noted that in actual applications, the number of transceivers 4004 is not limited to one, and the structure of the electronic device 4000 does not constitute a limitation on the embodiments of the present application.

[0089] Processor 4001 can be a CPU (Central Processing Unit), a general-purpose processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It can implement or execute the various exemplary logic blocks, modules, and circuits described in conjunction with the disclosure of this application. Processor 4001 can also be a combination that implements computing functions, such as a combination of one or more microprocessors, or a combination of a DSP and a microprocessor.

[0090] Bus 4002 may include a path for transmitting information between the above components. Bus 4002 may be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus. Bus 4002 may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 7 Only one thick line is used in the diagram, but this does not mean that there is only one bus or one type of bus.

[0091] The memory 4003 can be a ROM (Read Only Memory) or other types of static storage devices that can store static information and instructions, a RAM (Random Access Memory) or other types of dynamic storage devices that can store information and instructions, or an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory) or other optical disk storage, optical disk storage (including compact discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media, other magnetic storage devices, or any other medium that can be used to carry or store computer programs and can be read by a computer, without limitation here.

[0092] The memory 4003 is used to store the computer program for executing the embodiment of the present application, and the execution is controlled by the processor 4001. The processor 4001 is used to execute the computer program stored in the memory 4003 to implement the steps shown in the above method embodiment.

[0093] An embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the steps and corresponding contents of the aforementioned method embodiment can be implemented.

[0094] An embodiment of the present application also provides a computer program product, including a computer program, which can implement the steps and corresponding contents of the aforementioned method embodiment when executed by a processor.

[0095] The terms "first," "second," "third," "fourth," "1," "2," and the like (if any) in the specification and claims of this application and the accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a particular order or sequential sequence. It should be understood that the terms used in this manner are interchangeable where appropriate, so that the embodiments of the application described herein can be implemented in an order other than that shown or described in the drawings.

[0096] It should be understood that, although each operation step is indicated by arrows in the flowchart of the embodiment of the present application, the order of implementation of these steps is not limited to the order indicated by the arrows. Unless otherwise clearly stated herein, in some implementation scenarios of the embodiment of the present application, the implementation steps in each flowchart can be performed in other orders according to demand. In addition, some or all of the steps in each flowchart can include multiple sub-steps or multiple stages based on actual implementation scenarios. Some or all of these sub-steps or stages can be executed at the same time, and each sub-step or stage in these sub-steps or stages can also be executed at different times respectively. Under different scenarios at the execution time, the execution order of these sub-steps or stages can be flexibly configured according to demand, and the embodiment of the present application does not limit this.

[0097] The above are only optional implementation methods for some implementation scenarios of this application. It should be pointed out that for ordinary technicians in this technical field, without departing from the technical concept of the solution of this application, other similar implementation methods based on the technical ideas of this application also fall within the protection scope of the embodiments of this application.

Claims

1. A communication method for a multi-mode chip, characterized in that: The multi-mode chip has the ability to communicate through multiple communication modes, and the method includes: Start executing the current idle task, and if it is determined that the multiple communication tasks are in a sleep cycle, determine the next wake-up time of the multiple communication tasks, where the multiple communication tasks correspond one-to-one to the multiple communication modes; Determine a unique reference period from the current sleep periods of the plurality of communication tasks, use other current sleep periods other than the reference period as waiting periods, and determine a first time interval between a current moment and a reference wake-up moment corresponding to the reference period; For each pending period, instruct the communication task corresponding to the pending period to be awakened at the next awakening time corresponding to the reference period, update the duration of the pending period according to the duration of the reference period, determine a new scheduling duration, and terminate execution of the current idle task; The new scheduling duration is the longest scheduling duration among the scheduling durations corresponding to the multiple communication tasks; The updating of the duration of the to-be-adjusted period according to the duration of the reference period includes: For each pending adjustment period, if it is determined that the first time interval is shorter than the duration of the pending adjustment period, and the duration of the base period is greater than the duration of the pending adjustment period, then at least one communication task corresponding to the pending adjustment period is instructed to wake up at the next wake-up time corresponding to the base period, and the duration of the at least one pending adjustment period is updated to the duration of the base period.

2. The method according to claim 1, characterized in that The updating of the duration of the to-be-adjusted period according to the duration of the reference period further includes: For each pending period, if it is determined that the first time interval and the duration of the reference period are both less than the duration of the pending period, then instruct at least one communication task corresponding to the pending period to wake up at the next wake-up time corresponding to the reference period, and update the duration a of the at least one pending period to n times the duration b of the reference period; wherein, (n-1) b <a<n b.

3. The method according to claim 1, characterized in that The step of determining a unique reference period from the current sleep periods of the plurality of communication tasks and using other current sleep periods other than the reference period as periods to be adjusted further includes: If it is determined that there is only one communication mode whose sleep period cannot be adjusted among the multiple communication modes, then the current sleep period of the communication task corresponding to the communication mode whose sleep period cannot be adjusted is used as the reference period; The current sleep cycle of the communication task corresponding to at least one of the remaining communication modes capable of adjusting the sleep cycle is used as the cycle to be adjusted.

4. The method according to claim 1, wherein The method further includes determining a unique reference period from the current sleep periods of the plurality of communication tasks, and using other current sleep periods other than the reference period as the periods to be adjusted. If it is determined that the sleep period can be adjusted for all of the multiple communication modes, the communication mode with the smallest range of current working period is used as the first communication task, and the current sleep period of the first communication task is used as the reference period.

5. The method according to claim 1, wherein The above process starts executing the current idle task, and then further includes: If it is determined that at least one of the multiple communication tasks is in the scheduling period, the current idle task is terminated.

6. A communication device applied to a multi-mode chip, characterized in that: The multi-mode chip has the ability to communicate through at least two communication modes, and the communication device includes: A wake-up time determination module starts executing the current idle task. If it is determined that multiple communication tasks are in a sleep cycle, the next wake-up time of the multiple communication tasks is determined, and each communication task corresponds to a communication mode. A time interval determination module is configured to determine a unique reference period from the current sleep periods of the plurality of communication tasks, use other current sleep periods other than the reference period as waiting periods, and determine a first time interval between the current moment and a reference wake-up moment corresponding to the reference period; The cycle adjustment module is configured to, for each pending cycle, instruct the communication task corresponding to the pending cycle to be awakened at the next awakening time corresponding to the reference cycle, update the duration of the pending cycle based on the duration of the reference cycle, determine a new scheduling duration, and terminate the execution of the current idle task; wherein, the determining of the new scheduling duration includes: using the longest scheduling duration among the multiple communication tasks as the new scheduling duration of the multiple communication tasks; The cycle adjustment module is specifically used for: For each pending adjustment period, if it is determined that the first time interval is shorter than the duration of the pending adjustment period, and the duration of the base period is greater than the duration of the pending adjustment period, then at least one communication task corresponding to the pending adjustment period is instructed to wake up at the next wake-up time corresponding to the base period, and the duration of the at least one pending adjustment period is updated to the duration of the base period.

7. An electronic device comprising a memory, a processor, and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 5.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.

Citation Information

Patent Citations

  • Timer device based on FPGA

    CN105759665A

  • Power saving in peer-to-peer communication devices

    US20100165896A1