Microphone control authority distribution method and device, storage medium and electronic device

By analyzing the microphone control request type of the application software and reasonably allocating microphone permissions, the conflict problem when multiple application software in smart homes request microphones at the same time is solved, and the user experience is improved.

CN119227046APending Publication Date: 2024-12-31QINGDAO HAIER TECH +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411280096.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-12
Publication Date
2024-12-31

AI Technical Summary

Technical Problem

In smart homes, multiple application softwares are prone to conflicts when requesting microphone permissions at the same time, resulting in poor user experience. The existing technology has failed to effectively solve the problem of confusing microphone permission allocation.

Method used

By receiving the microphone control request from the target application software, parse the request type (mutex type, queue type, or default type), determine the microphone's control permission allocation method based on the request type, such as releasing permissions through broadcast messages, adding to the waiting queue, or Idle state assign permissions.

Benefits of technology

It realizes the rational allocation of microphone permissions, reduces the coupling between voice services, and improves the user's experience of using voice functions in the application.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119227046A_ABST
    Figure CN119227046A_ABST
Patent Text Reader

Abstract

The invention discloses a microphone control authority distribution method and device, a storage medium and an electronic device, and relates to the field of smart home, the microphone control authority distribution method comprises the steps that a microphone control request sent by target application software is received, and the microphone control request is used for requesting to acquire the control authority of a microphone; analyzing the microphone control request to obtain a request type of the microphone control request, the request type including a mutual exclusion type, a queue type and a default type; according to the request type of the microphone control request, the control authority of the microphone is allocated to the target application software, and the allocation mode of the control authority of the microphone is determined through the request type. By adopting the technical scheme, the problem of disordered microphone permission distribution is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of smart home, and more specifically, to a method, device, storage medium and electronic device for allocating microphone control permissions. Background Art

[0002] At present, in smart homes, there are more and more devices connected to large-screen TVs, so the microphone module of the TV needs to adapt to the application software compatible with each device. Different application software has different ways of controlling the microphone. When multiple applications request microphone permissions at the same time, conflicts are likely to occur, resulting in a poor user experience. Therefore, there is a problem of confusing microphone permission allocation in the relevant technology.

[0003] With respect to the problem of confusing allocation of microphone permissions in related technologies, no effective solution has been proposed yet. Summary of the invention

[0004] Embodiments of the present application provide a method, device, storage medium, and electronic device for allocating microphone control permissions, so as to at least solve the problem of confusion in microphone permission allocation in the related art.

[0005] According to an embodiment of the embodiments of the present application, a method for allocating microphone control permissions is provided, including: receiving a microphone control request sent by a target application software, wherein the microphone control request is used to request control permissions for a microphone; parsing the microphone control request to obtain a request type of the microphone control request, wherein the request type includes a mutually exclusive type, a queue type, and a default type; allocating control permissions for the microphone to the target application software according to the request type of the microphone control request, wherein an allocation method for the control permissions of the microphone is determined by the request type.

[0006] In an exemplary embodiment, control permissions are allocated to the target application software according to the request type of the microphone control request, including: when it is determined that the request type of the microphone control request is the mutually exclusive type, sending a message to all application software, wherein the message is used to instruct the application software currently occupying the control permission of the microphone to release the control permission of the microphone; and allocating the control permission of the microphone to the target application software.

[0007] In an exemplary embodiment, control permissions are allocated to the target application software according to the request type of the microphone control request, including: when it is determined that the request type of the microphone control request is the queue type, adding the microphone control request to a waiting queue; obtaining a sorting priority of the microphone control request in the waiting queue, wherein the sorting priority is determined according to the time when the microphone control request is added to the waiting queue; when it is determined that the sorting priority is the highest priority and the application software currently occupying the control permission of the microphone has released the control permission of the microphone, allocating the control permission of the microphone to the target application software.

[0008] In an exemplary embodiment, control permissions are allocated to the target application software according to the request type of the microphone control request, including: when it is determined that the request type of the microphone control request is the default type, obtaining the queue status of the waiting queue; when it is determined that the queue status indicates that there is no microphone control request in the waiting queue, obtaining the occupancy status of the control permission of the microphone; when it is determined that no application software occupies the control permission of the microphone, allocating the control permission of the microphone to the target application software.

[0009] In an exemplary embodiment, after allocating control permissions for the microphone to the target application software based on the request type of the microphone control request, the method further includes: after receiving a recording request initiated by the target object, sending an instruction to a remote recording device to instruct the remote recording device to collect an audio signal; after determining that the remote recording device has completed the collection of the audio signal, sending the audio signal to the target application software.

