A negotiation-based collaborative sleep and wake-up management method and system for multiple audio devices
Through unified monitoring and command coordination by the main control device, the multi-audio device system achieves consistency in state and energy consumption optimization during collaborative sleep and wake-up, solves the problem of inconsistent wake-up caused by independent device operation, and improves user experience and device battery life.
Patent Information
- Application Number
- CN202611364891.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-03
- Publication Date
- 2026-11-17
AI Technical Summary
In multi-audio device systems, the independent sleep and wake-up of devices leads to uncontrollable states, inconsistent wake-up times, resulting in sound misalignment, delays, or popping sounds. Furthermore, the wake-up process is time-consuming, impacting the user experience.
A master control device is introduced to uniformly monitor audio signals, generate coordinated sleep and wake-up commands, maintain device connection through low-power monitoring, ensure consistent device status, and synchronously play audio data after the slave device is ready.
It achieves state coordination and power consumption management of multiple audio devices, eliminates sound misalignment and delay, shortens wake-up recovery time, reduces overall system standby power consumption, and extends device battery life.
Smart Images

Figure CN123124061A_ABST
Abstract
Description
Technical Field
[0001] This specification relates to the field of audio device control technology, and in particular to a negotiated collaborative sleep and wake-up management method and system for multiple audio devices. Background Technology
[0002] With the rapid development of wireless audio technology, collaborative systems composed of multiple audio devices have been widely used in the consumer electronics field. For example, multi-room speaker systems can enable synchronized music playback in different rooms of a home; True Wireless Stereo (TWS) earbuds provide an immersive stereo experience through wireless connection between the left and right ears; and the combination of a soundbar and a wireless subwoofer constitutes a common home theater audio system. In these systems, multiple audio devices typically form a device group, communicating with each other via Bluetooth, Wi-Fi, or proprietary wireless protocols to collaboratively play signals from the same audio source.
[0003] To reduce system power consumption, extend device battery life, or reduce standby power consumption, existing multi-audio device systems generally incorporate sleep and wake-up mechanisms. In traditional implementations, each audio device in a device group typically performs silent detection of the audio signal independently and executes sleep or wake-up operations independently based on its detection results. For example, when an audio device detects an audio input interruption that lasts for a period of time, it will automatically shut down its amplifier or digital signal processing module to enter a low-power mode; when the audio signal is reintroduced, the audio device will automatically resume normal operation.
[0004] However, due to differences in detection sensitivity, algorithm thresholds, or hardware among different audio devices, a chaotic situation can easily arise where some audio devices within a device group have entered sleep mode while others are still operating normally, leading to an uncontrollable overall system state. When the audio signal recovers, each audio device wakes up independently, but due to differences in wake-up time, hardware initialization speed, and link recovery speed among different audio devices, the audio playback start time of each device is inconsistent, resulting in perceptible sound misalignment, delay, or popping sounds, severely impacting the user's listening experience. Furthermore, after some audio devices enter deep sleep mode, their wireless communication modules also shut down. Upon recovery from sleep mode, they need to re-establish network connections with other audio devices in the group (such as re-pairing and handshaking), a process that takes a long time, causing users to wait an extended period before audio playback resumes.
[0005] Therefore, we hope to propose a negotiation-based collaborative sleep and wake-up management method and system for multiple audio devices to improve the state coordination and energy consumption management effect in collaborative scenarios of multiple audio devices. Summary of the Invention
[0006] This specification provides one or more embodiments of a negotiated collaborative sleep and wake-up management method for multiple audio devices. The method, executed by a processor, includes: determining a master device and multiple slave devices in an audio device group; the master device buffering audio data; controlling the master device to monitor audio signals; generating a collaborative sleep command in response to the audio signals meeting a preset mute condition; sending the collaborative sleep command to the multiple slave devices, controlling the multiple slave devices to enter a sleep state and return a sleep confirmation signal to the master device; upon receiving all the sleep confirmation signals, controlling the master device to enter a low-power monitoring state to monitor the audio signals and sending heartbeat signals to the multiple slave devices in the sleep state; waking up the master device and sending a collaborative wake-up command to the multiple slave devices in response to the audio signals meeting a preset wake-up condition; and controlling the audio device group to synchronously play the audio data in response to the multiple slave devices being in a ready state.
[0007] This specification provides one or more embodiments of a negotiated collaborative sleep and wake-up management system for multiple audio devices. The system includes: a determination module configured to: determine a master control device and multiple slave devices in an audio device group, wherein the master control device caches audio data; a generation module configured to: control the master control device to monitor audio signals, and generate a collaborative sleep command in response to the audio signals meeting a preset mute condition; a control module configured to: send the collaborative sleep command to the multiple slave devices, control the multiple slave devices to enter a sleep state and return a sleep confirmation signal to the master control device; upon receiving all the sleep confirmation signals, control the master control device to enter a low-power listening state to monitor the audio signals and send heartbeat signals to the multiple slave devices in the sleep state; in response to the audio signals meeting a preset wake-up condition, wake up the master control device and send a collaborative wake-up command to the multiple slave devices; and in response to the multiple slave devices being in a ready state, control the audio device group to synchronously play the audio data. Attached Figure Description
[0008] This specification will be further described by way of exemplary embodiments, which will be described in detail with reference to the accompanying drawings. These embodiments are not limiting; in these embodiments, the same reference numerals denote the same structures, wherein:
[0009] Figure 1 This is a schematic diagram illustrating an application scenario of a negotiation-based collaborative sleep and wake-up management system for multiple audio devices, based on some embodiments of this specification. Figure 2 This is an exemplary block diagram of a negotiated collaborative sleep and wake-up management system for multiple audio devices, as shown in some embodiments of this specification. Figure 3 This is an exemplary flowchart of a negotiated collaborative sleep and wake-up management method for multiple audio devices, as shown in some embodiments of this specification. Figure 4 This is an exemplary flowchart illustrating the re-electing of the master control device according to some embodiments of this specification; Figure 5 This is an exemplary schematic diagram illustrating the sending of a coordinated wake-up command according to some embodiments of this specification; Figure 6 This is an exemplary schematic diagram of a re-electing master control device according to some embodiments of this specification. Detailed Implementation
[0010] To more clearly illustrate the technical solutions of the embodiments in this specification, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are merely some examples or embodiments of this specification. For those skilled in the art, these drawings can be applied to other similar scenarios without creative effort. Unless obvious from the context or otherwise specified, the same reference numerals in the drawings represent the same structures or operations.
[0011] The negotiated collaborative sleep and wake-up management method and system for multiple audio devices disclosed in some embodiments of this specification have significant advantages in energy efficiency optimization and synchronous collaboration. They can be widely applied to scenarios such as smart home theaters (multi-channel speaker collaborative sleep and wake-up, synchronized audio and video playback), smart conference systems (on-demand sleep and fast wake-up of multiple microphone and speaker arrays), in-vehicle multi-zone entertainment systems (balancing energy management and driving experience), and Internet of Things (IoT) distributed audio terminals (low-power standby and group synchronous response). They can effectively solve problems such as high standby power consumption of multiple devices, inconsistent sleep and wake-up timing leading to playback asynchrony, and lack of a unified collaborative scheduling mechanism.
[0012] Figure 1 This is a schematic diagram illustrating an application scenario of a negotiated collaborative sleep and wake-up management system for multiple audio devices, based on some embodiments of this specification.
[0013] In some embodiments, such as Figure 1 As shown, the application scenario of the multi-audio device negotiation-based collaborative sleep and wake-up management system (hereinafter referred to as application scenario 100) may include user terminal 110, network 120, processor 130, memory 140 and audio device 150.
[0014] In some embodiments, application scenario 100 may include multiple audio device collaborative playback scenarios such as home theaters, Bluetooth headsets, smart homes, and conference systems. For example, in a home theater scenario, when a user pauses a movie or the playback enters a long silent segment, the main control speaker can automatically detect the continuous silence and coordinate all surround speakers to enter a sleep state while maintaining a weak heartbeat monitoring link; when a valid audio signal is detected to be restored, the main control device quickly wakes up all speakers and synchronously resumes playback, achieving a balance between energy saving and instant response. In a Bluetooth headset scenario, the left and right earbuds and the charging case can negotiate a sleep state through a sleep mechanism, collaboratively entering a sleep state when the user removes the earbuds or when there is no audio output for a long time, and quickly waking up synchronously when the user puts them back on or when a ringtone sounds, thereby extending standby time and ensuring a good call experience. In a smart home scenario, smart speakers in multiple rooms can negotiate to enter a sleep state at night when there is no music playback, with only the main control device maintaining a low-power monitoring state. When the user uses a voice command or restarts music playback, the system can wake up all smart speakers in milliseconds, achieving seamless restoration of audio throughout the house.
[0015] User terminal 110 can be used to interact with users. Users can be one or more users, such as users directly using a negotiated collaborative sleep / wake management system for multiple audio devices, or other related users. In some embodiments, user terminal 110 may include a mobile phone 111, tablet 112, and computer 113, etc. In one embodiment, user terminal 110 can establish a connection with audio device 150 via wireless communication (such as Bluetooth). In some embodiments, user terminal 110 can be configured to input audio data.
[0016] Network 120 may include any suitable network capable of facilitating information and / or data exchange. In some embodiments, at least one component of application scenario 100 (e.g., user terminal 110, processor 130, memory 140, and audio device 150, etc.) may exchange information and / or data with at least one other component in application scenario 100 via network 120. For example, processor 130 may retrieve audio data, preset mute conditions, preset wake-up conditions, etc., from memory 140 via network 120.
[0017] In some embodiments, network 120 can be any one or more of wired or wireless networks. For example, network 120 may include cable networks, fiber optic networks, telecommunications networks, cable connections, or any combination thereof. Network connections between components may employ one or more of the above methods. In some embodiments, the network may be a point-to-point, shared, centralized, or other topologies, or a combination of multiple topologies. In some embodiments, network 120 may include one or more network access points.
[0018] Processor 130 can process data and / or information obtained from user terminal 110, network 120, memory 140, audio device 150, or other components of application scenario 100. Based on this data, information, and / or processing results, the processor can execute program instructions to perform one or more functions described in this specification. In some embodiments, processor 130 can determine a master device and multiple slave devices in an audio device group, with the master device buffering audio data; control the master device to monitor audio signals, and generate a cooperative sleep command in response to the audio signal meeting a preset mute condition; send the cooperative sleep command to multiple slave devices, control the multiple slave devices to enter a sleep state, and return a sleep confirmation signal to the master device; upon receiving all sleep confirmation signals, control the master device to enter a low-power listening state to monitor audio signals and send heartbeat signals to the multiple slave devices in the sleep state; wake up the master device and send a cooperative wake-up command to the multiple slave devices in response to the audio signal meeting a preset wake-up condition; and control the audio device group to synchronously play audio data in response to the multiple slave devices being in a ready state.
[0019] In some embodiments, processor 130 may be a single server or a group of servers. The server group may be centralized or distributed. In some embodiments, processor 130 may include one or more sub-processors (e.g., a single-core processor or a multi-core processor). By way of example only, the processor may include a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), a Neural-network Processing Unit (NPU), an Application-Specific Integrated Circuit (ASIC), or any combination thereof. In some embodiments, processor 130 may be local or remote. In some embodiments, processor 130 may be implemented on a cloud platform. For example, the cloud platform may include a private cloud, a public cloud, a hybrid cloud, a community cloud, a distributed cloud, an inter-cloud cloud, a multi-cloud, or any combination thereof.
[0020] The memory 140 may store data, instructions, and / or any other information generated during system operation. In some embodiments, the memory 140 may store data and / or information (e.g., audio data, co-sleep instructions, co-wake instructions, etc.) acquired by the user terminal 110, the processor 130, and the audio device 150.
[0021] In some embodiments, memory 140 may store data and / or instructions used by processor 130 to perform or use in order to complete the exemplary methods described herein. For example, memory 140 may store cooperative hibernation instructions generated by processor 130.
[0022] In some embodiments, memory 140 may include one or more storage units, each of which may be a separate device or part of another device. In some embodiments, memory 140 may be local memory or cloud storage. In some embodiments, storage device 140 may include random access memory (RAM), read-only memory (ROM), mass storage, or any combination thereof. In some embodiments, memory 140 may be part of user terminal 110, processor 130, and / or audio device 150.
[0023] Audio device 150 can perform functions such as audio data processing and / or output. An audio device refers to an electronic physical device capable of inputting, outputting, processing, or playing audio signals. For example, audio device 150 includes a combination of one or more devices with sound playback functions, such as a speaker 151, Bluetooth headset 152, and smart speaker 153. In some embodiments, audio device 150 can be an audio device embedded in user terminal 110.
[0024] For further explanation of the above content, please refer to Figures 2 to 6 And its related descriptions.
[0025] It should be noted that the above description of application scenario 100 is for illustrative purposes only and is not intended to limit the scope of this specification. Various variations and modifications can be made based on this specification by those skilled in the art. However, these variations and modifications do not depart from the scope of this specification.
[0026] Figure 2 This is an exemplary block diagram of a negotiated, collaborative sleep and wake-up management system for multiple audio devices, as shown in some embodiments of this specification. Figure 2 As shown, the multi-audio device negotiation-based collaborative sleep and wake-up management system 200 may include: a determination module 210, a generation module 220, and a control module 230.
[0027] In some embodiments, the determining module 210 is configured to determine a master device and a plurality of slave devices in an audio device group.
[0028] In some embodiments, the determining module 210 is further configured to: construct and maintain a master control candidate list based on the device status of each audio device in the audio device group, the master control candidate list including multiple candidate devices; in response to the master control device meeting a preset replacement condition, control the current master control device to send a takeover notice to the first candidate device; in response to receiving a takeover confirmation returned by the first candidate device, broadcast a master control switching notification and start a preset protection window; and in response to not receiving a takeover confirmation within a first preset time period, control the current master control device to terminate the replacement process and revert to the original working state, and send a takeover notice to the next candidate device of the first candidate device.
[0029] In some embodiments, the generation module 220 is configured to: control the master device to monitor the audio signal, and generate a cooperative sleep command in response to the audio signal meeting a preset mute condition.
[0030] In some embodiments, the control module 230 is configured to: send a coordinated sleep command to multiple slave devices, control the multiple slave devices to enter a sleep state and return a sleep confirmation signal to the master device; upon receiving all sleep confirmation signals, control the master device to enter a low-power monitoring state to monitor audio signals and send heartbeat signals to the multiple slave devices in the sleep state; wake up the master device and send a coordinated wake-up command to the multiple slave devices in response to the audio signal meeting a preset wake-up condition; and control the audio device group to synchronously play audio data in response to the multiple slave devices being in a ready state.
[0031] In some embodiments, the control module 230 is further configured to: acquire latency parameters of multiple slave devices; determine the sending time of sending a coordinated wake-up command to the multiple slave devices based on the latency parameters; and control the multiple slave devices to synchronously complete initialization and play audio data based on the sending time.
[0032] In some embodiments, the control module 230 is further configured to: after sending a coordinated wake-up command, in response to not receiving a readiness confirmation from the first slave device within a second preset time period, mark the first slave device as offline and control the online slave device to play; and when the first slave device in the offline state recovers, control the first slave device to listen to the synchronization timestamp sent by the master device and receive audio data, and play it on the network after alignment.
[0033] In some embodiments, the control module 230 is further configured to: in a low-power listening state, in response to any slave device not receiving a heartbeat signal within a third preset time period, send a probe request to the master device; and in response to the probe request not being responded to, re-elect the master device through an intra-group negotiation mechanism.
[0034] In some embodiments, all or some of the above modules may be integrated on the processor 130. The system 200 may also be integrated into an audio device group.
[0035] For further explanation of each of the above modules, please refer to [link / reference]. Figures 3-6 And its related descriptions.
[0036] It should be noted that the above description of system 200 and its modules is for convenience only and should not be construed as limiting this specification to the scope of the illustrated embodiments. It is understood that those skilled in the art, after understanding the principles of this system, may arbitrarily combine the various modules or construct subsystems connected to other modules without departing from these principles. In some embodiments, Figure 2 The determining module 210, generating module 220, and control module 230 disclosed herein can be different modules within a single system, or a single module can implement the functions of two or more of the aforementioned modules. For example, the modules can share a single storage module, or each module can have its own separate storage module. Such variations are all within the scope of protection of this specification.
[0037] Figure 3 This is an exemplary flowchart illustrating a negotiated, collaborative sleep and wake-up management method for multiple audio devices according to some embodiments of this specification. Figure 3 As shown, process 300 includes steps 310-360. In some embodiments, process 300 may be executed by a processor.
[0038] Step 310: Identify the master device and multiple slave devices in the audio device group, and have the master device cache the audio data.
[0039] An audio device group refers to a collection of multiple audio devices connected via wireless or wired communication links, capable of working collaboratively (e.g., playing the same audio source together). An audio device group may include a master device and multiple slave devices. For more information on audio devices, see [link to documentation]. Figure 1 And its related descriptions.
[0040] The master control device refers to the audio equipment that holds a dominant and controlling position in the audio equipment group and is responsible for signal monitoring, decision generation, and instruction distribution.
[0041] A slave device refers to an audio device in an audio device group that is in a passive response position, executes control commands issued by the master device, and reports its own status.
[0042] In some embodiments, the processor can determine the master device and multiple slave devices in an audio device group in various ways. For example, the audio device group establishes a mesh topology via a built-in Bluetooth RF module. After the mesh topology is established, the processor controls multiple audio devices to broadcast data packets containing their own hardware attributes via the Bluetooth Low Energy link in the mesh topology. If the processor detects that an audio device has established a connection with a Bluetooth audio source, it determines that audio device as the master device, and the remaining audio devices as slave devices. If no audio device is connected to a Bluetooth audio source, the processor controls the main chips of multiple audio devices to read their own power levels using local coulomb counters and perform a comprehensive score based on the remaining computing resources of the chips. The processor determines the audio device with the highest score as the master device, and that audio device broadcasts a role declaration frame through the mesh topology, while the remaining audio devices are determined as slave devices.
[0043] As an example only, in a system consisting of a main soundbar and two surround speakers, after the mesh topology is established, the processor detects that the main soundbar has established a connection with the Bluetooth audio source, and then determines the main soundbar as the master device and the two surround speakers as slave devices.
[0044] Audio data refers to sound information data represented in digital form that can be cached, transmitted, or played. For example, audio data can be a sampled and encoded sound data stream.
[0045] In some embodiments, audio data can be input to the main control device via a user terminal.
[0046] In some embodiments, a circular buffer is established in the running memory of the host device. The processor can activate the direct memory access controller within the host device to write the input audio data into the circular buffer in real time for caching and record the playback timestamp of the audio data. The playback timestamp refers to the absolute point in time when the audio data is played. The playback timestamp can be represented by the system clock of the host device.
[0047] Step 320: Monitor the audio signal and generate a coordinated sleep command in response to the audio signal meeting the preset mute condition.
[0048] An audio signal is an electrical signal or audio information stream used to characterize sound information. For example, an audio signal can be an analog audio voltage signal or a digital audio stream.
[0049] In some embodiments, the processor can sample the analog audio input port within a sampling period using the analog-to-digital converter built into the host device to obtain an audio signal.
[0050] A preset mute condition refers to the criteria used to determine that an audio signal is in a state of no effective sound. For example, a preset mute condition could be that the voltage amplitude of the audio signal is lower than a preset amplitude threshold and the mute duration reaches a preset duration. The voltage amplitude refers to the statistical value (such as the root mean square value) of the voltage amplitude corresponding to multiple sampling points of the audio signal within the sampling period. In some embodiments, the preset amplitude threshold and preset duration can be preset based on experience and stored in the memory of the main control device. For example, the preset amplitude threshold is 5 millivolts and the preset duration is 300 seconds.
[0051] A coordinated sleep command is a control instruction generated and distributed by the master device to notify multiple slave devices to enter sleep mode in sequence. For example, a coordinated sleep command may include a sleep control code.
[0052] In some embodiments, the processor can control the host device to monitor the audio signal and generate a cooperative sleep command in various ways in response to the audio signal meeting a preset mute condition. For example, the processor controls the host device to monitor the real-time input audio signal, calculates the root mean square value of the audio signal as the voltage amplitude in each sampling period, and compares the voltage amplitude with a preset amplitude threshold. If the voltage amplitude is lower than the preset amplitude threshold, the processor starts a built-in mute timer in the host device and uses the accumulated time of the mute timer as the mute duration. When the mute duration reaches a preset duration, the processor generates a cooperative sleep command.
[0053] As an example only, in a system consisting of a main soundbar speaker and two surround speakers, when audio data stops playing, the main soundbar speaker monitors the audio signal and generates a coordinated sleep command when it detects that the voltage amplitude of the audio signal is below five millivolts for 300 consecutive seconds.
[0054] Step 330: Send a coordinated sleep command to multiple slave devices to control multiple slave devices to enter sleep mode and return a sleep confirmation signal.
[0055] Hibernation mode refers to an energy-saving operating state in which the audio equipment group shuts down the main processing chip and audio power amplifier circuit, and only keeps the low-power monitoring module running.
[0056] A sleep confirmation signal is a signal used by a slave device to send a confirmation result to the master device after the slave device has completed sleep preparation or entered sleep mode.
[0057] In some embodiments, the processor can send coordinated sleep commands to multiple slave devices in various ways to control the multiple slave devices to enter a sleep state and return a sleep confirmation signal. For example, the processor can send coordinated sleep commands to multiple slave devices via Bluetooth Low Energy broadcast; after receiving the coordinated sleep commands, the multiple slave devices call their own microcontrollers to sequentially disconnect the built-in audio amplifier power supply and turn off the main processor clock source, thereby entering a sleep state, and unicast a sleep confirmation signal back to the master device via a wireless module.
[0058] As an example only, in a system consisting of a main soundbar and two surround speakers, the main soundbar sends a coordinated sleep command to the two surround speakers. After receiving the coordinated sleep command, the two surround speakers sequentially disconnect the power supply of their built-in audio amplifiers and turn off the main processor clock source, thereby entering sleep mode, and unicast a sleep confirmation signal back to the main soundbar via a wireless module.
[0059] Step 340: Upon receiving sleep confirmation signals from multiple slave devices, control the master device to enter a low-power listening state to monitor audio signals and send heartbeat signals to the multiple slave devices in sleep state.
[0060] Low-power monitoring mode refers to an energy-saving operating mode in which the main control device shuts down the main processing chip and audio power amplifier circuit, while keeping only the monitoring circuit and communication receiving module active.
[0061] A heartbeat signal is a communication signal that the master control device periodically broadcasts while in monitoring mode to maintain the link connection and announce its own liveness.
[0062] In some embodiments, upon receiving all sleep confirmation signals, the processor can control the master device to enter a low-power monitoring state to monitor audio signals and send heartbeat signals to multiple sleep-state slave devices through various methods. For example, the processor records the flag bits of the sleep confirmation signals of all slave devices through the status register of the master device; when all flag bits are set, the processor controls the master device to shut down the power amplifier power supply via the control bus and disconnect the operating voltage of the master processor, maintaining only the analog comparator circuit operating at microamplitude current and the low-power wireless coprocessor, thereby enabling the master device to enter a low-power monitoring state to monitor audio signals. Simultaneously, the processor controls the wireless coprocessor to send heartbeat signals to the multiple sleep-state slave devices at a preset period. The preset period can be set empirically.
[0063] As an example, in a system consisting of a soundbar main speaker and two surround speakers, after receiving sleep confirmation signals from the two surround speakers, the soundbar main speaker turns off the power amplifier and disconnects the operating voltage of the main processor, maintaining only the analog comparator circuit running at microamplitude current and the low-power wireless coprocessor, thereby entering a low-power monitoring state to monitor audio signals, and periodically sending heartbeat signals to the two sleep surround speakers through the wireless coprocessor.
[0064] Step 350: In response to the audio signal meeting the preset wake-up conditions, wake up the master control device and send a collaborative wake-up command to multiple slave devices.
[0065] Preset wake-up conditions refer to pre-defined trigger conditions used to determine when an audio device group should exit sleep mode and resume operation. For example, preset wake-up conditions could be that the energy of the audio signal exceeds a preset energy threshold or the voltage amplitude exceeds a preset amplitude threshold. The preset energy threshold and preset amplitude threshold can be set based on experience.
[0066] The collaborative wake-up command refers to the control command issued by the master control device to notify multiple slave devices to exit the hibernation state and resume full-link collaborative operation.
[0067] When the audio signal meets the preset wake-up conditions, the processor can first wake up the main control device's processor, DSP and other modules to restore full working capabilities.
[0068] In some embodiments, the processor monitors the voltage amplitude of the audio signal at the analog audio input port in real time using an analog comparator. When the voltage amplitude exceeds a preset amplitude threshold, the analog comparator outputs a level signal to trigger a hardware interrupt, thereby waking up the master device. After being woken up, the master device immediately sends a coordinated wake-up command to multiple slave devices via a wireless coprocessor.
[0069] For example, in a system consisting of a main soundbar and two surround speakers, when audio data is re-input, the voltage amplitude of the audio signal exceeds five millivolts. The analog comparator wakes up the main soundbar, and the main soundbar then sends a coordinated wake-up command to the two surround speakers.
[0070] In some embodiments, the processor acquires latency parameters of multiple slave devices; based on the latency parameters, determines the transmission time for sending a coordinated wake-up command to the multiple slave devices; and based on the transmission time, controls the multiple slave devices to synchronously complete initialization and play audio data. For more information on this section, see [link to relevant documentation]. Figure 5 And its related descriptions.
[0071] Step 360: In response to multiple slave devices being in a ready state, control the audio device group to synchronously play audio data.
[0072] The ready state refers to the state in which the device is ready to participate in synchronous audio playback after completing initialization and link establishment following wake-up.
[0073] Synchronized playback refers to the coordinated playback state in which a group of audio devices start at the same physical moment and align to output the same audio data.
[0074] In some embodiments, after sending a coordinated wake-up command, the master device receives ready information returned by multiple slave devices. When the master device confirms that all slave devices are ready, the processor reads the cached audio data and playback timestamp from the master device's circular buffer. Based on a preset delay table, the processor determines the latency parameters of each slave device; it subtracts the latency parameters of each slave device from the playback timestamp to obtain the synchronization timestamp for each slave device, and broadcasts the audio data and synchronization timestamp to the multiple slave devices. After receiving their respective synchronization timestamps, the multiple slave devices start their local audio hardware controllers based on the synchronized timestamps to control the audio device group to play audio data synchronously. The preset delay table may include multiple sets of correspondences between slave devices and latency parameters. The preset delay table can be set empirically. For more information on latency parameters, see [link to relevant documentation]. Figure 5 And its related descriptions.
[0075] Synchronization timestamps refer to the timestamp at which a device begins playing audio data. Synchronization timestamps provide a unified time reference for the master device and multiple slave devices, enabling audio device groups to coordinate the playback of audio data at the same time. This achieves synchronized output between multiple audio devices, avoiding problems such as inconsistent sound timing, echoes, or rhythmic errors caused by clock differences or transmission delays between audio devices.
[0076] For example, in a system consisting of a soundbar master speaker and two surround speakers, after confirming that the two surround speakers are ready, the soundbar master speaker broadcasts the audio data buffered in the circular buffer along with the synchronization timestamp to the two surround speakers, so that the first word of the audio data is not lost and the three speakers start playing synchronously.
[0077] In some embodiments, after sending a coordinated wake-up command, the processor, in response to not receiving a readiness confirmation from the first slave device within a second preset time period, marks the first slave device as offline and controls the online slave device to play; and when the first slave device in the offline state recovers, it controls the first slave device to listen to the synchronization timestamp sent by the master device and receive audio data, and plays it online after alignment.
[0078] The second preset time period refers to the pre-set time period used to wait for the first slave device to return a ready confirmation after sending the coordinated wake-up command. The second preset time period can be set based on experience. For example, the second preset time period is 150 milliseconds.
[0079] The first slave device refers to a slave device that fails to return a ready confirmation within the second preset time period during the collaborative wake-up process.
[0080] Readiness confirmation refers to the confirmation information used by a device to indicate that it has entered a ready state.
[0081] Offline status refers to a disconnected state where communication between the slave device and the master device is interrupted, or where the slave device is unable to participate in the current collaborative playback due to an abnormality.
[0082] An online slave device refers to a slave device that maintains normal communication with the master device and returns a ready confirmation.
[0083] In some embodiments, when the master device sends a coordinated wake-up command, the processor starts a non-blocking wait timer for the first slave device. When the second preset time period ends and the master device has not yet received a readiness confirmation from the first slave device, the processor marks the first slave device as offline in the audio device table and stops the waiting process for the first slave device; simultaneously, it controls the online slave device to start decoding and playing audio data. The audio device table can record the online status of multiple slave devices, etc. The audio device table can be dynamically updated.
[0084] Network-connected playback refers to the process by which the first slave device, after recovery, officially starts the power amplifier to connect for collaborative playback after completing the local clock phase-locking and smooth alignment of the audio phase.
[0085] In some embodiments, when the processor detects that the first slave device, which was offline, has resumed communication, it controls the first slave device to keep the power amplifier off and turn on the communication receiver. The slave device passively listens to the synchronization timestamp broadcast by the master device and simultaneously receives audio data via the data link without the power amplifier outputting. The first slave device uses its local phase-locked loop circuit to adjust the hardware sampling clock, decodes the audio data while the power amplifier is off, and writes it into a local circular buffer for pre-filling. When the playback progress in the local circular buffer aligns with the detected synchronization timestamp, the first slave device sends a network-ready unicast packet to the master device. Upon receiving the network-ready unicast packet, the master device controls the first slave device to turn on the power amplifier via communication commands and joins the network playback after time alignment is completed.
[0086] For example, in a home theater scenario, if the right surround speaker fails to respond with a readiness confirmation within 150 milliseconds because someone walks by and blocks the wireless signal, the main speaker immediately marks the right surround speaker as offline and controls the other speakers to play audio data normally. Two seconds later, the right surround speaker resumes communication, keeps its amplifier off, receives and decodes audio data via the data link, adjusts the playback progress of its local circular buffer to perfectly match the synchronization timestamp broadcast by the main speaker using its local phase-locked loop circuit, and then sends a network-ready unicast packet to the main speaker. The main speaker responds with a communication command to turn on the amplifier of the right surround speaker, and the right surround speaker aligns and plays audio online.
[0087] In some embodiments of this specification, a non-blocking state machine and a hot-connection mechanism are used to ensure that the system does not block playback from online slave devices when the first slave device unexpectedly loses connection. Simultaneously, the first slave device is allowed to seamlessly rejoin the playing system via a silent alignment mechanism upon recovery, eliminating transient noise generated during reconnection.
[0088] In some embodiments, the processor reconfigures the crossover matrix to mix the audio data of the offline channel into the online channel in response to the first slave device corresponding to the target channel being offline.
[0089] The target channel refers to the audio channel that plays a decisive role in the integrity of the sound field in a multi-channel system. For example, the target channel can be the bass channel, left / right surround channels, etc.
[0090] In some embodiments, the processor may determine the channel played by the first slave device that is offline as the target channel.
[0091] A frequency division matrix is an algorithm matrix used to control the allocation of audio signals of different frequency bands to different channels and to perform route remapping.
[0092] Offline channel refers to the audio channel corresponding to the first slave device.
[0093] Online channels refer to the corresponding audio channels from online devices.
[0094] In some embodiments, when the processor detects that the slave device corresponding to the target channel is offline, the processor reconfigures the crossover matrix via a digital signal processor (DSP) to mix the audio data from the offline channel into the online channel. For example, the DSP disables the physical output to the offline channel (such as the subwoofer channel) and disables the high-pass filter for the online channel (such as the left / right surround channels). Based on the crossover matrix, the DSP redirects and mixes the low-frequency audio data played by the slave device (such as the subwoofer) corresponding to the offline channel into the mixer of the online channel, and activates the dynamic range controller built into the online channel to prevent signal overload caused by the superimposed low-frequency signal. Low-frequency audio data refers to audio data below a preset cutoff frequency. The preset cutoff frequency can be set empirically. For example, the preset cutoff frequency is 80 Hz.
[0095] In some embodiments of this specification, when the slave device corresponding to the target channel is offline, the listening self-healing is performed through real-time dynamic configuration of the frequency division matrix, and the offline channel is reasonably allocated to the online channel through rerouting and mixing audio, so as to preserve the integrity of the audio data and reduce the sense of sound dropout.
[0096] In some embodiments of this specification, a rigorous negotiated collaborative sleep and wake-up management mechanism is constructed through a full-process design of "unified decision-making by the master controller + interactive confirmation of instructions + heartbeat keep-alive + ready synchronization". By having the master controller uniformly monitor audio signals and decide on sleep and wake-up timing, combined with the instruction execution and sleep confirmation mechanism of the slave devices, a high degree of consistency in the state of each member within the device group is ensured. By continuously sending heartbeat signals to the sleep slave devices when the master controller enters a low-power monitoring state, the logical connection between devices is maintained without interruption, significantly reducing the network recovery latency after wake-up. By limiting the audio device group to synchronized playback only after all slave devices have reached a ready state, the problems of sound misalignment, delay, and popping caused by the different wake-up speeds of each device are completely eliminated. Simultaneously, the master controller's buffered audio data ensures the continuity of playback after wake-up, while the slave devices' deep sleep combined with the master controller's low-power monitoring and hierarchical power management strategy significantly reduces the overall standby power consumption of the system, effectively extending the battery life of battery-powered devices.
[0097] In practical deployments, the master control device serves as the "decision-making center" of the entire audio equipment group, and its operational stability directly affects the overall availability of the system. If the master control device becomes unable to perform its functions due to power depletion, hardware failure, or the need for deep maintenance, the entire audio equipment group will face the risk of disrupted or even paralyzed collaborative management. Therefore, some embodiments in this specification further introduce a master control candidate list and a negotiated master control switching mechanism, enabling the system to dynamically replace the master control device, thereby significantly improving the system's fault tolerance and robustness under complex operating conditions. See related content. Figure 4 Explanation.
[0098] Figure 4 This is an exemplary flowchart illustrating the re-electing of the master control device according to some embodiments of this specification. Figure 4 As shown, process 400 includes steps 410-440. In some embodiments, process 400 may be executed by a processor.
[0099] Step 410: Based on the device status of each audio device in the audio device group, construct and maintain a master control candidate list.
[0100] Device status is a set of information characterizing the current health and operational capabilities of an audio device, such as remaining battery power, CPU load, network connection quality, and whether it is currently in sleep / wake-up / fault state. For example, device status may include power supply type, remaining battery power, charging status, speaker operating impedance, and wireless communication signal strength.
[0101] Power supply type refers to the power supply attribute of the audio device itself. For example, power supply type can include external power supply, battery power, etc. In some embodiments, the processor can obtain the power supply type through manual input from the user terminal. For more information on user terminals and audio devices, see [link to relevant documentation]. Figure 1 And its related descriptions.
[0102] In some embodiments, the processor can read the remaining power and charging status from the coulomb counter via the integrated circuit bus; obtain the output voltage and load current through the monitoring chip at the output of the audio amplifier, calculate and output the current operating impedance of the speaker; and obtain the signal strength of wireless communication through the physical layer of the wireless chip.
[0103] The master control candidate list refers to a list that records the priority order of multiple slave devices within an audio device group as backup master control devices.
[0104] In some embodiments, the master control candidate list may include multiple candidate devices.
[0105] Candidate devices refer to slave devices that are included in the master control candidate list and have the potential to replace the master control device.
[0106] In some embodiments, the master device periodically sends query packets to multiple slave devices to collect the device status of the multiple slave devices, scores the multiple slave devices, constructs a master candidate list according to the scores from high to low, and writes it into a structure array in memory.
[0107] Preset weighting rules refer to rules that assign different weights to remaining battery power, speaker operating impedance, and received signal strength based on power supply type, and then sum the results. Preset weighting rules can be set based on experience. For example, a preset weighting rule could be: if the device is powered by an external power source, then the weight of remaining battery power is set to 0.5, the weight of speaker operating impedance is set to 0.2, and the weight of wireless communication signal strength is set to 0.3.
[0108] In some embodiments, the device status of the slave device may include power supply type, residual current, speaker operating impedance, and Received Signal Strength Indicator (RSSI). The slave device has a load current monitoring chip connected to its audio amplifier output. The master device can calculate and output the current speaker operating impedance by monitoring the output voltage and load current. The physical layer of the slave device's wireless chip directly provides the received signal strength to the master device.
[0109] In some embodiments, the master device scores multiple slave devices based on their respective device states and preset weighting rules.
[0110] In some embodiments, when the master device detects changes in the power supply type, remaining power, charging status, speaker operating impedance, or wireless communication signal strength of any slave device, the processor recalculates the score of the slave device as a candidate device and updates the sorting, thereby dynamically maintaining the master candidate list.
[0111] The device status of each audio device within an audio device group is not static; for example, remaining battery power will decrease over time, and wireless communication signal strength will fluctuate with environmental conditions. If the master control candidate list is not updated for a long period, the system may make incorrect master control replacement decisions based on outdated device statuses. Therefore, some embodiments of this specification further introduce a periodic update mechanism for the master control candidate list to ensure the real-time nature and effectiveness of candidate device information.
[0112] In some embodiments, the processor adjusts the update cycle of the master control candidate list; and when multiple slave devices are in a sleep state, it controls multiple slave devices to send status update data to the master control device in an event-driven manner.
[0113] The update cycle refers to the time interval at which the master controller candidate list is re-evaluated, refreshed, or maintained.
[0114] In some embodiments, the processor adaptively adjusts the update cycle of the master control candidate list by modifying the value of the interrupt reload register of the system tick timer. For example, when a first preset condition is met, the processor increases the value of the reload register, extending the update cycle to a preset long update cycle; when a second or third preset condition is met, the processor decreases the value of the reload register, shortening the update cycle to a preset short update cycle. The first preset condition may be: the master control device is powered by an external power supply, and the remaining power of multiple slave devices is higher than a first preset power threshold. The second preset condition may be: the master control device is powered by a battery, and the remaining power of multiple slave devices is less than or equal to the first preset power threshold. The third preset condition may be: an increase in background noise energy is detected, leading to increased interference. Background noise energy refers to the energy carried by the continuous background noise inherent in the system or external environment when there is no audio signal input.
[0115] The first preset battery threshold, the preset long update cycle, and the preset short update cycle can be set based on experience. For example, the first preset battery threshold can be 50%, the preset long update cycle can be 30 minutes, and the preset short update cycle can be 10 seconds.
[0116] Event-driven operation refers to a workflow where corresponding processing or reporting is triggered based on events. For example, event-driven operation can be a workflow where reporting is triggered when events such as changes in the device's remaining battery power or charging status occur.
[0117] Status update data refers to data that reflects the current status of a device and is sent to the master device. For example, status update data may include remaining battery power, charging status, and wireless communication signal strength.
[0118] In some embodiments, the master device disables active polling when multiple slave devices are in sleep mode and writes preset trigger conditions for charging state switching and preset power change thresholds to each slave device. The processor controls multiple slave devices to operate only the wireless coprocessor and the charging management chip; when the pin level change of the charging management chip meets the preset trigger condition, or when the local voltage comparison circuit of a slave device detects that the power level exceeds the preset power change threshold, the processor triggers an interrupt pin to wake up the wireless coprocessor, and controls multiple slave devices to send a single update of status data, including remaining power level and charging status, to the master device in an event-driven manner, and immediately re-enters sleep mode after sending. The preset trigger condition and preset power change threshold can be set empirically. For example, the preset trigger condition can be: plugging and unplugging the charger, i.e., switching charging states. The preset power change threshold can be: the power level drops by more than 5%, i.e., a physical state jump.
[0119] In some embodiments of this specification, a dual power optimization strategy of adaptively adjusting the update cycle and event-driven mode is adopted to achieve a balance between low power consumption and high data freshness in the sleep state, effectively extending the overall standby life of the audio device group and ensuring the push accuracy during sudden wake-up.
[0120] Step 420: In response to the master control device meeting the preset replacement conditions, control the current master control device to send a takeover notice to the first candidate device.
[0121] Preset replacement conditions refer to pre-defined conditions used to trigger the current master control device to hand over or change roles. For example, preset replacement conditions may include the master control device's remaining battery power being lower than a second preset battery power threshold, or the wireless communication signal strength being lower than a preset strength threshold. The second preset battery power threshold and the preset strength threshold can be set based on experience. For example, the second preset battery power threshold can be 30%.
[0122] The first candidate device refers to the candidate device with the highest priority and ranked first in the master control candidate list.
[0123] A takeover notification is a notification message sent by the current master control device to the first candidate device to indicate that it is preparing to take over the master control responsibilities.
[0124] In some embodiments, the processor continuously monitors the device status of the current master device. When the processor detects that the remaining battery power of the current master device is lower than a second preset battery power threshold, or the signal strength of wireless communication is lower than a preset strength threshold, the processor reads the first candidate device from the master device candidate list and sends a takeover notice to the first candidate device via unicast.
[0125] Step 430: In response to receiving the takeover confirmation from the first candidate device, broadcast the master control switch notification and start the preset protection window.
[0126] Takeover confirmation refers to the confirmation information returned to the current master control device after the first candidate device completes its self-test and confirms that it can assume the master control responsibilities.
[0127] Master control switchover notification refers to a notification message broadcast by the master control device to all audio devices in the audio device group to announce that the master control role is about to be switched.
[0128] The preset protection window refers to the safe waiting time during master control handover when the current master control device continues to maintain heartbeat broadcasting and data forwarding to prevent link interruption. The preset protection window can be set based on experience.
[0129] In some embodiments, after the first candidate device initiates a local self-test and confirms that it is normal, it returns a takeover confirmation to the processor. Upon receiving the takeover confirmation from the first candidate device, the processor broadcasts a master control switch notification to all audio devices in the audio device group and starts a hardware timer as a preset protection window. The current master device continues to maintain heartbeat broadcasting within the preset protection window, while simultaneously continuing to perform audio data bridging and forwarding to ensure smooth and uninterrupted audio data playback.
[0130] In some embodiments, in response to the current master device receiving a master switching notification, the processor synchronizes the current mute timer reading, circuit reference parameters, and buffer configuration parameters to the first candidate device that is the new master device through a state hot synchronization protocol.
[0131] A state-based hot synchronization protocol refers to the communication and interaction rules that synchronize the real-time operating parameters of the current master control device to the new master control device without interrupting system operation. The state-based hot synchronization protocol can be preset by the system. Real-time operating parameters may include the current mute timer reading, circuit reference parameters, buffer configuration parameters, etc.
[0132] The mute timer reading refers to the current value of the timer used to characterize the cumulative duration of silence.
[0133] Circuit reference parameters are reference parameters used by hardware comparators or low-power analog-to-digital converters to determine valid audio. For example, circuit reference parameters may include level reference voltages, filter parameters, etc.
[0134] Buffer configuration parameters are a set of parameters used to describe how the buffer is organized and its read / write status. For example, buffer configuration parameters may include start and end address pointers, read / write pointer offsets, data depth parameters, etc.
[0135] The new master control device refers to the new master control node that takes over the master control of the audio equipment group after the master control switch is completed.
[0136] In some embodiments, after receiving a master control switch notification and before exiting the master control role, the current master device initiates a state hot synchronization protocol. The processor reads the real-time count value from the internally integrated timer register via the internal bus as the current mute timer reading; it reads the reference voltage register value and digital filter coefficients corresponding to the hardware comparator or low-power analog-to-digital converter as circuit reference parameters; and it reads the start and end physical addresses, read pointer offset, and write pointer offset of the circular buffer as buffer configuration parameters. The processor packages the current mute timer reading, circuit reference parameters, and buffer configuration parameters into the payload of the state hot synchronization protocol and unicasts it to the first candidate device that will become the new master device.
[0137] Within the preset protection window, the current master device continues to maintain the bridging forwarding of audio data, while the first candidate device continues to receive audio data. After receiving the aforementioned real-time operating parameters, the first candidate device writes these parameters into its local corresponding timer register, circuit control register, and memory controller. Based on the synchronized read pointer offset, write pointer offset, and continuously received audio data, it reconstructs the circular buffer state corresponding to the current playback progress locally, thus seamlessly continuing the original silence timing and buffer state after the master device switches. After the current master device relinquishes its master role, a seamless handover of master control is completed.
[0138] In some embodiments of this specification, the mute timer reading, circuit reference parameters, and buffer configuration parameters of the current master control device are synchronized at the hardware level during master control switching through a state hot synchronization protocol. This eliminates the interruption and loss of mute timer readings, reset of circuit reference parameters, or buffer overflow caused by master control switching, and achieves a seamless transition in audio data playback.
[0139] Step 440: In response to the lack of takeover confirmation within the first preset time period, the current master control device is controlled to terminate the replacement process and revert to its original working state, and a takeover notice is sent to the next candidate device after the first candidate device.
[0140] The first preset time period refers to the pre-set time period used during the master control switchover process to wait for the first candidate device to return a takeover confirmation. The first preset time period can be set based on experience.
[0141] The succession process refers to the complete sequence of actions in which the current master control device and the first candidate device hand over the master control authority, status, and role.
[0142] The original working state refers to the normal working and control state of the current main control equipment before the start of the replacement process.
[0143] The next candidate device refers to the second candidate device in the master control candidate list, following the first candidate device.
[0144] In some embodiments, if the processor does not receive a takeover confirmation from the first candidate device within a first preset time period, the processor confirms that the first candidate device is abnormal, controls the current master device to terminate the replacement process and revert to its original operating state, and continues to maintain the bridging forwarding of heartbeat broadcasts and audio data according to the original operating state. At the same time, the processor reads the next candidate device from the master candidate list and sends a takeover notice to the next candidate device.
[0145] In some embodiments of this specification, by maintaining a master control candidate list based on device status, proactive replacement and a smooth transition of the control link are achieved when the master control device experiences abnormal status or energy degradation. Simultaneously, through takeover confirmation, preset protection windows, and timeout rollback mechanisms, the physical availability of candidate devices is ensured, preventing control network failure due to vacant control.
[0146] It should be noted that the above descriptions of processes 300 and 400 are for illustrative purposes only and do not limit the scope of this specification. Those skilled in the art can make various modifications and changes to processes 300 and 400 under the guidance of this specification. However, such modifications and changes remain within the scope of this specification.
[0147] In practical operation, when the audio device group is in a low-power monitoring state or sleep state, ensuring that multiple slave devices can respond synchronously and efficiently to external triggers and quickly enter working state is crucial to guaranteeing a low-latency experience. Without a unified collaborative wake-up mechanism, multiple slave devices may experience problems such as stuttering, disconnection, or audio-visual asynchrony due to inconsistent wake-up timing or unready communication links. Therefore, some embodiments in this specification further introduce a collaborative wake-up command sending mechanism, where the master control device uniformly schedules and sends wake-up signals to multiple slave devices, thereby achieving synchronous activation and rapid readiness of the entire audio device group. See related content. Figure 5 Explanation.
[0148] Figure 5 This is an exemplary schematic diagram illustrating the sending of a coordinated wake-up command according to some embodiments of this specification.
[0149] In some embodiments, such as Figure 5 As shown, sending a coordinated wake-up command to multiple slave devices includes: the processor acquiring the latency parameters 510 of the multiple slave devices 540; determining the sending time 520 of sending the coordinated wake-up command 530 to the multiple slave devices 540 based on the latency parameters 510; and controlling the multiple slave devices 540 to synchronously complete initialization and play audio data 550 based on the sending time 520.
[0150] For more information on devices, co-wake-up commands, and audio data, see [link to documentation]. Figure 3 And its related descriptions.
[0151] Delay parameters are time parameters used to characterize the time required from when a device receives a coordinated wake-up command to when it begins to play audio. For example, delay parameters can include hardware startup delay, filter setup time, and wireless transmission delay. Hardware startup delay refers to the time required from when the device's audio processing unit is woken up to when it begins to output an audio signal. Filter setup time refers to the time required from when the device's digital signal processor begins receiving and processing audio data to when the digital filter's stable output waveform reaches a stable state.
[0152] In some embodiments, during the production testing phase, the processor can measure the charging time of the power amplifier capacitor from the device as the hardware startup delay; measure the settling time of the digital signal processor filter as the filter setup time; and measure the single-hop transmission time of the wireless data packet as the wireless transmission delay. The processor sums the hardware startup delay, the filter setup time, and the wireless transmission delay to obtain the delay parameters.
[0153] In some embodiments, when establishing a mesh topology, the processor reads the latency parameters of multiple slave devices and records them in memory.
[0154] The sending time refers to the point in time when the master device sends the coordinated wake-up command to the slave device. For more information about the master device, please refer to [link to documentation / reference]. Figure 3 And its related descriptions.
[0155] In some embodiments, the processor can read the playback timestamp of the audio data from the master device's circular buffer, subtract a latency parameter from the playback timestamp, and use this as the sending time for sending coordinated wake-up commands to multiple slave devices. For further explanation of playback timestamps, see [link to documentation]. Figure 3 And its related descriptions.
[0156] Initialization refers to the startup and preparation process performed on a device after it is woken up and before it can participate in the synchronous playback of audio data. For example, initialization may include hardware startup, filter establishment, wireless transmission, etc.
[0157] In some embodiments, the processor can send coordinated wake-up instructions to multiple slave devices using a time-difference transmission mechanism based on the transmission time, thereby controlling the multiple slave devices to synchronously complete initialization and play audio data. For example, the processor starts a hardware timer based on the transmission time; when the hardware timer generates a compare-match interrupt, in the interrupt service routine, the processor first sends a coordinated wake-up instruction to the slave device with a larger hardware startup delay (such as a high-power speaker), and then sends a coordinated wake-up instruction to the slave device with a smaller hardware startup delay (such as a low-power speaker), thereby controlling the multiple slave devices to complete initialization and play audio data at the same time. The time-difference transmission mechanism refers to the staggered distribution mode used by the master device when sending coordinated wake-up instructions to multiple slave devices.
[0158] In some embodiments of this specification, by obtaining the latency parameters of multiple slave devices, the collaborative wake-up command is sent at a time difference with microsecond-level precision. This solves the wake-up asynchrony problem caused by differences in the hardware architecture of slave devices from the perspective of command timing control, and ensures the initial alignment of the synchronous playback of audio data.
[0159] In practical applications, multiple slave devices within an audio device group are often distributed in different physical locations. This spatial difference leads to an objective deviation in the time it takes for sound to reach the listener. If synchronization is based solely on basic time delay parameters, the propagation time difference caused by physical distance may be ignored, resulting in a chaotic sound field or impaired stereo effect. To address this, some embodiments in this specification further introduce an acoustic time delay calculation and calibration mechanism based on relative position parameters. By quantifying the spatial differences among multiple slave devices, the time delay parameters are finely adjusted, thereby ensuring that the final audio output achieves accurate spatial synchronization in terms of perceived sound.
[0160] In some embodiments, the processor can calculate acoustic delay based on the relative position parameters of multiple slave devices; and calibrate the delay parameters of multiple slave devices based on the acoustic delay.
[0161] Relative position parameters refer to the coordinate parameters used to describe the physical location of multiple slave devices and the master listening point. For example, relative position parameters may include geometric dimensions and spatial coordinates. Physical space refers to the actual space where the system is deployed and operates. The master listening point is the spatial coordinate point representing the location of the listener's ears. The master listening point can be set based on experience.
[0162] In some embodiments, the processor reads the geometric dimensions of the physical space where the system is located, the spatial coordinates of multiple slave devices, and the spatial coordinates of the master listening point as relative position parameters.
[0163] Acoustic time delay refers to the time delay it takes for sound waves to travel through the air from multiple devices to the main listening point.
[0164] In some embodiments, the processor calculates the acoustic delay based on the relative position parameters of multiple slave devices and a preset sound velocity constant. The preset sound velocity constant can be set empirically. For example, the preset sound velocity constant is 340 m / s.
[0165] In some embodiments, the processor accumulates the hardware startup delay, filter setup time, wireless transmission delay, and acoustic delay of multiple slave devices obtained in the aforementioned manner to calibrate the delay parameters of the multiple slave devices. When controlling the master device to send audio data, the processor, based on the delay parameters, adjusts the read pointer offset of the circular buffer corresponding to the multiple slave devices through a digital signal processor, fine-tuning the playback timestamp of the audio data sent to the multiple slave devices. This allows slave devices located further away to play audio data earlier, thereby offsetting the longer acoustic delay and ensuring physical overlap of the multi-channel sound wave phases at the main listening point.
[0166] In some embodiments of this specification, acoustic delay is calculated based on relative position parameters, and the delay parameters of multiple slave devices are calibrated based on acoustic delay. Air propagation delay is incorporated into synchronization compensation, completing the leap from electrical signal synchronization to spatial acoustic phase coherence. This overcomes the auditory image misalignment caused by different physical distances between audio devices, creating an immersive three-dimensional aligned sound field for the listener.
[0167] During the long-term operation of an audio device group, the master control device, as the core scheduling node, is fundamental to ensuring the orderly operation of the system due to its health and connection stability. However, due to uncontrollable factors such as battery life, hardware aging, or environmental interference, the current master control device may face the risk of performance degradation or even unexpected offline status. Without effective contingency plans, such a single point of failure will directly paralyze the entire audio collaborative network. Therefore, some embodiments in this specification further propose a master control device re-election mechanism. Through preset triggering conditions and election logic, a new master control device is automatically selected to take over control when the current master control device is unable to perform its duties, thereby ensuring the continuity and high availability of the audio device group in dynamically changing environments. See related content. Figure 6 Explanation.
[0168] Figure 6 This is an exemplary schematic diagram of a re-electing master control device according to some embodiments of this specification.
[0169] In some embodiments, such as Figure 6 As shown, in the low-power listening state 610, the processor sends a probe request 630 to the master device 620 in response to any slave device 540 not receiving a heartbeat signal within a third preset time period; and in response to the probe request not being responded to, the processor re-elects the master device 620 through the group negotiation mechanism 640.
[0170] For more information on low-power monitoring, heartbeat signals, slave devices, and master devices, please refer to [link / reference]. Figure 3 And its related descriptions.
[0171] The third preset time period refers to a pre-set time window used to determine whether the slave device has continuously failed to receive a heartbeat signal during low-power monitoring. The third preset time period can be set empirically. For example, the third preset time period is 4 seconds.
[0172] A probe request is an active probe message initiated by a device to the master control device when it has not received a heartbeat signal, and which requires a mandatory response.
[0173] In some embodiments, during low-power listening mode, the processor sets a third preset time period via a local timer to monitor whether multiple slave devices receive heartbeat signals. If any slave device does not receive a heartbeat signal within the third preset time period, the processor controls the slave device to switch its RF receiving channel to a continuously active listening mode and sends a probe request to the master device via a low-power communication link. The continuously active listening mode refers to a mode in which the low-power wireless receiver of the slave device remains continuously active (i.e., the RF receiving channel does not intermittently or periodically sleep), monitoring and receiving heartbeat signals in real time.
[0174] Intra-group negotiation mechanisms refer to collaborative interaction rules among multiple slave devices through mutual communication and information exchange to form unified control decisions. For example, intra-group negotiation mechanisms can manifest as voting, ranking, etc.
[0175] Re-selection refers to the process by which multiple slave devices reselect a new master device after the current master device loses connection.
[0176] In some embodiments, the slave device waits for a response confirmation from the master device after sending a probe request. If the master device fails to return any response confirmation after a preset number of hardware retries, the slave device determines that the probe request has not been responded to, thus indicating a failure of the master device. The slave device then sends negotiation instructions to other reachable slave devices within the audio device group via an ad hoc wireless communication protocol, and re-elects a master device through an intra-group negotiation mechanism. For example, the processor constructs and maintains a master candidate list based on the device states of multiple slave devices in the audio device group, including multiple candidate devices; based on the master candidate list, a master device is re-elected. For further explanation on how to construct and maintain the master candidate list, see [link to documentation]. Figure 4 And its related descriptions.
[0177] In some embodiments of this specification, a progressive processing mechanism of loss of connection detection, probe request verification, and intra-group negotiation re-recommendation is used to balance low power consumption and diagnostic reliability, and to autonomously rebuild the control network when the main control device fails.
[0178] In some embodiments, when the master device sends a heartbeat signal, the processor assigns an audit token and a time offset to the second slave device; and controls the second slave device with the audit token to send a reverse probe signal to the master device after the time offset has elapsed, thereby performing a status determination of the master device.
[0179] The second slave device refers to the slave device selected from a group of slave devices to receive the audit token.
[0180] An audit token is an identification information assigned by the master device to the second slave device to designate it to perform a reverse activity audit task.
[0181] The time offset refers to the length of time that needs to be waited after obtaining an audit token from the device before sending a reverse probe signal.
[0182] In some embodiments, the master device randomly fills the data payload of the heartbeat signal to be sent with a single-byte device physical address hash value as an audit token, and attaches a value generated by the main chip hardware random number generator as a time offset. After the master device sends the heartbeat signal, the second slave device that matches the audit token receives and saves the time offset. Each time a heartbeat signal is sent, the master device assigns an audit token to only one second slave device.
[0183] A reverse detection signal refers to a detection signal sent by the second slave device to the master device for reverse detection of the active status of the master device.
[0184] Status determination refers to the conclusion reached regarding whether the main control device has crashed, lost power, or experienced a hardware malfunction. For example, the status determination result can be normal, faulty, or disconnected.
[0185] In some embodiments, the second slave device wakes up the wireless coprocessor after receiving the audit token and starts a hardware timer. After the time offset timer expires, the second slave device sends a single-packet reverse probe signal to the master device. Upon receiving the reverse probe signal, the master device's wireless coprocessor automatically returns a response frame immediately. If the second slave device does not receive the response frame within the hardware-level response window, it performs a status determination and determines that the master device has failed, subsequently broadcasting a link loss alarm to the mesh topology. The hardware-level response window refers to the response waiting period directly timed by the hardware timer, without relying on software polling.
[0186] In some embodiments of this specification, by sending an audit token and a time offset when sending a heartbeat signal, a single slave device can perform time-sharing reverse probing, reducing conflicts and energy consumption, and narrowing the time blind spot for determining the execution status of the master device, thereby improving the system's response speed.
[0187] In some embodiments, the processor controls a slave device to send a disconnection confirmation signal to the remaining slave devices in response to any slave device not receiving a heartbeat signal within a third preset time period; and initiates a re-election process in response to the number of remaining slave devices that have sent disconnection confirmation signals reaching a preset ratio threshold.
[0188] The remaining slave devices refer to all other online slave devices among multiple slave devices, excluding the one that is currently initiating the disconnection confirmation.
[0189] A disconnection confirmation signal is a confirmation message used between devices to verify whether the main control device has lost connection.
[0190] In some embodiments, when any slave device does not receive a heartbeat signal within a third preset time period, the processor controls that slave device (also known as the initiating slave device) to unicast a disconnection confirmation signal to all other remaining slave devices in the mesh topology through the mesh topology channel. The remaining slave devices (also known as receiving slave devices) that receive the disconnection confirmation signal check whether they received a heartbeat signal within the third preset time period and reply to the initiating slave device with either a disconnection confirmation signal or a disconnection rejection signal. For example, if the receiving slave device did not receive a heartbeat signal within the third preset time period, it replies to the initiating slave device with a disconnection confirmation signal; if the receiving slave device received a heartbeat signal within the third preset time period, it replies to the initiating slave device with a disconnection rejection signal.
[0191] In some embodiments, the processor executes a re-electing process based on the proportion of the remaining slave devices that have provided a disconnection confirmation signal to the total number of remaining slave devices, in order to re-determine a new master device when the current master device becomes disconnected.
[0192] The preset ratio threshold refers to the percentage threshold used to determine whether multiple slave devices have reached a consensus on the loss of connection of the master control device. The preset ratio threshold can be set based on experience. For example, the preset ratio threshold is one-half.
[0193] In some embodiments, the initiating slave device counts the received response frames, counts the number of remaining slave devices that have responded with a disconnection confirmation signal (i.e., replied with a disconnection confirmation signal), and calculates the ratio of the number of remaining slave devices that have responded with a disconnection confirmation signal to the total number of remaining slave devices, as the disconnection confirmation ratio. If the disconnection confirmation ratio is greater than or equal to a preset ratio threshold, the processor initiates a re-electing process. If the disconnection confirmation ratio is less than the preset ratio threshold, the processor determines that only some of the remaining slave devices have their communication channels blocked, and maintains the original mesh topology to avoid topology oscillation.
[0194] For example, in a system consisting of one master speaker and four slave speakers, if slave speaker number three does not receive a heartbeat signal from the master speaker within a third preset time period, it sends a disconnection confirmation signal to the remaining slave speakers (i.e., slave speakers number one, two, and four). If slave speakers number one and two reply with a disconnection confirmation signal, and slave speaker number four replies with a disconnection rejection signal, the disconnection confirmation ratio is two-thirds, greater than one-half. Slave speaker number three determines that the master speaker is truly disconnected and initiates a re-electing process. If slave speakers number one and two reply with a disconnection rejection signal, and slave speaker number four replies with a disconnection confirmation signal, the disconnection confirmation ratio is one-third, less than one-half. Slave speaker number three determines that the master speaker is not disconnected and abandons initiating the re-electing process, thus avoiding false elections caused by communication link abnormalities in slave speaker number three itself.
[0195] In some embodiments of this specification, a re-electing process is triggered by the proportion of disconnection confirmations of multiple remaining slave devices. Cross-validation is used to distinguish between the actual disconnection of the master device and the communication link anomaly of a single slave device, thereby reducing false elections and network conflicts and maintaining the stability of the mesh topology.
[0196] The basic concepts have been described above. Obviously, for those skilled in the art, the detailed disclosure above is merely illustrative and does not constitute a limitation of this specification. Although not explicitly stated herein, those skilled in the art may make various modifications, improvements, and corrections to this specification. Such modifications, improvements, and corrections are suggested in this specification and therefore remain within the spirit and scope of the exemplary embodiments described herein.
[0197] Finally, it should be understood that the embodiments described in this specification are merely illustrative of the principles of the embodiments described herein. Other variations may also fall within the scope of this specification. Therefore, alternative configurations of the embodiments described herein are intended to be illustrative rather than limiting, and should be considered consistent with the teachings of this specification. Accordingly, the embodiments described herein are not limited to those explicitly introduced and described herein.
Claims
1. A negotiation-based collaborative sleep and wake-up management method for multiple audio devices, characterized in that, The method is executed by a processor and includes: In the audio device group, a master device and multiple slave devices are identified, and the master device caches the audio data. The main control device monitors the audio signal and generates a cooperative sleep command in response to the audio signal meeting the preset mute condition. Send the coordinated sleep command to the plurality of slave devices, control the plurality of slave devices to enter sleep state and return a sleep confirmation signal to the master control device; Upon receiving the sleep confirmation signal returned by the plurality of slave devices, the master control device is controlled to enter a low-power listening state to monitor the audio signal and send a heartbeat signal to the plurality of slave devices in the sleep state; In response to the audio signal satisfying a preset wake-up condition, the master control device is woken up and a coordinated wake-up command is sent to the plurality of slave devices; and In response to the plurality of slave devices being in a ready state, the audio device group is controlled to synchronously play the audio data.
2. The method according to claim 1, characterized in that, The method further includes: Based on the device status of each audio device in the audio device group, a master control candidate list is constructed and maintained, which includes multiple candidate devices. In response to the master control device meeting the preset replacement conditions, the current master control device is controlled to send a takeover notice to the first candidate device; In response to receiving the takeover confirmation from the first candidate device, a master control switch notification is broadcast and a preset protection window is activated; and If no takeover confirmation is received within a first preset time period, the current master control device is controlled to terminate the replacement process and revert to its original working state, and the takeover notice is sent to the next candidate device after the first candidate device.
3. The method according to claim 1, characterized in that, Sending the coordinated wake-up command to the plurality of slave devices includes: Obtain the latency parameters of the multiple slave devices; Based on the latency parameter, determine the timing for sending the coordinated wake-up command to the plurality of slave devices; and Based on the transmission time, the multiple slave devices are controlled to synchronously complete initialization and play the audio data.
4. The method according to claim 1, characterized in that, The method further includes: After sending the coordinated wake-up command, in response to not receiving a readiness confirmation from the first slave device within a second preset time period, the first slave device is marked as offline and the online slave device is controlled to play; and When the first slave device recovers from the offline state, it is controlled to listen for the synchronization timestamp sent by the master device and receive the audio data, and then play it on the network after alignment.
5. The method according to claim 1, characterized in that, The method further includes: In the low-power monitoring state, in response to any of the slave devices not receiving the heartbeat signal within a third preset time period, a probe request is sent to the master control device; and If the detection request is not responded to, the master control device is re-elected through an intra-group negotiation mechanism.
6. A negotiation-based collaborative sleep and wake-up management system for multiple audio devices, characterized in that, The system includes: The determination module is configured to: determine a master device and multiple slave devices in an audio device group, with the master device caching audio data; The generation module is configured to: control the main control device to monitor the audio signal, and generate a cooperative sleep command in response to the audio signal meeting a preset mute condition; The control module is configured as follows: Send the coordinated sleep command to the plurality of slave devices, control the plurality of slave devices to enter sleep state and return a sleep confirmation signal to the master control device; Upon receiving all the aforementioned sleep confirmation signals, the master control device is controlled to enter a low-power listening state to monitor the audio signals and send heartbeat signals to the plurality of slave devices in the sleep state; In response to the audio signal satisfying a preset wake-up condition, the master control device is woken up and a coordinated wake-up command is sent to the plurality of slave devices; and In response to the plurality of slave devices being in a ready state, the audio device group is controlled to synchronously play the audio data.
7. The system according to claim 6, characterized in that, The determining module is further configured to: Based on the device status of each audio device in the audio device group, a master control candidate list is constructed and maintained, which includes multiple candidate devices. In response to the master control device meeting the preset replacement conditions, the current master control device is controlled to send a takeover notice to the first candidate device; In response to receiving the takeover confirmation from the first candidate device, a master control switch notification is broadcast and a preset protection window is activated; as well as If no takeover confirmation is received within a first preset time period, the current master control device is controlled to terminate the replacement process and revert to its original working state, and the takeover notice is sent to the next candidate device after the first candidate device.
8. The system according to claim 6, characterized in that, The control module is also configured to: Obtain the latency parameters of the multiple slave devices; Based on the latency parameter, determine the timing for sending the coordinated wake-up command to the plurality of slave devices; and Based on the transmission time, the multiple slave devices are controlled to synchronously complete initialization and play the audio data.
9. The system according to claim 6, characterized in that, The control module is also configured to: After sending the collaborative wake-up command, in response to not receiving a ready confirmation from the first slave device within a second preset time period, the first slave device is marked as offline and the online slave device is controlled to play; as well as When the first slave device recovers from the offline state, it is controlled to listen for the synchronization timestamp sent by the master device and receive the audio stream, and then play it on the network after alignment.
10. The system according to claim 6, characterized in that, The control module is also configured to: In the low-power monitoring state, in response to any of the slave devices not receiving the heartbeat signal within a third preset time period, a probe request is sent to the master control device. as well as If the detection request is not responded to, the master control device is re-elected through an intra-group negotiation mechanism.
