CN105844179A - Terminal protection method and device - Google Patents

Terminal protection method and device Download PDF

Info

Publication number
CN105844179A
CN105844179A CN201610158742.6A CN201610158742A CN105844179A CN 105844179 A CN105844179 A CN 105844179A CN 201610158742 A CN201610158742 A CN 201610158742A CN 105844179 A CN105844179 A CN 105844179A
Authority
CN
China
Prior art keywords
acceleration
terminal
difference
current
judge
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
CN201610158742.6A
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 CN201610158742.6A priority Critical patent/CN105844179A/en
Publication of CN105844179A publication Critical patent/CN105844179A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/81Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer by operating on the power supply, e.g. enabling or disabling power-on, sleep or resume operations

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Telephone Function (AREA)

Abstract

The embodiment of the invention discloses a terminal protection method and device. The terminal protection method comprises the following steps: obtaining the current accelerated speed of a terminal; subsequently, obtaining an accelerated speed difference value between the accelerated speed and a previous historical accelerated speed of the terminal; judging whether the accelerated speed difference value is greater than a first preset difference value or not; and if the accelerated speed difference value is greater than the first preset difference value, cutting off the power supply of the terminal. The scheme can cut off the power supply according to the accelerated speed difference value of the terminal when the power supply of the terminal needs to be cut off, and a user does not need to manually execute a power supply cutoff operation. Compared with the prior art, the terminal protection method quickens a power failure speed and can timely protect the terminal.

Description

A kind of terminal protecting methdo and device
Technical field
The present invention relates to field of terminal technology, particularly relate to a kind of terminal protecting methdo and device.
Background technology
Along with development and the development of mobile communications network of the Internet, simultaneously also along with the disposal ability of terminal With the fast development of storage capacity, the application program of magnanimity has obtained rapid propagation and use;Conventional application Program, while facilitating user job and life, is no lack of the application program newly developed day also into user Often life, the amusement sense in the quality of life that improve user, the frequency using terminal and use.
During the research present invention, inventor finds, the mode that the most typically employing complete machine is waterproof is to falling The terminal of water carries out waterproofing protection.But, which spends cost relatively big, and the water-proofing time of water-tight device Shorter, it is impossible to inherently this terminal to be protected.Such as, when terminal is fallen in deep water, if not having Having the power supply cut off this terminal, its motherboard circuit is susceptible to short circuit in the case of energising, causes terminal to damage Bad;In the prior art, needing artificially to perform power operation, due to the depth of water, user possibly cannot quickly send out Existing overboard terminal carries out power operation, and therefore power-off speed is slow, and once exceedes the anti-of terminal water-tight device The water time, terminal will be damaged.
From the foregoing, it will be observed that in prior art, when needs carry out power-off protection to terminal, there is terminal power-off speed Spend slower technical problem.
Summary of the invention
The embodiment of the present invention provides a kind of terminal protecting methdo and device, can solve in prior art at needs When terminal is carried out power-off protection, the slow technical problem of terminal power-off.
The embodiment of the present invention provides a kind of terminal protecting methdo, including:
Obtain the acceleration that terminal is current;
Obtain the acceleration difference between the history acceleration before described acceleration and described terminal;
Judge that whether described acceleration difference is more than the first preset difference value;
The most then cut off the power supply to described terminal.
In an embodiment of the present invention, after judging that described acceleration difference is more than the first preset difference value, cut Before the disconnected power supply to described terminal, described method also includes:
Judge whether the acceleration that described terminal is current in preset time period keeps steady statue;
The most then perform to cut off the step of the power supply to described terminal.
In an embodiment of the present invention, the described judgement acceleration that described terminal is current in preset time period is The step of no holding steady statue, specifically includes:
In preset time period, gather, every preset duration, the acceleration that described terminal is current;
Obtain the acceleration difference between the acceleration collected adjacent twice, poor to obtain multiple acceleration Value;
Judge that the acceleration that described terminal is current in preset time period is according to the plurality of acceleration difference No holding steady statue.
In an embodiment of the present invention, described judge in preset time period according to the plurality of acceleration difference Whether the current acceleration of described terminal keeps the step of steady statue, specifically includes:
The plurality of acceleration difference is compared with the second preset difference value, to obtain comparative result;
Judge whether the acceleration that described terminal is current in preset time period keeps according to described comparative result Steady statue.
In an embodiment of the present invention, after obtaining the current acceleration of terminal, obtain described acceleration with Before the acceleration difference between history acceleration before described terminal, described method also includes:
Judge that whether the current acceleration of described terminal is more than or equal to acceleration of gravity;
The most then perform to obtain the acceleration between the history acceleration before described acceleration and described terminal The step of difference.
Correspondingly, embodiments provide a kind of terminal protection device, including: acceleration acquisition module, Difference acquisition module, the first judge module and execution module;Wherein,
Described acceleration acquisition module, for obtaining the acceleration that terminal is current;
Described difference acquisition module, for obtain history acceleration before described acceleration and described terminal it Between acceleration difference;
Described first judge module, is used for judging that whether described acceleration difference is more than the first preset difference value;
Described execution module, for when described first judge module is judged to be, cuts off described terminal Power supply.
In an embodiment of the present invention, described device also includes: the second judge module;
At described first judge module, described second judge module, for judging that described acceleration difference is more than the After one preset difference value, before described execution module cuts off the power supply to described terminal, it is judged that at Preset Time Whether the acceleration that in section, described terminal is current keeps steady statue;
Described execution module, specifically for when described second judge module is judged to be, cuts off described end The power supply of end.
In an embodiment of the present invention, described second judge module, specifically include: gather submodule, acquisition Submodule and judge submodule;Wherein,
Described collection submodule, in preset time period, gathers described terminal every preset duration current Acceleration;
Described acquisition submodule, for obtaining the acceleration difference between the acceleration collected adjacent twice, To obtain multiple acceleration difference;
Described judgement submodule, for judging in preset time period described according to the plurality of acceleration difference Whether the current acceleration of terminal keeps steady statue.
In an embodiment of the present invention, described judgement submodule, specifically for by the plurality of acceleration difference Compare with the second preset difference value, to obtain comparative result;Judge when default according to described comparative result Between described terminal is current in section acceleration whether keep steady statue.
In an embodiment of the present invention, described device also includes: the 3rd judge module;
Described 3rd judge module, for described acceleration acquisition module obtain the current acceleration of terminal it After, adding between the history acceleration before the described difference acquisition module described acceleration of acquisition and described terminal Before speed difference, it is judged that whether the current acceleration of described terminal is more than or equal to acceleration of gravity;
Described difference acquisition module, specifically for when described 3rd judge module is judged to be, obtains described The acceleration difference between history acceleration before acceleration and described terminal.
Embodiments providing a kind of terminal protecting methdo and device, this terminal protecting methdo is by obtaining The acceleration that terminal is current, obtains the acceleration between the history acceleration before this acceleration and this terminal subsequently Degree difference, it is judged that whether this acceleration difference, more than the first preset difference value, if being more than, is then cut off this terminal Power supply;The program can be when needing to cut off the power supply to terminal, and the acceleration change according to this terminal is poor The size of value cuts off power supply, and manually performs power supply rupturing operation without user, in terms of existing technologies, Accelerate power-off speed, can in time terminal be protected.
Accompanying drawing explanation
For the technical scheme being illustrated more clearly that in the embodiment of the present invention, institute in embodiment being described below The accompanying drawing used is needed to be briefly described, it should be apparent that, the accompanying drawing in describing below is only the present invention Some embodiments, for those skilled in the art, on the premise of not paying creative work, also Other accompanying drawing can be obtained according to these accompanying drawings.
Fig. 1 is the schematic flow sheet of the terminal protecting methdo that the embodiment of the present invention one provides;
Fig. 2 is the schematic flow sheet of the terminal protecting methdo that the embodiment of the present invention three provides;
Fig. 3 a is the structural representation of the first terminal protection device that the embodiment of the present invention four provides;
Fig. 3 b is the structural representation of the second terminal protection device that the embodiment of the present invention four provides;
Fig. 3 c is the structural representation of the third terminal protection device that the embodiment of the present invention four provides.
Detailed description of the invention
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clearly Chu, be fully described by, it is clear that described embodiment be only a part of embodiment of the present invention rather than Whole embodiments.Based on the embodiment in the present invention, those skilled in the art are not making creative labor The every other embodiment obtained under dynamic premise, broadly falls into the scope of protection of the invention.
The embodiment of the present invention provides a kind of terminal protecting methdo and device.To be described in detail respectively below.
Embodiment one,
The present embodiment will be described from the angle of terminal protection device, and this terminal protection device specifically can collect Becoming in the terminal, this terminal can be the equipment such as smart mobile phone, panel computer.
A kind of terminal protecting methdo, including: obtain the acceleration that terminal is current, obtain subsequently this acceleration with The acceleration difference between history acceleration before this terminal, and judge that this acceleration difference is whether more than the One preset difference value, if being more than, then cuts off the power supply to this terminal.
As it is shown in figure 1, this terminal protecting methdo, idiographic flow can be such that
101, the acceleration that terminal is current is obtained.
Specifically, can obtain, by current acceleration detection mechanism, the acceleration that terminal is current, such as, Acceleration can be sent to this acceleration detection mechanism obtain when this terminal triggers the instruction obtaining acceleration Request, obtains, according to this acceleration, the acceleration that acquisition request terminal is current.
Wherein, this acceleration detection mechanism can be integrated in terminal with the form of software or hardware, such as, This acceleration detection mechanism can be G-sensor (Gravity-sensor, gravity sensor).
The mode obtaining the current acceleration of terminal in the present embodiment has multiple, such as, and can be fixed based on certain Time system trigger obtain the instruction of the current acceleration of this terminal, after terminal receives this instruction, refer to according to this Make and send acceleration acquisition request to built-in G-sensor, obtain request from this according to this acceleration The data storage areas that G-sensor is corresponding calls related data, the acceleration current to obtain terminal;Also The idiographic flow that i.e. step " obtains the acceleration that terminal is current " can be such that
Timing sends acceleration and obtains request;
The acceleration that acquisition request terminal is current is obtained according to this acceleration.
Wherein, timing can be set according to the actual requirements, such as, can set constant duration For 0.01s, 0.1s etc., it is of course also possible to set not constant duration.In order to terminal electricity can be saved Amount, can be set as bigger value, such as 1s, 2s etc. by this time interval, and this is not made by the present invention Concrete restriction.
102, the acceleration difference between the history acceleration before this acceleration and this terminal is obtained.
Specifically, after obtaining the acceleration that this terminal is current, then can be obtained by acceleration detection machine History acceleration before this terminal, obtains both according to the acceleration that this terminal is current with history acceleration Between acceleration difference;That is, step " obtain the history acceleration before this acceleration and this terminal it Between acceleration difference " idiographic flow can be such that
Obtain the history acceleration before this terminal;
Acceleration according to obtaining obtains corresponding acceleration difference with this history acceleration.
Wherein, the history acceleration before this terminal can be obtain the current acceleration of above-mentioned terminal it Before, the terminal acceleration of acquisition.Such as, the acceleration obtained for the first time is a1, and what second time obtained adds Speed is a2, and the current acceleration obtained is a3, then a1, a2 all can be described as history acceleration;And at this In inventive embodiments, the history acceleration before mentioned terminal is a2, and indication acceleration difference is i.e. For the acceleration difference of a3 Yu a2, △ a, △ a=a3-a2 or △ a=a2-a3 can be designated as.Wherein △ a The symbol (such as sign) involved by final result only represent direction, and do not indicate that its value size.
Such as, a1=3m/s is set2, a2=2m/s2, a3=1m/s2, then △ a=a2-a3=-1m/s2, wherein "-" represent the direction in opposite direction with acceleration a1, a2, a3, and do not indicate that the size of acceleration, Namely △ a=-1m/s2Represent that the current acceleration of terminal reduces 1m/s for history acceleration2
In specific implementation process, history can be sent to this acceleration detection mechanism (such as G-sensor) and add Speed obtains request, obtains request according to this history acceleration and deposits from the data that this acceleration detection mechanism is corresponding Storage area territory is extracted relevant data message, to obtain the history acceleration before terminal, subsequently can be to end End processor sends information process request, and this terminal handler can be transported to terminal according to this information process request Calculate device and issue operational order, by the operation result returned after terminal internalarithmetic, obtain between the two Acceleration difference.
Wherein, this information process request instruction need information to be processed, such as, calculate obtain acceleration with Acceleration difference between history acceleration.
103, judge that whether this acceleration difference is more than the first preset difference value;If so, step 104 is performed, If it is not, perform step 101.
Wherein, this first preset difference value can be set according to the actual requirements, in embodiments of the present invention, This first preset difference value is the calibration standard value of acceleration difference, therefore can be correlated with according to the actual requirements Experiment test to obtain this standard value.
Preferably, in order to avoid being directly to fall on the ground because of terminal, terminal is made to accelerate in the moment landed Directly by gravity acceleration g, (g approximates 9.8m/s to degree2) vanishing, cause excessive this of acceleration difference Plant extreme situation, and cause the erroneous judgement problem of terminal, can be that this acceleration difference sets upper limit threshold; That is, step " judges that whether this acceleration difference is more than the first preset difference value ", idiographic flow can be such that
In the range of judging whether this acceleration difference is in preset difference value;
If so, perform to obtain the step of the current acceleration of terminal;
If it is not, perform step 104.
104, the power supply to this terminal is cut off.
Specifically, after judging that this acceleration difference is more than the first preset difference value, can be to this terminal handler Send power down request, after terminal handler receives this power down request, issue cut-offing instruction, so that terminal Can perform to cut off the operation of the power supply to this terminal according to this cut-offing instruction.
Wherein, the mode to the power supply of this terminal of cutting off has multiple, such as, and can be to this terminal mainboard circuit Operating circuit send this cut-offing instruction, trigger the operating circuit of this motherboard circuit and the confession of above-mentioned motherboard circuit Electricity circuit disconnects, it is also possible to send this cut-offing instruction to the power supply circuits of this motherboard circuit, triggers this power supply electricity Road disconnects with the operating circuit of this motherboard circuit.
Preferably, in order to avoid terminal power-off continually, it is ensured that perform the accuracy rate of power operation, this enforcement In example, can be to perform step " to obtain the acceleration between the history acceleration before this acceleration and this terminal Degree difference " set a precondition, by whether being in this terminal of the multilevel iudge of gravity acceleration g Fall state, confirm that terminal is the need of power-off with preliminary;That is, obtain the current acceleration of terminal it After, before obtaining the acceleration difference between the history acceleration before this acceleration and this terminal, this terminal Guard method can also include:
Judge that whether the current acceleration of this terminal is more than or equal to acceleration of gravity;
The most then perform to obtain the acceleration difference between the history acceleration before this acceleration and this terminal Step.
Specifically, after obtaining the acceleration that terminal is current, can send to terminal handler and judge request, This acceleration and gravity acceleration g can be compared to obtain according to this judgement request by this terminal handler To result of determination, make terminal can perform next step operation according to this result of determination, obtain this acceleration to reduce The probability of the acceleration difference between history acceleration before degree and this terminal, and then it is frequent to avoid terminal Ground power-off, improves terminal and performs the accuracy rate of power operation.
From the foregoing, it will be observed that embodiments provide a kind of terminal protecting methdo, current by obtaining terminal Acceleration, obtains the acceleration difference between the history acceleration before this acceleration and this terminal subsequently, sentences This acceleration difference disconnected, whether more than the first preset difference value, if being more than, then cuts off the power supply to this terminal;Should Scheme can be cut according to the size of the acceleration change difference of this terminal when needing to cut off the power supply to terminal Cut-off electricity, and manually perform power supply rupturing operation without user, in terms of existing technologies, accelerate to resolve Electricity speed, can protect terminal in time.
Embodiment two,
Terminal protecting methdo of the present invention will be described further on the basis of embodiment one by the present embodiment. From embodiment one, the method can be when needing to cut off the power supply to terminal, according to the acceleration of this terminal The size of degree change difference determines whether to cut off power supply.But, the method is according only to an acceleration difference Defecation can perform power operation, and power-off probability is excessive, it is understood that there may be the problem of erroneous judgement.
In order to overcome the problem of above-mentioned erroneous judgement, the present embodiment in said method according to acceleration difference to this The power supply of terminal is further limited;That is, judge this acceleration difference more than the first preset difference value it After, before cutting off the power supply of this terminal, the method can also include:
Judge whether the acceleration that this terminal is current in preset time period keeps steady statue;
The most then perform to cut off the step of the power supply to this terminal.
Specifically, can determine terminal be in fall state after and acceleration change generation acceleration poor During value, initiate monitoring request to terminal, trigger according to this monitoring request and open acceleration monitoring pattern, make end The acceleration that it is current can be monitored in preset time period by end, to determine whether its acceleration keeps Steady statue, after determining that this acceleration is in steady statue, issues cut-offing instruction, to perform to cut off this The operation of the power supply of terminal.
In actual applications, in this terminal, timing means can be installed, according to the actual requirements, by this timing Device sets preset time period;Such as, the time can be set as 2s, in this preset time period, to Acceleration detection mechanism sends acceleration and obtains request, obtains request from corresponding storage further according to this acceleration Region is extracted relevant acceleration information, so that the acceleration that this terminal is current to be monitored.
Preferably, in order to save terminal operating resource and electricity, reduce the number of times judged, more intuitively embody The change of acceleration, in embodiments of the present invention, can be by within a predetermined period of time, timing or random Obtain the difference between adjacent acceleration, to judge whether the current acceleration of terminal keeps steady statue;Also I.e. step " judges whether the acceleration that this terminal is current in preset time period keeps steady statue " and specifically may be used To include:
In preset time period, gather, every preset duration, the acceleration that this terminal is current;
Obtain the acceleration difference between the acceleration collected adjacent twice, poor to obtain multiple acceleration Value;
Judge whether the acceleration that this terminal is current in preset time period is protected according to the plurality of acceleration difference Hold steady statue.
Specifically, timing can send acceleration collection request to this terminal, such as, this preset duration is permissible It is set as 0.1s, 0.01s etc., can be set according to the actual requirements, subsequently can be by this terminal Acceleration detection mechanism (such as G-sensor) gather corresponding acceleration, after terminal handler processes Acceleration difference between the acceleration collected for adjacent twice, judges acceleration according to this acceleration difference Change.
Alternatively, obtaining after multiple acceleration differences, specifically can:
The plurality of acceleration difference is compared with the second preset difference value, to obtain comparative result;
Judge whether the acceleration that this terminal is current in preset time period keeps stable according to this comparative result State.
In specific implementation process, predetermined amount of time can be set to 2s, this preset duration is set to 0.02s, then will get 100 acceleration differences in preset time period, by these 100 acceleration Difference compares with the second preset difference value (can be arranged by this second preset difference value is sufficiently small), it is judged that Whether less than this second preset difference value, obtain comparative result;During in order to avoid occur absolute error and Relative error, can set when the acceleration exceeding some (such as 95) in this comparative result When difference is less than the second preset difference value, it is determined that whether the acceleration that this terminal is current in preset time period keeps Steady statue.
From the foregoing, it will be observed that embodiments provide a kind of terminal protecting methdo, at above-mentioned terminal protecting methdo On the basis of, by after determining that acceleration difference is more than the first preset difference value, it is judged that in preset time period In the current acceleration of this terminal whether keep steady statue, if keeping steady statue, then perform to cut off this The operation of the power supply of terminal;Whether the program can keep steady by the state judging terminal current acceleration Fixed, to further determine that whether terminal performs power operation, rather than according only to the size of an acceleration difference Just perform power operation, thus improve the accuracy rate of judgement, reduce the probability of terminal power-off carelessly.
Embodiment three,
According to the method described by embodiment one and two, below citing is described in further detail.
In the present embodiment, specifically will be integrated in smart mobile phone with this terminal protection device, this smart mobile phone In G-sensor is installed, this smart mobile phone is described in detail as a example by falling in the air depth water.
As in figure 2 it is shown, a kind of terminal protecting methdo, idiographic flow can be such that
201, its current acceleration of smart mobile phone timing acquisition, and judge that whether this acceleration is less than gravity Acceleration;If it is not, perform step 202, the most then continue executing with its current acceleration of acquisition and judge Whether less than acceleration of gravity.
Specifically, smart mobile phone can be obtained by the current i.e. G-sensor of acceleration detection mechanism current Acceleration, such as, can be when this smart mobile phone triggers the instruction obtaining acceleration, to this G-sensor Send acceleration and obtain request, obtain request at data storage areas corresponding for G-sensor according to this acceleration The acceleration that middle acquisition is current, can send to this smart mobile phone central processing unit subsequently and judge request, according to This judgement request is by this acceleration and gravity acceleration g (i.e. 9.8m/s2) compare to obtain result of determination, Indirectly, can determine whether this smart mobile phone is in by this result of determination and fall state.
It should be noted that this smart mobile phone falls when, owing to air drag is minimum, therefore at this Inventive embodiments is negligible.
202, smart mobile phone obtains the acceleration difference between this acceleration and history acceleration before.
Specifically, history acceleration can be sent to the G-sensor in this smart mobile phone and obtain request, according to This history acceleration obtains request and extracts relevant from the data storage areas that this acceleration detection mechanism is corresponding Data message, to obtain history acceleration, subsequently can to central processing unit send information process request, This central processing unit can issue operational order according to this information process request to arithmetical unit, is transported by arithmetical unit The operation result returned after calculation, obtains acceleration difference between the two.
Such as, before overboard in a flash, acceleration is 9.8m/s to this smart mobile phone2, overboard rear one Moment, acceleration is 9.6m/s2;Assume initial acceleration direction for just, then it is contemplated that this acceleration Degree change occurs once reverse, and acceleration reduces 0.2m/s2
203, in the range of smart mobile phone judges whether this acceleration difference is in preset difference value;If so, perform Step 203, if it is not, perform step 201.
Wherein, this preset range can be set according to the actual requirements, and in embodiments of the present invention, this is years old Preset range be this smart mobile phone in overboard moment, the calibration standard value of acceleration difference, therefore can root The test carrying out being correlated with according to actual demand, to obtain this standard value, can be made up of with lower limit a higher limit Interval expression, such as [0.1m/s2,0.4m/s2]。
204, smart mobile phone judges whether the acceleration that it is current in preset time period keeps steady statue; If so, step 205 is performed, if it is not, perform step 201.
Specifically, can determine this smart mobile phone be in fall state after and the acceleration generation that changes add During speed difference, initiate monitoring request, trigger according to this monitoring request and open acceleration monitoring pattern, make this The acceleration that it is current can be monitored in preset time period by smart mobile phone, to determine that its acceleration is No holding steady statue.
In actual applications, at this smart mobile phone, timing means can be installed, according to the actual requirements, by this Timing means sets preset time period;Such as, the time can be set as 2s, in this preset time period, Send acceleration to G-sensor and obtain request, obtain request from corresponding memory area further according to this acceleration The acceleration information that middle extraction is relevant, to be monitored the acceleration that this smart mobile phone is current.
Preferably, run resource and electricity to save this smart mobile phone, reduce the number of times judged, more intuitively Ground embodies the change of acceleration, in embodiments of the present invention, can by within a predetermined period of time, timing or Person obtains the difference between adjacent acceleration at random, according to the change of this difference, it is judged that the acceleration that terminal is current Whether degree keeps steady statue.
In specific implementation process, owing to smart mobile phone is in overboard moment, can be owing to by buoyancy, accelerating Spend and reduce, then can be by the detection to G-sensor state, it is judged that whether the change of its acceleration is passed through The once rear acceleration keeping a steady statue.
Such as, before overboard in a flash, acceleration is 9.8m/s to this smart mobile phone2, overboard rear one Moment, acceleration is 9.6m/s2;Assume that initial acceleration direction, for just, meets overboard preset range and sets It is set to [0.1m/s2,0.4m/s2], then it is contemplated that this acceleration change occurs once reverse, acceleration Reduce 0.2m/s2, and in preset range, now can open acceleration monitoring pattern, to acceleration Change be monitored, the acceleration as monitored is 9.6m/s2、9.5m/s2、9.4m/s2、9.5m/s2、 9.4m/s2、9.4m/s2、9.4m/s2、9.4m/s2Etc. a series of relatively stable numerical value, then can be determined that this Terminal current acceleration keeps stable.
205, smart mobile phone performs power operation.
In actual applications, this smart mobile phone performs the mode of power operation to be had multiple, such as, and can be to this The operating circuit of smart mobile phone motherboard circuit sends this cut-offing instruction, trigger the operating circuit of this motherboard circuit with The power supply circuits of above-mentioned motherboard circuit disconnect, it is also possible to send this power-off to the power supply circuits of this motherboard circuit and refer to Order, triggers the operating circuit disconnection of these power supply circuits and this motherboard circuit.
From the foregoing, it will be observed that embodiments provide a kind of terminal protecting methdo, by obtaining its current adding Speed, and judge whether this acceleration is less than acceleration of gravity, if it is not, then obtain this acceleration and this intelligence Acceleration difference between the history acceleration of mobile phone, and judge whether this acceleration difference is in preset difference value In the range of, if in preset range, then judge whether the acceleration that it is current in preset time period keeps steady Determining state, if keeping steady statue, then performing power operation;The program can be fallen at this smart mobile phone deeply When water needs to cut off the power supply to it, cut off according to the size of its acceleration change difference and power, and without User manually performs power supply rupturing operation, in terms of existing technologies, accelerates power-off speed, can and Time ground this smart mobile phone is protected.
Embodiment four,
In order to preferably implement above method, the embodiment of the present invention also provides for a kind of terminal protection device, and this is eventually End protection device can integrated in the terminal, this terminal specifically can include mobile phone, panel computer or notebook Apparatus such as computer.As shown in Figure 3 a, this terminal protection device can include acceleration acquisition module 301, Difference acquisition module the 302, first judge module 303 and execution module 304;Wherein,
This acceleration acquisition module 301, for obtaining the acceleration that terminal is current;
This difference acquisition module 302, for obtaining between the history acceleration before this acceleration and this terminal Acceleration difference;
This first judge module 303, is used for judging that whether this acceleration difference is more than the first preset difference value
This execution module 304, for when this first judge module 303 is judged to be, cuts off this terminal Power supply.
Preferably, referring to Fig. 3 b, this terminal protection device can also include: second judges submodule 305;
At this first judge module 303, this second judge module 305, for judging that this acceleration difference is more than After first preset difference value, before this execution module 304 cuts off the power supply to this terminal, it is judged that when default Between this terminal is current in section acceleration whether keep steady statue;
This execution module 304, specifically for when this second judge module 305 is judged to be, cuts off this The power supply of terminal.
Preferably, this second judge module 305, specifically may include that collection submodule, obtain submodule With judge submodule;Wherein,
This collection submodule, in preset time period, gathers current the adding of this terminal every preset duration Speed;
This acquisition submodule, for obtaining the acceleration difference between the acceleration collected adjacent twice, with Obtain multiple acceleration difference;
According to the plurality of acceleration difference, this judgement submodule, for judging that this terminal is worked as in preset time period Whether front acceleration keeps steady statue.
Wherein, this judgement submodule, specifically may be used for the plurality of acceleration difference and the second preset difference value Compare, to obtain comparative result;Judge that this terminal is current in preset time period according to this comparative result Acceleration whether keep steady statue.
Preferably, referring to Fig. 3 c, this device can also include: the 3rd judge module 306;
3rd judge module 306, for obtaining, at this acceleration acquisition module 301, the acceleration that terminal is current After degree, this difference acquisition module 302 obtains between the history acceleration before this acceleration and this terminal Before acceleration difference, it is judged that whether the current acceleration of this terminal is more than or equal to acceleration of gravity;
This difference acquisition module 302, specifically for when the 3rd judge module 306 is judged to be, obtaining should The acceleration difference between history acceleration before acceleration and this terminal.
From the foregoing, it will be observed that embodiments provide a kind of terminal protection device, by acceleration acquisition module 301 obtain the acceleration that terminal is current, before difference acquisition module 302 obtains this acceleration and this terminal Acceleration difference between history acceleration, the first judge module 303 judges whether this acceleration difference is more than First preset difference value, execution module 304, when the first judge module 303 is judged to be, is cut off this terminal Power supply;The program can be when needing to cut off the power supply to terminal, and the acceleration change according to this terminal is poor The size of value cuts off power supply, and manually performs power supply rupturing operation without user, in terms of existing technologies, Accelerate power-off speed, can in time terminal be protected.
One of ordinary skill in the art will appreciate that all or part of step in the various methods of above-described embodiment Suddenly the program that can be by completes to instruct relevant hardware, and this program can be stored in a computer-readable In storage medium, storage medium may include that read only memory (ROM, Read Only Memory), Random access memory (RAM, RandomAccess Memory), disk or CD etc..
A kind of terminal protecting methdo provided the embodiment of the present invention above and device are described in detail, Principle and the embodiment of the present invention are set forth by program used herein specific case, above enforcement The explanation of example is only intended to help to understand method and the core concept thereof of the present invention;Simultaneously for this area Technical staff, according to the thought of the present invention, all can change in detailed description of the invention and range of applications Part, in sum, this specification content should not be construed as limitation of the present invention.

Claims (10)

1. a terminal protecting methdo, it is characterised in that including:
Obtain the acceleration that terminal is current;
Obtain the acceleration difference between the history acceleration before described acceleration and described terminal;
Judge that whether described acceleration difference is more than the first preset difference value;
The most then cut off the power supply to described terminal.
2. terminal protecting methdo as claimed in claim 1, it is characterised in that judging described acceleration Difference is more than after the first preset difference value, and before cutting off the power supply to described terminal, described method also includes:
Judge whether the acceleration that described terminal is current in preset time period keeps steady statue;
The most then perform to cut off the step of the power supply to described terminal.
3. terminal protecting methdo as claimed in claim 2, it is characterised in that described judgement is when default Between described terminal is current in section acceleration whether keep the step of steady statue, specifically include:
In preset time period, gather, every preset duration, the acceleration that described terminal is current;
Obtain the acceleration difference between the acceleration collected adjacent twice, poor to obtain multiple acceleration Value;
Judge that the acceleration that described terminal is current in preset time period is according to the plurality of acceleration difference No holding steady statue.
4. terminal protecting methdo as claimed in claim 3, it is characterised in that described according to the plurality of Acceleration difference judges whether the acceleration that described terminal is current in preset time period keeps steady statue Step, specifically includes:
The plurality of acceleration difference is compared with the second preset difference value, to obtain comparative result;
Judge whether the acceleration that described terminal is current in preset time period keeps according to described comparative result Steady statue.
5. terminal protecting methdo as claimed in claim 1, it is characterised in that terminal is current obtaining After acceleration, obtain the acceleration difference between the history acceleration before described acceleration and described terminal Before, described method also includes:
Judge that whether the current acceleration of described terminal is more than or equal to acceleration of gravity;
The most then perform to obtain the acceleration between the history acceleration before described acceleration and described terminal The step of difference.
6. a terminal protection device, it is characterised in that including: acceleration acquisition module, difference obtain Module, the first judge module and execution module;Wherein,
Described acceleration acquisition module, for obtaining the acceleration that terminal is current;
Described difference acquisition module, for obtain history acceleration before described acceleration and described terminal it Between acceleration difference;
Described first judge module, is used for judging that whether described acceleration difference is more than the first preset difference value;
Described execution module, for when described first judge module is judged to be, cuts off described terminal Power supply.
7. terminal protection device as claimed in claim 6, it is characterised in that described device also includes: the Two judge modules;
At described first judge module, described second judge module, for judging that described acceleration difference is more than the After one preset difference value, before described execution module cuts off the power supply to described terminal, it is judged that at Preset Time Whether the acceleration that in section, described terminal is current keeps steady statue;
Described execution module, specifically for when described second judge module is judged to be, cuts off described end The power supply of end.
8. terminal protection device as claimed in claim 7, it is characterised in that described second judge module, Specifically include: gather submodule, obtain submodule and judge submodule;Wherein,
Described collection submodule, in preset time period, gathers described terminal every preset duration current Acceleration;
Described acquisition submodule, for obtaining the acceleration difference between the acceleration collected adjacent twice, To obtain multiple acceleration difference;
Described judgement submodule, for judging in preset time period described according to the plurality of acceleration difference Whether the current acceleration of terminal keeps steady statue.
9. terminal protection device as claimed in claim 8, it is characterised in that described judgement submodule, Specifically for the plurality of acceleration difference is compared with the second preset difference value, to obtain comparative result; Judge whether the acceleration that described terminal is current in preset time period keeps stable according to described comparative result State.
10. terminal protection device as claimed in claim 6, it is characterised in that described device also includes: 3rd judge module;
Described 3rd judge module, for described acceleration acquisition module obtain the current acceleration of terminal it After, adding between the history acceleration before the described difference acquisition module described acceleration of acquisition and described terminal Before speed difference, it is judged that whether the current acceleration of described terminal is more than or equal to acceleration of gravity;
Described difference acquisition module, specifically for when described 3rd judge module is judged to be, obtains described The acceleration difference between history acceleration before acceleration and described terminal.
CN201610158742.6A 2016-03-18 2016-03-18 Terminal protection method and device Pending CN105844179A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610158742.6A CN105844179A (en) 2016-03-18 2016-03-18 Terminal protection method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610158742.6A CN105844179A (en) 2016-03-18 2016-03-18 Terminal protection method and device