[0010] In an exemplary embodiment, before sending the audio signal to the target application software, the method also includes: converting the audio signal into an audio stream array through a preset audio algorithm, and adding the audio stream array to a cache queue; processing the audio stream array in the cache queue according to a preset audio format of the target application software to obtain audio in the preset audio format; and sending the audio in the preset audio format to the target application software.

[0011] In an exemplary embodiment, after allocating control rights of the microphone to the target application software according to the request type of the microphone control request, the method further includes: sending a confirmation message to the target application software, wherein the confirmation message is used to confirm with the target application software whether to continue using the microphone; within a preset time period after sending the confirmation message, if it is determined that no response information from the target application software has been received, releasing the control rights of the microphone from the target application software, wherein the response information is used to indicate that the target application software confirms to continue using the microphone.

[0012] According to another aspect of an embodiment of the present application, a microphone control device is also provided, including: a receiving module, used to receive a microphone control request sent by a target application software, wherein the microphone control request is used to request control authority of the microphone; a parsing module, used to parse the microphone control request to obtain a request type of the microphone control request, wherein the request type includes a mutually exclusive type, a queue type, and a default type; an allocation module, used to allocate control authority of the microphone to the target application software according to the request type of the microphone control request, wherein the allocation method of the control authority of the microphone is determined by the request type.

[0013] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned method for allocating microphone control permissions when running.

[0014] According to another aspect of an embodiment of the present application, an electronic device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the method for allocating microphone control permissions through the computer program.

[0015] According to another aspect of the embodiments of the present application, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in any of the above method embodiments are implemented.

[0016] In an embodiment of the present application, after receiving the microphone control request of the target application software, the microphone control request can be parsed to obtain the request type of the microphone control request, and then the allocation method of the microphone control permission is determined for the target application software according to the request type of the microphone control request; the above technical solution is adopted to solve the problem of chaotic allocation of microphone permissions, thereby achieving the effect of reasonably allocating microphone permissions. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0018] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0019] Figure 1 It is a hardware environment diagram of a method for allocating microphone control permissions in an embodiment of the present application;

[0020] Figure 2 is a flowchart of a method for allocating microphone control permissions according to an embodiment of the present application;

[0021] Figure 3 1 is a flow chart of a method for allocating microphone control permissions according to an embodiment of the present application (I);

[0022] Figure 4 2 is a flow chart of a method for allocating microphone control permissions according to an embodiment of the present application;

[0023] Figure 5 It is a structural block diagram of a microphone control device according to an embodiment of the present application. DETAILED DESCRIPTION

[0024] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.

[0025] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0026] According to one aspect of an embodiment of the present application, a method for allocating microphone control permissions is provided. The method for allocating microphone control permissions is widely used in application scenarios such as software development. Optionally, in this embodiment, the above-mentioned method for allocating microphone control permissions can be applied to Figure 1 In the hardware environment composed of the terminal device 102 and the server 104 shown in FIG. Figure 1 As shown, the server 104 is connected to the terminal device 102 via a network, and can be used to provide services (such as application services, etc.) for the terminal or a client installed on the terminal. A database can be set on the server or independently of the server to provide data storage services for the server 104. Cloud computing and / or edge computing services can be configured on the server or independently of the server to provide data computing services for the server 104.

[0027] The network may include but is not limited to at least one of the following: wired network, wireless network. The wired network may include but is not limited to at least one of the following: wide area network, metropolitan area network, local area network, and the wireless network may include but is not limited to at least one of the following: WIFI (Wireless Fidelity), Bluetooth. The terminal device 102 may be but is not limited to a PC, a mobile phone, a tablet computer, a smart air conditioner, a smart range hood, a smart refrigerator, a smart oven, a smart stove, a smart washing machine, a smart water heater, a smart washing device, a smart dishwasher, a smart projection device, a smart TV, a smart clothes drying rack, a smart curtain, a smart audio and video, a smart socket, a smart speaker, a smart fresh air device, a smart kitchen and bathroom device, a smart bathroom device, a smart sweeping robot, a smart window cleaning robot, a smart mopping robot, a smart air purification device, a smart steamer, a smart microwave oven, a smart kitchen treasure, a smart purifier, a smart water dispenser, a smart door lock, etc.

