CN104182231B - A kind of progress control method and system of acceleration transducer application function - Google Patents
A kind of progress control method and system of acceleration transducer application function Download PDFInfo
- Publication number
- CN104182231B CN104182231B CN201410416787.XA CN201410416787A CN104182231B CN 104182231 B CN104182231 B CN 104182231B CN 201410416787 A CN201410416787 A CN 201410416787A CN 104182231 B CN104182231 B CN 104182231B
- Authority
- CN
- China
- Prior art keywords
- application function
- acceleration transducer
- timing
- frequency values
- acceleration
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Landscapes
- Telephone Function (AREA)
Abstract
The progress control method and system of a kind of acceleration transducer application function provided by the present invention, frequency values by obtaining data from acceleration transducer to application function preset into different numerical value, and the time for being obtained data to it according to the difference of its corresponding frequency values to the application function of each unlatching using timer and counter is timed, meet its acquisition data time value time-out when detecting, acceleration information is then sent to application function by acceleration transducer, to realize multiple purposes that the application function of its function is realized using acceleration transducer are run in the same time, improve the practicability and experience property of mobile terminal.
Description
Technical field
The present invention relates to a kind of operation of mobile communication field more particularly to acceleration transducer application function controls
Method and system.
Background technology
Currently, in intelligent terminal increasing has acceleration transducer, acceleration transducer to be widely used, may be used as moving
Terminal falls detection, tilt detection, whipping detection etc., while user-friendly, increases the body of intelligent terminal
The property tested.
But in the prior art, acceleration transducer sensor can only execute a kind of function within the same time;For example,
Acceleration transducer can realize following two functions respectively:Function one:Pedometer, function two:Transverse screen and vertical screen detection;But
In the prior art, both the above function can not enable simultaneously.
Therefore, the prior art is up for further improving.
Invention content
In view of above-mentioned shortcoming in the prior art, it is an object of the invention to provide a kind of acceleration sensing to the user
The progress control method and acceleration transducer of device application function, with solve in the prior art acceleration transducer in the same time
A problem of function can only be executed.
The technical proposal for solving the technical problem of the invention is as follows:
A kind of progress control method of acceleration transducer application function, wherein including:
A, prestore each application function from acceleration transducer obtain acceleration value corresponding to frequency values;
B, reception and the instruction of the opening application function that user sends out is executed;
C, the corresponding frequency values of whole application functions opened simultaneously are obtained;Acceleration transducer will according to the frequency values
Acceleration value is sent to corresponding application function;
D, application function runs simultaneously program according to the acceleration value got.
The progress control method of the acceleration transducer application function, wherein the step C includes:
The greatest common divisor of frequency values inverse corresponding to the application function that C11, calculating open simultaneously;
C21, acceleration transducer is timed by the timing of timer of the greatest common divisor, and counter is every
Every timing plus one;
C31, acceleration transducer the acceleration value got is sent to meet it is digital on timing and counter
The application function that product can be divided exactly by the inverse of frequency values.
The progress control method of the acceleration transducer application function, wherein further include after the step D:
If E, detect that user sends out closing or opens the instruction of any one application function, the instruction is executed,
And counter is reset, return to step C.
The progress control method of the acceleration transducer application function, wherein the step C further includes:
C21, judge whether the number for the application function that user opens is one, thens follow the steps C2 if one, otherwise
Execute step D;
C22, the inverse that the timing that timer is arranged is the corresponding frequency values of the application function.
The progress control method of the acceleration transducer application function, which is characterized in that also wrapped after the step E
It includes:
F, after detecting that user closes whole application functions, then Off Timer and counter.
A kind of operation control system of acceleration transducer application function, wherein including:
Memory module, for prestore each application function from acceleration transducer obtain acceleration value corresponding to frequency
Rate value;
Instruction module is received, the instruction for receiving and executing the opening application function that user sends out;
Frequency module is obtained, for obtaining the corresponding frequency values of whole application functions opened simultaneously;Acceleration transducer
Acceleration value is sent to corresponding application function according to the frequency values;
Module is run simultaneously, program is run simultaneously according to the acceleration value got for application function.
The operation control system of the acceleration transducer application function, wherein the acquisition frequency module includes pact
Number computing unit, timing unit and data transmission unit;
The common divisor computing unit, the most grand duke for calculating frequency values inverse corresponding to the application function opened simultaneously
Approximate number;
The timing unit, for determining acceleration transducer by the timing of timer of the greatest common divisor
When, and counter adds one every timing;
The acceleration value got is sent to for acceleration transducer and meets timing by the data transmission unit
With the application function that can be divided exactly by the inverse of frequency values of product of numbers on counter.
The operation control system of the acceleration transducer application function, wherein further include:
Application module is restarted, for when detecting that user sends out closing or open any one acceleration transducer application
When the instruction of function, then the instruction is executed, and reset counter, recalculate timing.
The operation control system of the acceleration transducer application function, wherein the acquisition frequency module further includes:Sentence
Disconnected counting unit and timing setting unit;
A counting unit is judged, for judging whether the number of the application function of user's unlatching is one;
Start by set date unit, the timing for timer to be arranged are falling for the corresponding frequency values of the application function
Number.
The operation control system of the acceleration transducer application function, which is characterized in that further include applying closedown module;
It is described to apply closedown module, for it ought detect that user closes whole application functions after, Off Timer and meter
Number device.
Advantageous effect, a kind of progress control method and system of acceleration transducer application function provided by the present invention,
By presetting into different numerical value in the frequency values for obtaining data from acceleration transducer to application function, and use timing
The time that the difference of the frequency of device and counter to the application function of each unlatching corresponding to it obtains it data carries out
Periodically, when detecting that meeting its obtains data time value time-out, then pass through acceleration transducer and send acceleration information to applying
Function runs multiple mesh that the application function of its function is realized using acceleration transducer to realize in the same time
, improve the practicability and experience property of mobile terminal.
Description of the drawings
Fig. 1 is a kind of method and step flow chart of the operation control of acceleration transducer application function of the present invention.
Fig. 2 is a kind of theory structure schematic diagram of the system of the operation control of acceleration transducer application function of the present invention.
Specific implementation mode
To make the objectives, technical solutions, and advantages of the present invention clearer and more explicit, develop simultaneously embodiment pair referring to the drawings
The present invention is further described.It should be appreciated that specific embodiment described herein is used only for explaining the present invention, and do not have to
It is of the invention in limiting.
A kind of progress control method of acceleration transducer application function provided by the present invention is as shown in Figure 1 described
The step flow chart of method, as shown, the described method comprises the following steps:
S1, prestore each application function from acceleration transducer obtain acceleration value corresponding to frequency values.
Due in the prior art, obtaining acceleration value from acceleration transducer to complete the application journey of application function
Sequence is to obtain data using same frequency, therefore the same time can only use one corresponding with acceleration transducer to answer
Use function.
In order to overcome the same time in the prior art that can only use the scarce of function corresponding with acceleration transducer
It is sunken, it is that acceleration value is each obtained from acceleration transducer to complete the application function of operational order in advance in the method for the present invention
Setting preserves a corresponding frequency values, in order to allow different application functions to use different frequencies from acceleration transducer
Place obtains acceleration value.
The corresponding frequency values of each application function are different in the method for the present invention that it can be seen from the above, so
It can preferably realize that different application function can get acceleration value in different times, synchronize operation.
S2, reception and the instruction for executing the opening application function that user sends out.
User is to receive the instruction for the opening application function that user sends out after each application function sets frequency values, move
Dynamic terminal receives the instruction and opens corresponding application function.The application function is to need to obtain number from acceleration transducer
According to realizing its function, such as:Pedometer, transverse screen vertical screen detection or fall detection etc..
The corresponding frequency values of whole application functions that S3, acquisition open simultaneously;Acceleration transducer is according to the frequency values
Acceleration value is sent to corresponding application function.
Acceleration value is sent to corresponding by acceleration transducer according to the preset frequency values of the application function opened simultaneously
Application function.
In order to preferably according to scheduled frequency values come transmission data, further include in this step:
S311 calculates the greatest common divisor of frequency values inverse corresponding to the application function opened simultaneously.
After user opens simultaneously the application function of several acquisition acceleration values being connected with acceleration transducer, obtain first
The preset frequency values of these application functions opened simultaneously are taken, and calculate the highest common divisor reciprocal corresponding to these frequency values
Number that is to say and calculate the corresponding greatest common divisor for obtaining the data period from acceleration transducer of these application functions.
S312, acceleration transducer is timed by the timing of timer of the greatest common divisor, and counter
Every timing plus one.
The timer being connected with acceleration transducer and application function is with calculated highest common divisor in above-mentioned steps S3
The counter that number is timed for timing, and is connected with application function counts the number of timing time-out
It counts, that is to say every the update of timing counter data once, time-out is primary just to add one.
S313, acceleration transducer the acceleration value got is sent to meet it is digital on timing and counter
The application function that product can be divided exactly by the inverse of frequency values.
When the number on counter meets:It is default equal to some application program that number on counter is multiplied by timing
Frequency values inverse when, then the acceleration value that acceleration transducer is obtained is sent to the application program, substantially
Be when timing summation of timer etc. with the application function from acceleration transducer from obtain data period when, then plus
Velocity sensor sends acceleration value to the application function.
S4, application function run simultaneously program according to the acceleration value got.
It gets the acceleration value that the application function of the acceleration value is got according to it while running program, complete to use
The operation that family is sent out.
In order to which the operation of better pair of application function corresponding with acceleration transducer controls, in the above method
On the basis of, there can also be following improvement:
Further include after the step S4:
If S5, when detecting that user sends out the instruction for turning off or on any one application function again, executing this and referring to
It enables, and resets counter, return to step S3.
If user close or in addition open again it is other need to obtain data from acceleration transducer apply work(
Can, then after closing or opening the application function, counter is zeroed out, and return to step S3 recalculates current unlatching
Whole application functions corresponding to frequency values inverse greatest common divisor, with new calculated highest common divisor numerical value to timer into
The progress control method of the row timing acceleration transducer application function, which is characterized in that the step S3 further includes:
S321, judge whether the number for the application function that user opens is one, and S322 is thened follow the steps if one, it is no
Then follow the steps S4.
If the application function that user opens is only one, the highest common divisor numerical value of its frequency inverse need not be calculated,
Next step is directly executed, it is no to then follow the steps S4.
S322, the inverse that the timing that timer is arranged is the corresponding frequency values of the application function.
The timing of timer is provided directly as to the inverse of the corresponding frequency values of the application function.
Further include after the step S5:
S6, after detecting that user closes whole application functions, then Off Timer and counter.
In order to carry out more detailed explanation to the above method, the concrete application situation of the method is said below
It is bright.
User will each need the acquisition data from acceleration transducer that could complete measurement first on its mobile terminal
The frequency that application program obtains data is configured, which could be provided as equidistant increase and either reduce or equimultiple
Number increases or reduces.For example the frequency values being arranged are:0.01Hz, 0.02 Hz, 0.05 Hz ....
After frequency values are provided with, user opens simultaneously the application work(that several needs obtain data from acceleration transducer
Can, such as three application functions have been opened simultaneously, preset frequency values are respectively:0.01Hz, 0.02 Hz, 0.05 Hz, meter
The greatest common divisor for calculating these three frequency values inverse is:10, then it was timed using timer for timing with 10 seconds, and
And after timer expiry, counter adds one, and after timer 10 seconds, timing time-out, then the number of counter is changed to 1, at this time
The frequency of three application functions is unsatisfactory for obtaining the condition of acceleration information value, and timer continues timing, works as counter
On number when being 2, then the application function that predeterminated frequency value is 0.05 at this time meets the number on timing and counter
Product can be divided exactly by the inverse of frequency values, i.e.,(10*2 )It can quilt(1/0.05)Divide exactly, therefore acceleration transducer is obtained at this time
The acceleration value taken is sent to the application function that the predeterminated frequency value is 0.05 Hz.
After timer is reset, timing is re-started, after the 5th time-out, the number on counter is 5, then presets at this time
The application function that frequency values are 0.02 meets timing and can be divided exactly by the inverse of frequency values product with the number on counter, i.e.,
(10*5 )It can quilt(1/0.02)Divide exactly, therefore the acceleration value that acceleration transducer is obtained at this time is sent to the default frequency
Rate value is the application function of 0.02 Hz.
After the tenth time-out of timer, the number 10 on counter, then predeterminated frequency value is 0.01 using work(at this time
Timing can be met and the product of the number on counter can be divided exactly by the inverse of frequency values, i.e.,(10*10 )It can quilt(1/
0.01)Divide exactly, therefore it is 0.01 Hz's that the acceleration value that acceleration transducer is obtained at this time, which is sent to the predeterminated frequency value,
Application function.Meanwhile application function that predeterminated frequency value is 0.02 meets timing and multiplies with digital on counter at this time
Product can be divided exactly by the inverse of frequency values, i.e.,(10*10 )It can quilt(1/0.02)Divide exactly, therefore acceleration transducer is obtained at this time
The acceleration value taken is sent to the application function that the predeterminated frequency value is 0.02 Hz.Meanwhile predeterminated frequency value is 0.05 at this time
Application function meets timing and can be divided exactly by the inverse of frequency values product with the number on counter, i.e.,(10*10 )It can quilt
(1/0.05)Divide exactly, therefore it is 0.05 that the acceleration value that acceleration transducer is obtained at this time, which is sent to the predeterminated frequency value,
The application function of Hz.
It is run at the same time to realize three different application functions, user can use upper in the terminal simultaneously
State three application functions.
On the basis of the present invention above-mentioned method, the invention also discloses a kind of operations of acceleration transducer application function
Control system, as shown in Fig. 2, the system comprises:
Memory module 10 is obtained from acceleration transducer corresponding to acceleration value for prestoring each application function
Frequency values;Its function is as described in above-mentioned steps S1.
Instruction module 20 is received, the instruction for receiving and executing the opening application function that user sends out;Its function is as above
It states described in step S2.
Frequency module 30 is obtained, for obtaining the corresponding frequency values of whole application functions opened simultaneously;Acceleration sensing
Acceleration value is sent to corresponding application function by device according to the frequency values;Its function is as described in above-mentioned steps S3.
Module 40 is run simultaneously, program is run simultaneously according to the acceleration value got for application function.Its function is such as
Described in above-mentioned steps S4.
The acquisition frequency module includes common divisor computing unit, timing unit and data transmission unit;
The common divisor computing unit, the most grand duke for calculating frequency values inverse corresponding to the application function opened simultaneously
Approximate number;
The timing unit, for determining acceleration transducer by the timing of timer of the greatest common divisor
When, and counter adds one every timing;
The acceleration value got is sent to for acceleration transducer and meets timing by the data transmission unit
The application function that can be divided exactly by the inverse of frequency values with product digital on counter.
The operation control system of the acceleration transducer application function, wherein further include:
Application module is restarted, for when detecting that user sends out closing or open any one acceleration transducer application
When the instruction of function, then the instruction is executed, and reset counter, recalculate timing.
The operation control system of the acceleration transducer application function, wherein the acquisition frequency module further includes:It obtains
Take frequency cells and timing setting unit;
A counting unit is judged, for judging whether the number of the application function of user's unlatching is one;
Start by set date unit, the timing for timer to be arranged are falling for the corresponding frequency values of the application function
Number.
The operation control system of the acceleration transducer application function, wherein further include applying closedown module;
It is described to apply closedown module, for it ought detect that user closes whole application functions after, Off Timer and meter
Number device.
The progress control method and system of a kind of acceleration transducer application function provided by the present invention, by correspondence
The frequency values for obtaining data from acceleration transducer with function preset into different numerical value, and each application function is according in advance
The frequency of setting to obtain data from acceleration transducer, specifically, the application using timer and counter to each unlatching
The time that the difference of frequency of the function corresponding to it obtains it data is timed, and meets its acquisition data when detecting
Time value time-out, reads the number of counter, when the predeterminated frequency of the application function of a certain unlatching meets:Timing and frequency
The inverse of value product can be divided exactly by the number on counter, then send acceleration information to using work(by acceleration transducer
Can, multiple purposes that the application function of its function is realized using acceleration transducer are run in the same time to realize,
Improve the practicability and experience property of mobile terminal.
It, can according to the technique and scheme of the present invention and its hair it is understood that for those of ordinary skills
Bright design is subject to equivalent substitution or change, and all these changes or replacement should all belong to the guarantor of appended claims of the invention
Protect range.
Claims (7)
1. a kind of progress control method of acceleration transducer application function, which is characterized in that including:
A, prestore each application function from acceleration transducer obtain acceleration value corresponding to frequency values;
B, reception and the instruction of the opening application function that user sends out is executed;
C, the corresponding frequency values of whole application functions opened simultaneously are obtained;Acceleration transducer will accelerate according to the frequency values
Angle value is sent to corresponding application function;
D, application function runs simultaneously program according to the acceleration value got;
The step C includes:
The greatest common divisor of frequency values inverse corresponding to the application function that C11, calculating open simultaneously;
C21, acceleration transducer is timed by the timing of timer of the greatest common divisor, and counter is every fixed
When the time add one;
The acceleration value got is sent to by C31, acceleration transducer meets timing and product digital on counter
The application function that can be divided exactly by the inverse of frequency values.
2. the progress control method of acceleration transducer application function according to claim 1, which is characterized in that the step
Further include after D:
If E, detect that user sends out closing or opens the instruction of any one application function, the instruction is executed, and clear
To-zero counter, return to step C.
3. the progress control method of acceleration transducer application function according to claim 2, which is characterized in that the step
Further include after E:
F, after detecting that user closes whole application functions, then Off Timer and counter.
4. a kind of operation control system of acceleration transducer application function, which is characterized in that including:
Memory module, for prestore each application function from acceleration transducer obtain acceleration value corresponding to frequency
Value;
Instruction module is received, the instruction for receiving and executing the opening application function that user sends out;
Frequency module is obtained, for obtaining the corresponding frequency values of whole application functions opened simultaneously;Acceleration transducer according to
Acceleration value is sent to corresponding application function by the frequency values;
Module is run simultaneously, program is run simultaneously according to the acceleration value got for application function;
The acquisition frequency module includes common divisor computing unit, timing unit and data transmission unit;
The common divisor computing unit, the highest common divisor for calculating frequency values inverse corresponding to the application function opened simultaneously
Number;
The timing unit, for being timed to acceleration transducer by the timing of timer of the greatest common divisor,
And counter adds one every timing;
The acceleration value got is sent to by acceleration transducer and meets timing with based on by the data transmission unit
The application function that digital product can be divided exactly by the inverse of frequency values on number device.
5. the operation control system of acceleration transducer application function according to claim 4, which is characterized in that further include:
Application module is restarted, for when detecting that user sends out closing or open any one acceleration transducer application function
Instruction when, then execute the instruction, and reset counter, recalculate timing.
6. the operation control system of acceleration transducer application function according to claim 4, which is characterized in that the acquisition
Frequency module further includes:Judge a counting unit and timing setting unit;
A counting unit is judged, for judging whether the number of the application function of user's unlatching is one;
Start by set date unit, the timing for timer to be arranged are the inverse of the corresponding frequency values of the application function.
7. the operation control system of acceleration transducer application function according to claim 4, which is characterized in that further include answering
Use closedown module;
It is described to apply closedown module, for it ought detect that user closes whole application functions after, Off Timer and counter.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410416787.XA CN104182231B (en) | 2014-08-22 | 2014-08-22 | A kind of progress control method and system of acceleration transducer application function |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410416787.XA CN104182231B (en) | 2014-08-22 | 2014-08-22 | A kind of progress control method and system of acceleration transducer application function |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104182231A CN104182231A (en) | 2014-12-03 |
CN104182231B true CN104182231B (en) | 2018-07-17 |
Family
ID=51963310
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410416787.XA Active CN104182231B (en) | 2014-08-22 | 2014-08-22 | A kind of progress control method and system of acceleration transducer application function |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104182231B (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106851000A (en) * | 2017-02-24 | 2017-06-13 | 惠州Tcl移动通信有限公司 | A kind of mobile terminal light intensity detection process method and system |
CN107302628B (en) | 2017-05-27 | 2020-02-11 | Oppo广东移动通信有限公司 | Application function control method and related product |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP2207154A1 (en) * | 2009-01-12 | 2010-07-14 | Info Network Systems | Method and device for detecting a fall |
CN102833644A (en) * | 2011-06-15 | 2012-12-19 | 比亚迪股份有限公司 | Bluetooth headset with acceleration transducer and control method of Bluetooth headrest |
CN103027687A (en) * | 2012-12-05 | 2013-04-10 | 北京工业大学 | Old people fall detection and alarm system based on 3D (3-dimensional) accelerometer and gyroscope |
CN103386181A (en) * | 2013-07-25 | 2013-11-13 | Tcl通讯(宁波)有限公司 | Mobile terminal and rope skipping counting method adopting same |
-
2014
- 2014-08-22 CN CN201410416787.XA patent/CN104182231B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP2207154A1 (en) * | 2009-01-12 | 2010-07-14 | Info Network Systems | Method and device for detecting a fall |
CN102833644A (en) * | 2011-06-15 | 2012-12-19 | 比亚迪股份有限公司 | Bluetooth headset with acceleration transducer and control method of Bluetooth headrest |
CN103027687A (en) * | 2012-12-05 | 2013-04-10 | 北京工业大学 | Old people fall detection and alarm system based on 3D (3-dimensional) accelerometer and gyroscope |
CN103386181A (en) * | 2013-07-25 | 2013-11-13 | Tcl通讯(宁波)有限公司 | Mobile terminal and rope skipping counting method adopting same |
Also Published As
Publication number | Publication date |
---|---|
CN104182231A (en) | 2014-12-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106053103B (en) | Node Dynamic Data Acquiring and propagation | |
US11234656B2 (en) | Information processing apparatus and information processing method | |
CN105473062B (en) | Information processing unit, information processing method and information processing system | |
CN109558053A (en) | A kind of method, mobile terminal and computer readable storage medium for adjusting screen and showing | |
US10292639B2 (en) | Information processing device and information processing method | |
CN103400476A (en) | Sitting posture reminding method and device | |
CN102999264A (en) | Method and device for automatically setting desktop background, and electronic equipment | |
CN103645629B (en) | A kind of alarm clock timing method | |
CN107045528A (en) | A kind of method and terminal reminded of going on a journey | |
CN105549878A (en) | Electronic book page turning control method and device | |
CN104182231B (en) | A kind of progress control method and system of acceleration transducer application function | |
CN111278155B (en) | Information transmission method, terminal equipment and network side equipment | |
CN106037560A (en) | Intelligent shower system and control method thereof | |
CN104954528A (en) | Detection method and apparatus of electricity consumption information of terminal equipment | |
CN108469101A (en) | A kind of method of remote control air cleaning unit | |
CN104301060B (en) | A kind of node synchronous collection method and system sampled based on hardware trigger | |
CN105353964A (en) | Input control method, apparatus and terminal equipment | |
CN107969009A (en) | The method, apparatus and terminal of control terminal communication | |
CN103164281B (en) | Control to gather method and the electronic equipment of image | |
CN104156592B (en) | Data processing method and data processing equipment | |
CN115793918A (en) | Wallpaper display method and device and electronic equipment | |
US20170046497A1 (en) | Sensory Density and Diversity for Living in Place | |
WO2001059736A3 (en) | System and method of facilities and operations monitoring and remote management support | |
CN110072207A (en) | A kind of remote collecting device based on NB-IoT technology | |
CN109869863A (en) | A kind of air purifier based on Internet technology |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |