A power consumption control method and device of a power supply apparatus, an apparatus, and a storage medium

CN122823670APending Publication Date: 2026-09-25SHENZHEN TIANSHITONG INTELLIGENT CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610959161.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-06-30
Publication Date
2026-09-25

AI Technical Summary

Technical Problem

[0003]然而,相关技术所采用的方法仅依靠固定设置的阈值进行模式调整,无法灵活适用于存在充电能力差异的不同供电设备,从而降低对供电设备的功耗控制的准确性

Benefits of technology

[0009]本申请实施例提出的供电设备的功耗控制方法和装置、设备及存储介质,根据当日最高电量与预设充满电量的比较结果更新基础阈值,使基础阈值始终跟随设备近期充电表现进行缓慢调整,形成对自身充电能力的长期认知。通过根据当日天气数据从按天气类型和日照等级划分的充电自学习模型中确定目标统计项,并对充电样本统计值和未充满样本统计值执行非对称更新,使得在当日达到充满时仅增加充满次数而不记录被电池容量上限截断后的电量增量,从而避免了因满电截断导致的学习样本失真,在未充满时则基于实际充电量更新未充满平均充电量,保证了未充满场景下充电量统计的准确性。根据次日天气数据确定预测统计项并预测次日预测充电量,使设备具备了预测未来补能状况的能力;进而根据次日预测充电量以及当日天气数据计算天气调整量,使得天气调整量能够综合反映基于当日天气情况和次日天气情况对充电的综合影响,最终根据基础阈值和天气调整量确定目标常电阈值,该目标常电阈值既保留了长期策略的稳定性,又具备了对未来天气变化的快速响应能力。如此,本申请实施例可以更好地实现太阳能供电设备功耗模式的自适应动态优化控制,提高对供电设备的功耗控制的准确性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122823670A_ABST
    Figure CN122823670A_ABST
Patent Text Reader

Abstract

The application provides a power consumption control method and device of a power supply equipment, equipment and a storage medium, and belongs to the technical field of power consumption control of the power supply equipment. The method comprises the following steps: acquiring daily charging data and weather forecast data of the solar power supply equipment; updating a basic threshold according to a comparison result of a daily maximum power and a preset full power; determining a target statistical item from a charging self-learning model according to daily weather data; performing asymmetric updating on charging sample statistical values and non-full sample statistical values in the target statistical item according to the comparison result; predicting a next-day charging capacity according to a predicted statistical item determined from the model according to next-day weather data; obtaining a weather adjustment amount according to a next-day predicted charging amount, next-day weather data and daily weather data; and determining a target normal power threshold according to the basic threshold and the weather adjustment amount, so as to control the solar power supply equipment to switch between a normal power mode and a power saving mode. The embodiment of the application can improve the accuracy of power consumption control of the power supply equipment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of power consumption control technology for power supply equipment, and in particular to a power consumption control method, apparatus, device, and storage medium for power supply equipment. Background Technology

[0002] Solar-powered cameras, doorbells, environmental sensors, communication gateways, and other low-power terminals typically rely on solar panels for supplemental power in addition to battery power. These devices usually support a constant power mode and a power-saving mode. In constant power mode, the device can provide higher network frequency and a more complete functional experience, while in power-saving mode, the device reduces processing or network frequency to extend battery life. To balance battery life and performance, related technologies usually set a battery level threshold. When the battery level is above this threshold, it enters constant power mode; when it is below the threshold, it enters power-saving mode. This threshold is dynamically adjusted based on historical charging results to achieve power consumption control of the powered device.

[0003] However, the methods used in these technologies rely solely on fixed threshold values ​​for mode adjustment, which cannot be flexibly applied to different power supply devices with varying charging capabilities, thereby reducing the accuracy of power consumption control for the power supply devices. Summary of the Invention

[0004] The main objective of this application is to propose a power consumption control method, apparatus, device, and storage medium for power supply equipment, which can be flexibly applied to different power supply equipment with different charging capabilities, thereby improving the accuracy of power consumption control for power supply equipment.

[0005] To achieve the above objectives, a first aspect of this application proposes a power consumption control method for a power supply device, applied to a solar power supply device, the method comprising: The system acquires the daily charging data and weather forecast data of the solar power supply device within a preset statistical period. The weather forecast data includes the weather data for the current day and the weather data for the next day. The daily charging data includes the highest daily power consumption. The base threshold is updated based on the comparison between the highest daily power consumption and the preset fully charged power consumption. The base threshold is used to characterize the power consumption benchmark for controlling the solar power supply device to switch between constant power mode and power saving mode without considering weather factors. The target statistical item is determined from the preset charging self-learning model based on the weather data of the day. The charging self-learning model includes multiple statistical items classified according to weather type and sunshine level. Based on the comparison between the highest battery level of the day and the preset fully charged battery level, perform asymmetric updates on the charging sample statistics and the incompletely charged sample statistics in the target statistics item; Based on the next day's weather data, predictive statistics are determined from the charging self-learning model, and the next day's charging capacity is predicted based on the predictive statistics. The next day's charging capacity includes the next day's predicted charging amount. Based on the predicted charging amount for the next day, the weather data for the next day, and the weather data for the current day, a weather adjustment amount is calculated. The weather adjustment amount is used to characterize the degree of influence of the weather change for the next day on the power consumption control for the current day. The target constant power threshold is determined based on the base threshold and the weather adjustment amount, and the solar power supply equipment is controlled to switch between the constant power mode and the power saving mode based on the target constant power threshold.

[0006] To achieve the above objectives, a second aspect of this application provides a power consumption control device for a power supply device, the device comprising: The acquisition module is used to acquire the daily charging data and weather forecast data of the solar power supply equipment within a preset statistical period. The weather forecast data includes the weather data of the current day and the weather data of the next day, and the daily charging data includes the highest power consumption of the day. The threshold update module is used to update the base threshold based on the comparison result between the highest power consumption of the day and the preset fully charged power consumption. The base threshold is used to characterize the power consumption benchmark for controlling the solar power supply equipment to switch between constant power mode and power saving mode without considering weather factors. The statistical item determination module is used to determine target statistical items from a preset charging self-learning model based on the weather data of the day. The charging self-learning model includes multiple statistical items classified according to weather type and sunshine level. The numerical update module is used to perform asymmetric updates on the charging sample statistics and the incompletely charged sample statistics in the target statistics item based on the comparison result between the highest battery level of the day and the preset fully charged battery level. The capacity prediction module is used to determine prediction statistics from the charging self-learning model based on the next day's weather data, and to predict the next day's charging capacity based on the prediction statistics, wherein the next day's charging capacity includes the next day's predicted charging amount. The adjustment amount calculation module is used to calculate the weather adjustment amount based on the next day's predicted charging amount, the next day's weather data, and the current day's weather data. The weather adjustment amount is used to characterize the degree of influence of the next day's weather changes on the current day's power consumption control. The mode switching module is used to determine a target constant power threshold based on the base threshold and the weather adjustment amount, and to control the solar power supply equipment to switch between the constant power mode and the power saving mode based on the target constant power threshold.

[0007] To achieve the above objectives, a third aspect of the present application provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the method described in any one of the embodiments of the first aspect.

[0008] To achieve the above objectives, a fourth aspect of the present application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method described in any one of the embodiments of the first aspect.

[0009] The power consumption control method, apparatus, device, and storage medium for power supply equipment proposed in this application update a basic threshold based on the comparison between the highest daily power consumption and the preset fully charged power consumption. This ensures that the basic threshold is constantly and slowly adjusted according to the recent charging performance of the device, forming a long-term understanding of its own charging capabilities. By determining target statistical items from a charging self-learning model categorized by weather type and sunshine level based on the daily weather data, and performing asymmetric updates on the statistical values ​​of charging samples and incompletely charged samples, the method ensures that when the device reaches full charge on a given day, only the number of full charge cycles is increased without recording the power increment after being truncated by the battery capacity limit. This avoids the distortion of learning samples caused by full charge truncation. When the device is not fully charged, the average incompletely charged power consumption is updated based on the actual charging amount, ensuring the accuracy of charging amount statistics in incompletely charged scenarios. Based on the next day's weather data, predictive statistics are determined and the predicted charging amount for the next day is predicted, enabling the equipment to predict future charging conditions. Then, based on the predicted charging amount for the next day and the current day's weather data, a weather adjustment is calculated. This weather adjustment comprehensively reflects the combined impact of the current and next day's weather conditions on charging. Finally, a target constant power threshold is determined based on a base threshold and the weather adjustment. This target constant power threshold maintains the stability of the long-term strategy while also possessing a rapid response capability to future weather changes. Thus, the embodiments of this application can better achieve adaptive dynamic optimization control of the power consumption mode of solar power supply equipment, improving the accuracy of power consumption control for the power supply equipment. Attached Figure Description

[0010] Figure 1 This is a flowchart of a power consumption control method for a power supply device provided in an embodiment of this application; Figure 2 This is a schematic diagram of a process for updating the basic threshold provided in an embodiment of this application; Figure 3 This is a schematic diagram of a data structure of the charging self-learning model provided in an embodiment of this application; Figure 4 This is a flowchart of the process for predicting the charging speed level for the next day, provided in an embodiment of this application. Figure 5This is a schematic diagram of a process for splitting and updating full and incomplete samples according to an embodiment of this application; Figure 6 This is a flowchart illustrating the next-day charging capacity prediction provided in an embodiment of this application; Figure 7 This is a schematic diagram of a process for calculating weather adjustment amount and switching modes provided in an embodiment of this application; Figure 8 This is a schematic diagram of a power consumption control device for a power supply equipment provided in an embodiment of this application; Figure 9 This is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0011] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0012] It should be noted that although functional modules are divided in the device schematic diagram and a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart. The terms "first," "second," etc., used in the specification, claims, and the foregoing drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.

[0013] Solar-powered cameras, doorbells, environmental sensors, communication gateways, and other low-power terminal devices typically rely on solar panels for supplementary power in addition to battery power. These devices often support both constant-power and power-saving modes. In constant-power mode, the device can provide higher networking frequencies, lower service latency, or a more complete functional experience; for example, a camera can maintain real-time video streaming and high-definition image quality in constant-power mode. In power-saving mode, the device extends battery life by reducing processing frequency, sampling frequency, or networking frequency; for example, a camera can reduce the frame rate or use an event-triggered wake-up mechanism in power-saving mode. The core power management challenge for these devices is maximizing the runtime of constant-power mode without depleting the battery.