[0028] In this embodiment, a method for allocating microphone control permissions is provided, which is applied to the above terminal device. Figure 2: is a flowchart of a method for allocating microphone control permissions according to an embodiment of the present application, and the process includes the following steps:

[0029] Step S202, receiving a microphone control request sent by the target application software, wherein the microphone control request is used to request to obtain control authority for the microphone;

[0030] Step S204, parsing the microphone control request to obtain a request type of the microphone control request, wherein the request type includes a mutually exclusive type, a queue type, and a default type;

[0031] Step S206: allocating control authority of the microphone to the target application software according to the request type of the microphone control request, wherein the allocation method of the control authority of the microphone is determined by the request type.

[0032] It should be noted that in the above step S206, different allocation methods include but are not limited to waiting for other application software to finish using the microphone before allocating the microphone control authority to the target application software, and directly preempting the microphone control authority of other application software.

[0033] Through the above steps, after receiving the microphone control request of the target application software, the microphone control request can be parsed to obtain the request type of the microphone control request, and then the allocation method of the microphone control permission is determined for the target application software according to the request type of the microphone control request, thereby solving the problem of chaotic microphone permission allocation in related technologies and achieving the effect of reasonably allocating microphone permissions.

[0034] In an exemplary embodiment, control permissions are allocated to the target application software according to the request type of the microphone control request, including: when it is determined that the request type of the microphone control request is the mutually exclusive type, sending a message to all application software, wherein the message is used to instruct the application software currently occupying the control permission of the microphone to release the control permission of the microphone; and allocating the control permission of the microphone to the target application software.

[0035] Optionally, in the above embodiment, the exclusive use of microphones can be achieved through cross-process communication methods such as broadcasting. Before using the microphone, the target application software first sends a broadcast message to all application software. If an application software is using the microphone, it stops using the microphone after receiving the above broadcast message, releases the control authority of the microphone, and then allocates the control authority of the microphone to the target application software.

[0036] In an exemplary embodiment, control permissions are allocated to the target application software according to the request type of the microphone control request, including: when it is determined that the request type of the microphone control request is the queue type, adding the microphone control request to a waiting queue; obtaining a sorting priority of the microphone control request in the waiting queue, wherein the sorting priority is determined according to the time when the microphone control request is added to the waiting queue; when it is determined that the sorting priority is the highest priority and the application software currently occupying the control permission of the microphone has released the control permission of the microphone, allocating the control permission of the microphone to the target application software.

[0037] Optionally, in the above embodiment, the sorting priority is determined according to the time when the microphone control request is added to the waiting queue. The earlier the time when the microphone control request is added to the waiting queue, the higher the priority of the microphone control request.

[0038] In an exemplary embodiment, control permissions are allocated to the target application software according to the request type of the microphone control request, including: when it is determined that the request type of the microphone control request is the default type, obtaining the queue status of the waiting queue; when it is determined that the queue status indicates that there is no microphone control request in the waiting queue, obtaining the occupancy status of the control permission of the microphone; when it is determined that no application software occupies the control permission of the microphone, allocating the control permission of the microphone to the target application software.

[0039] Optionally, in the above embodiment, when the microphone is in an idle state and there is no application software waiting to use the microphone, a default application software can be used to use the microphone. For example, the default application software may be an intelligent voice assistant. When other application software needs to use the microphone, the intelligent voice assistant is controlled to release the microphone permission.

[0040] In an exemplary embodiment, after allocating control permissions for the microphone to the target application software based on the request type of the microphone control request, the method further includes: after receiving a recording request initiated by the target object, sending an instruction to a remote recording device to instruct the remote recording device to collect an audio signal; after determining that the remote recording device has completed the collection of the audio signal, sending the audio signal to the target application software.

[0041] Optionally, in the above embodiment, in addition to collecting audio signals through the microphone of the TV, audio signals can also be collected through remote recording devices such as smart doorbells, smart cameras, etc. In some linkage scenarios, the application software on the TV may need to obtain audio signals collected by other devices.

[0042] In an exemplary embodiment, before sending the audio signal to the target application software, the method also includes: converting the audio signal into an audio stream array through a preset audio algorithm, and adding the audio stream array to a cache queue; processing the audio stream array in the cache queue according to a preset audio format of the target application software to obtain audio in the preset audio format; and sending the audio in the preset audio format to the target application software.

