WO2022228085A1 - 一种休眠调度方法及设备 - Google Patents

一种休眠调度方法及设备 Download PDF

Info

Publication number
WO2022228085A1
WO2022228085A1 PCT/CN2022/085845 CN2022085845W WO2022228085A1 WO 2022228085 A1 WO2022228085 A1 WO 2022228085A1 CN 2022085845 W CN2022085845 W CN 2022085845W WO 2022228085 A1 WO2022228085 A1 WO 2022228085A1
Authority
WO
WIPO (PCT)
Prior art keywords
sleep
wake
information
service
link
Prior art date
Application number
PCT/CN2022/085845
Other languages
English (en)
French (fr)
Inventor
杨明
何志光
杨建华
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP22794556.5A priority Critical patent/EP4311314A1/en
Publication of WO2022228085A1 publication Critical patent/WO2022228085A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0212Power saving arrangements in terminal devices managed by the network, e.g. network or access point is master and terminal is slave
    • H04W52/0216Power saving arrangements in terminal devices managed by the network, e.g. network or access point is master and terminal is slave using a pre-established activity schedule, e.g. traffic indication frame
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0203Power saving arrangements in the radio access network or backbone network of wireless communication networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/12Arrangements for remote connection or disconnection of substations or of equipment thereof
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0212Power saving arrangements in terminal devices managed by the network, e.g. network or access point is master and terminal is slave
    • H04W52/0219Power saving arrangements in terminal devices managed by the network, e.g. network or access point is master and terminal is slave where the power saving management affects multiple terminals
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0225Power saving arrangements in terminal devices using monitoring of external events, e.g. the presence of a signal
    • H04W52/0229Power saving arrangements in terminal devices using monitoring of external events, e.g. the presence of a signal where the received signal is a wanted signal
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0225Power saving arrangements in terminal devices using monitoring of external events, e.g. the presence of a signal
    • H04W52/0235Power saving arrangements in terminal devices using monitoring of external events, e.g. the presence of a signal where the received signal is a power saving command
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0225Power saving arrangements in terminal devices using monitoring of external events, e.g. the presence of a signal
    • H04W52/0248Power saving arrangements in terminal devices using monitoring of external events, e.g. the presence of a signal dependent on the time of the day, e.g. according to expected transmission activity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/20Manipulation of established connections
    • H04W76/28Discontinuous transmission [DTX]; Discontinuous reception [DRX]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/20Manipulation of established connections
    • H04W76/25Maintenance of established connections
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/20Manipulation of established connections
    • H04W76/27Transitions between radio resource control [RRC] states
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Definitions

  • the present application relates to the field of communication technologies, and in particular, to a sleep scheduling method and device.
  • a sleep scheduling method is proposed. For example, the current sleep scheduling method based on the power save mode (PSM) protocol; or, the sleep scheduling method based on the target wake time (TWT) protocol; or, based on the notice of absence (notice of absence, The sleep scheduling method of NOA) protocol.
  • PSM power save mode
  • TWT target wake time
  • NOA notice of absence
  • the above three sleep scheduling methods can all be considered as central node-based scheduling methods, which cannot be applied to many-to-many network topology.
  • the present application provides a sleep scheduling method and device, which are used to save the power consumption of each device as much as possible without affecting the normal service interaction of each device in a distributed system.
  • a sleep scheduling method is provided.
  • the method can be used in a distributed system including a first device, a second device, and a third device.
  • the distributed system can be a one-to-many connection system, or a many-to-many connection. system.
  • the method can be applied to any device in the distributed system, and the method is executed by the first device as an example below.
  • the method includes:
  • the first device determines the arrival of the first service according to the first scene information, generates second sleep and wake-up information according to the first scene information and the first sleep and wake-up information, and updates the second sleep and wake-up information to the sleep and wake-up schedule.
  • the first scene information is used to indicate the service characteristics of the first service.
  • the first sleep-wake-up information is used to indicate the current sleep-wake-up conditions of the first device in each time slice within the sleep scheduling period.
  • the second sleep-wake-up information is used to indicate the sleep-wake-up conditions on each time slice within the sleep scheduling period that need to be satisfied when the first device performs services including the first service.
  • the sleep-wake-up schedule includes sleep-wake-up conditions of each device in the distributed system, and is used by the first device to send data or receive each device with other devices in the distributed system.
  • a minimum sleep wake-up time (also called a time slice) is defined in the time dimension, and N time slices are used as a sleep scheduling period.
  • a unified sleep-wake-up schedule is established for each device in the distributed system.
  • the sleep-wake-up schedule can indicate the latest sleep-wake-up time of all devices in the distributed system in each time slice within the sleep scheduling period.
  • other suitable devices can be selected to perform distributed services in coordination.
  • a service such as the first service
  • the first device may update its own data during the sleep-wake-up period according to the characteristics of the first service. Sleep and wake up to ensure the normal operation of the first service and save power consumption as much as possible. Further, the first device may update the updated sleep-wake information to the sleep-wake schedule. Other provinces are similar to the first device, so that each device in the distributed system can independently schedule each device according to specific services, so that each device can go to sleep as much as possible without affecting the service latency and throughput, saving energy. consumption.
  • Each device dynamically updates its own dormancy and wake-up state according to the dormancy and wake-up states of other devices, and the dormancy and wake-up state can be flexibly changed, which is also convenient to meet the actual transmission requirements of burst services.
  • the sleep scheduling method provided by the embodiments of the present application can be applied to many-to-many connection scenarios .
  • the method further includes:
  • the first device broadcasts a first periodic notification frame (periodical notify frame, PNF) within a preset time slice within the dormancy scheduling period, and receives the second PNF from the second device, and updates the stored dormancy wake-up schedule according to the second PNF .
  • the first PNF is used to indicate the second sleep-wake-up information
  • the second PNF is used to indicate the sleep-wake-up information of the second device.
  • each device may broadcast its own current sleep and wake-up information at a preset time slot within the sleep scheduling period, so that each device maintains the sleep and wake-up schedule according to the sleep and wake-up information of other devices.
  • the method further includes:
  • the first device determines to enter any one of the following scenarios, where the first device updates the sleep and wake-up information of the corresponding link, and notifies the second device of the updated sleep and wake-up information of the corresponding link; wherein the scenario includes: keep-alive scenario, link change scenario, emergency service scenario or service change scenario, the keep-alive scenario is used to instruct the link of the first device to remain connected, and there is no service data interaction between the first device and other devices .
  • the application scenario of the first device may change, for example, there is an emergency service between the first device and the second device, or, for example, the transmission between the first device and the second device
  • the traffic of the link varies greatly.
  • the first device can adaptively adjust the sleep and wake-up information of the corresponding link and notify the second device.
  • the second device can update the stored sleep-wake-up information of the corresponding link according to the latest sleep-wake-up information of the transmission link between the first device and the second device, without affecting the service on the transmission link of other devices.
  • the first device enters a keep-alive scenario, and the method further includes:
  • the first device queries the cached data amount; when the data amount is greater than or equal to the first preset threshold, the first device updates the sleep and wake-up information of the transmission link between the first device and the second device to the first device Link sleep wakeup information. And the first device sends the first notification frame to the second device, and receives the second notification frame from the second device.
  • the first notification frame carries the sleep and wake-up information of the first link, so that the second device updates the stored sleep-wake information of the transmission link between the first device and the second device according to the sleep and wake-up information of the first link. It is the sleep and wake-up information of the second link; the second notification frame carries the sleep and wake-up information of the second link.
  • the first device may not send service data in time.
  • the first device may update its own sleep and wake-up information.
  • the first device may set the first P time slots in the sleep-wake-up period to the wake-up state, so as to save the cache space of the first device as much as possible.
  • the first device and the second device inform the second device of the sleep and wake-up information of the first link.
  • the second device updates the sleep-wake-up information of the corresponding transmission link, it can inform the first device of the sleep-wake-up information of the second link.
  • the first device enters a link change scenario, and the method further includes:
  • the first device determines that the traffic of the transmission link between the first device and the second device is greater than or equal to the second preset threshold, and updates the sleep and wake-up information of the transmission link between the first device and the second device to the first device Link sleep wakeup information. And the first device sends the first notification frame to the second device, and receives the second notification frame from the second device.
  • the first notification frame carries the sleep and wake-up information of the first link, so that the second device updates the stored sleep-wake information of the transmission link between the first device and the second device according to the sleep and wake-up information of the first link. It is the sleep and wake-up information of the second link; the second notification frame carries the sleep and wake-up information of the second link.
  • the first device can adaptively temporarily increase the wake-up time slice according to the size of the link traffic, so as to transmit the service data stored in the data cache module to the peer device quickly and reduce the delay.
  • the first device enters an emergency service scenario, and the method further includes:
  • the first device updates the sleep-wake information of the transmission link between the first device and the second device to the first link sleep-wake information. And the first device sends the first notification frame to the second device, and receives the second notification frame from the second device.
  • the first notification frame carries the sleep and wake-up information of the first link, so that the second device updates the stored sleep-wake information of the transmission link between the first device and the second device according to the sleep and wake-up information of the first link. It is the sleep and wake-up information of the second link; the second notification frame carries the sleep and wake-up information of the second link.
  • This solution considers another possible application scenario, that is, sudden service generation among multiple interconnected devices.
  • each device in the distributed system can be flexibly scheduled. For example, the first device and the second device negotiate a sleep-wake-up time slice for sending and receiving emergency services, so that the data of the emergency services are transmitted as quickly as possible, and Try not to affect the overall sleep of the distributed system.
  • the first device generates the second sleep-wake information according to the first scene information and the first sleep-wake information, including: the first device is based on the first preset rule, the first scene information, and the first sleep-wake information.
  • the wake-up information generates second sleep-wake information, wherein the first preset rule satisfies one or more of the following preset rules.
  • Exemplary preset rule 1 the first device currently has no service, the first device cannot determine the sleep-wake-up information for the first service, and the second sleep-wake-up information is used to indicate that the first device is in each time slice in the sleep scheduling period. is awake. It can be understood that when the first device currently has no service and the first service arrives, it cannot determine the dormancy and wake-up status of the first service. In this case, in order to ensure the normal operation of the subsequent first service, the first device can be set. Awake for the entire sleep scheduling period.
  • the first device currently has services
  • the first sleep-wake information indicates that the first device is in the wake-up state in each time slice within the sleep scheduling period
  • the second sleep-wake information is used to indicate that the first device is sleeping.
  • Each time slice in the scheduling period is in the awake state.
  • the first device currently has a service
  • the current service requires the first device to be in the wake-up state during the entire dormancy scheduling period, so in order to ensure the smooth progress of the current service, no matter what the dormant wake-up situation needs to be satisfied by the first service, it needs to be awake.
  • Device The first device is in an awake state during the entire sleep scheduling period.
  • Exemplary preset rule 3 The first device currently has a service, and the first sleep-wake information indicates that the first device is in the wake-up state for part of the time slice within the sleep scheduling period. If the first device cannot determine to perform sleep-wake-up for the first service information, the second sleep-wake information is used to indicate that the first device is in the wake-up state for each time slice in the sleep scheduling period; if the first device can determine the sleep-wake information for the first service, the second sleep-wake information is based on the first device. A dormancy-wakeup message and the dormancy-wakeup message for the first device to perform the first service are generated.
  • the first device currently has a service, but the current service requires that the first device only needs to be in an awake state for a part of the time slice in the entire sleep scheduling period.
  • the first device may be set to be in the wake-up state during the entire sleep scheduling period.
  • the first device can determine the sleep-wake condition of the first service, it can combine the sleep-wake condition that the current service needs to meet and the sleep-wake condition that the first service needs to satisfy to determine the first device to perform the current service and the sleep-wake condition that the first service needs to meet. In the wake-up situation from sleep, try to ensure that the first device goes into sleep as much as possible to save power consumption.
  • the first scene information includes one or more of the following information:
  • Type information of the first service, the minimum delay tolerance value of the first service, the packet sending interval corresponding to the first service, and the scene gear corresponding to the first service, where the scene gear is used to indicate that the first service is in the sleep state The sleep and wake-up conditions of each time slice in the scheduling period, and the sleep and wake-up conditions corresponding to different scene gears are different.
  • the scenario information may be the minimum delay tolerance value of the first service, and it is relatively straightforward for the first device to determine the sleep-wakeup information that needs to be satisfied according to the minimum delay tolerance value of the first service.
  • the scene information may also be service type information.
  • the first device can determine the service characteristics of the first service according to the relevant information delivered by the application layer based on the service flow, and then determine the minimum delay tolerance value that needs to be satisfied by the first service according to the service characteristics, and then determine the service characteristics that need to be satisfied. Sleep-wake condition.
  • the scene information may be the packet sending interval of the first service.
  • the first device can monitor some features of the first service, such as the packet sending interval of the first service, to determine the sleep-wake-up condition that needs to be satisfied.
  • the scene information may also be a scene gear, which directly represents the dormancy scheduling situation that needs to be satisfied by the first service, which is more direct.
  • an electronic device in a second aspect, includes a display screen, one or more processing modules, a memory, and one or more programs.
  • the one or more programs are stored in the memory, and the one or more programs include instructions that, when executed by the electronic device, cause the electronic device to perform the above-mentioned first aspect or The method provided by the first device in any possible implementation manner, or the electronic device is caused to perform the above-mentioned first aspect or the method provided by the second device in any possible implementation manner.
  • the electronic device may perform: determine the arrival of the first service according to the first scenario information, generate second sleep-wake information according to the first scenario information and the first sleep-wake information, and update the second sleep-wake information to the sleep-wake schedule surface.
  • the first scene information is used to indicate the service characteristics of the first service.
  • the first sleep-wake-up information is used to indicate the current sleep-wake-up conditions of the first device in each time slice within the sleep scheduling period.
  • the second sleep-wake-up information is used to indicate the sleep-wake-up conditions on each time slice within the sleep scheduling period that need to be satisfied when the first device performs services including the first service.
  • the sleep-wake-up schedule includes sleep-wake-up conditions of each device in the distributed system, and is used by the first device to send data or receive each device with other devices in the distributed system.
  • the electronic device further includes a transceiver module, wherein the transceiver module is configured to: broadcast the first PNF within a preset time slice in the sleep scheduling period, and receive the first PNF from the second electronic device 2 PNF.
  • the first PNF is used to indicate the second sleep-wake-up information
  • the second PNF is used to indicate the sleep-wake-up information of the second electronic device.
  • processing module is also used for:
  • the scenarios include: a keep-alive scenario, a link change scenario, an emergency service scenario or a service change scenario, the keep-alive scenario is used to instruct the link of the first device to remain connected, and the first device There is no business data interaction with other devices.
  • the electronic device enters a keep-alive scenario, wherein the processing module is further configured to: query the cached data amount, and when the data amount is greater than or equal to a first preset threshold, updating the sleep-wake-up information of the transmission link between the electronic device and the second device to the first-link sleep-wake-up information;
  • the transceiver module is further configured to: send a first notification frame to the second device, where the first notification frame carries the sleep and wake-up information of the first link, so that the second device can store the electronic data according to the sleep-wake information of the first link.
  • the sleep and wake-up information of the transmission link between the device and the second device is updated to the second link sleep and wake-up information; and a second notification frame from the second device is received, and the second notification frame carries the sleep of the second link. Wake up message.
  • the processing module is further configured to: determine that the traffic of the transmission link between the electronic device and the second device is greater than or equal to a second preset threshold , updating the sleep-wake-up information of the transmission link between the electronic device and the second device to the first-link sleep-wake-up information;
  • the transceiver module is further configured to: send a first notification frame to the second device, where the first notification frame carries the sleep and wake-up information of the first link, so that the second device according to the first link Update the stored sleep-wake information of the transmission link between the electronic device and the second device to the second link sleep-wake information; and receive a second notification from the second device frame, and the second notification frame carries the sleep and wake-up information of the second link.
  • the processing module is further configured to: update the sleep-wake-up information of the transmission link between the electronic device and the second device to the sleep-wake-up information of the first link ;
  • the transceiver module is further configured to: send a first notification frame to the second device, where the first notification frame carries the sleep and wake-up information of the first link, so that the second device according to the first link Update the stored sleep-wake information of the transmission link between the electronic device and the second device to the second link sleep-wake information; and receive a second notification from the second device frame, and the second notification frame carries the sleep and wake-up information of the second link.
  • the processing module is specifically configured to: generate the second sleep-wake-up information based on the first preset rule, the first scene information, and the first sleep-wake-up information, where the first preset rule satisfies one of the following one or more:
  • the electronic device currently has no service, and the electronic device cannot determine the sleep-wake-up information for the first service, and the second sleep-wake-up information is used to indicate that the electronic device is in the wake-up state in each time slice within the sleep scheduling period; or,
  • the electronic device currently has a business
  • the first sleep-wake information indicates that the electronic device is in the wake-up state in each time slice within the sleep scheduling period
  • the second sleep-wake information is used to indicate that the electronic device is in the wake-up state in each time slice within the sleep scheduling period ;
  • the electronic device currently has a service, and the first sleep-wake information indicates that the electronic device is in the wake-up state for part of the time slice in the sleep scheduling period. If the electronic device cannot determine the sleep-wake information for the first service, the second sleep-wake information is used to indicate The electronic device is in the awake state in each time slice in the dormancy scheduling period; if the electronic device can determine the dormancy and wake-up information for the first service, the second dormancy and wake-up information is based on the first dormancy and wake-up information and the electronic device performs the dormancy of the first service. Wake-up message generation.
  • the first scene information includes one or more of the following information:
  • Type information of the first service the minimum delay tolerance value of the first service, the packet sending interval corresponding to the first service, and the scene gear corresponding to the first service.
  • the scene gear is used to indicate the sleep and wake-up conditions of each time slice of the first service in the sleep scheduling period, and the sleep and wake-up conditions corresponding to different scene gears are different.
  • an electronic device comprising a module/unit for performing the method performed by the first device in the first aspect or any possible implementation manner.
  • a system in a fourth aspect, includes a first device, a second device, and a third device.
  • the system may also include other devices.
  • the devices included in the system can implement distributed services, such as multiple screen collaboration.
  • Each device may be implemented by the electronic device of the second aspect or the electronic device of the third aspect.
  • a chip in a fifth aspect, includes a processor and an interface, the interface is used for communicating with the processor and receiving information from other devices; the processor is used for executing the above-mentioned first aspect and the first aspect The method described in any of the possible implementations of .
  • a computer-readable storage medium is provided, the computer-readable storage medium is used to store a computer program, and when the computer program runs on a computer, the computer is made to execute one or more of the following methods : the method executed by the first device in the first aspect or any one of the possible implementation manners.
  • a seventh aspect provides a computer program product comprising instructions, the computer program product is used to store a computer program, and when the computer program is run on a computer, the computer is caused to perform one or more of the following methods: The method performed by the first device in the above-mentioned first aspect or any possible implementation manner.
  • a unified sleep-wake-up schedule is established for each device in the distributed system.
  • the power consumption of each device is saved as much as possible without affecting the normal service interaction of each device in the distributed system.
  • the sleep scheduling method provided by the embodiments of the present application can be applied to many-to-many connection scenarios .
  • Fig. 1 is the working schematic diagram of PSM
  • Fig. 2 is the working schematic diagram of TWT
  • Fig. 3 is the working schematic diagram of NOA
  • FIG. 4 is a schematic diagram of the architecture of a first distributed system provided by an embodiment of the present application.
  • FIG. 5 is a schematic diagram of the architecture of a second distributed system provided by an embodiment of the present application.
  • FIG. 6 is a schematic diagram of a sleep-wake-up period provided by an embodiment of the present application.
  • FIG. 7A is a schematic diagram of a hardware structure of an electronic device provided by an embodiment of the present application.
  • FIG. 7B is a schematic diagram of a software structure of an electronic device provided by an embodiment of the present application.
  • FIG. 8 is a schematic diagram of the scheduling relationship of each functional module for implementing the sleep scheduling method provided by the embodiment of the present application.
  • FIG. 9 is a schematic diagram of a frame structure for carrying a first part of an RP value provided by an embodiment of the present application.
  • FIG. 10 is a schematic flowchart of a sleep scheduling method for a distributed system provided by an embodiment of the present application.
  • FIG. 11 is a schematic structural diagram of a PNF provided by an embodiment of the application.
  • FIG. 12 is a schematic flowchart of an exemplary sleep scheduling method provided by an embodiment of the present application.
  • FIG. 13 is a schematic diagram of a processing flow of an emergency service provided by an embodiment of the present application.
  • FIG. 14 is a schematic structural diagram of a dynamic negotiation frame provided by an embodiment of the present application.
  • FIG. 15 is another schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • a multi-screen collaboration function (or referred to as a multi-device collaboration function) is provided, thereby supporting applications and services of multi-device collaboration, such as multi-screen collaboration and information sharing.
  • device 1 can cast a screen to device 2, so that files on device 1 can be opened on device 2.
  • a mobile phone and a personal computer personal computer, PC
  • a mirror image of the mobile phone is displayed on the display screen of the PC, and the mirror image of the mobile phone displayed on the PC can also be understood as a screen-casting interface.
  • the user operates on the screen projection interface on the PC. For example, if the user chooses to open file A, the PC can open file A, but in fact file A is a file in the mobile phone. Compared with a mobile phone, a PC has a larger display screen area, and a user viewing the file on the PC can improve the user's viewing effect.
  • distributed services applications or services that rely on the collaborative work of multiple devices are collectively referred to as distributed services. It should be understood that supporting distributed services requires connecting multiple terminal devices such as mobile phones, tablets, PCs, and display screens to achieve one-to-one connection or one-to-many connection between multiple devices, or even many-to-many connection, that is, multiple The equipment is interconnected, so that distributed services can run collaboratively in multiple terminal equipment.
  • multiple sleep scheduling methods are provided to save power consumption of each device in the network topology, for example, the following sleep scheduling methods.
  • Dormancy scheduling mode based on the power save mode (PSM) protocol.
  • the sleep scheduling method is suitable for a one-to-many network topology.
  • one-to-many is one-to-many between an access point (also called an access node) (access point, AP) and a station (also called a station) (station, STA).
  • the AP can be regarded as the master node, and the STA can be regarded as the slave node.
  • the AP maintains the connection of multiple STA devices, so the sleep scheduling method based on the PSM protocol can also be considered as a central sleep strategy.
  • the main idea is that the AP caches the data of the STA, and when any STA sleeps over, it actively requests the AP to obtain data, and the AP sends the data to the STA.
  • the STA can continue to sleep, so as to achieve the purpose of saving power consumption.
  • the server can send the data of one or more STAs to the AP, and the AP caches the data of one or more devices.
  • the AP periodically broadcasts the buffer status of the AP in a beacon frame. Any STA can wake up periodically at the start of a fixed beacon frame according to the listening interval to monitor the beacon frame broadcast by the AP. If the STA monitors the beacon frame and determines from the beacon frame that the AP stores the data of the STA, then the STA requests the AP to obtain data; on the contrary, if the STA determines from the beacon frame that the AP does not store the data of the STA, then the STA STA continues to sleep.
  • the second sleep scheduling method is a sleep scheduling method based on the target wake time (TWT) protocol.
  • TWT target wake time
  • the TWT mechanism can be applied to energy-saving scenarios in a large-scale IoT environment.
  • the second dormancy scheduling mode is similar to the first dormancy scheduling mode, and is also a central dormancy strategy, that is, a central node is required for scheduling.
  • the STA and AP negotiate to establish a schedule, which may consist of TWT time periods.
  • the AP performs sleep scheduling for each STA in the network topology based on the schedule.
  • the TWT time period negotiated by the STA and the AP includes one or more beacon periods.
  • the STA will wake up and wait for the trigger frame sent by the AP to perform a data exchange.
  • the STA completes this data exchange, the STA enters the sleep state.
  • each STA independently negotiates a TWT time period with the AP, and each STA has a separate TWT time period.
  • the TWT time periods of STA1 and STA2 are TW1 and TW2 respectively, that is, the wake-up times of STA1 and STA2 are different.
  • the AP can also group multiple STAs according to the set TWT time period, so that the AP can schedule multiple STAs at the same time, thereby improving the scheduling efficiency.
  • Dormancy scheduling mode 3 Dormancy scheduling mode based on notice of absence (NOA) protocol.
  • NOA protocol can be applied to a network topology established by a peer-to-peer (Peer-to-Peer, P2P) protocol.
  • P2P peer-to-peer
  • the general idea of the NOA protocol is that the central node determines the time to enter and exit dormancy, and the slave node sleeps and wakes up at the same time as the central node according to the decision of the central node. For example, the central node sends NOA information to the slave node, so that the slave node sleeps and wakes up simultaneously with the central node according to the received NOA information.
  • the central node configures the time for entering and exiting sleep, and generates NOA information.
  • the central node sends NOA information to one or more slave nodes through beacon frames, etc. Any slave node receives NOA information, and sleeps or exits sleep according to the NOA information.
  • the central node is an AP and the slave node is a STA.
  • the AP sends a beacon frame carrying NOA information.
  • STA1 and STA2 receive the beacon frame at the target beacon transmission time (TBTT), and according to the NOA information carried in the beacon frame, the sleep time can be set to be consistent with the sleep time of the AP .
  • TBTT can be considered as the time interval during which the AP continuously sends two beacons.
  • the above-mentioned three sleep scheduling methods can be considered as scheduling methods based on the central node.
  • the AP acts as the central node to maintain the connections of multiple STA devices.
  • each STA independently negotiates a TWT time period with the AP, and the AP maintains the connections of multiple STA devices.
  • the AP in the third sleep scheduling mode, can be regarded as a central node, and multiple STAs sleep and wake up at the same time as the AP based on the NOA information of the AP.
  • more and more services may be expected to be implemented collaboratively among any devices in the network.
  • the above three sleep scheduling methods can all be considered as scheduling methods based on the central node, which obviously cannot be applied to the many-to-many network topology.
  • each STA needs to send a request to the AP to trigger the AP to send the buffered data to the STA.
  • the signaling overhead is large and the data acquisition efficiency is low.
  • sleep scheduling mode 3 the setting of NOA information is relatively simple and fixed. Once the NOA information is set, it is generally fixed, unless the NOA information is reset or the set NOA information is cancelled. However, there may be burst services in the network topology. Obviously, the sleep scheduling mode 3 cannot meet the scene of burst services.
  • the embodiment of the present application provides a sleep scheduling method for a distributed system, which saves the power consumption of each device as much as possible without affecting normal service interaction.
  • the sleep scheduling method provided in this embodiment of the present application can be applied to various distributed systems, such as the following distributed systems:
  • WiFi P2P wireless fidelity peer-to-peer
  • the WiFi P2P protocol is a point-to-point connection technology that enables multiple WiFi devices to form a network without an access point (also known as an access point, AP).
  • the network may also be called a P2P Network, or a P2P group, and multiple WiFi devices within the network can communicate with each other.
  • the general principle of the WiFi P2P protocol is that a Transmission Control Protocol (TCP)/Internet Protocol (IP) link can be established directly between two workstations (also known as stations) (Station, STA).
  • TCP Transmission Control Protocol
  • IP Internet Protocol
  • STA One of the two STAs can be regarded as an AP in the traditional sense, and is called a group owner (GO).
  • GO group owner
  • the other STA of the two STAs can be called a group.
  • User group client, GC
  • GC group client
  • a GO in a P2P Network or a P2P Group can correspond to one GC, or can correspond to multiple GCs, that is, there can be a one-to-one relationship or a one-to-many relationship between GO and GC.
  • FIG. 4 shows a network architecture of distributed system one.
  • FIG. 4 includes three terminal devices, which are respectively a terminal device 401 , a terminal device 402 and a terminal device 403 located in a network.
  • the terminal device 401 and the terminal device 402 are mobile phones, and the terminal device 403 is a PAD as an example.
  • the terminal device 403 is GO, and the terminal device 401 and the terminal device 402 are both GCs.
  • the terminal device 403 can perform collaborative services with the terminal device 401 , and can also perform collaborative services with the terminal device 402 . For example, as shown in FIG.
  • the terminal device 403 and the terminal device 402 can perform screen projection services. If the business that needs to be coordinated exists in any two GCs in multiple interconnected settings, since the GC and the GC cannot communicate with each other, it is obvious that the coordinated business cannot be performed. For example, as shown in Figure 4, information sharing needs to be implemented between the terminal device 401 and the terminal device 402. However, since the terminal device 401 and the terminal device 402 are both GCs, the roles of the terminal device 402 and the terminal device 401 are limited. The connection between the terminal device 402 and the terminal device 103 needs to be disconnected.
  • FIG. 4 takes the terminal device 401 as the GO and the terminal device 402 as the GC as an example. That is to say, the role of a device can change as the chain is established. For example, after the initial chain establishment of the terminal device 401, the role of the terminal device 401 is GC, and after the chain is re-established, the role of the terminal device 401 is GO.
  • WiFi P2P protocol is developed based on the 802.11 protocol framework and belongs to a central network communication structure. That is, WiFi P2P requires that each terminal device must be configured with a role, such as GO or GC. As a central node, GO can communicate with any GC node connected to the GO, but cannot communicate with each other between GO and GO, and between GC and GC. For example, the terminal device 402, the terminal device 401 and the terminal device 403 cooperate to watch videos on multiple screens. If the terminal device 402 uses the information sharing function, it is limited by the roles played by the terminal device 403 and the terminal device 401, and the terminal device 402 and the terminal need to be disconnected. Only the connection between the devices 403 can realize the information sharing between the terminal device 402 and the terminal device 401 , otherwise the information sharing between the terminal device 402 and the terminal device 401 cannot be realized.
  • a role such as GO or GC.
  • GO can communicate with any GC node connected to the GO, but cannot communicate with each
  • Distributed system two, one-to-one connection, or one-to-many connection, or many-to-many connection system For example, devices discover each other based on Bluetooth or WiFi, and establish a connection with the discovered device; then negotiate link information for establishing WiFi direct communication with each other through the established communication channel, and implement WiFi direct communication between devices based on the link information , thus forming a distributed system. Since the communication connection is established between the devices after discovery, and then the link information for establishing the WiFi direct communication between the devices is negotiated through the communication channel established between the devices, there is no need to assign specific roles to each device. Devices can have a one-to-one relationship, a one-to-many relationship, or a many-to-many relationship.
  • the roles of each device in the established distributed system are equal. In this way, distributed services can be coordinated among any devices, and distributed services will not be restricted due to role issues.
  • the first device of the distributed system can mirror the screen to the second device, and files can be shared between the first device and the third device, that is, without role conflict.
  • FIG. 5 is a schematic diagram of a distributed system.
  • FIG. 5 takes the distributed system including 5 devices as an example, it should be understood that these 5 devices are in the same network.
  • the five devices are device 501 , device 502 , device 503 , device 504 and device 505 .
  • Device 501 , device 502 , device 503 , device 504 , and device 505 can perform multi-screen collaboration or information sharing.
  • device 501 can perform multi-screen collaboration or information sharing with device 502 or device 503, device 502 and device 504 can perform multi-screen collaboration, and device 503 and device 505 can perform information sharing.
  • Figure 5 takes as an example that device 501 is a mobile phone, device 502 is a portable computer, device 503 is a tablet computer, device 504 is a personal computer, and device 505 is a smart speaker.
  • device 501 may broadcast a discovery message over a Bluetooth communication channel, the discovery message being used to discover one or more devices, eg, device 502 - device 505 .
  • the device 503 receives the discovery message, and can send a response message to the device 501 for the discovery message.
  • the device 501 receives the response message, and can establish a Bluetooth connection with the device 503 according to the response message.
  • other devices can also establish a Bluetooth connection with the device 501 .
  • the device 501 After the device 501 establishes a Bluetooth connection with each device, it can negotiate link information for establishing WiFi direct communication, and establish WiFi direct communication with each other based on the link information, thereby forming a second distributed system.
  • the sleep scheduling method provided by the embodiment of the present application can be applied to various scenarios, for example, the following scenarios:
  • Scenario 1 also known as a keep-alive scenario, means that there is no interaction of business data among multiple interconnected devices. For example, multiple devices are connected to form a distributed system. However, at present, none of the devices in the distributed system have services that need to be performed, and naturally there is no need for data interaction between devices. In this case, any device in the distributed system can be in a sleep state to save power consumption as much as possible. It should be understood that even if the device is in a dormant state, the link between the devices remains connected, so that some data (that is, keep-alive data) can be exchanged between the devices, such as the interaction of data that is not sensitive to small traffic and delay, and is not It will affect the normal operation between devices.
  • some data that is, keep-alive data
  • Scenario 2 also known as a business scenario, refers to the interaction of business data among multiple interconnected devices.
  • the mobile phone is the device that initiates screen projection
  • PC1, PC2, and PC3 are the service devices for mirroring.
  • the mobile phone projects or shares documents to PC1, PC2, and PC3.
  • each device can be independently scheduled according to the specific service form of each device in the distributed system, such as ongoing or not, so that each device can be independently scheduled without affecting the service latency and throughput.
  • the device goes to sleep as much as possible to save power.
  • Scenario 3 also known as a business burst scenario, that is, a sudden business is generated between multiple interconnected devices.
  • each device in the distributed system can be flexibly scheduled, so that the data of the burst service is transmitted as quickly as possible, and the sleep of the entire distributed system is not affected as much as possible.
  • the minimum sleep-wake-up time (unit) may be defined in the time dimension, for example, a time slot of 16 ms is used as the minimum sleep-wake-up time, and N minimum sleep-wake-up times are used as the sleep-wake-up period, where N is greater than 2 the integer.
  • FIG. 6 is a schematic diagram of a sleep-wake-up cycle.
  • the time slots included in the sleep-wake-up period can be divided into announcement time slots and service time slots.
  • the announcement time slots are, for example, the first M time slots of the sleep-wake-up period, and are used for each device in the distributed system to notify the device of the sleep-wake-up situation in the sleep-wake-up period.
  • the time slot after the announcement time slot is the service time slot, which is mainly used for sending and receiving data.
  • the first device may send a periodic notification frame (periodical notify frame, PNF) in an announcement time slot, where the PNF is used to indicate the first device Sleep-wake condition throughout the sleep-wake cycle.
  • PNF periodic notification frame
  • Each device of the distributed system receives the PNF from other devices, and can determine and update its own sleep-wake-up time based on its own sleep-wake-up situation.
  • a sleep-wake-up schedule may be established, and the sleep-wake schedule may be used to indicate the sleep-wake-up time of each device in the distributed system.
  • the sleep-wake-up schedule is a K*N-sized bitmap, where K is the number of devices included in the distributed system, and N is the number of time slots in the sleep-wake-up period. Since the sleep-wake schedule includes sleep-wake information of each device in the distributed system, each device can select other suitable devices to perform distributed services based on the sleep-wake schedule. Since each device in the distributed system does not need to rely on a fixed device in the distributed system, such as a central node, to update the sleep-wake schedule table, the sleep scheduling method provided by the embodiments of the present application can be applied to many-to-many connection scenarios.
  • any device actively performs distributed services according to the sleep-wake-up schedule, that is, data transmission, without sending a request in advance to trigger the other party to send data.
  • the sleep-wake scheduling method signaling overhead between devices can be reduced. , to improve the efficiency of data transmission.
  • Each device dynamically updates its own sleep and wake-up status according to the sleep-wake-up status of other devices, and the sleep-wake-up status can be flexibly changed.
  • it can meet the actual transmission requirements of burst services.
  • the technical solutions provided in the embodiments of the present application may be applied to electronic devices, for example, any device that constitutes the first distributed system or the second distributed system.
  • Electronic devices and embodiments for using such electronic devices are described below.
  • the electronic device may be a portable electronic device, such as a mobile phone, a PAD, a portable computer, a wearable device with a wireless communication function (such as a smart watch, smart glasses, smart bracelet, or smart helmet, etc.), or in-vehicle equipment, etc.
  • portable electronic devices include, but are not limited to, carry-on Or portable electronic devices with other operating systems.
  • the above-mentioned electronic device may not be a portable device, for example, it may also be a desktop computer, such as a PC, or may also be a device such as a television.
  • FIG. 7A shows a schematic structural diagram of an electronic device 700 .
  • the illustrated electronic device 700 is only an example, and that the electronic device 700 may have more or fewer components than those shown, two or more components may be combined, or may have different Parts configuration.
  • the various components shown in the figures may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and/or application specific integrated circuits.
  • the electronic device 700 may include a processor 710 , an external memory interface 720 , an internal memory 721 , a universal serial bus (USB) interface 730 , a charge management module 740 , a power management module 741 , and a battery 742 , Antenna 1, Antenna 2, Mobile Communication Module 750, Wireless Communication Module 760, Audio Module 770, Speaker 770A, Receiver 770B, Microphone 770C, Headphone Interface 770D, Sensor Module 780, Key 790, Motor 791, Indicator 792, Camera 793 , display screen 794, and subscriber identification module (subscriber identification module, SIM) card interface 795 and so on.
  • a processor 710 an external memory interface 720 , an internal memory 721 , a universal serial bus (USB) interface 730 , a charge management module 740 , a power management module 741 , and a battery 742 , Antenna 1, Antenna 2, Mobile Communication Module 750, Wireless Communication Module 760,
  • the sensor module 780 may include a pressure sensor 780A, a gyroscope sensor 780B, an air pressure sensor 780C, a magnetic sensor 780D, an acceleration sensor 780E, a distance sensor 780F, a proximity light sensor 780G, a fingerprint sensor 780H, a temperature sensor 780J, a touch sensor 780K, and ambient light.
  • the processor 710 may include one or more processing units, for example, the processor 710 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), controller, memory, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (NPU) Wait. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
  • the controller may be the nerve center and command center of the electronic device 700 . The controller can generate an operation control signal according to the instruction operation code and timing signal, and complete the control of fetching and executing instructions.
  • a memory may also be provided in the processor 710 for storing instructions and data.
  • the memory in processor 710 is cache memory. This memory may hold instructions or data that have just been used or recycled by the processor 710 . If the processor 710 needs to use the instruction or data again, it can be directly called from the memory, so that repeated access can be avoided, the waiting time of the processor 710 can be reduced, and the efficiency of the system can be improved.
  • the processor 710 may execute the information sharing method provided by the embodiments of the present application.
  • the embodiment of the present application provides a fast collaborative operation service (Fast Collaborative Service).
  • the collaborative fast operation service may be a software module, the software module may run on the processor 710, and the software module may be understood as a computer program.
  • the software module can provide system-level capabilities. Taking the Android system as an example, from a business perspective, the software module can be placed in the system service (system_server) process, and the activity manager service in the system_server process (activity manager service, Modules such as AMS), package manager service (PMS), or window manager service (window manager service) jointly build the basic capabilities of the platform.
  • system_server system service
  • the activity manager service in the system_server process activity manager service, Modules such as AMS), package manager service (PMS), or window manager service (window manager service) jointly build the basic capabilities of the platform.
  • the collaborative shortcut operation service can also be placed in other processes.
  • the processor 710 integrates different devices, such as integrating a CPU and a GPU
  • the CPU and the GPU may cooperate to execute the methods provided by the embodiments of the present application.
  • some algorithms in the methods provided by the embodiments of the present application are executed by the CPU, and another part of the algorithms are executed by the GPU Execute for faster processing efficiency.
  • processor 710 may include one or more interfaces.
  • the interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous transceiver ( universal asynchronous receiver/transmitter, UART) interface, mobile industry processor interface (MIPI), general-purpose input/output (GPIO) interface, subscriber identity module (SIM) interface , and/or Universal Serial Bus (USB) interface, etc.
  • I2C integrated circuit
  • I2S integrated circuit built-in audio
  • PCM pulse code modulation
  • PCM pulse code modulation
  • UART universal asynchronous transceiver
  • MIPI mobile industry processor interface
  • GPIO general-purpose input/output
  • SIM subscriber identity module
  • USB Universal Serial Bus
  • the USB interface 730 is an interface that conforms to the USB standard specification, and can specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, and the like.
  • the USB interface 730 can be used to connect a charger to charge the electronic device 700, and can also be used to transmit data between the electronic device 700 and peripheral devices.
  • the charging management module 740 is used to receive charging input from the charger.
  • the power management module 741 is used for connecting the battery 742 , the charging management module 740 and the processor 710 .
  • the power management module 741 receives input from the battery 742 and/or the charging management module 740, and supplies power to the processor 710, the internal memory 721, the external memory, the display screen 794, the camera 793, and the wireless communication module 770.
  • the I2C interface is a bidirectional synchronous serial bus that includes a serial data line (SDA) and a serial clock line (SCL).
  • processor 710 may contain multiple sets of I2C buses.
  • the processor 710 can be respectively coupled to the touch sensor 780K, the charger, the flash, the camera 793 and the like through different I2C bus interfaces.
  • the processor 710 may couple the touch sensor 780K through the I2C interface, so that the processor 710 and the touch sensor 780K communicate through the I2C bus interface, so as to realize the touch function of the electronic device 700 .
  • a mobile industry processor interface (mobile industry processor interface, MIPI) interface can be used to connect the processor 710 with peripheral devices such as the display screen 794 and the camera 793 .
  • MIPI interfaces include camera serial interface (CSI), display serial interface (DSI), etc.
  • the processor 710 communicates with the camera 793 through a CSI interface to implement the photographing function of the electronic device 700 .
  • the processor 710 communicates with the display screen 794 through the DSI interface to implement the display function of the electronic device 700 .
  • the GPIO interface can be configured by software.
  • the GPIO interface can be configured as a control signal or as a data signal.
  • the GPIO interface may be used to connect the processor 710 with the camera 793, the display screen 794, the wireless communication module 760, the audio module 770, the sensor module 780, and the like.
  • the GPIO interface can also be configured as I2C interface, I2S interface, UART interface, MIPI interface, etc.
  • the wireless communication function of the electronic device 700 can be implemented by the antenna 1, the antenna 2, the mobile communication module 750, the wireless communication module 760, the modulation and demodulation processor, the baseband processor, and the like.
  • Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals.
  • Each antenna in electronic device 700 may be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization.
  • the antenna 1 can be multiplexed as a diversity antenna of the wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
  • the mobile communication module 750 can provide a wireless communication solution including 2G/3G/4G/5G, etc. applied on the electronic device 700 .
  • the mobile communication module 750 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), and the like.
  • the mobile communication module 750 can receive electromagnetic waves from the antenna 1, filter and amplify the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation.
  • the mobile communication module 750 can also amplify the signal modulated by the modulation and demodulation processor, and then convert it into electromagnetic waves for radiation through the antenna 1 .
  • at least part of the functional modules of the mobile communication module 750 may be provided in the processor 710 .
  • at least part of the functional modules of the mobile communication module 750 may be provided in the same device as at least part of the modules of the processor 710 .
  • the wireless communication module 760 can provide applications on the electronic device 700 including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellites Wireless communication solutions such as global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared technology (IR).
  • WLAN wireless local area networks
  • BT Bluetooth
  • GNSS global navigation satellite system
  • FM frequency modulation
  • NFC near field communication
  • IR infrared technology
  • the wireless communication module 760 may be one or more devices integrating at least one communication processing module.
  • the wireless communication module 760 receives electromagnetic waves via the antenna 2 , frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 710 .
  • the wireless communication module 760 can also receive the signal to be sent from the processor 710 , perform frequency modulation on it, amplify the signal, and then convert it into an electromagnetic wave for radiation through the antenna 2 .
  • the antenna 1 of the electronic device 700 is coupled with the mobile communication module 750, and the antenna 2 is coupled with the wireless communication module 760, so that the electronic device 700 can communicate with the network and other devices through wireless communication technology.
  • the wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), broadband Code Division Multiple Access (WCDMA), Time Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC , FM, and/or IR technology, etc.
  • the GNSS may include global positioning system (global positioning system, GPS), global navigation satellite system (global navigation satellite system, GLONASS), Beidou navigation satellite system (beidou navigation satellite system, BDS), quasi-zenith satellite system (quasi -zenith satellite system, QZSS) and/or satellite based augmentation systems (SBAS).
  • global positioning system global positioning system, GPS
  • global navigation satellite system global navigation satellite system, GLONASS
  • Beidou navigation satellite system beidou navigation satellite system, BDS
  • quasi-zenith satellite system quadsi -zenith satellite system, QZSS
  • SBAS satellite based augmentation systems
  • the interface connection relationship between the modules illustrated in the embodiments of the present application is only a schematic illustration, and does not constitute a structural limitation of the electronic device 700 .
  • the electronic device 700 may also adopt different interface connection manners in the foregoing embodiments, or a combination of multiple interface connection manners.
  • the electronic device 700 implements a display function through a GPU, a display screen 794, an application processor, and the like.
  • the GPU is a microprocessor for image processing, and is connected to the display screen 794 and the application processor.
  • the GPU is used to perform mathematical and geometric calculations for graphics rendering.
  • Processor 710 may include one or more GPUs that execute program instructions to generate or alter display information.
  • Display screen 794 is used to display images, videos, and the like.
  • Display screen 794 includes a display panel.
  • the display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (active-matrix organic light).
  • LED organic light-emitting diode
  • AMOLED organic light-emitting diode
  • FLED flexible light-emitting diode
  • Miniled MicroLed, Micro-oLed, quantum dot light-emitting diode (quantum dot light emitting diodes, QLED) and so on.
  • the electronic device 700 can realize the shooting function, or realize the function of capturing images, through the ISP, the camera 793, the video codec, the GPU, the display screen 794, and the application processor.
  • the ISP is used to process the data fed back by the camera 793. For example, when taking a photo, the shutter is opened, the light is transmitted to the camera photosensitive element through the lens, the light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye. ISP can also perform algorithm optimization on image noise, brightness, and skin tone. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, the ISP may be located in the camera 793.
  • Camera 793 is used to capture still images or video.
  • the object is projected through the lens to generate an optical image onto the photosensitive element.
  • the photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor.
  • CMOS complementary metal-oxide-semiconductor
  • the photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal.
  • the ISP outputs the digital image signal to the DSP for processing.
  • DSP converts digital image signals into standard RGB, YUV and other formats of image signals.
  • the electronic device 700 may include 1 or N cameras 793 , where N is a positive integer greater than 1.
  • a digital signal processor is used to process digital signals, in addition to processing digital image signals, it can also process other digital signals. For example, when the electronic device 700 selects a frequency point, the digital signal processor is used to perform Fourier transform on the energy of the frequency point, and the like.
  • Video codecs are used to compress or decompress digital video.
  • Electronic device 700 may support one or more video codecs.
  • the electronic device 700 can play or record videos in various encoding formats, such as: moving picture experts group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4, and so on.
  • MPEG moving picture experts group
  • the NPU is a neural-network (NN) computing processor.
  • NN neural-network
  • Applications such as intelligent cognition of the electronic device 700 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, and the like.
  • Internal memory 721 may be used to store computer executable program code, which includes instructions.
  • the internal memory 721 may include a storage program area and a storage data area.
  • the storage program area can store an operating system, an application program required for at least one function (such as a sound playback function, an image playback function, etc.), and the like.
  • the storage data area may store data (such as audio data, phone book, etc.) created during the use of the electronic device 700 and the like.
  • the internal memory 721 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), and the like.
  • the processor 710 executes various functional applications and data processing of the electronic device 700 by executing the instructions stored in the internal memory 721 and/or the instructions stored in the memory provided in the processor.
  • the external memory interface 720 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device.
  • the external memory card communicates with the processor 710 through the external memory interface 720 to realize the data storage function. Such as saving pictures, videos and other files in an external memory card.
  • the electronic device 700 may implement audio functions through an audio module 770, a speaker 770A, a receiver 770B, a microphone 770C, an earphone interface 770D, and an application processor. Such as music playback, recording, etc.
  • the keys 790 include a power-on key, a volume key, and the like. Keys 790 may be mechanical keys. It can also be a touch key.
  • the electronic device 700 may receive key inputs and generate key signal inputs related to user settings and function control of the electronic device 700 .
  • Motor 791 can generate vibrating cues.
  • the motor 791 can be used for vibrating alerts for incoming calls, and can also be used for touch vibration feedback.
  • touch operations acting on different applications can correspond to different vibration feedback effects.
  • the touch vibration feedback effect can also support customization.
  • the indicator 792 may be an indicator light, which may be used to indicate charging status, battery change, and may also be used to indicate messages, missed calls, notifications, and the like.
  • the SIM card interface 795 is used to connect a SIM card. The SIM card can be contacted and separated from the electronic device 700 by being inserted into the SIM card interface 795 or pulled out from the SIM card interface 795 .
  • FIG. 7A do not constitute a specific limitation on the electronic device 700, and the mobile phone may also include more or less components than those shown in the figure, or combine some components, or separate some components, Or a different component arrangement.
  • the combination/connection relationship between the components in FIG. 7A can also be adjusted and modified.
  • the software system of the electronic device 700 may adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture.
  • the embodiment of the present invention takes the Android system with a layered architecture as an example to illustrate the software structure of the electronic device 700 as an example.
  • FIG. 7B is a block diagram of a software structure of an electronic device 700 according to an embodiment of the present application.
  • the layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate with each other through software interfaces.
  • the Android system is divided into four layers, which are an application layer, an application framework layer, a system library, and a kernel layer from top to bottom.
  • the application layer can include a series of application packages.
  • the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, etc.
  • the application framework layer provides an application programming interface (application programming interface, API) and a programming framework for applications in the application layer.
  • the application framework layer includes some predefined functions. As shown in FIG. 7B, the application framework layer may include window managers, content providers, view systems, telephony managers, resource managers, notification managers, and the like.
  • a window manager is used to manage window programs. The window manager can get the size of the display screen, determine whether there is a status bar, lock the screen, take screenshots, etc.
  • Content providers are used to store and retrieve data and make these data accessible to applications.
  • the data may include video, images, audio, calls made and received, browsing history and bookmarks, phone book, etc.
  • the view system includes visual controls, such as controls for displaying text, controls for displaying pictures, and so on. View systems can be used to build applications.
  • a display interface can consist of one or more views.
  • the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
  • the phone manager is used to provide the communication function of the electronic device 700 .
  • the management of call status including connecting, hanging up, etc.).
  • the resource manager provides various resources for the application, such as localization strings, icons, images, layout files, video files, etc.
  • the notification manager enables applications to display notification information in the status bar, which can be used to convey notification-type messages, and can disappear automatically after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc.
  • the notification manager can also display notifications in the status bar at the top of the system in the form of graphs or scroll bar text, such as notifications of applications running in the background, and notifications on the screen in the form of dialog windows. For example, text information is prompted in the status bar, a prompt sound is issued, the electronic device vibrates, and the indicator light flashes.
  • the system library includes core libraries and virtual machines, and is responsible for the scheduling and management of the operating system.
  • the system library consists of two parts: one part is the function functions that the java language needs to call, and the other part is the core library of the operating system.
  • the application layer and the application framework layer run in virtual machines.
  • the virtual machine executes the java files of the application layer and the application framework layer as binary files.
  • the virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, safety and exception management, and garbage collection.
  • a system library can include multiple functional modules. For example: surface manager (surface manager), media library (Media Libraries), 3D graphics processing library (eg: OpenGL ES), 2D graphics engine (eg: SGL), etc.
  • the surface manager is used to manage the display subsystem and provides the fusion of 2D and 3D layers for multiple applications.
  • the media library supports playback and recording of a variety of commonly used audio and video formats, as well as still image files.
  • the media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
  • the 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
  • 2D graphics engine is a drawing engine for 2D drawing.
  • the kernel layer is the layer between hardware and software, providing application programming interface (API) and programming framework for the application framework layer.
  • the kernel layer at least includes a hardware abstraction layer (HAL), a driver layer and a firmware layer.
  • the firmware layer is located between the driver layer and the hardware.
  • the dormancy scheduling service provided by the embodiments of the present application may be located at the kernel layer. For example, various algorithms involved in the sleep scheduling service may exist in the kernel layer in the form of corresponding functional modules in the form of encapsulation interfaces.
  • the hardware abstraction layer is an interface layer between the operating system kernel and the hardware circuit, and is used to realize the identification of the sleep scenario, the scheduling of the sleep-wake-up schedule of the device, and/or the power control of the device.
  • the hardware abstraction layer includes a scene recognition module and a basic scheduling module.
  • the scene recognition module is the interface with the application framework layer, which provides the ability to parse the commands of the application layer.
  • the application of the application layer sets the scene through a command, and the scene recognition module can determine the current application scene by parsing the command.
  • the scene identification module may notify the basic scheduling module of the determined scene.
  • the basic scheduling module can receive the information used to indicate the scene from the scene identification module, and generate the basic sleep and wake-up conditions of each link in the distributed system according to the scene, and notify the low-power system of the generated basic sleep and wake-up conditions of each link. consumption state machine module.
  • the hardware abstraction layer may further include a dynamic scheduling module, configured to cooperate with the low-power state machine module when an emergency service arrives, determine whether the emergency service can be sent in this sleep-wake cycle, and perform dynamic scheduling The negotiated sleep wake-up time is passed to the low-power state machine module.
  • a dynamic scheduling module configured to cooperate with the low-power state machine module when an emergency service arrives, determine whether the emergency service can be sent in this sleep-wake cycle, and perform dynamic scheduling The negotiated sleep wake-up time is passed to the low-power state machine module.
  • the dynamic scheduling module is not essential, so it is indicated by a dotted line in FIG. 7B .
  • the driver layer also known as the (host media access control, HAMC) layer, is used for the implementation of the protocol stack, such as the generation and analysis of elements in the sleep-wake schedule table in PNF, the maintenance of the sleep-wake-up state of each device, and the dynamic sleep-wake negotiation. Frame generation and parsing, interactive process and state machine of sleep dynamic negotiation, and power control interactive protocol.
  • HAMC host media access control
  • the driver layer may include a frame processing module, a low-power state machine module, a virtual access point (virtual access point, VAP) management module, a device link building module, a device synchronization module, and a master device election module.
  • VAP virtual access point
  • the frame processing module is mainly used for parsing and generating related frames, such as the processing of PNF, dynamic negotiation frames and notification frames of sleep and wake-up schedules.
  • the low-power state machine module is a low-power state machine, which is mainly used to generate the sleep and wake-up information of the device and maintain the sleep-wake-up schedule.
  • the low-power state machine module can be used to generate, reset, renew.
  • Low-power state machine modules can also be used to interact with other modules. For example, the low-power state machine module can notify other modules of the device's sleep wake-up information, dynamic negotiation information, and information required to generate various frames.
  • the VAP management module can be used to create and delete VAPs. It should be understood that a VAP is to virtualize multiple APs on a physical AP, each virtualized AP is a VAP, and each VAP provides the same functions as the physical AP. Users can create different VAPs on one AP to provide wireless access services for different user groups.
  • the device link building module can be used for related work such as link building and disconnection between devices.
  • the device synchronization module can be used to synchronize devices in the system.
  • the master election module can be used to elect masters from multiple devices in a distributed system, and to update masters.
  • the firmware layer also known as the (device media access control, DMAC) layer, is mainly used to directly control the hardware registers. For example, it can generate timer wake-up and sleep interrupt offsets based on the sleep wake-up schedule, and hardware timing based on TSF offsets. Wake-up by device interrupt, sleep by hardware timer interrupt based on TSF offset, data cache in sleep state, power gating register configuration for deep sleep and light sleep sleep state, and external power amplifier , PA), built-in variable gain amplifier (varialbe gain amplifier, VGA) power gear configuration;
  • DMAC device media access control
  • the firmware layer may include a data buffer module, a low power consumption timer module, a power control scheduling module, a sleep-wake-up state machine module, a demodulation module, and the like.
  • the data cache module is used to manage cached data. For example, in a dormant (keep alive) state, the data cache module can cache data that arrives within the sleep time of the device, or emergency service data that arrives and cannot be sent in time. When the data cached in the data cache module is larger than a certain threshold, the data cache module can notify the low-power state machine module to increase the wake-up time of the device.
  • the low-power timer module is mainly used to handle various interrupt events and distribution, and sleep-related timers to manage the start of each minimum sleep wake-up time and the start of the sleep scheduling period.
  • the power control scheduling module is mainly used for power control scheduling.
  • the power level can be adjusted through the distance information between devices and the bit error feedback at the receiving end.
  • the power control scheduling module determines the signal strength of the reference signal receiving power (RSRP) indicating the distance information between the sending and receiving ends, and converts it into different distance levels according to different signal strengths, so as to obtain different power transmission gears grade.
  • RSRP reference signal receiving power
  • the power control scheduling module performs dynamic power adjustment according to the bit error information fed back by the receiving end. When at a certain power level, the bit error fed back by the receiving end is relatively high, then dynamic power adjustment is performed. When the bit error fed back by the receiving end is higher than a certain threshold, a power upshift is triggered.
  • the sleep-wake-up state machine module can control the sleep-wake-up situation of each device according to the sleep-wake-up schedule.
  • the dormancy scheduling service can also be divided into more or less functional modules according to other factors, or even divided into 8 functional modules.
  • the functions of each functional module are divided in other ways.
  • the dormant scheduling service may not be divided into functional modules, but work as a whole.
  • FIG. 8 it is a schematic diagram of the scheduling relationship of each functional module for implementing the sleep scheduling method provided by the embodiment of the present application.
  • the firmware layer can set a wake-up interrupt according to the sleep-wake-up schedule, and the wake-up interrupt will trigger the low-power timer module to send a time slice arrival event to the low-power state machine module.
  • the time slice arrival event is used to trigger the low-power timer module to set the start of the sleep wake-up time and the start of the sleep scheduling period.
  • the low-power timer module receives the time slice arrival event, it can set a timer of 16ms, that is, set the start of the sleep wake-up time.
  • the low-power timer module can also detect the current time slot, such as an announcement time slot or a service time slot.
  • the device can send and receive service data according to the set sleep-wake-up time and sleep-wake-up period.
  • the application in the application layer can notify the scene identification module of the service information (scenario information) through the agreed interface. If the service changes, for example, the service type or service characteristics change, the scene recognition module can notify the basic scheduling module of the latest service information.
  • the basic scheduling module will estimate the sleep and wake-up situation of the device according to the latest service information and current service conditions, and notify the low-power state machine module of the estimation result as the basic sleep-wake-up time information.
  • the low-power state machine module receives and saves the basic sleep and wake-up time information from the basic scheduling module.
  • the low-power state machine module first inquires the buffering situation of the data cache module in the announcement time slot of each dormancy scheduling period, and then fills in the dormancy-wake-up schedule table according to the basic dormancy-wake-up time information.
  • the data buffer module may notify the low power consumption state machine module to temporarily increase the working time slot.
  • the low-power state machine module sends a notification frame of the sleep and wake-up condition of the device in this time slot, that is, the PNF, to the frame processing module.
  • the low-power state machine module will also send an information element (IE) for generating a dynamic negotiation notification frame to the frame processing module (5 in Figure 8).
  • IE information element
  • the frame processing module receives the PNF, parses the PNF, and notifies the low-power state machine module of the result after parsing the frame.
  • the low-power state machine module can update the sleep and wake-up schedule according to the result sent by the frame processing module.
  • the frame processing module receives the IE for generating the dynamic negotiation notification frame, and generates the dynamic negotiation frame according to the IE.
  • the frame processing module will also parse the received negotiation frame, and send the relevant information obtained after parsing (such as the time information of negotiated sending data to the low-power state machine module, so that the low-power
  • the power consumption state machine module updates the sleep and wake-up schedule, and modifies interrupts and sets low-power timers.
  • the low-power state machine module will check the sleep wake-up schedule to check whether the next time slot is 0 (that is, the wake-up time slot). Offset interrupt is set in case of wakeup scheduler. If the next time slot is 1 (ie sleep time slot), continue to set the timer.
  • the scene recognition module when it receives an indication from the application layer and needs to send urgent services, it notifies the dynamic scheduling module.
  • the dynamic scheduling module parses the emergency service message, determines the address of the receiver, and queries the low-power state machine module for the availability of the receiver.
  • the low-power state machine module informs the dynamic scheduling module of the busy and idle conditions of the receiver.
  • the dynamic scheduling module determines the latest available time slot according to the busy and idle conditions of the receiver. After that, the dynamic scheduling module notifies the low-power state machine module of the latest available time slot, and the low-power state machine module can modify the sleep and wake-up schedule according to the received latest available time slot information. Mark this time slot for negotiation of emergency service packets.
  • Any device in the distributed system can update its own sleep-wake-up status in the sleep-wake-up schedule according to the sleep-wake-up time of other devices. Therefore, each device selects other suitable devices at the right time according to the sleep-wake-up schedule for coordinated distribution. mode service, avoid unnecessary wake-up, thus saving power consumption.
  • the embodiments of the present application provide multiple devices, and the multiple devices may be the same device, such as the electronic device 300; or, the multiple devices may also be different devices, for example, some of the multiple devices are electronic devices 300, some devices are monitors.
  • the embodiments of the present application do not limit the implementation form of the multiple devices.
  • the multiple devices may all be electronic devices, or the multiple devices may also be chips in the electronic devices, or some of the multiple devices. It is an electronic device, and some devices are chips in electronic devices.
  • the embodiments of the present application also provide a distributed system correspondingly.
  • the distributed system may include at least two devices among multiple devices.
  • the distributed system may also include other devices. Multi-screen collaboration and information sharing can be performed between any devices in the distributed system.
  • multiple interconnected devices may form a system as shown in FIG. 4 , or may form a system as shown in FIG. 5 .
  • each device can independently control whether to sleep, so as to enter a longer sleep as much as possible and save energy to the greatest extent. consumption.
  • each device in the embodiments of the present application implements independent sleep and wake-up based on the same sleep scheduling period, and for unified scheduling, the master device in the system may be the main device, that is, the master device sets the sleep scheduling period, and the rest devices use the sleep schedule set by the master device.
  • the scheduling cycle is the main one.
  • each device when the link is established, each device has been assigned roles, GO can be regarded as the master device, and GC can be regarded as the slave device.
  • GO can be regarded as the master device
  • GC can be regarded as the slave device.
  • the roles of each device in the system are equal, that is, the master device and the slave device are not distinguished. Therefore, before introducing the sleep scheduling method provided by the embodiment of the present application, how to select the master device in the system as shown in FIG. 5 is introduced first.
  • multiple devices in the distributed system may be prioritized, and the device with the highest priority may be used as the master device. If the set of all devices in the distributed system is called a domain, the device with the highest priority in the domain is the master device. This embodiment of the present application does not limit the manner of determining the priority.
  • the device priority may be determined according to one or more of the device type of each device, the battery life of the device, the hardware capability of the device, the protocol version adopted by the device, the number of devices connected to the device, and the MAC address of the device. class.
  • the type of the device is, for example, a display, a PC, a tablet, a mobile phone, an IOT device, a smart speaker, or a wearable device.
  • the battery life of the device for example, is the remaining battery level of the device, such as high battery, medium battery, medium-low battery, and low battery. It should be noted that the embodiment of this application does not limit the number of levels of the remaining power level, and each remaining power level can be defined in advance.
  • the remaining power level is greater than or equal to 70% of the total power level, then the level of the remaining power level is high power; If the power is greater than or equal to 50% of the total power and less than 70% of the total power, the remaining power level is medium power; the remaining power is greater than or equal to 30% of the total power and less than 50% of the total power, then the remaining power The power level is medium and low power; the remaining power is less than 30% of the total power, then the remaining power level is low power.
  • the hardware capability of the device for example, the device uses dual WiFi chips or a single WiFi chip.
  • the type of the device, the endurance capability of the device, and the hardware capability of the device are only examples, and the embodiments of the present application do not limit the specific representation of the type of the device, the endurance capability of the device, and the hardware capability of the device.
  • the priority of each device may be determined according to the priority information of each device, such as the device type, the battery life of the device, the hardware capability of the device, the protocol version adopted by the device, the number of devices connected to the device, and the priority of the MAC address of the device. priority. That is, the priority of each device is determined according to the device type of each device. If the priority of each device is determined according to the device type of each device, the priority of the device can be further determined according to the battery life of the device, and so on until Prioritize each device.
  • the priority information of each device such as the device type, the battery life of the device, the hardware capability of the device, the protocol version adopted by the device, the number of devices connected to the device, and the priority of the MAC address of the device. priority. That is, the priority of each device is determined according to the device type of each device. If the priority of each device is determined according to the device type of each device, the priority of the device can be further determined according to the battery life of the device, and so on until Prioritize each device
  • Each device can report its own ranking priority (RP) value, and the RP value can be used to indicate the priority information of each device.
  • the RP value may occupy one field, or may occupy multiple fields, which is not limited in this embodiment of the present application. For example, each content indicated by the RP value may occupy different bits of the same field respectively; or each content indicated by the RP value may occupy different fields respectively.
  • the RP value may include two parts, one part is used to indicate the ranking level (ranking level), and the other part is used to indicate the MAC address of the device, wherein the ranking level may include the device level, the protocol version number of the device, and the connected device. number of devices.
  • the device level further includes the type of the device, the battery life of the device, and the hardware capability of the device.
  • the sorting level field includes three fields, and the three fields are a device level field, a protocol version number field, and a connection number field. It should be noted that the embodiments of the present application do not limit the specific names of the three fields. This embodiment of the present application does not limit the number of bits occupied by each field. Exemplarily, see Table 1 for the definition of the equipment level field.
  • the slave devices can synchronize based on the time of the master device, including but not limited to the following two ways.
  • the master device may periodically send time synchronization frames, which may carry time information for time synchronization.
  • the time synchronization frame may be an 802.11 Beacon frame, which carries timer synchronization function (timer synchronization function, TSF) time information and a basic service set identifier (basic service set identifier, BSSID) of the distributed system. Since the 802.11Beacon frame is used as the time synchronization frame, the TSF of the 802.11Beacon frame can be used, so that the hardware clock synchronization with an error level of 10us can be realized, and the synchronization time between devices can be shortened as much as possible.
  • time synchronization frame may be an 802.11 Beacon frame, which carries timer synchronization function (timer synchronization function, TSF) time information and a basic service set identifier (basic service set identifier, BSSID) of the distributed system. Since the 802.11Beacon frame is used as the time synchronization frame, the TSF of the 8
  • Any slave device receives a time synchronization frame from the master device, and can obtain the BSSID carried by the time synchronization frame. If the acquired BSSID is the same as its own BSSID, it can be considered that the time synchronization frame is sent by a master device located in a network, and synchronization with the master device can be realized according to the time synchronization frame. For example, if the slave device determines that the acquired BSSID is the same as its own BSSID, the TSF counter can be refreshed, thereby realizing time synchronization with the master device.
  • the second synchronization method is active time synchronization, that is, the slave device actively applies for time synchronization.
  • the slave device actively applies for time synchronization, and does not need to wait for the master device to send a time synchronization frame, and can complete synchronization with the master device in advance, thereby reducing the synchronization delay.
  • the slave device to apply for time synchronization is the first slave device.
  • the first slave device can actively broadcast a time synchronization request message, such as a sync_request action signaling frame, to request synchronization time from devices in the same network that have completed time synchronization.
  • the master device or other slave devices can send a response message, such as a sync_response action signaling frame, to the first slave device.
  • the response message may carry the TSF time information of the master device or other slave devices and the time domain (social slot) position of the sending information.
  • the social slot position can be considered as the time slot position where all devices in the near field interact when they discover each other.
  • the first slave device After receiving the response message, the first slave device can complete time pre-synchronization according to the TSF time information carried in the response message, that is, align with the TSF time information of the master device. It should be understood that each device maintains the TSF time information based on a local timer, but there is a delay in sending the information by the device. Therefore, after the first slave device receives the response message, the first slave device may not yet discover other slave devices in the network. Therefore, the first slave device can also monitor the action signaling frame from the master device or other slave devices in the social slot, so as to complete the final synchronization according to the time information carried in the action signaling frame.
  • the master device can set a sleep and wake-up period of N time slots, each time slot can be regarded as a time slice, and the minimum unit of the time slice can be preset, such as 16ms, or other possible values.
  • Each device in the system can choose to sleep or wake up in each time slot in the sleep-wake-up cycle according to actual requirements, such as connection with other devices and service conditions.
  • the form of a bitmap may be used to identify whether each time slot is in a sleep or wake-up state.
  • Each device can broadcast its own sleep and wake-up information, so that each device in the system knows each other's own sleep and wake-up status, so that the wake-up device can be selected to perform distributed services, and multiple devices can sleep as much as possible. , save energy.
  • first sleep-wake information the original basic sleep-wake information of each device
  • second sleep-wake information the sleep-wake information regenerated by each device based on service requirements
  • the method involves multiple devices in FIG. 4 or FIG. 5 .
  • the method involves a first device and multiple devices, and the multiple devices include, for example, a second device, a third device, or even a fourth device as an example.
  • the first device may be any device in FIG. 4 or FIG. 5
  • the multiple devices may also be any device in FIG. 4 or FIG. 5 . Since for any device, the process of updating its own sleep and wake-up information is the same for each device, in the following introduction process, the first device updates its own sleep and wake-up information as an example.
  • N 32
  • FIG. 10 shows a flow of a sleep scheduling method for a distributed system provided by an embodiment of the present application.
  • the method is performed by the first device as an example.
  • the scene identification module sends scene information to the basic scheduling module, and accordingly, the basic scheduling module receives the scene information, where the scene information is used to indicate the service characteristics of the first service to be performed by the first device.
  • the first device When the first service arrives, the first device may be required to switch from a sleep state to an awake state on certain time slots. For this reason, if the first service arrives, the application in the application layer can notify the scene identification module of the scene information of the first service through the agreed interface.
  • the scene identification module receives scene information from the application layer, and can identify the scene information to determine that the first service requires the first device to wake up from sleep.
  • the scenario information may include the MAC address of the opposite end, so as to inform the first device which device or devices the first service comes from.
  • the scene information may also include scene-related information, such as the packet sending interval of the first service, the minimum delay tolerance value of the first service, and the number of frames per second (number of frames per second, fps). one or more of, or other information used to identify the first service, such as service type, audio type, video type, or file type, etc. It should be understood that the sleep and wake-up conditions corresponding to different scene information are also different.
  • the first device is in the wake-up state in each time slot in the sleep scheduling period; if If the minimum tolerance value of the first service is relatively high, the first device may be in an awake state for part of the time in the dormancy scheduling period, and in a dormant state for part of the time slot.
  • the scene information may also include information for indicating scene-related information, such as called scene gear.
  • the scene gear can be set according to the scene-related information. For example, if the minimum delay tolerance value of the first service is low, the scene gear is higher, and the minimum tolerance value of the first service is higher, then the scene gear is low. It should be understood that the scene gear may be used to indicate the sleep-wake-up situation of the first device in each time slice within the sleep scheduling period. In this embodiment of the present application, multiple scene gears may be pre-defined, and different scene gears correspond to different sleep-wake-up situations.
  • the scene rank may occupy multiple bits, or the scene rank may be defined according to the sleep-wake state of each time slot of the sleep schedule period.
  • four scene gears may be defined, eg, referred to as first gear, second gear, third gear, and fourth gear.
  • the scene gear may occupy 2 bits, for example, 00 identifies the first gear, 01 identifies the second gear, 10 identifies the third gear, and 11 identifies the fourth gear. ⁇ , ⁇ “11111111111111111111111111111”, ⁇ “10101010101010101010”, ⁇ “10000100001000010000100001000010”, ⁇ “10000000000100000000001000000000”, ⁇ ,“0” ⁇ ,“1” ⁇
  • the scene information may also include scene gears and scene-related information, which are not limited in the embodiments of the present application.
  • the basic scheduling module generates second sleep and wake-up information according to the scene information and the first sleep-wake-up information, where the first sleep-wake-up information is used to indicate the current sleep-wake-up situation of the first device.
  • the basic scheduling module receives the scene information, and can estimate the sleep and wake-up situation of the first device according to the scene information and the current business situation, that is, the first sleep-wake-up information, to determine the time slot that the first device needs to wake up.
  • the device link establishment module of the first device will initialize the sleep-wake state of the first device.
  • the first device may be initialized to be in an awake state in each time slot in the dormancy scheduling period, so as to ensure the normal operation of various services as much as possible.
  • the structure of sleep-wake-up information for each link can be defined as follows:
  • Timeinfo is used to indicate the sleep and wake-up information of the link
  • MacAddr is the address of the peer end of the link
  • AwakeDozeBitmap is used to indicate the sleep and wake-up information of the link.
  • timeinfo eg MacAddr may indicate the MAC address of the second device
  • AwakeDozeBitmap is set to 1.
  • the device link establishment module may delete the Timeinfo of the link between the first device and the second device, that is, release the Timeinfo.
  • the device link building module After the device link building module initializes the Timeinfo of the first device and the second device, it can send the AwakeDozeBitmap to the basic scheduling module.
  • the basic scheduling module may generate the first sleep-wake-up information based on the scene information.
  • the basic scheduling module may generate the first sleep and wake-up information based on the first preset rule and the scene information.
  • the first preset rule can satisfy:
  • the basic scheduling module may acquire scene information, such as frames per second (frames per second, fps), and generate the first sleep and wake-up information according to the fps. It is agreed that the announcement time slot is the starting point of each dormant scheduling period, and the first time slot after the announcement time slot is the time slot that can send services. Starting from the first time slot in which services can be sent, the number of time slots that can continuously sleep is (The packet sending interval is equal to 1000/fps). For example, if the scene information indicates a 60fps scene, the number of time slots that can sleep continuously is That is, the first device should not sleep.
  • scene information indicates a 60fps scene
  • the number of time slots that can sleep continuously is That is, the first device should not sleep.
  • the first sleep wake-up information of the link should be designed to wake up for one time slot and sleep for one time slot.
  • the first sleep wake-up information that is, AwakeDozeBitmap, is shown in Table 2.
  • the first sleep wake-up information of the link should be designed to wake up for 1 time slot and sleep for 5 time slots.
  • the first sleep wake-up information that is, AwakeDozeBitmap
  • Table 3 also uses the agreed announcement time slot as the starting point of each dormancy scheduling period, and the first time slot after the announcement time slot is available for sending Take the time slot of a service as an example.
  • the first device may be required to switch from the sleep state on some time slots to the wake-up state. To this end, the first device needs to update the first sleep-wake information, that is, generate the second sleep-wake information. It can be considered that the second sleep-wakeup information is used to instruct the first device to perform the original service and the sleep-wakeup condition that the first service needs to meet.
  • the first dormancy wake-up information may be used to indicate that the first device is in a dormant state in each time slot in the dormancy scheduling period.
  • the scene identification module detects the arrival of the first service, for example, the scene identification module receives scene (service) information from the application layer, can identify the scene information, and notify the basic scheduling module of the identification result.
  • the basic scheduling module estimates, according to the received scene information, the sleep-wake-up situation of the first device performing the first service, and generates second sleep-wake-up information according to the estimation result and the first sleep-wake-up information.
  • the basic scheduling module may estimate the sleep-wake-up situation of the first device performing the first service based on a preset rule.
  • the preset rules may satisfy one or more of the following:
  • the basic scheduling module cannot determine the dormancy and wake-up status of the first device for the first service, and the second dormancy and wake-up information generated by the basic scheduling module is used to indicate the first device. It is in the awake state in each time slot in the sleep scheduling period.
  • the basic scheduling module determines that the first service arrives when the first device currently has no service, for example, scene information is received, but the specific scene cannot be specified according to the scene information. For example, the basic scheduling module cannot determine the minimum delay tolerance value or the scene gear of the first service, then the first device can be set to wake up in each time slot in the sleep scheduling period to ensure the smooth progress of the first service.
  • the first dormancy wake-up information indicates that the first device is in the wake-up state in each time slot in the dormant scheduling period
  • the first service arrives, and the second dormancy wake-up generated by the basic scheduling module
  • the information is used to indicate that the first device is in an awake state in each time slot in the sleep scheduling period.
  • the first device Because the first device currently has services, and the first sleep-wake-up information indicates that the first device is in a wake-up state in each time slot in the sleep scheduling period. It can be considered that the current service requires the first device to be in the awake state all the time. In order not to affect the current service of the first device, even if the first service arrives, the first device still keeps the awake state.
  • the first dormancy wake-up information indicates that the first device is in the awake state in some time slots in the dormant scheduling period
  • the first service arrives, and the basic scheduling module cannot determine that the first device is in the awake state.
  • the second sleep-wake-up information generated by the basic scheduling module is used to indicate that the first device is in the wake-up state in each time slot in the sleep-scheduling period; the basic scheduling module can determine that the first device performs the first The sleep-wake-up situation of the service, the basic scheduling module generates second sleep-wake-up information according to the first sleep-wake-up information and the determined sleep-wake-up situation of the first device performing the first service, and the second sleep-wake-up information can be used to indicate that the first device is sleeping Part of the time slot in the scheduling period is in an awake state, so that the first device is in a dormant state as much as possible to save power consumption.
  • the first sleep-wake-up information of the first device may be as shown in Table 4.
  • the sleep-wake-up information corresponding to the second service is shown in Table 5, for example.
  • the first device may update the first sleep-wake information, that is, regenerate the sleep-wake information, that is, the second sleep-wake information, according to the sleep-wake information of the first service and the first sleep-wake information.
  • the second sleep-wake-up information is shown in Table 6, for example.
  • the basic scheduling module can determine the new service when there is a service currently, it can update the first sleep-wake information based on the new service, that is, generate the second sleep-wake information. .
  • the first device may also update the first sleep-wake information based on a preset rule, that is, generate the second sleep-wake information.
  • the first device currently has a service
  • the first dormancy wake-up information indicates that the first device is in the awake state in each time slot of the dormant scheduling cycle
  • the basic scheduling module receives an instruction to delete the first service
  • the basic scheduling module It is impossible to determine the sleep-wake-up condition that the first device needs to meet for the remaining services, then the second sleep-wake-up information indicates that the first device is in the wake-up state in each time slot of the sleep scheduling period; on the contrary, the basic scheduling module can determine that the first device is in the wake-up state. If the rest of the service needs to satisfy the sleep-wake condition, then the second sleep-wake information is generated based on the first sleep-wake information and the determined sleep-wake condition.
  • the first device currently has a service
  • the first dormancy wake-up information indicates that the first device is in an awake state in a part of the time slot of the dormant scheduling period
  • the basic scheduling module receives an instruction to delete the first service
  • the basic scheduling module according to
  • the second dormancy and wake-up information is generated by the dormancy and wake-up conditions that the first device needs to meet to perform the remaining services and the first dormancy and wake-up information.
  • the basic scheduling module receives the command to adjust the service, and generates the second sleep and wake-up information according to the first sleep-wake-up information and the sleep-wake-up condition that the adjusted service needs to meet.
  • the update of the first sleep and wake-up information of the first device is to combine the sleep and wake-up information of all links of the first device. For each time slot, if the state of any link in the time slot is "1", the state of the time slot in the second sleep wake-up information is still “1"; only when all the links are in the time slot's state If the state is "0", the state of the time slot in the second sleep-wake-up information is "0".
  • the basic scheduling module sends the second sleep and wake-up information to the low-power state machine module, and correspondingly, the low-power state machine module receives the second sleep and wake-up information.
  • the low-power state machine module updates the sleep-wake-up schedule table according to the second sleep-wake-up information.
  • the basic scheduling module can notify the low-power state machine module of the latest sleep-wake-up status of the device, that is, the second sleep-wake-up information.
  • the low-power state machine module updates the latest sleep-wake-up information of the device to the sleep-wake schedule table. Since the sleep-wake schedule table can be used to schedule all devices in the distributed system, when the sleep-wake-up condition of a device is updated, the low-power state machine module can update the sleep-wake-up condition of the device to the sleep-wake-up schedule table. , so that the first device can select an appropriate device to perform the distributed service according to the sleep-wake-up schedule.
  • the frame processing module broadcasts the PNF in the announcement time slot of the next sleep-scheduling cycle to inform each other of the sleep-wake-up information corresponding to each other.
  • the PNF is used to indicate the sleep-wake-up situation of each time slot of the first device in the sleep scheduling period, which may be regarded as a private broadcast action frame.
  • the PNF may also include other information, such as the MAC address of the first device, information used to identify the type of the PNF, and the number of devices connected to the first device. and other information.
  • FIG. 11 is a schematic structural diagram of a PNF provided by an embodiment of the present application.
  • a PNF may include multiple fields, such as a MAC header field, a code field, an organizationally unique identifier (OUI) field, an OUI type field, an action type field, a or multiple attribute fields, connection number fields, frame check sequence (FCS), etc.
  • UMI organizationally unique identifier
  • OUI type field OUI type field
  • action type field a or multiple attribute fields
  • connection number fields such as connection number fields, frame check sequence (FCS), etc.
  • FCS frame check sequence
  • the MAC header field can be determined according to the MAC header of the action frame, for example, it can carry the MAC address (also referred to as the source address, that is, the PNF belongs to the first device) and the destination address of the first device. Since the first device broadcasts the PNF, the destination address is the destination address of the broadcast.
  • the code field can be filled in according to the category code of the action frame, for example, it can be determined to be 127 according to the 802.11 protocol, that is, indicating a Vendor-specific action.
  • the OUI field may be predefined, for example, the OUI field may be used to carry "0x00-E0-FC" to indicate that the PNF is a private frame.
  • the OUI Type field is used to identify the type of OUI, for example, a private frame related to the PNF provided by this embodiment of the present application.
  • the action type field is used to identify the action frame type, for example, the frame type of PNF can be "0x01".
  • the one or more attribute fields are at least used to carry sleep-wake-up information of the first device.
  • the connection number field is used to carry the number of devices connected by the first device.
  • S1001 only takes the first device as an example.
  • each device in the distributed system broadcasts the PNF in the announcement time slot in the dormancy scheduling period, so that the dormancy and wake-up schedule can be generated according to the dormancy and wake-up information of each device.
  • the frame processing module of the first device may also parse the PNF received from other devices, and send the parsing result to the low-power state machine module, so that the low-power state machine module can advertise the time slot according to other devices.
  • the sent PNF updates the sleep-wake schedule table stored by itself.
  • the sleep-wake schedule table carries identification information for uniquely identifying the device, such as a MAC address or an ID.
  • the low-power state machine module After the low-power state machine module updates the sleep-wake-up schedule, it can broadcast a PNF frame in the next announcement time slot for establishing a connection or transmitting information between devices.
  • the master device in the distributed system has defined a sleep scheduling period, and the low-power timer modules of each device in the system respectively set timers for setting the start of the sleep scheduling period and the start of the sleep wake-up time.
  • the low-power state machine module can update its own sleep and wake-up state so that the service can be performed normally.
  • the low-power state machine module can update the updated sleep-wake-up state to the saved sleep-wake-up schedule, and notify other devices of the updated sleep-wake-up state, so that other devices can update the saved sleep-wake schedule, so that The system adopts a unified sleep and wake-up schedule for sleep scheduling.
  • the first device may perform the first service according to the updated sleep-wake-up schedule. It should be understood that, in a possible scenario, the first device may need to re-evaluate its own sleep-wake-up status later. The following lists several scenarios in which the first device needs to update its own sleep-wakeup information and the stored sleep-wakeup schedule.
  • Scenario 1 may also be referred to as a link change scenario.
  • the service traffic on the link may change, and the current sleep and wake-up situation of the first device may not be optimal.
  • the data cache module of the first device stores more service data.
  • the wake-up time slot can be temporarily increased at this time.
  • the service traffic decreases for a period of time. In this case, the first device can be put into more sleep modes to save power consumption as much as possible.
  • the low-power state machine module of the first device may, before updating the sleep-wake-up schedule in the announcement time slot of each sleep scheduling period, that is, before sending the PNF, according to the traffic size of each link of the first device, Adaptively adjust the sleep-wake schedule. For example, when the traffic of the link between the first device and the second device exceeds a certain threshold, the low-power state machine module can temporarily increase the wake-up time slot, that is, the sleep-wake-up information of the first device can indicate more wake-up states.
  • a certain link of the first device may have a sudden emergency service. In this case, the wake-up time slot may also be temporarily increased.
  • the traffic statistics on the link between the first device and the second device can be implemented through the bottom layer, that is, the bottom layer monitors the traffic and collects statistics, or it can be based on business-related information statistics issued by the upper layer of the service flow.
  • the embodiment does not limit this.
  • the sleep-wake-up information of any link of the first device changes, and the first device needs to notify the changed sleep-wake-up information to the peer device (eg, the second device) of the corresponding link.
  • the peer device eg, the second device
  • the first device may update the sleep and wake-up information of the first link, and notify the second device of the updated sleep and wake-up information of the first link.
  • the second device may update the stored sleep-wake information of the first link according to the updated sleep-wake information of the first link from the first device.
  • the second device may notify the first device of the updated sleep-wake information of the first link, and the first device updates the sleep-wake information of the first link again based on this. In this way, the dormancy and wake-up information of the first link saved by the first device and the second device are consistent, so as to ensure the normal operation of the service.
  • the sleep-wake-up information of the first device needs to satisfy the sleep-wake-up information of each link of the first device.
  • the first device can store the sleep and wake-up information of each link of the first device. If the sleep and wake-up information of any link of the first device changes, the sleep and wake-up information of the first device needs to be updated, and the updated sleep and wake-up information needs to be updated. Update to the sleep-wake schedule table stored by the first device.
  • Scenario 2 also known as emergency business scenario.
  • Urgent business can be considered as a business that needs to be dealt with on a priority basis.
  • the first device may temporarily increase the wake-up time slot for sending or receiving emergency services. It should be understood that the first device needs to notify the second device to temporarily increase the wake-up time slot, so as to ensure that emergency services can be normally performed between the first device and the second device.
  • the first device and the second device may negotiate a sleep-wake condition for sending emergency traffic, and update sleep-wake information for a link (eg, the first link) between the first device and the second device .
  • a link eg, the first link
  • the first device and the second device may negotiate a sleep-wake-up situation for sending an emergency service.
  • the first device may update its own sleep-wake-up information and the stored sleep-wake-up schedule according to the sleep-wake-up information of the transmission link finally updated by the first device.
  • Scenario three also known as the keep-alive scenario. That is, the links of the interconnected devices remain connected, but there is no service data exchange between the interconnected devices.
  • this scenario although there is no service data interaction between interconnected devices, because the links of interconnected devices remain connected, some data can be maintained between devices, such as the interaction of data that is not sensitive to small traffic and delay, which will not affect the interaction between devices. normal work. Therefore, in the keep-alive scenario, the interaction of data that is not sensitive to small traffic and delay may be involved.
  • the first device will also update its own sleep-wakeup information and the stored sleep-wakeup schedule. For example, due to factors such as interference, the first device does not send the service data in time, but stores the service data in the data cache module.
  • the low-power state machine module of the first device may first query the data amount stored in the data cache module before updating the sleep-wake-up schedule in the announcement time slot of each sleep scheduling period. If the data amount is greater than or equal to the preset threshold, then The wake-up time slot can be temporarily increased to send the data stored in the data buffer module as soon as possible.
  • the sleep-wake-up time slot of the link of the first device also changes, because the first device needs to notify the peer device of the change in the sleep-wake-up condition of the link. And the first device needs to update the sleep and wake-up information of the first device, and update the updated sleep and wake-up information to the sleep and wake-up schedule stored in the first device.
  • the basic scheduling module can also start to detect the amount of data stored in the data cache module in each time slot. Once it is determined that the amount of data is greater than or equal to the preset threshold, unless the low-power state machine module updates the sleep state of the first device. Wake-up information and sleep-wake schedule.
  • Scenario 4 also known as the business change scenario.
  • the service of the first device may be changed, for example, the first service ends the first service, the first device joins the second service, or the first service of the first device is changed to the second service, or the first device deletes of previously conducted business, etc.
  • the first device needs to re-evaluate its own sleep-wake-up situation, that is, the first device can adaptively increase the wake-up time slot or decrease the wake-up time slot according to the change of the service. For example, if the first device ends the first service, the first device may temporarily reduce the wake-up time slot. For another example, if a second service is added to the first device, the first device may temporarily increase the wake-up time slot.
  • the low-power state machine module of the first device can first determine whether there is a change in the service before updating the sleep-wake-up schedule in the announcement time slot of each sleep scheduling period.
  • the wake-up information is adjusted, and the sleep-wake information and the sleep-wake schedule table are updated according to the sleep-wake-up information adjusted by the corresponding link.
  • the first device will update the sleep-wakeup information and the sleep-wakeup schedule.
  • the first device also needs to inform the opposite device of the latest sleep and wake-up information of the first device. For example, if the transmission of sleep-wake-up information of any link changes, the sleep-wake-up information needs to be regenerated and saved.
  • one end of the link can notify the frame processing module of the updated sleep and wake-up information, and the frame processing module announces the time slot to notify the frame way to inform the link peer of the new sleep and wake-up information.
  • the first device after the first device generates the second sleep-wake information and updates the sleep-wake schedule, it can also flexibly adjust the sleep-wake information of the corresponding link of the first device based on the actual application scenario, and flexibly adjust the sleep-wake information of the corresponding link according to the sleep-wake of the corresponding link.
  • the information updates its own sleep-wakeup information and sleep-wakeup schedule, so as to make the first device go into sleep more often and save power consumption on the premise of not affecting various services of the first device.
  • the following takes multiple scenarios as examples, and takes the peer device of the first device as the second device as an example to introduce how the first device updates the link-level sleep-wake information, as well as its own sleep-wake information and stored sleep-wake information. Timing of the schedule. It should be understood that the first device can monitor whether to enter any one of the above four scenarios, and if it enters a certain scenario, adaptively adjust the sleep and wake-up information of the corresponding link of the first device according to the actual requirements of the scenario. For convenience of description, hereinafter, the sleep-wake-up information at the link level is referred to as link sleep-wake-up information.
  • the first device adjusts the sleep and wake-up information of the transmission link.
  • the sleep-wake-up information adjusted by the first device for the transmission link can be called the first-link sleep-wake-up information; the sleep-wake-up information updated by the second device for the transmission link is called the second-link sleep-wake-up information. information.
  • the low power consumption state machine module determines that the first device enters any one of multiple scenarios, updates the sleep-wakeup information of the corresponding link, and updates its own sleep-wakeup information and sleep-wakeup schedule.
  • the following describes the specific process of the dormancy scheduling method provided by the embodiment of the present application in a keep-alive scenario and an emergency service after a normal service.
  • FIG. 12 is a schematic flowchart of a sleep scheduling method in a keep-alive scenario provided by an embodiment of the present application.
  • FIG. 12 takes the execution of the first device as an example.
  • the low power consumption timer determines whether the current time slot is an announcement time slot.
  • Interrupt events can be set, for example, the time slice arrival event is used to trigger the low-power timer to throw the time-slice event to the low-power state machine module. After receiving the event, the low-power state machine module will set a timer and determine whether the current time slot is an announcement time slot. If the current time slot is not an announced time slot, S1202-S1203 can be performed; if the current time slot is an announced time slot, then S1204 and the steps after S1204 can be performed.
  • the current time slot is a service time slot
  • service data can be sent and received on the time slot in the awake state according to the current sleep-wake-up schedule.
  • a timer can be set according to the sleep-wake-up schedule table, and an interrupt event can be set, so as to continue the sleep schedule in the next sleep schedule period.
  • the current time slot is the announcement time slot
  • the low-power state machine module updates the sleep-wake-up schedule.
  • the low-power state machine module may update the saved sleep-wake-up schedule according to the sleep-wake-up information indicated by the PNF frame from each device.
  • the basic scheduling module determines whether it is in a keep-alive scenario.
  • the scene identification module can identify the service, and generate scene information and send it to the basic scheduling module.
  • the basic scheduling module judges whether the service has data transmission and reception according to the received scene information, that is, judges whether there is a new service. For the specific implementation of the scene information, reference may be made to the related content introduction of the aforementioned S1001, and details are not repeated here. If the scene information indicates that there is a service, the basic scheduling module generates second sleep-wake information according to the scene information and the current first sleep-wake information.
  • the low-power state machine module in the first device will update the second sleep-wakeup information and the stored sleep-wakeup schedule.
  • the low power consumption state machine module may set the first device to be in a sleep state in each time slot in the sleep scheduling period.
  • the low-power state machine module may update the sleep-wake-up status of the first P time slots in the sleep-scheduling period, and update the sleep-wake-up schedule.
  • P is a positive integer, and P is as small as possible, and the P time slots are consecutive time slots. That is, the low-power state machine module updates the sleep and wake-up information of consecutive P time slots as close as possible to the announced time slot.
  • P available time slots that are as advanced and continuous as possible in the dormancy scheduling period may be selected to transmit service data, so as to improve data transmission efficiency. For example, P consecutive time slots are put into the awake state.
  • the low power consumption state machine module After the low power consumption state machine module updates the sleep and wake-up information, it can update the updated sleep and wake-up information to the stored sleep and wake-up schedule, and broadcast the updated sleep and wake-up information in the announcement time slot.
  • the data volume of the service data of the data cache module is small, it has little effect on the transmission efficiency of subsequent links. In this case, in order to save the power consumption of the first device as much as possible, it is not necessary to adjust the sleep and wake-up information of the P time slots. .
  • the low-power state machine module can update the sleep and wake-up information of P time slots.
  • the first device may be set to remain dormant during the dormancy scheduling period to save power consumption.
  • the amount of data in the data cache module may be larger or smaller. If the amount of data in the data buffer module is small, the P time slots are set to the wake-up state, which consumes a relatively large amount of power. Therefore, in some embodiments, when the low-power state machine module determines that the data cache module has service data that needs to be sent, it can also adjust the current sleep and wake-up information from one low-power consumption gear to another low-power consumption gear. For example, if the current low power consumption gear is the sixth gear, it can be adjusted from the sixth gear to the fourth gear, or other gears.
  • the specific gear to be adjusted can be predefined, for example, two low-power-consumption gears are adjusted up. Alternatively, it may be determined according to the monitored link traffic size which gear to adjust the current low power consumption to, so as to improve the data transmission efficiency as much as possible and reduce the power consumption of the first device as much as possible.
  • the first device updates the dormancy wake-up status of the first P time slots in the dormancy scheduling period, it can notify other devices in the system in the announcement time slot, and the other devices will update themselves according to the latest dormancy wake-up information of the first device. Stored sleep-wake schedule. In this way, the dormancy and wake-up schedules maintained by each device in the entire system are consistent, so as to ensure the normal operation of services among various devices, and each device can enter sleep as much as possible when normal services are performed to save power consumption as much as possible.
  • FIG. 13 is a schematic diagram of the processing flow of emergency services.
  • the first device needs to send emergency services to the second device, or the second device needs to send emergency services to the first device, the first device and the second device need to negotiate the emergency services according to the emergency services.
  • time slot and update its own sleep and wake-up information and the stored sleep and wake-up schedule.
  • the following describes how to update the sleep and wake-up information of the link when there is an emergency service from the second device.
  • the first device determines that there is an emergency service that needs to be sent after the time slot is announced.
  • the first device queries the sleep-wake-up schedule.
  • the first device determines whether the second device has been sleeping in the time slot after the current sleep scheduling period.
  • the dormancy and wake-up schedule table saved by the first device includes dormancy and wake-up information of the second device, so that whether the second device has been dormant in the time slot after the current dormancy scheduling period can be determined according to the dormancy and wake-up information of the second device.
  • the second device has been dormant in the time slot after the current dormancy scheduling period, and then stores the incoming emergency service data in the data cache module, so as to preferentially send the urgent service data when a dormancy scheduling period arrives.
  • the first device and the second device negotiate the time slot for emergency service in the announcement time slot, and then transmit and receive the emergency service in the negotiated time slot.
  • the second device is not always sleeping in the time slot after the current dormancy scheduling period, then the first device can select a time slot that can be used to send emergency services, and update the sleep wake-up information of the first device.
  • the first device sends the first notification frame to the second device, and accordingly, the second device receives the first notification frame.
  • the first device After the first device selects a time slot available for sending the emergency service, it may notify the second device that the first device will send the emergency service data.
  • the first notification frame can be sent in the wake-up time slot of the second device, for example, can be sent in the nearest time slot available to the second device, the first notification frame includes the identity information of the first device, and the first device selected can be used for sending.
  • Information such as the time slot of the emergency service (that is, the above-mentioned first link sleep and wake-up information).
  • the second device parses the first notification frame, and updates the sleep-wake-up information of the corresponding link.
  • the second device After receiving the first notification frame, the second device can parse the first notification frame, and obtain the first link sleep wake-up information from the first notification frame, that is, the number of time slots used by the first device to send emergency services to the second device and other information.
  • the second device may set the time slot of the number of time slots required for sending the emergency service to the awake state according to the first link sleep wakeup information, obtain the second link sleep wakeup information, and update the saved sleep wakeup schedule.
  • the second device may notify the first device of the second link sleep and wake-up information through the reply frame of the first notification frame, that is, the second notification frame, to start transmitting the time slot of the emergency service.
  • the first device and the second device perform sending and receiving of emergency services on the negotiated time slot.
  • device A initiates a screen projection service to device B, such as a 30fps distributed video stream; device A also initiates a screen projection service to device C, such as a 10fps distributed gallery.
  • the sleep-wake-up situation corresponding to the 30fps distributed video stream is shown in Table 7, that is, the sleep-wake-up information of device B in the sleep-wake-up schedule table is:
  • the sleep-wake-up situation corresponding to the 10fps distributed image gallery is shown in Table 8, that is, the sleep-wake-up information of device C in the sleep-wake-up schedule table is:
  • device A can generate the sleep-wake-up information shown in Table 9, that is, the sleep-wake-up information of device A in the sleep-wake schedule table is:
  • any of Device A, Device B, or Device C can broadcast its own sleep-wake-up information in the announcement time slot of the sleep-scheduling period, and update the latest sleep-wake-up information to Sleep-wake schedule.
  • Device A or device B or device C can perform sleep and wake-up according to its own sleep-wake-up information in the sleep-wake-up schedule.
  • device A wakes up in the first time slot, sleeps in the second time slot, wakes up in the third time slot, and so on.
  • the sleep and wake-up information of device A needs to be updated.
  • the sleep and wake-up information of device D is, for example, Table 10:
  • Device A updates its own sleep and wake-up information according to the sleep and wake-up information of device D, and the updated sleep and wake-up information is shown in Table 11, for example.
  • the emergency service arrives in the 11th time slot, and the emergency service requires 4 time slots. Then device A can inform device C to adjust the sleep and wake-up information according to the emergency service. As can be seen from Table 8, after the emergency service arrives, the latest wake-up time slot is the thirteenth time slot. It can be seen from Table 11 that device A is also in the wake-up state in the thirteenth time slot, so device A and device C can negotiate available time slots for emergency services in the thirteenth time slot.
  • the device A can send the third notification frame to the device C in the 13th time slot, and after receiving the first notification frame, the device C updates the sleep and wake-up information according to the emergency service request. For example, if device C determines that the emergency service requires 4 time slots, it can start from the 13th time slot and set the 4 consecutive time slots as the wake-up state, that is, set the 14th-17th time slots as the wake-up state. Device C may notify device A of the updated sleep and wake-up information, that is, device C sends a second notification frame to device A. When device A receives the second notification frame, it can also set the 14th to 17th time slots to the wake-up state.
  • Device C and device A respectively update their own sleep-wakeup information and sleep-wakeup schedule according to the negotiation result.
  • the updated sleep and wake-up information of device C is, for example, Table 12
  • the updated sleep and wake-up information of device A is, for example, Table 13.
  • Device A can wake up from sleep according to Table 13, and device C can wake up from sleep according to Table 12, so as to realize the sending and receiving of emergency services.
  • the device C in Table 8 is in the wake-up state in the thirteenth time slot
  • the device A in Table 11 is in the wake-up state in the thirteenth time slot, which are only examples.
  • device A may wake up the thirteenth time slot first, and then send the first notification frame to device C.
  • the first device may notify the second device of the adjusted sleep and wake-up information of the corresponding link.
  • the low-power state machine module sends a first notification frame to the second device, and accordingly, the second device receives the first notification frame, where the first notification frame carries the sleep and wake-up information of the first link.
  • the low power consumption state machine module receives a second notification frame from the second device, where the second notification frame carries the sleep and wake-up information of the second link.
  • the low power consumption state module may determine whether the first device enters any one of the above four scenarios. If it is determined that the first device enters a certain scenario, then the sleep-wake-up information of the corresponding link of the first device is updated to obtain the sleep-wake-up information of the first link. The first device also needs to notify the second device of the sleep and wake-up information of the first link, so that the second device adaptively updates the stored sleep-wake information of the corresponding link.
  • the data cache module of the first device stores more business data, in order to quickly store the business data stored in the data cache module It is transmitted to the second device, and the wake-up time slot can be temporarily increased at this time. That is, the first device can flexibly adjust the sleep-wake-up information of the transmission link to obtain the sleep-wake-up information of the first link. After obtaining the sleep and wake-up information of the first link, the first device may send a first notification frame to the second device, where the first notification frame carries the sleep and wake-up information of the first link. That is, the first device notifies the second device of the sleep wake-up information of the first link.
  • the second device may update the sleep and wake-up information of the transmission link saved by itself according to the sleep-wake-up information of the first link, and obtain the sleep-wake-up information of the second link.
  • the second device may notify the first device of the second link sleep and wake-up information, so that the first device updates the sleep and wake-up information of the corresponding link according to the second link sleep and wake-up information.
  • the first notification frame may be sent in the wake-up time slot of the second device.
  • the second device is in the wake-up state in the fifth time slot in the sleep scheduling period, then the first device may be in the fifth time slot. slot to send the first notification frame to the second device.
  • the first device may directly send the first notification frame to the second device in the fifth time slot. If the first device is sleeping in the 5th time slot and the second device is awake in the 5th time slot, the first device can wake up the 5th time slot first, and then wake up in the 5th time slot Send the first notification frame to the second device.
  • the second device after receiving the first notification frame, the second device feeds back the second notification frame to the first device. If the delay is not large, the second notification frame can be sent in the 5th time slot, and can also be sent in other wake-up time slots, such as the 6th time slot. Considering that due to the existence of factors such as interference, the second device may not be able to receive the first notification frame. timer. If the timer expires and the first device has not received the second notification frame from the second device, it can be considered that the second device has not received the first notification frame, and the first device can re-send the first notification to the second device frame.
  • the first device when there is an emergency service between the first device and the second device, the first device can also temporarily increase the wake-up time slot. That is, the first device needs to update the sleep-wakeup information of the transmission link between the first device and the second device. Likewise, after the first device updates the sleep-wake-up information of the transmission link, it needs to notify the second device.
  • the first notification frame may also instruct the second device to start an emergency service. For example, the first device sends the first notification frame to the second device in the fifth time slot of the second device.
  • the second device After the second device receives the first notification frame, it can wake up all the time slots after the fifth time slot, and the first device can also wake up all the time slots after the fifth time slot. In this way, the link sleep wake-up information between the first device and the second device is also consistent.
  • the first device can notify the second device. For example, the first device sends the first notification frame to the second device again to indicate the end of the emergency service.
  • the second device receives the first notification frame and can restore the sleep-wake-up information of the corresponding link to sleep-wake-up between emergency services. information.
  • Scenarios 3 and 4 are similar to scenarios 1 and 2, and the first device also needs to update the sleep-wakeup information of the corresponding link, which is not repeated here.
  • the low-power state machine module of the first device adjusts the sleep-wake-up information of any link, it needs to adaptively update its own sleep-wake-up information and sleep-wake-up schedule.
  • the first device updates its own sleep and wake-up information, it may notify other devices of the latest sleep and wake-up information of the first device.
  • the low-power state machine module may send the latest sleep and wake-up information of the first device to the frame processing module, and the frame processing module may generate a PNF based on the latest sleep and wake-up information of the first device to broadcast the PNF in the announcement time slot.
  • the first notification frame and the second notification frame may be sent in the announcement time slot of the dormancy scheduling period, or may be sent in the service time slot in the awake state in the dormancy scheduling period.
  • the first notification frame may include, for example, a MAC header field, a code field, an OUI field, an OUI type field, an action type field, an attribute field, and an FCS field, wherein the attribute field is used to carry the information of the first device. Sleep wakeup information. Similar to the PNF frame, the specific functions of the fields of the first notification frame may refer to the introduction of the PNF, and will not be repeated here.
  • the first device updates the sleep and wake-up information of the first link according to the second notification frame, and transmits and receives service data in the service time slot of the sleep scheduling period based on the updated sleep and wake-up information of the first link.
  • the first device After receiving the second notification frame, the first device can update the sleep and wake-up information of the first link according to the second notification frame, so as to ensure that the sleep and wake-up information of the links saved by the first device and the second device are consistent. Afterwards, the first device may send and receive service data in the service time slot in the awake state in the sleep scheduling period based on the updated link sleep and wake-up information.
  • the first device can flexibly adjust the sleep-wake information of the corresponding link according to the actual scene.
  • the following describes a possible implementation manner of the first device adjusting the sleep-wake information.
  • multiple low-power consumption gears may be predefined, and each low-power consumption gear is used to indicate a sleep-wake-up situation of each time slot of the first device in a sleep scheduling period.
  • the sleep and wake-up information corresponding to different low power consumption gears is different.
  • the basic scheduling module may determine what kind of first sleep-wake-up information to generate based on the scene information, that is, determine which low power consumption gear to use based on the scene information.
  • the low-power state machine module can also determine how to update the sleep-wake-up information according to the actual scenario, for example, adjust the low-power-consumption gear corresponding to the current sleep-wake-up information to another low-power gear.
  • six low power consumption gears may be defined, the six low power consumption gears include first gear, second gear, third gear, fourth gear, fifth gear and sixth gear, wherein , the higher the gear, the more power saving.
  • the announcement time slot of the first device in the dormancy scheduling period corresponding to any gear is in an awake state.
  • the first sleep and wake-up information of the first gear can be "11111111111111111111111111111", that is, all time slots in the entire sleep scheduling period are in the wake-up state;
  • the first sleep wake-up information of the second gear can be "111010101010101010101010101010101010101010", that is, the service time slot wakes up once every time slot;
  • the first sleep wake-up information of the third gear can be "111001001001001001001001001001001001", that is, the service time slot wakes up every 2 time slots;
  • the first sleep wake-up information of the fourth gear can be "11100001000010000100001000010000", that is, the service time slot wakes up every 4 time slots;
  • the first sleep wake-up information of the fifth gear can be "11100000010000001000000100000010", that is, the service time slot wakes up every 6 time slots;
  • the first sleep wake-up information of the sixth gear can be "11100000000001000000000010000000", that is, the service time slot wakes up once every 10 time slots.
  • a special gear can also be defined, for example, wake up 2 time slots every L*32 time slots, and L is a positive integer greater than or equal to 1. It can also be understood that in a special gear, the device can enter deep sleep. When the device is in deep sleep, wake-up of the device can be triggered based on special means, for example, wake-up of the device based on Bluetooth.
  • the new sleep-wake-up information initially transmitted by the basic scheduling module to the low-power state machine module may represent the lowest gear, that is, the first gear.
  • the basic scheduling module can adjust the gears in the first gear according to the scene information, that is, adjust the number of consecutive 0s in the first gear. For example, the basic scheduling module determines that the scene information from the application layer is "110000010000010000010000010000010", that is, it is required to wake up every 5 time slots.
  • the sleep wakeup information can be set to any one of the first to fourth gears. .
  • Each gear can correspond to a threshold, such as the amount of data sent per unit time.
  • the low-power timer module may set a timer to perform traffic statistics on the link between the first device and the second device. The timer starts. If the link traffic between the first device and the second device is lower than the threshold X1 for a period of time, the low-power state machine module can determine that the sleep wake-up information is reduced by one gear until it falls to the fourth gear . Further, if the current sleep and wake-up information has been reduced to the lowest limit, but the link traffic between the first device and the second device is still lower than the threshold X1 for a period of time, the low power consumption state module can continue to lower the lowest limit.
  • the low-power state machine module can increase the level corresponding to the sleep and wake-up information, for example, restore to full wake-up or service settings 's gear. If the link traffic between the first device and the second device continues to increase within a period of time and exceeds the threshold X2, the low-power state machine module can continue to increase the current level corresponding to the sleep and wake-up information until it reaches the highest level .
  • the first device when it determines that there is an emergency service, it can adjust the current sleep and wake-up information from one low power consumption gear to another low power consumption gear. For example, if the current low power consumption gear is the sixth gear, it can be adjusted from the sixth gear to the fourth gear, or other gears.
  • the specific gear to be adjusted can be predefined, for example, two low-power-consumption gears are adjusted up. Alternatively, it may be determined according to the monitored link traffic size which gear to adjust the current low power consumption to, so as to improve the data transmission efficiency as much as possible and reduce the power consumption of the first device as much as possible.
  • the first device determines that the amount of data stored in the data cache module is greater than the preset threshold, and can adjust the current sleep and wake-up information from one low power consumption gear to another low power consumption gear. For example, if the current low power consumption gear is the sixth gear, it can be adjusted from the sixth gear to the fourth gear, or other gears.
  • the specific gear to be adjusted can be predefined, for example, two low-power-consumption gears are adjusted up. Alternatively, it may be determined according to the specific amount of data to which gear the current low power consumption gear should be adjusted, so as to improve the data transmission efficiency as much as possible and reduce the power consumption of the first device as much as possible.
  • the first device determines that the service has changed, and can adjust the current sleep and wake-up information from one low power consumption gear to another low power consumption gear.
  • the first device is currently performing the first service, and the current low power consumption gear is the fourth gear. If the second service arrives, it can be adjusted from the fourth gear to the third gear, or other gears.
  • the specific gear to be adjusted can be predefined, for example, two low-power-consumption gears are adjusted down. Alternatively, it may be determined which gear to adjust the current low power consumption gear to according to the characteristics of the second service, so as to reduce the power consumption of the first device as much as possible.
  • the first device is currently performing the first service, and the current low power consumption gear is the fourth gear. If the first service is deleted, it can be adjusted from the fourth gear to the fifth gear, or other gears.
  • the specific gear to be adjusted can be predefined, for example, two low-power-consumption gears are adjusted up.
  • one device in a system formed by multiple devices establishing connections, one device may be selected from the multiple devices as the master device, and the master device decides to use N time slices as a sleep scheduling period.
  • Each device can independently select the sleep-wake state of each time slice in the sleep scheduling period.
  • Each device can broadcast its own sleep and wake-up information in a preset time slice of the sleep scheduling period.
  • Each device receives PNFs from other devices, and can determine and update the saved sleep and wake-up schedule in combination with its own sleep and wake-up conditions. In this way, all devices in the system can implement sleep scheduling based on a unified sleep and wake-up schedule.
  • the sleep scheduling method provided by the embodiment of the present application is applicable to many-to-many connection scenarios.
  • the embodiments of the present application further provide an electronic device, for example, a mobile phone, or a PAD, or a portable computer, or a smart speaker.
  • the electronic device may include: a display screen 1501; one or more processors 1502; one or more memories 1503 for storing one or more programs 1504; A communication bus 1505 is connected.
  • the display screen 1501 can be used to display the content of a file in the electronic device; or the display screen 1501 can also be used to display the desktop of the electronic device; or the display screen 1501 can be used to display an image and so on.
  • the electronic device when one or more programs 1504 stored in the memory 1503 are executed by one or more processors 1502, the electronic device can be used to execute the embodiments shown in FIG. 10 or 13 or 14 or other corresponding embodiments. each step.
  • each functional module in this embodiment of the present invention may be integrated into one processing module, or each module may exist physically alone, or two or more modules may be integrated into one module.
  • the basic scheduling module and the dynamic scheduling module may be the same module or different modules.
  • the above-mentioned integrated modules may be implemented in the form of hardware, or in the form of software function modules, or in the form of hardware combined with software function modules.
  • “at least one” refers to one or more, and “multiple” refers to two or more.
  • “And/or”, describing the association relationship of associated objects, indicates that there can be three kinds of relationships, such as , A and/or B, can indicate: the existence of A alone, the existence of A and B at the same time, the existence of B alone, where A and B can be singular or plural.
  • the character “/” generally indicates that the associated object is a kind of "or ” relationship.
  • “At least one of the following items” or similar expressions refers to any combination of these items, including any combination of single item(s) or plural items(s).
  • a, b or c At least one item (a) of , can represent: a, b, c, a and b, a and c, b and c, or a and b and c, where a, b, c can be single or multiple.
  • ordinal numbers such as “first” and “second” mentioned in the embodiments of the present application are used to distinguish multiple objects, and are not used to limit the size, content, order, and timing of multiple objects , priority or importance, etc.
  • the second file and the second file are only used to distinguish different files, but do not indicate the difference in size, content, priority, or importance of the two files.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

本申请公开了一种休眠调度方法及设备,该方法可用于包括第一设备、第二设备和第三设备的分布式系统。该方法包括:第一设备根据第一场景信息确定有第一业务到来,并根据第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,以及将第二休眠唤醒信息更新至休眠唤醒调度表。其中,第一休眠唤醒信息用于指示第一设备当前在休眠调度周期内的各个时间片上的休眠唤醒情况。第二休眠唤醒信息用于指示第一设备进行包括第一业务在内的业务时需要满足的休眠调度周期内的各个时间片上的休眠唤醒情况。本申请中各个设备基于该休眠唤醒调度表进行业务收发时,在不影响各个设备的正常业务交互的前提下,可尽可能节省各个设备功耗。

Description

一种休眠调度方法及设备
相关申请的交叉引用
本申请要求在2021年04月30日提交国家知识产权局、申请号为202110480045.3、申请名称为“一种休眠调度方法及设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信技术领域,尤其涉及一种休眠调度方法及设备。
背景技术
多设备互联的网络拓扑,由于设备的链路较多,相对于常见的单连接场景,该设备负载更大,功耗也更高。为了节约网络拓扑中的各个设备的功耗,提出了休眠调度方式。例如目前的基于省电模式(power save mode,PSM)协议的休眠调度方式;或者,基于目标唤醒时间(target wake time,TWT)协议的休眠调度方式;又或者,基于缺席通知(notice of absence,NOA)协议的休眠调度方式。
上述的三种休眠调度方式都可以认为是基于中心节点的调度方式,无法适用于多对多的网络拓扑。
发明内容
本申请提供一种休眠调度方法及设备,用于在不影响分布式系统中各个设备的正常业务交互的前提下,尽可能节省各个设备功耗。
第一方面,提供一种休眠调度方法,该方法可用于包括第一设备、第二设备和第三设备的分布式系统,分布式系统可以是一对多连接的系统,也可以多对多连接的系统。该方法可适用于分布式系统的任意设备,下面以该方法由第一设备执行为例。该方法包括:
第一设备根据第一场景信息确定有第一业务到来,并根据第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,以及将第二休眠唤醒信息更新至休眠唤醒调度表。其中,第一场景信息用于指示第一业务的业务特征。第一休眠唤醒信息用于指示第一设备当前在休眠调度周期内的各个时间片上的休眠唤醒情况。第二休眠唤醒信息用于指示第一设备进行包括第一业务在内的业务时,需要满足的休眠调度周期内的各个时间片上的休眠唤醒情况。所述休眠唤醒调度表包括分布式系统内的各个设备的休眠唤醒情况,用于第一设备与所述分布式系统中的其他设备进行数据的发送或接收各个设备。
在本申请实施例中,为了降低分布式系统中的各个设备的功耗,在时间维度上定义最小休眠唤醒时间(也称为时间片),并以N个时间片作为一个休眠调度周期。为分布式系统中的各个设备建立了统一的休眠唤醒调度表,该休眠唤醒调度表可指示分布式系统的所有设备在休眠调度周期内的各个时间片的最新休眠唤醒时间,所以各个设备根据该休眠唤醒调度表可选择其他合适的设备协同进行分布式业务。例如,第一设备和分布式系统的其他设备(例如第二设备)之间可能有业务(例如第一业务)要传输,第一设备可根据第一 业务的特征更新自身在休眠唤醒周期内的休眠唤醒情况,以保证第一业务的正常进行以及尽量节省功耗。进一步,第一设备可将更新后的休眠唤醒信息更新至休眠唤醒调度表。其他省类似第一设备,这样分布式系统中的各个设备可根据具体业务对各个设备独立地进行调度,以在不影响业务时延吞吐的前提下,使得各个设备尽可能多进入休眠,节约功耗。各个设备根据其他设备的休眠唤醒情况动态地更新自身的休眠唤醒情况,休眠唤醒情况可灵活变化,这样还便于满足突发业务的实际传输需求。另外,由于分布式系统中的各个设备更新休眠唤醒调度表无需依赖分布式系统中的某一固定设备,例如中心节点,所以本申请实施例提供的休眠调度方法可适用于多对多的连接场景。
在一种可能的实现方式中,所述方法还包括:
第一设备在休眠调度周期内的预设时间片内广播第一定期通知帧(periodical notify frame,PNF),并接收来自第二设备的第二PNF,根据第二PNF更新存储的休眠唤醒调度表。其中,第一PNF用于指示第二休眠唤醒信息,第二PNF用于指示第二设备的休眠唤醒信息。可以理解的是,各个设备可在休眠调度周期内的预设时间片广播自身当前的休眠唤醒信息,以便各个设备根据其他设备的休眠唤醒信息来维护休眠唤醒调度表。从而保证分布式系统的所有设备在休眠调度周期内的各个时间片的休眠唤醒时间是最新的,保证设备间进行业务时尽可能多进入休眠,节约功耗。
在一种可能的实现方式中,所述方法还包括:
第一设备确定进入如下的任意一种场景,第一设备更新相应链路的休眠唤醒信息,并将相应链路更新后的休眠唤醒信息通知给第二设备;其中,所述场景包括:保活场景、链路变化场景、紧急业务场景或业务变更场景,所述保活场景用于指示所述第一设备的链路保持连接状态,且所述第一设备与其他设备之间无业务数据交互。应理解,随着第一设备的业务进行,第一设备的应用场景可能发生变化,例如第一设备和第二设备之间有紧急业务,又例如,第一设备和第二设备之间的传输链路的流量变化较大。这种情况下表,第一设备可适应性调整相应链路的休眠唤醒信息,并通知给第二设备。这样第二设备可根据第一设备和第二设备之间传输链路最新的休眠唤醒信息来更新所保存的相应链路的休眠唤醒信息,不会影响其他设备的传输链路上的业务进行。
在一种可能的实现方式中,第一设备进入保活场景,所述方法还包括:
第一设备查询所缓存的数据量;在数据量大于或等于第一预设阈值的情况下,第一设备将第一设备和第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息。且第一设备向第二设备发送第一通知帧,并接收来自第二设备的第二通知帧。其中,第一通知帧携带第一链路休眠唤醒信息,以使得第二设备根据第一链路的休眠唤醒信息将存储的第一设备和第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;第二通知帧携带第二链路休眠唤醒信息。该方案考虑到一种可能的应用场景,例如第一设备由于干扰等因素,可能有业务数据没有及时发送出去。这种场景下,尽管第一设备和第二设备之间可能无业务传输,但是为了将第一设备缓存的数据尽量发送出去,第一设备还是可以更新自身的休眠唤醒信息。例如第一设备可将休眠唤醒周期内的前P个时隙置为唤醒状态,以尽量节约第一设备的缓存空间。为保证第一设备和对端设备针对发送所缓存的数据的传输链路的休眠唤醒信息一致,第一设备和告知第二设备第一链路休眠唤醒信息。同理,第二设备更新相应传输链路的休眠唤醒新,可告知第一设备第二链路休眠唤醒信息。
在一种可能的实现方式中,第一设备进入链路变化场景,所述方法还包括:
第一设备确定第一设备和第二设备之间的传输链路的流量大于或等于第二预设阈值,将第一设备和第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息。且第一设备向第二设备发送第一通知帧,并接收来自第二设备的第二通知帧。其中,第一通知帧携带第一链路休眠唤醒信息,以使得第二设备根据第一链路的休眠唤醒信息将存储的第一设备和第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;第二通知帧携带第二链路休眠唤醒信息。该方案考虑到另一种可能的应用场景,例如随着第一设备与第二设备之间链路的流量的变化,第一设备当前的休眠唤醒情况可能不是最佳的。这种情况下,第一设备可根据链路流量大小,适应性临时增加唤醒时间片,以较快地将数据缓存模块所存储的业务数据传输给对端设备,降低时延。
在一种可能的实现方式中,第一设备进入紧急业务场景,所述方法还包括:
第一设备将第一设备和第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息。且第一设备向第二设备发送第一通知帧,并接收来自第二设备的第二通知帧。其中,第一通知帧携带第一链路休眠唤醒信息,以使得第二设备根据第一链路的休眠唤醒信息将存储的第一设备和第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;第二通知帧携带第二链路休眠唤醒信息。该方案考虑到另一种可能的应用场景,即互联的多个设备间有突然业务产生。这种情况下,可灵活地调度分布式系统中的各个设备,例如第一设备和第二设备协商用于收发紧急业务的休眠唤醒时间片,使得突发业务的数据尽量较快地传输,且尽量不影响分布式系统整体的休眠。
在一种可能的实现方式中,第一设备根据第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,包括:第一设备基于第一预设规则、第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,其中,第一预设规则满足如下的一种或多种预设规则。
示例性的预设规则一,第一设备当前无业务,第一设备无法确定进行第一业务的休眠唤醒信息,第二休眠唤醒信息用于指示第一设备在休眠调度周期内的各个时间片均处于唤醒状态。可以理解的是,当第一设备当前无业务,有第一业务到来时,无法确定第一业务的休眠唤醒情况,这种情况下,为了保证后续第一业务的正常进行,可设置第一设备在整个休眠调度周期内处于唤醒状态。
示例性的预设规则二,第一设备当前有业务,第一休眠唤醒信息指示第一设备在休眠调度周期内的各个时间片处于唤醒状态,第二休眠唤醒信息用于指示第一设备在休眠调度周期内的各个时间片均处于唤醒状态。可以理解的,第一设备当前有业务,且当前业务要求第一设备在整个休眠调度周期内处于唤醒状态,那么为了保证当前业务的顺利进行,无论第一业务需要满足的休眠唤醒情况如何,需设备第一设备在整个休眠调度周期内处于唤醒状态。
示例性的预设规则三,第一设备当前有业务,第一休眠唤醒信息指示第一设备在休眠调度周期内的部分时间片处于唤醒状态,若第一设备无法确定进行第一业务的休眠唤醒信息,则第二休眠唤醒信息用于指示第一设备在休眠调度周期内的各个时间片均处于唤醒状态;若第一设备能够确定进行第一业务的休眠唤醒信息,第二休眠唤醒信息基于第一休眠唤醒信息以及第一设备进行第一业务的休眠唤醒信息生成。可以理解的,第一设备当前有业务,但是当前业务要求第一设备只需在整个休眠调度周期内的部分时间片处于唤醒状态即可。这种情况下,如果第一设备无法确定到来的第一业务的休眠唤醒情况,为了保证后续第一业务的正常进行,可设置第一设备在整个休眠调度周期内处于唤醒状态。而如果第 一设备可确定第一业务的休眠唤醒情况,那么可结合当前业务需要满足的休眠唤醒情况以及第一业务需要满足的休眠唤醒情况确定第一设备进行当前业务和第一业务需要满足的休眠唤醒情况,以尽量保证第一设备尽可能多的进入休眠,节省功耗。
在一种可能的实现方式中,第一场景信息包括如下信息的一种或多种:
第一业务的类型信息、第一业务的最低时延容忍值、第一业务对应的发包间隔,以及第一业务对应的场景档位,其中,场景档位用于指示第一业务在所述休眠调度周期内的各个时间片的休眠唤醒情况,不同的场景档位对应的休眠唤醒情况不同。
在本申请实施例对场景信息的具体形式不作限制。例如场景信息可以是第一业务的最低时延容忍值,第一设备根据第一业务的最低时延容忍值来确定需要满足的休眠唤醒信息,较为直接。又例如,场景信息也可以是业务的类型信息。这种情况下,第一设备可根据应用层基于业务流下发的相关信息确定第一业务的业务特征,进而根据业务特征来确定第一业务需要满足的最低时延容忍值,再确定需要满足的休眠唤醒情况。或者,场景信息可以是第一业务的发包间隔。由于应用层可能不会下发第一业务的相关信息,这种情况下,第一设备可自己监测第一业务的一些特征,例如第一业务的发包间隔,从而确定需要满足的休眠唤醒情况。或者,场景信息也可以是场景档位,直接表征第一业务需要满足的休眠调度情况,更为直接。
第二方面,提供一种电子设备,该电子设备包括显示屏、一个或多个处理模块、存储器、以及一个或多个程序。其中,所述一个或多个程序被存储在所述存储器中,所述一个或多个程序包括指令,当所述指令被所述电子设备执行时,使得所述电子设备执行上述第一方面或者任意一种可能的实施方式中由第一设备所提供的方法,或者,使得所述电子设备执行上述第一方面或者任意一种可能的实施方式中由第二设备所提供的方法。
例如,电子设备可执行:根据第一场景信息确定有第一业务到来,并根据第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,以及将第二休眠唤醒信息更新至休眠唤醒调度表。其中,第一场景信息用于指示第一业务的业务特征。第一休眠唤醒信息用于指示第一设备当前在休眠调度周期内的各个时间片上的休眠唤醒情况。第二休眠唤醒信息用于指示第一设备进行包括第一业务在内的业务时,需要满足的休眠调度周期内的各个时间片上的休眠唤醒情况。所述休眠唤醒调度表包括分布式系统内的各个设备的休眠唤醒情况,用于第一设备与所述分布式系统中的其他设备进行数据的发送或接收各个设备。
作为一种可选的实现方式,所述电子设备还包括收发模块,其中,收发模块用于:在休眠调度周期内的预设时间片内广播第一PNF,以及接收来自第二电子设备的第二PNF。第一PNF用于指示第二休眠唤醒信息,第二PNF用于指示第二电子设备的休眠唤醒信息。
作为一种可选的实现方式,所述处理模块还用于:
确定进入如下的任意一种场景,更新相应链路的休眠唤醒信息,并将相应链路更新后的休眠唤醒信息通知给所述第二设备;
其中,所述场景包括:保活场景、链路变化场景、紧急业务场景或业务变更场景,所述保活场景用于指示所述第一设备的链路保持连接状态,且所述第一设备与其他设备之间无业务数据交互。
作为一种可选的实现方式,电子设备进入保活场景,其中,所述处理模块还用于:查询所缓存的数据量,在所述数据量大于或等于第一预设阈值的情况下,将电子设备和第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
所述收发模块还用于:向第二设备发送第一通知帧,该第一通知帧携带第一链路休眠唤醒信息,以使得第二设备根据第一链路的休眠唤醒信息将存储的电子设备和第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;并接收来自第二设备的第二通知帧,该第二通知帧携带所述第二链路休眠唤醒信息。
作为一种可选的实现方式,电子设备进入所述链路变化场景,所述处理模块还用于:确定电子设备和第二设备之间的传输链路的流量大于或等于第二预设阈值,将电子设备和第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
所述收发模块还用于:向所述第二设备发送第一通知帧,所述第一通知帧携带所述第一链路休眠唤醒信息,以使得所述第二设备根据所述第一链路的休眠唤醒信息将存储的所述电子设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;并接收来自所述第二设备的第二通知帧,所述第二通知帧携带所述第二链路休眠唤醒信息。
作为一种可选的实现方式,电子设备进入紧急业务场景,所述处理模块还用于:将电子设备和第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
所述收发模块还用于:向所述第二设备发送第一通知帧,所述第一通知帧携带所述第一链路休眠唤醒信息,以使得所述第二设备根据所述第一链路的休眠唤醒信息将存储的所述电子设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;并接收来自所述第二设备的第二通知帧,所述第二通知帧携带所述第二链路休眠唤醒信息。
作为一种可选的实现方式,处理模块具体用于:基于第一预设规则、第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,其中,第一预设规则满足如下的一种或多种:
电子设备当前无业务,电子设备无法确定进行第一业务的休眠唤醒信息,第二休眠唤醒信息用于指示电子设备在所述休眠调度周期内的各个时间片均处于唤醒状态;或者,
电子设备当前有业务,第一休眠唤醒信息指示电子设备在休眠调度周期内的各个时间片处于唤醒状态,第二休眠唤醒信息用于指示电子设备在休眠调度周期内的各个时间片均处于唤醒状态;或者,
电子设备当前有业务,第一休眠唤醒信息指示电子设备在休眠调度周期内的部分时间片处于唤醒状态,若电子设备无法确定进行第一业务的休眠唤醒信息,则第二休眠唤醒信息用于指示电子设备在休眠调度周期内的各个时间片均处于唤醒状态;若电子设备能够确定进行第一业务的休眠唤醒信息,第二休眠唤醒信息基于第一休眠唤醒信息以及电子设备进行第一业务的休眠唤醒信息生成。
作为一种可选的实现方式,第一场景信息包括如下信息的一种或多种:
第一业务的类型信息、第一业务的最低时延容忍值、第一业务对应的发包间隔,以及第一业务对应的场景档位。其中,场景档位用于指示第一业务在休眠调度周期内的各个时间片的休眠唤醒情况,不同的场景档位对应的休眠唤醒情况不同。
关于第二方面或各种可选的实施方式所带来的技术效果,可参考对于第一方面或相应的实施方式所带来的技术效果的介绍。
第三方面,提供一种电子设备,所述电子设备包括用于执行第一方面或者任意一种可能的实施方式中由第一设备所执行的方法的模块/单元。
第四方面,提供一种系统,该系统包括第一设备、第二设备和第三设备,可选的,该 系统还可以包括其他设备,该系统所包括的设备能够实现分布式业务,例如多屏协同。各个设备可通过第二方面的电子设备或第三方面的电子设备实现。
第五方面,提供一种芯片,该芯片包括处理器和接口,所述接口用于与所述处理器通信以及接收来自其他设备的信息;所述处理器用于执行上述第一方面以及第一方面的任一可能实现方式中所述的方法。
第六方面,提供一种计算机可读存储介质,所述计算机可读存储介质用于存储计算机程序,当所述计算机程序在计算机上运行时,使得所述计算机执行如下的一种或多种方法:上述第一方面或任意一种可能的实施方式中由第一设备所执行的方法。
第七方面,提供一种包含指令的计算机程序产品,所述计算机程序产品用于存储计算机程序,当所述计算机程序在计算机上运行时,使得所述计算机执行如下的一种或多种方法:上述第一方面或的任意一种可能的实施方式中由第一设备所执行的方法。
通过本申请实施例提供的技术方案,为分布式系统中的各个设备建立了统一的休眠唤醒调度表。各个设备基于该休眠唤醒调度表实现与其他设备间的业务收发时,在不影响分布式系统中各个设备的正常业务交互的前提下,尽可能节省各个设备功耗。另外,由于分布式系统中的各个设备更新休眠唤醒调度表无需依赖分布式系统中的某一固定设备,例如中心节点,所以本申请实施例提供的休眠调度方法可适用于多对多的连接场景。
附图说明
图1为PSM的工作示意图;
图2为TWT的工作示意图;
图3为NOA的工作示意图;
图4为本申请实施例提供的第一种分布式系统的架构示意图;
图5为本申请实施例提供的第二种分布式系统的架构示意图;
图6为本申请实施例提供的休眠唤醒周期的示意图;
图7A为本申请实施例提供的电子设备的硬件结构示意图;
图7B为本申请实施例提供的电子设备的软件结构示意图;
图8为实现本申请实施例提供的休眠调度方法的各个功能模块调度关系的示意图;
图9为本申请实施例提供的承载RP值的第一部分的一种帧结构示意图;
图10为本申请实施例提供的分布式系统的休眠调度方法的一流程示意图;
图11为本申请实施例提供的PNF的一种结构示意图;
图12为本申请实施例提供的一示例性的休眠调度方法的流程示意图;
图13为本申请实施例提供的紧急业务的处理流程示意图;
图14为本申请实施例提供的动态协商帧的结构示意图;
图15为本申请实施例提供的电子设备的另一结构示意图。
具体实施方式
为了使本申请的目的、技术方案和优点更加清楚,下面将结合附图对本申请作进一步地详细描述。
随着物联网技术的发展,越来越多的业务或应用希望可以通过多个设备协同工作实现。 例如,为了提高用户的体验,提供了多屏协同功能(或者,称为多设备协同功能),从而可支持多设备协同工作的应用与业务,例如多屏协同、信息共享等。举例来说,在多屏协同功能下,设备1可以向设备2进行投屏,从而设备1上的文件可以在设备2上打开。例如手机和个人计算机(personal computer,PC)进行多屏协同,则在PC的显示屏上会显示手机的镜像,在PC上显示的手机的镜像也可理解为投屏界面。用户在PC上的投屏界面上操作,例如用户选择打开文件A,则PC可以打开文件A,但实际上文件A是手机中的文件。PC相对于手机来说显示屏的面积更大,用户在PC上观看该文件,可以提升用户的观看效果。
为了便于描述,在本申请实施例中,将依赖多设备协同工作的应用或业务统称为分布式业务。应理解,支撑分布式业务需要将手机、平板、PC、显示屏等多个终端设备连接在一起,实现多个设备间的一对一连接或一对多连接,甚至多对多连接,即多设备互联,从而使分布式业务在多个终端设备中协同运行。
应理解,多设备互联的网络拓扑,由于设备的链路较多,相对于常见的单连接场景,该设备负载更大,功耗也更高。所以一些实施例中,提供了多种休眠调度方式,以节约网络拓扑中的各个设备的功耗,例如以下休眠调度方式。
休眠调度方式一、基于省电模式(power save mode,PSM)协议的休眠调度方式。该休眠调度方式适用于一对多的网络拓扑架构。以网络拓扑中,一对多是接入点(又称为访问节点)(access point,AP)-工作站(又称为站点)(station,STA)之间一对多为例。AP可认为是主节点,STA可认为是从节点。AP作为中心节点来维护多个STA设备的连接,所以基于PSM协议的休眠调度方法也可认为是中心式的休眠策略。其主要思想是:AP缓存STA的数据,当任意STA休眠结束后主动向AP请求获取数据,AP才会向STA发送数据。在AP没有缓存某个STA的数据时,该STA可继续休眠,从而达到节约功耗的目的。
为便于理解,请参见图1,为PSM工作示意图。服务器可将一个或多个STA的数据发送给AP,AP缓存一个或多个设备的数据。AP在信标(beacon)帧中周期性广播该AP的缓存区情况。任意STA可按照监听间隔(listen interval)周期性地在固定的beacon帧的起始时刻唤醒,来监听AP广播的beacon帧。如果STA监听到beacon帧,从该beacon帧中确定AP存储有该STA的数据,那么该STA向AP请求获取数据;相反,如果STA从该beacon帧中确定AP没有存储该STA的数据,那么该STA继续休眠。
休眠调度方式二、基于目标唤醒时间(target wake time,TWT)协议的休眠调度方式。TWT机制可适用于大规模物联网环境下的节能场景。休眠调度方式二与休眠调度方式一类似,也是中心式的休眠策略,即需要中心节点来调度。例如,STA和AP协商建立了一张时间表,该时间表可由TWT时间周期组成。AP基于该时间表对网络拓扑中的各个STA进行休眠调度。
为便于理解,请参见图2,为TWT工作示意图。通常,STA和AP所协商的TWT时间周期包含一个或多个beacon周期。当STA和AP所协商的时间周期到达后,STA会唤醒,并等待AP发送的触发帧,进行一次数据交换。当STA完成本次数据交换,STA进入睡眠状态。其中,每个STA独立和AP协商TWT时间周期,每个STA都具有单独的TWT时间周期,如图STA1和STA2的TWT时间周期分别为TW1和TW2,即STA1和STA2的唤醒时间不同。AP也可以根据设定的TWT时间周期对多个STA进行分组,这样AP可同时对多个STA进行调度,从而提高调度效率。
休眠调度方式三、基于缺席通知(notice of absence,NOA)协议的休眠调度方式。NOA协议可应用于点对点(Peer-to-Peer,P2P)协议建立的网络拓扑。NOA协议的大致思想是,中心节点确定进入休眠以及退出休眠的时间,从节点按照中心节点的决定,与中心节点同时睡眠同时唤醒。例如,中心节点将NOA信息发送给从节点,以使得从节点根据接收的NOA信息与中心节点同时睡眠同时唤醒。
为便于理解,请参见图3,为NOA工作示意图。中心节点配置进入休眠以及退出休眠的时间,生成NOA信息。中心节点通过beacon帧等将NOA信息发送给一个或多个从节点。任意从节点接收到NOA信息,根据NOA信息进行休眠或退出休眠。例如,中心节点是AP,从节点是STA。AP发送携带NOA信息的beacon帧,STA1和STA2在信标预定传输时间(target beacon transmission time,TBTT)接收到该beacon帧,根据该beacon帧携带的NOA信息可设置休眠时间同AP的休眠时间一致。这里TBTT可以认为是AP连续发送两个beacon)的时间间隔。
上述的三种休眠调度方式均可认为是基于中心节点的调度方式。例如休眠调度方式一中,由AP作为中心节点来维护多个STA设备的连接。又例如休眠调度方式二中,每个STA独立与AP协商TWT时间周期,AP维护多个STA设备的连接。又例如休眠调度方式三中,可将AP看作是中心节点,多个STA基于AP的NOA信息,与AP同时睡眠同时唤醒。但是随着业务的种类,或需求的增加,越来越多业务可能希望网络内的任意设备间协同实现,显然一对一或一对多的网络拓扑无法满足此类业务的运行。为了支持这类业务,会提出多对多的网络拓扑,即网络拓扑中不存在固定的中心节点,任意设备间都可以协同工作实现这类业务。
然而上述的三种休眠调度方式都可以认为是基于中心节点的调度方式,显然无法适用于多对多的网络拓扑。且休眠调度方式一中,各个STA每次都需要向AP发送请求来触发AP向STA发送所缓存的数据,对于STA来说,信令开销较大,获取数据的效率较低。休眠调度方式三中,NOA信息的设置比较单一固定,一旦设置了NOA信息,一般就会固定,除非是重新设置NOA信息或者取消所设置的NOA信息。然而网络拓扑中可能有突发业务,显然休眠调度方式三无法满足突发业务的场景。
鉴于此,本申请实施例提供了分布式系统的一种休眠调度方法,在不影响正常业务交互的前提下,尽可能节省各个设备功耗。
本申请实施例提供的休眠调度方法可以应用于多种分布式系统,例如以下分布式系统:
分布式系统一、一对一连接,或一对多连接的系统。例如,基于无线保真(wireless fidelity,WiFi)联盟(WI-FI alliance,WFA)开发定义了无线保真点对点(wireless fidelity Peer-to-Peer,WiFi P2P)协议建立的分布式系统。WiFi P2P协议是一种点对点的连接技术,使得多个WiFi设备在没有接入点(又称为访问节点)(access point,AP)的情况下也能构成一个网络(Network)。该网络也可称为P2P Network,或者P2P组(Group),该网络内的多个WiFi设备能够相互通信。WiFi P2P协议的大致原理是:可在两台工作站(又称为站点)(Station,STA)之间直接建立传输控制协议(transmission control protocol,TCP)/网际协议(internet protocol,IP)链接。这两台STA中的一台STA可认为是传统意义上的AP,称为群组拥有者(group owner,GO),相对而言,这两台STA中的另外一台STA可称为群组用户(group client,GC)。也就是GC类似STA,GO类似AP,那么类似STA连接到AP,GC也可连接到GO。应理解,在P2P Network或P2P Group中的一个GO可对应一个GC,也可以对 应多个GC,即GO和GC之间可以是一对一的关系,也可以是一对多的关系。
例如,请参见图4,示出了分布式系统一的一种网络架构。图4包括3个终端设备,这3个终端设备分别是位于一个网络内的终端设备401、终端设备402和终端设备403。图4以终端设备401和终端设备402是手机,终端设备403是PAD为例。在图4中,终端设备401、终端设备402和终端设备403初始建链之后,终端设备403是GO,终端设备401和终端设备402均为GC。终端设备403可以与终端设备401进行协同业务,也可以与终端设备402进行协同业务。例如,如图1所示,终端设备403和终端设备402可进行投屏业务。如果需要协同的业务存在于互联的多个设置中的任意两个GC,由于GC与GC之间不能互相通信,显然无法进行协同业务。例如,如图4所示,需要在终端设备401和终端设备402之间实现信息共享,但是由于终端设备401和终端设备402均为GC,那么受终端设备402和终端设备401充当的角色限制,需要断开终端设备402和终端设备103之间的连接。对终端设备401和终端设备402重新建链,以使得终端设备401为GO,从而实现与终端设备402之间的信息共享,否则无法实现终端设备402和终端设备401之间的信息共享。当终端设备401和终端设备402重新建链之后,终端设备401和终端设备402中一个终端设备充当GO,另一个终端设备充当GC。例如,图4以终端设备401充当GO,终端设备402充当GC为例。也就是说一个设备的角色随着建链的变化,角色是可以变化的,例如终端设备401在初始建链之后,终端设备401的角色为GC,再之后重新建链之后,终端设备401的角色是GO。
应理解,WiFi P2P协议基于802.11协议框架开发,属于一种中心式的网络通信结构。也就是,WiFi P2P要求每个终端设备都必须配置一个角色,例如可以是GO或GC。GO作为中心节点,能够与该GO连接的任意GC节点进行通信,但是GO和GO之间、GC与GC之间不能相互通信。例如,终端设备402与终端设备401以及终端设备403多屏协同看视频,如果终端设备402使用信息共享功能,那么受终端设备403和终端设备401充当的角色限制,需要断开终端设备402和终端设备403之间的连接才能实现终端设备402和终端设备401之间的信息共享,否则无法实现终端设备402和终端设备401之间的信息共享。
分布式系统二、一对一连接,或一对多连接,或多对多连接的系统。例如,设备间基于蓝牙或WiFi互相发现,并与发现的设备建立连接;再通过建立的通信通道协商彼此建立WiFi直连通信的链路信息,基于该链路信息实现设备间的WiFi直连通信,从而组成分布式系统。由于设备间发现之后建立通信连接,再通过设备间建立的通信通道协商设备间建立WiFi直连通信的链路信息,所以无需为各个设备分配具体的角色。设备间可以是一对一的关系,也可以是一对多的关系,还可以是多对多的关系,所建立的分布式系统中各个设备的角色对等。这样分布式业务可在任意设备间协同,不会因角色问题而使得分布式业务受限。例如,分布式系统的第一设备可投屏到第二设备,同时第一设备和第三设备之间可共享文件,即不受角色冲突。
例如,请参见图5,为分布式系统的一种示意图。图5以分布式系统包括5个设备为例,应理解,这5个设备处于同一个网络内。这5个设备分别为设备501、设备502、设备503、设备504和设备505。设备501、设备502、设备503、设备504和设备505之间可进行多屏协同或信息共享等。例如,设备501可与设备502或设备503进行多屏协同或信息共享,设备502与设备504可进行多屏协同,设备503与设备505可进行信息共享。 图5以设备501是手机、设备502是便携计算机、设备503是平板电脑、设备504是个人电脑和设备505是智能音箱为例。
以设备501为例,设备501可通过蓝牙通信信道广播发现消息,该发现消息用于发现一个或多个设备,例如设备502-设备505。设备502-设备505中的任意设备,例如设备503接收到该发现消息,可向设备501发送针对该发现消息的响应消息。设备501接收到该响应消息,可根据该响应消息与设备503建立蓝牙连接。依次类推,其他设备也可以与设备501建立蓝牙连接。设备501与各个设备建立蓝牙连接之后,可协商建立WiFi直连通信的链路信息,并基于该链路信息彼此建立WiFi直连通信,从而组成分布式系统二。
本申请实施例提供的休眠调度方法可以应用于多种场景,例如以下场景:
场景一,也称为保活场景,即互联的多个设备间没有业务数据的交互。例如,多个设备建立了连接,形成分布式系统。但是当前该分布式系统中的设备都没有需要进行的业务,自然无需设备间的数据交互。这种情况下,分布式系统中的任意设备都可以处于休眠状态,以尽量节约功耗。应理解,即使设备处于休眠状态,但是设备间的链路保持连接状态,以使得设备间可以保持一些数据(也就是保活的数据)的交互,例如小流量时延不敏感数据的交互,不会影响设备间正常工作。
场景二,也称为业务场景,即互联的多个设备间有业务数据的交互。例如手机为投屏发起设备,PC1、PC2和PC3为投屏服务设备,手机向PC1、PC2和PC3投屏或者分享文档。这种情况下,可根据分布式系统中的各个设备的具体业务的形态,例如正在进行,或不进行等对各个设备独立地进行调度,以在不影响业务时延吞吐的前提下,使得各个设备尽可能多进入休眠,节约功耗。
场景三,也称为业务突发场景,即互联的多个设备间有突然业务产生。这种情况下,可灵活地调度分布式系统中的各个设备,使得突发业务的数据尽量较快地传输,且尽量不影响分布式系统整体的休眠。
如上介绍了本申请实施例的几种应用场景,当然除了如上场景之外,本申请实施例还可以应用于其他场景,具体的不做限制。在各种应用场景中,为了在不影响正常业务交互的前提下,尽可能节省各个设备功耗。本申请实施例可在时间维度上定义最小休眠唤醒时间(单位),例如以16ms的一个时隙为最小休眠唤醒时间,并以N个最小休眠唤醒时间作为休眠唤醒周期,其中,N为大于2的整数。
请参见图6,为休眠唤醒周期的示意图。休眠唤醒周期包括的时隙可分为宣告时隙和业务时隙。宣告时隙例如为休眠唤醒周期的前M个时隙,用于分布式系统内的各个设备通知本设备在休眠唤醒周期内的休眠唤醒情况。宣告时隙之后的时隙为业务时隙,主要用于进行数据的收发。
在本申请实施例中,以分布式系统的任意设备,例如第一设备为例,第一设备可在宣告时隙发送定期通知帧(periodical notify frame,PNF),该PNF用于指示第一设备在整个休眠唤醒周期的休眠唤醒情况。分布式系统的各个设备接收到来自其他设备的PNF,可结合自身的休眠唤醒情况,确定并更新自身的休眠唤醒时间。示例性的,本申请实施例可建立休眠唤醒调度表,该休眠唤醒调度表可用于指示分布式系统中各个设备的休眠唤醒时间。例如,该休眠唤醒调度表为K*N大小的比特位图(bitmap),其中,K为分布式系统包括的设备的数量,N为休眠唤醒周期的时隙个数。该休眠唤醒调度表由于包括分布式系统中各个设备的休眠唤醒信息,所以各个设备基于该休眠唤醒调度表可选择其他合适的设备协 同进行分布式业务。由于分布式系统中的各个设备更新休眠唤醒调度表无需依赖分布式系统中的某一固定设备,例如中心节点,所以本申请实施例提供的休眠调度方法可适用于多对多的连接场景。另外,任意设备根据休眠唤醒调度表主动进行分布式业务,即数据的传输,无需事先发送请求以触发对方发送数据,相较于上述的休眠调度方式一来说,可减少设备间的信令开销,提高数据传输的效率。各个设备根据其他设备的休眠唤醒情况动态地更新自身的休眠唤醒情况,休眠唤醒情况可灵活变化,相较于上述的休眠调度方式三来说,能够满足突发业务的实际传输需求。
本申请实施例提供的技术方案可以应用在电子设备中,例如组成分布式系统一或分布式系统二的任意设备。以下介绍电子设备和用于使用这样的电子设备的实施例。在本申请一些实施例中,电子设备可以是便携式电子设备,诸如手机、PAD、便携计算机、具备无线通讯功能的可穿戴设备(如智能手表、智能眼镜、智能手环、或智能头盔等)、或车载设备等。便携式电子设备的示例性实施例包括但不限于搭载
Figure PCTCN2022085845-appb-000001
或者其它操作系统的便携式电子设备。还应当理解的是,在本申请其他一些实施例中,上述电子设备也可以不是便携式设备,例如也可以是台式计算机,例如PC,或者也可以是电视机等设备。
示例性地,图7A给出了一种电子设备700的结构示意图。
应理解,图示电子设备700仅是一个范例,并且电子设备700可以具有比图中所示出的更多的或者更少的部件,可以组合两个或更多的部件,或者可以具有不同的部件配置。图中所示出的各种部件可以在包括一个或多个信号处理和/或专用集成电路在内的硬件、软件、或硬件和软件的组合中实现。
如图7A所示,电子设备700可以包括处理器710,外部存储器接口720,内部存储器721,通用串行总线(universal serial bus,USB)接口730,充电管理模块740,电源管理模块741,电池742,天线1,天线2,移动通信模块750,无线通信模块760,音频模块770,扬声器770A,受话器770B,麦克风770C,耳机接口770D,传感器模块780,按键790,马达791,指示器792,摄像头793,显示屏794,以及用户标识模块(subscriber identification module,SIM)卡接口795等。其中传感器模块780可以包括压力传感器780A,陀螺仪传感器780B,气压传感器780C,磁传感器780D,加速度传感器780E,距离传感器780F,接近光传感器780G,指纹传感器780H,温度传感器780J,触摸传感器780K,环境光传感器780L,骨传导传感器780M等。
下面结合图7A对电子设备700的各个部件进行具体的介绍。
处理器710可以包括一个或多个处理单元,例如,处理器710可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processing unit,GPU),图像信号处理器(image signal processor,ISP),控制器,存储器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。其中,控制器可以是电子设备700的神经中枢和指挥中心。控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。
处理器710中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器710中的存储器为高速缓冲存储器。该存储器可以保存处理器710刚用过或循环使用的指令或数据。如果处理器710需要再次使用该指令或数据,可从存储器中直接调用,从而可避免 重复存取,可减少处理器710的等待时间,因而可提高系统的效率。
处理器710可以运行本申请实施例提供的信息分享的方法。例如本申请实施例提供协同快捷操作服务(Fast Collaborative Service),协同快捷操作服务可以是软件模块,该软件模块可以运行在处理器710上,该软件模块可以理解为计算机程序。例如该软件模块可以提供系统级的能力,以安卓系统为例,从业务角度考虑,该软件模块可以放在系统服务(system_server)进程中,与system_server进程中的活动管理器服务(activity manager service,AMS)、包管理器服务(package manager service,PMS)、或窗口管理器服务(window manager service)等模块共同构筑平台基础能力。或者,从实现角度考虑,除了system_server进程外,协同快捷操作服务也可以放在其他进程中。当处理器710集成不同的器件,比如集成CPU和GPU时,CPU和GPU可以配合执行本申请实施例提供的方法,例如本申请实施例提供的方法中部分算法由CPU执行,另一部分算法由GPU执行,以得到较快的处理效率。
在一些实施例中,处理器710可以包括一个或多个接口。比如,接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integrated circuit sound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purpose input/output,GPIO)接口,用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。
USB接口730是符合USB标准规范的接口,具体可以是Mini USB接口,Micro USB接口,USB Type C接口等。USB接口730可以用于连接充电器为电子设备700充电,也可以用于电子设备700与外围设备之间传输数据。充电管理模块740用于从充电器接收充电输入。电源管理模块741用于连接电池742,充电管理模块740与处理器710。电源管理模块741接收电池742和/或充电管理模块740的输入,为处理器710,内部存储器721,外部存储器,显示屏794,摄像头793,和无线通信模块770等供电。
I2C接口是一种双向同步串行总线,包括一根串行数据线(serial data line,SDA)和一根串行时钟线(derail clock line,SCL)。在一些实施例中,处理器710可以包含多组I2C总线。处理器710可以通过不同的I2C总线接口分别耦合触摸传感器780K,充电器,闪光灯,摄像头793等。例如:处理器710可以通过I2C接口耦合触摸传感器780K,使处理器710与触摸传感器780K通过I2C总线接口通信,实现电子设备700的触摸功能。
移动产业处理器接口(mobile industry processor interface,MIPI)接口可以被用于连接处理器710与显示屏794,摄像头793等外围器件。MIPI接口包括摄像头串行接口(camera serial interface,CSI),显示屏串行接口(display serial interface,DSI)等。在一些实施例中,处理器710和摄像头793通过CSI接口通信,实现电子设备700的拍摄功能。处理器710和显示屏794通过DSI接口通信,实现电子设备700的显示功能。
GPIO接口可以通过软件配置。GPIO接口可以被配置为控制信号,也可被配置为数据信号。在一些实施例中,GPIO接口可以用于连接处理器710与摄像头793,显示屏794,无线通信模块760,音频模块770,传感器模块780等。GPIO接口还可以被配置为I2C接口,I2S接口,UART接口,MIPI接口等。
电子设备700的无线通信功能可以通过天线1,天线2,移动通信模块750,无线通信模块760,调制解调处理器以及基带处理器等实现。天线1和天线2用于发射和接收电磁 波信号。电子设备700中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。例如:可以将天线1复用为无线局域网的分集天线。在另外一些实施例中,天线可以和调谐开关结合使用。
移动通信模块750可以提供应用在电子设备700上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块750可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(low noise amplifier,LNA)等。移动通信模块750可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块750还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块750的至少部分功能模块可以被设置于处理器710中。在一些实施例中,移动通信模块750的至少部分功能模块可以与处理器710的至少部分模块被设置在同一个器件中。
无线通信模块760可以提供应用在电子设备700上的包括无线局域网(wireless local area networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequency modulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块760可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块760经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器710。无线通信模块760还可以从处理器710接收待发送的信号,对其进行调频,放大,经天线2转为电磁波辐射出去。
在一些实施例中,电子设备700的天线1和移动通信模块750耦合,天线2和无线通信模块760耦合,使得电子设备700可以通过无线通信技术与网络以及其他设备通信。所述无线通信技术可以包括全球移动通讯系统(global system for mobile communications,GSM),通用分组无线服务(general packet radio service,GPRS),码分多址接入(code division multiple access,CDMA),宽带码分多址(wideband code division multiple access,WCDMA),时分码分多址(time-division code division multiple access,TD-SCDMA),长期演进(long term evolution,LTE),BT,GNSS,WLAN,NFC,FM,和/或IR技术等。所述GNSS可以包括全球卫星定位系统(global positioning system,GPS),全球导航卫星系统(global navigation satellite system,GLONASS),北斗卫星导航系统(beidou navigation satellite system,BDS),准天顶卫星系统(quasi-zenith satellite system,QZSS)和/或星基增强系统(satellite based augmentation systems,SBAS)。
可以理解的是,本申请实施例示意的各模块间的接口连接关系,只是示意性说明,并不构成对电子设备700的结构限定。在本申请另一些实施例中,电子设备700也可以采用上述实施例中不同的接口连接方式,或多种接口连接方式的组合。
电子设备700通过GPU,显示屏794,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏794和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器710可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。
显示屏794用于显示图像,视频等。显示屏794包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emitting diode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrix organic light emitting diode的,AMOLED),柔性发光二极管(flex light-emitting diode,FLED),Miniled,MicroLed, Micro-oLed,量子点发光二极管(quantum dot light emitting diodes,QLED)等。
电子设备700可以通过ISP,摄像头793,视频编解码器,GPU,显示屏794以及应用处理器等实现拍摄功能,或者说实现采集图像的功能。
ISP用于处理摄像头793反馈的数据。例如,拍照时,打开快门,光线通过镜头被传递到摄像头感光元件上,光信号转换为电信号,摄像头感光元件将所述电信号传递给ISP处理,转化为肉眼可见的图像。ISP还可以对图像的噪点,亮度,肤色进行算法优化。ISP还可以对拍摄场景的曝光,色温等参数优化。在一些实施例中,ISP可以设置在摄像头793中。
摄像头793用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,电子设备700可以包括1个或N个摄像头793,N为大于1的正整数。
数字信号处理器用于处理数字信号,除了可以处理数字图像信号,还可以处理其他数字信号。例如,当电子设备700在频点选择时,数字信号处理器用于对频点能量进行傅里叶变换等。
视频编解码器用于对数字视频压缩或解压缩。电子设备700可以支持一种或多种视频编解码器。这样,电子设备700可以播放或录制多种编码格式的视频,例如:动态图像专家组(moving picture experts group,MPEG)1,MPEG2,MPEG3,MPEG4等。
NPU为神经网络(neural-network,NN)计算处理器,通过借鉴生物神经网络结构,例如借鉴人脑神经元之间传递模式,对输入信息快速处理,还可以不断的自学习。通过NPU可以实现电子设备700的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。
内部存储器721可以用于存储计算机可执行程序代码,可执行程序代码包括指令。内部存储器721可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储电子设备700使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器721可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。处理器710通过运行存储在内部存储器721的指令,和/或存储在设置于处理器中的存储器的指令,执行电子设备700的各种功能应用以及数据处理。
外部存储器接口720可以用于连接外部存储卡,例如Micro SD卡,实现扩展电子设备的存储能力。外部存储卡通过外部存储器接口720与处理器710通信,实现数据存储功能。例如将图片,视频等文件保存在外部存储卡中。
电子设备700可以通过音频模块770,扬声器770A,受话器770B,麦克风770C,耳机接口770D,以及应用处理器等实现音频功能。例如音乐播放,录音等。
按键790包括开机键,音量键等。按键790可以是机械按键。也可以是触摸式按键。电子设备700可以接收按键输入,产生与电子设备700的用户设置以及功能控制有关的键信号输入。马达791可以产生振动提示。马达791可以用于来电振动提示,也可以用于触 摸振动反馈。例如,作用于不同应用(例如拍照,音频播放等)的触摸操作,可以对应不同的振动反馈效果。触摸振动反馈效果还可以支持自定义。指示器792可以是指示灯,可以用于指示充电状态,电量变化,也可以用于指示消息,未接来电,通知等。SIM卡接口795用于连接SIM卡。SIM卡可以通过插入SIM卡接口795,或从SIM卡接口795拔出,实现与电子设备700的接触和分离。
可以理解的是,图7A所示的部件并不构成对电子设备700的具体限定,手机还可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。此外,图7A中的部件之间的组合/连接关系也是可以调整修改的。
电子设备700的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。本发明实施例以分层架构的Android系统为例,示例性说明电子设备700的软件结构。
图7B是本申请实施例的电子设备700的软件结构框图。
分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将Android系统分为四层,从上至下分别为应用程序层、应用程序框架层、系统库和内核层。
应用程序层可以包括一系列应用程序包。如图7B所示,应用程序包可以包括相机,图库,日历,通话,地图,导航,WLAN,蓝牙,音乐,视频,短信息等应用程序。
应用程序框架层为应用程序层的应用程序提供应用编程接口(application programming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。如图7B所示,应用程序框架层可以包括窗口管理器,内容提供器,视图系统,电话管理器,资源管理器,通知管理器等。窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。
内容提供器用来存放和获取数据,并使这些数据可以被应用访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。
视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。
电话管理器用于提供电子设备700的通信功能。例如通话状态的管理(包括接通,挂断等)。
资源管理器为应用提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。
通知管理器使应用可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话窗口形式出现在屏幕上的通知。例如在状态栏提示文本信息,发出提示音,电子设备振动,指示灯闪烁等。
系统库包括核心库和虚拟机,负责操作系统的调度和管理。系统库包含两部分:一部分是java语言需要调用的功能函数,另一部分是操作系统的核心库。应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进 制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。
系统库可以包括多个功能模块。例如:表面管理器(surface manager),媒体库(Media Libraries),三维图形处理库(例如:OpenGL ES),2D图形引擎(例如:SGL)等。其中,表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如:MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。三维图形处理库用于实现三维图形绘图,图像渲染,合成,和图层处理等。2D图形引擎是2D绘图的绘图引擎。
内核层是硬件和软件之间的层,为应用程序框架层提供应用编程接口(application programming interface,API)和编程框架。如图7B所示,内核层至少包含硬件抽象层(hardware abstraction layer,HAL)、驱动层和固件层。固件层位于驱动层和硬件之间。本申请实施例提供的休眠调度服务可位于内核层。例如休眠调度服务所涉及的各个算法可通过封装接口的形式,以对应的功能模块的形式存在于内核层。
硬件抽象层是位于操作系统内核与硬件电路之间的接口层,用于实现对休眠场景的识别、本设备的休眠唤醒调度表的调度,和/或设备的功率控制。
如图7B所示,硬件抽象层包括场景识别模块和基本调度模块。场景识别模块是与应用程序框架层的接口,可提供解析应用程序层的命令的能力。应用程序层的应用通过命令对场景进行设置,场景识别模块通过解析该命令可确定当前的应用场景。场景识别模块可将确定的场景通知给基本调度模块。基本调度模块可接收来自场景识别模块的用于指示场景的信息,并根据该场景生成分布式系统中各个链路的基本休眠唤醒情况,并将生成的各个链路的基本休眠唤醒情况告知低功耗状态机模块。
在一些实施例中,硬件抽象层还可以包括动态调度模块,用于在紧急业务到来时通过与低功耗状态机模块协作,确定该紧急业务是否可以在本休眠唤醒周期发送,并在进行动态协商获得的休眠唤醒时间传递给低功耗状态机模块。需要说明的是,动态调度模块不是不必可少的,所以在图7B中以虚线进行示意。
驱动层,也称为(host media access control,HAMC)层,用于协议栈的实现,例如实现PNF中休眠唤醒调度表中元素的生成与解析,各个设备的休眠唤醒状态的维护,休眠动态协商帧的生成与解析,休眠动态协商的交互流程与状态机,以及功率控制交互的协议等。
如图7B所示,驱动层可包括帧处理模块、低功耗状态机模块、虚拟接入点(virtual access point,VAP)管理模块、设备建链模块、设备同步模块、主设备选举模块。
帧处理模块主要用于相关帧的解析和生成,例如PNF、动态协商帧及休眠唤醒调度表的通知帧的处理。低功耗状态机模块为低功耗状态机,主要用于生成设备的休眠唤醒信息,并维护休眠唤醒调度表,例如,低功耗状态机模块可用于休眠唤醒调度表的生成,重置,更新。低功耗状态机模块还可以用于与其他模块进行交互。例如,低功耗状态机模块可将设备的休眠唤醒信息,动态协商信息以及生成各种帧所需的信息通知给其他模块。
VAP管理模块可用于VAP的创建和删除。应理解,VAP就是在一个物理实体AP上虚拟出多个AP,每一个被虚拟出的AP就是一个VAP,每个VAP提供和物理实体AP一样的功能。用户可以在一个AP上创建不同的VAP来为不同的用户群体提供无线接入服务。
设备建链模块可用于设备间的建链,拆链等相关工作。
设备同步模块可用于设备在系统中的同步。
主设备选举模块可用于从分布式系统中的多个设备中选举主设备,以及对主设备的更新。
固件层,也称为(device media access contrl,DMAC)层,主要用于直接控制硬件寄存器,例如,可实现基于休眠唤醒调度表生成定时器唤醒与休眠中断偏移,基于TSF偏移的硬件定时器中断唤醒,基于TSF偏移的硬件定时器中断休眠,处于休眠状态下的数据缓存,实现深睡、浅睡休眠状态的电源门控(power gating)寄存器配置,以及外置功率放大器(power amplifier,PA)、内置可变增益放大器(varialbe gain amplifier,VGA)功率档位配置;
如图7B所示,固件层可包括数据缓存模块、低功耗定时器模块、功率控制调度模块、休眠唤醒状态机模块以及解调模块等。
数据缓存模块用于管理缓存数据,例如,在休眠(保活)状态下,数据缓存模块可缓存设备在休眠时间内到来的数据,或者缓存到来的且未能及时发送的紧急业务数据。当数据缓存模块中缓存的数据大于一定门限时,数据缓存模块可通知低功耗状态机模块增加设备的唤醒时间。
低功耗定时器模块主要用于处理各种中断事件和分发,休眠相关的定时器,以用来管理各个最小休眠唤醒时间的起始和休眠调度周期的起始。
功率控制调度模块主要用于功率控制调度,例如,可通过设备间的距离信息及接收端误码反馈来进行功率档位的调整。例如,功率控制调度模块确定指示收发两端距离信息的参考信号接收功率(reference signal receiving power,RSRP)的信号强度,根据不同信号强度,转换为不同的距离等级,从而得到不同的发功档位等级。又例如,功率控制调度模块根据收端反馈的误码信息进行功率动态调整。当在某个功率等级下,收端反馈的误码较高,那么进行功率动态调整。当收端反馈的误码高于一定阈值,则触发功率升档。
休眠唤醒状态机模块可根据休眠唤醒调度表来控制各设备的睡醒情况。
需要说明的是,如上的功能模块只是一种示例,在实际应用中,休眠调度服务也可以按照其他因素来划分为更多或更少的功能模块,或者即使划分为8个功能模块,也可以按照其他方式来划分各个功能模块的功能。或者休眠调度服务也可以不划分功能模块,而是按照整体来工作。
下面结合应用场景,示例性说明电子设备700的软件以及硬件的一些工作流程。
请参见图8,为实现本申请实施例提供的休眠调度方法的各个功能模块调度关系的示意图。
如图8中的①,电子设备700中,固件层可根据休眠唤醒调度表设置唤醒中断,通过唤醒中断会触发低功耗定时器模块发送时间片到达事件给低功耗状态机模块。时间片到达事件用于触发低功耗定时器模块设置休眠唤醒时间的起始和休眠调度周期的起始。例如低功耗定时器模块接收到时间片到达事件,可设置16ms的定时器,即设置休眠唤醒时间的起始。当然,低功耗定时器模块还可以检测当前时隙,例如宣告时隙或业务时隙。设备可根据所设置的休眠唤醒时间和休眠唤醒周期进行业务数据的收发。
如图8中的②,当有业务到来时,应用程序层中的应用可通过约定的接口将业务信息(场景信息)通知给场景识别模块。如果业务出现变化,例如业务类型或者业务特征等发生变化,场景识别模块可将最新的业务信息通知给基本调度模块。
如图8中的③,基本调度模块会根据最新的业务信息和当前业务情况对设备的休眠唤醒情况进行估计,并将估计结果作为基本休眠唤醒时间信息告知给低功耗状态机模块。
如图8中的④,低功耗状态机模块接收并保存来自基本调度模块的基本休眠唤醒时间信息。低功耗状态机模块在每个休眠调度周期的宣告时隙先查询数据缓存模块的缓存情况,再根据基本休眠唤醒时间信息来填写休眠唤醒调度表。另外,当数据缓存模块的缓存的数据大小超过一定门限时,数据缓存模块可以通知低功耗状态机模块临时增加工作时隙。之后,低功耗状态机模块将本时隙本设备的休眠唤醒情况通知帧,即PNF发给帧处理模块。当然,如果有紧急业务时,低功耗状态机模块也会将用于生成动态协商通知帧的信息元素(IE)发送给帧处理模块(如图8中的⑤)。
如图8中的⑥,帧处理模块接收到PNF,对PNF进行解析,将解析帧后的结果通知给低功耗状态机模块。低功耗状态机模块可根据帧处理模块发送的结果更新休眠唤醒调度表。帧处理模块接收到用于生成动态协商通知帧的IE,根据该IE生成动态协商帧。同时,帧处理模块在动态协商期间,也会将接收到的协商帧进行解析,并将解析之后获得的相关信息(如协商发送数据的时间信息发送给低功耗状态机模块,以使得低功耗状态机模块进行休眠唤醒调度表的更新,并修改中断和设置低功耗定时器。
如图8中的⑦,在低功耗定时器超时时,低功耗状态机模块会查看休眠唤醒调度表,检查下一时隙是否为0(即唤醒时隙),若为0,则根据休眠唤醒调度表的情况设置偏移中断。如果下一时隙为1(即休眠时隙),则继续设置定时器。
当然,如图8中的⑧,当场景识别模块接收到应用层指示,有紧急业务需要发送时,通知动态调度模块。如图8中的⑨,动态调度模块对紧急业务报文进行解析,确定接收端的地址,向低功耗状态机模块查询接收端的忙闲情况。低功耗状态机模块将接收端的忙闲情况告知动态调度模块。动态调度模块根据接收端的忙闲情况确定最近可用的时隙。之后动态调度模块将最近可用的时隙通知给低功耗状态机模块,低功耗状态机模块可根据接收的最近可用的时隙信息修改休眠唤醒调度表,同时,低功耗状态机模块会标记该时隙为紧急业务报文协商使用。
分布式系统中的任意设备均可以根据其他设备的休眠唤醒时间来更新休眠唤醒调度表中自身的休眠唤醒情况,所以各个设备根据该休眠唤醒调度表在合适的时机选择其他合适的设备协同进行分布式业务,避免不必要的唤醒,从而更加节约功耗。
为了便于理解,本申请以下实施例将以具有图7A所示结构的电子设备700为例,结合附图对本申请实施例提供的休眠调度方法进行具体阐述。
本申请实施例提供多个设备,这多个设备可以是相同的设备,例如为电子设备300;或者,这多个设备也可以是不同的设备,例如这多个设备中的部分设备为电子设备300,部分设备为显示器。本申请实施例对这多个设备的实现形式不作限制,例如这多个设备均可以是电子设备,或者这多个设备也可以是电子设备中的芯片,又或者这多个设备中的部分设备是电子设备,部分设备是电子设备中芯片。
本申请实施例还对应提供一种分布式系统,该分布式系统可包括多个设备中的至少两个设备,当然,该分布式系统还可以包括其他设备。分布式系统中的任意设备之间可进行多屏协同,信息分享等。在本申请实施例中,互联的多个设备可以形成如图4所示的系统,也可以形成如图5所示的系统。
下面结合附图介绍本申请实施例提供的技术方案。在下文的介绍过程中,以该方法应 用于图4或图5所示的网络架构为例。应理解,多设备互联的情况下,如果多个设备相互之间有业务,例如第一设备投屏到多个设备或者设备间分享文件。但是可能不需要系统内的全部设备同时都工作,为了尽量节约各个设备的能耗,在本申请实施例中,各个设备可独立控制自己是否休眠,以尽量进入更长的休眠,最大限度节约能耗。
另外,本申请实施例各个设备基于相同的休眠调度周期实现独立的休眠唤醒,而为了统一调度,可以系统中的主设备为主,即主设备设置休眠调度周期,其余设备以主设备设置的休眠调度周期为主。上述图4所示的系统在建立链接时,各个设备已分配好角色,GO可认为是主设备,GC可认为是从设备。但是图5所示的系统由于各个设备通过蓝牙、WiFi发现彼此建立连接,所以系统中各个设备之间的角色对等,也就是不分主设备和从设备。因此在介绍本申请实施例提供的休眠调度方法之前,先介绍如图5所示的系统中如何选择主设备。
在可能的实现方式中,可对分布式系统中的多个设备进行优先级排序,将优先级最高的设备作为主设备。如果将分布式系统内所有设备的集合称为域,那么域内优先级最高的设备即为主设备。本申请实施例对优先级的确定方式不作限制。
作为一种示例,可根据各个设备的设备类型、设备的续航能力、设备的硬件能力、设备采用的协议版本、设备连接的设备数量和设备的MAC地址的一种或多种来确定设备的优先级。其中,设备的类型,例如为显示器、PC、平板、手机、IOT设备、智能音箱或穿戴设备等。设备的续航能力,例如为设备的剩余电量等级,例如高电量、中电量、中低电量以及低电量等。需要说明的是,本申请实施例对剩余电量等级的等级数量不作限制,各个剩余电量等级可事先定义,例如剩余电量大于或等于总电量的70%,那么该剩余电量的等级为高电量;剩余电量大于或等于总电量的50%,且小于总电量的70%,那么该剩余电量的等级为中电量;剩余电量大于或等于总电量的30%,且小于总电量的50%,那么该剩余电量的等级为中低电量;剩余电量小于总电量的30%,那么该剩余电量的等级为低电量。设备的硬件能力,例如设备采用双WiFi芯片或者单WiFi芯片。需要说明的是,设备的类型、设备的续航能力和设备的硬件能力等仅是举例说明,本申请实施例对设备的类型、设备的续航能力和设备的硬件能力的具体表现形式不作限制。
本申请实施例可按照各个设备的优先级信息,例如设备类型、设备的续航能力、设备的硬件能力、设备采用的协议版本、设备连接的设备数量和设备的MAC地址的优先级来确定设备的优先级。也就是,优先根据各个设备的设备类型来确定设备的优先级,如果根据各个设备的设备类型确定各个设备的优先级一致,可进一步根据设备的续航能力来确定设备的优先级,依次类推,直到确定出各个设备的优先级。例如可依次执行:1)比较各设备的类型,设备类型较高的设备为主设备,如果各设备的类型相同,可继续2);2)比较各设备的续航能力,续航能力较高的设备为主设备,如果各设备的续航能力相同,可继续3);3)比较各设备的硬件能力,设备硬件能力较高的为主设备,如果各设备的硬件能力相同,可继续4);4)比较各设备的协议版本,版本号较高的设备为主设备,如果各设备的版本号相同,可继续5);5)比较各设备所连接的设备数,连接数高的设备为主设备,如果各设备所连接的设备数相同,继续6);6)分别对各设备的MAC地址按位比较,MAC地址较高的设备为主设备。
各个设备可上报自身的优先级排序(ranking priority,RP)值,该RP值可用于指示各个设备的优先级信息。RP值可占用一个字段,也可以占用多个字段,对此,本申请实施例 不作限制。例如,RP值指示的各个内容可分别占用同一字段的不同比特;或者RP值指示的各个内容可分别占用不同的字段。
示例性的,RP值可包括两部分,一部分用于指示排序等级(ranking level),另一部分用于指示设备的MAC地址,其中,排序等级可包括设备等级、设备的协议版本号、设备所连接的设备数量。设备等级又包括设备的类型、设备的续航能力和设备的硬件能力。
举例来说,请参见图9,为承载RP值的第一部分的一种帧结构。即排序等级字段包括3个字段,这3个字段为设备等级字段、协议版本号字段和连接数字段。需要说明的是,本申请实施例对这3个字段的具体名称不作限制。本申请实施例对各个字段所占用的比特数不作限制。示例性的,设备等级字段的定义可参见表1。
表1
Figure PCTCN2022085845-appb-000002
在分布式系统内选出主设备之后,从设备可基于主设备的时间进行同步,包括但不限于以下两种方式。
例如,主设备可周期性发送时间同步帧,该时间同步帧可携带用于时间同步的时间信息。例如,该时间同步帧可以是802.11Beacon帧,携带有定时器同步功能(timer synchronization function,TSF)时间信息以及该分布式系统的基本服务集标识符(basic service set identifier,BSSID)。由于采用802.11Beacon帧作为时间同步帧,可沿用802.11Beacon帧的TSF,从而能够实现10us误差级别的硬件时钟同步,尽量缩短设备间的同步时间。任意从设备接收到来自主设备的时间同步帧,可获取该时间同步帧携带的BSSID。如果获取到的BSSID与自身的BSSID相同,那么可认为该时间同步帧是位于一个网络内的主设备发送的,可以根据该时间同步帧实现与主设备的同步。例如,从设备确定获取到的BSSID与自身的BSSID相同,则可以刷新TSF计数器,从而实现与主设备的时间同步。
同步方式二、主动时间同步,即从设备主动申请时间同步。从设备主动申请时间同步,不需要等待主设备发送时间同步帧,可提前与主设备完成同步,从而降低同步时延。
以要申请时间同步的从设备是第一从设备为例,第一从设备可主动广播时间同步请求消息,例如sync_request action信令帧,以向同一网络内已经完成时间同步的设备请求同步时间。主设备或其他从设备接收到该时间同步请求消息,可向第一从设备发送针对该时间 同步请求消息的响应消息,例如sync_response action信令帧。该响应消息可携带主设备或其他从设备的TSF时间信息和发送信息的时域(social slot)位置。social slot位置可认为是近场所有设备相互发现时交互的时隙位置。第一从设备接收到该响应消息,可根据该响应消息携带的TSF时间信息完成时间预同步,即与主设备的TSF时间信息对齐。应理解,每个设备维护TSF时间信息是基于本地定时器,然而设备发送信息存在时延。因此第一从设备接收到响应消息后,第一从设备可能还没有发现网络内的其他从设备。因此,第一从设备还可在social slot监听来自主设备或其他从设备的action信令帧,以根据该action信令帧携带的时间信息完成最终同步。
主设备确定之后,主设备可设置N个时隙的休眠唤醒周期,每个时隙可以看作是一个时间片,该时间片的最小单元可预先设置,例如16ms,或者其他可能的值。系统中的各个设备可根据实际需求,例如与其他设备的连接情况和业务情况在休眠唤醒周期上的各个时隙上选择休眠或者唤醒。本申请实施例可采用bitmap的形式来标识每个时隙是休眠或唤醒状态。
每个设备可以广播自身的休眠唤醒信息,这样系统中的各个设备彼此都知道各自的休眠唤醒情况,从而可选择处于唤醒的设备进行分布式业务,最大限度地使多个设备进行尽量多的休眠,节约能耗。在下文的介绍中,为了便于区分,将各个设备原始的基本休眠唤醒信息称为第一休眠唤醒信息,将各个设备基于业务需求重新生成的休眠唤醒信息称为第二休眠唤醒信息。
应理解,该方法涉及图4或图5中的多个设备。为了便于描述,下文的介绍中,以该方法涉及第一设备和多个设备,多个设备例如包括第二设备和第三设备,甚至第四设备等为例。第一设备可以是图4或图5中的任意设备,多个设备也可以是图4或图5中的任意设备。由于对任意设备来说,每个设备更新自身的休眠唤醒信息的过程相同,因此在下文的介绍过程中,以第一设备更新自身的休眠唤醒信息为例。在下面的介绍中,以N=32,M=2,即休眠调度周期包括32个时隙,宣告时隙为32个时隙最前2个时隙为例。
请参见图10,示出了本申请实施例提供的分布式系统的休眠调度方法的流程。该方法以第一设备执行为例。
S1001、场景识别模块向基本调度模块发送场景信息,相应的,基本调度模块接收该场景信息,该场景信息用于指示第一设备要进行的第一业务的业务特征。
当第一业务到来时,可能需要第一设备从某些时隙上的休眠状态切换为唤醒状态。为此,如果第一业务到来,应用程序层中的应用可通过约定的接口将第一业务的场景信息通知给场景识别模块。场景识别模块接收到来自应用层的场景信息,可对该场景信息进行识别,以确定第一业务需要第一设备的休眠唤醒情况。
场景信息可包括对端MAC地址,以告知第一设备第一业务来自哪个设备或哪几个设备。除此之外,场景信息还可以包括场景相关信息,例如第一业务的发包间隔、第一业务的最低延时容忍值,和每秒传输的帧数(number of frames per second,fps数)中的一种或多种,或者其他用于标识第一业务的信息,例如业务类型,音频类型、视频类型,或者文件类型等。应理解,不同的场景信息对应的休眠唤醒情况也有所不同,例如,如果第一业务的最低时延容忍值较低,那么第一设备在休眠调度周期内的各个时隙都处于唤醒状态;如果第一业务的最低容忍值较高,那么第一设备可在休眠调度周期内的部分时间处于唤醒状态,部分时隙处于休眠状态。
在一些实施例中,场景信息也可以包括用于指示场景相关信息的信息,例如称为场景档位。场景档位可根据场景相关信息来设置,例如第一业务的最低时延容忍值较低,那么场景档位较高,第一业务的最低容忍值较高,那么场景档位较低。应理解,场景档位可用于指示第一设备在休眠调度周期内的各个时间片的休眠唤醒情况。本申请实施例可预先定义多个场景档位,不同的场景档位对应不同的休眠唤醒情况。
本申请实施例对场景档位的具体实现形式不作限制。在一些实施例中,场景档位可占用多个比特,或者场景档位可根据休眠调度周期的各个时隙的休眠唤醒状态来定义。
示例性的,可定义4个场景档位,例如称为第一档、第二档、第三档和第四档。例如,场景档位可占用2比特,例如00标识第一档、01标识第二档、10标识第三档,11标识第四档。又例如,第一档为“11111111111111111111111111111111”,第二档为“10101010101010101010101010101010”,第三档为“10000100001000010000100001000010”,第四档为“10000000000100000000001000000000”,其中,“0”表示休眠,“1”表示唤醒。
当然,在一些实施例中,场景信息也可以包括场景档位和场景相关信息,对此,本申请实施例不作限制。
S1002、基本调度模块根据场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,其中,第一休眠唤醒信息用于指示第一设备当前的休眠唤醒情况。
基本调度模块接收到场景信息,可根据该场景信息以及当前的业务情况,即第一休眠唤醒信息对第一设备的休眠唤醒情况进行估计,以确定第一设备需要唤醒的时隙。通常来说,第一设备与其他设备,例如第二设备建立连接完成后,第一设备的设备建链模块会初始化第一设备的休眠唤醒情况。例如,可初始化第一设备在休眠调度周期内的各个时隙都处于唤醒状态,以尽量保证各种业务的正常进行。
例如,在一些实施例中,可定义每个链路的休眠唤醒信息的结构体如下:
Figure PCTCN2022085845-appb-000003
其中,Timeinfo用于指示链路的休眠唤醒信息,MacAddr为链路对端地址,AwakeDozeBitmap用于指示链路的休眠唤醒信息。在初始化Timeinfo时,例如MacAddr可指示第二设备的MAC地址,AwakeDozeBitmap中每个位都设置为1。当然,第一设备和第二设备建立的链路断开时,设备建链模块可删除第一设备和第二设备间链路的Timeinfo,即释放Timeinfo。
设备建链模块初始化第一设备和第二设备的Timeinfo之后,可将AwakeDozeBitmap发送给基本调度模块。
基本调度模块可基于场景信息生成第一休眠唤醒信息。示例性的,基本调度模块可基于第一预设规则以及场景信息生成第一休眠唤醒信息。第一预设规则可满足:
1)如果场景信息为空,那么以第一设备当前的业务情况为准,根据该业务情况生成第一休眠唤醒信息。
2)如果场景信息不为空,那么根据场景信息以及当前的业务情况生成第一休眠唤醒信息。
基本调度模块可获取场景信息,例如每秒传输帧数(frames per second,fps),根据该fps生成第一休眠唤醒信息。约定宣告时隙作为每个休眠调度周期的起始点,宣告时隙后的第一个时隙为可发送业务的时隙。从第一个可发送业务的时隙开始,可连续休眠的时隙数为
Figure PCTCN2022085845-appb-000004
(其中发包间隔等于1000/fps)。例如,如果场景信息指示60fps的场景,则可连续休眠的时隙数为
Figure PCTCN2022085845-appb-000005
即第一设备应该不休眠。又例如,如果场景信息指示30fps的场景,则可连续休眠的时隙数为
Figure PCTCN2022085845-appb-000006
所以该链路的第一休眠唤醒信息应该设计为唤醒1个时隙,休眠1个时隙。这种情况下,第一休眠唤醒信息,即AwakeDozeBitmap如表2所示。
表2 30fps场景对应的第一休眠唤醒信息
1 1 1 0 1 0 1 0 1 0 1 0 1 0 1 0
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0
同理,如果场景信息指示10fps的场景,则可连续休眠的时隙数为
Figure PCTCN2022085845-appb-000007
所以该链路的第一休眠唤醒信息应该设计为唤醒1个时隙,休眠5个时隙。这种情况下,第一休眠唤醒信息,即AwakeDozeBitmap如表3所示,表3同样以约定宣告时隙作为每个休眠调度周期的起始点,宣告时隙后的第一个时隙为可发送业务的时隙为例。
表3 10fps场景对应的第一休眠唤醒信息
1 1 1 0 0 0 0 0 1 0 0 0 0 0 1 0
0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0
应理解,第一业务到来,那么可能需要第一设备从某些时隙上的休眠状态切换为唤醒状态,为此,第一设备需要更新第一休眠唤醒信息,即生成第二休眠唤醒信息。可认为,第二休眠唤醒信息用于指示所述第一设备进行原始业务以及第一业务需满足的休眠唤醒情况。
例如,第一设备当前没有需要进行的业务,那么第一休眠唤醒信息可用于指示第一设备在休眠调度周期内的各个时隙上均处于休眠状态。如果场景识别模块检测到第一业务到来,例如场景识别模块接收到来自应用层的场景(业务)信息,可对该场景信息进行识别,并将识别结果通知给基本调度模块。基本调度模块根据接收到的场景信息,对第一设备进行第一业务的休眠唤醒情况进行估计,并根据估计结果以及第一休眠唤醒信息生成第二休眠唤醒信息。
基本调度模块根据接收到的场景信息,可基于预设规则对第一设备进行第一业务的休眠唤醒情况进行估计。
作为一种示例,预设规则可满足如下的一种或多种:
1)第一设备当前无业务的情况下,第一业务到来,基本调度模块无法确定第一设备进行第一业务的休眠唤醒情况,基本调度模块生成的第二休眠唤醒信息用于指示第一设备在休眠调度周期内的各个时隙内均处于唤醒状态。
基本调度模块在第一设备当前无业务的情况下,若确定第一业务到来,例如接收到场景信息,但是无法根据场景信息明确特定的场景。例如基本调度模块无法确定第一业务的最低时延容忍值或者场景档位等,那么可设置第一设备在休眠调度周期内的各个时隙均处于唤醒状态,以保证第一业务的顺利进行。
2)第一设备当前有业务,且第一休眠唤醒信息指示第一设备在休眠调度周期内的各个时隙均处于唤醒状态的情况下,第一业务到来,基本调度模块生成的第二休眠唤醒信息用于指示第一设备在休眠调度周期内的各个时隙内均处于唤醒状态。
由于第一设备当前有业务,且第一休眠唤醒信息指示第一设备在休眠调度周期内的各个时隙均处于唤醒状态。可认为,当前业务的进行需要第一设备一直处于唤醒状态,为了不影响第一设备当前业务的进行,即使第一业务到来,第一设备仍然一直保持唤醒状态。
3)第一设备当前有业务,且第一休眠唤醒信息指示第一设备在休眠调度周期内的部分时隙均处于唤醒状态的情况下,第一业务到来,基本调度模块无法确定第一设备进行第一业务的休眠唤醒情况,基本调度模块生成的第二休眠唤醒信息用于指示第一设备在休眠调度周期内的各个时隙内均处于唤醒状态;基本调度模块能够确定第一设备进行第一业务的休眠唤醒情况,基本调度模块根据第一休眠唤醒信息以及确定的第一设备进行第一业务的休眠唤醒情况生成第二休眠唤醒信息,该第二休眠唤醒信息可用于指示第一设备在休眠调度周期内的部分时隙内处于唤醒状态,以使得第一设备尽可能多地处于休眠状态,节约功耗。
作为一种示例,第一设备的第一休眠唤醒信息可如表4所示。
表4第一休眠唤醒信息
1 1 1 1 0 0 1 0 0 1 0 0 1 0 0 1
0 0 1 0 0 1 0 0 1 0 0 1 0 0 1 0
假设有第二业务,该第二业务对应的休眠唤醒信息例如为表5所示。
表5第二业务的休眠唤醒信息
1 1 1 0 1 0 1 0 1 0 1 0 1 0 1 0
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0
基于第一业务需求,第一设备可更新第一休眠唤醒信息,即根据第一业务的休眠唤醒信息以及第一休眠唤醒信息重新生成休眠唤醒信息,即第二休眠唤醒信息。第二休眠唤醒信息例如为表6所示。
表6第二休眠唤醒信息
1 1 1 1 1 0 1 0 1 1 1 0 1 0 1 1
1 0 1 0 1 1 1 0 1 0 1 1 1 0 1 0
从表4-表6可以看出,基本调度模块在当前有业务的情况下,若能确定新到来的业务,那么可基于新到来的业务更新第一休眠唤醒信息,即生成第二休眠唤醒信息。
当然,如果第一设备完成某些任务,也就是某些任务结束,那么第一设备也可以基于预设规则更新第一休眠唤醒信息,即生成第二休眠唤醒信息。
4)第一设备当前有业务,第一休眠唤醒信息指示第一设备在休眠调度周期的各个时隙内均处于唤醒状态的情况下,基本调度模块接收到删除第一业务的指令,基本调度模块无法确定第一设备进行剩余业务需要满足的休眠唤醒情况,那么第二休眠唤醒信息指示第一设备在休眠调度周期的各个时隙内均处于唤醒状态;相反,基本调度模块可以确定第一设备进行剩余业务需要满足的休眠唤醒情况,那么基于第一休眠唤醒信息以及确定的休眠唤醒情况生成第二休眠唤醒信息。
5)第一设备当前有业务,第一休眠唤醒信息指示第一设备在休眠调度周期的部分时 隙内处于唤醒状态的情况下,基本调度模块接收到删除第一业务的指令,基本调度模块根据第一设备进行剩余业务需要满足的休眠唤醒情况以及第一休眠唤醒信息生成第二休眠唤醒信息。
6)基本调度模块接收到对业务进行调整的命令,根据第一休眠唤醒信息以及调整后的业务需要满足的休眠唤醒情况生成第二休眠唤醒信息。
应理解,第一设备的第一休眠唤醒信息的更新是将第一设备的所有链路的休眠唤醒信息进行结合。针对每个时隙来说,若任一链路在该时隙的状态为“1”,则第二休眠唤醒信息中该时隙的状态仍然为“1”;只有当所有链路在该时隙的状态为“0”,则第二休眠唤醒信息中该时隙的状态为“0”。
S1003、基本调度模块将第二休眠唤醒信息发送给低功耗状态机模块,相应的,低功耗状态机模块接收该第二休眠唤醒信息。
S1004、低功耗状态机模块根据第二休眠唤醒信息更新休眠唤醒调度表。
基本调度模块可将该设备最新的休眠唤醒情况,即第二休眠唤醒信息告知低功耗状态机模块。低功耗状态机模块将该设备最新的休眠唤醒信息更新至休眠唤醒调度表。由于休眠唤醒调度表可用于调度分布式系统内的所有设备,因此,当某个设备的休眠唤醒情况更新,低功耗状态机模块可将该设备更新的休眠唤醒情况更新至休眠唤醒调度表中,这样第一设备根据休眠唤醒调度表就可以选择合适的设备进行分布式业务。
例如,当任意设备的休眠唤醒情况发生变化,帧处理模块在下一个休眠调度周期的宣告时隙广播PNF,以告知彼此各自对应的休眠唤醒信息。以第一设备为例,PNF用于指示第一设备在休眠调度周期内的各个时隙的休眠唤醒情况,可认为是一个私有的广播action帧。PNF除了包括第一设备在休眠调度周期内的各个时隙的休眠唤醒信息,还可以包括其他信息,例如第一设备的MAC地址、用于标识PNF的类型的信息、第一设备连接的设备数量等信息。
作为一示例,请参见图11,为本申请实施例提供的PNF的一种结构示意图。PNF可包括多个字段,例如MAC头(header)字段,代码(code)字段、组织唯一标识符(organizationally unique identifier,OUI)字段、OUI类型(type)字段、开始类型(action type)字段、一个或多个属性字段、连接数字段、帧校验序列(frame check sequence,FCS)等。需要说明的是,图11只是示例,PNF可包括更多或更少的字段,每个字段可占用一个或多个比特,本申请实施例对此不作限制。
其中,MAC header字段可按照action帧的MAC头来确定,例如可承载第一设备的MAC地址(也称为源地址,即PNF是第一设备的)和目的地址。由于第一设备广播PNF,所以目的地址为广播的目的地址。code字段可根据action帧的类别代码(category code)来填写,例如可根据802.11协议确定为127,即指示Vendor-specific action。OUI字段可预先定义,例如OUI字段可用于承载“0x00-E0-FC”,以示意PNF为私有帧。OUI Type字段用于标识OUI的类型,例如与本申请实施例提供的PNF相关的私有帧。action type字段用于标识action帧类型,例如PNF的帧类型可为“0x01”。一个或多个属性字段至少用于承载第一设备的休眠唤醒信息。连接数字段用于承载第一设备连接的设备数量。
应理解,S1001只是以第一设备为例。实际上分布式系统内的各个设备都在休眠调度周期内的宣告时隙广播PNF,这样可根据各个设备的休眠唤醒信息生成休眠唤醒调度表。例如,第一设备的帧处理模块也可以将接收到来自其他设备的PNF进行解析,并将解析结 果发送给低功耗状态机模块,以使得低功耗状态机模块根据其他设备在宣告时隙发送的PNF更新自身存储的休眠唤醒调度表。例如,休眠唤醒调度表中携带用于唯一标识设备的标识信息,例如MAC地址或ID等。低功耗状态机模块更新休眠唤醒调度表之后,可在下一个宣告时隙广播PNF帧,用于设备间建立连接或者传输信息。应理解,分布式系统中的主设备已定义休眠调度周期,系统中的各个设备的低功耗定时器模块分别设置定时器用于设置休眠调度周期的起始以及休眠唤醒时间的起始。当有业务到来时,低功耗状态机模块可更新自身的休眠唤醒状态,以能够正常进行该业务。同时,低功耗状态机模块可将更新后的休眠唤醒状态更新至保存的休眠唤醒调度表,并将更新后的休眠唤醒状态告知其他设备,以使得其他设备更新保存的休眠唤醒调度表,使得系统采用统一的休眠唤醒调度表进行休眠调度。
第一设备可根据更新后的休眠唤醒调度表来进行第一业务。应理解,在可能的场景中,第一设备之后可能需要重新估计自身的休眠唤醒情况。下面列举几种第一设备需要更新自身的休眠唤醒信息以及存储的休眠唤醒调度表的场景。
场景一,也可以称为链路变化场景。
对于第一设备的任意一条链路而言,该链路上的业务流量可能发生变化,第一设备当前的休眠唤醒情况可能不是最佳的。例如,第一设备的某条链路的业务数据变多,即流量变大,那么第一设备的数据缓存模块所存储的业务数据较多,为了较快地将数据缓存模块所存储的业务数据传输给对端设备,此时可临时增加唤醒时隙。又例如,一段时间内业务流量降低,这种情况下,可以让第一设备进入更多的休眠,以尽量节约功耗。基于此,第一设备的低功耗状态机模块在每个休眠调度周期的宣告时隙更新休眠唤醒调度表之前,即发送PNF之前,可先根据第一设备的各条链路的流量大小,适应性地调整休眠唤醒调度表。例如,当第一设备和第二设备之间链路的流量超过一定门限时,低功耗状态机模块可临时增加唤醒时隙,即第一设备的休眠唤醒信息可指示更多的唤醒状态。当然,第一设备的某条链路可能有突发的紧急业务,这种情况下,也可临时增加唤醒时隙。需要说明的是,对第一设备和第二设备之间的链路进行流量统计可以通过底层实现,即底层监控流量并统计,也可以是基于业务流上层下发的业务相关信息统计,本申请实施例对此不作限制。
当然,为了保证业务的正常进行,第一设备的任意链路的休眠唤醒信息发生变化,第一设备需要将变化后的休眠唤醒信息通知给对应链路的对端设备(例如第二设备)。以第一设备和第二设备之间的传输链路是第一链路为例。第一设备的第一链路的休眠唤醒信息发生变化,第一设备可更新第一链路的休眠唤醒信息,并将第一链路更新后的休眠唤醒信息告知第二设备。第二设备可根据来自第一设备的第一链路更新后的休眠唤醒信息,更新所保存的第一链路的休眠唤醒信息。第二设备可将第一链路更新后的休眠唤醒信息告知第一设备,第一设备基于此再次更新第一链路的休眠唤醒信息。这样第一设备和第二设备保存的第一链路的休眠唤醒信息是一致的,以保证业务的正常进行。
应理解,第一设备的休眠唤醒信息需满足第一设备的各个链路的休眠唤醒信息。第一设备可以存储第一设备的各个链路的休眠唤醒信息,第一设备的任意链路的休眠唤醒信息发生变化,都需要更新第一设备的休眠唤醒信息,并将更新后的休眠唤醒信息更新至第一设备存储的休眠唤醒调度表。
场景二,也称为紧急业务场景。
紧急业务可认为是需要优先处理的业务。当有来自第二设备的紧急业务请求,或者第 一设备有需要向第二设备发送紧急业务时,第一设备当前的休眠唤醒情况可能不是最佳的。这种情况下,第一设备可临时增加唤醒时隙,用于发送或接收紧急业务。应理解,第一设备临时增加唤醒时隙需要告知第二设备,以保证第一设备和第二设备之间能够正常进行紧急业务。
在一些实施例中,第一设备和第二设备可协商用于发送紧急业务的休眠唤醒情况,并更新第一设备和第二设备之间的链路(例如第一链路)的休眠唤醒信息。关于第一设备和第二设备协商用于发送紧急业务的休眠唤醒情况的具体方案将在下文中介绍。当然,第一设备可根据第一设备最终更新后的传输链路的休眠唤醒信息来更新自身的休眠唤醒信息和存储的休眠唤醒调度表。
场景三,也称为保活场景。即互联设备的链路保持连接状态,但是互联设备间无业务数据交互。这种场景下,尽管互联设备之间无业务数据交互,但是由于互联设备的链路保持连接状态,这样设备间可以保持一些数据,例如小流量时延不敏感数据的交互,不会影响设备间正常工作。所以保活场景下,可能涉及小流量时延不敏感数据的交互,自然第一设备也会更新自身的休眠唤醒信息以及存储的休眠唤醒调度表。例如,由于干扰等因素,第一设备没有及时将业务数据发送出去,而是存储在了数据缓存模块。如果数据缓存模块存储大量的数据,显然降低了第一设备的存储空间的利用率。因此,在保活场景下,数据缓存模块中可能有之前未传输完的业务数据。第一设备的低功耗状态机模块在每个休眠调度周期的宣告时隙更新休眠唤醒调度表之前,可先查询数据缓存模块存储的数据量,如果该数据量大于或等于预设阈值,那么可临时增加唤醒时隙,以将数据缓存模块中存储的数据尽快发送出去。这种场景下,第一设备的链路的休眠唤醒时隙也有所变化,因为第一设备需要通知对端设备,链路的休眠唤醒情况的变化。且第一设备需要更新第一设备的休眠唤醒信息,并将更新后的休眠唤醒信息更新至第一设备存储的休眠唤醒调度表。
需要说明的是,基本调度模块也可以在每个时隙开始检测数据缓存模块存储的数据量,一旦确定数据量大于或等于预设阈值,那么除非低功耗状态机模块更新第一设备的休眠唤醒信息以及休眠唤醒调度表。
场景四,也称为业务变更场景。
应理解,第一设备的业务可能会发生变更,例如第一业务结束第一业务,第一设备有第二业务加入,或者第一设备的第一业务变更为第二业务,或者第一设备删除之前进行的业务的等。这种情况下,第一设备需要重新估计自身的休眠唤醒情况,即第一设备可根据业务的变更情况,适应性增加唤醒时隙或者减少唤醒时隙。例如,第一设备结束第一业务,那么第一设备可临时减少唤醒时隙。又例如,有第二业务加入第一设备,那么第一设备可临时增加唤醒时隙。因此,第一设备的低功耗状态机模块在每个休眠调度周期的宣告时隙更新休眠唤醒调度表之前,可先判断业务是否有变更,如果变更,可对第一设备相应链路的休眠唤醒信息进行调整,并根据相应链路调整后的休眠唤醒信息更新休眠唤醒信息以及休眠唤醒调度表。
应理解,场景一和场景四中,任一场景发生,第一设备都会更新休眠唤醒信息以及休眠唤醒调度表。除此之前,第一设备还需要告知对端设备,第一设备最新的休眠唤醒信息。例如,任一链路的休眠唤醒信息发送变化,都需要重新生成休眠唤醒信息,并保存。为了保持基于该链路的休眠唤醒信息链路两端设备的休眠唤醒能够保持一致,链路的一端可将更新后的休眠唤醒信息通知给帧处理模块,帧处理模块在宣告时隙以通知帧的方式告知链 路对端新的休眠唤醒信息。
可以理解为,第一设备生成第二休眠唤醒信息并更新休眠唤醒调度表之后,还可以基于实际的应用场景,灵活调整第一设备相应链路的休眠唤醒信息,并根据相应链路的休眠唤醒信息更新自身的休眠唤醒信息以及休眠唤醒调度表,以尽量在不影响第一设备进行各种业务的前提下,使得第一设备更多地进入休眠,节省功耗。
下面分别以多个场景为例,以第一设备的对端设备是第二设备为例,介绍第一设备如何更新链路级的休眠唤醒信息,以及更新自身的休眠唤醒信息以及存储的休眠唤醒调度表的时机。应理解,第一设备可监控是否进入上述四种场景中的任意一种,如果进入某种场景,那么根据该场景的实际需求,适应性调整第一设备相应链路的休眠唤醒信息。为了便于描述,下文中,将链路级别的休眠唤醒信息称为链路休眠唤醒信息。针对第一设备和第二设备之间的某条传输链路,出现某种场景的情况下,第一设备调整该传输链路的休眠唤醒信息。可将第一设备针对该传输链路调整后的休眠唤醒信息称为第一链路休眠唤醒信息;将第二设备针对该传输链路,更新后的休眠唤醒信息称为第二链路休眠唤醒信息。
S1005、低功耗状态机模块确定第一设备进入多种场景中的任意一种场景,更新相应链路的休眠唤醒信息,并更新自身的休眠唤醒信息以及休眠唤醒调度表。
为了便于理解,下面以正常业务之后,在保活场景和紧急业务下,介绍本申请实施例提供的休眠调度方法的具体流程。
示例性的,请参见图12,为本申请实施例提供的保活场景下的休眠调度方法的流程示意图。图12以第一设备执行为例。
S1201、低功耗定时器在中断事件到来时,判断当前时隙是否是宣告时隙。
可设置中断事件,例如时间片到达事件用于触发低功耗定时器抛时间片事件给低功耗状态机模块。低功耗状态机模块收到事件后,会设置定时器,并判断当前时隙是否是宣告时隙。如果当前时隙不是宣告时隙,那么可执行S1202-S1203;如果当前时隙是宣告时隙,那么可执行S1204以及S1204之后的步骤。
S1202、在业务时隙进行业务数据的收发。
S1203、根据休眠唤醒调度表设置定时器,以设置中断事件。
应理解,如果当前时隙是业务时隙,那么可按照当前的休眠唤醒调度表在处于唤醒状态的时隙上进行业务数据的收发。之后,可根据休眠唤醒调度表设置定时器,设置中断事件,从而继续下一个休眠调度周期内的休眠调度。
S1204、当前时隙是宣告时隙,低功耗状态机模块更新休眠唤醒调度表。
如果当前时隙是宣告时隙,那么低功耗状态机模块可根据来自各个设备的PNF帧指示的休眠唤醒信息来更新所保存的休眠唤醒调度表。
S1205、基本调度模块判断是否处于保活场景。
应理解,如果有业务到来,那么场景识别模块可对业务进行识别,并生成场景信息发送给基本调度模块。基本调度模块根据接收的场景信息判断该业务是否有数据的收发,即判断是否有新的业务。场景信息的具体实现可参考前述S1001的相关内容介绍,这里不再赘述。如果场景信息指示有业务,那么基本调度模块根据场景信息以及当前的第一休眠唤醒信息生成第二休眠唤醒信息。
之后,如果出现前述场景一到场景四中的任意一种场景,第一设备中的低功耗状态机模块会更新第二休眠唤醒信息以及存储的休眠唤醒调度表。
S1206、若确定不是保活场景,可判断是否进入其他场景。
S1207、若确定为保活场景,可查询数据缓存模块中是否有业务数据发送。
S1208、如果数据缓存模块没有业务数据需要发送,那么低功耗状态机模块可设置第一设备在休眠调度周期内的各个时隙都处于休眠状态。
S1209、如果数据缓存模块有业务数据需要发送,低功耗状态机模块可更新休眠调度周期内的前P个时隙的休眠唤醒情况,并更新休眠唤醒调度表。P为正整数,且P尽量小,P个时隙是连续的时隙。也就是低功耗状态机模块更新尽量靠近宣告时隙的连续P个时隙的休眠唤醒信息。
如果是保活场景,也就是数据缓存模块中可能有之前未传输完的业务数据。此时,可查询数据缓存模块中是否有业务数据需要发送。如果数据缓存模块中有业务数据需要发送,为了将数据缓存模块中的业务数据尽快发送完,那么可在休眠调度周期内可用的时隙发送业务数据。优选的,可选择休眠调度周期内尽可能靠前且连续的P个可用时隙发送业务数据,提高数据传输效率。例如,将连续的P个时隙置为唤醒状态。低功耗状态机模块更新休眠唤醒信息之后,可将更新后的休眠唤醒信息更新至存储的休眠唤醒调度表,并在宣告时隙广播更新后的休眠唤醒信息。考虑到数据缓存模块的业务数据的数据量较少时,对后续链路传输效率影响不大,这种情况下,为了尽量节约第一设备的功耗,无需调整P个时隙的休眠唤醒信息。换句话说,如果数据缓存模块中有业务数据需要发送,且业务数据的数据量大于某预设阈值,低功耗状态机模块可更新P个时隙的休眠唤醒信息。当然,如果数据缓存模块中没有业务数据要发送,那么可设置第一设备在休眠调度周期内保持休眠,以节约功耗。考虑到数据缓存模块中的数据量可能较大,也可能较小。如果数据缓存模块中的数据量较小,将P个时隙置为唤醒状态,相对来说功耗较大。因此,在一些实施例中,低功耗状态机模块确定数据缓存模块有业务数据需要发送时,也可将当前的休眠唤醒信息从一个低功耗档位调整到另一个低功耗档位。例如,当前低功耗档位为第六档位,那么可从第六档位调整到第四档位,或者其他档位。具体调整到哪个档位可以是预定义的,例如调高2个低功耗档位。或者,可根据监控的链路流量大小来确定将当前低功耗档位调整到哪个档位,以尽量提高数据传输效率,并尽量降低第一设备的功耗。
应理解,第一设备更新休眠调度周期内的前P个时隙的休眠唤醒情况之后,可在宣告时隙告知系统内的其余设备,其余设备会根据第一设备最新的休眠唤醒信息来更新自身存储的休眠唤醒调度表。这样整个系统各个设备保持的休眠唤醒调度表一致,以保证各个设备间业务正常进行,且各个设备在正常进行业务的情况下,能够尽量多地进入休眠,尽可能地节省功耗。
请参见图13,为紧急业务的处理流程示意图。有紧急业务的情况下,例如第一设备需要向第二设备发送紧急业务,或者第二设备需要向第一设备发送紧急业务,第一设备和第二设备需要根据紧急业务协商用于紧急业务的时隙,并更新自身的休眠唤醒信息以及存储的休眠唤醒调度表。为了便于理解,下面介绍有来自第二设备的紧急业务的情况下,如何实现链路的休眠唤醒信息的更新。
S1301、第一设备确定宣告时隙后有紧急业务需要发送。
S1302、第一设备查询休眠唤醒调度表。
S1303、第一设备判断第二设备在当前休眠调度周期之后的时隙是否一直处于休眠。
应理解,第一设备保存的休眠唤醒调度表包括第二设备的休眠唤醒信息,从而可以根 据第二设备的休眠唤醒信息确定第二设备在当前休眠调度周期之后的时隙是否一直处于休眠。
S1304、第二设备在当前休眠调度周期之后的时隙一直处于休眠,那么将到来的紧急业务数据存储在数据缓存模块,以在一个休眠调度周期到来时,优先发送该紧急业务数据。
在下一个休眠调度周期到来时,优先发送紧急业务数据时,第一设备和第二设备在宣告时隙协商进行紧急业务的时隙,之后在协商好的时隙进行紧急业务的收发。
S1305、第二设备在当前休眠调度周期之后的时隙不是一直处于休眠,那么第一设备可选择可用于发送紧急业务的时隙,并更新第一设备的休眠唤醒信息。
S1306、第一设备向第二设备发送第一通知帧,相应的,第二设备接收该第一通知帧。
第一设备选择可用于发送紧急业务的时隙之后,可告知第二设备,第一设备将要发送紧急业务数据。第一通知帧可在第二设备的唤醒时隙发送,例如可在第二设备可用的最近时隙发送,第一通知帧包括第一设备的身份标识信息,以及第一设备选择的可用于发送紧急业务的时隙等信息(也就是上述的第一链路休眠唤醒信息)。
S1307、第二设备解析第一通知帧,并更新相应链路的休眠唤醒信息。
第二设备接收到第一通知帧,可解析该第一通知帧,从第一通知帧中获取第一链路休眠唤醒信息,即第一设备用于向第二设备发送紧急业务的时隙数等信息。第二设备可根据第一链路休眠唤醒信息将发送紧急业务需要的时隙数的时隙设置为唤醒状态,获得第二链路休眠唤醒信息,并更新保存的休眠唤醒调度表。第二设备获得第二链路休眠唤醒信息之后,可将第二链路休眠唤醒信息通过第一通知帧的回复帧,即第二通知帧告知第一设备,开始传输紧急业务的时隙。
S1308、第一设备和第二设备在协商好的时隙上进行紧急业务的收发。
为了便于理解,下面以具体的示例对图13和图14所示的流程进行说明。
假设存在设备A、设备B和设备C,其中,设备A向设备B发起投屏业务,例如30fps分布式视频流;设备A向设备C也发起投屏业务,例如10fps分布式图库。
30fps分布式视频流对应的休眠唤醒情况例如为表7所示,也就是休眠唤醒调度表中设备B的休眠唤醒信息为:
表7
1 1 1 0 1 0 1 0 1 0 1 0 1 0 1 0
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0
10fps分布式图库对应的休眠唤醒情况例如为表8所示,也就是休眠唤醒调度表中设备C的休眠唤醒信息为:
表8
1 1 1 0 0 0 1 0 0 0 0 0 1 0 0 0
0 0 1 0 0 0 0 0 1 0 0 0 0 0 1 0
那么设备A根据表7和表8,可生成如表9所示的休眠唤醒信息,即休眠唤醒调度表中设备A的休眠唤醒信息为:
表9
1 1 1 0 1 0 1 0 1 0 1 0 1 0 1 0
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0
设备A、设备B或设备C中的任意设备根据自身业务需求,生成新的休眠唤醒信息之后,可在休眠调度周期的宣告时隙广播自身的休眠唤醒信息,并将最新的休眠唤醒信息更新至休眠唤醒调度表。设备A或设备B或设备C可按照休眠唤醒调度表中自身的休眠唤醒信息进行休眠唤醒。以设备A为例,如表9所示,设备A在第一个时隙唤醒,在第二个时隙休眠,在第三个时隙唤醒,以此类推。然而,如果此时系统中增加了设备D,但是设备A和设备D之间无业务,设备D与其他设备之间可能有业务。随着设备D的加入,设备A的休眠唤醒信息需要更新。假设,设备D的休眠唤醒信息例如为表10:
表10
1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
设备A根据设备D的休眠唤醒信息更新自身的休眠唤醒信息,更新后的休眠唤醒信息例如为表11所示。
表11
1 1 1 0 1 0 1 0 1 0 1 0 1 0 1 0
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0
如果设备A和设备C之间有紧急业务需要从设备A发送给设备C。假设紧急业务是在第11个时隙到来,且该紧急业务需要4个时隙。那么设备A可告知设备C,根据紧急业务调整休眠唤醒信息。从表8可以看出,紧急业务到来之后,最近的唤醒时隙即第13个时隙。而从表11中可以看出,设备A在第13个时隙也处于唤醒状态,那么设备A和设备C可在第13个时隙协商用于紧急业务的可用时隙。即设备A可在第13个时隙向设备C发送第三通知帧,设备C接收第一通知帧之后,根据紧急业务求更新休眠唤醒信息。例如设备C确定紧急业务需要4个时隙,可从第13个时隙开始,将连续的4个时隙设置为唤醒状态,即将第14-17个时隙设置为唤醒状态。设备C可将更新后的休眠唤醒信息告知设备A,即设备C向设备A发送第二通知帧。设备A接收到第二通知帧,也可以将第14-17个时隙设置为唤醒状态。设备C和设备A根据协商结果分别更新自身的休眠唤醒信息,以及休眠唤醒调度表。设备C更新后的休眠唤醒信息例如为表12,设备A更新后的休眠唤醒信息例如为表13。
表12
1 1 0 0 0 0 1 0 0 0 0 0 1 1 1 1
1 0 1 0 0 0 0 0 1 0 0 0 0 0 1 0
表13
1 1 1 0 1 0 1 0 1 0 1 0 1 1 1 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0
设备A可按照表13进行休眠唤醒,设备C可按照表12进行休眠唤醒,以实现紧急业务的收发。需要说明的是,表8中设备C在第13个时隙处于唤醒状态,表11中设备A在第13个时隙处于唤醒状态,仅是举例。在一些实施例中,即使设备A在第13个时隙处于休眠状态,设备A还是可以将第13个时隙先唤醒,再向设备C发送第一通知帧。
第一设备根据实际场景调整相应链路的休眠唤醒信息之后,可将相应链路调整后的休眠唤醒信息告知第二设备。
S1006、低功耗状态机模块向第二设备发送第一通知帧,相应的,第二设备接收该第一通知帧,第一通知帧携带第一链路休眠唤醒信息。
S1007、低功耗状态机模块接收来自第二设备的第二通知帧,第二通知帧携带第二链路休眠唤醒信息。
第一设备进行第一业务之后,低功耗状态模块可判断第一设备是否进入上述四种场景中的任意一种。如果确定第一设备进入某种场景,那么更新第一设备相应链路的休眠唤醒信息,获得第一链路休眠唤醒信息。第一设备还需要将第一链路休眠唤醒信息告知第二设备,以使得第二设备适应性更新所保存的对应链路的休眠唤醒信息。
以场景一为例。当第一设备和第二设备之间的传输链路的流量变大,那么可认为第一设备的数据缓存模块所存储的业务数据较多,为了较快地将数据缓存模块所存储的业务数据传输给第二设备,此时可临时增加唤醒时隙。即第一设备可灵活调整传输链路的休眠唤醒信息,获得第一链路休眠唤醒信息。第一设备获得第一链路休眠唤醒信息之后,可向第二设备发送第一通知帧,该第一通知帧携带第一链路休眠唤醒信息。即第一设备将第一链路休眠唤醒信息告知第二设备。第二设备可根据第一链路休眠唤醒信息更新自身保存的该传输链路的休眠唤醒信息,获得第二链路休眠唤醒信息。具体的第二设备根据第一链路休眠唤醒信息更新所保存的对应链路的休眠唤醒信息可参考前述表3-表5,这里不再赘述。第二设备获得第二链路休眠唤醒信息之后,可将第二链路休眠唤醒信息告知第一设备,以使得第一设备根据第二链路休眠唤醒信息更新对应链路的休眠唤醒信息。
在一些实施例中,第一通知帧可在第二设备的唤醒时隙发送,例如第二设备在休眠调度周期内的第5个时隙处于唤醒状态,那么第一设备可在第5个时隙将第一通知帧发送给第二设备。需要说明的是,如果第一设备和第二设备在第5个时隙都处于唤醒状态,那么第一设备可直接在第5个时隙将第一通知帧发送给第二设备。如果第一设备在第5个时隙处于休眠状态,而第二设备在第5个时隙处于唤醒状态,那么第一设备可先将第5个时隙唤醒,之后再在第5个时隙将第一通知帧发送给第二设备。应理解,第二设备接收到第一通知帧之后,向第一设备反馈第二通知帧。如果时延不大,那么第二通知帧可在第5个时隙发送,也能在其他唤醒时隙,例如第6个时隙发送。考虑到由于干扰等因素的存在,第二设备可能无法收到第一通知帧,为了保证第一设备和第二设备之间针对某条链路的休眠唤醒信息一致,本申请实施例还可以设置定时器。如果该定时器超时,第一设备还未接收到来自第二设备的第二通知帧,可认为第二设备没有接收到第一通知帧,那么第一设备可重新向第二设备发送第一通知帧。
同理,对于场景二来说,当第一设备和第二设备之间有紧急业务,第一设备也可临时增加唤醒时隙。即第一设备需要更新第一设备和第二设备之间的传输链路的休眠唤醒信息。同样第一设备更新该传输链路的休眠唤醒信息之后,需要告知第二设备。在场景二中,由于第一设备和第二设备之间是紧急业务,因此,为了将紧急业务的数据较快地完成传输。作为第一通知帧的一种可替换的实现方式,第一通知帧也可以指示第二设备开始紧急业务。举例来说,第一设备在第二设备的第5个时隙将第一通知帧发送给第二设备。第二设备接收到第一通知帧之后,可将第5个时隙之后的所有时隙唤醒,而第一设备也可以将第5个时隙之后的所有时隙唤醒。这样第一设备和第二设备之间的链路休眠唤醒信息也是一致的。当然,紧急业务结束,第一设备可告知第二设备。例如第一设备向第二设备再次发送第一通知帧,用于指示结束紧急业务,第二设备接收到第一通知帧,可将对应链路的休眠唤醒 信息恢复成紧急业务之间的休眠唤醒信息。
场景三和场景四与场景一和场景二类似,第一设备也需要更新相应链路的休眠唤醒信息,这里不再赘述。当然,第一设备的低功耗状态机模块调整任意链路的休眠唤醒信息之后,需适应性更新自身的休眠唤醒信息以及休眠唤醒调度表。第一设备更新自身的休眠唤醒信息之后,可将第一设备最新的休眠唤醒信息告知其他设备。示例性的,低功耗状态机模块可向帧处理模块发送第一设备最新的休眠唤醒信息,帧处理模块可基于第一设备最新的休眠唤醒信息生成PNF,以在宣告时隙广播该PNF。需要说明的是,第一通知帧和第二通知帧可以在休眠调度周期的宣告时隙发送,也可以在休眠调度周期内处于唤醒状态的业务时隙发送。
作为一种示例,请参见图14,为第一通知帧或第二通知帧的结构示意图。以第一通知帧为例,第一通知帧可包括例如MAC header字段,code字段、OUI字段、OUI type字段、action type字段、属性字段以及FCS字段,其中,属性字段用于承载第一设备的休眠唤醒信息。与PNF帧类似,第一通知帧的各个字段的具体作用可参考PNF的介绍,这里不再赘述。
S1008、第一设备根据第二通知帧更新第一链路休眠唤醒信息,并基于更新后的第一链路休眠唤醒信息在休眠调度周期的业务时隙进行业务数据的收发。
第一设备接收到第二通知帧,可根据第二通知帧更新第一链路休眠唤醒信息,以确保第一设备和第二设备所保存的链路的休眠唤醒信息一致。之后第一设备可基于更新后的链路休眠唤醒信息在休眠调度周期内的处于唤醒状态的业务时隙进行业务数据的收发。
上述以四种可能的场景为例,介绍了第一设备可根据实际场景灵活调整相应链路的休眠唤醒信息,下面介绍第一设备调整休眠唤醒信息的可能实现方式。
作为一种示例,本申请实施例可预定义多个低功耗档位,每个低功耗档位用于指示第一设备在休眠调度周期内的各个时隙的休眠唤醒情况。不同的低功耗档位对应的休眠唤醒信息不同。基本调度模块可基于场景信息来确定生成何种第一休眠唤醒信息,即基于场景信息确定使用哪个低功耗档位。当然,低功耗状态机模块也可以根据实际场景来确定如何更新休眠唤醒信息,例如将当前休眠唤醒信息对应的低功耗档位调整为另一个低功耗档位。
在一些实施例中,可定义6个低功耗档位,这6个低功耗档位包括第一档、第二档、第三档、第四档、第五档和第六档,其中,档位越高,越节约功耗。第一设备在任意档位对应的休眠调度周期内的宣告时隙都处于唤醒状态。例如:
第一档的第一休眠唤醒信息可为“11111111111111111111111111111111”,即整个休眠调度周期内的所有时隙都处于唤醒状态;
第二档的第一休眠唤醒信息可为“11101010101010101010101010101010”,即业务时隙每间隔1个时隙唤醒一次;
第三档的第一休眠唤醒信息可为“111001001001001001001001001001001”,即业务时隙每间隔2个时隙唤醒一次;
第四档的第一休眠唤醒信息可为“11100001000010000100001000010000”,即业务时隙每间隔4个时隙唤醒一次;
第五档的第一休眠唤醒信息可为“11100000010000001000000100000010”,即业务时隙每间隔6个时隙唤醒一次;
第六档的第一休眠唤醒信息可为“11100000000001000000000010000000”,即业务时隙 每间隔10个时隙唤醒一次。
另外,为了更节约设备的能耗,还可以定义特殊档位,例如,每间隔L*32个时隙唤醒2个时隙,L为大于或等于1的正整数。也可以理解为,特殊档位下,设备可以进入深度休眠。当设备处于深度休眠,可基于专门的手段触发设备唤醒,例如基于蓝牙唤醒设备。
可认为,第一档到第六档是第一设备亮屏或暗屏时可选择的档位,特殊档位是第一设备暗屏时可选择的档位。基本调度模块初始传输给低功耗状态机模块的休眠唤醒新信息可表示最下限档位,即第一档。之后基本调度模块可根据场景信息在第一档中做档位调整,即调整第一档中连续0的个数。举例来说,基本调度模块确定来自应用层的场景信息为“110000010000010000010000010000010”,即要求每间隔5个时隙唤醒一次,此时可设置休眠唤醒信息为第一档到第四档中的任意一档。每一个档位可对应一个阈值,例如单位时间内发送的数据量。
第一设备灵活调整休眠唤醒信息时,例如在场景一中,低功耗定时器模块可设置定时器,以对第一设备和第二设备之间的链路进行流量统计。定时器开始,如果一段时间内第一设备和第二设备之间的链路流量均低于阈值X1,那么低功耗状态机模块可确定休眠唤醒信息降低一个档位,直至降至第四档。进一步地,如果当前休眠唤醒信息已经降低至最下限档位,但是一段时间内第一设备和第二设备之间的链路流量仍低于阈值X1,那么低功耗状态模块可继续下调最下限档位以及当前的休眠唤醒信息对应的档位,直至降低至可选档位中的最低档,例如第六档或特殊档位。当然,一段时间内第一设备和第二设备之间的链路流量增加且超过阈值X1时,那么低功耗状态机模块可提升休眠唤醒信息对应的档位,例如恢复至全醒或业务设置的档位。如果一段时间内第一设备和第二设备之间的链路流量继续增加,且超过阈值X2,那么低功耗状态机模块可继续提升休眠唤醒信息当前对应的档位,直到提高到最高档位。
同理,在场景二中,第一设备确定有紧急业务时,可将当前的休眠唤醒信息从一个低功耗档位调整到另一个低功耗档位。例如,当前低功耗档位为第六档位,那么可从第六档位调整到第四档位,或者其他档位。具体调整到哪个档位可以是预定义的,例如调高2个低功耗档位。或者,可根据监控的链路流量大小来确定将当前低功耗档位调整到哪个档位,以尽量提高数据传输效率,并尽量降低第一设备的功耗。
在场景三中,第一设备确定数据缓存模块存储的数据量大于预设阈值,可将当前的休眠唤醒信息从一个低功耗档位调整到另一个低功耗档位。例如,当前低功耗档位为第六档位,那么可从第六档位调整到第四档位,或者其他档位。具体调整到哪个档位可以是预定义的,例如调高2个低功耗档位。或者,可根据具体的数据量大小来确定将当前低功耗档位调整到哪个档位,以尽量提高数据传输效率,并尽量降低第一设备的功耗。
在场景四中,第一设备确定业务发生变更,可将当前的休眠唤醒信息从一个低功耗档位调整到另一个低功耗档位。例如,第一设备当前进行第一业务,当前低功耗档位为第四档位,如有第二业务到来,那么可从第四档位调整到第三档位,或者其他档位。具体调整到哪个档位可以是预定义的,例如调低2个低功耗档位。或者,可根据第二业务的特征来确定将当前低功耗档位调整到哪个档位,以尽量降低第一设备的功耗。又例如,第一设备当前进行第一业务,当前低功耗档位为第四档位,如有第一业务删除,那么可从第四档位调整到第五档位,或者其他档位。具体调整到哪个档位可以是预定义的,例如调高2个低功耗档位。
在本申请实施例中,多个设备建立连接形成的系统,从多个设备中可选择一个设备作为主设备,由该主设备决定以N个时间片为一个休眠调度周期。每个设备可独立选择在休眠调度周期上的各个时间片的休眠唤醒状态。每个设备可在休眠调度周期的预设时间片广播自身的休眠唤醒信息,各个设备接收到来自其他设备的PNF,可结合自身的休眠唤醒情况,确定并更新保存的休眠唤醒调度表。这样系统内的全部设备可基于统一的休眠唤醒调度表实现休眠调度。由于系统中的各个设备更新休眠唤醒调度表无需依赖分布式系统中的某一固定设备,例如中心节点,所以本申请实施例提供的休眠调度方法可适用于多对多的连接场景。
基于以上实施例,本申请实施例还提供了一种电子设备,该电子设备例如为手机、或PAD、或便携计算机、或智能音箱等。如图15所示,该电子设备可以包括:显示屏1501;一个或多个处理器1502;一个或多个存储器1503,用于存储一个或多个程序1504;上述各器件可以通过一个或多个通信总线1505连接。所述显示屏1501可以用于显示电子设备中的某个文件的内容;或者所述显示屏1501还可以用于显示电子设备的桌面;或者所述显示屏1501可以用于显示一个图像等等。
其中,当存储器1503中存储的一个或多个程序1504被一个或多个处理器1502执行时,电子设备可以用于执行如图10或13或14所示的实施例或其他相应实施例中的各个步骤。
需要说明的是,本申请实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。本发明实施例中的各功能模块可以集成在一个处理模块中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个模块中。例如,上述实施例中,基本调度模块和动态调度模块可以是同一个模块,也不同的模块。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现,也可以采用硬件结合软件功能模块的形式实现。
本申请实施例中,至少一个”是指一个或者多个,“多个”是指两个或两个以上。“和/或”,描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B的情况,其中A,B可以是单数或者复数。字符“/”一般表示前后关联对象是一种“或”的关系。“以下至少一项(个)”或其类似表达,是指的这些项中的任意组合,包括单项(个)或复数项(个)的任意组合。例如,a,b或c中的至少一项(个),可以表示:a,b,c,a和b,a和c,b和c,或a和b和c,其中a,b,c可以是单个,也可以是多个。
术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。
以及,除非有相反的说明,本申请实施例提及“第一”、“第二”等序数词是用于对多个对象进行区分,不用于限定多个对象的大小、内容、顺序、时序、优先级或者重要程度等。例如,第二文件和第二文件,只是为了区分不同的文件,而并不是表示这两个文件的大小、内容、优先级或者重要程度等的不同。
显然,本领域的技术人员可以对本申请进行各种改动和变型而不脱离本申请的精神和范围。这样,倘若本申请的这些修改和变型属于本申请权利要求及其等同技术的范围之内,则本申请也意图包含这些改动和变型在内。