[0014] To strike a balance between battery life and performance, existing solutions typically set a battery level threshold. When the battery level is above this threshold, the device enters a constant power mode to provide a full experience; when the battery level is below the threshold, the device switches to a power-saving mode to conserve power. Within this framework, dynamically adjusting this threshold becomes crucial. In existing technologies, a typical threshold adjustment scheme adjusts the threshold based on whether the device reached a full charge in the previous statistical period. If it was fully charged the previous day, the threshold is appropriately lowered, allowing the device to maintain constant power mode at lower battery levels; if it wasn't fully charged the previous day, the threshold is raised, causing the device to enter power-saving mode earlier to conserve power. Another approach is to directly use historical battery level data for linear regression or mean prediction to estimate the future charging capacity and adjust the threshold accordingly.

[0015] However, the existing solutions described above have the following technical drawbacks during implementation: Firstly, the response speed to future weather changes is slow. Because the current solution relies solely on historical charging results to adjust thresholds, it cannot predict future weather trends. If continuous rain is expected the next day, the device may still maintain a low threshold due to sufficient charging the previous day, leading to excessive power consumption today and subsequent depletion of power. Conversely, if the next day is sunny, the device cannot anticipate this and appropriately relax the power consumption limit for the day, missing the opportunity to improve the user experience under predictable charging conditions.

[0016] Secondly, there are significant differences in individual charging capabilities between different devices. The installation location, orientation, surrounding obstructions, and the conversion efficiency of the solar panels themselves vary considerably. Under the same weather conditions, the actual charging capabilities of different devices can differ by several times. A uniform set of rules is difficult to adapt to the individual circumstances of each device, and some devices experience frequent power outages or are unable to enter constant power mode for extended periods due to improper threshold settings.

[0017] Third, when the device reaches full charge early in the day, the battery power is cut off by the upper limit of the battery's physical capacity, and the solar power generation in the following hours cannot be recorded and stored. If the daily power increment (i.e., full charge minus initial charge) is directly used as the learning sample, the actual charging capacity of the device under that weather condition will be seriously underestimated, resulting in a consistently conservative threshold prediction and reducing the available time of the constant power mode.

[0018] Fourth, even if all devices are predicted to be fully charged the next day, the speed at which they reach full charge under actual lighting conditions can vary drastically. For devices with extremely fast charging speeds, even a lower battery level on the first day can be quickly recharged the next day, allowing for more efficient use of electricity that day. However, for devices with slower charging speeds, even if they can barely be fully charged the next day, they need to enter power-saving mode earlier to allow sufficient charging time. Existing binary judgments based on whether a device is fully charged are insufficient to distinguish between these scenarios.

[0019] Therefore, the methods used in the relevant technologies cannot be flexibly applied to different power supply devices with different charging capabilities, thereby reducing the accuracy of power consumption control for power supply devices.

[0020] Based on this, embodiments of this application provide a power consumption control method, apparatus, device, and storage medium for power supply equipment, which can be flexibly applied to different power supply equipment with different charging capabilities, thereby improving the accuracy of power consumption control for power supply equipment.

[0021] This application's embodiments can acquire and process relevant data based on artificial intelligence (AI) technology. AI is the theory, methods, technology, and application system that uses digital computers or computers-controlled machines to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results. Basic AI technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing technology, operating / interactive systems, and mechatronics. AI software technologies mainly include computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.

[0022] The power consumption control method for power supply equipment provided in this application relates to the field of power consumption control technology for power supply equipment. The power consumption control method for power supply equipment provided in this application can be applied to a terminal, a server, or software running on either a terminal or a server. In some embodiments, the terminal can be a smartphone, tablet, laptop, desktop computer, etc.; the server can be configured as an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms; the software can be an application implementing the power consumption control method for power supply equipment, but is not limited to the above forms.

[0023] This application can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics devices, network personal computers (PCs), minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This application can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0024] Please see Figure 1 , Figure 1 This is a flowchart of a power consumption control method for a power supply device provided in an embodiment of this application. In some embodiments of this application, Figure 1 The method described below may include, but is not limited to, steps S110 to S170. Figure 1 These seven steps will be explained in detail.

[0025] Step S110: Obtain the daily charging data and weather forecast data of the solar power supply equipment within a preset statistical period. The weather forecast data includes the weather data of the current day and the weather data of the next day. The daily charging data includes the highest power consumption of the day. Step S120: Update the basic threshold based on the comparison between the highest battery level of the day and the preset fully charged battery level; Step S130: Determine the target statistical item from the preset charging self-learning model based on the weather data of the day. The charging self-learning model includes multiple statistical items divided according to weather type and sunshine level. Step S140: Based on the comparison results between the highest battery level of the day and the preset fully charged battery level, perform asymmetric updates on the charging sample statistics and the incompletely charged sample statistics in the target statistics item. Step S150: Determine the prediction statistics from the charging self-learning model based on the weather data of the next day, and predict the charging capacity of the next day based on the prediction statistics. The charging capacity of the next day includes the predicted charging amount of the next day. Step S160: Calculate the weather adjustment amount based on the predicted charging amount for the next day, the weather data for the next day, and the weather data for the current day. Step S170: Determine the target constant power threshold based on the basic threshold and the weather adjustment amount, and control the solar power supply equipment to switch between constant power mode and power saving mode based on the target constant power threshold.

[0026] It should be noted that the power consumption control method for power supply equipment provided in this application embodiment can be specifically applied to solar power supply equipment. This solar power supply equipment refers to electronic devices that are powered by solar panels, including but not limited to solar-powered cameras, solar doorbells, communication gateways, environmental monitoring equipment, or other terminal devices that simultaneously support constant power mode and power-saving mode. The solar power supply equipment may include at least a processor, memory, battery, solar charging module, charging detection module, communication module, and load control module. The processor is used to execute a threshold control program; the memory is used to store weather forecast data, a charging self-learning model, and configuration parameters; the charging detection module is used to collect charging voltage, charging current, and battery power; and the load control module is used to switch service load strategies according to the target constant power threshold.

[0027] In step S110 of some embodiments, the preset statistical period refers to the time window used to calculate the charging performance of the day and update the basic threshold and the charging self-learning model. In one embodiment, the preset statistical period can be a natural day, i.e., from 0:00 to 24:00 every day. In another embodiment, the preset statistical period can also be the most recent 7 days, 15 days, or 30 days, used to build and update the rolling historical window of the charging self-learning model. Daily charging data refers to the charging-related data collected by the solar power supply device within the current preset statistical period. Daily charging data can specifically include the highest daily charge, the charge at the previous statistical time, and the first time reached. The highest daily charge refers to the highest value reached by the battery charge within the current statistical period, expressed as a percentage. For example, a highest daily charge of 92% means that the battery charge reached 92% of its rated capacity on this day. The charge at the previous statistical time refers to the battery charge recorded at the preset statistical time of the previous natural day. For example, if the preset statistical time is 20:00 every day, then the charge at the previous statistical time is the battery charge recorded at 20:00 yesterday. The first time reached refers to the moment when the battery charge first reaches the preset full charge on this day, which can be expressed as a specific time point. In another implementation, the first arrival time can also be represented by the offset time relative to 0:00 of the day.

[0028] The preset full charge level refers to the target charge threshold used to determine whether the solar power equipment is considered fully charged for the day. The preset full charge level does not necessarily equal the upper limit of the battery's physical capacity (100%), but can be a threshold set according to actual needs. In one embodiment, the preset full charge level can be set to 95%, meaning that the equipment is considered fully charged when the highest charge level reaches or exceeds 95%. In another embodiment, the preset full charge level can be set to 98%, 99%, or 100%.

[0029] Weather forecast data refers to future weather information for the location of the solar-powered equipment. Weather forecast data can include at least the weather data for the current day, the weather data for the next day, the sunshine duration for the current day, and / or the sunshine duration for the next day. The current day's weather data refers to weather-related information for that day, which may include the weather type for that day. The next day's weather data refers to weather-related information for the following day, which may include the weather type for the next day. Weather type refers to a classification of weather conditions, which may include, but is not limited to, sunny, cloudy, overcast, rainy, and snowy. In specific deployment areas, weather types may also be extended to fog, dust storms, or other types. Weather types can be represented by numerical codes, such as 0 for sunny, 1 for cloudy, 2 for overcast, 3 for rain, and 4 for snow, without limitation. Sunshine duration refers to the length of time the sun shines during the day, usually measured in hours. Sunshine duration can be obtained through weather forecast services or calculated based on sunrise and sunset times and cloud cover information.

[0030] In some embodiments, weather forecast data is obtained as follows: the solar-powered device can report its location information to a server via a communication module; the server can then query weather services based on the location information to obtain weather forecast data; the server then distributes the weather forecast data to the solar-powered device. In another embodiment, the solar-powered device can also directly access network weather services to obtain weather forecast data via its built-in communication module, without needing to go through a server. The server can cache weather forecast data by region, and multiple solar-powered devices within the same region can share the weather forecast data. The solar-powered device can cache the received weather forecast data in local non-volatile memory for use in case of communication failure.

[0031] In step S120 of some embodiments, a base threshold is used to characterize the power reference for controlling the switching between constant power mode and power saving mode of the solar-powered device without considering weather factors. The base threshold is a percentage value; for example, a base threshold of 85% means that, without considering weather factors, the device should be in or enter constant power mode when the battery level is above 85%, and in or enter power saving mode when the battery level is below 85%. The base threshold is a long-term memory and accumulation of the device's historical charging capacity, and can be gradually adjusted as the number of days the device operates increases.

[0032] In some embodiments, the initial value of the base threshold can be set to 85%. In another embodiment, the initial value of the base threshold can be set to 90% or 80%. The base threshold can also have a preset base threshold range, that is, the base threshold is limited to a certain upper and lower limit. For example, the lower limit of the base threshold can be set to 70%, and the upper limit can be set to 95%, that is, the base threshold is always kept in the range of 70% to 95%.

[0033] In some embodiments, step S120 may specifically include, but is not limited to, the following steps: If the highest battery level of the day is greater than or equal to the preset full charge level, the reduction value is determined based on the comparison between the first time the battery level is reached and the preset time point, and the basic threshold is updated according to the reduction value. If the highest battery level of the day is less than the preset full charge level, the basic threshold is updated based on the difference between the preset full charge level and the highest battery level of the day.

