CN111510820B - Microphone equipment expansion method and device and microphone equipment synchronization method and device - Google Patents

Microphone equipment expansion method and device and microphone equipment synchronization method and device Download PDF

Info

Publication number
CN111510820B
CN111510820B CN202010167315.0A CN202010167315A CN111510820B CN 111510820 B CN111510820 B CN 111510820B CN 202010167315 A CN202010167315 A CN 202010167315A CN 111510820 B CN111510820 B CN 111510820B
Authority
CN
China
Prior art keywords
microphone device
sub
microphone
driver
terminal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010167315.0A
Other languages
Chinese (zh)
Other versions
CN111510820A (en
Inventor
赵海钦
王建
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou Kaizhi Technology Co ltd
Original Assignee
Hangzhou Kaizhi Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou Kaizhi Technology Co ltd filed Critical Hangzhou Kaizhi Technology Co ltd
Priority to CN202010167315.0A priority Critical patent/CN111510820B/en
Publication of CN111510820A publication Critical patent/CN111510820A/en
Application granted granted Critical
Publication of CN111510820B publication Critical patent/CN111510820B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R1/00Details of transducers, loudspeakers or microphones
    • H04R1/20Arrangements for obtaining desired frequency or directional characteristics
    • H04R1/32Arrangements for obtaining desired frequency or directional characteristics for obtaining desired directional characteristic only
    • H04R1/40Arrangements for obtaining desired frequency or directional characteristics for obtaining desired directional characteristic only by combining a number of identical transducers
    • H04R1/406Arrangements for obtaining desired frequency or directional characteristics for obtaining desired directional characteristic only by combining a number of identical transducers microphones
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4411Configuring for operating with peripheral devices; Loading of device drivers

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • General Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • Otolaryngology (AREA)
  • Acoustics & Sound (AREA)
  • Signal Processing (AREA)
  • Circuit For Audible Band Transducer (AREA)

Abstract

The invention discloses a method and a device for expanding microphone equipment on a terminal and a method and a device for synchronizing the microphone equipment, wherein the method comprises the following steps: when detecting that at least one sub-microphone device is connected with a terminal, a main microphone device driver loaded on the terminal performs automatic adaptation updating based on the at least one sub-microphone device; the at least one sub-microphone device sends the collected audio data to the microphone device driver which is automatically adapted and updated; and automatically adapting the updated microphone device driver to output the data of the sub-microphone device to the terminal. In the embodiment of the invention, the expansion of the microphone equipment can be completed by using more configured terminals without integrating an algorithm, and the data processing part is arranged at the terminal part, so that the low delay can be realized.

Description

Microphone equipment expansion method and device and microphone equipment synchronization method and device
Technical Field
The invention relates to the technical field of microphone equipment expansion and data synchronization after the microphone equipment expansion, in particular to a microphone equipment expansion method and device and a microphone equipment synchronization method and device on a terminal.
Background
The existing MIC (microphone device) expansion scheme, such as the rocom scheme, needs to connect the expansion MIC to its original MIC device, so that multiple interfaces are needed to support the expansion MIC on the original MIC device, which brings great difficulty in structure and circuit; and inserting the expanded MIC into the main MIC, processing data by the main MIC, serving as equipment to send the data to an upper computer, and performing algorithm processing on the main MIC.
The technical problems of the existing method at least comprise that: the main MIC is subjected to algorithm processing, so the performance of the main MIC is stronger, and the cost is higher; the main MIC needs an external interface access sub MIC, and the structure and the circuit are difficult to realize; performing main MIC secondary data processing in an MIC access, and bringing unequal delay according to CPU performance; and after the MIC is extended, a technical problem how to implement data synchronization of the extended MIC needs to be solved.
Disclosure of Invention
The invention aims to overcome the defects of the prior art, and provides a microphone equipment expansion method and device and a microphone equipment synchronization method and device on a terminal, which can use a lower configured terminal to complete the expansion of microphone equipment without an integrated algorithm, and realize low delay when a data processing part is at a terminal part; and after the expansion, the data synchronization of the microphone device after the expansion is realized, and the noise influence is reduced.
In order to solve at least one technical problem, an embodiment of the present invention provides a microphone device extension method on a terminal, where the method includes:
when detecting that at least one sub-microphone device is connected with a terminal, a main microphone device driver loaded on the terminal performs automatic adaptation driver updating based on the at least one sub-microphone device;
the at least one sub-microphone device sends the collected audio data to the microphone device driver updated by the automatic adaptation driver; and the number of the first and second groups,
and automatically adapting the updated microphone equipment driver to output the data of the sub-microphone equipment to the terminal.
Optionally, after detecting that the at least one sub-microphone device is connected to the terminal, the method further includes:
and loading the driver corresponding to each sub-microphone device in the at least one sub-microphone device on the terminal.
Optionally, the type of the driver corresponding to the at least one sub-microphone device exposed in the operating system on the terminal is a non-standard microphone device driver.
Optionally, the automatically adapting driver update of the main microphone device driver loaded on the terminal based on the at least one sub-microphone device includes:
the main microphone equipment loaded on the terminal simulates the drive of one microphone equipment according to the corresponding drive;
the driver of the microphone device is updated based on the at least one sub-microphone device.
Optionally, the driving of the microphone device performs automatic adaptive driving update based on the at least one sub-microphone device, including:
acquiring the number of collected audio paths contained in each sub-microphone device based on the corresponding drive of each sub-microphone device in the at least one sub-microphone device;
and the drive of the microphone equipment is automatically adapted to drive and update according to the number of collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
Optionally, the automatically adapting, according to the number of collected audio channels included in each sub-microphone device of the at least one sub-microphone device, the driving of the microphone device to update the driving includes:
the microphone equipment is driven to increase the number of collected audio channels contained in each sub-microphone equipment in the at least one sub-microphone equipment on the basis of the original number of collected audio channels;
and the drive of the microphone equipment is automatically adapted to drive and update according to the number of the collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
Optionally, the number of the audio acquisition paths included in each sub-microphone device is one or two.
In addition, an embodiment of the present invention further provides a microphone device synchronization method on a terminal, where the method includes:
respectively adding a buffer area in the main microphone device and the at least one sub-microphone device;
the main microphone device and the at least one sub-microphone device respectively buffer the acquired audio data into respective buffer areas;
the terminal comprises a main microphone device, at least one sub-microphone device and a running system, wherein the running system on the terminal extracts the same amount of audio data in respective buffer areas of the main microphone device and the at least one sub-microphone device based on a preset clock period; and the number of the first and second groups,
and the respective buffer areas in the main microphone device and the at least one sub-microphone device adjust the speed of the corresponding microphone device for acquiring the audio data according to the amount of the cached audio data.
Optionally, the buffering the collected audio data into respective buffer areas by the main microphone device and the at least one sub-microphone device respectively includes:
the main microphone device and the at least one sub-microphone device respectively collect audio data according to the crystal oscillator frequency of the respective built-in chip;
and caching the collected audio data into respective buffer areas according to the time sequence.
Optionally, the data amount of the respective audio data stored in the respective buffer areas of the main microphone device and the at least one sub-microphone device is a preset specific value;
the number of the preset specific values is at least twice of the amount of the audio data extracted by the operating system on the terminal in a preset time period.
Optionally, the adjusting, by the buffer area in each of the main microphone device and the at least one sub-microphone device, the rate at which the corresponding microphone device acquires the audio data according to the amount of the buffered audio data includes:
comparing the amount of the audio data cached in the buffer areas of the main microphone device and the at least one sub-microphone device with a preset specific value;
and adjusting the rate of acquiring the audio data by the corresponding microphone equipment according to the comparison result.
Optionally, the adjusting the rate at which the corresponding microphone device acquires the audio data according to the comparison result includes:
when the comparison result is that the number of the cached audio data is smaller than a preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to be increased;
when the comparison result is that the number of the cached audio data is greater than a preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to be reduced;
and when the comparison result shows that the number of the cached audio data is equal to a preset specific value, adjusting the rate of acquiring the audio data by the corresponding microphone equipment to maintain.
In addition, an embodiment of the present invention further provides an expansion apparatus for a microphone device on a terminal, where the apparatus includes:
the simulation updating module: the terminal comprises a main microphone device driver, a sub-microphone device driver and a main microphone device driver, wherein the main microphone device driver is used for carrying out automatic adaptation driver updating on the basis of at least one sub-microphone device when the fact that at least one sub-microphone device is connected with the terminal is detected;
a data sending module: the microphone device driver is used for sending the acquired audio data to the microphone device driver after the automatic adaptation driver is updated by the at least one sub-microphone device; and the number of the first and second groups,
a data output module: and the data used for automatically adapting the microphone equipment driver after the driver update to output the sub-microphone equipment to the terminal.
In addition, an embodiment of the present invention further provides a microphone device synchronization apparatus on a terminal, where the apparatus includes:
a buffer addition module: the microphone device is used for respectively adding a buffer area in the main microphone device and the at least one sub-microphone device;
a data caching module: the main microphone device and the at least one sub-microphone device are used for respectively caching the acquired audio data into respective buffer areas;
a data extraction module: the running system used on the terminal respectively extracts the same amount of audio data in respective buffer areas of the main microphone device and the at least one sub-microphone device based on a preset clock period; and the number of the first and second groups,
the data acquisition and adjustment module: and the buffer areas used for the main microphone equipment and the at least one sub-microphone equipment respectively adjust the speed of the corresponding microphone equipment for acquiring the audio data according to the cached audio data quantity.
In the embodiment of the invention, when at least one sub-microphone device is detected to be connected with a terminal, a main microphone device driver loaded on the terminal carries out automatic adaptation driver updating based on the at least one sub-microphone device; the at least one sub-microphone device sends the collected audio data to the microphone device driver updated by the automatic adaptation driver; automatically adapting the updated microphone device driver to output the data of the sub-microphone device to the terminal; the expansion of the microphone equipment can be completed by using a lower configured terminal without integrating an algorithm, and the data processing part is arranged at the terminal part, so that low delay can be realized.
Adding a buffer area in the main microphone device and the at least one sub-microphone device respectively; the main microphone device and the at least one sub-microphone device respectively buffer the acquired audio data into respective buffer areas; the terminal comprises a main microphone device, at least one sub-microphone device and a running system, wherein the running system on the terminal extracts the same amount of audio data in respective buffer areas of the main microphone device and the at least one sub-microphone device based on a preset clock period; the buffer areas of the main microphone device and the at least one sub-microphone device respectively adjust the speed of the corresponding microphone device for acquiring the audio data according to the amount of the cached audio data; after the expansion, the data synchronization of the microphone device after the expansion is realized, and the noise influence is reduced.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a flowchart illustrating a microphone device extension method at a terminal according to an embodiment of the present invention;
fig. 2 is a flow chart illustrating a microphone device synchronization method at a terminal in an embodiment of the present invention;
fig. 3 is a flowchart illustrating a microphone device extension method and a microphone device synchronization method incorporated in a terminal in the present embodiment;
fig. 4 is a schematic structural composition diagram of a microphone device extension apparatus on a terminal in an embodiment of the present invention;
fig. 5 is a schematic structural component diagram of a microphone device synchronization apparatus on a terminal in an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Examples
Referring to fig. 1, fig. 1 is a flowchart illustrating a method for extending a microphone device on a terminal according to an embodiment of the present invention.
As shown in fig. 1, a microphone device extension method on a terminal, the method comprising:
s11: when detecting that at least one sub-microphone device is connected with a terminal, a main microphone device driver loaded on the terminal performs automatic adaptation driver updating based on the at least one sub-microphone device;
in this specific implementation process, after detecting that at least one sub-microphone device is connected to the terminal, the method further includes: and loading the driver corresponding to each sub-microphone device in the at least one sub-microphone device on the terminal.
Further, the type of the driver corresponding to the at least one sub-microphone device exposed in the terminal-upper operating system is a non-standard microphone device driver.
Further, the automatically adapting driver update of the main microphone device driver loaded on the terminal based on the at least one sub-microphone device includes: the main microphone equipment loaded on the terminal simulates the drive of one microphone equipment according to the corresponding drive; the driver of the microphone device is updated based on the at least one sub-microphone device.
Further, the driving of the microphone device is updated based on the at least one sub-microphone device by automatic adaptive driving, including: acquiring the number of collected audio paths contained in each sub-microphone device based on the corresponding drive of each sub-microphone device in the at least one sub-microphone device; and the drive of the microphone equipment is automatically adapted to drive and update according to the number of collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
Further, the automatically adapting the driving of the microphone device according to the number of collected audio channels included in each of the at least one sub-microphone device includes: the microphone equipment is driven to increase the number of collected audio channels contained in each sub-microphone equipment in the at least one sub-microphone equipment on the basis of the original number of collected audio channels; and the drive of the microphone equipment is automatically adapted to drive and update according to the number of the collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
Furthermore, the number of the audio acquisition paths contained in each sub-microphone device is one or two.
Specifically, an operating system running on the terminal detects whether sub-microphone devices are connected with the terminal by detecting changes of level signals of the access port, and generally when detecting that the sub-microphone devices are connected, the operating system obtains the number of the connected sub-microphone devices, which is at least one; in the implementation process, the sub-microphone device is generally connected to the terminal through the USB interface, which does not exclude that other interfaces may be subsequently used to connect to the terminal, depending on the type of the output port of the sub-microphone device.
After the sub-microphone device is connected to the terminal, the terminal starts to load the driver corresponding to the sub-microphone device, and the loaded driver, the driver type exposed in the operating system on the terminal, is the driver of the non-standard microphone device.
Before the sub-microphone device is inserted or the sub-microphone device to be inserted can normally work, a main microphone device must be present on the terminal, a corresponding driver of the main microphone device is also loaded on the terminal, and the type of the driver exposed on the operating system of the terminal is the microphone driver; when the terminal detects that the sub microphone device is inserted, and after the driver corresponding to the sub microphone device is loaded, the driver corresponding to the main microphone device performs automatic adaptation driver updating according to the driver corresponding to the sub microphone device.
The specific automatic adaptation drive updating process is that the main microphone equipment of the terminal simulates the drive of one microphone equipment according to the corresponding drive and then utilizes the drive of the microphone equipment to perform automatic adaptation drive updating according to the sub-microphone equipment; for example, the number of channels of the collected audio data included in each sub-microphone device is obtained according to the corresponding driver of each sub-microphone device in all the sub-microphone devices connected to the terminal, and then the driver of the microphone device performs automatic adaptation drive updating according to the number of channels of the collected audio data included in each sub-microphone device in all the sub-microphone devices in the terminal; for another example, the driver of the microphone device increases the number of paths for acquiring audio data included in each of all the sub-microphone devices in the terminal based on the original number of paths for acquiring audio data, and then the driver of the microphone device performs automatic adaptation driver update after increasing the number of paths for acquiring audio data included in each of all the sub-microphone devices in the terminal.
Generally, the number of paths for acquiring audio data included in each sub-microphone device is one or two; and the number of the sub-microphone devices accessing the terminal is online, specifically according to the limitation of the physical condition of the main microphone but not related to the interface of the terminal.
The main microphone device can be rapidly expanded in the mode.
S12: the at least one sub-microphone device sends the collected audio data to the microphone device driver updated by the automatic adaptation driver;
in the implementation process of the invention, when audio data is collected, the sub-microphone device connected to the terminal sends the collected audio data to the microphone device driver updated by the automatic adaptation driver.
S13: and automatically adapting the updated microphone equipment driver to output the data of the sub-microphone equipment to the terminal.
In the specific implementation process of the present invention, after the updated microphone device of the auto-adaptive driver receives the corresponding audio data, the audio data is output to the terminal, or the terminal extracts data from the updated microphone device of the auto-adaptive driver according to a certain clock cycle, where the data includes the audio data collected by the sub-microphone device and the audio data collected by the main microphone device.
In the embodiment of the invention, when at least one sub-microphone device is detected to be connected with a terminal, a main microphone device driver loaded on the terminal carries out automatic adaptation driver updating based on the at least one sub-microphone device; the at least one sub-microphone device sends the collected audio data to the microphone device driver updated by the automatic adaptation driver; automatically adapting the updated microphone device driver to output the data of the sub-microphone device to the terminal; the expansion of the microphone equipment can be completed by using a lower configured terminal without integrating an algorithm, and the data processing part is arranged at the terminal part, so that low delay can be realized.
Examples
Referring to fig. 2, fig. 2 is a flowchart illustrating a microphone device synchronization method on a terminal according to an embodiment of the present invention.
As shown in fig. 2, a microphone device synchronization method on a terminal, the method comprising:
s21: respectively adding a buffer area in the main microphone device and the at least one sub-microphone device;
in the implementation process of the invention, a buffer area is respectively added in the main microphone device and the sub-microphone device, and the buffer area is mainly used for caching the corresponding collected audio data.
Because the crystal oscillators in the main microphone device and the sub-microphone device for controlling the acquisition of the audio data have tolerance problems, the data acquisition is misaligned after the data acquisition is carried out for a long enough time, and the output data may have noise on the terminal.
S22: the main microphone device and the at least one sub-microphone device respectively buffer the acquired audio data into respective buffer areas;
in a specific implementation process of the present invention, the caching the collected audio data in respective buffer areas by the main microphone device and the at least one sub-microphone device includes: the main microphone device and the at least one sub-microphone device respectively collect audio data according to the crystal oscillator frequency of the respective built-in chip; and caching the collected audio data into respective buffer areas according to the time sequence.
Specifically, the main microphone device and the sub-microphone device respectively collect audio data according to the crystal oscillator frequency of the respective built-in chip, and then buffer the collected audio data into respective buffer areas according to the collected microphone devices according to the collected time sequence.
S23: the terminal comprises a main microphone device, at least one sub-microphone device and a running system, wherein the running system on the terminal extracts the same amount of audio data in respective buffer areas of the main microphone device and the at least one sub-microphone device based on a preset clock period;
in the specific implementation process of the invention, an operating system (operating system) on the terminal can respectively extract the same amount of audio data in respective buffer areas of the main microphone device and the sub-microphone device simultaneously according to a preset time period; therefore, the data quantity extracted each time is the same, the time sequence is also the same, the error of the data is ensured to be smaller, and the noise formed on the terminal is reduced to be within a controllable range.
S24: and the respective buffer areas in the main microphone device and the at least one sub-microphone device adjust the speed of the corresponding microphone device for acquiring the audio data according to the amount of the cached audio data.
In a specific implementation process of the present invention, the data amount of the respective audio data stored in the respective buffer areas of the main microphone device and the at least one sub-microphone device is a preset specific value; the number of the preset specific values is at least twice of the amount of the audio data extracted by the operating system on the terminal in a preset time period.
Further, the adjusting, by the buffer of each of the main microphone device and the at least one sub-microphone device, the rate at which the corresponding microphone device collects the audio data according to the amount of the buffered audio data includes: comparing the amount of the audio data cached in the buffer areas of the main microphone device and the at least one sub-microphone device with a preset specific value; and adjusting the rate of acquiring the audio data by the corresponding microphone equipment according to the comparison result.
Further, the adjusting the rate of acquiring the audio data by the corresponding microphone device according to the comparison result includes: when the comparison result is that the number of the cached audio data is smaller than a preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to be increased; when the comparison result is that the number of the cached audio data is greater than a preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to be reduced; and when the comparison result shows that the number of the cached audio data is equal to a preset specific value, adjusting the rate of acquiring the audio data by the corresponding microphone equipment to maintain.
Specifically, the data amount of the respective audio data stored in the respective buffer areas of the main microphone device and the sub-microphone device is a preset specific value, and is a preset specific value of the same data; the number of the preset specific values is generally twice as large as the amount of audio data extracted by the operating system on the terminal within a preset time period.
Comparing the audio data amount cached in the buffer areas of the main microphone equipment and the sub-microphone equipment with a preset specific value; and then adjusting the speed of the audio data collected by the corresponding microphone device according to the comparison result.
Specifically, when the comparison result is that the number of the cached audio data is smaller than a preset specific value, the rate of acquiring the audio data by the corresponding microphone device needs to be adjusted to be increased; when the comparison result shows that the number of the cached audio data is greater than a preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to be reduced; and when the comparison result shows that the number of the cached audio data is equal to the preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to maintain.
In the embodiment of the invention, a buffer area is respectively added in the main microphone device and the at least one sub-microphone device; the main microphone device and the at least one sub-microphone device respectively buffer the acquired audio data into respective buffer areas; the terminal comprises a main microphone device, at least one sub-microphone device and a running system, wherein the running system on the terminal extracts the same amount of audio data in respective buffer areas of the main microphone device and the at least one sub-microphone device based on a preset clock period; the buffer areas of the main microphone device and the at least one sub-microphone device respectively adjust the speed of the corresponding microphone device for acquiring the audio data according to the amount of the cached audio data; after the expansion, the data synchronization of the microphone device after the expansion is realized, and the noise influence is reduced.
Examples
Referring to fig. 3, fig. 3 is a flow chart illustrating a microphone device extension method and a microphone device synchronization method incorporated in a terminal according to an embodiment of the present invention
As shown in fig. 3, a data processing method on a terminal includes a microphone device extension method and a microphone device synchronization method, and specifically includes the following steps:
s31: when detecting that at least one sub-microphone device is connected with a terminal, a main microphone device driver loaded on the terminal performs automatic adaptation driver updating based on the at least one sub-microphone device;
s32: the at least one sub-microphone device sends the collected audio data to the microphone device driver updated by the automatic adaptation driver;
s33: respectively adding a buffer area in the main microphone device and the at least one sub-microphone device;
s34: the main microphone device and the at least one sub-microphone device respectively buffer the acquired audio data into respective buffer areas;
s35: the terminal comprises a main microphone device, at least one sub-microphone device and a running system, wherein the running system on the terminal extracts the same amount of audio data in respective buffer areas of the main microphone device and the at least one sub-microphone device based on a preset clock period;
s36: and the respective buffer areas in the main microphone device and the at least one sub-microphone device adjust the speed of the corresponding microphone device for acquiring the audio data according to the amount of the cached audio data.
In the implementation of the present invention, the specific implementation processes of S31-S36 can refer to the above embodiments, and are not described herein again.
By the embodiment, the expansion of the microphone equipment can be completed by using a lower-configuration terminal without integrating an algorithm, and the data processing part is arranged at the terminal part, so that low delay can be realized; and after the expansion, the data synchronization of the microphone device after the expansion is realized, and the noise influence is reduced.
Examples
Referring to fig. 4, fig. 4 is a schematic structural composition diagram of a microphone device expansion apparatus on a terminal according to an embodiment of the present invention.
As shown in fig. 4, a microphone device extension apparatus on a terminal, the apparatus comprising:
the simulation update module 41: the terminal comprises a main microphone device driver, a sub-microphone device driver and a main microphone device driver, wherein the main microphone device driver is used for carrying out automatic adaptation driver updating on the basis of at least one sub-microphone device when the fact that at least one sub-microphone device is connected with the terminal is detected;
in this specific implementation process, after detecting that at least one sub-microphone device is connected to the terminal, the method further includes: and loading the driver corresponding to each sub-microphone device in the at least one sub-microphone device on the terminal.
Further, the type of the driver corresponding to the at least one sub-microphone device exposed in the terminal-upper operating system is a non-standard microphone device driver.
Further, the automatically adapting driver update of the main microphone device driver loaded on the terminal based on the at least one sub-microphone device includes: the main microphone equipment loaded on the terminal simulates the drive of one microphone equipment according to the corresponding drive; the driver of the microphone device is updated based on the at least one sub-microphone device.
Further, the driving of the microphone device is updated based on the at least one sub-microphone device by automatic adaptive driving, including: acquiring the number of collected audio paths contained in each sub-microphone device based on the corresponding drive of each sub-microphone device in the at least one sub-microphone device; and the drive of the microphone equipment is automatically adapted to drive and update according to the number of collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
Further, the automatically adapting the driving of the microphone device according to the number of collected audio channels included in each of the at least one sub-microphone device includes: the microphone equipment is driven to increase the number of collected audio channels contained in each sub-microphone equipment in the at least one sub-microphone equipment on the basis of the original number of collected audio channels; and the drive of the microphone equipment is automatically adapted to drive and update according to the number of the collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
Furthermore, the number of the audio acquisition paths contained in each sub-microphone device is one or two.
Specifically, an operating system running on the terminal detects whether sub-microphone devices are connected with the terminal by detecting changes of level signals of the access port, and generally when detecting that the sub-microphone devices are connected, the operating system obtains the number of the connected sub-microphone devices, which is at least one; in the implementation process, the sub-microphone device is generally connected to the terminal through the USB interface, which does not exclude that other interfaces may be subsequently used to connect to the terminal, depending on the type of the output port of the sub-microphone device.
After the sub-microphone device is connected to the terminal, the terminal starts to load the driver corresponding to the sub-microphone device, and the loaded driver, the driver type exposed in the operating system on the terminal, is the driver of the non-standard microphone device.
Before the sub-microphone device is inserted or the sub-microphone device to be inserted can work normally, a main microphone device is necessarily required to be arranged on the terminal in advance, a corresponding driver of the main microphone device is loaded on the terminal, and the type of the driver exposed on an operating system of the terminal is a microphone driver; when the terminal detects that the sub microphone device is inserted, and after the driver corresponding to the sub microphone device is loaded, the driver corresponding to the main microphone device performs automatic adaptation driver updating according to the driver corresponding to the sub microphone device.
The specific automatic adaptation drive updating process is that the main microphone equipment of the terminal simulates the drive of one microphone equipment according to the corresponding drive and then utilizes the drive of the microphone equipment to perform automatic adaptation drive updating according to the sub-microphone equipment; for example, the number of channels of the collected audio data included in each sub-microphone device is obtained according to the corresponding driver of each sub-microphone device in all the sub-microphone devices connected to the terminal, and then the driver of the microphone device performs automatic adaptation drive updating according to the number of channels of the collected audio data included in each sub-microphone device in all the sub-microphone devices in the terminal; for another example, the driver of the microphone device increases the number of paths for acquiring audio data included in each of all the sub-microphone devices in the terminal based on the original number of paths for acquiring audio data, and then the driver of the microphone device performs automatic adaptation driver update after increasing the number of paths for acquiring audio data included in each of all the sub-microphone devices in the terminal.
Generally, the number of paths for acquiring audio data included in each sub-microphone device is one or two; and the number of the sub-microphone devices accessing the terminal is online, specifically according to the limitation of the physical condition of the main microphone but not related to the interface of the terminal.
The main microphone device can be rapidly expanded in the mode.
The data transmission module 42: the microphone device driver is used for sending the acquired audio data to the microphone device driver after the automatic adaptation driver is updated by the at least one sub-microphone device;
in the implementation process of the invention, when audio data is collected, the sub-microphone device connected to the terminal sends the collected audio data to the microphone device driver updated by the automatic adaptation driver.
The data output module 43: and the data used for automatically adapting the microphone equipment driver after the driver update to output the sub-microphone equipment to the terminal.
In the specific implementation process of the present invention, after the updated microphone device of the auto-adaptive driver receives the corresponding audio data, the audio data is output to the terminal, or the terminal extracts data from the updated microphone device of the auto-adaptive driver according to a certain clock cycle, where the data includes the audio data collected by the sub-microphone device and the audio data collected by the main microphone device.
In the embodiment of the invention, when at least one sub-microphone device is detected to be connected with a terminal, a main microphone device driver loaded on the terminal carries out automatic adaptation driver updating based on the at least one sub-microphone device; the at least one sub-microphone device sends the collected audio data to the microphone device driver updated by the automatic adaptation driver; and automatically adapting the microphone device driver updated by the driver to output the data of the sub-microphone device to the terminal; the expansion of the microphone equipment can be completed by using a lower configured terminal without integrating an algorithm, and the data processing part is arranged at the terminal part, so that low delay can be realized.
Examples
Referring to fig. 5, fig. 5 is a schematic structural composition diagram of a microphone device synchronization apparatus on a terminal according to an embodiment of the present invention.
As shown in fig. 5, a microphone device synchronization apparatus on a terminal, the apparatus comprising:
the buffer addition module 51: the microphone device is used for respectively adding a buffer area in the main microphone device and the at least one sub-microphone device;
in the implementation process of the invention, a buffer area is respectively added in the main microphone device and the sub-microphone device, and the buffer area is mainly used for caching the corresponding collected audio data.
Because the crystal oscillators in the main microphone device and the sub-microphone device for controlling the acquisition of the audio data have tolerance problems, the data acquisition is misaligned after the data acquisition is carried out for a long enough time, and the output data may have noise on the terminal.
The data cache module 52: the main microphone device and the at least one sub-microphone device are used for respectively caching the acquired audio data into respective buffer areas;
in a specific implementation process of the present invention, the caching the collected audio data in respective buffer areas by the main microphone device and the at least one sub-microphone device includes: the main microphone device and the at least one sub-microphone device respectively collect audio data according to the crystal oscillator frequency of the respective built-in chip; and caching the collected audio data into respective buffer areas according to the time sequence.
Specifically, the main microphone device and the sub-microphone device respectively collect audio data according to the crystal oscillator frequency of the respective built-in chip, and then buffer the collected audio data into respective buffer areas according to the collected microphone devices according to the collected time sequence.
The data extraction module 53: the running system used on the terminal respectively extracts the same amount of audio data in respective buffer areas of the main microphone device and the at least one sub-microphone device based on a preset clock period;
in the specific implementation process of the invention, an operating system (operating system) on the terminal can respectively extract the same amount of audio data in respective buffer areas of the main microphone device and the sub-microphone device simultaneously according to a preset time period; therefore, the data quantity extracted each time is the same, the time sequence is also the same, the error of the data is ensured to be smaller, and the noise formed on the terminal is reduced to be within a controllable range.
The data acquisition conditioning module 54: and the buffer areas used for the main microphone equipment and the at least one sub-microphone equipment respectively adjust the speed of the corresponding microphone equipment for acquiring the audio data according to the cached audio data quantity.
In a specific implementation process of the present invention, the data amount of the respective audio data stored in the respective buffer areas of the main microphone device and the at least one sub-microphone device is a preset specific value; the number of the preset specific values is at least twice of the amount of the audio data extracted by the operating system on the terminal in a preset time period.
Further, the adjusting, by the buffer of each of the main microphone device and the at least one sub-microphone device, the rate at which the corresponding microphone device collects the audio data according to the amount of the buffered audio data includes: comparing the amount of the audio data cached in the buffer areas of the main microphone device and the at least one sub-microphone device with a preset specific value; and adjusting the rate of acquiring the audio data by the corresponding microphone equipment according to the comparison result.
Further, the adjusting the rate of acquiring the audio data by the corresponding microphone device according to the comparison result includes: when the comparison result is that the number of the cached audio data is smaller than a preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to be increased; when the comparison result is that the number of the cached audio data is greater than a preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to be reduced; and when the comparison result shows that the number of the cached audio data is equal to a preset specific value, adjusting the rate of acquiring the audio data by the corresponding microphone equipment to maintain.
Specifically, the data amount of the respective audio data stored in the respective buffer areas of the main microphone device and the sub-microphone device is a preset specific value, and is a preset specific value of the same data; the number of the preset specific values is generally twice as large as the amount of audio data extracted by the operating system on the terminal within a preset time period.
Comparing the audio data amount cached in the buffer areas of the main microphone equipment and the sub-microphone equipment with a preset specific value; and then adjusting the speed of the audio data collected by the corresponding microphone device according to the comparison result.
Specifically, when the comparison result is that the number of the cached audio data is smaller than a preset specific value, the rate of acquiring the audio data by the corresponding microphone device needs to be adjusted to be increased; when the comparison result shows that the number of the cached audio data is greater than a preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to be reduced; and when the comparison result shows that the number of the cached audio data is equal to the preset specific value, the speed of acquiring the audio data by the corresponding microphone equipment needs to be adjusted to maintain.
In the embodiment of the invention, a buffer area is respectively added in the main microphone device and the at least one sub-microphone device; the main microphone device and the at least one sub-microphone device respectively buffer the acquired audio data into respective buffer areas; the terminal comprises a main microphone device, at least one sub-microphone device and a running system, wherein the running system on the terminal extracts the same amount of audio data in respective buffer areas of the main microphone device and the at least one sub-microphone device based on a preset clock period; the buffer areas of the main microphone device and the at least one sub-microphone device respectively adjust the speed of the corresponding microphone device for acquiring the audio data according to the amount of the cached audio data; after the expansion, the data synchronization of the microphone device after the expansion is realized, and the noise influence is reduced.
Those skilled in the art will appreciate that all or part of the steps in the methods of the above embodiments may be implemented by associated hardware instructed by a program, which may be stored in a computer-readable storage medium, and the storage medium may include: a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic or optical disk, or the like.
In addition, the method and the apparatus for extending a microphone device on a terminal, and the method and the apparatus for synchronizing a microphone device provided by the embodiments of the present invention are described in detail above, and a specific example should be used herein to explain the principle and the implementation of the present invention, and the description of the above embodiments is only used to help understanding the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (6)

1. A microphone apparatus extension method on a terminal, the method comprising:
when detecting that at least one sub-microphone device is connected with a terminal, a main microphone device driver loaded on the terminal performs automatic adaptation driver updating based on the at least one sub-microphone device;
the at least one sub-microphone device sends the collected audio data to the microphone device driver updated by the automatic adaptation driver; and the number of the first and second groups,
automatically adapting the updated microphone device driver to output the data of the sub-microphone device to the terminal;
the automatic adaptation driver update of the main microphone device driver loaded on the terminal based on the at least one sub-microphone device comprises:
the main microphone equipment loaded on the terminal simulates the drive of one microphone equipment according to the corresponding drive;
the driver of the microphone device performs an auto-adaptive driver update based on the at least one sub-microphone device;
the driving of the microphone device is updated based on the at least one sub-microphone device for automatic adaptation driving, including:
acquiring the number of collected audio paths contained in each sub-microphone device based on the corresponding drive of each sub-microphone device in the at least one sub-microphone device;
and the drive of the microphone equipment is automatically adapted to drive and update according to the number of collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
2. The microphone device expansion method according to claim 1, wherein after detecting that the at least one sub-microphone device is connected to the terminal, the method further comprises:
and loading the driver corresponding to each sub-microphone device in the at least one sub-microphone device on the terminal.
3. The microphone device expansion method according to claim 2, wherein the type of the driver corresponding to the at least one sub-microphone device exposed in the terminal-upper operating system is a non-standard microphone device driver.
4. The microphone device expansion method according to claim 1, wherein the driving of the microphone device is updated according to the number of captured audio paths included in each of the at least one sub-microphone device, and the method comprises:
the microphone equipment is driven to increase the number of collected audio channels contained in each sub-microphone equipment in the at least one sub-microphone equipment on the basis of the original number of collected audio channels;
and the drive of the microphone equipment is automatically adapted to drive and update according to the number of the collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
5. The microphone device expansion method according to claim 4, wherein the number of the collected audio paths included in each sub-microphone device is one or two.
6. An apparatus for extending a microphone device on a terminal, the apparatus comprising:
the simulation updating module: the terminal comprises a main microphone device driver, a sub-microphone device driver and a main microphone device driver, wherein the main microphone device driver is used for carrying out automatic adaptation driver updating on the basis of at least one sub-microphone device when the fact that at least one sub-microphone device is connected with the terminal is detected;
a data sending module: the microphone device driver is used for sending the acquired audio data to the microphone device driver after the automatic adaptation driver is updated by the at least one sub-microphone device; and the number of the first and second groups,
a data output module: the microphone equipment driver is used for automatically adapting the updated microphone equipment driver to output the data of the sub-microphone equipment to the terminal;
the automatic adaptation driver update of the main microphone device driver loaded on the terminal based on the at least one sub-microphone device comprises:
the main microphone equipment loaded on the terminal simulates the drive of one microphone equipment according to the corresponding drive;
the driver of the microphone device performs an auto-adaptive driver update based on the at least one sub-microphone device;
the driving of the microphone device is updated based on the at least one sub-microphone device for automatic adaptation driving, including:
acquiring the number of collected audio paths contained in each sub-microphone device based on the corresponding drive of each sub-microphone device in the at least one sub-microphone device;
and the drive of the microphone equipment is automatically adapted to drive and update according to the number of collected audio paths contained in each sub-microphone equipment in the at least one sub-microphone equipment.
CN202010167315.0A 2020-03-11 2020-03-11 Microphone equipment expansion method and device and microphone equipment synchronization method and device Active CN111510820B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010167315.0A CN111510820B (en) 2020-03-11 2020-03-11 Microphone equipment expansion method and device and microphone equipment synchronization method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010167315.0A CN111510820B (en) 2020-03-11 2020-03-11 Microphone equipment expansion method and device and microphone equipment synchronization method and device

Publications (2)

Publication Number Publication Date
CN111510820A CN111510820A (en) 2020-08-07
CN111510820B true CN111510820B (en) 2022-04-26

Family

ID=71877626

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010167315.0A Active CN111510820B (en) 2020-03-11 2020-03-11 Microphone equipment expansion method and device and microphone equipment synchronization method and device

Country Status (1)

Country Link
CN (1) CN111510820B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112687248B (en) * 2020-12-22 2023-10-31 广州番禺巨大汽车音响设备有限公司 Audio playing control method and device based on intelligent DJ sound system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102713795A (en) * 2010-08-18 2012-10-03 华为终端有限公司 Terminal, and I/O extension apparatus, method and system
CN205721746U (en) * 2016-05-24 2016-11-23 北京立华莱康平台科技有限公司 BIOS starts module and system board
CN108964970A (en) * 2017-05-24 2018-12-07 安讯士有限公司 For providing the equipment, system and method for additional function to device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI318369B (en) * 2006-10-02 2009-12-11 Egis Technology Inc Multi-functional storage apparatus and control method thereof

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102713795A (en) * 2010-08-18 2012-10-03 华为终端有限公司 Terminal, and I/O extension apparatus, method and system
CN205721746U (en) * 2016-05-24 2016-11-23 北京立华莱康平台科技有限公司 BIOS starts module and system board
CN108964970A (en) * 2017-05-24 2018-12-07 安讯士有限公司 For providing the equipment, system and method for additional function to device

Also Published As

Publication number Publication date
CN111510820A (en) 2020-08-07

Similar Documents

Publication Publication Date Title
TWI543803B (en) A web games is run of a method and an apparatus
CN101437111B (en) Devices and methods for extracting signal
CN105681821B (en) A kind of playback method of audio, play system and server
US7983866B2 (en) Device testing system and test data obtaining method
CN110888619B (en) Digital audio power amplifier synchronization circuit and method and electronic equipment
CN111510820B (en) Microphone equipment expansion method and device and microphone equipment synchronization method and device
CN106936930B (en) Method and device for preventing disconnection of webpage game
CN109257094B (en) Pre-emphasis value evaluation method and device for serial deserializing transmitter
CN110784422A (en) Cloud mobile phone network data separation method, device, medium and terminal equipment
CN110768664B (en) Data sampling method and device
CN114679665A (en) Bluetooth headset audio and video synchronization method and device, electronic equipment and storage medium
US20220124435A1 (en) Earphone upgrade method, earphone assembly, upgrade device and non-transitory computer readable storage medium
CN113242434B (en) Video compression method and related device
CN113014510A (en) Data caching method and device in distributed test of inertial navigation system
CN106658042A (en) Data pushing method, and related client and server
WO2024119944A1 (en) Parameter configuration method and apparatus, audio device group, and readable storage medium
CN107306397B (en) Terminal equipment network access method and device based on wireless communication technology
JP2000066948A (en) Memory lsi with compressed data input/output function
CN111190540B (en) Control method and device for write balance of memory interface
US11457423B2 (en) Radio communications
CN109361714B (en) User login authentication method, device, equipment and computer storage medium
CN103118092A (en) Method and device for realizing single login
CN107580247B (en) Vibration playing method and device and electronic equipment
CN109660670B (en) Automatic backlight adjusting method and system, terminal device and storage medium
CN107708036B (en) Method and device for debugging output power of audio equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant