Charging monitoring method, abnormality determination method, device, electronic device and server
By monitoring the charging time and battery capacity increment of electronic devices in different scenarios, calculating the average charging speed and comparing it with the set threshold, the problem of charging abnormality is solved, and charging efficiency and user experience are improved.
Patent Information
- Application Number
- CN202210840764.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-18
- Publication Date
- 2024-12-17
- Estimated Expiration
- 2042-07-18
AI Technical Summary
During the charging process of electronic devices, how to effectively determine whether the charging is abnormal, especially the changes in charging speed in different scenarios.
By monitoring the continuous charging time and battery capacity increment of the electronic device in different scenarios, the average charging speed is calculated and compared with the set speed threshold to determine whether the charging is abnormal.
It realizes monitoring of the average charging speed during the charging process of electronic devices, and can promptly judge and prompt charging abnormalities, improving the charging efficiency and user experience of electronic devices.
Smart Images

Figure CN115001111B_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of charging technology, and in particular relates to a charging monitoring method, an abnormality determination method, a device, an electronic device and a server. Background Art
[0002] With the development of communication technology, electronic devices such as mobile phones and tablet computers have become indispensable tools in daily life. As the frequency of use of electronic devices increases, electronic devices need to be charged frequently to meet the needs of users. However, charging abnormalities may occur during the charging process, so how to judge charging abnormalities is a technical problem that needs to be solved urgently. Summary of the invention
[0003] Embodiments of the present application provide a charging monitoring method, an abnormality determination method, an apparatus, an electronic device, and a server. By monitoring the average charging speed of the electronic device in a given scenario, it is possible to determine whether the electronic device is charging abnormally based on the average charging speed.
[0004] In a first aspect, an embodiment of the present application provides a charging monitoring method, comprising:
[0005] During the charging process of the electronic device, obtaining the continuous charging time of the electronic device in a target scenario and the battery capacity increment during the continuous charging time, wherein the target scenario is the scenario in which the electronic device is located during the charging process;
[0006] Calculate a first average charging speed based on the continuous charging time and the battery capacity increment, where the first average charging speed is an average charging speed of the electronic device in the target scenario;
[0007] Based on the first average charging speed, it is determined whether the electronic device is charging abnormally.
[0008] In an embodiment of the present application, during the charging process of an electronic device, the continuous charging time in the scenario in which the electronic device is located (i.e., the target scenario) and the battery capacity increment during the continuous charging time can be obtained. Based on the continuous charging time and the battery capacity increment, the average charging speed of the electronic device in the target scenario can be calculated, thereby enabling monitoring of the average charging speed during the charging process, and determining whether the electronic device is charging abnormally based on the average charging speed.
[0009] In a second aspect, an embodiment of the present application provides an abnormality determination method, including:
[0010] Receiving a first average charging speed of the electronic device, where the first average charging speed is an average charging speed of the electronic device in the target scenario, where the target scenario is a scenario in which the electronic device is located during the charging process;
[0011] If the first average charging speed is less than a first speed threshold corresponding to the target scenario, it is determined that the electronic device is charging abnormally.
[0012] In an embodiment of the present application, after receiving the average charging speed of the electronic device in the target scenario, the average charging speed is compared with a first speed threshold. If the average charging speed is less than the first speed threshold, it means that the average charging speed is too low to meet the charging demand of the electronic device, thereby determining that the electronic device is charging abnormally, thereby realizing the judgment of the charging abnormality of the electronic device.
[0013] In a third aspect, an embodiment of the present application provides a charging monitoring device, including:
[0014] A data acquisition module, used to acquire, during the charging process of the electronic device, the continuous charging time of the electronic device in a target scenario and the battery capacity increment during the continuous charging time, wherein the target scenario is the scenario in which the electronic device is located during the charging process;
[0015] A speed calculation module, configured to calculate a first average charging speed based on the continuous charging time and the battery capacity increment, wherein the first average charging speed is an average charging speed of the electronic device in the target scenario;
[0016] The first determination module is used to determine whether the electronic device is charging abnormally based on the first average charging speed.
[0017] In a fourth aspect, an embodiment of the present application provides an abnormality determination device, including:
[0018] A speed receiving module, configured to receive a first average charging speed of the electronic device, wherein the first average charging speed is an average charging speed of the electronic device in the target scenario, and the target scenario is a scenario in which the electronic device is located during the charging process;
[0019] The second determination module is configured to determine that charging of the electronic device is abnormal if the first average charging speed is less than a first speed threshold corresponding to the target scenario.
[0020] In a fifth aspect, an embodiment of the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the charging monitoring method described in the first aspect above are implemented.
[0021] In a sixth aspect, an embodiment of the present application provides a server, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the abnormality determination method described in the first aspect above are implemented.
[0022] In the seventh aspect, an embodiment of the present application provides a chip, including a processor, which is used to read and execute a computer program stored in a memory to perform the steps of the charging monitoring method described in the first aspect above, or to perform the steps of the abnormality determination method described in the second aspect above.
[0023] Optionally, the memory is connected to the processor via a circuit or wire.
[0024] In an eighth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, it implements the steps of the charging monitoring method as described in the first aspect above, or implements the steps of the abnormality determination method as described in the second aspect above.
[0025] In the ninth aspect, an embodiment of the present application provides a computer program product. When the computer program product is run on an electronic device, the electronic device executes the steps of the charging monitoring method described in the first aspect above, or implements the steps of the abnormality determination method described in the second aspect above.
[0026] It can be understood that the third aspect, fourth aspect, fifth aspect, sixth aspect, seventh aspect, eighth aspect and ninth aspect provided above are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0028] Figure 1 is a schematic diagram of the network architecture of a charging monitoring system provided by an embodiment of the present application;
[0029] Figure 2 It is a schematic diagram of the implementation flow of the charging monitoring method provided in one embodiment of the present application;
[0030] Figure 3This is an example diagram of the charging monitoring process;
[0031] Figure 4 is another example diagram of the charging monitoring process;
[0032] Figure 5 It is a schematic diagram of the implementation flow of the abnormality determination method provided in one embodiment of the present application;
[0033] Figure 6 is a structural schematic diagram of a charging monitoring device provided in an embodiment of the present application;
[0034] Figure 7 is a schematic diagram of the structure of an abnormality determination device provided in an embodiment of the present application;
[0035] Figure 8 is a structural schematic diagram of an electronic device provided by an embodiment of the present application;
[0036] Fig. 9 It is a schematic diagram of the structure of a server provided in one embodiment of the present application. DETAILED DESCRIPTION
[0037] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0038] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.
[0039] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0040] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0041] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0042] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0043] It should be understood that the size of the serial numbers of the steps in this embodiment does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application.
[0044] In order to illustrate the technical solution described in this application, a specific embodiment is provided below for illustration.
[0045] See also Figure 1 , is a schematic diagram of the network architecture of a charging monitoring system provided in an embodiment of the present application. For ease of explanation, only the parts related to this embodiment are shown.
[0046] like Figure 1 As shown, the charging monitoring system includes an electronic device 1 and a server 2 .
[0047] The electronic device 1 and the server 2 may establish a communication connection via a wired or wireless method, which is not limited here. After the electronic device 1 and the server 2 establish a communication connection, data can be exchanged to determine the charging abnormality of the electronic device.
[0048] The electronic device 1 may be a mobile phone, a tablet computer or other device. The embodiment of the present application does not impose any limitation on the specific type of the electronic device.
[0049] The server 2 may be a server related to the electronic device, such as a server of an electronic device manufacturer.
[0050] It is understandable that the server 1 can be a single server or a server group consisting of multiple servers.
[0051] Understandably, Figure 1The number of electronic devices 1 and servers 2 in the embodiment is only exemplary. Any number can be selected and arranged according to actual needs.
[0052] The electronic device 1 is used to execute the charging monitoring method in the present application. The electronic device 1 can monitor the average charging speed during the charging process, and send the average charging speed to the server 2, providing the server 2 with the average charging speed for determining whether the electronic device is abnormally charged. The server 2 is used to execute the abnormality determination method in the present application. The average charging speed provided by the electronic device can be used to determine whether the electronic device is abnormally charged, and a prompt is issued when the charging is abnormal, which can facilitate electronic device manufacturers to promptly understand the abnormal situation of the electronic device during the charging process, so as to handle the abnormal situation and improve the charging speed of the electronic device.
[0053] Optionally, the electronic device 1 may also judge charging abnormality based on its own average charging speed during the charging process.
[0054] See also Figure 2 , is a schematic diagram of the implementation flow of a charging monitoring method provided by an embodiment of the present application, and the charging monitoring method is applied to an electronic device. Figure 2 As shown, the charging monitoring method may include the following steps:
[0055] Step 201 : during the charging process of the electronic device, obtaining the continuous charging time of the electronic device in a target scenario and the battery capacity increment during the continuous charging time.
[0056] Among them, the target scene is the scene in which the electronic device is in the charging process, such as the screen-on scene, the screen-off scene, etc.
[0057] If the screen of the electronic device is lit, it is determined that the electronic device is in the screen-on scene. For example, a user picks up the electronic device and manually presses the power button to light up the screen of the mobile phone, or a user plays a video or displays a game screen through the electronic device. In these cases, the electronic device is in the screen-on scene.
[0058] If the screen of the electronic device is not lit, it can be determined that the electronic device is in the screen-off scene. For example, the user manually presses the power button to turn off the screen. In this case, the electronic device is in the screen-off scene.
[0059] It is understandable that there may or may not be scene switching in the electronic device during the charging process. The above scene switching is the switching of different scenes. When there is a scene switching, the target scene includes the scene before switching and the scene after switching. For example, during the charging process, the electronic device switches from the screen-on scene to the screen-off scene, then the scene before switching is the screen-on scene, and the scene after switching is the screen-off scene. When there is no scene switching, the number of target scenes is 1. For example, during the charging process, the electronic device is always in the screen-off scene, then the target scene is the screen-off scene.
[0060] In an optional embodiment, the obtaining of the continuous charging time of the electronic device in the target scenario and the battery capacity increment during the continuous charging time includes:
[0061] When the electronic device stops charging or the battery capacity stops updating in the target scenario, obtaining the continuous charging time of the electronic device in the target scenario and the battery capacity increment during the continuous charging time;
[0062] Alternatively, when a scene switch occurs in the electronic device, the continuous charging time of the electronic device in the scene before the switch and the battery capacity increment during the continuous charging time are obtained, and the scene before the switch and the scene after the switch are both target scenes.
[0063] The above-mentioned electronic device stops charging in the target scenario, including but not limited to being fully charged, the electronic device being disconnected from the charging device, etc.
[0064] When charging an electronic device, there may be multiple charging modes, such as fast charging mode, normal charging mode, etc. The charging speed of the fast charging mode is greater than the charging speed of the normal charging mode. The above-mentioned full charge report includes but is not limited to fast charging full charge report, normal charging full charge report, etc. For example, when the above-mentioned full charge report is fast charging full charge report, based on this application, the average charging speed of the electronic device in different scenarios of the fast charging stage can be counted.
[0065] The charging device is a power supply conversion device for the electronic device, such as a power adapter. The electronic device and the charging device can establish a communication connection via wired or wireless means, which is not limited here.
[0066] The electronic device being disconnected from the charging device indicates that the electronic device is switched from a charging state to a non-charging state.
[0067] The battery capacity stops updating, including but not limited to the electronic device may still be charging, but the battery capacity is no longer updated. When judging whether the battery capacity stops updating, the battery capacity can be obtained at intervals of a preset time (for example, 5 seconds). If the battery capacity of two adjacent times is the same or the difference is small (for example, the difference between the battery capacity of two adjacent times is less than the set value, which can be set according to actual needs and is not limited here), it can be determined that the battery capacity stops updating. Since the percentage of power displayed on the electronic device also stops updating or updates slowly when the battery capacity stops updating, it is also possible to judge whether the battery capacity stops updating by the percentage of power of the electronic device. For example, when a mobile phone is charged by fast charging, the battery capacity is no longer updated when it is charged to about 98% (i.e., the percentage of power). This application can be used to count the average charging speed of electronic devices in different scenarios during the capacity update stage. The capacity update stage refers to the stage in which the battery capacity has been updated, that is, the stage before the battery capacity stops updating.
[0068] When the electronic device stops charging or the battery capacity stops updating in the target scenario, the time when charging stops or the time when the battery capacity stops updating can be obtained, and the battery capacity when charging stops or the capacity when the battery capacity stops updating can be obtained. The time when charging stops or the time when the battery capacity stops updating is the time when the electronic device ends charging in the target scenario, and the battery capacity when charging stops or the capacity when the battery capacity stops updating is the end charging capacity of the electronic device in the target scenario; the difference between the end charging time and the start charging time of the electronic device in the target scenario can be calculated to obtain the continuous charging time of the electronic device in the target scenario; the difference between the end charging capacity and the start charging capacity of the electronic device in the target scenario can be calculated to obtain the battery capacity increment of the electronic device in the target scenario. Among them, the start charging time of the electronic device in the target scenario is the time when the electronic device starts charging in the target scenario, and the time can be recorded when the electronic device starts charging in the target scenario. The start charging capacity of the electronic device in the target scenario is the battery capacity of the electronic device when it starts charging in the target scenario, and the battery capacity can be recorded when the electronic device starts charging in the target scenario.
[0069] When an electronic device switches scenes, the time and battery capacity when the scene switching occurs can be obtained. The time when the scene switching occurs is the end charging time of the electronic device in the scene before the switching, and the battery capacity when the scene switching occurs is the end charging capacity of the electronic device in the scene before the switching; the difference between the end charging time and the start charging time of the electronic device in the scene before the switching can be calculated to obtain the continuous charging time of the electronic device in the scene before the switching; the difference between the end charging capacity and the start charging capacity of the electronic device in the scene before the switching can be calculated to obtain the battery capacity increment of the electronic device in the scene before the switching.
[0070] It is understandable that the time when the scene switching occurs is also the start charging time of the electronic device in the scene after the switching, and the battery capacity when the scene switching occurs is also the start charging capacity of the electronic device in the scene after the switching. If the electronic device switches scenes, stops charging, or stops updating the battery capacity in the scene after the switching, the continuous charging time and battery capacity increment of the electronic device in the scene after the switching can be obtained.
[0071] For example, when charging the mobile phone, the mobile phone is in the screen-on scene. During the charging process, if the mobile phone switches from the screen-on scene to the screen-off scene, the continuous charging time of the mobile phone in the screen-on scene and the battery capacity increment during the continuous charging time can be obtained, and the start charging time and the start charging capacity of the mobile phone in the screen-off scene can be recorded, and the mobile phone can continue to be monitored. Two situations may occur during the monitoring process. In the first case, if the mobile phone is monitored to switch from the screen-off scene to the screen-on scene, the end charging time and the end charging capacity of the mobile phone in the screen-off scene can be recorded, and the continuous charging time of the mobile phone in the screen-off scene and the battery capacity increment during the continuous charging time can be calculated. In this case, the end charging time of the mobile phone in the screen-off scene is also the start charging time of the mobile phone in the screen-on scene, and the end charging capacity of the mobile phone in the screen-off scene is also the start charging capacity of the mobile phone in the screen-on scene. Continue to monitor the mobile phone. If it is monitored that the mobile phone stops charging or the battery capacity stops updating, the end charging time and the end charging capacity of the mobile phone in the screen-on scene can be recorded. At this time, the continuous charging time in the screen-on scene and the battery capacity increment during the continuous charging time can be updated. In the second case, if it is monitored that the mobile phone stops charging or the battery capacity stops updating, the end charging time and end charging capacity of the mobile phone in the screen-off scenario are recorded, and the continuous charging time of the mobile phone in the screen-off scenario and the battery capacity increment during the continuous charging time can be calculated.
[0072] When there is a scene switching in an electronic device, by respectively obtaining the continuous charging time of the electronic device in the scene before the switching and the battery capacity increment during the continuous charging time, the continuous charging time and battery capacity increment of the electronic device in different scenes can be obtained, so as to judge whether the electronic device is charging abnormally in different scenes based on these data. For example, during the charging process, the electronic device switches from the screen-on scene to the screen-off scene, then the scene before the switching is the screen-on scene, and the scene after the switching is the screen-off scene. By respectively obtaining the continuous charging time and battery capacity increment of the electronic device in the screen-on scene and the screen-off scene, it can be judged whether the electronic device is charging abnormally in the screen-on scene, and whether it is charging abnormally in the screen-off scene.
[0073] Considering that the user may repeatedly switch scenes during the charging process of the electronic device, in this case, the battery capacity of the electronic device may not be updated in time, affecting the accuracy of the obtained battery capacity increment. Therefore, in order to improve the accuracy of the obtained battery capacity increment, the electronic device can first determine whether the continuous charging time is greater than the time threshold after obtaining the continuous charging time in the target scene. When the continuous charging time is greater than the time threshold (for example, 2 minutes), the battery capacity increment within the continuous charging time is obtained. If the continuous charging time is less than or equal to the time threshold, the battery capacity of the electronic device may not be updated in time, and there is no need to obtain the battery capacity increment within the continuous charging time, that is, when judging whether the electronic device is charging abnormally, the scene with a short continuous charging time during the charging process can be ignored. Among them, the time threshold is used to determine whether to obtain the battery capacity increment within the continuous charging time. Optionally, the above time threshold can be set according to actual needs, and it is not limited here.
[0074] If scene switching occurs during the charging process and the continuous charging time of each scene is greater than the time threshold, then it can be determined that there are both screen-on scenes and screen-off scenes during this charging process, and the continuous charging time of the electronic device in the screen-on scene and the battery capacity increment during the continuous charging time, as well as the continuous charging time of the electronic device in the screen-off scene and the battery capacity increment during the continuous charging time can be obtained respectively; based on the continuous charging time of the electronic device in the screen-on scene and the battery capacity increment during the continuous charging time, the average charging speed of the electronic device in the screen-on scene is calculated, and based on the average charging speed of the electronic device in the screen-on scene, it can be determined whether the electronic device is charging abnormally in the screen-on scene; based on the continuous charging time of the electronic device in the screen-off scene and the battery capacity increment during the continuous charging time, the average charging speed of the electronic device in the screen-off scene is calculated, and based on the average charging speed of the electronic device in the screen-off scene, it can be determined whether the electronic device is charging abnormally in the screen-off scene. Among them, this charging refers to the charging in step 201.
[0075] Of course, there may be only screen-on scenes or screen-off scenes during the charging process. For example, during the charging process, the electronic device is always in the screen-off scene, or the scene switches during the charging process, the continuous charging time of the screen-off scene is greater than the time threshold, but the continuous charging time of the screen-on scene is less than or equal to the time threshold. For these situations, it can be considered that only the screen-off scene exists during the charging process. During the charging process, the electronic device is always in the screen-on scene, or the scene switches during the charging process, the continuous charging time of the screen-on scene is greater than the time threshold, but the continuous charging time of the screen-off scene is less than or equal to the time threshold. For these situations, it can be considered that only the screen-on scene exists during the charging process.
[0076] Step 202: Calculate a first average charging speed based on the continuous charging time and the battery capacity increment.
[0077] The first average charging speed is the average charging speed of the electronic device in the target scenario. The first average charging speed can be obtained by dividing the battery capacity increment by the continuous charging time.
[0078] In order to prevent the electronic device from repeatedly calculating the first average charging speed in this charging, a charging speed mark can be set, which indicates whether the first average charging speed has been calculated in this charging. If the charging speed mark is the first mark, the first average charging speed is calculated based on the continuous charging time and the battery capacity increment, and the first mark indicates that the first average charging speed is not calculated in this charging. After calculating the first average charging speed, it is necessary to synchronously update the charging speed mark, that is, update the charging speed mark to the second mark, and the second mark indicates that the first average charging speed has been calculated in this charging. For example, the first mark is false and the second mark is true.
[0079] It is understandable that if the electronic device is disconnected from the charging device, it means that the current charging has ended. In order not to affect the first average charging speed calculated by the electronic device in the next charging, the charging speed mark can be updated to the first mark.
[0080] In an application scenario, a mobile phone can be used as an example to introduce its charging monitoring process. This application can execute the charging monitoring process at intervals of a preset time (for example, 5 seconds), that is, the charging monitoring process is executed every 5 seconds (which can be called a charging 5-second thread). Figure 3As shown, when the mobile phone is plugged into the power adapter, the charging 5s thread will be turned on. The 5s thread has a monitoring function for turning on regular tracking points (regular tracking points refer to general tracking points similar to monitoring the average charging speed). The monitoring function thread runs every 5s. If the power charger is just plugged in, it will be pulled up for the first time. If it is the first time, it is necessary to record the current scene of the mobile phone (for example, led_on=true indicates a screen-on scene, led_on=false indicates a screen-off scene), the current system time pre_time of the mobile phone (used to calculate the continuous charging time) and the current battery capacity pre_rm (used to calculate the battery capacity increment). If it is not the first time, it is determined whether the mobile phone starts charging (that is, whether charge_start is equal to true). The judgment standard is that the state 5 seconds ago was not charging and the current state is charging; when charge_start is equal to true, it is necessary to recalculate the current scene, the current system time pre_time and the current battery capacity pre_rm; then it is determined whether the mobile phone stops charging (that is, whether charge_end is equal to true). The judgment standard is that the state 5s ago was charging and the current state is not charging. If the mobile phone meets any of the conditions of charge_end=true, full charge, and battery capacity stop updating, it is determined that the continuous charging time and battery capacity increment in the screen-on / off scenario need to be updated, and the update flag need_update=true is set, otherwise the update flag need_update=false is set.
[0081] When led_on=true 5s ago, and the current led_on=false or need_update=true, it indicates that the continuous charging time and battery capacity increment in the screen-on scenario need to be calculated. Get the current system time curr_time, and the current system time curr_time-the last saved system time pre_time>2min, indicating that the continuous charging time in the screen-on scenario has exceeded 2min, so it is necessary to record the battery capacity increment ledon_rm=curr_rm-pre_rm and the continuous charging time ledon_time=curr_time-pre_time in the screen-on scenario, and re-update the mobile phone system time pre_time=curr_time and the battery capacity pre_rm=curr_rm.
[0082] When led_on = false 5s ago, and the current led_on = true or need_update = true, it indicates that the continuous charging time and battery capacity increment in the screen-off scenario need to be calculated. Get the current system time, and the current system time curr_time-the last saved system time pre_time>2min, indicating that the continuous charging time in the screen-off scenario has exceeded 2min, so it is necessary to record the battery capacity increment ledoff_rm = curr_rm-pre_rm and the continuous charging time ledoff_time = curr_time-pre_time in the screen-off scenario, and re-update the mobile phone system time pre_time = curr_time and the battery capacity pre_rm = curr_rm. And update the previous led_on status to the current led_on status every 5s.
[0083] like Figure 4 As shown, after updating the current state of led_on, if the mobile phone meets any of the conditions of charge_end=true, full charge, and battery capacity stopping updating, the calculation process is triggered. The average charging speed in the screen-on scenario and the average charging speed in the screen-off scenario are only calculated once. Therefore, in order to avoid repeated calculations, a charging speed mark is set. If it has been calculated, it will not be calculated again. If it has not been calculated, it is determined whether the continuous charging time ledon_time in the screen-on scenario is equal to 0. If ledon_time is equal to 0, the average charging speed ledon_ave_speed in the screen-on scenario is set to 0. If ledon_time is not equal to 0, the average charging speed ledon_ave_speed in the screen-on scenario is set to ledon_rm / ledon_time; similarly, it is determined whether the continuous charging time ledoff_time in the screen-off scenario is equal to 0. If ledoff_time is equal to 0, the average charging speed ledoff_ave_speed in the screen-off scenario is set to 0. If it is not equal to 0, the average charging speed ledoff_ave_speed in the screen-off scenario is set to ledoff_rm / ledoff_time.
[0084] When the mobile phone is disconnected from the power adapter (for example, the power adapter is unplugged), the voltage output of the power adapter can be interrupted, and then the average charging speed is calculated. If the average charging speed has been calculated, all variables are reset to the default values, such as ledon_rm=0\ledoff_rm=0\ledon_time=0\ledoff_time=0\ledon_ave_speed=0\ledoff_ave_speed=0, and the charging speed flag is updated to false. Finally, the 5s charging thread is stopped to stop the regular point monitoring.
[0085] Step 203: Determine whether the electronic device is charging abnormally based on the first average charging speed.
[0086] Determining whether the electronic device is charging abnormally may refer to determining whether the electronic device is charging abnormally in a target scenario. For example, if the first average charging speed is the average charging speed of the electronic device in a bright screen scenario, then based on the first average charging speed, it can be determined whether the electronic device is charging abnormally in a bright screen scenario.
[0087] Step 203 may be implemented in either of the following two ways.
[0088] In the first method, the electronic device compares the first average charging speed with the first speed threshold corresponding to the target scenario; if the first average charging speed is less than the first speed threshold, it is determined that the charging of the electronic device is abnormal; if the first average charging speed is greater than or equal to the first speed threshold, it is determined that the charging of the electronic device is normal.
[0089] Among them, the first speed threshold is used to determine whether the device is charging abnormally in the target scenario. If the first average charging speed is less than the first speed threshold, it is determined that the electronic device is charging abnormally in the target scenario; if the first average charging speed is greater than or equal to the first speed threshold, it is determined that the electronic device is charging normally in the target scenario. For example, the first average charging speed is the average charging speed of the electronic device in the bright screen scenario. If the first average charging speed is less than the first speed threshold, it can be determined that the electronic device is charging abnormally in the bright screen scenario; if the first average charging speed is greater than or equal to the first speed threshold, it can be determined that the electronic device is charging normally in the bright screen scenario.
[0090] After determining that the electronic device is charging abnormally, the electronic device can send corresponding prompt information to the server. The prompt information reflects the abnormal charging of the electronic device. After the server receives the prompt information, it can help the electronic device manufacturer to promptly understand the abnormal situation of the electronic device during the charging process, so as to handle the abnormal situation and improve the charging speed of the electronic device.
[0091] In a second manner, the electronic device sends a first average charging speed to the server, and the first average charging speed is used to determine that the electronic device is charging abnormally when the first average charging speed is less than a first speed threshold.
[0092] After obtaining the first average charging speed, the electronic device may send the first average charging speed to the server, and the server may compare the first average charging speed with a first speed threshold to determine whether the electronic device is charging abnormally in the target scenario.
[0093] After determining whether the electronic device is charging abnormally based on the first average charging speed, the server may send a determination result to the electronic device, where the determination result includes whether the electronic device is charging abnormally or charging normally, so that the electronic device can know whether it is charging abnormally.
[0094] In an optional embodiment, before sending the first average charging speed to the server, the electronic device may determine whether the first average charging speed is greater than the second speed threshold. If the first average charging speed is greater than the second speed threshold, the first average charging speed is sent to the server to reduce the impact of the electronic device being unable to charge on the abnormal analysis in the server; if the first average charging speed is less than or equal to the second speed threshold, the first average charging speed is not sent to the server, and a direct prompt may be given that the electronic device cannot be charged. The second speed threshold is less than the first speed threshold. Optionally, on the basis that the second speed threshold is less than the first speed threshold, the second speed threshold (for example, 0) may be set according to actual needs, and this is not limited here.
[0095] It is understandable that, since the power consumption of electronic devices is different when charging in different scenarios, resulting in different increases in the battery temperature of the electronic devices, different first speed thresholds can be set for different scenarios, and / or different second speed thresholds can be set for different scenarios, so as to adaptively determine whether the electronic device is charging abnormally in different scenarios based on different first speed thresholds, and adaptively determine whether to send the average charging speed of the electronic device in different scenarios to the server based on different second speed thresholds. For example, since the power consumption of electronic devices in the screen-on scenario is higher than that in the screen-off scenario, resulting in a larger increase in the battery temperature and a slower charging speed, the first speed threshold corresponding to the screen-on scenario can be set to be less than the first speed threshold corresponding to the screen-off scenario, and the second speed threshold corresponding to the screen-on scenario can be set to be less than the second speed threshold corresponding to the screen-off scenario. Of course, the first speed thresholds corresponding to different scenarios may also be the same, and the second speed thresholds corresponding to different scenarios may also be the same, which is not limited here.
[0096] In an optional embodiment, after determining that the electronic device is charging abnormally, the method further includes:
[0097] If at least one second average charging speed is greater than or equal to the first speed threshold, it is determined that the charging abnormality of the electronic device is abnormal heat dissipation of the electronic device, and the second average charging speed is the average charging speed of the reference device in the target scenario, and the reference device is a device that uses the same charging solution as the electronic device.
[0098] The charging scheme is a scheme that instructs the electronic device and the reference device on how to charge, such as a scheme for implementing a fast charging method.
[0099] If the second average charging speed is greater than or equal to the first speed threshold, it means that the reference device is charging normally. If the reference device and the electronic device use the same charging scheme, and the reference device charges normally but the electronic device charges abnormally, it means that the electronic device has abnormal heat dissipation, resulting in excessive battery temperature, thereby reducing the charging speed.
[0100] Abnormal heat dissipation can be understood as the poor heat dissipation effect of the electronic device compared to the reference device. For example, an unreasonable layout of the hardware on the printed circuit board (PCB) of the electronic device may lead to poor heat dissipation effect.
[0101] For example, there are 50 reference devices. If the average charging speed of these 50 reference devices in the screen-on scenario is greater than or equal to the first speed threshold, and the average charging speed of the electronic device in the screen-on scenario is less than the first speed threshold, it can be determined that the electronic device has heat dissipation abnormality.
[0102] In an optional embodiment, the battery temperature of the electronic device in the target scenario can be obtained; if the battery temperature is less than the temperature threshold corresponding to the target scenario, the third speed threshold corresponding to the target scenario is increased to obtain the increased speed threshold, and the third speed threshold is the lower limit of the charging speed of the electronic device in the target scenario; or, the battery temperature is sent to a server, and the increased speed threshold sent by the server is received, and the increased speed threshold is sent by the server based on the battery temperature; when the battery temperature rises, the charging speed of the electronic device in the target scenario is controlled based on the increased speed threshold.
[0103] The battery temperature of the electronic device in the target scenario may be the battery temperature at any time in the target scenario, or may be the battery temperature when obtaining the continuous charging time in the target scenario and the battery capacity increment within the continuous charging time, which is not limited here.
[0104] It is understandable that, since the power consumption of electronic devices is different when charging in different scenarios, resulting in different increases in the battery temperature of the electronic devices, different temperature thresholds may be set for different scenarios, and / or different third speed thresholds may be set for different scenarios, so as to adaptively determine whether to increase the corresponding third speed threshold based on different temperature thresholds, and adaptively control the charging speed of the electronic devices in different scenarios based on different third speed thresholds. For example, since the power consumption of electronic devices in the screen-on scenario is higher than that in the screen-off scenario, resulting in a larger increase in the battery temperature and a slower charging speed, the temperature threshold corresponding to the screen-on scenario may be set to be smaller than the temperature threshold corresponding to the screen-off scenario, and the third speed threshold corresponding to the screen-on scenario may be set to be smaller than the third speed threshold corresponding to the screen-off scenario. Of course, the temperature thresholds corresponding to different scenarios may also be the same, and the third speed thresholds corresponding to different scenarios may also be the same, which are not limited here.
[0105] The above-mentioned increased speed threshold can be obtained by the electronic device based on the battery temperature, or it can be obtained by the server based on the battery temperature. When the electronic device obtains the increased speed threshold based on the battery temperature, it can update its own temperature control strategy so that the temperature control strategy is closer to the actual charging situation of the electronic device. When the server obtains the increased speed threshold based on the battery temperature, the server can update the temperature control strategy of the electronic device so that the temperature control strategy is closer to the actual charging situation of the electronic device. Among them, the temperature control strategy includes a third speed threshold. When the battery temperature rises, the charging speed of the electronic device in the target scenario is reduced, and the reduced charging speed is controlled to be not less than the third speed threshold to maintain a balance between temperature and charging speed, and to increase the speed as much as possible when the temperature of the electronic device is not too high. The above-mentioned third speed threshold is greater than the first speed threshold.
[0106] In an optional embodiment, after determining that the electronic device is abnormally charged, a first prompt may be issued to prompt that the electronic device is abnormally charged. For example, the electronic device may issue the first prompt by voice, text, vibration, etc.
[0107] By prompting charging abnormalities, electronic devices can help electronic device users to promptly understand abnormal conditions of the electronic devices during charging, so that the abnormal conditions can be handled in a timely manner, thereby improving the charging speed of the electronic devices.
[0108] In an embodiment of the present application, during the charging process of an electronic device, the continuous charging time in the scenario in which the electronic device is located (i.e., the target scenario) and the battery capacity increment during the continuous charging time can be obtained. Based on the continuous charging time and the battery capacity increment, the average charging speed of the electronic device in the target scenario can be calculated, thereby enabling monitoring of the average charging speed during the charging process, and determining whether the electronic device is charging abnormally based on the average charging speed.
[0109] See also Figure 5 , is a schematic diagram of an implementation flow of an abnormality determination method provided in an embodiment of the present application, and the abnormality determination method is applied to a server. Figure 5 As shown, the abnormality determination method may include the following steps:
[0110] Step 501: Receive a first average charging speed of an electronic device.
[0111] The first average charging speed is the average charging speed of the electronic device in a target scene. The target scene is the scene in which the electronic device is in the charging process, such as a screen-on scene, a screen-off scene, etc.
[0112] Step 502: If the first average charging speed is less than a first speed threshold corresponding to the target scenario, it is determined that the electronic device is charging abnormally.
[0113] Among them, the first speed threshold is used to determine whether the device is charging abnormally in the target scenario. If the first average charging speed is less than the first speed threshold, it is determined that the electronic device is charging abnormally in the target scenario; if the first average charging speed is greater than or equal to the first speed threshold, it is determined that the electronic device is charging normally in the target scenario. For example, the first average charging speed is the average charging speed of the electronic device in the bright screen scenario. If the first average charging speed is less than the first speed threshold, it can be determined that the electronic device is charging abnormally in the bright screen scenario; if the first average charging speed is greater than or equal to the first speed threshold, it can be determined that the electronic device is charging normally in the bright screen scenario.
[0114] It should be noted that, for the setting of the first speed threshold, reference may be made to the relevant description of the previous charging monitoring method embodiment, which will not be repeated here.
[0115] In an optional embodiment, after determining that the electronic device is charging abnormally, the method further includes:
[0116] If at least one second average charging speed is greater than or equal to the first speed threshold, it is determined that the charging abnormality of the electronic device is abnormal heat dissipation of the electronic device, and the second average charging speed is the average charging speed of the reference device in the target scenario, and the reference device is a device that uses the same charging solution as the electronic device.
[0117] The charging scheme is a scheme that instructs the electronic device and the reference device on how to charge, such as a scheme for implementing a fast charging method.
[0118] If the second average charging speed is greater than or equal to the first speed threshold, it means that the reference device is charging normally. If the reference device and the electronic device use the same charging scheme, and the reference device charges normally but the electronic device charges abnormally, it means that the electronic device has abnormal heat dissipation, resulting in excessive battery temperature, thereby reducing the charging speed.
[0119] Abnormal heat dissipation can be understood as the poor heat dissipation effect of the electronic device compared to the reference device. For example, the unreasonable layout of the hardware on the PCB of the electronic device may lead to poor heat dissipation effect.
[0120] For example, there are 50 reference devices. If the average charging speed of these 50 reference devices in the screen-on scenario is greater than or equal to the first speed threshold, and the average charging speed of the electronic device in the screen-on scenario is less than the first speed threshold, it can be determined that the electronic device has heat dissipation abnormality.
[0121] In an optional embodiment, the server receives the battery temperature of the electronic device in the target scenario; if the battery temperature is less than the temperature threshold corresponding to the target scenario, the server increases the third speed threshold corresponding to the target scenario to obtain the increased speed threshold, the third speed threshold being the lower limit of the charging speed of the electronic device in the target scenario; and sends the increased speed threshold to the electronic device, the increased speed threshold being used to control the charging speed of the electronic device in the target scenario. The third speed threshold is greater than the first speed threshold.
[0122] It should be noted that, regarding the setting of the above-mentioned temperature threshold and the above-mentioned third speed threshold, reference may be made to the relevant description of the previous charging monitoring method embodiment, which will not be repeated here.
[0123] The server can update the temperature control strategy of the electronic device based on the increase of the third speed threshold by the battery temperature, so that the temperature control strategy is closer to the actual charging situation of the electronic device. The temperature control strategy includes the third speed threshold. When the battery temperature rises, the charging speed of the electronic device in the target scenario is reduced, and the reduced charging speed is controlled to be not less than the third speed threshold to maintain the balance between temperature and charging speed, and to increase the speed as much as possible when the temperature of the electronic device is not too high.
[0124] In an optional embodiment, after the server determines that the electronic device is abnormally charged, a second prompt may be issued to prompt that the electronic device is abnormally charged.
[0125] For example, the server may send the second prompt via voice, text, etc.
[0126] By prompting the electronic device to charge abnormally, the server can help the electronic device manufacturer to promptly understand the abnormal situation of the electronic device during the charging process, so as to handle the abnormal situation and improve the charging speed of the electronic device.
[0127] In an embodiment of the present application, after receiving the average charging speed of the electronic device in the target scenario, the average charging speed is compared with a first speed threshold. If the average charging speed is less than the first speed threshold, it means that the average charging speed is too low to meet the charging demand of the electronic device. Thus, it can be determined that the electronic device is charging abnormally in the target scenario, thereby realizing the judgment of the charging abnormality of the electronic device.
[0128] See also Figure 6 , is a schematic diagram of the structure of a charging monitoring device provided in an embodiment of the present application. For the sake of convenience of explanation, only the parts related to the embodiment of the present application are shown.
[0129] The charging monitoring device comprises:
[0130] A data acquisition module 61 is used to acquire the continuous charging time of the electronic device and the battery capacity increment during the continuous charging time in a target scenario during the charging process of the electronic device, where the target scenario is the scenario in which the electronic device is located during the charging process;
[0131] A speed calculation module 62, configured to calculate a first average charging speed based on the continuous charging time and the battery capacity increment, where the first average charging speed is an average charging speed of the electronic device in a target scenario;
[0132] The first determination module 63 is configured to determine whether the electronic device is abnormally charged based on the first average charging speed.
[0133] Optionally, the first determining module 63 is specifically configured to:
[0134] If the first average charging speed is less than a first speed threshold corresponding to the target scenario, it is determined that the electronic device is charging abnormally.
[0135] Optionally, the first determining module 63 is specifically configured to:
[0136] A first average charging speed is sent to a server, where the first average charging speed is used to determine that charging of the electronic device is abnormal when the first average charging speed is less than a first speed threshold corresponding to a target scenario.
[0137] Optionally, the first determining module 63 is specifically configured to:
[0138] If the first average charging speed is greater than a second speed threshold corresponding to the target scenario, the first average charging speed is sent to the server.
[0139] Optionally, the data acquisition module 61 is specifically used for:
[0140] When the electronic device stops charging or the battery capacity stops updating in the target scenario, obtaining the continuous charging time of the electronic device in the target scenario and the battery capacity increment during the continuous charging time;
[0141] Alternatively, when a scene switch occurs in the electronic device, the continuous charging time of the electronic device in the scene before the switch and the battery capacity increment during the continuous charging time are obtained, and the scene before the switch and the scene after the switch are both target scenes.
[0142] Optionally, the speed calculation module 62 is specifically used for:
[0143] If the charging speed mark is the first mark, the first average charging speed is calculated based on the continuous charging time and the battery capacity increment. The first mark indicates that the first average charging speed is not calculated in this charging.
[0144] Optionally, the charging monitoring device further includes:
[0145] A first updating module, configured to update the charging speed mark to a second mark, wherein the second mark indicates that the first average charging speed has been calculated in this charging;
[0146] The second updating module is used to update the charging speed mark to the first mark if the electronic device is disconnected from the charging device.
[0147] Optionally, the charging monitoring device further includes:
[0148] The heat dissipation determination module is used to determine that the charging abnormality of the electronic device is a heat dissipation abnormality of the electronic device if at least one second average charging speed is greater than or equal to the first speed threshold, the second average charging speed is the average charging speed of a reference device in a target scenario, and the reference device is a device that uses the same charging solution as the electronic device.
[0149] Optionally, the charging monitoring device further includes:
[0150] A temperature acquisition module, used to acquire the battery temperature of the electronic device in a target scenario;
[0151] A threshold increasing module, configured to increase a third speed threshold corresponding to the target scenario to obtain an increased speed threshold if the battery temperature is less than a temperature threshold corresponding to the target scenario, wherein the third speed threshold is a lower limit of the charging speed of the electronic device in the target scenario;
[0152] Alternatively, a data processing module is used to send the battery temperature to the server and receive an increased speed threshold sent by the server, where the increased speed threshold is sent by the server based on the battery temperature;
[0153] The speed control module is used to control the charging speed of the electronic device in a target scenario based on the increased speed threshold when the battery temperature rises.
[0154] Optionally, the charging monitoring device further includes:
[0155] The first prompt module is used to issue a first prompt to prompt that the electronic device is charging abnormally.
[0156] The charging monitoring device provided in the embodiment of the present application can be applied in the aforementioned charging monitoring method embodiment. For details, please refer to the description of the aforementioned method embodiment, which will not be repeated here.
[0157] See also Figure 7 , is a structural diagram of an abnormality determination device provided in an embodiment of the present application. For the sake of convenience of explanation, only the parts related to the embodiment of the present application are shown.
[0158] The above-mentioned abnormality determination device comprises:
[0159] A speed receiving module 71 is used to receive a first average charging speed of the electronic device, where the first average charging speed is an average charging speed of the electronic device in a target scenario, where the target scenario is a scenario in which the electronic device is located during charging;
[0160] The second determination module 72 is configured to determine that the charging of the electronic device is abnormal if the first average charging speed is less than a first speed threshold corresponding to the target scenario.
[0161] Optionally, the abnormality determination device further includes:
[0162] The second prompt module is used to issue a second prompt to prompt that the electronic device is charging abnormally.
[0163] Optionally, the abnormality determination device further includes:
[0164] The heat dissipation determination module is used to determine that the charging abnormality of the electronic device is a heat dissipation abnormality of the electronic device if at least one second average charging speed is greater than or equal to the first speed threshold, the second average charging speed is the average charging speed of a reference device in a target scenario, and the reference device is a device that uses the same charging solution as the electronic device.
[0165] Optionally, the abnormality determination device further includes:
[0166] A temperature receiving module, used to receive the battery temperature of the electronic device in a target scenario;
[0167] A threshold increasing module, configured to increase a third speed threshold corresponding to the target scenario to obtain an increased speed threshold if the battery temperature is less than a temperature threshold corresponding to the target scenario, wherein the third speed threshold is a lower limit of the charging speed of the electronic device in the target scenario;
[0168] The threshold sending module is used to send the increased speed threshold to the electronic device, and the increased speed threshold is used to control the charging speed of the electronic device in the target scenario.
[0169] The abnormality determination device provided in the embodiment of the present application can be applied in the aforementioned abnormality determination method embodiment. For details, please refer to the description of the aforementioned method embodiment, which will not be repeated here.
[0170] Figure 8 Schematic diagram of the structure of an electronic device provided by an embodiment of the present application. Figure 8 As shown, the electronic device 8 of this embodiment includes: one or more processors 80 (only one is shown in the figure), a memory 81, and a computer program 82 stored in the memory 81 and executable on the at least one processor 80. When the processor 80 executes the computer program 82, the steps in the above-mentioned charging monitoring method embodiment are implemented.
[0171] The electronic device 8 may include, but is not limited to, a processor 80 and a memory 81. Those skilled in the art will appreciate that Figure 8 It is only an example of the electronic device 8 and does not constitute a limitation of the electronic device 8. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the electronic device may also include input and output devices, network access devices, buses, etc.
[0172] The processor 80 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0173] The memory 81 may be an internal storage unit of the electronic device 8, such as a hard disk or memory of the electronic device 8. The memory 81 may also be an external storage device of the electronic device 8, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the electronic device 8. Further, the memory 81 may also include both an internal storage unit and an external storage device of the electronic device 8. The memory 81 is used to store the computer program and other programs and data required by the electronic device. The memory 81 may also be used to temporarily store data that has been output or is to be output.
[0174] Fig. 9 Schematic diagram of the structure of a server provided by an embodiment of the present application. Fig. 9 As shown, the server 9 of this embodiment includes: one or more processors 90 (only one is shown in the figure), a memory 91, and a computer program 92 stored in the memory 91 and executable on the at least one processor 90. When the processor 90 executes the computer program 92, the steps in the above-mentioned abnormality determination method embodiment are implemented.
[0175] The server 9 may include, but is not limited to, a processor 90 and a memory 91. Those skilled in the art will appreciate that Fig. 9 It is only an example of the server 9 and does not constitute a limitation on the server 9. The server 9 may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the server may also include input and output devices, network access devices, buses, etc.
[0176] The processor 90 may be a CPU, or other general-purpose processors, DSP, ASIC, FPGA or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor.
[0177] The memory 91 may be an internal storage unit of the server 9, such as a hard disk or memory of the server 9. The memory 91 may also be an external storage device of the server 9, such as a plug-in hard disk, SMC, SD card, flash memory card, etc. equipped on the server 9. Further, the memory 91 may include both an internal storage unit of the server 9 and an external storage device. The memory 91 is used to store the computer program and other programs and data required by the server. The memory 91 may also be used to temporarily store data that has been output or is to be output.
[0178] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned device can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0179] The embodiment of the present application further provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments can be implemented.
[0180] An embodiment of the present application also provides a computer program product, which, when the computer program product runs on an electronic device, enables the electronic device to implement the steps in the above-mentioned charging monitoring method embodiment when the computer program product is executed, or when the computer program product runs on a server, enables the server to implement the steps in the above-mentioned abnormality determination method embodiment when the computer program product is executed.
[0181] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0182] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0183] In the embodiments provided in the present application, it should be understood that the disclosed devices / electronic devices / servers and methods can be implemented in other ways. For example, the device / electronic device / server embodiments described above are merely schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0184] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0185] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable media do not include electric carrier signals and telecommunication signals.
[0186] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A charging monitoring method, characterized in that: include: During the charging process of the electronic device, obtaining the continuous charging time of the electronic device in a target scenario and the battery capacity increment during the continuous charging time, wherein the target scenario is the scenario in which the electronic device is located during the charging process; Calculate a first average charging speed based on the continuous charging time and the battery capacity increment, where the first average charging speed is an average charging speed of the electronic device in the target scenario; Based on the first average charging speed, determining whether the electronic device is charging abnormally; After determining that the electronic device is abnormally charged, obtaining a battery temperature of the electronic device in the target scenario; sending the battery temperature to a server, and receiving an increased speed threshold sent by the server, wherein the increased speed threshold is sent by the server based on the battery temperature; When the battery temperature increases, the charging speed of the electronic device in the target scenario is controlled based on the increased speed threshold.
2. The charging monitoring method according to claim 1, characterized in that: The determining whether the electronic device is abnormally charged based on the first average charging speed includes: If the first average charging speed is less than a first speed threshold corresponding to the target scenario, it is determined that the electronic device is charging abnormally.
3. The charging monitoring method according to claim 1, characterized in that: The determining whether the electronic device is abnormally charged based on the first average charging speed includes: The first average charging speed is sent to a server, where the first average charging speed is used to determine that charging of the electronic device is abnormal when the first average charging speed is less than a first speed threshold corresponding to the target scenario.
4. The charging monitoring method according to claim 3, characterized in that: The sending the first average charging speed to the server includes: If the first average charging speed is greater than a second speed threshold corresponding to the target scenario, the first average charging speed is sent to the server, and the second speed threshold is less than the first speed threshold.
5. The charging monitoring method according to any one of claims 2 to 4, characterized in that: After determining that the electronic device is abnormally charged, the method further includes: If at least one second average charging speed is greater than or equal to the first speed threshold, it is determined that the charging abnormality of the electronic device is a heat dissipation abnormality of the electronic device, and the second average charging speed is the average charging speed of a reference device in the target scenario, and the reference device is a device that uses the same charging solution as the electronic device.
6. The charging monitoring method according to claim 1, characterized in that: The obtaining of the continuous charging time of the electronic device in the target scenario and the battery capacity increment during the continuous charging time includes: When the electronic device stops charging or the battery capacity stops updating in the target scenario, acquiring the continuous charging time of the electronic device in the target scenario and the battery capacity increment during the continuous charging time; Alternatively, when the electronic device switches scenes, the continuous charging time of the electronic device in the scene before the switching and the battery capacity increment during the continuous charging time are obtained, and the scene before the switching and the scene after the switching are both the target scenes.
7. The charging monitoring method according to claim 1, characterized in that: Obtaining the battery capacity increment during the continuous charging time, including: If the continuous charging time is greater than the time threshold, the battery capacity increment within the continuous charging time is acquired.
8. The charging monitoring method according to claim 1, characterized in that: The calculating a first average charging speed based on the continuous charging time and the battery capacity increment comprises: If the charging speed mark is a first mark, the first average charging speed is calculated based on the continuous charging time and the battery capacity increment, and the first mark indicates that the first average charging speed is not calculated in this charging.
9. The charging monitoring method according to claim 8, characterized in that: After calculating the first average charging speed, the method further includes: The charging speed flag is updated to a second flag, where the second flag indicates that the first average charging speed has been calculated in the current charging.
10. The charging monitoring method according to claim 9, characterized in that: After the charging speed mark is updated to the second mark, the method further includes: If the electronic device is disconnected from the charging device, the charging speed mark is updated to the first mark.
11. The charging monitoring method according to claim 1, characterized in that: Also includes: If the battery temperature is lower than the temperature threshold corresponding to the target scenario, the third speed threshold corresponding to the target scenario is increased to obtain an increased speed threshold, where the third speed threshold is a lower limit of the charging speed of the electronic device in the target scenario.
12. The charging monitoring method according to claim 1, characterized in that: After determining that the electronic device is abnormally charged, the method further includes: A first prompt is issued to indicate that the electronic device is charging abnormally.
13. A method for determining an abnormality, characterized in that: include: Receiving a first average charging speed of the electronic device, where the first average charging speed is an average charging speed of the electronic device in a target scenario, where the target scenario is a scenario in which the electronic device is located during charging; If the first average charging speed is less than a first speed threshold corresponding to the target scenario, determining that the electronic device is charging abnormally; Receiving a battery temperature of the electronic device in the target scenario; If the battery temperature is lower than the temperature threshold, increasing the third speed threshold corresponding to the target scenario to obtain an increased speed threshold, wherein the third speed threshold is a lower limit of the charging speed of the electronic device in the target scenario; The increased speed threshold is sent to the electronic device, where the increased speed threshold is used to control the charging speed of the electronic device in the target scenario.
14. The abnormality determination method according to claim 13, characterized in that: After determining that the electronic device is abnormally charged, the method further includes: If at least one second average charging speed is greater than or equal to the first speed threshold, it is determined that the charging abnormality of the electronic device is a heat dissipation abnormality of the electronic device, and the second average charging speed is the average charging speed of a reference device in the target scenario, and the reference device is a device that uses the same charging solution as the electronic device.
15. The abnormality determination method according to any one of claims 13 to 14, characterized in that: After determining that the electronic device is abnormally charged, the method further includes: A second prompt is issued to indicate that the electronic device is charging abnormally.
16. A charging monitoring device, characterized in that: include: A data acquisition module, used to acquire, during the charging process of the electronic device, the continuous charging time of the electronic device in a target scenario and the battery capacity increment during the continuous charging time, wherein the target scenario is the scenario in which the electronic device is located during the charging process; A speed calculation module, configured to calculate a first average charging speed based on the continuous charging time and the battery capacity increment, wherein the first average charging speed is an average charging speed of the electronic device in the target scenario; A first determining module, configured to determine whether the electronic device is abnormally charged based on the first average charging speed; A temperature acquisition module, configured to acquire a battery temperature of the electronic device in the target scenario after determining that the electronic device is abnormally charged; a data processing module, configured to send the battery temperature to a server, and receive an increased speed threshold sent by the server, wherein the increased speed threshold is sent by the server based on the battery temperature; The speed control module is used to control the charging speed of the electronic device in the target scenario based on the increased speed threshold when the battery temperature increases.
17. An abnormality determination device, characterized in that: include: A speed receiving module, configured to receive a first average charging speed of the electronic device, where the first average charging speed is an average charging speed of the electronic device in a target scenario, where the target scenario is a scenario in which the electronic device is located during charging; A second determination module, configured to determine that charging of the electronic device is abnormal if the first average charging speed is less than a first speed threshold corresponding to the target scenario; A temperature receiving module, used to receive the battery temperature of the electronic device in the target scenario; a threshold increasing module, configured to increase a third speed threshold corresponding to the target scenario to obtain an increased speed threshold if the battery temperature is less than a temperature threshold, wherein the third speed threshold is a lower limit of the charging speed of the electronic device in the target scenario; The threshold sending module is used to send the increased speed threshold to the electronic device, and the increased speed threshold is used to control the charging speed of the electronic device in the target scenario.
18. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the steps of the charging monitoring method according to any one of claims 1 to 12 are implemented.
19. A server comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the abnormality determination method according to any one of claims 13 to 15 are implemented.
20. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the computer program implements the steps of the charging monitoring method according to any one of claims 1 to 12, or implements the steps of the abnormality determination method according to any one of claims 13 to 15.