[0034] If the highest daily battery level is greater than or equal to the preset full charge level, it indicates that the device has reached a full charge state that day, signifying good charging conditions. In this case, a reduction margin can be determined based on the comparison between the first full charge time and the preset time point, and the base threshold is updated accordingly, allowing the device to maintain a constant power mode at lower battery levels. The preset time points include a first time point, a second time point, and a third time point, with the first time point earlier than the second time point, and the second time point earlier than the third time point. For example, the first, second, and third time points can be set to 9:00, 11:00, and 14:00, respectively. It should be noted that the specific values ​​of the above time points are only examples and can be adjusted according to device type, deployment region (different latitudes result in different sunrise and sunset times), and season in actual applications. For example, in high-latitude regions during winter, the first time point can be adjusted to 10:00. Specifically, if the first full charge time is earlier than the first time point (e.g., before 9:00), it indicates that the device has already reached a full charge in the morning, with excellent charging conditions. In this case, the base threshold is reduced according to the first reduction margin, which is, for example, 4%. If the first charging time falls between the first and second time points (e.g., between 9:00 and 11:00), it indicates the device was fully charged during the morning hours, and charging conditions are good. In this case, the base threshold is reduced by the second reduction rate, for example, 3%. If the first charging time falls between the second and third time points (e.g., between 11:00 and 14:00), it indicates the device was fully charged during the midday hours, and charging conditions are acceptable. In this case, the base threshold is reduced by the third reduction rate, for example, 2%. If the first charging time is later than the third time point (e.g., after 14:00), it indicates the device was fully charged late in the afternoon, and charging conditions are average. In this case, the base threshold is reduced by the fourth reduction rate, for example, 1%.

[0035] It should be noted that the first reduction magnitude is greater than the second reduction magnitude, the second reduction magnitude is greater than the third reduction magnitude, and the third reduction magnitude is greater than or equal to the fourth reduction magnitude. That is, the earlier the battery is fully charged, the greater the reduction magnitude, indicating a stronger charging capability of the device under those weather conditions, thus allowing it to maintain a constant power mode at lower battery levels. The specific values ​​of each reduction magnitude can be adjusted according to the actual application scenario. For example, in scenarios where charging capabilities are generally strong, the overall reduction magnitude values ​​can be increased; in scenarios where charging capabilities are generally weak, the overall reduction magnitude values ​​can be decreased. The value after reducing the base threshold should not be lower than the lower limit of the preset base threshold range. For example, if the preset lower limit of the base threshold is 70%, and the value after reducing the base threshold is lower than 70%, the base threshold should be set to 70%.

[0036] If the highest battery level of the day is less than the preset full charge level, it indicates that the device has not reached a full charge state that day, suggesting poor charging conditions or excessive power consumption. In this case, the base threshold can be increased based on the difference between the preset full charge level and the highest battery level of the day, allowing the device to enter power-saving mode earlier to conserve battery power. Specifically, this application embodiment can calculate the difference between the preset full charge level and the highest battery level of the day, reflecting the gap between the device's state and its full charge state on that day. For example, if the preset full charge level is 95% and the highest battery level of the day is 87%, the difference is 8%. In one embodiment, this application can use this difference as an increase to update the base threshold; for example, if the base threshold is 85% and the difference is 8%, the updated base threshold is 93%. In another embodiment, this application can determine different increase ranges based on the range of the difference. For example, if the difference is less than 5% (i.e., the highest battery level of the day is above 90%), it indicates that the charging conditions are acceptable, and the increase is 2%; if the difference is between 5% and 10% (i.e., the highest battery level of the day is between 85% and 90%), it indicates that the charging conditions are average, and the increase is 5%; if the difference is greater than 10% (i.e., the highest battery level of the day is below 85%), it indicates that the charging conditions are poor, and the increase is 8%. By increasing the value in stages, the adjustment range of the base threshold can be controlled more precisely. In another embodiment, this application can also use a portion of the difference as the increase amount, such as 50% or 80% of the difference. Regardless of the increase method used, the value of the base threshold after the increase should not exceed the upper limit of the preset base threshold range. For example, if the preset upper limit of the base threshold is 95%, and the value exceeds 95% after the base threshold is increased, the base threshold is set to 95%.

[0037] In some embodiments, when abnormal power consumption of the solar-powered equipment is detected, the base threshold can be set to a preset protection threshold (e.g., 95%). Abnormal power consumption includes, but is not limited to: the device being abnormally woken up at night (which can be determined by detecting the wake-up frequency and wake-up time), the average power consumption per unit time being significantly higher than the historical average (e.g., more than 1.5 times the historical average), and a certain business module being abnormally persistent (e.g., a functional module failing to hibernate normally due to a software bug). Under abnormal power consumption conditions, the device faces a higher risk of power consumption, therefore, the base threshold needs to be set to a higher protection value so that the device enters power-saving mode when the power consumption is high, prioritizing the continuous operation of the device.

[0038] In some embodiments, a limiting process is performed on the updated base threshold to ensure that the base threshold always remains within a preset base threshold range. The lower limit of the preset base threshold range can be 70%, and the upper limit can be 95%, meaning that the value of the base threshold is restricted to between 70% and 95%. The limiting process ensures that the base threshold does not deviate from a reasonable range due to over-adjustment, maintaining the stability of the threshold control system.

[0039] In some embodiments, when abnormal power consumption of the solar-powered device is detected, a base threshold can be set as a preset protection threshold. Abnormal power consumption includes, but is not limited to: abnormal wake-up at night, average power consumption per unit time significantly higher than historical levels, and abnormal persistent operation of business modules. The preset protection threshold is a relatively high power threshold, such as 95%, used to prioritize power protection during abnormal power consumption and prevent the device from shutting down due to abnormal power consumption. In another embodiment, abnormal power consumption can be detected by monitoring the average current of the device. If the average current for multiple consecutive statistical periods exceeds 1.5 times the normal value, it is determined to be abnormal power consumption.

[0040] In some embodiments, the updated base threshold can also be subjected to a limiting process to keep the base threshold within a preset base threshold range. For example, if the preset base threshold range is 70% to 95%, when the calculated base threshold is lower than 70%, the base threshold is set to 70%; when the calculated base threshold is higher than 95%, the base threshold is set to 95%.

[0041] In the above embodiments, this application achieves a refined evaluation of the device's charging capability by determining different reduction rates based on the time of the first full charge when the highest daily charge is greater than or equal to the preset full charge (the earlier the full charge is reached, the greater the reduction rate). This ensures that the threshold adjustment range matches the quality of the charging conditions and avoids over-adjustment or under-adjustment problems caused by uniform adjustment.

[0042] Reference Figure 2 , Figure 2This is a flowchart illustrating the updating of the basic threshold provided in this application embodiment. The basic threshold update process begins by reading the charging data for the day. After reading the data, this application embodiment first determines whether the highest battery level of the day is greater than or equal to the preset full charge level. If yes, it indicates that the device has reached a full charge level for the day, and the charging conditions are good. The basic threshold is then reduced according to the time when the preset full charge level was first reached, based on the corresponding reduction range from the first to the fourth preset reduction range. The earlier the first full charge time, the larger the selected reduction range, indicating stronger charging capability of the device under those weather conditions, allowing it to maintain a constant power mode at lower battery levels. If no, it indicates that the device has not reached a full charge level for the day, and the charging conditions are insufficient or power consumption is high. The basic threshold is then increased based on the difference between the preset full charge level and the highest battery level of the day. The larger the difference, the larger the increase, so that the device enters power-saving mode earlier to protect battery power. After completing the above threshold adjustment based on charging performance, the device is further checked for abnormal power consumption. If yes, the basic threshold is set to a preset protection threshold (e.g., 95%) to prioritize the device's continued operation during abnormal power consumption. If no, the aforementioned update result based on charging performance is maintained, and the protection threshold is not triggered. Finally, the baseline threshold is subjected to a limiting process to be restricted to a preset baseline threshold range (e.g., 70% to 95%), and the updated baseline threshold is output as the basis component for subsequent calculation of the target constant voltage threshold.

[0043] In step S130 of some embodiments, the charging self-learning model refers to a statistical data structure, categorized by weather type and sunshine level, used to record the historical charging performance of solar power equipment under different weather conditions. The charging self-learning model can include multiple statistical items categorized by weather type and sunshine level. The sunshine level is a classification based on sunshine duration; for example, 0 hours of sunshine indicates no sunshine, sunshine duration greater than 0 hours and less than or equal to 3 hours indicates low sunshine, sunshine duration greater than 3 hours and less than or equal to 6 hours indicates moderate sunshine, sunshine duration greater than 6 hours and less than or equal to 9 hours indicates high sunshine, and sunshine duration greater than 9 hours indicates extremely high sunshine. It should be noted that the threshold for sunshine level classification can also be adjusted according to the latitude and season of the equipment deployment area. Each combination of weather type and sunshine level corresponds to an independent statistical item; for example, "sunny + high sunshine" corresponds to one statistical item, and "cloudy + moderate sunshine" corresponds to another.

[0044] Each statistical item includes, but is not limited to, the following statistical values: charging sample statistics and incompletely charged sample statistics. Charging sample statistics record the number of times the device reached a fully charged state under corresponding weather conditions, including, for example, the number of times it reached a fully charged state on a given day (or, in a historical statistical context, the predicted number of fully charged states). Incompletely charged sample statistics record the charging amount and the number of times the device did not reach a fully charged state under corresponding weather conditions, including, for example, the cumulative incompletely charged amount on a given day, the number of incompletely charged instances on a given day, and the average incompletely charged amount on a given day. All statistical items maintain a consistent field structure but are independent of each other in terms of statistical values ​​to reflect the actual charging performance of the device under different weather and sunshine conditions.

[0045] The target statistical item refers to the statistical item in the self-learning charging model that matches the weather data of the day. Specifically, based on the weather type and sunshine level of the day (or the sunshine level is determined based on the weather type and sunshine duration), the target statistical item is selected from multiple statistical items in the self-learning charging model. For example, if the weather is sunny and the sunshine duration is 8 hours (high sunshine), the target statistical item is the statistical item corresponding to "sunny + high sunshine".

[0046] For example, such as Figure 3 The diagram shown illustrates a data structure of the charging self-learning model provided in this embodiment. The charging self-learning model can be implemented using a two-dimensional statistical table, with one dimension representing weather type and the other representing sunshine level. Each combination of weather type and sunshine level corresponds to an independent statistical item. The statistical items maintain a consistent field structure (including fields such as weather type index, sunshine type index, number of full charge attempts, cumulative charging amount before full charge, number of times before full charge, average charging amount before full charge, cumulative peak charging power, number of power records, and average peak charging power). However, the statistical values ​​of each item are independent, thus enabling the recording of the device's historical charging performance under different weather and sunshine conditions. The core feature of this model is that each solar power device maintains its own independent charging self-learning model. As the number of operating days increases, whenever a preset statistical time arrives, the device locates the corresponding statistical item based on the actual weather type and sunshine level of the day, and updates the statistical value of the number of full charges or the relevant statistical value of not being fully charged based on whether the preset full charge capacity has been reached that day, so that the model can continuously accumulate historical data. When predicting the charging capacity of the next day, the corresponding prediction statistical item is located based on the weather type and sunshine level of the next day, and the statistical values ​​such as the number of full charges, the average charging amount of not fully charged, and the average peak charging power are read to calculate the predicted charging amount and the charging speed level of the next day, providing personalized historical data basis for the calculation of subsequent weather adjustment.

[0047] It should be noted that the charging self-learning model in this application embodiment can be saved to non-volatile memory. The persistent file of the charging self-learning model includes a file header and a data area. The file header includes a magic number, version number, data size, and checksum. When the electronic device starts up, the persistent file is checked based on the magic number, version number, data size, and checksum. If the checksum fails, the charging self-learning model is cleared.

[0048] In step S140 of some embodiments, asymmetric updating refers to using different update strategies for the statistical values ​​of charged samples and those of incompletely charged samples. Specifically, it is processed separately based on whether a preset full charge level has been reached on that day. The core purpose of this asymmetric processing is to avoid contaminating the estimation of charging capacity by cutting off charging at full charge.

[0049] It should be noted that the charging sample statistics include the number of full charges per day. The number of full charges per day refers to the historical number of times the device reached the preset full charge level under the corresponding weather and sunshine conditions, as recorded in the target statistical item. The number of full charges per day is a cumulative value, initially 0, incremented by 1 each time a full charge sample is encountered. In prediction, this value is called the predicted number of full charges. The incomplete charge sample statistics include the cumulative incomplete charge amount per day, the number of incomplete charges per day, and the average incomplete charge amount per day. The cumulative incomplete charge amount per day refers to the total charge amount recorded in the target statistical item when the device did not reach the preset full charge level under the corresponding weather and sunshine conditions. The number of incomplete charges per day refers to the historical number of times the device did not reach the preset full charge level under the corresponding weather and sunshine conditions, as recorded in the target statistical item. The average incomplete charge amount per day refers to the average charge amount recorded in the target statistical item when the device did not reach the preset full charge level under the corresponding weather and sunshine conditions, and its value is the cumulative incomplete charge amount per day divided by the number of incomplete charges per day.

[0050] In some embodiments, step S140 may specifically include, but is not limited to, the following steps: If the highest battery capacity of the day is greater than or equal to the preset full charge capacity, the number of full charge counts for the day will be incremented by 1, and the cumulative charge amount that is not fully charged, the number of times that is not fully charged, and the average charge amount that is not fully charged for the day will remain unchanged. If the highest battery level of the day is less than the preset full charge level, the actual charge amount of the day is determined based on the difference between the highest battery level of the day and the battery level at the previous statistical time. The actual charge amount of the day is added to the cumulative charge amount that is not fully charged on the day, the number of times it is not fully charged is incremented by 1, and the average charge amount that is not fully charged on the day is updated based on the ratio of the updated cumulative charge amount that is not fully charged on the day to the updated number of times it is not fully charged on the day.

[0051] If the highest daily charge is greater than or equal to the preset full charge, it indicates that the device has reached the preset full charge for the day, forming a full charge sample. At this point, the charging sample statistics can be updated by incrementing the daily full charge count in the target statistics by 1. However, the average charge amount not fully charged in the target statistics is not updated based on the daily charge increment. That is, the statistics for the not fully charged sample remain unchanged; the daily cumulative charge amount not fully charged, the daily number of not fully charged attempts, and the daily average charge amount not fully charged all remain unchanged. These values ​​are not updated in the statistics for the full charge sample. The technical significance of this approach is that when the device reaches full charge early in the day, the actual recorded battery charge increment is truncated by the battery's physical capacity limit, and subsequent solar power generation cannot be stored because the battery is already full. If this truncated charge increment (e.g., only recording 20% ​​from 80% to 100%) is used to update the average charge amount not fully charged, it will severely underestimate the device's true charging capacity under those weather conditions. By updating only the full charge count, the truncated charge data is avoided from contaminating the quantitative statistics, thereby improving the accuracy of charging capacity estimation.

[0052] If the highest battery level of the day is less than the preset full charge level, it means that the device has not reached the preset full charge level for the day, forming an incomplete charge sample. In this case, the actual charging amount for the day can be determined based on the difference between the highest battery level of the day and the battery level at the previous statistical time. The method for determining the actual charging amount for the day is as follows: calculate the difference between the highest battery level of the day and the battery level at the previous statistical time. If the difference is greater than 0, the difference is determined as the actual charging amount for the day; if the difference is not greater than 0, the actual charging amount for the day is determined as 0. Specifically, this can be expressed by the formula: Actual charging amount for the day = max(0, highest battery level of the day - battery level at the previous statistical time). After determining the actual charging amount for the day, this embodiment can update the statistical value of the incomplete charge sample: add the actual charging amount for the day to the cumulative incomplete charge amount for the day in the target statistical item; add 1 to the number of times the device has not been fully charged for the day in the target statistical item; update the average incomplete charge amount for the day based on the ratio of the updated cumulative incomplete charge amount for the day to the updated number of times the device has not been fully charged for the day. This asymmetric update method can employ differentiated statistical update strategies for fully charged and partially charged samples, avoiding the contamination of charging capacity estimation by full-charge truncation, while retaining sample counts to support subsequent prediction decisions.

[0053] In the above embodiments, this application fundamentally avoids the problem of underestimating charging capacity caused by full-charge cutoff by simply incrementing the number of full-charges by 1 when the preset full-charge capacity is reached on the same day without updating the statistical value related to incomplete full-charge. By calculating the actual charging amount for the day based on the difference between the power at the previous statistical time and the highest power at the same day when the preset full-charge capacity is not reached on the same day, and updating the average charging amount for incomplete full-charge, this ensures that the statistical value of incomplete full-charge samples can truly reflect the device's ability to replenish energy when it is not fully charged, providing an accurate quantitative basis for subsequent prediction.

[0054] In step S150 of some embodiments, the predicted statistical item refers to the statistical item in the charging self-learning model that matches the weather data of the next day. Specifically, in the embodiments of this application, the corresponding statistical item can be found from multiple statistical items in the charging self-learning model based on the weather type and sunshine level of the next day (or the sunshine level can be determined based on the weather type and sunshine duration of the next day) in the weather data of the next day, and determined as the predicted statistical item. The predicted statistical item is not a part of the data in the target statistical item, but an independent statistical item in the charging self-learning model corresponding to "weather type of the next day + sunshine level of the next day". In implementation, a mapping rule between weather type and sunshine level can be established in advance, and the predicted statistical item can be obtained by indexing from the two-dimensional statistical table according to the mapping rule.

[0055] Next-day charging capability includes the predicted next-day charging amount and the next-day charging speed rating. Next-day charging capability refers to the charging performance that the device is likely to achieve under the next day's weather conditions, predicted based on historical statistical information. The predicted next-day charging amount is a percentage or indicator value used to represent the increase in power the device can obtain the next day or whether it can be fully charged. The next-day charging speed rating is a rating indicating how fast the device charges the next day.

[0056] In some embodiments, the process of predicting the next day's charging amount may specifically include the following steps: If the predicted number of full charge times in the prediction statistics item is greater than or equal to the threshold of the first number, the predicted charging amount for the next day will be determined as the preset full charge indicator value. The preset full charge indicator value is used to indicate that the battery capacity can reach the preset full charge capacity on the next day. If the predicted number of times to fully charge is less than the threshold of the first count and the predicted number of times not fully charged in the prediction statistics is greater than or equal to the threshold of the second count, the average amount of the predicted amount of not fully charged in the prediction statistics will be determined as the predicted amount of charging for the next day. If the predicted number of full charge attempts is less than the first threshold and the number of incomplete charge attempts is less than the second threshold, the predicted charging amount for the next day is determined based on the weather data for the next day and the preset mapping table.

[0057] The predicted number of full-charge attempts refers to the number of times the device has historically reached a preset full charge under the corresponding weather and sunshine conditions. The first count threshold is a preset threshold, such as 3 times. When the predicted number of full-charge attempts reaches or exceeds 3, it indicates that the device has historically been successfully fully charged multiple times under those weather and sunshine conditions, demonstrating a high confidence level. In this case, the predicted charge amount for the next day can be determined as the preset full-charge indicator value. The preset full-charge indicator value is a logical identifier value used to characterize that the battery capacity can reach the preset full charge level the next day. The preset full-charge indicator value can be a specific numerical value, such as 100%, or a special encoded value, such as 0xFFFF or -1. When historical data shows that the device has successfully fully charged multiple times under the same weather conditions, there is reason to believe that it will also be fully charged the next day. The more full-charge attempts, the higher the confidence level of the prediction.

