CN108900702A - The treating method and apparatus of vibration prompt - Google Patents

The treating method and apparatus of vibration prompt Download PDF

Info

Publication number
CN108900702A
CN108900702A CN201810601652.9A CN201810601652A CN108900702A CN 108900702 A CN108900702 A CN 108900702A CN 201810601652 A CN201810601652 A CN 201810601652A CN 108900702 A CN108900702 A CN 108900702A
Authority
CN
China
Prior art keywords
vibration
calling
type
camera
call request
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.)
Pending
Application number
CN201810601652.9A
Other languages
Chinese (zh)
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 CN201810601652.9A priority Critical patent/CN108900702A/en
Publication of CN108900702A publication Critical patent/CN108900702A/en
Pending legal-status Critical Current

Links

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/72454User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to context-related or environment-related conditions
    • 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
    • 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/72463User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions to restrict the functionality of the device

Landscapes

  • Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Environmental & Geological Engineering (AREA)
  • Telephone Function (AREA)
  • Mobile Radio Communication Systems (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The present invention proposes a kind for the treatment of method and apparatus of vibration prompt, wherein method includes:Interface for calling vibration to service is listened to, when listening to call request, vibration parameters are obtained from call request, according to vibration parameters, identify vibration time type, according to vibration time type, determine whether prevent call request to the calling of vibration service during foreground application calls camera.According to the type of Vibrating parameter identification vibration time, so that it is determined that whether preventing call request to the calling of vibration service during calling camera, it solves in the related technology, when in the scene that electronic equipment is in vibrating alert, when carrying out Image Acquisition since Oscillation Amplitude is stronger, the technical issues of causing shooting picture shake to cause fuzzy pictures, or even can not focusing.

Description

The treating method and apparatus of vibration prompt
Technical field
The present invention relates to electronic technology field more particularly to a kind for the treatment of method and apparatus of vibration prompt.
Background technique
By setting vibrating motor in electronic product, vibrating alert is realized.
In the related technology, when electronic equipment is under vibrating alert mode, when vibrating motor vibration is reminded, by Amplitude is larger when motor vibrations, can be because the vibration of motor leads to float, out when electronic product is under photographed scene The problems such as showing fuzzy pictures, or even can not focusing.
Summary of the invention
The present invention is directed to solve at least some of the technical problems in related technologies.
For this purpose, the present invention proposes a kind of processing method of vibration prompt, by according to Vibrating parameter identification vibration time Type, whether so that it is determined that preventing call request to the calling of vibration service during calling camera, reaching does not influence to clap The effect for taking the photograph image quality solves in the related technology, when in the scene that electronic equipment is in vibrating alert, is carrying out Image Acquisition When due to Oscillation Amplitude it is stronger, cause shooting picture shake to cause fuzzy pictures, or even the technical issues of can not focus.
The present invention proposes a kind of processing unit of vibration prompt.
The present invention proposes a kind of electronic equipment.
The present invention proposes a kind of computer readable storage medium.
One aspect of the present invention embodiment proposes a kind of processing method of vibration prompt, and this method is applied to electronic equipment, Electronic equipment has vibrating motor, and vibrating motor issues vibration prompt under the control of vibration service, wherein method includes:
Interface for calling vibration to service is listened to;Wherein, the vibration service is for controlling the vibration horse Up to sending vibration prompt;
When listening to call request, vibration parameters are obtained from the call request;
According to the vibration parameters, vibration time type is identified;
According to the vibration time type, determine whether prevent the calling during foreground application calls camera Request the calling to the vibration service.
Another aspect of the invention embodiment proposes a kind of processing unit of vibration prompt, which may be disposed at electronics and set Standby, the electronic equipment has vibrating motor, and the vibrating motor issues vibration prompt under the control of the vibration service, fills Set including:
Module is listened to, for listening to the interface for calling vibration to service;Wherein, the vibration service is for controlling It makes the vibrating motor and issues vibration prompt;
Module is obtained, for obtaining vibration parameters from the call request when listening to call request;
Identification module, for identifying vibration time type according to the vibration parameters;
Determining module, for according to the vibration time type, determining during foreground application calls camera to be It is no to prevent the call request to the calling of the vibration service.
Another aspect of the invention embodiment proposes a kind of electronic equipment, including:Vibrating motor, camera, memory, place The computer program managing device and storage on a memory and can running on a processor, the vibrating motor and the camera point It is not electrically connected with the processor, when the processor executes described program, realizes that vibration described in aforementioned one side face mentions The processing method shown.
Another aspect of the invention embodiment proposes a kind of computer readable storage medium, is stored thereon with computer Jie Matter when the program is executed by processor, realizes the processing method of vibration prompt described in aforementioned one side face.
Technical solution provided by the embodiment of the present invention may include following beneficial effect:
Interface for calling vibration to service is listened to, when listening to call request, is obtained from call request Vibration parameters identify vibration time type according to vibration parameters, according to vibration time type, determine and take the photograph in foreground application calling As whether preventing call request to the calling of vibration service during head.Pass through the class according to Vibrating parameter identification vibration time Type, whether so that it is determined that preventing call request to the calling of vibration service during calling camera, reaching does not influence to shoot The effect of image quality.
Detailed description of the invention
Above-mentioned and/or additional aspect and advantage of the invention will become from the following description of the accompanying drawings of embodiments Obviously and it is readily appreciated that, wherein:
Fig. 1 is a kind of flow diagram of the processing method of vibration prompt provided by the embodiment of the present invention;
Fig. 2 is the flow diagram of the processing method of another kind vibration prompt provided by the embodiment of the present invention;
Fig. 3 is a kind of structural schematic diagram of the processing unit of vibration prompt provided in an embodiment of the present invention;
Fig. 4 is one of the structural schematic diagram of electronic equipment 100 provided by the embodiment of the present invention;
Fig. 5 is the second structural representation of electronic equipment 100 provided by the embodiment of the present invention;And
Fig. 6 is the third structural representation of electronic equipment 100 provided by the embodiment of the present invention.
Specific embodiment
The embodiment of the present invention is described below in detail, examples of the embodiments are shown in the accompanying drawings, wherein from beginning to end Same or similar label indicates same or similar element or element with the same or similar functions.Below with reference to attached The embodiment of figure description is exemplary, it is intended to is used to explain the present invention, and is not considered as limiting the invention.
Below with reference to the accompanying drawings the treating method and apparatus of the vibration prompt of the embodiment of the present invention is described.
Fig. 1 is a kind of flow diagram of the processing method of vibration prompt provided by the embodiment of the present invention, and this method is answered For electronic equipment, there is vibrating motor in electronic equipment, vibration prompt is realized by driving vibrating motor.
As shown in Figure 1, this approach includes the following steps:
Step 101, the interface for calling vibration to service is listened to.
Specifically, listening to for request is called to the interface for calling vibration to service, wherein vibration service is for controlling Vibrating motor processed issues vibration prompt.
Step 102, when listening to call request, vibration parameters are obtained from call request.
Wherein, vibration parameters, are carried in call request, the data comprising being used to indicate vibration time, for identification Vibration time type.
Step 103, according to vibration parameters, vibration time type is identified.
Wherein, vibration time type include in short-term long type and it is long when long type.
Specifically, when there is the single parameter value for being used to indicate single vibration time in vibration parameters, when identification is vibrated Long type is long type in short-term, wherein when single parameter value refers to only vibration one time, the value of vibration time, for example, single join Numerical value is 10, then represents single vibration time as 10 milliseconds;Exist in vibration parameters and is used to indicate the one of multiple vibration time When group parameter value, according to the parameter value for being used to indicate implementation strategy in vibration parameters, identification vibration time type is long duration class Type or in short-term long type, wherein one group of parameter value is used to indicate the corresponding multiple elements pair of the repeatedly vibration for including, each member Element indicates respectively the vibration time of delay time and this time once vibrated to comprising two elements, for example, one group of parameter value is { 0,30,20,30 }, wherein 0 and 30 represent an element pair in one group of parameter value, and 0 representative does not postpone to vibrate immediately, 30 generations Table vibration time is that 30ms, 20 and 30 represents second element pair in one group of parameter value, and 20 represent delay 20ms, and 30 represent vibration A length of 30ms when dynamic, that is, after the completion of vibrating for the first time, continue to vibrate 30ms after postponing 20ms.
Step 104, according to vibration time type, determine whether prevent to call during foreground application calls camera Request the calling to vibration service.
Specifically, if vibration time type is that long type prevents to adjust during foreground application calls camera in short-term With request to the calling of vibration service;If long type when vibration time type is long, the process of camera is called in foreground application In, allow call request to the calling of vibration service.By judging vibration time type for long type in short-term, to vibration service Call request is prevented, realize vibration time type be in short-term long type when, do not influence foreground call camera clapped According to when image quality.
In the processing method of the vibration prompt of the embodiment of the present invention, the interface for calling vibration to service is listened to, When listening to call request, vibration parameters are obtained from call request, according to vibration parameters, identify vibration time type, root According to vibration time type, determine whether prevent call request to the tune of vibration service during foreground application calls camera With.By the type according to Vibrating parameter identification vibration time, so that it is determined that whether preventing to call during calling camera The calling to vibration service is requested, the influence that vibration long in short-term acquires camera image is avoided, realizes in specific field The purpose of shooting image quality is not influenced under scape.
Through the analysis to above-described embodiment it is found that in the case where electronic equipment is in vibrating alert scene, vibration is being determined After the type of duration, according to vibration time type, determines whether to prevent to call during foreground application calls camera and ask The calling to vibration service is sought, that is, defaults the application that foreground application is calling camera, and in practical application, in front stage operation Application program is all not the application for calling camera, and therefore, the invention proposes the processing methods of another vibration prompt Possible implementation, the method for the present embodiment can be applied to electronic equipment, take the mobile phone as an example, be illustrated in the present embodiment.
Fig. 2 is the flow diagram of the processing method of another kind vibration prompt provided by the embodiment of the present invention, such as Fig. 2 institute Show, this method comprises the following steps:
Step 201, the interface for calling vibration to service is listened to.
Specifically, there is vibrating motor, vibration service issues vibration prompt for controlling vibrating motor, by right in mobile phone The interface of vibration service is listened to, and call request is obtained.
Step 202, when listening to call request, the event letter of vibration parameters and triggering vibration is obtained from call request Breath.
Wherein, vibration parameters, are carried in call request, the data comprising being used to indicate vibration time, for identification Vibration time type.
It is carried in the event information of triggering vibration and call request, being used to indicate triggering need to call vibration to service Event information includes mechanical key trigger event, virtual case trigger event and non-virtual case trigger event.
Step 203, determine that the event information of triggering vibration meets presupposed information.
Specifically, it is determined that the event information of triggering vibration meets presupposed information, wherein presupposed information is the touching of non-virtual key Hair event, for example, quarter-bell, incoming call and background message etc., wherein background message refers to the application in the running background of electronic equipment The message of program push, for example, wechat message, QQ message, short message etc..
It should be noted that running background, refers to that application program is still run in the electronic device, but its display interface is not It shows in the window.
Step 204, when there is the single parameter value for being used to indicate single vibration time in vibration parameters, when identification is vibrated Long type is long type in short-term.
It should be noted that the single parameter value of single vibration time, the duration of corresponding single vibration, the single parameter value Numerical value is smaller, for example, being 30 milliseconds, data value corresponding for single vibration time is not construed as limiting in the present embodiment.
Step 205, when there is one group of parameter value for being used to indicate multiple vibration time in vibration parameters, joined according to vibration It is used to indicate the parameter value of implementation strategy in number, long type or long type in short-term when identification vibration time type is long.
Specifically, when there is one group of parameter value for being used to indicate multiple vibration time in vibration parameters, from vibration parameters Middle read is used to indicate the parameter value of implementation strategy, and determines implementation strategy, if implementation strategy is that circulation executes, from being used for It indicates that first in one group of parameter value of multiple vibration time starts to execute, and the multiple parameter values in one group of parameter value is followed Ring executes, for example, one group of parameter value is { 0,20,5,20,5,20 }, when implementation strategy is that circulation executes, i.e., opens from first Begin to execute, i.e., do not postpone 20 milliseconds of vibration, vibrate 20 milliseconds again after 5 milliseconds of delay, then vibrate 20 milliseconds after postponing 5 milliseconds, follows Ring execute delay 5 milliseconds after vibrate 20 milliseconds, until user trigger stop, because circulation execute after so that total vibration time compared with It is long, so that it is determined that long type when the vibration time type is long.
If implementation strategy is to determine vibration time type for long class in short-term when executing since n-th of one group of parameter value Type;Wherein, n is positive integer, for example, one group of parameter value is { 0,20,5,20,5,20 }, since the third position of one group of parameter value It executes, after 5 milliseconds of delay, vibrates 20 milliseconds, after continuing 5 milliseconds of delay, vibrate 20 milliseconds, because total time of vibration is still less, So that it is determined that vibration time type is long type in short-term.
If implementation strategy is that single executes, vibration time type is determined for long type in short-term, for example, one group of parameter value is { 0,20,5,20,5,20 }, single execute, i.e., do not postpone multiple elements corresponding in one group of parameter value immediately to executing one time It executes 20 milliseconds, postpones 5 seconds, then execute 20 milliseconds, postpone 5 milliseconds, and execute 20 milliseconds, that is, a length of 60 milli when executing total Second, the time is shorter, and considerably shorter than 1 second, so that it is determined that vibration time type is long type in short-term.
Step 206, determine that camera is called in the application of front stage operation.
After identifying vibration time type, it is also necessary to further determine that whether the application program of front stage operation has invoked and take the photograph As head, specifically, the mark of the application program of front stage operation is obtained by operating system, as a kind of possible implementation, Acquisition foreground is established in the service (Activity Manager Service, AMS) of interaction between management foreground and system to transport The interface of the mark of capable application program obtains the mark of the application program of front stage operation from interface.Pass through webcam driver The function being previously inserted in program obtains the mark for calling the application program of camera, if the mark of the application program of front stage operation Know and mismatched with the mark for the application program for calling camera, it is determined that foreground application does not call camera, the type application It is more, such as railway booking application program, video playing application program;If the mark of the application program of front stage operation is taken the photograph with calling As the mark matching of the application program of head, determine that foreground application calls camera, for example, " camera " application program of mobile phone.Only Have after determining that foreground application calls camera, just after the call request for listening to vibration service, according to call request, sentences It is disconnected whether to prevent call request to the calling of vibration service, treatment effeciency is improved, the purpose for shooting image quality is not influenced.
Step 207, according to vibration time type, determine whether prevent to call during foreground application calls camera Request the calling to vibration service.
Specifically, in mobile phone application, vibration time type is the event information of long type in short-term, for example, wechat message, QQ message, short message etc., this kind of message can be than more frequently pushing, and the vibration prompt time is shorter, when determining foreground application tune When with camera, can prevent the call request of long type in short-term to vibration service calling, to avoid shooting when because frequently it is short Shi Zhendong causes shooting picture to be shaken and makes shooting picture fuzzy.
The event information of long type when vibration time type is long, comprising cell phone incoming call, quarter-bell etc., the vibration of long type when long The frequency that dynamic event occurs is lower, but vibration time is longer, to ensure that user receives vibrating alert, avoids user from missing important Information, though foreground application be call camera in application, when can not prevent long the event of long type call request To the calling of vibration service.
For example, image taking is carried out by camera application program in mobile phone terminal under the scene of mobile phone terminal unlatching vibrating alert, I.e. camera applications are in front stage operation, when mobile phone terminal has incoming message, the vibration of long type when incoming call is defaulted as long, although at this time Call the camera applications of camera in front stage operation, but because of long type when the vibration time type of incoming call belongs to long, therefore, The call request of vibration is not prevented, allow calling vibration remind, similarly, other event informations it is long when long type vibration When dynamic prompting, processing mode is identical, no longer repeats one by one herein;If mobile phone terminal has the long type in short-term such as QQ or wechat message Message when, because the message of long type in short-term is more frequent, and vibration time is shorter, then can hinder the call request of vibration Only, achieve the effect that not influence to shoot image quality, at the same can the directly mute prompt of suspension windows, prompt user to have QQ or wechat etc. Instant message.
The processing method of the vibration prompt of the embodiment of the present invention listens to the interface for calling vibration to service, when When listening to call request, vibration parameters are obtained from call request, according to vibration parameters, identify vibration time type, and right Foreground application is identified, determines that foreground application calls camera, in turn, according to vibration time type, is determined in foreground application Call request whether is prevented to realize to the calling of vibration service and obtain vibration time by identification during calling camera Type, and determine that foreground application calls camera, to prevent the calling of vibration service during calling camera, prevent Because vibration causes shooting to be shaken, the problem of picture module.
In order to realize above-described embodiment, the present invention also proposes a kind of processing unit of vibration prompt.
Fig. 3 is a kind of structural schematic diagram of the processing unit of vibration prompt provided in an embodiment of the present invention, device setting In electronic equipment, electronic equipment has vibrating motor, and vibrating motor issues vibration prompt under the control of vibration service.
As shown in figure 3, the device includes:It listens to module 31, obtain module 32, identification module 33 and determining module 34.
Module 31 is listened to, for listening to the interface for calling vibration to service, wherein vibration service is for controlling Vibrating motor issues vibration prompt.
Module 32 is obtained, for obtaining vibration parameters from call request when listening to call request.
Identification module 33, for identifying vibration time type according to vibration parameters.
Determining module 34, for according to vibration time type, determine during foreground application calls camera whether Prevent call request to the calling of vibration service.
Further, in a kind of possible implementation of the embodiment of the present invention, which further includes:It obtains and determines mould Block is specifically used for:
The mark of the application program of front stage operation is obtained by operating system;
By the function being previously inserted in webcam driver program, the mark for calling the application program of camera is obtained;
If the mark of the application program of front stage operation is matched with the mark for the application program for calling camera, determine that foreground is answered With calling camera.
As a kind of possible implementation, above-mentioned determining module 31 is specifically used for:
If vibration time type is that long type prevents call request during foreground application calls camera in short-term To the calling of vibration service;
If long type when vibration time type is long, during foreground application calls camera, allow call request To the calling of vibration service.
As a kind of possible implementation, above-mentioned identification module 33 specifically can be used for:
When there is the single parameter value for being used to indicate single vibration time in vibration parameters, identification vibration time type is Long type in short-term;
When there is one group of parameter value for being used to indicate multiple vibration time in vibration parameters, it is used for according in vibration parameters Indicate the parameter value of implementation strategy, long type or long type in short-term when identification vibration time type is long.
As a kind of possible implementation, above-mentioned identification module 33 specifically be can be also used for:
The parameter value for being used to indicate implementation strategy is read from vibration parameters, and determines implementation strategy;
If implementation strategy is that circulation executes, long type when vibration time type is long is determined;
If implementation strategy is to determine vibration time type for long class in short-term when executing since n-th of one group of parameter value Type;Wherein, n is positive integer;
If implementation strategy is that single executes, determine vibration time type for long type in short-term.
As a kind of possible implementation, call request carry triggering vibration event information, above-mentioned determining module, It can be also used for:
Determine that the event information of triggering vibration meets presupposed information.
As a kind of possible implementation, presupposed information is non-virtual key trigger event.
It should be noted that the aforementioned device for being also applied for the embodiment to the explanation of embodiment of the method, is realized former Type is managed, details are not described herein again.
In the processing unit of above-mentioned vibration prompt, the division of modules by way of example only, in other embodiments, can The processing unit of vibration prompt is divided into other disparate modules as required, to complete the complete of above-mentioned vibration prompt processing unit Portion or partial function.
In the processing unit of the vibration prompt of the embodiment of the present invention, the interface for calling vibration to service is listened to, When listening to call request, vibration parameters are obtained from call request, according to vibration parameters, identify vibration time type, root According to vibration time type, determine whether prevent call request to the tune of vibration service during foreground application calls camera With.By the type according to Vibrating parameter identification vibration time, so that it is determined that whether preventing to call during calling camera The calling to vibration service is requested, the influence that acquires to camera image of vibration is avoided, realizes under special scenes not shadow Ring the effect of shooting image quality.
In order to realize above-described embodiment, the embodiment of the invention also provides a kind of electronic equipment, Fig. 4 is the embodiment of the present invention One of the structural schematic diagram of provided electronic equipment 100, as shown in figure 4, the electronic equipment 100 includes vibrating motor 40, takes the photograph As head 21, memory 31, processor 32.
Processor 32 is electrically connected with vibrating motor 40 and camera 21 respectively.
Processor 32 is realized described in preceding method embodiment for running the computer program being stored on memory 31 Vibration prompt processing method.
Based on the above embodiment, the embodiment of the invention also provides a kind of electronic equipment, Fig. 5 is mentioned by the embodiment of the present invention The second structural representation of the electronic equipment 100 of confession, as shown in figure 5, the electronic equipment 100 further includes:Ontology 10, sliding equipment 20, magnet 51, magnetic field detectors 55 and mainboard 30.
Sliding equipment 20 can opposing body 10 it is mobile, to protrude from the side wall of ontology 10, alternatively, being contained in ontology 10.
Camera 21 is provided on sliding equipment 20, camera 21 is slided with sliding equipment 20.
One in sliding equipment 20 and ontology 10 is provided with magnet 51, another in sliding equipment 20 and ontology 10 is set Magnetic field detectors 52 are equipped with, magnetic field detectors 52 and processor 32 are electrically connected.
As a kind of possible implementation, magnetic field detectors 52 are specially Hall element, and processor 32 is for receiving suddenly The detected signal value of your element output, and for determining sliding equipment 20 relative to the current of ontology 10 according to detected signal value Relative position, so that it is determined that whether sliding equipment 20 is complete when the needs of sliding equipment 20 are skidded off to protrude from the side wall of ontology 10 It skids off entirely to reach predetermined position, does not fully slide out arrival predeterminated position to avoid sliding equipment 20, and influence sliding equipment 20 The components such as camera, the sensor of middle carrying can not work normally, and lead to dysfunction;Alternatively, determining when sliding equipment 20 needs It slides back to when being contained in ontology 10, whether sliding equipment 20 slides back to reach predetermined position, not to avoid sliding equipment 20 completely Predetermined position is slid back into completely, influences the problem of electronic product beauty, or even can produce because of predetermined position is not slid back into completely Raw abnormal alarm.
It is worth noting that, " one in sliding equipment 20 and ontology 10 is provided with magnet 51,20 He of sliding equipment herein It includes two kinds of situations that another in ontology 10, which is provided with magnetic field detectors 52 ", first is that magnet 51 is fixed on sliding equipment 20, Magnetic field detectors 52 are fixed on ontology 10, second is that magnet 51 is fixed on ontology 10, magnetic field detectors 52 are fixed on skate machine On structure 20, as shown in Figure 5, for the set-up mode of another situation, principle is identical, no longer draws and shows.In addition, magnetic field is visited It surveys device 52 and magnet 51 can be staggered relatively in the vertical direction, it can also be staggered relatively in the horizontal direction.In other words, only It wants magnetic field detectors 52 and magnet 51 to can produce relative motion, the specific location of magnetic field detectors 52 and magnet 51 is not limited System.
By the analysis to above-described embodiment it is found that by the way that magnetic field detectors 52 and magnet 51 is arranged in electronic equipment 100, The relative motion of magnetic field detectors 52 and magnet 51, determines the phase of sliding equipment 20 and ontology 10 when being slided by sliding equipment 20 To position, and the method for the relative position of another detection sliding equipment and ontology is proposed in the present embodiment, pass through infrared biography Sensor determines the relative position of sliding equipment and ontology, and Fig. 6 is the structure of electronic equipment 100 provided by the embodiment of the present invention The three of schematic diagram, as shown in fig. 6, the electronic equipment 100 can also include infrared sensor, infrared sensor is set to skate machine In structure 20, infrared sensor at least two, in the present embodiment by taking two infrared sensors as an example, respectively 61 and 62, to this Embodiment is illustrated.
The glide direction out of plumb of the line of infrared sensor 61 and infrared sensor 62 and sliding equipment 20, infrared sensing Device 61 and infrared sensor 62 are electrically connected with processor 32 respectively.
As a kind of possible implementation, infrared sensor 61 and infrared sensor 62, one may be disposed at skate machine The top of structure 20, another may be disposed at the bottom end of sliding equipment 20, infrared after the sliding of sliding equipment 20 protrudes from ontology 10 Sensor 61 and 62 also protrudes from ontology 10, infrared sensor 61 and infrared sensor 62 can by detecting distance to determine whether It blocks, so that the relative position of sliding equipment 20 Yu ontology 10 is judged, specifically, when infrared sensor 61 and infrared sensor 62 at 10 inside of ontology, and the infrared light that infrared sensor issues is blocked by ontology 10, and the distance measured is smaller and threshold value It is close, with skidding off for sliding equipment 20, when the distance that infrared sensor 61 measures is much larger than threshold value, then the infrared sensor 61 protrude from ontology 10, similarly, it may be determined that whether infrared sensor 62 protrudes from ontology 10, to can determine that sliding equipment 20 is It is no to fully slide out to reach predetermined position, arrival predeterminated position is not fully slid out to avoid sliding equipment 20, and influence skate machine The components such as the camera, the sensor that carry in structure 20 can not work normally, and lead to dysfunction;Alternatively, sliding equipment is worked as in determination 20 need to slide back to when being contained in ontology 10, and whether sliding equipment 20 is slid back to completely to reach predetermined position, to avoid sliding equipment 20 do not slide back into predetermined position completely, influence the problem of electronic product beauty, or even can be because not sliding back into predetermined position completely And generate abnormal alarm.
In order to realize above-described embodiment, the embodiment of the present invention also proposes a kind of computer readable storage medium, stores thereon There is computer program, the processing side of the vibration prompt as described in preceding method embodiment is realized when which is executed by processor Method.
In the description of this specification, reference term " one embodiment ", " some embodiments ", " example ", " specifically show The description of example " or " some examples " etc. means specific features, structure, material or spy described in conjunction with this embodiment or example Point is included at least one embodiment or example of the invention.In the present specification, schematic expression of the above terms are not It must be directed to identical embodiment or example.Moreover, particular features, structures, materials, or characteristics described can be in office It can be combined in any suitable manner in one or more embodiment or examples.In addition, without conflicting with each other, the skill of this field Art personnel can tie the feature of different embodiments or examples described in this specification and different embodiments or examples It closes and combines.
In addition, term " first ", " second " are used for descriptive purposes only and cannot be understood as indicating or suggesting relative importance Or implicitly indicate the quantity of indicated technical characteristic.Define " first " as a result, the feature of " second " can be expressed or Implicitly include at least one this feature.In the description of the present invention, the meaning of " plurality " is at least two, such as two, three It is a etc., unless otherwise specifically defined.
Any process described otherwise above or method description are construed as in flow chart or herein, and expression includes It is one or more for realizing custom logic function or process the step of executable instruction code module, segment or portion Point, and the range of the preferred embodiment of the present invention includes other realization, wherein can not press shown or discussed suitable Sequence, including according to related function by it is basic simultaneously in the way of or in the opposite order, to execute function, this should be of the invention Embodiment person of ordinary skill in the field understood.
Expression or logic and/or step described otherwise above herein in flow charts, for example, being considered use In the order list for the executable instruction for realizing logic function, may be embodied in any computer-readable medium, for Instruction execution system, device or equipment (such as computer based system, including the system of processor or other can be held from instruction The instruction fetch of row system, device or equipment and the system executed instruction) it uses, or combine these instruction execution systems, device or set It is standby and use.For the purpose of this specification, " computer-readable medium ", which can be, any may include, stores, communicates, propagates or pass Defeated program is for instruction execution system, device or equipment or the dress used in conjunction with these instruction execution systems, device or equipment It sets.The more specific example (non-exhaustive list) of computer-readable medium includes following:Electricity with one or more wiring Interconnecting piece (electronic device), portable computer diskette box (magnetic device), random access memory (RAM), read-only memory (ROM), erasable edit read-only storage (EPROM or flash memory), fiber device and portable optic disk is read-only deposits Reservoir (CDROM).In addition, computer-readable medium can even is that the paper that can print described program on it or other are suitable Medium, because can then be edited, be interpreted or when necessary with it for example by carrying out optical scanner to paper or other media His suitable method is handled electronically to obtain described program, is then stored in computer storage.
It should be appreciated that each section of the invention can be realized with hardware, software, firmware or their combination.Above-mentioned In embodiment, software that multiple steps or method can be executed in memory and by suitable instruction execution system with storage Or firmware is realized.Such as, if realized with hardware in another embodiment, following skill well known in the art can be used Any one of art or their combination are realized:With for data-signal realize logic function logic gates from Logic circuit is dissipated, the specific integrated circuit with suitable combinational logic gate circuit, programmable gate array (PGA), scene can compile Journey gate array (FPGA) etc..
Those skilled in the art are understood that realize all or part of step that above-described embodiment method carries It suddenly is that relevant hardware can be instructed to complete by program, the program can store in a kind of computer-readable storage medium In matter, which when being executed, includes the steps that one or a combination set of embodiment of the method.
It, can also be in addition, each functional unit in each embodiment of the present invention can integrate in a processing module It is that each unit physically exists alone, can also be integrated in two or more units in a module.Above-mentioned integrated mould Block both can take the form of hardware realization, can also be realized in the form of software function module.The integrated module is such as Fruit is realized and when sold or used as an independent product in the form of software function module, also can store in a computer In read/write memory medium.
Storage medium mentioned above can be read-only memory, disk or CD etc..Although having been shown and retouching above The embodiment of the present invention is stated, it is to be understood that above-described embodiment is exemplary, and should not be understood as to limit of the invention System, those skilled in the art can be changed above-described embodiment, modify, replace and become within the scope of the invention Type.

Claims (15)

1. a kind of processing method of vibration prompt, which is characterized in that be applied to electronic equipment, the electronic equipment has vibration horse It reaches, the described method comprises the following steps:
Interface for calling vibration to service is listened to;Wherein, the vibration service is for controlling the vibrating motor hair Vibration prompt out;
When listening to call request, vibration parameters are obtained from the call request;
According to the vibration parameters, vibration time type is identified;
According to the vibration time type, determine whether prevent the call request during foreground application calls camera To the calling of the vibration service.
2. processing method according to claim 1, which is characterized in that it is described according to the vibration time type, it determines Whether foreground application prevents the call request to the calling of the vibration service during calling camera, including:
If the vibration time type is that long type prevents the calling during foreground application calls camera in short-term Request the calling to the vibration service;
If long type when vibration time type is long, during foreground application calls camera, allow the call request To the calling of the vibration service.
3. processing method according to claim 1, which is characterized in that it is described according to the vibration parameters, when identification is vibrated Long type, including:
When there is the single parameter value for being used to indicate single vibration time in the vibration parameters, the vibration time class is identified Type is long type in short-term;
When there is one group of parameter value for being used to indicate multiple vibration time in the vibration parameters, according in the vibration parameters It is used to indicate the parameter value of implementation strategy, identifies long type or long type in short-term when the vibration time type is long.
4. processing method according to claim 3, which is characterized in that described to hold according to being used to indicate in the vibration parameters The parameter value of row strategy identifies long type or long type in short-term when the vibration time type is long, including:
It is used to indicate the parameter value of implementation strategy described in reading from the vibration parameters, and determines the implementation strategy;
If the implementation strategy is that circulation executes, long type when the vibration time type is long is determined;
If the implementation strategy is when executing since n-th of one group of parameter value, to determine that the vibration time type is Long type in short-term;Wherein, n is positive integer;
If the implementation strategy is that single executes, determine the vibration time type for long type in short-term.
5. processing method according to claim 1-4, which is characterized in that the call request carries triggering vibration Dynamic event information;It is described to further include before identifying vibration time type according to the vibration parameters:
Determine that the event information of the triggering vibration meets presupposed information.
6. processing method according to claim 5, which is characterized in that the presupposed information is that non-virtual key triggers thing Part.
7. processing method according to claim 1-4, which is characterized in that the method also includes:
The mark of the application program of front stage operation is obtained by operating system;
By the function being previously inserted in webcam driver program, the mark for calling the application program of camera is obtained;
If the mark of the application program of the front stage operation is matched with the mark of the application program for calling camera, before determining Camera is called in platform application.
8. a kind of processing unit of vibration prompt, which is characterized in that be applied to electronic equipment, the electronic equipment has vibration horse It reaches, described device includes:
Module is listened to, for listening to the interface for calling vibration to service;Wherein, the vibration service is for controlling It states vibrating motor and issues vibration prompt;
Module is obtained, for obtaining vibration parameters from the call request when listening to call request;
Identification module, for identifying vibration time type according to the vibration parameters;
Determining module, for determining whether hinder during foreground application calls camera according to the vibration time type Only calling of the call request to the vibration service.
9. a kind of electronic equipment, which is characterized in that including:Vibrating motor, camera, memory, processor and it is stored in storage On device and the computer program that can run on a processor, the vibrating motor and the camera respectively with the processor electricity Property connection realize the processing of vibration prompt as described in any in claim 1-7 when the processor executes described program Method.
10. electronic equipment according to claim 9, which is characterized in that the electronic equipment includes ontology and sliding equipment, The sliding equipment can be mobile relative to the ontology, to protrude from the side wall of the ontology, alternatively, being contained in the ontology;
Wherein, the camera is provided on the sliding equipment, the camera is slided with the sliding equipment.
11. electronic equipment according to claim 10, which is characterized in that one in the sliding equipment and the ontology Be provided with magnet, another in the sliding equipment and the ontology is provided with magnetic field detectors, the magnetic field detectors with The processor is electrically connected.
12. electronic equipment according to claim 11, which is characterized in that the memory and the processor are set to institute It states on the mainboard of body interior;The mainboard is fixedly connected with the ontology;
The magnet is set to the sliding equipment, and the magnetic field detectors are set to the mainboard;Alternatively, the magnet setting In the mainboard, the magnetic field detectors are set to the sliding equipment.
13. electronic equipment according to claim 12, which is characterized in that the magnetic field detectors are specially Hall element;
The processor is also used to receive the detected signal value of the Hall element output;It is determined according to the detected signal value Position of the sliding equipment relative to the ontology.
14. electronic equipment according to claim 10, which is characterized in that the sliding equipment is provided with infrared sensor, The infrared sensor is at least two, the glide direction of line and the sliding equipment between at least two infrared sensors Out of plumb;The infrared sensor and the processor are electrically connected;
The processor is also used to receive the optical signal value of at least two infrared sensor;According at least two light Signal value determines position of the sliding equipment relative to the ontology.
15. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the program is by processor The processing method of the vibration prompt as described in any in claim 1-7 is realized when execution.
CN201810601652.9A 2018-06-08 2018-06-08 The treating method and apparatus of vibration prompt Pending CN108900702A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810601652.9A CN108900702A (en) 2018-06-08 2018-06-08 The treating method and apparatus of vibration prompt

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810601652.9A CN108900702A (en) 2018-06-08 2018-06-08 The treating method and apparatus of vibration prompt

Publications (1)

Publication Number Publication Date
CN108900702A true CN108900702A (en) 2018-11-27

Family

ID=64344782

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810601652.9A Pending CN108900702A (en) 2018-06-08 2018-06-08 The treating method and apparatus of vibration prompt

Country Status (1)

Country Link
CN (1) CN108900702A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2020181530A1 (en) * 2019-03-13 2020-09-17 深圳市大疆创新科技有限公司 Gimbal vibration adjustment method, gimbal and client
CN113726957A (en) * 2021-08-30 2021-11-30 联想(北京)有限公司 Vibration control method and device and electronic equipment
CN114727010A (en) * 2022-02-28 2022-07-08 荣耀终端有限公司 Camera control method, device and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104468951A (en) * 2013-09-18 2015-03-25 联想(北京)有限公司 Information processing method and electronic equipment
US20150087274A1 (en) * 2013-09-20 2015-03-26 Lenovo (Singapore) Pte, Ltd. Modifying a device notification
CN104767870A (en) * 2014-01-07 2015-07-08 中兴通讯股份有限公司 Message response method and device
CN105228116A (en) * 2015-10-27 2016-01-06 努比亚技术有限公司 A kind of intelligent prompt device, method and mobile terminal distinguishing information priorities

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104468951A (en) * 2013-09-18 2015-03-25 联想(北京)有限公司 Information processing method and electronic equipment
US20150087274A1 (en) * 2013-09-20 2015-03-26 Lenovo (Singapore) Pte, Ltd. Modifying a device notification
CN104767870A (en) * 2014-01-07 2015-07-08 中兴通讯股份有限公司 Message response method and device
CN105228116A (en) * 2015-10-27 2016-01-06 努比亚技术有限公司 A kind of intelligent prompt device, method and mobile terminal distinguishing information priorities

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2020181530A1 (en) * 2019-03-13 2020-09-17 深圳市大疆创新科技有限公司 Gimbal vibration adjustment method, gimbal and client
CN113726957A (en) * 2021-08-30 2021-11-30 联想(北京)有限公司 Vibration control method and device and electronic equipment
CN114727010A (en) * 2022-02-28 2022-07-08 荣耀终端有限公司 Camera control method, device and storage medium
CN114727010B (en) * 2022-02-28 2023-08-22 荣耀终端有限公司 Control method, equipment and storage medium of camera

Similar Documents

Publication Publication Date Title
EP3574633B1 (en) Electronic device including speaker
CN108900702A (en) The treating method and apparatus of vibration prompt
CN106056841B (en) Safe early warning method, apparatus and system based on mobile terminal
EP3866011A1 (en) Resource processing method and apparatus for mobile terminal, computer device and storage medium
CN109462726B (en) Camera control method and device
CN108154140A (en) Voice awakening method, device, equipment and computer-readable medium based on lip reading
CN110224870B (en) Interface monitoring method and device, computing equipment and storage medium
CN104811613A (en) Camera focusing method
CA3074367C (en) Distributed muster for ocean-going vessels
EP4080862B1 (en) Intelligent reminding method and device
CN108829461A (en) Camera starts control method, device and electronic equipment
CN105426485A (en) Image combination method and device, intelligent terminal and server
CN109660859A (en) A kind of animated show method and mobile terminal
CN108989638B (en) Imaging apparatus, control method thereof, electronic apparatus, and computer-readable storage medium
CN108810051A (en) Data transmission method and device
CN104811612A (en) Terminal
CN110677580B (en) Shooting method, shooting device, storage medium and terminal
CN108845836A (en) Control method, device and the electronic equipment of sliding equipment
CN107684787B (en) Dust removal method and dust removal device for mobile terminal
CN105791685A (en) Control method, control device and electronic device
CN112423176A (en) Earphone noise reduction method and device, storage medium and noise reduction earphone
CN105791542A (en) Method and device for searching mobile terminal and mobile terminal
CN108986279A (en) Starting method, system, electric bicycle and the storage medium of electric bicycle
CN103685935B (en) Method and apparatus for controlling camera image capture
JP2024019277A (en) Driving condition monitoring device, driving condition monitoring system, driving condition monitoring method, and drive recorder

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20181127

RJ01 Rejection of invention patent application after publication