CN108848262B - Mode conversion method for wearable equipment and related product - Google Patents

Mode conversion method for wearable equipment and related product Download PDF

Info

Publication number
CN108848262B
CN108848262B CN201810606177.4A CN201810606177A CN108848262B CN 108848262 B CN108848262 B CN 108848262B CN 201810606177 A CN201810606177 A CN 201810606177A CN 108848262 B CN108848262 B CN 108848262B
Authority
CN
China
Prior art keywords
data
production mode
sound production
mode
audio playing
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.)
Expired - Fee Related
Application number
CN201810606177.4A
Other languages
Chinese (zh)
Other versions
CN108848262A (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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201810606177.4A priority Critical patent/CN108848262B/en
Publication of CN108848262A publication Critical patent/CN108848262A/en
Application granted granted Critical
Publication of CN108848262B publication Critical patent/CN108848262B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • H04M1/72451User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to schedules, e.g. using calendar applications
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/16Sound input; Sound output
    • G06F3/162Interface to dedicated audio devices, e.g. audio drivers, interface to CODECs
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B1/00Details of transmission systems, not covered by a single one of groups H04B3/00 - H04B13/00; Details of transmission systems not characterised by the medium used for transmission
    • H04B1/38Transceivers, i.e. devices in which transmitter and receiver form a structural unit and in which at least one part is used for functions of transmitting and receiving
    • H04B1/3827Portable transceivers
    • H04B1/385Transceivers carried on the body, e.g. in helmets
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/60Substation equipment, e.g. for use by subscribers including speech amplifiers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • H04M1/72409User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by interfacing with external accessories
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • H04M1/72442User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality for playing music files

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Human Computer Interaction (AREA)
  • Multimedia (AREA)
  • Theoretical Computer Science (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • General Health & Medical Sciences (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • Telephone Function (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The embodiment of the application discloses a mode switching method of a wearable device and a related product, wherein the method is applied to the wearable device and comprises the following steps: the system comprises a processing component, a first audio playing component, a second audio playing component and a wireless transceiver; the first audio playing component works through a first sound production mode, and the second audio playing component works through a second sound production mode; the method comprises the following steps: the method comprises the steps of keeping wireless connection with the electronic equipment, and receiving an audio file through the wireless connection; and controlling the first audio playing component to play the audio file by adopting a first sound production mode, acquiring first time of playing the first sound production mode, and controlling the second audio playing component to play the audio file by adopting a second sound production mode if the first time exceeds a time threshold. The technical scheme provided by the application has the advantage of high user experience.

Description

Mode conversion method for wearable equipment and related product
Technical Field
The application relates to the technical field of mobile terminal accessories, in particular to a mode conversion method for wearable equipment and a related product.
Background
With the popularization and application of smart phones, users increasingly rely on smart phones, and wearable devices, such as wireless earphones, smart watches, smart bracelets and other devices, are also widely applied with the rise of smart phones. For wearable equipment, use wireless headset here as an example, wireless headset has the advantage of being connected with the smart mobile phone conveniently, and for wireless headset, it is too long in the live time, unable conversion mode, and it is healthy to use wireless headset influence ear like this for a long time, has influenced user's experience degree.
Disclosure of Invention
The embodiment of the application provides a mode conversion method for a wearable device and the wearable device, so that the mode conversion can be executed according to time, and the user experience is improved.
In a first aspect, an embodiment of the present application provides a wearable device, where the wearable device includes: the system comprises a processing component, a first audio playing component, a second audio playing component and a wireless transceiver; the processing component is connected with the first audio playing component, the second audio playing component and the wireless transceiver respectively, the first audio playing component works in a first sound production mode, and the second audio playing component works in a second sound production mode;
the wireless transceiver is used for keeping wireless connection with the electronic equipment and receiving the audio file through the wireless connection;
the processing component is configured to control the first audio playing component to play the audio file in a first sound generation mode, acquire a first time of playing the first sound generation mode, and control the second audio playing component to play the audio file in the second sound generation mode if the first time exceeds a time threshold.
In a second aspect, a mode switching method for a wearable device is provided, where the method is applied to the wearable device and includes: the system comprises a processing component, a first audio playing component, a second audio playing component and a wireless transceiver; the first audio playing component works through a first sound production mode, and the second audio playing component works through a second sound production mode; the method comprises the following steps:
the method comprises the steps of keeping wireless connection with the electronic equipment, and receiving an audio file through the wireless connection;
and controlling the first audio playing component to play the audio file by adopting a first sound production mode, acquiring first time of playing the first sound production mode, and controlling the second audio playing component to play the audio file by adopting a second sound production mode if the first time exceeds a time threshold.
In a third aspect, a computer-readable storage medium is provided, which stores a computer program for electronic data exchange, wherein the computer program causes a computer to perform the method provided in the second aspect.
In a fourth aspect, there is provided a computer program product comprising a non-transitory computer readable storage medium storing a computer program operable to cause a computer to perform the method provided by the second aspect
It can be seen that after the audio file is obtained by the technical scheme provided by the application, the processing component can control the first audio playing component to play the audio file in the first sound production mode, when the first time of playing exceeds a time threshold, the first sound production mode is switched to the second sound production mode, namely, the audio file is played in the second sound production mode, and because the sound production modes after mode conversion are different, the influence of sound on ear health can be reduced, and the user experience degree is improved.
Drawings
In order to more clearly illustrate the embodiments of the present application 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 application, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic diagram of a network architecture of a wearable device and a wireless communication device.
Fig. 1a is a schematic structural diagram of a wireless headset provided in the present application.
Fig. 1b is a schematic structural diagram of an electronic device provided in the present application.
Fig. 2 is a schematic structural diagram of a wearable device provided in the present application.
Fig. 3a is a schematic structural diagram of an input matrix according to an embodiment of the present application.
Fig. 3b is a schematic structural diagram of inputting three-dimensional data according to an embodiment of the present application.
Fig. 4 is a flowchart illustrating a wearable device mode switching method according to the present application.
Fig. 5 is a block diagram of a partial structure of a wearable device connected to a mobile terminal according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, 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 inventive step, are within the scope of the present disclosure.
The terms "first," "second," and the like in the description and claims of the present application and in the above-described drawings are used for distinguishing between different objects and not for describing a particular order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the application. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
The wireless communication device according to the embodiment of the present application may include various handheld devices, vehicle-mounted devices, wearable devices, computing devices or other processing devices connected to a wireless modem, and various forms of User Equipment (UE), Mobile Stations (MS), terminal devices (terminal device), and the like. For convenience of description, the above-mentioned devices are collectively referred to as wireless communication devices.
In the wearable device provided in the first aspect,
the processing component is specifically configured to acquire a second time for playing the second sound generation mode, and control the first audio playing component to play the audio file in the first sound generation mode if the second time exceeds a time threshold.
In the wearable device provided in the first aspect,
the wearable device further includes: an acceleration sensor connected to the processing component;
the acceleration sensor is used for acquiring acceleration data;
the processing unit is used for forming input data according to the collected acceleration data and the collection time of the collected acceleration data, inputting the input data into a preset neural network model, executing multilayer forward operation to obtain a forward operation result, and determining whether to switch the sound production mode according to the forward operation result.
In the wearable device provided in the first aspect,
the processing component is specifically configured to obtain a type of sample input data and an arrangement rule of the sample input data in a training sample of the preset neural network model, and if the type is matrix data, form an input matrix by the acceleration data and the acquisition time according to the arrangement rule, and if the type is a three-dimensional data block, form an input three-dimensional data block by the acceleration data and the acquisition time according to the arrangement rule.
In the wearable device provided in the first aspect, the processing unit is specifically configured to obtain a type of sample input data in a training sample of a preset neural network model and an arrangement rule of the sample input data, where the type is matrix data [ H [ ]0】【W0Determining total amount of acceleration data and acquisition time Y, e.g. Y < H0*W0(ii) a Computing
Figure GDA0002678473300000041
Executing a process of inserting n values to obtain data after the insertion process, wherein the process of inserting n values specifically includes: inserting n acceleration data into the acceleration data, inserting n acquisition times into the acquisition times, and forming an input matrix according to the arrangement rule by the data after insertion processing, wherein the size of the input matrix is [ H ]0】【W0H, the H0Is a height value of the matrix, the W0May be the width value of the matrix.
In the wearable device provided in the first aspect,
the processing component is specifically configured to extract, from the forward operation result, X elements whose element values are greater than a set threshold and X positions corresponding to the X elements, and determine that the forward operation result is a switching of the sounding mode if more than X/2 of the X positions correspond to a switching of the sounding mode; if the occurrence mode corresponding to more than X/2 positions in the X positions is not switched, determining that the forward operation structure is not switched in the sound production mode; and X is an integer greater than or equal to 2.
In the method provided in the second aspect, a second time of playing the second sound emission mode is acquired, and if the second time exceeds a time threshold, the first audio playing component is controlled to play the audio file in the first sound emission mode.
In a second aspect, there is provided a method in which the wearable device further includes: an acceleration sensor connected to the processing component; the method further comprises the following steps:
acquiring acceleration data;
and forming input data according to the acquired acceleration data and the acquisition time of the acquired acceleration data, inputting the input data into a preset neural network model, executing multilayer forward operation to obtain a forward operation result, and determining whether to switch the sound production mode according to the forward operation result.
In the method provided in the second aspect, the forming input data according to the collected acceleration data and the collection time of the collected acceleration data specifically includes:
and acquiring the type of sample input data and the arrangement rule of the sample input data in a training sample of the preset neural network model, if the type is matrix data, forming an input matrix by the acceleration data and the acquisition time according to the arrangement rule, and if the type is a three-dimensional data block, forming an input three-dimensional data block by the acceleration data and the acquisition time according to the arrangement rule.
In the method provided in the second aspect, the determining whether to perform the switching of the sound emission mode according to the forward operation result specifically includes:
extracting X elements with element values larger than a set threshold value and X positions corresponding to the X elements from the forward operation result, and determining that the forward operation result is the switching of the sound production mode if the X positions exceed X/2 positions corresponding to the switching of the sound production mode; if the occurrence mode corresponding to more than X/2 positions in the X positions is not switched, determining that the forward operation structure is not switched in the sound production mode; and X is an integer greater than or equal to 2.
Referring to fig. 1, fig. 1 is a schematic diagram of a network architecture disclosed in an embodiment of the present application, where the network architecture may include an electronic device and a wireless headset, where the wireless headset may be communicatively connected to the electronic device through a wireless network (e.g., bluetooth, infrared, or WiFi). It should be noted that the wireless headset may include one or more earplugs, and the embodiments of the present application are not limited thereto. In a specific implementation, the wireless headset may send a pairing request to the electronic device, and the electronic device may receive the pairing request sent by the wearable device, where the wearable device includes at least one independent component, and in response to the pairing request, detect a number of components included in the wearable device, and display information of the wearable device, such as an electric quantity, a pairing number, and the like, according to the number of components.
Fig. 1a is a structural diagram of a wireless headset according to an embodiment of the present disclosure, as shown in fig. 1a, two earplugs may be completely separated from each other. As shown in fig. 1a, the wireless headset includes: two earplugs, each earplug comprising: an earbud housing 121, a speaker disposed on a surface of the earbud housing 121, the earbud further comprising: the wireless transceiver 122, a processing chip (not shown), and a battery (not shown), wherein the processing chip is electrically connected to the touch pad, the wireless transceiver, and the speaker, specifically, the electrical connection may be through a bus, but in practical applications, the electrical connection may also be through other connection methods.
Referring to fig. 1b, fig. 1b is a schematic structural diagram of an electronic device disclosed in the embodiment of the present application, the electronic device 100 includes a storage and processing circuit 110, and a communication circuit 120 and an audio component 140 connected to the storage and processing circuit 110, wherein in some specific electronic devices 100, a display component 130 or a touch component may be further disposed.
The electronic device 100 may include control circuitry, which may include storage and processing circuitry 110. The storage and processing circuitry 110 may be a memory, such as a hard drive memory, a non-volatile memory (e.g., flash memory or other electronically programmable read-only memory used to form a solid state drive, etc.), a volatile memory (e.g., static or dynamic random access memory, etc.), etc., and the embodiments of the present application are not limited thereto. Processing circuitry in storage and processing circuitry 110 may be used to control the operation of electronic device 100. The processing circuitry may be implemented based on one or more microprocessors, microcontrollers, digital signal processors, baseband processors, power management units, audio codec chips, application specific integrated circuits, display driver integrated circuits, and the like.
The storage and processing circuitry 110 may be used to run software in the electronic device 100, such as Voice Over Internet Protocol (VOIP) telephone call applications, simultaneous interpretation functions, media playing applications, operating system functions, and so forth. Such software may be used to perform control operations such as, for example, camera-based image capture, ambient light measurement based on an ambient light sensor, proximity sensor measurement based on a proximity sensor, information display functions implemented based on a status indicator such as a status indicator light of a light emitting diode, touch event detection based on a touch sensor, operations associated with performing wireless communication functions, operations associated with collecting and generating audio signals, control operations associated with collecting and processing button press event data, and other functions in the electronic device 100, to name a few.
The electronic device 100 may also include input-output circuitry 150. The input-output circuit 150 may be used to enable the electronic device 100 to input and output data, i.e., to allow the electronic device 100 to receive data from an external device and also to allow the electronic device 100 to output data from the electronic device 100 to the external device. The input-output circuit 150 may further include a sensor 170. The sensors 170 may include ambient light sensors, optical and capacitive based proximity sensors, touch sensors (e.g., optical based touch sensors and/or capacitive touch sensors, where the touch sensors may be part of a touch display screen or may be used independently as a touch sensor structure), acceleration sensors, and other sensors, among others.
The input-output circuitry 150 may also include a touch sensor array (i.e., the display component 130 may be a touch display screen). The touch sensor may be a capacitive touch sensor formed by a transparent touch sensor electrode (e.g., an Indium Tin Oxide (ITO) electrode) array, or may be a touch sensor formed using other touch technologies, such as acoustic wave touch, pressure sensitive touch, resistive touch, optical touch, and the like, and the embodiments of the present application are not limited thereto.
The electronic device 100 may also include an audio component 140. The audio component 140 may be used to provide audio input and output functionality for the electronic device 100. The audio components 140 in the electronic device 100 may include a speaker, a microphone, a buzzer, a tone generator, and other components for generating and detecting sound.
The communication circuit 120 may be used to provide the electronic device 100 with the capability to communicate with external devices. The communication circuit 120 may include analog and digital input-output interface circuits, and wireless communication circuits based on radio frequency signals and/or optical signals. The wireless communication circuitry in communication circuitry 120 may include radio-frequency transceiver circuitry, power amplifier circuitry, low noise amplifiers, switches, filters, and antennas. For example, the wireless Communication circuitry in Communication circuitry 120 may include circuitry to support Near Field Communication (NFC) by transmitting and receiving Near Field coupled electromagnetic signals. For example, the communication circuit 120 may include a near field communication antenna and a near field communication transceiver. The communications circuitry 120 may also include a cellular telephone transceiver and antenna, a wireless local area network transceiver circuitry and antenna, and so forth.
The electronic device 100 may further include a battery, power management circuitry, and other input-output units 160. The input-output unit 160 may include buttons, joysticks, click wheels, scroll wheels, touch pads, keypads, keyboards, cameras, light emitting diodes or other status indicators, and the like.
A user may input commands through input-output circuitry 150 to control the operation of electronic device 100, and may use output data of input-output circuitry 150 to enable receipt of status information and other outputs from electronic device 100.
Referring to fig. 2, fig. 2 is a schematic structural diagram of a wearable device provided in the present application, as shown in fig. 2, the wearable device includes: a first earplug and a second earplug, wherein the first earplug or the second earplug may comprise: a processing component 201, a first audio playing component 202, a second audio playing component 204 and a wireless transceiver 203; wherein, the processing component 201 is connected to the first audio playing component 202, the second audio playing component 204 and the wireless transceiver 203 respectively; the first audio playing section 202 operates in a first sound emission mode, and the second audio playing section 204 operates in a second sound emission mode. Specifically, the first audio playing component 202 may be a sound wave emitting component, such as a speaker, and the second audio playing component may be a bone conduction sound emitting component, and performs sound emitting operation in a bone conduction mode. Of course, in practical applications, the operation mode of the first audio playing part may be interchanged with the operation mode of the second audio playing part.
A wireless transceiver 203 for maintaining a wireless connection with the electronic device and receiving audio files through the wireless connection;
the wireless connection may specifically be a bluetooth connection, a wifi connection, a radio frequency connection, or other wireless connection manners, and certainly in practical applications, other wireless connection manners may also be adopted.
The audio file may be specifically an individual audio file, and certainly may also be a file of an audio portion in a video file, and the present application is not limited to what manner the audio file is obtained.
The processing unit 201 is configured to control the first audio playing unit 202 to play the audio file in a first sound generation mode, acquire a first time of playing in the first sound generation mode, and control the second audio playing unit 204 to play the audio file in a second sound generation mode if the first time exceeds a time threshold.
The technical scheme that this application provides is obtaining the audio file after, and processing part 201 can control first audio playback part 202 and adopt first vocal mode to play the audio file, when the very first time of broadcast surpassed the time threshold, switches first vocal mode to second vocal mode, plays this audio file through second vocal mode promptly, because the mode of vocalizing is also different after the mode conversion, so can reduce the influence of sound to ear health, improves user experience.
The technical effects of the present application are described below by an example, where the wearable device uses a wireless headset as an example, the sound generation mode corresponding to the wearable device may be a first mode, a sound wave sound generation mode, a second mode, and a bone conduction sound generation mode, so after receiving an audio file, the wearable device uses the first mode, that is, the sound wave sound generation mode, to play the audio file, and when the first time of playing exceeds a time threshold, the wearable device switches to the second mode, that is, the bone conduction sound generation mode, to play, so that when the bone conduction sound generation mode plays the audio file, the sound wave sound generation mode plays, that is, the wearable device stops working, so that no sound wave affects the health of the ear, that is, the bone conduction sound is generated through the bone conduction mode, and no impact is caused on the health of the ear.
Optionally, the processing unit 201 is configured to acquire a second time of playing in the second sound emission mode, and if the second time exceeds a time threshold, control the first audio playing unit 202 to play the audio file in the first sound emission mode.
According to the technical scheme, the second sound production mode is prevented from influencing the body of the user due to the fact that the second sound production mode works for too long time, the influence of long-term use of the same sound production mode on the body can be reduced by the two mode switching modes, and user experience is improved.
Optionally, the wearable device further comprises: the acceleration sensor is used for acquiring acceleration data; the processing unit 201 is configured to compose input data according to the acceleration data and the time for acquiring the acceleration data, input the input data into a preset neural network model, execute a multilayer forward operation to obtain a forward operation result, and determine whether to perform sound production mode switching according to the forward operation result.
Optionally, the implementation manner of composing the acceleration data and the time for acquiring the acceleration data into the input data may specifically be:
the processing unit 201 is specifically configured to obtain a type of sample input data in a training sample of a preset neural network model and an arrangement rule of the sample input data, and if the type is matrix data, form an input matrix by using the acceleration data and time for acquiring the acceleration data according to the arrangement rule, and if the type is a three-dimensional data block, form an input three-dimensional data block by using the acceleration data and time for acquiring the acceleration data according to the arrangement rule.
The above input data is determined by a practical example, where the type of the input data is matrix data, and the arrangement rule may be that the input data is arranged in the width direction (W) in the following order: acceleration data-acquisition time, if the acceleration data and the amount of time to acquire the acceleration data are not sufficient to form a matrix, the acceleration data and the amount of time to acquire the acceleration data are made to form a matrix by supplementing zero elements. A specific supplementary schematic diagram is shown in fig. 3a, and as shown in fig. 3a, the last black box is an element that is filled with zero, and each box in fig. 3a represents an element of a matrix. Of course, the above arrangement rule may also be: arranged in the width direction in the following order: the time-acceleration data are acquired, but other arrangement rules, such as height (H) arrangement, are also possible. Each box in fig. 3a represents an element of an input matrix.
The type of the input data here is exemplified by a three-dimensional data block, and the arrangement rule may be that the data are arranged in the width direction (W) in the following order: acceleration data-acquisition time, if the acceleration data and the amount of time for acquiring the acceleration data are not enough to form a three-dimensional data block, the acceleration data and the amount of time for acquiring the acceleration data are made to form a three-dimensional data block by supplementing zero elements. The specific supplementary schematic diagram is shown in fig. 3b, as shown in fig. 3b, the last black box is an element for supplementing zero, and each box in fig. 3b represents an element of a three-dimensional data block.
In the training method of the neural network model, each sample input data in a plurality of sample input data is input into the neural network model for training to update the weight data in the neural network model, all the plurality of sample input data are trained to update the weight data, the neural network model at the moment is a trained neural network model, and the weight data are not changed after the neural network model is trained. The plurality of sample input data at least needs to include: sample input data for switching the sound emission pattern and sample input data for not switching the sound emission pattern. Because the weight data in the preset neural network model is not changed, the input data which is input into the preset neural network model and is subjected to forward operation needs to be consistent with the type of the sample input data, and if the types are inconsistent, the result of the operation which is possibly executed by the neural network model has a lot of deviations. Specifically, matrix-matrix multiplication in mathematical computation and computation between three-dimensional data blocks are performed according to positions of elements, and if types of the elements are inconsistent, corresponding positions of the elements are changed, for example, the input matrix shown in fig. 3a and the input three-dimensional data shown in fig. 3b, even if the input matrix and the input three-dimensional data are respectively composed by using the same acceleration data and acquisition time, because the types are inconsistent, positions of most elements in the input matrix and the input three-dimensional data are inconsistent, and misalignment of the positions can lead to a large deviation of a computed result, so that a forward output result is inaccurate, and an inaccurate forward output result can lead to a deviation of a gesture determined according to the forward output result. The input data formed by the same type and the same arrangement rule can reduce the inconsistency of positions and types, and improve the accuracy of the forward output result.
Optionally, the processing unit is specifically configured to obtain a type of sample input data in a training sample of the preset neural network model and an arrangement rule of the sample input data, where the type is matrix data [ H [ ]0】【W0Determining total amount of acceleration data and acquisition time Y, e.g. Y < H0*W0(ii) a Computing
Figure GDA0002678473300000101
Executing a process of inserting n values to obtain data after the insertion process, wherein the process of inserting n values specifically includes: inserting n acceleration data into the acceleration data, inserting n acquisition times into the acquisition times, and forming an input matrix according to the arrangement rule by the data after insertion processing, wherein the size of the input matrix is [ H ]0】【W0H, the H0Is a height value of the matrix, the W0May be the width value of the matrix.
The insertion manner of the n pieces of acceleration data may be various, for example, in an alternative manner, n pieces of acceleration data are inserted after the acceleration data, the n pieces of acceleration data may be an average value of the collected acceleration values, and of course, the n pieces of acceleration data may be n values in a discrete distribution, the n values in the discrete distribution are within a set range, and the average value of the n values in the discrete distribution is the same as the average value of the collected acceleration values. The inserting n acquisition times may be specifically, inserting n acquisition times after the acquisition time with a set frequency, where the set frequency may be a frequency set by a user.
The insertion mode can simulate the originally collected acceleration data and the collection time as much as possible, so that the authenticity of the input matrix data can be improved, and the accuracy of a forward operation result is improved.
Optionally, determining whether to perform the switching of the sound emission mode according to the forward operation result may specifically include: and the processing component is specifically used for extracting X elements with element values larger than a set threshold value and X positions corresponding to the X elements from the forward operation result, if the X positions exceed X/2 positions corresponding to the switching of the sound production mode, determining that the forward operation result is the switching of the sound production mode, otherwise, if the X positions exceed X/2 positions corresponding to the non-switching of the sound production mode, determining that the forward operation structure is the non-switching of the sound production mode.
It should be noted that, for the training sample input data, because it is labeled sample data, that is, it is known that the training sample input data belongs to the switching of the sounding mode or the non-switching of the sounding mode, the training sample (the sounding mode is not switched) is input into the preset neural network model to obtain the forward operation result, and the position corresponding to the element in the forward operation result, which is greater than the set threshold value, is the sounding mode non-switching. Similarly, the training sample (sound generation mode switching) is input into a preset neural network model to obtain a forward operation result, and the position corresponding to the element in the forward operation result, which is greater than the set threshold value, is the sound generation mode switching.
Referring to fig. 4, fig. 4 provides a mode switching method of a wearable device, where the method is applied to the wearable device, and includes: the system comprises a processing component, a first audio playing component, a second audio playing component and a wireless transceiver; the first audio playing component works through a first sound production mode, and the second audio playing component works through a second sound production mode; the method comprises the following steps:
s401, keeping wireless connection with electronic equipment, and receiving an audio file through the wireless connection;
step S402, controlling the first audio playing component to play the audio file by adopting a first sound producing mode, and acquiring first time of playing the first sound producing mode;
step S403, if the first time exceeds the time threshold, controlling the second audio playing component to play the audio file in the second sound generation mode.
Optionally, the method further includes:
and acquiring second time for playing the second sound production mode, and controlling the first audio playing component to play the audio file in the first sound production mode if the second time exceeds a time threshold.
Optionally, the wearable device further includes: an acceleration sensor connected to the processing component; the method further comprises the following steps:
acquiring acceleration data;
and forming input data according to the acquired acceleration data and the acquisition time of the acquired acceleration data, inputting the input data into a preset neural network model, executing multilayer forward operation to obtain a forward operation result, and determining whether to switch the sound production mode according to the forward operation result.
Optionally, the forming input data according to the collected acceleration data and the collection time of the collected acceleration data specifically includes:
and acquiring the type of sample input data and the arrangement rule of the sample input data in a training sample of the preset neural network model, if the type is matrix data, forming an input matrix by the acceleration data and the acquisition time according to the arrangement rule, and if the type is a three-dimensional data block, forming an input three-dimensional data block by the acceleration data and the acquisition time according to the arrangement rule.
Optionally, the forming input data according to the collected acceleration data and the collection time of the collected acceleration data specifically includes:
obtaining the type of sample input data in a training sample of a preset neural network model and the arrangement rule of the sample input data, if the type is matrix data [ H ]0】【W0Determining total amount of acceleration data and acquisition time Y, e.g. Y < H0*W0(ii) a Computing
Figure GDA0002678473300000121
Executing a process of inserting n values to obtain data after the insertion process, wherein the process of inserting n values specifically includes: inserting n acceleration data into the acceleration data, inserting n acquisition times into the acquisition times, and forming an input matrix according to the arrangement rule by the data after insertion processing, wherein the size of the input matrix is [ H ]0】【W0H, the H0Is a height value of the matrix, the W0May be the width value of the matrix.
Optionally, the determining whether to perform the switching of the sound emission mode according to the forward operation result specifically includes:
extracting X elements with element values larger than a set threshold value and X positions corresponding to the X elements from the forward operation result, and determining that the forward operation result is the switching of the sound production mode if the X positions exceed X/2 positions corresponding to the switching of the sound production mode; if the occurrence mode corresponding to more than X/2 positions in the X positions is not switched, determining that the forward operation structure is not switched in the sound production mode; and X is an integer greater than or equal to 2.
Fig. 5 is a block diagram illustrating a partial structure of a wearable device connected to a mobile terminal provided in an embodiment of the present application. Referring to fig. 5, the wearable device includes: radio Frequency (RF) circuit 910, memory 920, input unit 930, sensor 950, first audio playing component 960 (e.g., an audio collector), Wireless Fidelity (WiFi) module 970, application processor AP980, power supply 990, second audio playing component 999, and so on. Those skilled in the art will appreciate that the wearable device configuration shown in fig. 5 does not constitute a limitation of the wearable device and may include more or fewer components than shown, or some components may be combined, or a different arrangement of components, e.g., the rf circuit 910 may be connected to a single or multiple antennas.
The following specifically describes each constituent component of the wearable device with reference to fig. 5:
the input unit 930 may be used to receive input numeric or character information and generate key signal inputs related to user settings and function control of the cellular phone. Specifically, the input unit 930 may include a touch display 933 and other input devices 932. In particular, other input devices 932 may include, but are not limited to, one or more of physical keys, function keys (e.g., volume control keys, switch keys, etc.), a trackball, a joystick, and the like.
The radio frequency circuit 910 is configured to maintain a wireless connection with an electronic device, and receive an audio file through the wireless connection;
and the application processor AP980 is configured to control the first audio playing component to play the audio file in the first sound generation mode, acquire a first time of playing the first sound generation mode, and control the second audio playing component to play the audio file in the second sound generation mode if the first time exceeds a time threshold.
The application processor AP980 is specifically configured to acquire a second time for playing the second sound generation mode, and if the second time exceeds a time threshold, control the first audio playing component to play the audio file in the first sound generation mode.
The application processor AP980 is specifically configured to form input data according to the acquired acceleration data and the acquisition time of the acquired acceleration data, input the input data into a preset neural network model, execute a multilayer forward operation to obtain a forward operation result, and determine whether to perform sound production mode switching according to the forward operation result.
And the application processor AP980 is specifically configured to obtain a type of sample input data and an arrangement rule of the sample input data in a training sample of the preset neural network model, and if the type is matrix data, form an input matrix by using the acceleration data and the acquisition time according to the arrangement rule, and if the type is a three-dimensional data block, form an input three-dimensional data block by using the acceleration data and the acquisition time according to the arrangement rule.
The application processor AP980 is specifically configured to extract, from the forward operation result, X elements whose element values are greater than a set threshold and X positions corresponding to the X elements, and if there are more than X/2 positions in the X positions corresponding to the switching of the sound emission mode, determine that the forward operation result is the switching of the sound emission mode; if the occurrence mode corresponding to more than X/2 positions in the X positions is not switched, determining that the forward operation structure is not switched in the sound production mode; and X is an integer greater than or equal to 2.
The AP980 is a control center of the wearable device, connects various parts of the entire wearable device with various interfaces and lines, executes various functions of the wearable device and processes data by running or executing software programs and/or modules stored in the memory 920 and calling data stored in the memory 920, thereby monitoring the wearable device as a whole. Optionally, AP980 may include one or more processing units; alternatively, the AP980 may integrate an application processor that handles primarily the operating system, user interface, and applications, etc., and a modem processor that handles primarily wireless communications. It will be appreciated that the modem processor described above may not be integrated into the AP 980.
Further, the memory 920 may include high speed random access memory, and may also include non-volatile memory, such as at least one flash memory device, or other volatile solid state storage device.
RF circuitry 910 may be used for the reception and transmission of information. In general, the RF circuit 910 includes, but is not limited to, an antenna, at least one Amplifier, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In addition, the RF circuit 910 may also communicate with networks and other devices via wireless communication. The wireless communication may use any communication standard or protocol including, but not limited to, bluetooth, wifi, gsm, gprs, cdma, wcdma, lte, air interface, etc.
The wearable device may also include at least one sensor 950, such as an ultrasonic sensor, an angle sensor, a light sensor, a motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, where the ambient light sensor may detect whether the wearable device is in an ear insertion state according to the brightness of ambient light, the luminance of the touch display screen is adjusted according to the ear insertion state, and the proximity sensor may turn off the touch display screen and/or backlight when the wearable device moves to the ear. As one type of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in each direction (generally three axes), detect the magnitude and direction of gravity when stationary, and can be used for applications (such as horizontal and vertical screen switching, related games, magnetometer attitude calibration), vibration recognition related functions (such as pedometer, tapping), and the like for recognizing the attitude of the wearable device; as for other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which can be configured on the wearable device, detailed descriptions thereof are omitted.
Audio collector 960, speaker 961, microphone 962 may provide an audio interface between the user and the wearable device. The audio collector 960 can transmit the received electrical signal converted from the audio data to the speaker 961, and the audio data is converted into a sound signal by the speaker 961 for playing; on the other hand, the microphone 962 converts the collected sound signal into an electrical signal, and the electrical signal is received by the audio collector 960 and converted into audio data, and the audio data is processed by the audio data playing AP980, and then sent to, for example, a mobile phone through the RF circuit 910, or played to the memory 920 for further processing.
WiFi belongs to short distance wireless transmission technology, and the wearable device can help the user to send and receive data and the like through the WiFi module 970, which provides wireless broadband internet access for the user. Although fig. 5 shows the WiFi module 970, it is understood that it does not belong to the essential constitution of the wearable device, and may be omitted entirely as needed within the scope of not changing the essence of the application.
The wearable device can further comprise a bluetooth module, the bluetooth module is used for realizing connection with the electronic device, the bluetooth module can be separately arranged, and in practical application, the bluetooth module can be integrated in an application processor due to different selected application processors.
The wearable device also includes a power supply 990 (e.g., a battery) for supplying power to various components, and optionally, the power supply may be logically connected to the AP980 via a power management system, so that functions of managing charging, discharging, and power consumption are implemented via the power management system.
Although not shown, the wearable device may further include a camera, a light supplement device, a light sensor, and the like, which are not described herein again.
It can be seen that after the audio file is obtained by the technical scheme provided by the application processor, the application processor can control the first audio playing component to play the audio file in the first sound production mode, when the first time of playing exceeds a time threshold, the first sound production mode is switched to the second sound production mode, namely, the audio file is played in the second sound production mode, and because the sound production modes after mode conversion are different, the influence of sound on ear health can be reduced, and the user experience degree is improved.
Embodiments of the present application also provide a computer storage medium, where the computer storage medium stores a computer program for electronic data exchange, and the computer program enables a computer to execute some or all of the steps of any one of the wearable device mode switching methods described in the above method embodiments.
Embodiments of the present application also provide a computer program product comprising a non-transitory computer readable storage medium storing a computer program, the computer program being operable to cause a computer to perform some or all of the steps of any one of the wearable device mode switching methods as recited in the above method embodiments.
In the foregoing embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus may be implemented in other manners. For example, the above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one type of division of logical functions, and there may be other divisions when actually implementing, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not implemented. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of some interfaces, devices or units, and may be an electric or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit may be implemented in the form of hardware, or may be implemented in the form of a software program module.
The foregoing is an implementation of the embodiments of the present application, and it should be noted that, for those skilled in the art, several modifications and decorations can be made without departing from the principle of the embodiments of the present application, and these modifications and decorations are also regarded as the protection scope of the present application.

Claims (7)

1. A wearable device, characterized in that the wearable device comprises: the device comprises a processing component, a first audio playing component, a second audio playing component, an acceleration sensor and a wireless transceiver; wherein the acceleration sensor is connected with the processing component; the processing component is respectively connected with the first audio playing component, the second audio playing component and the wireless transceiver, the first audio playing component works in a first sound production mode, and the second audio playing component works in a second sound production mode;
the wireless transceiver is used for keeping wireless connection with the electronic equipment and receiving the audio file through the wireless connection;
the processing component is configured to control the first audio playing component to play the audio file in a first sound generation mode, acquire a first time of playing the first sound generation mode, and control the second audio playing component to play the audio file in the second sound generation mode if the first time exceeds a time threshold; acquiring second time for playing the second sound production mode, and controlling the first audio playing component to play the audio file in the first sound production mode if the second time exceeds a time threshold;
the acceleration sensor is used for acquiring acceleration data;
the processing unit is further configured to form input data according to the acquired acceleration data and the acquisition time of the acquired acceleration data, input the input data into a preset neural network model, execute multilayer forward operation to obtain a forward operation result, and determine whether to perform sounding mode switching according to the forward operation result.
2. The wearable device according to claim 1,
the processing component is specifically configured to obtain a type of sample input data and an arrangement rule of the sample input data in a training sample of the preset neural network model, and if the type is matrix data, form an input matrix by the acceleration data and the acquisition time according to the arrangement rule, and if the type is a three-dimensional data block, form an input three-dimensional data block by the acceleration data and the acquisition time according to the arrangement rule.
3. The wearable device according to claim 1,
the processing component is specifically configured to extract, from the forward operation result, X elements whose element values are greater than a set threshold and X positions corresponding to the X elements, and determine that the forward operation result is a switching of the sounding mode if more than X/2 of the X positions correspond to a switching of the sounding mode; if the occurrence mode corresponding to more than X/2 positions in the X positions is not switched, determining that the forward operation structure is not switched in the sound production mode; and X is an integer greater than or equal to 2.
4. A mode switching method of a wearable device, the method being applied to the wearable device, and comprising: the device comprises a processing component, a first audio playing component, a second audio playing component, an acceleration sensor and a wireless transceiver, wherein the acceleration sensor is connected with the processing component; the first audio playing component works through a first sound production mode, and the second audio playing component works through a second sound production mode; the method comprises the following steps:
the method comprises the steps of keeping wireless connection with the electronic equipment, and receiving an audio file through the wireless connection;
controlling the first audio playing component to play the audio file by adopting a first sound production mode, acquiring first time of playing the first sound production mode, and controlling the second audio playing component to play the audio file by adopting a second sound production mode if the first time exceeds a time threshold; acquiring second time for playing the second sound production mode, and controlling the first audio playing component to play the audio file in the first sound production mode if the second time exceeds a time threshold;
acquiring acceleration data;
and forming input data according to the acquired acceleration data and the acquisition time of the acquired acceleration data, inputting the input data into a preset neural network model, executing multilayer forward operation to obtain a forward operation result, and determining whether to switch the sound production mode according to the forward operation result.
5. The method according to claim 4, wherein the composing input data from the collected acceleration data and the collection time of the collected acceleration data comprises:
and acquiring the type of sample input data and the arrangement rule of the sample input data in a training sample of the preset neural network model, if the type is matrix data, forming an input matrix by the acceleration data and the acquisition time according to the arrangement rule, and if the type is a three-dimensional data block, forming an input three-dimensional data block by the acceleration data and the acquisition time according to the arrangement rule.
6. The method according to claim 4, wherein the determining whether to perform the switching of the sound emission mode according to the forward operation result specifically comprises:
extracting X elements with element values larger than a set threshold value and X positions corresponding to the X elements from the forward operation result, and determining that the forward operation result is the switching of the sound production mode if the X positions exceed X/2 positions corresponding to the switching of the sound production mode; if the occurrence mode corresponding to more than X/2 positions in the X positions is not switched, determining that the forward operation structure is not switched in the sound production mode; and X is an integer greater than or equal to 2.
7. A computer-readable storage medium, characterized in that it stores a computer program for electronic data exchange, wherein the computer program causes a computer to perform the method according to any one of claims 4-6.
CN201810606177.4A 2018-06-13 2018-06-13 Mode conversion method for wearable equipment and related product Expired - Fee Related CN108848262B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810606177.4A CN108848262B (en) 2018-06-13 2018-06-13 Mode conversion method for wearable equipment and related product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810606177.4A CN108848262B (en) 2018-06-13 2018-06-13 Mode conversion method for wearable equipment and related product

Publications (2)

Publication Number Publication Date
CN108848262A CN108848262A (en) 2018-11-20
CN108848262B true CN108848262B (en) 2021-03-05

Family

ID=64211045

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810606177.4A Expired - Fee Related CN108848262B (en) 2018-06-13 2018-06-13 Mode conversion method for wearable equipment and related product

Country Status (1)

Country Link
CN (1) CN108848262B (en)

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN2854988Y (en) * 2005-08-19 2007-01-03 易路达科技有限公司 Bluetooth earphone
CN103458339A (en) * 2012-06-01 2013-12-18 联想(北京)有限公司 Audio output control method and electronic equipment
CN106685459B (en) * 2016-12-27 2019-07-30 广东小天才科技有限公司 Wearable device operation control method and wearable device

Also Published As

Publication number Publication date
CN108848262A (en) 2018-11-20

Similar Documents

Publication Publication Date Title
CN109150221B (en) Master-slave switching method for wearable equipment and related product
CN108886653B (en) Earphone sound channel control method, related equipment and system
CN109561420B (en) Emergency help-seeking method and related equipment
CN109041142A (en) Main earphone switching method and relevant device
CN108897516B (en) Wearable device volume adjustment method and related product
CN107911445A (en) A kind of information push method, mobile terminal and storage medium
CN106413070B (en) A kind of power regulating method, mobile terminal and computer readable storage medium
CN108600887B (en) Touch control method based on wireless earphone and related product
CN108834013B (en) Wearable equipment electric quantity balancing method and related product
CN109274812B (en) Method for controlling electronic device through ultrasonic gestures and related product
CN108882084B (en) Wearable equipment electric quantity balancing method and related product
CN107864299B (en) Picture display method and related product
CN109121034B (en) Master-slave switching method based on volume and related product
CN108989546B (en) Approach detection method of electronic device and related product
CN109582820B (en) Song playing method, terminal equipment and server
CN108736950A (en) Method, mobile terminal and the computer readable storage medium of antenna switching
CN110277097B (en) Data processing method and related equipment
CN108900942B (en) Play control method and electronic equipment
CN108536272B (en) Method for adjusting frame rate of application program and mobile terminal
CN109040425B (en) Information processing method and related product
CN108255632B (en) Fall data calculation method based on artificial intelligence and related product
CN110764650A (en) Key trigger detection method and electronic equipment
CN110209543A (en) A kind of detection method and terminal of earphone socket
CN108848262B (en) Mode conversion method for wearable equipment and related product
CN108923809B (en) Auditory canal sundry prompting method and related product

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
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20210305

CF01 Termination of patent right due to non-payment of annual fee