[0058] The predicted number of times the device failed to fully charge refers to the number of times it failed to fully charge as recorded in the prediction statistics item, i.e., the number of times the device failed to reach the preset full charge level under the corresponding weather and sunshine conditions. The second threshold is a preset threshold used to determine whether the sample of devices that failed to fully charge has statistical significance, for example, 3 times. When the predicted number of times the device failed to fully charge is insufficient to determine whether it can be fully charged (less than the first threshold), but the predicted number of times the device failed to fully charge reaches or exceeds the second threshold, it indicates that the device has failed to fully charge multiple times in the past under the weather and sunshine conditions, but has accumulated enough sample data of devices that failed to fully charge. Therefore, the sample of devices that failed to fully charge is considered to be statistically representative, and the average charge amount that failed to fully charge can be used as the prediction value. In this case, the predicted average charge amount that failed to fully charge in the prediction statistics item is determined as the predicted charge amount for the next day. The predicted average charge amount that failed to fully charge reflects the average amount of electricity that the device can replenish when it fails to fully charge under the weather conditions. For example, if the predicted average charge amount that failed to fully charge is 15%, then the predicted charge amount for the next day is 15%, which means that it is predicted that about 15% of the electricity can be replenished under the weather conditions the next day, but it is not enough to fully charge the device. The logic behind this approach is that while a full-charge sample is insufficient to support the conclusion that the battery can be fully charged, a sufficient number of incomplete samples can be used to make a relatively reliable quantitative estimate of the charging amount for the next day.

[0059] The problem lies in the insufficient sample size in the prediction statistics (lacking enough statistical samples regardless of whether the device is fully charged or not), making reliable predictions based on the device's own historical statistical data impossible. In this case, the predicted charging amount for the next day is determined based on the next day's weather data and a preset mapping table. The preset mapping table is a pre-defined table that records the default predicted charging amount corresponding to different weather types and / or sunshine levels. The preset mapping table can be set based solely on weather type, or it can be set based on a combination of weather type and sunshine level. For example, a preset mapping table set solely based on weather type could be: 30% for sunny weather; 20% for cloudy weather; 10% for overcast weather; 3% for rainy weather; and 1% for snowy weather. The default values ​​in the preset mapping table can be preset at the factory, or manually adjusted based on experience during operation, or updated based on background statistics. The logic behind this approach is that when the device's own historical data is insufficient, a preset general experience value is used as a baseline prediction to ensure that the device can still perform basic threshold control under new installation or new weather conditions, so as not to fail to work due to a lack of historical data.

[0060] In the above embodiments, this application adopts three different prediction strategies based on the sufficiency of samples in the prediction statistics: predicting that the device can be fully charged when there are enough full charge attempts, using the average charge amount of the device that is not fully charged to make quantitative predictions when there are enough incomplete full charge attempts, and using a preset mapping table to make a backup prediction when there are insufficient samples. This achieves reliable prediction under various data conditions, making full use of the device's historical learning data and ensuring that the system can still operate normally when there is insufficient data.

[0061] Please refer to Figure 4 , Figure 4 This is a flowchart illustrating the process of predicting the charging speed level for the next day, as provided in an embodiment of this application. In some embodiments, the steps of the process for predicting the charging speed level for the next day may include, but are not limited to, steps S410 to S440, as described below. Figure 4 These four steps will be explained in detail.

[0062] Step S410: During the charging process, when the battery level is within a preset sampling range, the charging voltage and charging current are acquired, and the real-time charging power is calculated based on the charging voltage and charging current. Step S420: Determine the maximum value among the real-time charging powers calculated for the day as the peak charging power for the day; Step S430: Update the cumulative peak charging power and the number of power records in the prediction statistics item according to the peak charging power of the day, and update the average peak charging power in the prediction statistics item according to the ratio between the updated cumulative peak charging power and the updated number of power records. Step S440: Determine the charging speed level for the next day by comparing the average peak charging power with the preset power threshold.

[0063] In step S410 of some embodiments, the preset sampling interval refers to the range of battery charge levels used to sample charging power. In one embodiment, the preset sampling interval can be a range of 50% to 80% of the battery charge. The reason for choosing this interval is that when the battery charge is low (e.g., below 50%), the device may be in a low-charge protection phase, and the charging strategy may be affected by the protection mechanism; when the battery charge is high (e.g., above 80%), the device may enter a trickle charging phase, where the charging current gradually decreases, failing to accurately reflect the solar panel's energy replenishment capability. Thus, the 50% to 80% interval relatively avoids these two special phases, better reflects the effective energy replenishment capability of the solar panel for the battery, and the sampled charging power data is more representative.

[0064] The charging voltage and charging current are acquired in real time by the charging detection module. The charging voltage refers to the voltage output by the solar panel (after passing through the charging management circuit); the charging current refers to the current flowing into the battery. In one implementation, the sampling frequency of the charging voltage and charging current can be once every 10 seconds, once per minute, or other frequencies set according to actual needs. A higher sampling frequency can capture transient changes in power more effectively, but it also consumes more storage and computing resources.

[0065] In step S420 of some embodiments, the maximum value among the real-time charging powers calculated at all sampling times of the day is selected as the peak charging power of the day. The peak charging power of the day reflects the maximum charging power that the device can achieve under the best lighting conditions of the day, and is used to characterize the upper limit of the device's charging capacity in the non-trickle charging phase.

[0066] In step S430 of some embodiments, the cumulative peak charging power in the prediction statistics item refers to the sum of the peak charging power recorded historically for each day under the weather and sunshine conditions corresponding to the prediction statistics item. The number of power records refers to the number of days with recorded peak charging power data under the weather and sunshine conditions. The average peak charging power refers to the average value of the historical peak charging power under the weather and sunshine conditions. After obtaining the peak charging power of the day, the peak charging power of the day can be accumulated based on the cumulative peak charging power in the prediction statistics item. Specifically, if the cumulative peak charging power before the update is P_sum_old and the peak charging power of the day is P_peak, then the updated cumulative peak charging power P_sum_new = P_sum_old + P_peak. The number of power records in the prediction statistics item is incremented by 1. The average peak charging power is updated according to the ratio between the updated cumulative peak charging power and the updated number of power records. It should be noted that regardless of whether the preset full charge is reached on the day, the cumulative peak charging power, the number of power records, and the average peak charging power in the statistics item can be updated based on the peak charging power of the day. That is, the sampling and updating of peak charging power is independent of the full charge determination, so as to ensure sufficient accumulation of charging speed data.

[0067] In step S440 of some embodiments, the preset power threshold is a power boundary value used to divide charging speed levels. This preset power threshold may include a first power threshold, a second power threshold, and a third power threshold, with the first power threshold being greater than the second power threshold, and the second power threshold being greater than the third power threshold. For example, the first power threshold may be 5W, the second power threshold may be 3W, and the third power threshold may be 1.5W. Multiple preset speed levels include a first speed level, a second speed level, a third speed level, and a fourth speed level, with the average peak charging power corresponding to each speed level decreasing sequentially. Embodiments of this application can determine the charging speed level for the next day based on the comparison results between the average peak charging power and each preset power threshold.

[0068] Specifically, for example, when the average peak charging power is greater than or equal to a first power threshold, the charging speed level for the next day is determined to be the first speed level. The first speed level indicates extremely fast charging, meaning the device can charge at a very high power under these weather conditions. When the average peak charging power is less than the first power threshold but greater than or equal to a second power threshold, the charging speed level for the next day is determined to be the second speed level. The second speed level indicates fast charging. When the average peak charging power is less than the second power threshold but greater than or equal to a third power threshold, the charging speed level for the next day is determined to be the third speed level. The third speed level indicates moderate charging. When the average peak charging power is less than the third power threshold, the charging speed level for the next day is determined to be the fourth speed level. The fourth speed level indicates slow charging.

[0069] In another embodiment, the number of preset speed levels can be three or five. For example, three thresholds can be set to divide into four levels, or four thresholds can be set to divide into five levels. In yet another embodiment, when the number of power records in the prediction statistics is insufficient (e.g., the number of power records is less than the third threshold), it is considered that there are not enough speed samples, and the charging speed level for the next day can be set to the default level (e.g., medium speed or slow speed), or the speed-related adjustment component can be disabled in the subsequent weather adjustment calculation.

[0070] In the above embodiments, this application avoids the interference of the low-power protection stage and the high-power trickle stage on power sampling by sampling charging power within a preset sampling interval, so that the sampled peak charging power more accurately reflects the effective energy replenishment capability of the solar panel. By comparing the average peak charging power with a preset power threshold to determine the charging speed level, a quantitative evaluation of the device charging speed is achieved, providing speed dimension data for the subsequent refined calculation of weather adjustment amounts.

[0071] like Figure 5 The diagram illustrates a process for splitting and updating fully charged and partially charged samples according to an embodiment of this application. When a preset statistical time (e.g., 8:00 PM daily) is reached, the update process begins. First, the target statistical item is determined from the charging self-learning model based on the day's weather type and sunshine level. Simultaneously, the peak charging power for the day has been recorded within a preset sampling range (50% to 80% battery capacity) during the charging process. Then, it is determined whether the highest battery capacity of the day is greater than or equal to the preset fully charged capacity. Based on the determination result, the process splits into two different update branches: if the highest battery capacity of the day is greater than or equal to the preset fully charged capacity, it enters the fully charged sample branch, where only the number of fully charged times in the target statistical item is incremented by 1, without using the day's battery capacity increment to update the average charging amount for partially charged samples, thus avoiding underestimation of charging capacity due to battery capacity truncation; if the highest battery capacity of the day is less than the preset fully charged capacity, it enters the partially charged sample branch. At this point, we can first calculate the daily charging amount (i.e., the difference between the highest charging amount of the day and the charging amount at the previous statistical time, and not less than 0). Then, we add this daily charging amount to the cumulative charging amount that is not fully charged in the target statistics item, and increment the number of times the charging is not fully charged by 1. Finally, we update the average charging amount that is not fully charged based on the ratio of the updated cumulative charging amount that is not fully charged to the updated number of times the charging is not fully charged. After completing the above-mentioned splitting and updating of fully charged and not fully charged samples, regardless of which branch the day belongs to, we uniformly update the cumulative peak charging power, the number of power records, and the average peak charging power in the target statistics item based on the peak charging power of the day, thereby simultaneously maintaining the statistical information of charging amount and charging speed. Finally, we save the updated target statistics item to the charging self-learning model as historical data for subsequent predictions.