Claims (19)

  1. 一种休眠调度方法,用于包括第一设备、第二设备和第三设备的分布式系统,其特征在于,包括:
    所述第一设备根据第一场景信息确定有第一业务到来,所述第一场景信息用于指示所述第一业务的业务特征;
    所述第一设备根据所述第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,所述第一休眠唤醒信息用于指示所述第一设备当前在休眠调度周期内的各个时间片上的休眠唤醒情况,所述第二休眠唤醒信息用于指示所述第一设备进行包括所述第一业务在内的业务时,需要满足的所述休眠调度周期内的各个时间片上的休眠唤醒情况;
    所述第一设备将所述第二休眠唤醒信息更新至休眠唤醒调度表,所述休眠唤醒调度表包括所述分布式系统内的各个设备的休眠唤醒情况,所述休眠唤醒调度表用于所述第一设备与所述分布式系统的其他设备进行数据的收发。
  2. 如权利要求1所述的方法,其特征在于,所述方法还包括:
    所述第一设备在所述休眠调度周期内的预设时间片内广播第一定时通知帧PNF,所述第一PNF用于指示所述第二休眠唤醒信息;
    所述第一设备接收来自所述第二设备的第二PNF,所述第二PNF用于指示所述第二设备的休眠唤醒信息;
    所述第一设备根据所述第二PNF更新存储的所述休眠唤醒调度表。
  3. 如权利要求2所述的方法,其特征在于,所述方法还包括:
    所述第一设备确定进入如下的任意一种场景,所述第一设备更新相应链路的休眠唤醒信息,并将相应链路更新后的休眠唤醒信息通知给所述第二设备;
    其中,所述场景包括:保活场景、链路变化场景、紧急业务场景或业务变更场景,所述保活场景用于指示所述第一设备的链路保持连接状态,且所述第一设备与其他设备之间无业务数据交互。
  4. 如权利要求3所述的方法,其特征在于,所述第一设备进入所述保活场景,所述方法还包括:
    所述第一设备查询所缓存的数据量;
    在所述数据量大于或等于第一预设阈值的情况下,所述第一设备将所述第一设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
    所述第一设备向所述第二设备发送第一通知帧,所述第一通知帧携带所述第一链路休眠唤醒信息,以使得所述第二设备根据所述第一链路的休眠唤醒信息将存储的所述第一设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;
    所述第一设备接收来自所述第二设备的第二通知帧,所述第二通知帧携带所述第二链路休眠唤醒信息。
  5. 如权利要求3所述的方法,其特征在于,所述第一设备进入所述链路变化场景,所述方法还包括:
    所述第一设备确定所述第一设备和所述第二设备之间的传输链路的流量大于或等于第二预设阈值,所述第一设备将所述第一设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
    所述第一设备向所述第二设备发送第一通知帧,所述第一通知帧携带所述第一链路休眠唤醒信息,以使得所述第二设备根据所述第一链路的休眠唤醒信息将存储的所述第一设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;
    所述第一设备接收来自所述第二设备的第二通知帧,所述第二通知帧携带所述第二链路休眠唤醒信息。
  6. 如权利要求3所述的方法,其特征在于,所述第一设备进入所述紧急业务场景,所述方法还包括:
    所述第一设备将所述第一设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
    所述第一设备向所述第二设备发送第一通知帧,所述第一通知帧携带所述第一链路休眠唤醒信息,以使得所述第二设备根据所述第一链路的休眠唤醒信息将存储的所述第一设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;
    所述第一设备接收来自所述第二设备的第二通知帧,所述第二通知帧携带所述第二链路休眠唤醒信息。
  7. 如权利要求1-6任一项所述的方法,其特征在于,所述第一设备根据所述第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,包括:
    所述第一设备基于第一预设规则、所述第一场景信息以及所述第一休眠唤醒信息生成所述第二休眠唤醒信息,其中,所述第一预设规则满足如下的一种或多种:
    所述第一设备当前无业务,所述第一设备无法确定进行所述第一业务的休眠唤醒信息,所述第二休眠唤醒信息用于指示所述第一设备在所述休眠调度周期内的各个时间片均处于唤醒状态;或者,
    所述第一设备当前有业务,所述第一休眠唤醒信息指示所述第一设备在所述休眠调度周期内的各个时间片处于唤醒状态,所述第二休眠唤醒信息用于指示所述第一设备在所述休眠调度周期内的各个时间片均处于唤醒状态;或者,
    所述第一设备当前有业务,所述第一休眠唤醒信息指示所述第一设备在所述休眠调度周期内的部分时间片处于唤醒状态,若所述第一设备无法确定进行所述第一业务的休眠唤醒信息,则所述第二休眠唤醒信息用于指示所述第一设备在所述休眠调度周期内的各个时间片均处于唤醒状态;若所述第一设备能够确定进行所述第一业务的休眠唤醒信息,所述第二休眠唤醒信息基于所述第一休眠唤醒信息以及所述第一设备进行所述第一业务的休眠唤醒信息生成。
  8. 如权利要求1-7任一项所述的方法,其特征在于,所述第一场景信息包括如下信息的一种或多种:
    所述第一业务的类型信息、所述第一业务的最低时延容忍值、所述第一业务对应的发包间隔,以及所述第一业务对应的场景档位,其中,所述场景档位用于指示所述第一业务在所述休眠调度周期内的各个时间片的休眠唤醒情况,不同的场景档位对应的休眠唤醒情况不同。
  9. 一种电子设备,其特征在于,所述电子设备为分布式系统中的多个电子设备的任意电子设备,所述分布式系统还包括第二电子设备和第三电子设备,所述电子设备包括存储器及与所述存储器耦合的至少一个处理模块;所述存储器用于存储指令,所述至少一个处理模块用于执行所述指令;其中,所述至少一个处理模块执行所述指令时使得所述电子设 备执行:
    根据第一场景信息确定有第一业务到来,所述第一场景信息用于指示所述第一业务的业务特征;
    根据所述第一场景信息以及第一休眠唤醒信息生成第二休眠唤醒信息,所述第一休眠唤醒信息用于指示所述第一设备当前在休眠调度周期内的各个时间片上的休眠唤醒情况,所述第二休眠唤醒信息用于指示所述第一设备进行包括所述第一业务在内的业务时,需要满足的所述休眠调度周期内的各个时间片上的休眠唤醒情况;
    将所述第二休眠唤醒信息更新至休眠唤醒调度表,所述休眠唤醒调度表包括所述分布式系统内的各个设备的休眠唤醒情况,所述休眠唤醒调度表用于所述电子设备与所述分布式系统中的其他设备进行数据的收发。
  10. 如权利要求9所述的电子设备,其特征在于,所述电子设备还包括收发模块,其中,
    所述收发模块用于:在所述休眠调度周期内的预设时间片内广播第一定时通知帧PNF,以及接收来自所述第二电子设备的第二PNF,所述第一PNF用于指示所述第二休眠唤醒信息,所述第二PNF用于指示所述第二电子设备的休眠唤醒信息;
    所述处理模块还用于:根据所述第二PNF更新存储的所述休眠唤醒调度表。
  11. 如权利要求10所述的电子设备,其特征在于,所述处理模块还用于:
    确定进入如下的任意一种场景,更新相应链路的休眠唤醒信息,并将相应链路更新后的休眠唤醒信息通知给所述第二设备;
    其中,所述场景包括:保活场景、链路变化场景、紧急业务场景或业务变更场景,所述保活场景用于指示所述第一设备的链路保持连接状态,且所述第一设备与其他设备之间无业务数据交互。
  12. 如权利要求11所述的电子设备,其特征在于,所述电子设备进入所述保活场景,其中,所述处理模块还用于:查询所缓存的数据量,在所述数据量大于或等于第一预设阈值的情况下,将所述电子设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
    所述收发模块还用于:向所述第二设备发送第一通知帧,所述第一通知帧携带所述第一链路休眠唤醒信息,以使得所述第二设备根据所述第一链路的休眠唤醒信息将存储的所述电子设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;并接收来自所述第二设备的第二通知帧,所述第二通知帧携带所述第二链路休眠唤醒信息。
  13. 如权利要求11所述的电子设备,其特征在于,所述电子设备进入所述链路变化场景,所述处理模块还用于:确定所述电子设备和所述第二设备之间的传输链路的流量大于或等于第二预设阈值,将所述电子设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
    所述收发模块还用于:向所述第二设备发送第一通知帧,所述第一通知帧携带所述第一链路休眠唤醒信息,以使得所述第二设备根据所述第一链路的休眠唤醒信息将存储的所述电子设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;并接收来自所述第二设备的第二通知帧,所述第二通知帧携带所述第二链路休眠唤醒信息。
  14. 如权利要求11所述的电子设备,其特征在于,所述电子设备进入所述紧急业务场 景,所述处理模块还用于:将所述电子设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第一链路休眠唤醒信息;
    所述收发模块还用于:向所述第二设备发送第一通知帧,所述第一通知帧携带所述第一链路休眠唤醒信息,以使得所述第二设备根据所述第一链路的休眠唤醒信息将存储的所述电子设备和所述第二设备之间的传输链路的休眠唤醒信息更新为第二链路休眠唤醒信息;并接收来自所述第二设备的第二通知帧,所述第二通知帧携带所述第二链路休眠唤醒信息。
  15. 如权利要求9-14任一项所述的电子设备,其特征在于,所述处理模块具体用于:
    基于第一预设规则、所述第一场景信息以及所述第一休眠唤醒信息生成所述第二休眠唤醒信息,其中,所述第一预设规则满足如下的一种或多种:
    所述电子设备当前无业务,所述电子设备无法确定进行所述第一业务的休眠唤醒信息,所述第二休眠唤醒信息用于指示所述电子设备在所述休眠调度周期内的各个时间片均处于唤醒状态;或者,
    所述电子设备当前有业务,所述第一休眠唤醒信息指示所述电子设备在所述休眠调度周期内的各个时间片处于唤醒状态,所述第二休眠唤醒信息用于指示所述电子设备在所述休眠调度周期内的各个时间片均处于唤醒状态;或者,
    所述电子设备当前有业务,所述第一休眠唤醒信息指示所述电子设备在所述休眠调度周期内的部分时间片处于唤醒状态,若所述电子设备无法确定进行所述第一业务的休眠唤醒信息,则所述第二休眠唤醒信息用于指示所述电子设备在所述休眠调度周期内的各个时间片均处于唤醒状态;若所述电子设备能够确定进行所述第一业务的休眠唤醒信息,所述第二休眠唤醒信息基于所述第一休眠唤醒信息以及所述电子设备进行所述第一业务的休眠唤醒信息生成。
  16. 如权利要求9-15任一项所述的电子设备,其特征在于,所述第一场景信息包括如下信息的一种或多种:
    所述第一业务的类型信息、所述第一业务的最低时延容忍值、所述第一业务对应的发包间隔,以及所述第一业务对应的场景档位,其中,所述场景档位用于指示所述第一业务在所述休眠调度周期内的各个时间片的休眠唤醒情况,不同的场景档位对应的休眠唤醒情况不同。
  17. 一种分布式系统,其特征在于,包括多个如权利要求9-16任一项的电子设备。
  18. 一种芯片,其特征在于,所述芯片包括处理模块和接口,所述接口用于与所述处理模块通信以及接收来自其他设备的信息;所述处理模块用于执行如权利要求1-8任一项所述的方法。
  19. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有计算机可执行指令,所述计算机可执行指令在被电子设备调用时,使所述电子设备执行如权利要求1至8任一项所述的方法。
PCT/CN2022/085845 2021-04-30 2022-04-08 一种休眠调度方法及设备 WO2022228085A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
EP22794556.5A EP4311314A1 (en) 2021-04-30 2022-04-08 Sleep scheduling method and device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110480045.3A CN115278831A (zh) 2021-04-30 2021-04-30 一种休眠调度方法及设备
CN202110480045.3 2021-04-30

Publications (1)

Publication Number Publication Date
WO2022228085A1 true WO2022228085A1 (zh) 2022-11-03

Family

ID=83745503

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/085845 WO2022228085A1 (zh) 2021-04-30 2022-04-08 一种休眠调度方法及设备

Country Status (3)

Country Link
EP (1) EP4311314A1 (zh)
CN (1) CN115278831A (zh)
WO (1) WO2022228085A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116736076A (zh) * 2023-05-12 2023-09-12 珠海妙存科技有限公司 芯片休眠状态检测方法和系统、电子设备和存储介质

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115686383B (zh) * 2022-12-30 2023-04-18 摩尔线程智能科技(北京)有限责任公司 存储器的控制方法和控制器以及芯片系统
CN116132203B (zh) * 2023-02-02 2023-07-21 卧安科技(深圳)有限公司 智能家居场景的设备唤醒控制方法、物联网设备及系统
CN116501475B (zh) * 2023-06-21 2023-10-20 杭州炬华科技股份有限公司 线程调度方法、系统以及介质

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040230638A1 (en) * 2003-05-01 2004-11-18 Krishna Balachandran Adaptive sleeping and awakening protocol for an energy-efficient adhoc network
CN101404602A (zh) * 2008-11-04 2009-04-08 南京航空航天大学 一种适用于多跳ad hoc网络的DCF协议节点自适应休眠机制
CN109729550A (zh) * 2018-12-11 2019-05-07 深圳市联智物联网科技有限公司 一种适用于半双工无线通信系统的节能唤醒方法
CN109729575A (zh) * 2018-12-27 2019-05-07 中国移动通信集团江苏有限公司 工作模式确定的方法、装置、设备及介质
US20190320602A1 (en) * 2018-04-23 2019-10-24 Rachio, Inc. Low power data transmission for sprinkler systems
CN111406426A (zh) * 2017-12-04 2020-07-10 赛普拉斯半导体公司 包括蓝牙收发器的并置收发器的业务流共存的实现
CN112533269A (zh) * 2019-09-17 2021-03-19 华为技术有限公司 一种数据收发方法、电子设备与计算机可读存储介质

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040230638A1 (en) * 2003-05-01 2004-11-18 Krishna Balachandran Adaptive sleeping and awakening protocol for an energy-efficient adhoc network
CN101404602A (zh) * 2008-11-04 2009-04-08 南京航空航天大学 一种适用于多跳ad hoc网络的DCF协议节点自适应休眠机制
CN111406426A (zh) * 2017-12-04 2020-07-10 赛普拉斯半导体公司 包括蓝牙收发器的并置收发器的业务流共存的实现
US20190320602A1 (en) * 2018-04-23 2019-10-24 Rachio, Inc. Low power data transmission for sprinkler systems
CN109729550A (zh) * 2018-12-11 2019-05-07 深圳市联智物联网科技有限公司 一种适用于半双工无线通信系统的节能唤醒方法
CN109729575A (zh) * 2018-12-27 2019-05-07 中国移动通信集团江苏有限公司 工作模式确定的方法、装置、设备及介质
CN112533269A (zh) * 2019-09-17 2021-03-19 华为技术有限公司 一种数据收发方法、电子设备与计算机可读存储介质

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116736076A (zh) * 2023-05-12 2023-09-12 珠海妙存科技有限公司 芯片休眠状态检测方法和系统、电子设备和存储介质
CN116736076B (zh) * 2023-05-12 2024-04-09 珠海妙存科技有限公司 芯片休眠状态检测方法和系统、电子设备和存储介质