[0043] Optionally, in the above embodiment, the audio signal collected by the remote recording device and the audio signal input by the microphone of the TV may be audio signals of different formats. There may be compatibility issues when the application software processes audio of different formats. Therefore, the audio signal collected by the remote recording device needs to be formatted uniformly before being sent to the target application.

[0044] In an exemplary embodiment, after allocating control rights of the microphone to the target application software according to the request type of the microphone control request, the method further includes: sending a confirmation message to the target application software, wherein the confirmation message is used to confirm with the target application software whether to continue using the microphone; within a preset time period after sending the confirmation message, if it is determined that no response information from the target application software has been received, releasing the control rights of the microphone from the target application software, wherein the response information is used to indicate that the target application software confirms to continue using the microphone.

[0045] In order to better understand the process of the method for allocating the above-mentioned microphone control authority, the implementation method flow of the above-mentioned microphone control is described below in combination with an optional embodiment, but it is not used to limit the technical solution of the embodiment of the present application.

[0046] In an alternative embodiment, Figure 3 is a schematic flow chart of a method for allocating microphone control permissions according to an embodiment of the present application, such as Figure 3 As shown, the specific process includes the following:

[0047] Step S301: the user initiates recording in the target application software, and the target application software requests control authority for the microphone;

[0048] Step S302: registering a recording task (equivalent to a microphone control request);

[0049] Optionally, in the above step S302, registering the recording task refers to configuring attribute parameters in the request information when the target application software initiates a recording request. Specific attribute parameter configuration information is shown in Table 1.

[0050] Table 1

[0051]

[0052] Step S303: determining the recording type (equivalent to the type of microphone control request) through the configuration information of the recording task;

[0053] Step S304: Determine that the recording type is one of the mutually exclusive type, the queue type, and the default type, that is, select one of steps S304-1, S304-2, and S304-3 to execute;

[0054] Step S304-1: When it is determined that the recording type is a mutually exclusive type, a broadcast message is sent to notify other application software to release the microphone control permission, and the microphone control permission is allocated to the target application software. This type has the highest priority, such as a voice call scenario;

[0055] Step S304-2: When it is determined that the recording type is a queue type, the recording task is added to the waiting queue, and the microphone control authority is obtained in order from the earliest to the latest according to the adding time;

[0056] Step S304-3: When it is determined that the recording type is the default type, and the microphone is in an idle state and there is no application waiting in line to use the microphone, the control authority of the microphone is assigned to the default application, which has the lowest priority, such as voice assistant software.

[0057] Step S305: updating the control authority of the microphone in the manner of step S304;

[0058] Step S306: Determine the application software currently using the microphone.

[0059] Through the above embodiments, the problem of competition among microphone permissions can be solved, the coupling between voice services can be reduced, and the user experience when using the voice function in the application can be improved.

[0060] In an alternative embodiment, Figure 4 is a schematic flow chart of a method for allocating microphone control permissions according to an embodiment of the present application, such as Figure 4 As shown, the specific process includes the following:

[0061] Step S401: the television receives a recording request;

[0062] Step S402: Determine whether recording is initiated by the voice button on the TV remote control, if yes, execute step S403, otherwise execute step S404;

[0063] Step S403: collect audio signals through the TV remote control recording, and execute step S405;

[0064] Step S404: collect audio signals through remote recording equipment, and execute step S405;

[0065] Step S405: transmitting the collected audio signal to the recording middleware;

[0066] Step S406: Performing format processing on the audio signal through an audio algorithm to unify the audio format standards between different devices or applications;

[0067] Optionally, in the above step S406, the recording middleware is in a state of waiting to be awakened. The awakening method can be determined by determining whether a hardware medium state has changed (such as a remote control voice button), or it may be a wake-up word or a recording request. When in the ready state, the microphone responsible for recording begins to continuously output the audio stream to the recording middleware. The recording middleware will split or assemble the received audio stream into the audio stream array required by the target application software according to the buffer size, and add it to the buffer queue. During the splitting and assembly, the audio stream array can be processed by optimization algorithm (for example, signal amplification, noise optimization, etc.).

[0068] Step S407: query the permission information of the current microphone to determine the application software currently using the microphone;

[0069] Step S408: Send the processed audio to the application software currently using the microphone.

[0070] Optionally, in the above step S408, since the recording middleware processes the audio stream array according to the target application software, the compatibility adaptation work of the audio input and output can be greatly reduced.

[0071] Through the above embodiments, the voice middleware is used as a bridge between the voice audio stream and the audio processing end, so that the audio flow process is simpler, the differences between different applications or devices are eliminated, and the cost of related voice scene adaptation is effectively reduced.