[0072] like Figure 6 The diagram shown illustrates a flowchart of next-day charging capacity prediction provided in an embodiment of this application. The prediction process first determines prediction statistics from the charging self-learning model based on the next day's weather type and sunshine level. These statistics record statistical information accumulated by the device under corresponding historical weather and sunshine conditions, including the number of times the device was fully charged, the number of times it was not fully charged, the average charging amount when not fully charged, and the average peak charging power. After determining the prediction statistics, the process branches execute the prediction of the next day's predicted charging amount and the prediction of the next day's charging speed level in parallel. For the prediction of the next day's charging amount, firstly, it is determined whether the number of times the battery was fully charged in the prediction statistics is greater than or equal to the threshold of the first count: if yes, it means that the device has been successfully fully charged many times in the past under the weather conditions, and has a high confidence of full charge. In this case, the predicted charging amount for the next day is determined as the preset full charge indicator value (used to characterize that the battery capacity can reach the preset full charge capacity the next day); if no, it is further determined whether the number of times the battery was not fully charged in the prediction statistics is greater than or equal to the threshold of the second count: if yes, it means that the device has accumulated enough samples of not fully charged under the weather conditions. In this case, the average charging amount of not fully charged in the prediction statistics is determined as the predicted charging amount for the next day; if no, it means that the number of samples in the prediction statistics is insufficient. In this case, the default predicted charging amount is determined by a preset mapping table based on the weather type and / or sunshine level of the next day. For predicting the charging speed level for the next day, the process first checks if the number of power records in the prediction statistics is greater than or equal to the third threshold. If so, it indicates that the device has accumulated sufficient peak charging power samples under the given weather conditions. Then, based on the comparison between the average peak charging power in the prediction statistics and multiple preset power thresholds, the next day's charging speed level is determined to be one of several preset speed levels. For example, the first speed level corresponds to "extremely fast," the second speed level to "fast," the third speed level to "medium," and the fourth speed level to "slow." The higher the average peak charging power, the faster the corresponding next day's charging speed level. If not, it indicates insufficient power records and a lack of sufficient speed samples. In this case, the next day's charging speed level can be set to a default level (e.g., medium or slow), or the speed-related adjustment component can be disabled in subsequent weather adjustment calculations. This prediction process, through graded judgment of sample sufficiency, achieves reliable prediction under various data conditions, providing data input for subsequent weather adjustment calculations in two dimensions: the predicted charging amount and the next day's charging speed level.

[0073] In step S160 of some embodiments, the weather adjustment amount is used to characterize the degree of impact of the next day's weather changes on the power consumption control of the current day. The weather adjustment amount can be a positive value, indicating that the threshold needs to be increased due to unfavorable weather, so as to enter the power saving mode earlier; or it can be a negative value, indicating that the threshold can be decreased due to favorable weather, so as to extend the duration of the constant power mode. The weather adjustment amount is expressed in percentage points, for example, -5% means that the base threshold is reduced by 5 percentage points, and +3% means that the base threshold is increased by 3 percentage points.

[0074] In some embodiments, step S160 may specifically include, but is not limited to, the following steps: The first adjustment component is determined based on the weather type of the day; The second adjustment component is determined based on the day's sunshine duration from the day's weather data; The third adjustment component is determined based on the predicted charging volume for the next day. The fourth adjustment component is determined based on the charging speed level of the following day; The candidate weather adjustment is obtained by summing the first, second, third, and fourth adjustment components. The candidate weather adjustment values ​​are subjected to a limit process to obtain the weather adjustment values.

[0075] The calculation of the weather adjustment amount comprehensively considers multiple dimensions, including the weather factors of the current day, the weather factors of the next day, the predicted charging amount for the next day, and the charging speed level for the next day. The first adjustment component is an offset related to the actual weather conditions of the current day. The weather of the current day directly affects the actual charging amount, thereby affecting the consumption strategy of the current day's electricity. The first adjustment component can be obtained by mapping the weather type of the current day. In one embodiment, if the weather type of the current day is sunny, the first adjustment component is -5%; if the weather type of the current day is cloudy, the first adjustment component is -2%; if the weather type of the current day is overcast, the first adjustment component is 0%; if the weather type of the current day is rainy or snowy, the first adjustment component is +3%. The specific value of the first adjustment component can be adjusted according to the equipment type and deployment area. In another embodiment, the first adjustment component can further consider the degree of weather type, for example, +2% for light rain and +5% for heavy rain.

[0076] The second adjustment component is an offset related to the duration of sunshine on that day. Longer sunshine duration indicates better sunlight conditions and more efficient solar charging. In one implementation, if the sunshine duration is greater than or equal to 8 hours, the second adjustment component is -2%; if the sunshine duration is less than or equal to 2 hours, the second adjustment component is +2%; and if the sunshine duration is between 2 and 8 hours, the second adjustment component is set to 0%. In another implementation, the sunshine duration threshold can be adjusted according to the latitude of the deployment area; for example, it can be set to 10 hours in low-latitude regions.

[0077] The third adjustment component is an offset related to the predicted charge amount for the next day. The predicted charge amount for the next day reflects the power replenishment the device can obtain the following day, directly affecting whether the power consumption limit should be relaxed on that day. In one embodiment, if the predicted charge amount for the next day indicates that the battery capacity can reach a preset full charge level the next day, such as a preset full charge indicator value or 100%, the third adjustment component is determined to be -5%; if the predicted charge amount for the next day is a specific value between 50% and 99%, the third adjustment component is determined to be -2%; if the predicted charge amount for the next day is less than 30%, the third adjustment component is determined to be +5%; if the predicted charge amount for the next day is between 30% and 50%, the third adjustment component is determined to be 0%. In another embodiment, the third adjustment component can be linearly or piecewise mapped based on the specific value of the predicted charge amount for the next day.

[0078] The fourth adjustment component is an offset related to the next-day charging speed level. The next-day charging speed level reflects how quickly the device will fully charge the next day, and is crucial for the fine-tuning of the daily power consumption strategy. In one implementation, if the predicted next-day charging amount indicates that the battery capacity will reach the preset full charge level the next day, the fourth adjustment component is determined based on the next-day charging speed level. For example, if the next-day charging speed level is very fast, the fourth adjustment component is set to -3%; if it is fast, the fourth adjustment component is set to -2%; if it is medium, the fourth adjustment component is set to -1%; if it is slow or there is no speed sample, the fourth adjustment component is set to 0%. If the predicted next-day charging amount does not indicate that the battery capacity will reach the preset full charge level the next day, the fourth adjustment component is set to zero. That is, the charging speed factor is only included in the calculation of the weather adjustment amount when it is predicted that the device will be fully charged the next day. The reason for this is that if the device cannot be fully charged the next day, discussing the speed of charging is meaningless, and the threshold should not be lowered due to "fast charging but incomplete charging," leading to excessive power consumption on that day.

[0079] Further, the first, second, third, and fourth adjustment components are summed to obtain the candidate weather adjustment amount. Limiting processing refers to restricting the candidate weather adjustment amount within a preset range to prevent excessively large or small weather adjustment amounts from causing threshold anomalies. In one embodiment, the lower limit of the weather adjustment amount is -18%, and the upper limit is +15%. If the candidate weather adjustment amount is lower than -18%, the weather adjustment amount is set to -18%; if the candidate weather adjustment amount is higher than +15%, the weather adjustment amount is set to +15%; if the candidate weather adjustment amount is within the range of [-18%, +15%], the weather adjustment amount is the candidate weather adjustment amount.

[0080] In some embodiments, calculating the weather adjustment amount further includes determining a fifth adjustment component based on the lowest temperature of the day or the lowest temperature of the following day. The fifth adjustment component is a temperature-related offset, as excessively low temperatures can affect the battery's charge and discharge performance. For example, if the lowest temperature is below -10 degrees Celsius, the fifth adjustment component is determined to be +3%; if the lowest temperature is between -10 degrees Celsius and 0 degrees Celsius, the fifth adjustment component is determined to be +1%; if the lowest temperature is not lower than 0 degrees Celsius, the fifth adjustment component is determined to be 0%. The first, second, third, fourth, and fifth adjustment components are then summed to obtain the candidate weather adjustment amount. In one embodiment, the lower of the lowest temperature of the day and the lowest temperature of the following day is used as the temperature determination criterion to more conservatively protect the battery capacity.

[0081] In the above embodiments, this application determines and sums adjustment components from multiple dimensions, including the weather type of the day, the sunshine duration of the day, the predicted charging amount and charging speed level of the next day, and the temperature, thereby achieving a comprehensive evaluation of the weather adjustment amount. This ensures that the weather adjustment amount can fully reflect the impact of multi-dimensional weather factors on power consumption control on the day and the next day. By performing amplitude limiting processing on the candidate weather adjustment amounts, excessive deviation of the weather adjustment amount that could lead to threshold abnormalities is avoided.

[0082] In some embodiments, the step of determining the fourth adjustment component based on the next-day charging speed level may specifically include the following steps: If the predicted charging amount for the next day indicates that the battery capacity can reach the preset full charge capacity, the fourth adjustment component is determined according to the charging speed level for the next day. The fourth adjustment component decreases as the charging speed level for the next day increases. If the predicted charging amount for the next day indicates that the battery capacity for the next day cannot reach the preset full charge, the fourth adjustment component will be set to zero.

[0083] In this embodiment, if the predicted charging amount for the next day indicates that the battery capacity can reach the preset full charge level, a fourth adjustment component can be determined based on the charging speed level for the next day. This fourth adjustment component decreases as the charging speed level increases; that is, the faster the speed, the more negative the fourth adjustment component, and the stronger its effect on lowering the threshold. For example, if the charging speed level for the next day is the first speed level (extremely fast), the fourth adjustment component is determined to be -3%. If the charging speed level for the next day is the second speed level (fast), the fourth adjustment component is determined to be -2%.

[0084] In other embodiments, if the number of power records in the prediction statistics is insufficient to support speed level judgment (e.g., the number of power records is less than the third threshold), it can be considered that there are insufficient speed samples. In this case, the fourth adjustment component can be set to 0% to avoid making inappropriate adjustments when information is insufficient. A negative fourth adjustment component means that the faster the charging speed, the larger the negative component in the weather adjustment, and the lower the final target constant power threshold. The device can still maintain constant power mode at lower power levels. This is reasonable: if it can be quickly fully charged the next day, the power consumed when the power is low on the day can be quickly replenished the next day, allowing for a more aggressive usage strategy.

[0085] If the predicted charging amount for the next day does not indicate that the battery capacity will reach the preset full charge level, the fourth adjustment component can be set to zero. The logic behind this is that if the prediction indicates the battery cannot be fully charged the next day, discussing the charging speed is meaningless. In this case, the threshold should not be lowered due to the "charging speed level," otherwise it may lead to excessive power consumption on that day and insufficient power the next day. By setting the fourth adjustment component to zero, it ensures that speed information is used for fine-tuning only when a full charge is predicted for the next day, avoiding misleading adjustments caused by speed information when full charge conditions are not met.