Also Published As

Publication number Publication date
CN115278831A (zh) 2022-11-01
EP4311314A1 (en) 2024-01-24

Similar Documents

Publication Publication Date Title
WO2022228085A1 (zh) 一种休眠调度方法及设备
WO2021185141A1 (zh) Wi-Fi Aware的建链方法、系统、电子设备和存储介质
WO2021143541A1 (zh) 无线通信方法和具有无线通信功能的设备
WO2021175300A1 (zh) 数据传输方法、装置、电子设备和可读存储介质
WO2021052245A1 (zh) 一种数据收发方法、电子设备与计算机可读存储介质
EP4084486A1 (en) Cross-device content projection method, and electronic device
WO2022228083A1 (zh) 一种多设备建立连接的方法及设备
WO2021143314A1 (zh) 一种降低移动终端功耗的方法及移动终端
WO2021115193A1 (zh) 一种设备组网方法、电子设备及系统
WO2022017474A1 (zh) 任务处理方法及相关装置
WO2022143508A1 (zh) 一种近场中传输数据的方法、设备及系统
WO2022228051A1 (zh) 一种设备组网方法、电子设备及存储介质
WO2023179731A1 (zh) 休眠唤醒方法及电子设备
WO2023025191A1 (zh) 通信方法及电子设备
WO2022012356A1 (zh) 数据传输方法和装置
CN115220881A (zh) 进程管理方法、电子设备、进程管理系统以及存储介质
WO2022237458A1 (zh) 一种资源管理方法及设备
CN113490191B (zh) 蓝牙通信方法及其介质和电子设备
WO2023035837A1 (zh) 数据同步方法及设备
RU2803186C1 (ru) Способ беспроводной связи и устройство, имеющее функцию беспроводной связи
WO2023039890A1 (zh) 视频传输的方法和电子设备
WO2023005783A1 (zh) 数据处理方法及电子设备
WO2023138533A1 (zh) 业务协同方法、电子设备、可读存储介质和芯片系统
WO2022206603A1 (zh) 通信资源协作方法及电子设备
WO2024109623A1 (zh) 一种待机方法及装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22794556

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2022794556

Country of ref document: EP

WWE Wipo information: entry into national phase

Ref document number: 18288665

Country of ref document: US

ENP Entry into the national phase

Ref document number: 2022794556

Country of ref document: EP

Effective date: 20231019

NENP Non-entry into the national phase

Ref country code: DE