Publications (1)

Publication Number Publication Date
CN105844179A true CN105844179A (en) 2016-08-10

Family

ID=56588332

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610158742.6A Pending CN105844179A (en) 2016-03-18 2016-03-18 Terminal protection method and device

Country Status (1)

Country Link
CN (1) CN105844179A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106993173A (en) * 2017-04-07 2017-07-28 青岛海信宽带多媒体技术有限公司 A kind of micro- correction triggering method and micro- throwing equipment for throwing equipment
CN109495053A (en) * 2018-09-29 2019-03-19 维沃移动通信有限公司 A kind of method and terminal device of drive motor vibration
WO2019085732A1 (en) * 2017-10-31 2019-05-09 深圳市万普拉斯科技有限公司 Over-voltage protection control method and apparatus, mobile terminal and readable storage medium
CN116558623A (en) * 2023-07-05 2023-08-08 天津宜科自动化股份有限公司 System for measuring vibration degree based on capacitance

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060156039A1 (en) * 2002-09-19 2006-07-13 Stmicroelectronics S.A. Power supply for an asynchronous data treatment circuit
CN102279285A (en) * 2011-03-11 2011-12-14 华为终端有限公司 Terminal, method and apparatus for detecting drop information thereof
CN103207955A (en) * 2012-01-11 2013-07-17 联想(北京)有限公司 Method and system for protecting electronic terminal and electronic terminal
CN103561171A (en) * 2013-10-31 2014-02-05 惠州Tcl移动通信有限公司 Protection processing method and system for mobile phone to fall into water
CN104427092A (en) * 2013-08-22 2015-03-18 中兴通讯股份有限公司 Automatic shutdown method and device for mobile terminal and mobile terminal

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060156039A1 (en) * 2002-09-19 2006-07-13 Stmicroelectronics S.A. Power supply for an asynchronous data treatment circuit
CN102279285A (en) * 2011-03-11 2011-12-14 华为终端有限公司 Terminal, method and apparatus for detecting drop information thereof
CN103207955A (en) * 2012-01-11 2013-07-17 联想(北京)有限公司 Method and system for protecting electronic terminal and electronic terminal
CN104427092A (en) * 2013-08-22 2015-03-18 中兴通讯股份有限公司 Automatic shutdown method and device for mobile terminal and mobile terminal
CN103561171A (en) * 2013-10-31 2014-02-05 惠州Tcl移动通信有限公司 Protection processing method and system for mobile phone to fall into water

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106993173A (en) * 2017-04-07 2017-07-28 青岛海信宽带多媒体技术有限公司 A kind of micro- correction triggering method and micro- throwing equipment for throwing equipment
WO2019085732A1 (en) * 2017-10-31 2019-05-09 深圳市万普拉斯科技有限公司 Over-voltage protection control method and apparatus, mobile terminal and readable storage medium
CN109495053A (en) * 2018-09-29 2019-03-19 维沃移动通信有限公司 A kind of method and terminal device of drive motor vibration
CN116558623A (en) * 2023-07-05 2023-08-08 天津宜科自动化股份有限公司 System for measuring vibration degree based on capacitance
CN116558623B (en) * 2023-07-05 2024-04-26 天津宜科自动化股份有限公司 System for measuring vibration degree based on capacitance