[0086] In the above embodiments, this application can limit the adjustment component corresponding to the charging speed level to be included in the weather adjustment amount only when the predicted charging amount can be fully charged on the next day. This avoids misleading threshold reduction caused by speed information when the charging cannot be fully charged, and ensures that the adjustment effect of the speed factor is activated under the correct conditions. This achieves both fine control and ensures power safety.

[0087] In step S170 of some embodiments, the target constant power threshold is the final power threshold used to control the device to switch between constant power mode and power saving mode. The target constant power threshold is determined by a base threshold and a weather adjustment amount, reflecting a comprehensive consideration of the device's long-term historical charging capacity and short-term weather changes. The target constant power threshold is calculated as follows: Target constant power threshold = Base threshold + Weather adjustment amount. For example, if the base threshold is 85% and the weather adjustment amount is -5%, then the target constant power threshold is 80%; if the base threshold is 85% and the weather adjustment amount is +10%, then the target constant power threshold is 95%. After determining the target constant power threshold, the current battery power of the solar power supply device is obtained, and the power consumption mode of the device is controlled according to the comparison result between the current battery power and the target constant power threshold. Specifically, if the current battery power is greater than or equal to the target constant power threshold, the solar power supply device is controlled to enter or maintain constant power mode; if the current battery power is lower than the target constant power threshold, the solar power supply device is controlled to enter or maintain power saving mode. In constant power mode, the devices operate with full business capabilities; for example, cameras stream video at high frame rates and high resolutions, and doorbells maintain real-time network connectivity and fast response. In power-saving mode, the devices operate at reduced power consumption levels; for example, cameras reduce frame rates or use event-triggered wake-up, and doorbells reduce network connection frequency or extend wake-up intervals.

[0088] Example 1: An electronic device has a base threshold of 85%. The weather is sunny with 8 hours of sunshine on the current day, and the next day is also sunny with 8 hours of sunshine. Historical learning data shows that under "sunny + high sunshine" conditions, the device is frequently fully charged, and the average peak charging power is greater than 5W. Therefore, the device can obtain the following components: current day weather type component -5%, current day sunshine duration component -2%, next day predicted charging amount component -5%, next day charging speed component -3%, and weather adjustment amount -15%. The final constant power threshold is 70%, allowing the device to maintain a constant power mode for a longer period during good weather conditions.

[0089] Example 2: An electronic device has a base threshold of 85%. The weather is rainy with 1 hour of sunshine on the current day, and the next day is also rainy with 1 hour of sunshine. Historical learning data shows that under "rain + low sunshine" conditions, the device can only replenish energy by an average of 10%. If the lowest temperature is -5 degrees Celsius, then the following components are calculated: weather type component +3%, sunshine duration component +2%, predicted charging amount for the next day +5%, temperature component +1%, and weather adjustment component +11%. The final constant power threshold is 96%, which, after limiting, becomes 95%, allowing the device to enter power-saving mode earlier.

[0090] Example 3: The day was rainy with 2 hours of sunshine, and the next day was sunny with 7 hours of sunshine. Historical learning data shows that under "sunny + high sunshine" conditions, the device was fully charged multiple times, with an average peak charging power of 4W. Although the charging conditions were poor on the day, the weather adjustment could partially offset the unfavorable factors because it was expected to be fully charged quickly the next day. This resulted in the final constant power threshold remaining close to or slightly lower than the base threshold, reflecting the control strategy of "if the power can be replenished the next day, more power can be used on the current day."

[0091] Please refer to Figure 7 , Figure 7 This is a flowchart illustrating the calculation and mode switching of weather adjustment amount provided in this application embodiment. The calculation of the weather adjustment amount integrates five dimensions of input information: the weather type of the day, the sunshine duration of the day, the predicted charging amount for the next day, the charging speed level for the next day, and temperature information. The temperature information may include the lowest temperature of the day or the lowest temperature of the next day. First, a first adjustment component is determined based on the weather type of the day (e.g., negative adjustment for sunny days, positive adjustment for rainy days). A second adjustment component is determined based on the sunshine duration of the day (longer sunshine tends to lead to a more negative adjustment). A third adjustment component is determined based on the predicted charging amount for the next day (higher predicted charging amount tends to lead to a more negative adjustment). A fourth adjustment component is determined based on the charging speed level for the next day (but this component is only activated when the predicted charging amount for the next day indicates that the preset full charge can be achieved; otherwise, it is set to zero). A fifth adjustment component is determined based on the temperature information (positive adjustment tends to be applied in low-temperature environments). Then, the first to fifth adjustment components are summed to obtain a candidate weather adjustment amount, and a limiting process is performed on this candidate weather adjustment amount to obtain the final weather adjustment amount. Subsequently, the base threshold is added to the weather adjustment amount to obtain the target constant power threshold. A secondary limiting process is then applied to this target constant power threshold to ensure it remains within a reasonable range. Finally, the device's current battery level is obtained, and it is determined whether the current level is greater than or equal to the target constant power threshold. If yes, the device is controlled to enter or maintain constant power mode; otherwise, it is controlled to enter or maintain power-saving mode to reduce power consumption and extend battery life. This completes the dynamic switching control of power consumption modes based on weather forecasting and charging self-learning.

[0092] The power consumption control method for a power supply device provided in this application is equivalent to providing an adaptive decoding optimization method for multi-channel video detection, and the technical effects it can produce are as follows: (1) By using a two-layer architecture that calculates the base threshold and the weather adjustment amount separately, the device retains the long-term stable strategy (base threshold) based on historical charging results, and can also make rapid corrections based on weather forecasts (weather adjustment amount), thus solving the technical problem of the existing solution's lagging response to future weather changes. When the weather is favorable the next day, the device can lower the threshold in advance and continue to maintain the normal power mode when the power is still sufficient, improving the user experience; when the weather is unfavorable the next day, the device can raise the threshold in advance and enter the power-saving mode when the power is still high, reserving power for future rainy weather and reducing the risk of the device shutting down due to power depletion.

[0093] (2) By constructing a device-level charging self-learning model categorized by weather type and sunshine level, each device can independently learn and accumulate historical charging data based on its individual factors such as installation location, orientation angle, obstruction conditions, and solar panel efficiency. This solves the technical problem that existing unified rules are difficult to adapt to the individual differences of different devices. Devices installed in open areas will learn stronger charging capabilities, obtain lower thresholds, and longer constant power time; devices installed in the shade or facing north will learn weaker charging capabilities and automatically adopt a more conservative threshold strategy.

[0094] (3) Asymmetric updates are performed on fully charged and partially charged samples. Fully charged samples are updated only with the number of full charge cycles without including the daily cut-off charge increment in the average charge amount for partially charged samples. This fundamentally avoids the problem of underestimation of charging capacity caused by the upper limit of battery capacity. It solves the technical problem of deviation caused by full charge cut-off when the charge increment is directly used as the learning sample in the existing scheme, and makes the charging self-learning model more accurate in representing the real power generation capacity.

[0095] (4) By sampling the peak charging power within the 50% to 80% battery capacity range and determining the charging speed level accordingly, the threshold control can not only determine whether the battery can be fully charged the next day, but also distinguish the speed at which it can be fully charged the next day. This solves the technical problem that existing binary judgments based on whether the battery is fully charged are difficult to finely control the threshold. Furthermore, the adjustment component corresponding to the speed level is only included in the weather adjustment amount when it is predicted that the battery can be fully charged the next day. This achieves fine control of the reasonable logic of "the battery can be fully charged quickly tomorrow → more electricity can be used today", and avoids misjudgment due to speed factors when the battery cannot be fully charged.

[0096] (5) By setting a degradation operation mechanism when weather data is invalid or expired, the device can automatically switch to operation based only on the basic threshold when communication is abnormal or weather service is unavailable, taking into account both intelligent adjustment capability and system availability; by setting a persistent storage and startup verification mechanism for the charging self-learning model, it is ensured that historical learning data is not lost after the device restarts or abnormal power outages, thereby improving the reliability of the system and the stability of long-term operation.

[0097] In summary, the embodiments of this application provide a complete solution that combines adaptability, individualization, deviation prevention, and fine-tuning capabilities, enabling better adaptive dynamic optimization control of the power consumption mode of solar power supply equipment and improving the accuracy of power consumption control for the power supply equipment.

[0098] Please see Figure 8 This application embodiment also provides a power consumption control device for a power supply device, the power consumption control device 800 for the power supply device comprising: The acquisition module 810 is used to acquire the daily charging data and weather forecast data of the solar power supply equipment within a preset statistical period. The weather forecast data includes the weather data of the current day and the weather data of the next day, and the daily charging data includes the highest power consumption of the day. The threshold update module 820 is used to update the basic threshold based on the comparison between the highest power consumption of the day and the preset fully charged power consumption. The basic threshold is used to characterize the power reference for controlling the solar power supply equipment to switch between normal power mode and power saving mode without considering weather factors. The statistical item determination module 830 is used to determine target statistical items from a preset charging self-learning model based on the weather data of the day. The charging self-learning model contains multiple statistical items classified according to weather type and sunshine level. The numerical update module 840 is used to perform asymmetric updates on the charging sample statistics and the incompletely charged sample statistics in the target statistics item based on the comparison results between the highest battery level of the day and the preset fully charged battery level. The capacity prediction module 850 is used to determine the prediction statistics from the charging self-learning model based on the next day's weather data, and predict the next day's charging capacity based on the prediction statistics. The next day's charging capacity includes the predicted charging amount for the next day. The adjustment calculation module 860 is used to calculate the weather adjustment amount based on the predicted charging amount for the next day, the weather data for the next day, and the weather data for the current day. The weather adjustment amount is used to characterize the degree of influence of the weather change for the next day on the power consumption control for the current day. The mode switching module 870 is used to determine the target constant power threshold based on the basic threshold and the weather adjustment amount, and to control the solar power supply equipment to switch between constant power mode and power saving mode according to the target constant power threshold.

[0099] It should be noted that the power consumption control device for the power supply equipment provided in this application embodiment is used to implement the power consumption control method for the power supply equipment provided in the above embodiment, and the specific implementation process corresponds to the power consumption control method for the power supply equipment in the above embodiment. It can be referred to the aforementioned power consumption control method for the power supply equipment, and will not be repeated here.