[0072] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods of each embodiment of the present application.

[0073] Figure 5is a structural block diagram of a microphone control device according to an embodiment of the present application; Figure 5 As shown, including:

[0074] The receiving module 52 is used to receive a microphone control request sent by the target application software, wherein the microphone control request is used to request to obtain the control authority of the microphone;

[0075] A parsing module 54, configured to parse the microphone control request to obtain a request type of the microphone control request, wherein the request type includes a mutually exclusive type, a queue type, and a default type;

[0076] The allocation module 56 is configured to allocate the control authority of the microphone to the target application software according to the request type of the microphone control request, wherein the allocation method of the control authority of the microphone is determined by the request type.

[0077] Through the above-mentioned device, after receiving the microphone control request of the target application software, the microphone control request can be parsed to obtain the request type of the microphone control request, and then the allocation method of the microphone control permission can be determined for the target application software according to the request type of the microphone control request, thereby solving the problem of chaotic microphone permission allocation in related technologies and achieving the effect of reasonably allocating microphone permissions.

[0078] In an exemplary embodiment, the allocation module 56 is further used to: when it is determined that the request type of the microphone control request is the mutually exclusive type, send a message to all application software, wherein the message is used to instruct the application software currently occupying the control authority of the microphone to release the control authority of the microphone; and allocate the control authority of the microphone to the target application software.

[0079] In an exemplary embodiment, the above-mentioned allocation module 56 is also used to: when it is determined that the request type of the microphone control request is the queue type, add the microphone control request to the waiting queue; obtain the sorting priority of the microphone control request in the waiting queue, wherein the sorting priority is determined according to the time when the microphone control request is added to the waiting queue; when it is determined that the sorting priority is the highest priority and the application software currently occupying the control authority of the microphone has released the control authority of the microphone, allocate the control authority of the microphone to the target application software.

[0080] In an exemplary embodiment, the allocation module 56 is also used to: when it is determined that the request type of the microphone control request is the default type, obtain the queue status of the waiting queue; when it is determined that the queue status indicates that there is no microphone control request in the waiting queue, obtain the occupancy status of the control authority of the microphone; when it is determined that no application software occupies the control authority of the microphone, allocate the control authority of the microphone to the target application software.

[0081] In an exemplary embodiment, the above-mentioned allocation module 56 is also used to: after receiving a recording request initiated by the target object, send an instruction to the remote recording device to instruct the remote recording device to collect the audio signal; after determining that the remote recording device has completed the collection of the audio signal, send the audio signal to the target application software.

[0082] In an exemplary embodiment, the above-mentioned allocation module 56 is also used to: convert the audio signal into an audio stream array through a preset audio algorithm, and add the audio stream array to the cache queue; process the audio stream array in the cache queue according to the preset audio format of the target application software to obtain audio in the preset audio format; and send the audio in the preset audio format to the target application software.

[0083] In an exemplary embodiment, the allocation module 56 is further used to: send a confirmation message to the target application software, wherein the confirmation message is used to confirm with the target application software whether to continue using the microphone; within a preset time period after sending the confirmation message, if it is determined that no response message from the target application software has been received, release the control authority of the microphone from the target application software, wherein the response message is used to indicate that the target application software confirms to continue using the microphone.

[0084] An embodiment of the present application further provides a storage medium, which includes a stored program, wherein the program executes any of the above methods when it is run.

[0085] Optionally, in this embodiment, the storage medium may be configured to store program codes for executing the following steps:

[0086] S1, receiving a microphone control request sent by a target application software, wherein the microphone control request is used to request to obtain control authority of the microphone;

[0087] S2, parsing the microphone control request to obtain a request type of the microphone control request, wherein the request type includes a mutually exclusive type, a queue type, and a default type;

[0088] S3: Allocate control authority of the microphone to the target application software according to the request type of the microphone control request, wherein an allocation method of the control authority of the microphone is determined by the request type.

[0089] An embodiment of the present application further provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.

[0090] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.

[0091] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:

[0092] S1, receiving a microphone control request sent by a target application software, wherein the microphone control request is used to request to obtain control authority of the microphone;

[0093] S2, parsing the microphone control request to obtain a request type of the microphone control request, wherein the request type includes a mutually exclusive type, a queue type, and a default type;

[0094] S3: Allocate control authority of the microphone to the target application software according to the request type of the microphone control request, wherein an allocation method of the control authority of the microphone is determined by the request type.