Similar Documents

Publication Publication Date Title
CN105844179A (en) Terminal protection method and device
CN105825153B (en) A kind of mobile terminal guard method and device
TW201535266A (en) Resource adjustment methods and systems for virtual machines
CN106445783A (en) Method and device for detecting jamming of electronic equipment and electronic equipment
CN106412247A (en) Drop protection method and apparatus
CN107247647B (en) BBU working state detection method and system in memory system
CN104809400A (en) Process protection method and device
CN103927230A (en) Memory usage feedback method and device
CN105843726B (en) A kind of terminal protecting methdo and device
CN104580721A (en) Alarm clock implementation method for terminal
CN106201843A (en) The processing method of a kind of terminal data, device and terminal
WO2016183918A1 (en) Method and device for processing storage space
CN106021007A (en) Method for detecting fault of terminal and terminal
CN115095544A (en) Fan fault detection method and device, computer equipment and storage medium
CN102915264A (en) Data protection method and device
CN102929770B (en) The monitoring and positioning method that Embedded Linux System User space task is exclusive
CN106055406A (en) Program operation method and terminal
CN105554104B (en) According to GPS satellite number bolt down procedure running background method and device
CN103837835A (en) Method and device for detecting capacity decreasing degree of mobile device battery
CN108897667A (en) A kind of memory temperature alarm method, device and equipment
CN105204954A (en) Method and terminal for processing dead halt state
CN108899595B (en) Temperature detection method, device and equipment for battery
CN105656156A (en) Power-off handling method and device
CN113886196B (en) On-chip power consumption management method, electronic device and storage medium
CN102810840B (en) Voltage protection system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20160810