[0100] This application also provides an electronic device (i.e., a computer device), which includes a memory and a processor. The memory stores a computer program, and when the processor executes the computer program, it can implement the power consumption control method of any of the power supply devices described in the above embodiments. This electronic device can be any smart terminal, including tablet computers, in-vehicle computers, etc.

[0101] Please see Figure 9 , Figure 9 This illustration shows the hardware structure of an electronic device according to another embodiment, the electronic device comprising: The processor 910 can be implemented using a general-purpose central processing unit (CPU), microprocessor, application specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this application. The memory 920 can be implemented as a read-only memory (ROM), static storage device, dynamic storage device, or random access memory (RAM). The memory 920 can store the operating system and other applications. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 920 and is called and executed by the processor 910 to execute the power consumption control method of the power supply device in the embodiments of this application. The input / output interface 930 is used to implement information input and output; The communication interface 940 is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, network cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.). Bus 950 transmits information between various components of the device (e.g., processor 910, memory 920, input / output interface 930, and communication interface 940); The processor 910, memory 920, input / output interface 930 and communication interface 940 are connected to each other within the device via bus 950.

[0102] This application also provides a computer-readable storage medium storing a computer program for causing a computer to execute the power consumption control method for the power supply device described in the above embodiments.

[0103] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

[0104] This invention also provides a computer program product that stores program instructions. When executed by a computer, the program instructions cause the computer to implement the power consumption control method for the power supply device described in any of the above embodiments.

[0105] It should be noted that any software tools or components not belonging to this company appearing in the embodiments of this application are merely illustrative examples and do not represent actual use. All user personal information involved in the embodiments of this application has been authorized (with knowledge and consent) by the relevant parties or has been fully authorized by all parties, and the executing entity may obtain it through various legal and compliant means. The collection, storage, use, processing, transmission, provision, and disclosure of the information, data, and signals involved all comply with relevant laws and regulations and do not violate public order and good morals.

[0106] The embodiments described in this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided by the embodiments of this application. As those skilled in the art will know, with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of this application are also applicable to similar technical problems.

[0107] Those skilled in the art will understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of this application, and may include more or fewer steps than shown, or combine certain steps, or different steps.

[0108] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0109] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.

[0110] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0111] It should be understood that in this application, "at least one (item)" means one or more, and "more than" means two or more. "And / or" is used to describe the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one (item) of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one (item) of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.

[0112] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of the units described above is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0113] The units described above as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0114] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0115] If the integrated unit is implemented as 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 technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes multiple instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing programs, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0116] The preferred embodiments of the present application have been described above with reference to the accompanying drawings, but this does not limit the scope of the claims of the present application. Any modifications, equivalent substitutions, and improvements made by those skilled in the art without departing from the scope and substance of the embodiments of the present application shall be within the scope of the claims of the present application.

Claims

1. A power consumption control method for a power supply device, applied to a solar power supply device, characterized in that, The method includes: The system acquires the daily charging data and weather forecast data of the solar power supply device within a preset statistical period. The weather forecast data includes the weather data for the current day and the weather data for the next day. The daily charging data includes the highest daily power consumption. The base threshold is updated based on the comparison between the highest daily power consumption and the preset fully charged power consumption. The base threshold is used to characterize the power consumption benchmark for controlling the solar power supply device to switch between constant power mode and power saving mode without considering weather factors. The target statistical item is determined from the preset charging self-learning model based on the weather data of the day. The charging self-learning model includes multiple statistical items classified according to weather type and sunshine level. Based on the comparison between the highest battery level of the day and the preset fully charged battery level, perform asymmetric updates on the charging sample statistics and the incompletely charged sample statistics in the target statistics item; Based on the next day's weather data, predictive statistics are determined from the charging self-learning model, and the next day's charging capacity is predicted based on the predictive statistics. The next day's charging capacity includes the next day's predicted charging amount. Based on the predicted charging amount for the next day, the weather data for the next day, and the weather data for the current day, a weather adjustment amount is calculated. The weather adjustment amount is used to characterize the degree of influence of the weather change for the next day on the power consumption control for the current day. The target constant power threshold is determined based on the base threshold and the weather adjustment amount, and the solar power supply equipment is controlled to switch between the constant power mode and the power saving mode based on the target constant power threshold.

2. The method according to claim 1, characterized in that, The daily charging data also includes the first time the preset full charge level is reached on that day. Updating the base threshold based on the comparison between the highest daily charge level and the preset full charge level includes: If the highest battery level of the day is greater than or equal to the preset full charge level, the reduction value is determined based on the comparison between the first time the battery level was reached and the preset time point, and the basic threshold is updated according to the reduction value. If the highest battery level of the day is less than the preset full charge level, the basic threshold is updated based on the difference between the preset full charge level and the highest battery level of the day.

3. The method according to claim 1, characterized in that, The charging data for the day also includes the electricity level at the previous statistical time. The charging sample statistics include the number of times the battery was fully charged on the day. The incompletely charged sample statistics include the cumulative amount of incompletely charged battery on the day, the number of times the battery was not fully charged on the day, and the average amount of incompletely charged battery on the day. The step of performing asymmetric updates on the charging sample statistics and the incompletely charged sample statistics in the target statistics item based on the comparison result between the highest battery level of the day and the preset fully charged battery level includes: If the highest battery level of the day is greater than or equal to the preset full charge level, the number of full charge counts for the day is incremented by 1, and the cumulative charge amount not fully charged on the day, the number of times the battery is not fully charged on the day, and the average charge amount not fully charged on the day remain unchanged. If the highest daily charge is less than the preset full charge, the actual daily charge is determined based on the difference between the highest daily charge and the charge at the previous statistical time. The actual daily charge is added to the cumulative charge that is not fully charged on the same day. The number of times the battery is not fully charged is incremented by 1. The average daily charge that is not fully charged is updated based on the ratio of the updated cumulative charge that is not fully charged on the same day to the updated number of times the battery is not fully charged on the same day.

4. The method according to claim 1, characterized in that, The next-day charging capability also includes a next-day charging speed level, and the prediction process for the next-day charging speed level includes: During the charging process, when the battery level is within a preset sampling range, the charging voltage and charging current are acquired, and the real-time charging power is calculated based on the charging voltage and the charging current. The maximum value among the real-time charging powers calculated on the same day is determined as the peak charging power for the day. The cumulative peak charging power and the number of power records in the prediction statistics are updated based on the peak charging power of the day, and the average peak charging power in the prediction statistics is updated based on the ratio between the updated cumulative peak charging power and the updated number of power records. The next day's charging speed level is determined by comparing the average peak charging power with a preset power threshold.

5. The method according to claim 4, characterized in that, Based on the predicted charging amount for the next day, the weather data for the next day, and the weather data for the current day, a weather adjustment amount is calculated, including: The first adjustment component is determined based on the weather type of the day; The second adjustment component is determined based on the day's sunshine duration from the day's weather data. The third adjustment component is determined based on the predicted charging amount for the next day. The fourth adjustment component is determined based on the next day's charging speed level; The candidate weather adjustment amount is obtained by summing the first adjustment component, the second adjustment component, the third adjustment component, and the fourth adjustment component; The candidate weather adjustment values ​​are subjected to amplitude limiting processing to obtain the weather adjustment values.

6. The method according to claim 5, characterized in that, The determination of the fourth adjustment component based on the next day's charging speed level includes: If the predicted charging amount for the next day indicates that the battery capacity for the next day can reach the preset full charge capacity, the fourth adjustment component is determined according to the charging speed level for the next day, and the fourth adjustment component decreases as the charging speed level for the next day increases. If the predicted charging amount for the next day indicates that the battery charge for the next day cannot reach the preset full charge, the fourth adjustment component is set to zero.

7. The method according to claim 1, characterized in that, The process of predicting the next day's predicted charging amount includes: If the predicted number of full charge times in the predicted statistics item is greater than or equal to the threshold of the first number, the predicted charging amount for the next day is determined as the preset full charge indicator value. The preset full charge indicator value is used to characterize that the battery capacity can reach the preset full charge capacity on the next day. If the predicted number of times to fully charge is less than the first number threshold and the predicted number of times not fully charged in the prediction statistics item is greater than or equal to the second number threshold, the average predicted charging amount of not fully charged in the prediction statistics item is determined as the predicted charging amount for the next day. If the predicted number of full charges is less than the first number threshold and the number of incomplete charges is less than the second number threshold, the predicted charging amount for the next day is determined based on the weather data for the next day and a preset mapping table.

8. A power consumption control device for a power supply equipment, characterized in that, The device includes: The acquisition module is used to acquire the daily charging data and weather forecast data of the solar power supply equipment within a preset statistical period. The weather forecast data includes the weather data of the current day and the weather data of the next day, and the daily charging data includes the highest power consumption of the day. The threshold update module is used to update the base threshold based on the comparison result between the highest power consumption of the day and the preset fully charged power consumption. The base threshold is used to characterize the power consumption benchmark for controlling the solar power supply equipment to switch between constant power mode and power saving mode without considering weather factors. The statistical item determination module is used to determine target statistical items from a preset charging self-learning model based on the weather data of the day. The charging self-learning model includes multiple statistical items classified according to weather type and sunshine level. The numerical update module is used to perform asymmetric updates on the charging sample statistics and the incompletely charged sample statistics in the target statistics item based on the comparison result between the highest battery level of the day and the preset fully charged battery level. The capacity prediction module is used to determine prediction statistics from the charging self-learning model based on the next day's weather data, and to predict the next day's charging capacity based on the prediction statistics, wherein the next day's charging capacity includes the next day's predicted charging amount. The adjustment amount calculation module is used to calculate the weather adjustment amount based on the next day's predicted charging amount, the next day's weather data, and the current day's weather data. The weather adjustment amount is used to characterize the degree of influence of the next day's weather changes on the current day's power consumption control. The mode switching module is used to determine a target constant power threshold based on the base threshold and the weather adjustment amount, and to control the solar power supply equipment to switch between the constant power mode and the power saving mode based on the target constant power threshold.

9. An electronic device, characterized in that, The electronic device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the method according to any one of claims 1 to 7.

10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the method of any one of claims 1 to 7.