[0095] Optionally, in this embodiment, the above-mentioned storage medium may include but is not limited to: a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and other media that can store program codes.

[0096] An embodiment of the present application further provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the steps in any one of the above method embodiments are implemented.

[0097] An embodiment of the present application further provides another computer program product, including a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in any of the above method embodiments are implemented.

[0098] The embodiments of the present application also provide a computer program, which includes computer instructions, which are stored in a computer-readable storage medium; a processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the steps in any one of the above method embodiments.

[0099] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments and optional implementation modes, and this embodiment will not be described in detail here.

[0100] Obviously, those skilled in the art should understand that the above modules or steps of the present application can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, and optionally, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order from that herein, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.

[0101] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A method for allocating microphone control authority, characterized in that: include: Receiving a microphone control request sent by a target application software, wherein the microphone control request is used to request to obtain control authority of the microphone; Parsing the microphone control request to obtain a request type of the microphone control request, wherein the request type includes a mutually exclusive type, a queue type, and a default type; The control authority of the microphone is allocated to the target application software according to the request type of the microphone control request, wherein the allocation method of the control authority of the microphone is determined by the request type.

2. The method for allocating microphone control authority according to claim 1, characterized in that: Allocating control authority to the target application software according to the request type of the microphone control request includes: In the case where it is determined that the request type of the microphone control request is the mutually exclusive type, sending a message to all application software, wherein the message is used to instruct the application software currently occupying the control authority of the microphone to release the control authority of the microphone; Allocate control authority of the microphone to the target application software.

3. The method for allocating microphone control authority according to claim 1, characterized in that: Allocating control authority to the target application software according to the request type of the microphone control request includes: In a case where it is determined that the request type of the microphone control request is the queue type, adding the microphone control request to a waiting queue; Obtaining a sorting priority of the microphone control request in the waiting queue, wherein the sorting priority is determined according to a time when the microphone control request is added to the waiting queue; When it is determined that the sorting priority is the highest priority and the application software currently occupying the control authority of the microphone has released the control authority of the microphone, the control authority of the microphone is allocated to the target application software.

4. The method for allocating microphone control authority according to claim 1, characterized in that: Allocating control authority to the target application software according to the request type of the microphone control request includes: In a case where it is determined that the request type of the microphone control request is the default type, obtaining a queue state of the waiting queue; When it is determined that the queue status indicates that there is no microphone control request in the waiting queue, obtaining the occupation status of the control authority of the microphone; When it is determined that no application software occupies the control authority of the microphone, the control authority of the microphone is allocated to the target application software.

5. The method for allocating microphone control authority according to claim 1, characterized in that: After allocating the control permission of the microphone to the target application software according to the request type of the microphone control request, the method further includes: After receiving a recording request initiated by a target object, sending a command to a remote recording device to instruct the remote recording device to collect an audio signal; After determining that the remote recording device completes the collection of the audio signal, the audio signal is sent to the target application software.

6. The method for allocating microphone control authority according to claim 5, characterized in that: Before sending the audio signal to the target application software, the method further includes: Convert the audio signal into an audio stream array by using a preset audio algorithm, and add the audio stream array to a cache queue; Processing the audio stream array in the cache queue according to the preset audio format of the target application software to obtain audio in the preset audio format; The audio in the preset audio format is sent to the target application software.

7. The method for allocating microphone control authority according to claim 1, characterized in that: After allocating the control permission of the microphone to the target application software according to the request type of the microphone control request, the method further includes: Sending a confirmation message to the target application software, wherein the confirmation message is used to confirm with the target application software whether to continue to use the microphone; Within a preset time period after sending the confirmation information, if it is determined that no response information from the target application software is received, the control authority of the microphone is released from the target application software, wherein the response information is used to indicate that the target application software confirms to continue using the microphone.

8. A microphone control device, characterized in that: include: A receiving module, used to receive a microphone control request sent by a target application software, wherein the microphone control request is used to request to obtain control authority of the microphone; A parsing module, used for parsing the microphone control request to obtain a request type of the microphone control request, wherein the request type includes a mutually exclusive type, a queue type, and a default type; The allocation module is used to allocate the control authority of the microphone to the target application software according to the request type of the microphone control request, wherein the allocation method of the control authority of the microphone is determined by the request type.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein the program executes the method described in any one of claims 1 to 7 when executed.

10. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 7 through the computer program.