Charging and discharging control method and device

Through the multi-dimensional control strategy integrating charging equipment, charging piles and grid status parameters, the multi-target conflict in charging pile control technology is solved, safe, economical and efficient charging and discharging management is achieved, extending battery life and improving equipment reliability.

CN120363775APending Publication Date: 2025-07-25NANYANG JINGUAN INTELLIGENT SWITCH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510666952.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-22
Publication Date
2025-07-25

AI Technical Summary

Technical Problem

The existing charging pile control technology mainly relies on a single-dimensional decision-making mechanism, and it is difficult to achieve global optimization between battery life protection, equipment reliability guarantee and power grid coordination requirements, especially in multi-target conflict scenarios, it is difficult to take into account the interests of users, equipment and power grids.

Method used

The first, second and third charging and discharging control strategies are determined based on the battery status parameters of the target charging equipment, the health status parameters of the charging pile and the grid status parameters, and the first, second and third charging and discharging control strategies are respectively, and integrated into the target charging and discharging control strategy to achieve multi-dimensional coordinated control and dynamically optimize the charging and discharging process.

Benefits of technology

It realizes that while ensuring safety, taking into account the interests of users, equipment and the power grid, solving multi-target conflict problems, extending battery life, improving the operating reliability of charging piles, and quickly responding to grid scheduling needs and avoiding local overload.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120363775A_ABST
    Figure CN120363775A_ABST
Patent Text Reader

Abstract

The invention provides a charging and discharging control method and device. The method comprises the steps of determining a first charging and discharging control strategy of a charging pile based on a battery state parameter of target charging equipment; based on the health state parameters of the charging pile, determining a second charging and discharging control strategy of the charging pile; determining a third charging and discharging control strategy of the charging pile based on the power grid state parameter; and fusing the first charging and discharging control strategy, the second charging and discharging control strategy and the third charging and discharging control strategy as a target charging and discharging control strategy of the charging pile, so as to perform charging and discharging control on the charging pile based on the target charging and discharging control strategy. According to the invention, benefits of users, equipment and a power grid can be considered on the premise of guaranteeing safety, and the problem of multi-target conflict is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of charging pile control, and particularly to a charge and discharge control method and device. Background Art

[0002] With the popularization of electric vehicles, the charge and discharge control technology of charging piles has become the key to ensuring the user experience and the safe operation of the power grid. The current charge and discharge control technology of electric vehicle charging piles mainly relies on a single-dimensional decision-making mechanism. The charge and discharge control strategies of traditional charging piles mostly focus on a single dimension. For example, the power distribution is dynamically adjusted according to the urgency input by the user and the package type, or the load is regulated in response to the power grid dispatching instruction. The charging power is automatically increased during the low electricity price period, and during the peak period, a delayed charging suggestion or preferential incentive is pushed through the APP.

[0003] However, although these control methods can meet the basic requirements in specific scenarios, there is a lack of systematic coordination among battery life protection, equipment reliability guarantee, and power grid coordination requirements. Especially in the scenario of multi-objective conflicts, it is difficult to achieve global optimization, and there are significant limitations. Summary of the Invention

[0004] Embodiments of the present invention provide a charge and discharge control method and device to solve the problem that the current charging pile control method is difficult to take into account the requirements of multiple parties.

[0005] In a first aspect, embodiments of the present invention provide a charge and discharge control method, including: Determining a first charge and discharge control strategy of the charging pile based on the battery state parameters of the target charging device; Determining a second charge and discharge control strategy of the charging pile based on the health state parameters of the charging pile; Determining a third charge and discharge control strategy of the charging pile based on the power grid state parameters; Fusing the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy as the target charge and discharge control strategy of the charging pile, so as to control the charge and discharge of the charging pile based on the target charge and discharge control strategy.

[0006] In a possible implementation manner, the battery state parameters include the SOH value and the temperature. Determining a first charge and discharge control strategy of the charging pile based on the battery state parameters of the target charging device includes: Determining a charging derating coefficient based on the temperature of the target charging device and the temperature threshold; Determining a first charging current based on the SOH value, the charging derating coefficient, and the initial charging current of the target charging device; wherein, the initial charging current is determined based on the maximum allowable charging current and the rated charging current of the target charging device and the maximum safe charging current of the power grid; Determine the first discharge current based on the maximum allowable discharge current, rated discharge current, and SOH value of the target charging device.

[0007] In a possible implementation, before determining the first charge-discharge control strategy of the charging pile based on the battery state parameters of the target charging device, it further includes: Based on the identity of the target charging device, look up the historical charging curve and / or historical discharge curve of the target charging device in the historical charge-discharge database; For each historical charging curve, intercept the constant-current charging interval and calculate the charging amount through integration to obtain the battery capacity corresponding to this historical charging curve; For each historical discharge curve, intercept the constant-current discharge interval and calculate the discharge amount through integration to obtain the battery capacity corresponding to this historical discharge curve; Based on the moments corresponding to each historical charging curve and / or historical discharge curve, combine each battery capacity into a battery capacity sequence; Input the battery capacity sequence into the LSTM network to obtain the battery capacity at the current moment.

[0008] In a possible implementation, the health state parameters of the charging pile include contact resistance, cooling efficiency, and insulation resistance; determining the second charge-discharge control strategy of the charging pile based on the health state of the charging pile includes: Based on the ratio of the contact resistance to the initial contact resistance, determine the contact resistance derating factor; Based on the insulation resistance, safety threshold, and danger threshold, determine the insulation resistance derating factor; Based on the ratio of the cooling efficiency to the rated cooling efficiency, determine the cooling efficiency derating factor; Multiply the contact resistance derating factor, insulation resistance derating factor, and cooling efficiency derating factor by the initial charging power to obtain the charging power of the second charge-discharge control strategy; Multiply the contact resistance derating factor, insulation resistance derating factor, and cooling efficiency derating factor by the initial discharge power to obtain the discharge power of the second charge-discharge control strategy.

[0009] In a possible implementation, the grid state parameters include the PCC point voltage sequence and the PCC point frequency sequence; determining the third charge-discharge control strategy of the charging pile based on the grid state parameters includes: Calculate the cosine similarity between the PCC point voltage sequence and the PCC point voltage sequences of multiple preset grid standard states as the first cosine similarity; Calculate the cosine similarity between the PCC point frequency sequence and the PCC point frequency sequences of multiple preset grid standard states as the second cosine similarity; Calculate the difference between the average voltage of the PCC point voltage sequence and the average voltage of the PCC point voltage sequences of multiple preset grid standard states; Calculate the difference between the average frequency of the PCC point frequency sequence and the average frequency of the PCC point frequency sequences of multiple preset grid standard states; For each grid standard state, normalize and perform weighted summation on the first cosine similarity, second cosine similarity, reciprocal of the average voltage difference, and reciprocal of the average frequency difference corresponding to this grid standard state, and use it as the similarity between this grid standard state and the PCC point voltage sequence and PCC point frequency sequence; Use the charge and discharge control strategy corresponding to the grid standard state with the highest similarity as the third charge and discharge control strategy of the charging pile.

[0010] In a possible implementation manner, before determining the third charge and discharge control strategy of the charging pile based on the grid state parameters, it further includes: Obtain the historical charge and discharge control strategies of multiple charging piles and the corresponding PCC point voltage sequences and PCC point frequency sequences; For each historical charge and discharge control strategy, cluster each group of PCC point voltage sequences and PCC point frequency sequences based on similarity to obtain multiple clustering clusters; Use each clustering cluster as a grid standard state, and use the PCC point voltage sequence and PCC point frequency sequence corresponding to the clustering center of this clustering cluster as the PCC point voltage sequence and PCC point frequency sequence corresponding to the grid standard state.

[0011] In a possible implementation manner, fusing the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy as the target charge and discharge control strategy of the charging pile includes: Calculate the weight of the first charge and discharge control strategy based on the SOC value of the target charging device and a preset SOC threshold; Calculate the weight of the second charge and discharge control strategy based on the contact resistance, cooling efficiency, insulation resistance of the charging pile and preset contact resistance threshold, cooling efficiency threshold, insulation resistance threshold; Calculate the weight of the third charge and discharge control strategy based on the grid load rate and a preset grid load rate threshold; Perform weighted summation on the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy based on each weight to obtain the target charge and discharge control strategy of the charging pile.

[0012] In a second aspect, an embodiment of the present invention provides a charge and discharge control device, including: A first determination module, configured to determine the first charge and discharge control strategy of the charging pile based on the battery state parameters of the target charging device; A second determination module, configured to determine a second charge and discharge control strategy of the charging pile based on the health status parameters of the charging pile; A third determination module, configured to determine a third charge and discharge control strategy of the charging pile based on the grid status parameters; A fusion control module, configured to fuse the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy as the target charge and discharge control strategy of the charging pile, so as to perform charge and discharge control on the charging pile based on the target charge and discharge control strategy.

[0013] In a third aspect, an embodiment of the present invention provides a terminal, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the method described in the first aspect or any possible implementation manner of the first aspect above are implemented.

[0014] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium storing a computer program, and when the computer program is executed by a processor, the steps of the method described in the first aspect or any possible implementation manner of the first aspect above are implemented.

[0015] An embodiment of the present invention provides a charge and discharge control method and device. By hierarchically obtaining battery state parameters, charging pile operation states, and real-time grid parameters, and generating multi-dimensional control strategies accordingly, and finally fusing them into a dynamically optimized target charge and discharge strategy, it breaks through the limitations of traditional single-dimensional control. The adaptive strategy based on the battery state can actively derate for abnormal working conditions such as aging or low temperature, avoid irreversible damage caused by overcharging and over-discharging, and extend the battery life. The real-time evaluation of the health state of the charging pile can identify potential hazards such as increased contact resistance and decreased heat dissipation efficiency in advance, prevent equipment failures through power limitation, and improve operation reliability. The in-depth coordination of grid parameters ensures rapid response to dispatching requirements during high load or frequency fluctuations, and avoids local grid overload. This multi-dimensional collaborative control method can balance the interests of users, equipment, and the grid while ensuring safety, and solve the multi-objective conflict problem. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following will briefly introduce the drawings required for use in the embodiments or the description of the prior art. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0017] Figure 1 It is a flowchart of the implementation of a charge and discharge control method provided by an embodiment of the present invention; Figure 2It is a schematic structural diagram of a charge and discharge control device provided by an embodiment of the present invention; Figure 3 It is a schematic diagram of a terminal provided by an embodiment of the present invention. Detailed implementation manners

[0018] In the following description, specific details such as specific system structures and technologies are presented for the purpose of illustration rather than limitation, so as to thoroughly understand the embodiments of the present invention. However, those skilled in the art should clearly understand that the present invention can also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to avoid unnecessary details from interfering with the description of the present invention.

[0019] To make the objectives, technical solutions, and advantages of the present invention clearer, the following will be described through specific embodiments with reference to the accompanying drawings.

[0020] Refer to Figure 1 , which shows the implementation flowchart of a charge and discharge control method provided by an embodiment of the present invention, and is described in detail as follows: Step 101: Determine the first charge and discharge control strategy of the charging pile based on the battery state parameters of the target charging device.

[0021] In this embodiment, the target charging device refers to an electric vehicle or other energy storage device that accesses the charging pile for energy exchange, and its battery state parameters include physical quantities such as state of charge (SOC), state of health (SOH), temperature, and internal resistance that characterize the current performance of the battery.

[0022] The charging pile obtains the battery state parameters through the vehicle communication interface and generates the first charge and discharge control strategy based on this. For example, when the battery SOH is lower than the preset threshold, the system reduces the maximum allowable charging current according to the degree of aging to avoid the out-of-control temperature rise caused by the increase in internal resistance; if the battery temperature exceeds the safe range, the preheating or forced cooling program is started, and the charging power is dynamically limited.

[0023] In this embodiment, the physical state of the battery is mapped to a power control instruction. By actively adapting to the battery characteristics, the risks of overcharging, over-discharging, and thermal runaway are avoided, the battery service life can be extended, and the safety of the charging process can be improved, especially suitable for high cycle number or extreme temperature scenarios.

[0024] Step 102: Determine the second charge and discharge control strategy of the charging pile based on the health state parameters of the charging pile.

[0025] In this embodiment, the health state parameters of the charging pile cover indicators such as contact resistance, insulation resistance, coolant flow rate, and heat dissipation efficiency that reflect the operation reliability of the device.

[0026] Generate a second charge and discharge control strategy by real-time monitoring the health status parameters of key components of the charging pile. For example, when it is detected that the contact resistance of the charging gun abnormally increases, the system calculates the power derating coefficient according to the resistance change rate and limits the output current to prevent the connector from overheating; when the efficiency of the cooling system decreases, switch to the standby heat dissipation mode and trigger a maintenance signal.

[0027] In this embodiment, by quantifying the impact of equipment health deterioration on operating capacity, the traditional fixed-threshold protection is upgraded to dynamic adaptive protection. The principle lies in establishing a dynamic association model between the equipment state and the power carrying capacity, and adjusting the operating boundary through real-time feedback. This design can significantly improve the reliability of the charging pile in scenarios of gradual faults such as connector wear and coolant leakage, and reduce the risk of sudden shutdown.

[0028] Step 103: Based on the grid state parameters, determine the third charge and discharge control strategy of the charging pile.

[0029] In this embodiment, the grid state parameters refer to the real-time grid operating condition information such as the voltage, frequency, and dispatching instructions at the point of common coupling (PCC).

[0030] Generate the third charge and discharge control strategy based on the grid state parameters. Specifically, when it is detected that the grid frequency deviates from the stable range or a dispatching instruction is received, the charging pile cluster automatically adjusts the total power output. For example, when the grid is overloaded, the charging power is limited proportionally, or when the frequency drops suddenly, reverse discharging is started to support the grid.

[0031] This embodiment relies on the closed-loop control of grid state perception and power regulation. By responding to grid demands in real time, load flexible regulation can be achieved, which can enhance the coordination ability between the charging pile and the grid, relieve local grid congestion, and at the same time create technical conditions for operators to participate in the demand response market.

[0032] Step 104: Integrate the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy as the target charge and discharge control strategy of the charging pile, and perform charge and discharge control on the charging pile based on the target charge and discharge control strategy.

[0033] In this embodiment, the above three strategies can be integrated into the target charge and discharge control strategy through a multi-objective optimization algorithm. For example, in the scenario of low battery power and high grid load, the system dynamically allocates the weights of each strategy: prioritize ensuring the minimum safe charging power (the first charge and discharge control strategy), derate according to grid requirements (the third charge and discharge control strategy), and at the same time ensure that the health parameters of the charging pile do not exceed the limit (the second charge and discharge control strategy).

[0034] The fusion process can adopt normalization to eliminate the dimensional difference and smooth the power adjustment trajectory through model predictive control. In this embodiment, by dynamically balancing the conflicts among battery demand, device capabilities, and grid constraints, global optimization under complex working conditions can be achieved, which can not only meet the emergency charging needs of users but also avoid equipment overload or grid instability, realizing the multi-objective coordination of safety, economy, and efficiency.

[0035] In the embodiment of the present invention, battery state parameters, charging pile operation states, and real-time grid parameters are obtained layer by layer, and based on this, a multi-dimensional control strategy is generated, which is finally integrated into a dynamically optimized target charge-discharge strategy, breaking through the limitations of traditional single-dimensional control. The adaptive strategy based on the battery state can actively derate for abnormal working conditions such as aging or low temperature, avoiding irreversible damage caused by overcharging and over-discharging, and extending the battery life. The real-time assessment of the health state of the charging pile can identify potential hazards such as increased contact resistance and decreased heat dissipation efficiency in advance, prevent equipment failures through power limitation, and improve operation reliability. The in-depth coordination of grid parameters ensures rapid response to dispatching requirements during high load or frequency fluctuations, avoiding local grid overload. This multi-dimensional coordinated control method can balance the interests of users, devices, and the grid while ensuring safety, and solve the multi-objective conflict problem.

[0036] In a possible implementation manner, the battery state parameters include the SOH value and temperature. Based on the battery state parameters of the target charging device, a first charge-discharge control strategy for the charging pile is determined, including: Determining a charging derating coefficient based on the temperature of the target charging device and the temperature threshold; Determining a first charging current based on the SOH value, charging derating coefficient, and initial charging current of the target charging device; wherein, the initial charging current is determined based on the maximum allowable charging current, rated charging current of the target charging device, and the maximum safe charging current of the grid; Determining a first discharge current based on the maximum allowable discharge current, rated discharge current, and SOH value of the target charging device.

[0037] In this embodiment, the charge-discharge control strategy can cover three levels: judgment conditions, parameter ranges, and control instructions. The judgment conditions can involve dimensions such as battery state, charging pile state, grid state, and environmental conditions. The parameter types involved can include power parameters (maximum charging power, power adjustment step size, ramp rate), voltage / current parameters (output voltage range, current accuracy, ripple coefficient, etc.), and temperature parameters (battery allowable charging temperature, charging pile heat dissipation temperature threshold, coolant flow rate, etc.). By restricting the parameter ranges, the charging speed can be balanced with the safety of the device / grid, preventing thermal runaway and extending the device life.

[0038] For a target charging device that supports the BMS protocol, the battery status parameters, such as the SOH value and temperature, can be directly obtained through communication. When determining the first charge and discharge control strategy of the charging pile based on the battery health status of the target charging device, first calculate the temperature derating coefficient according to the deviation degree between the real-time temperature and the preset temperature threshold. Specifically, when the battery temperature exceeds the threshold, the derating ratio is dynamically adjusted through an exponential function model, so that the closer the temperature is to the safety boundary, the more significant the power reduction. For example, the temperature derating coefficient can be expressed as:

[0039] where, is the temperature derating coefficient, is the current temperature, is the preset threshold, is the temperature sensitivity coefficient. The physical meaning of this formula is that when the temperature exceeds the threshold, the derating coefficient decays exponentially, thereby non-linearly suppressing the temperature rise risk.

[0040] Subsequently, the initial charging current is corrected twice in combination with the SOH value. The initial charging current is jointly determined by the maximum charging current allowed by the battery, the safe current that the power grid can bear, and the rated current of the charging pile, that is, the minimum value of the three is selected as the benchmark. The calculation formula for the charging current is:

[0041] The calculation formula for the discharge current is:

[0042] where, is the maximum allowed charging current, is the rated charging current, is the maximum safe charging current of the power grid, is the maximum allowed discharge current, is the rated discharge current.

[0043] The square root function of the SOH value is introduced in the calculation formula of the charging current to achieve aging adaptation, so that the charging current of an aging battery (such as SOH = 80%) is reduced to about 90% of that of a new battery, which not only avoids overheating caused by increased internal resistance but also retains a reasonable charging speed.

[0044] In the discharge scenario, the maximum allowed discharge current is limited according to the SOH value to ensure that the discharge current is always within the safe range after battery aging and prevent deep discharge from accelerating capacity decay.

[0045] In a possible implementation manner, before determining the first charge and discharge control strategy of the charging pile based on the battery status parameters of the target charging device, it further includes: Based on the identity of the target charging device, search for the historical charging curve and / or historical discharging curve of the target charging device in the historical charge-discharge database; For each historical charging curve, intercept the constant-current charging interval and calculate the charging amount through integration to obtain the battery capacity corresponding to the historical charging curve; For each historical discharging curve, intercept the constant-current discharging interval and calculate the discharging amount through integration to obtain the battery capacity corresponding to the historical discharging curve; Based on the moments corresponding to each historical charging curve and / or historical discharging curve, combine each battery capacity into a battery capacity sequence; Input the battery capacity sequence into the LSTM network to obtain the battery capacity at the current moment.

[0046] In this embodiment, for scenarios where the BMS does not support obtaining battery state parameters, the system retrieves the historical charge-discharge curves of the target charging device in the historical database based on the unique identity identifier of the target charging device (such as the vehicle VIN code or battery serial number).

[0047] For each historical charging curve, identify the time interval of the constant-current charging stage, and calculate the actual charged amount by performing a time integration on the current signal in this interval. Similarly, perform the same integration operation on the constant-current discharging section in the historical discharging curve to obtain the corresponding actual discharged amount. By traversing all historical curves, the system generates a time-ordered battery capacity sequence, which reflects the decay trajectory of the battery capacity with the number of cycles or usage time. For missing values in the battery capacity sequence, interpolation can be performed for filling.

[0048] Subsequently, the system inputs the capacity sequence into a long short-term memory network (LSTM) for time series modeling. The LSTM network captures the long-term dependencies of capacity decay through internal memory units, such as the coupling effect of cycle aging and calendar aging. The network input is the historical capacity value and its corresponding timestamp, and the output is the predicted capacity at the current moment. During the training process, the LSTM network can also automatically learn the influence of different usage patterns (such as the fast charging ratio, ambient temperature distribution) on capacity decay, so as to adapt to the characteristic differences of individual batteries. Inferring the internal state by using the time series characteristics of the battery charge-discharge behavior can overcome the limitations of traditional methods that rely on real-time BMS data and provide a reliable basis for the charge-discharge strategy.

[0049] In addition, the maximum charging current and maximum discharging current in the historical data can be statistically analyzed, the median or mode of the historical charging current can be statistically analyzed as the rated charging current, and the median or mode of the historical discharging current can be statistically analyzed as the rated discharging current.

[0050] In a possible implementation, the health state parameters of the charging pile include contact resistance, cooling efficiency, and insulation resistance; based on the health state of the charging pile, a second charge and discharge control strategy for the charging pile is determined, including: Determine the contact resistance derating factor based on the ratio of the contact resistance to the initial contact resistance; Determine the insulation resistance derating factor based on the insulation resistance, the safety threshold, and the danger threshold; Determine the cooling efficiency derating factor based on the ratio of the cooling efficiency to the rated cooling efficiency; Multiply the contact resistance derating factor, the insulation resistance derating factor, and the cooling efficiency derating factor by the initial charging power to obtain the charging power of the second charge and discharge control strategy; Multiply the contact resistance derating factor, the insulation resistance derating factor, and the cooling efficiency derating factor by the initial discharge power to obtain the discharge power of the second charge and discharge control strategy.

[0051] In this embodiment, when determining the second charge and discharge control strategy, the system first calculates the contact resistance derating factor based on the ratio of the real-time measured value of the contact resistance to its initial calibrated value. Specifically, this factor reflects the impact of the increase in contact resistance on power loss through a square root relationship. The calculation formula for the contact resistance derating factor is:

[0052] where, is the initial contact resistance value calibrated at the factory, is the current measured value. This design balances the joule heat effect and equipment availability through non-linear derating - when the contact resistance doubles due to oxidation or wear, the power is derated to about 70% of the initial value, which not only avoids overheating and melting of the connector but also retains reasonable power supply capacity.

[0053] For the insulation resistance, the system determines the derating factor according to the position of the real-time measured value between the safety threshold and the danger threshold. When the insulation resistance is between the safety threshold (such as 500Ω / V) and the danger threshold (such as 100Ω / V), the lower the insulation resistance, the more significant the derating, which directly reflects the risk of leakage current. If the insulation resistance is lower than the danger threshold, the output is forcibly cut off to ensure safety. This mechanism can identify the leakage risk caused by moisture, contamination, or insulation aging. For example, when the insulation resistance drops to 80kΩ due to rain intrusion, the system automatically limits the power to 60% of the safe level and triggers a drainage and dehumidification maintenance instruction.

[0054] The cooling efficiency derating factor is directly determined by the ratio of the real-time heat dissipation capacity to the rated capacity. The actual heat dissipation capacity is calculated by the product of the coolant flow rate and the temperature difference. If the liquid cooling pump fails and the flow rate is halved, the heat dissipation capacity drops synchronously, and the system derates the power proportionally to avoid overheating of the power devices.

[0055] Finally, the power command of the second charge and discharge control strategy is generated by multiplying the initial power by each derating factor. The initial charging power is obtained by taking the minimum value among the maximum charging power allowed by the battery, the available charging power allocated by the grid, and the nominal rated charging power of the charging pile. The initial discharging power is obtained by taking the minimum value among the maximum discharging power allowed by the battery, the reverse feeding power allowed by the grid, and the nominal rated discharging power of the charging pile.

[0056] In a possible implementation, the grid state parameters include the PCC point voltage sequence and the PCC point frequency sequence; based on the grid state parameters, determining the third charge and discharge control strategy of the charging pile includes: Calculating the cosine similarity between the PCC point voltage sequence and the PCC point voltage sequences of multiple preset grid standard states as the first cosine similarity; Calculating the cosine similarity between the PCC point frequency sequence and the PCC point frequency sequences of multiple preset grid standard states as the second cosine similarity; Calculating the difference between the average voltage of the PCC point voltage sequence and the average voltages of the PCC point voltage sequences of multiple preset grid standard states; Calculating the difference between the average frequency of the PCC point frequency sequence and the average frequencies of the PCC point frequency sequences of multiple preset grid standard states; For each grid standard state, normalizing and weighted summing the first cosine similarity, the second cosine similarity, the reciprocal of the average voltage difference, and the reciprocal of the average frequency difference corresponding to this grid standard state as the similarity between this grid standard state and the PCC point voltage sequence and the PCC point frequency sequence; Taking the charge and discharge control strategy corresponding to the grid standard state with the highest similarity as the third charge and discharge control strategy of the charging pile.

[0057] In this embodiment, the grid state parameters include the voltage sequence and the frequency sequence of the point of common coupling (PCC).

[0058] When determining the third charge and discharge control strategy, first calculate the cosine similarity between the real-time collected voltage sequence and the voltage sequences corresponding to multiple preset grid standard states, and this value reflects the morphological similarity of the voltage waveforms. Similarly, calculate the cosine similarity between the frequency sequence and the standard frequency sequence. At the same time, the system calculates the absolute deviation between the current voltage sequence average value and the voltage mean values of each standard state, as well as the frequency mean deviation. To balance the dimensional difference, take the reciprocal of the deviation value and normalize it. Finally, the comprehensive similarity of each standard state is calculated as the similarity through weighted fusion.

[0059] This calculation method dynamically identifies the typical mode to which the current working condition of the power grid belongs (such as normal power supply, photovoltaic surplus, sudden load increase, etc.) through waveform similarity matching and mean shift analysis. The cosine similarity captures the dynamic fluctuation characteristics of voltage / frequency, and the mean deviation reflects the steady-state offset degree. The combination of the two can avoid misjudgment of a single index. For example, when the photovoltaic fluctuation causes periodic distortion of the voltage, the cosine similarity can effectively match the preset standard state of "high-penetration new energy", and the mean deviation helps to exclude the interference of temporary disturbances, thereby improving the adaptability of the charging pile to the complex power grid environment. Especially in areas with a high proportion of renewable energy, it can automatically switch to a control mode suitable for the current power grid stability, avoiding misoperation of protection and enhancing the active support ability for the power grid.

[0060] In a possible implementation manner, before determining the third charge and discharge control strategy of the charging pile based on the power grid state parameters, it further includes: Obtain the historical charge and discharge control strategies of multiple charging piles and the corresponding PCC point voltage sequences and PCC point frequency sequences; For each historical charge and discharge control strategy, cluster each group of PCC point voltage sequences and PCC point frequency sequences based on similarity to obtain multiple clusters; Take each cluster as a power grid standard state, and take the PCC point voltage sequence and PCC point frequency sequence corresponding to the cluster center of the cluster as the PCC point voltage sequence and PCC point frequency sequence corresponding to the power grid standard state.

[0061] In this embodiment, before determining the third charge and discharge control strategy, the system constructs a power grid standard state library by analyzing historical data. Specifically, the system obtains the historical charge and discharge control strategies of multiple charging piles and their corresponding PCC point voltage sequences and frequency sequences to form a data sample set. For each historical control strategy (such as constant power charging, frequency modulation discharge, etc.), the system takes the associated voltage-frequency sequence group as the input and performs cluster analysis through similarity measurement.

[0062] Calculate the similarity in the same way as in the previous embodiment, and divide the sequences with similar fluctuation patterns into the same cluster through a clustering algorithm (such as DBSCAN or K-means). Each cluster represents a typical power grid operation state.

[0063] After clustering, the system takes the voltage sequence and frequency sequence corresponding to the centroid of each cluster as the reference features of the power grid standard state and establishes a mapping relationship with the original historical control strategy. For example, the voltage sequence of a certain cluster shows small periodic fluctuations and the frequency mean is stable, which may correspond to the "conventional load" standard state, and its associated strategy is to allow maximum power charging; the voltage sequence of another cluster has high-frequency disturbances and the frequency continues to be low, then it is mapped to the "weak power grid" standard state, and the associated strategy is to limit the charging power and enable reactive power compensation.

[0064] In this embodiment, unsupervised learning is used to mine the implicit grid operating conditions patterns in historical data, dynamically associating discrete control strategies with continuously changing grid states. Compared with manually defining standard states, the data-driven clustering process can adaptively capture local grid characteristics (such as distributed power generation penetration rate, line impedance distribution), making the generated standard state library more regionally adaptable and time-effective.

[0065] On the one hand, the typical states are characterized by clustering centroids, reducing the computational complexity of real-time pattern matching; on the other hand, the mapping relationship between historical strategies and state clusters provides data support for optimizing control strategies and improves control efficiency.

[0066] During the implementation process, the standard state library supports dynamic updates: when a new grid fluctuation pattern (such as sub-synchronous oscillation caused by the addition of a new wind farm) is detected, the system re-clusters the new data samples and generates an expanded state library to ensure that the third control strategy always adapts to grid evolution. This self-evolution mechanism enables the charging pile to maintain high-precision state recognition and control response even when the grid topology changes or a large-scale access of new energy occurs, avoiding strategy failures caused by an outdated standard state library.

[0067] In a possible implementation, the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy are fused as the target charge and discharge control strategy of the charging pile, including: Calculating the weight of the first charge and discharge control strategy based on the SOC value of the target charging device and a preset SOC threshold; Calculating the weight of the second charge and discharge control strategy based on the contact resistance, cooling efficiency, insulation resistance of the charging pile and preset contact resistance threshold, cooling efficiency threshold, insulation resistance threshold; Calculating the weight of the third charge and discharge control strategy based on the grid load rate and a preset grid load rate threshold; Performing weighted summation on the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy based on each weight to obtain the target charge and discharge control strategy of the charging pile.

[0068] In this embodiment, the fusion of the target charge-discharge control strategy is achieved through dynamic weight allocation. Specifically, the system calculates the first strategy weight based on the deviation degree of the SOC value of the target charging device from its preset threshold (such as 20%). When the SOC is lower than the threshold, the weight increases linearly as the SOC decreases, reflecting the principle of prioritizing emergency charging needs. For example, the non-linear relationship between SOC and weight is mapped through a piecewise function. For the health state of the charging pile, the system combines the relative relationship between the real-time measured values of contact resistance, cooling efficiency, and insulation resistance and their corresponding thresholds, and uses the geometric mean method to generate the second strategy weight. If any parameter exceeds the limit, the weight is significantly increased to force the triggering of protective derating. For example, when the contact resistance exceeds the threshold, the weight response curve shows a step characteristic. The grid load rate weight increases according to the square relationship with the ratio of its exceeding the preset threshold (such as 80%), so as to strengthen the grid support priority in high-load scenarios.

[0069] In the above embodiment, the first charge-discharge control strategy is the limit value of the charge-discharge current, the second charge-discharge control strategy is the limit value of the charge-discharge power, and the charge-discharge parameters involved in the third charge-discharge control strategy include power, frequency response parameters, and voltage. When the output parameter types of the three control strategies are different, the charge-discharge current of the first charge-discharge control strategy can be converted into charge-discharge power by using the bus voltage, and the power commands of the second and third charge-discharge control strategies remain in the original unit. Thus, the parameter dimensions of the three strategies are unified, and weighted summation can be performed. After each weight is calculated, the system ensures that the sum is 1 through normalization processing to avoid exceeding the power command limit. The control of the charging pile will ultimately be implemented in the adjustment of power or current, and the final target strategy is the weighted sum of the power commands of each strategy. In specific implementation, the parameters of the weight function can be dynamically optimized through machine learning.

[0070] In this embodiment, by quantifying the competition relationship between multiple objectives, the user's needs (fast charging with low SOC), device safety (health degradation protection), and grid interaction (load rate regulation) are dynamically fused. For example, when the SOC is extremely low and the grid load rate is moderate, the first strategy weight dominates, allowing short-term over-rated power charging; if the cooling efficiency of the charging pile drops suddenly at this time, the second strategy weight rises and triggers derating to balance the charging speed and device reliability. Its technical effect is to replace the traditional binary decision-making (such as complete shutdown or full-power operation) through a continuously adjustable weight mechanism, achieve smooth transition and global optimization under complex working conditions, and at the same time strengthen the priority of key constraints through the non-linear characteristics (such as square, exponential) of the weight function to ensure the safety bottom line in extreme scenarios.

[0071] It should be understood that the magnitudes of the sequence numbers of the steps in the above embodiments do not mean the order of execution. The execution order of each process should be determined according to its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.

[0072] The following is an apparatus embodiment of the present invention. For details not described in detail herein, reference may be made to the corresponding method embodiment above.

[0073] Figure 2 Fig. 5 shows a schematic structural diagram of a charge and discharge control device provided by an embodiment of the present invention. For the sake of convenience of description, only the parts related to the embodiment of the present invention are shown and are described in detail as follows: As Figure 2 shown, a charge and discharge control device 2 includes: A first determination module 21, configured to determine a first charge and discharge control strategy of a charging pile based on battery state parameters of a target charging device; A second determination module 22, configured to determine a second charge and discharge control strategy of the charging pile based on health state parameters of the charging pile; A third determination module 23, configured to determine a third charge and discharge control strategy of the charging pile based on grid state parameters; A fusion control module 24, configured to fuse the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy as a target charge and discharge control strategy of the charging pile, so as to perform charge and discharge control on the charging pile based on the target charge and discharge control strategy.

[0074] In a possible implementation manner, the battery state parameters include an SOH value and a temperature. The first determination module 21 is specifically configured to: Determine a charging derating coefficient based on the temperature of the target charging device and a temperature threshold; Determine a first charging current based on the SOH value, the charging derating coefficient, and an initial charging current of the target charging device; wherein, the initial charging current is determined based on the maximum allowable charging current and the rated charging current of the target charging device and the maximum safe charging current of the grid; Determine a first discharging current based on the maximum allowable discharging current, the rated discharging current, and the SOH value of the target charging device.

[0075] In a possible implementation manner, the first determination module 21 is further configured to: Before determining the first charge and discharge control strategy of the charging pile based on the battery state parameters of the target charging device, look up the historical charging curve and / or historical discharging curve of the target charging device in a historical charge and discharge database based on the identity of the target charging device; For each historical charging curve, intercept the constant current charging interval and calculate the charging amount by integration to obtain the battery capacity corresponding to the historical charging curve; For each historical discharging curve, intercept the constant current discharging interval and calculate the discharging amount by integration to obtain the battery capacity corresponding to the historical discharging curve; Based on the moments corresponding to each historical charging curve and / or historical discharging curve, combine each battery capacity into a battery capacity sequence; Input the battery capacity sequence into the LSTM network to obtain the battery capacity at the current moment.

[0076] In a possible implementation, the health status parameters of the charging pile include contact resistance, cooling efficiency, and insulation resistance; the second determination module 22 is specifically configured to: Based on the ratio of the contact resistance to the initial contact resistance, determine the contact resistance derating factor; Based on the insulation resistance, safety threshold, and danger threshold, determine the insulation resistance derating factor; Based on the ratio of the cooling efficiency to the rated cooling efficiency, determine the cooling efficiency derating factor; Multiply the contact resistance derating factor, insulation resistance derating factor, and cooling efficiency derating factor by the initial charging power to obtain the charging power of the second charge and discharge control strategy; Multiply the contact resistance derating factor, insulation resistance derating factor, and cooling efficiency derating factor by the initial discharging power to obtain the discharging power of the second charge and discharge control strategy.

[0077] In a possible implementation, the grid state parameters include the PCC point voltage sequence and the PCC point frequency sequence; the third determination module 23 is specifically configured to: Calculate the cosine similarity between the PCC point voltage sequence and the PCC point voltage sequences of multiple preset grid standard states as the first cosine similarity; Calculate the cosine similarity between the PCC point frequency sequence and the PCC point frequency sequences of multiple preset grid standard states as the second cosine similarity; Calculate the difference between the average voltage of the PCC point voltage sequence and the average voltages of the PCC point voltage sequences of multiple preset grid standard states; Calculate the difference between the average frequency of the PCC point frequency sequence and the average frequencies of the PCC point frequency sequences of multiple preset grid standard states; For each grid standard state, perform normalization processing and weighted summation on the first cosine similarity, second cosine similarity, reciprocal of the average voltage difference, and reciprocal of the average frequency difference corresponding to this grid standard state as the similarity between this grid standard state and the PCC point voltage sequence and the PCC point frequency sequence; Use the charge and discharge control strategy corresponding to the grid standard state with the highest similarity as the third charge and discharge control strategy of the charging pile.

[0078] In a possible implementation, the third determination module 23 is further configured to: Before determining the third charge and discharge control strategy of the charging pile based on the grid state parameters, obtain the historical charge and discharge control strategies of multiple charging piles, as well as the corresponding PCC point voltage sequences and PCC point frequency sequences; For each historical charge and discharge control strategy, cluster each group of PCC point voltage sequences and PCC point frequency sequences based on similarity to obtain multiple clusters; Take each cluster as a grid standard state, and take the PCC point voltage sequence and PCC point frequency sequence corresponding to the cluster center of the cluster as the PCC point voltage sequence and PCC point frequency sequence corresponding to the grid standard state.

[0079] In a possible implementation, the fusion control module 24 is specifically configured to: Calculate the weight of the first charge and discharge control strategy based on the SOC value of the target charging device and a preset SOC threshold; Calculate the weight of the second charge and discharge control strategy based on the contact resistance, cooling efficiency, insulation resistance of the charging pile, and preset contact resistance threshold, cooling efficiency threshold, insulation resistance threshold; Calculate the weight of the third charge and discharge control strategy based on the grid load rate and a preset grid load rate threshold; Perform weighted summation on the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy based on each weight to obtain the target charge and discharge control strategy of the charging pile.

[0080] In the embodiments of the present invention, by hierarchically obtaining battery state parameters, charging pile operating states, and real-time grid parameters, and generating multi-dimensional control strategies accordingly, and finally fusing them into a dynamically optimized target charge and discharge strategy, it breaks through the limitations of traditional single-dimensional control. The adaptive strategy based on the battery state can actively derate for abnormal working conditions such as aging or low temperature, avoid irreversible damage caused by overcharging and over-discharging, and extend the battery life; the real-time assessment of the charging pile health state can identify potential hazards such as increased contact resistance and decreased heat dissipation efficiency in advance, prevent equipment failures through power limitation, and improve operation reliability; the in-depth coordination of grid parameters ensures rapid response to dispatching requirements during high load or frequency fluctuations, and avoids local grid overload. This multi-dimensional cooperative control method can balance the interests of users, equipment, and the grid under the premise of ensuring safety, and solve the problem of multi-objective conflicts.

[0081] Figure 3 It is a schematic diagram of the terminal provided by the embodiments of the present invention. As Figure 3As shown in the figure, the terminal 3 of this embodiment includes: a processor 30, a memory 31, and a computer program 32 stored in the memory 31 and executable on the processor 30. When the processor 30 executes the computer program 32, the steps in each of the above-described embodiments of the charge and discharge control method are implemented. Alternatively, when the processor 30 executes the computer program 32, the functions of each module / unit in each of the above-described device embodiments are implemented.

[0082] Exemplarily, the computer program 32 can be divided into one or more modules / units, and the one or more modules / units are stored in the memory 31 and executed by the processor 30 to complete the present invention. The one or more modules / units can be a series of computer program instruction segments capable of performing specific functions, and these instruction segments are used to describe the execution process of the computer program 32 in the terminal 3.

[0083] The terminal 3 can be a computing device such as a desktop computer, a notebook, a palm computer, and a cloud server. The terminal 3 may include, but is not limited to, a processor 30 and a memory 31. Those skilled in the art can understand that Figure 3 merely examples of the terminal 3, which do not constitute a limitation on the terminal 3, may include more or fewer components than shown in the figure, or combine certain components, or different components. For example, the terminal may further include input / output devices, network access devices, a bus, etc.

[0084] The so-called processor 30 may be a central processing unit (CPU), or may also be other general-purpose processors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor, or the processor may also be any conventional processor, etc.

[0085] The memory 31 may be an internal storage unit of the terminal 3, such as a hard disk or memory of the terminal 3. The memory 31 may also be an external storage device of the terminal 3, such as a plug-in hard disk equipped on the terminal 3, a Smart Media Card (SMC), a Secure Digital (SD) card, a Flash Card, etc. Further, the memory 31 may also include both the internal storage unit of the terminal 3 and external storage devices. The memory 31 is used to store the computer program and other programs and data required by the terminal. The memory 31 may also be used to temporarily store data that has been output or is to be output.

[0086] Those skilled in the art can clearly understand that, for the convenience and brevity of description, only the above-mentioned division of each functional unit and module is used as an example. In actual applications, the above functions can be allocated to different functional units and modules according to needs, that is, the internal structure of the device is divided into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated unit can be implemented in the form of hardware or in the form of a software functional unit. In addition, the specific names of each functional unit and module are only for the convenience of mutual distinction and do not limit the protection scope of this application. The specific working process of the units and modules in the above system can refer to the corresponding process in the foregoing method embodiment and will not be elaborated here.

[0087] In the above embodiments, the descriptions of the respective embodiments have their own emphases. For parts not detailed or recorded in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0088] Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be implemented by electronic hardware, or by a combination of computer software and electronic hardware. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present invention.

[0089] In the embodiments provided by the present invention, it should be understood that the disclosed device / terminal and method can be implemented in other ways. For example, the device / terminal embodiments described above are merely illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces. The indirect couplings or communication connections of the devices or units can be in electrical, mechanical or other forms.

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

[0091] In addition, in each embodiment of the present invention, the functional units can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

[0092] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, to implement all or part of the processes in the above method embodiments of the present invention, it can also be completed by a computer program instructing relevant hardware. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by a processor, the steps of the above various embodiments of a charge and discharge control method can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in the form of source code, object code, executable file or some intermediate form, etc. The computer-readable medium can include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium, etc. It should be noted that the content included in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, the computer-readable medium does not include electrical carrier signals and telecommunication signals.

[0093] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention, and should all be included within the protection scope of the present invention.

Claims

1. A charge and discharge control method, characterized in that Including: Determine the first charge-discharge control strategy of the charging pile based on the battery state parameters of the target charging device; Determine the second charge-discharge control strategy of the charging pile based on the health state parameters of the charging pile; Determine the third charge-discharge control strategy of the charging pile based on the grid state parameters; Fuse the first charge-discharge control strategy, the second charge-discharge control strategy, and the third charge-discharge control strategy as the target charge-discharge control strategy of the charging pile, so as to control the charging and discharging of the charging pile based on the target charge-discharge control strategy.

2. The charge and discharge control method according to claim 1, wherein The battery state parameters include the SOH value and temperature. The determining the first charge-discharge control strategy of the charging pile based on the battery state parameters of the target charging device includes: Determine the charging derating coefficient based on the temperature of the target charging device and the temperature threshold; Determine the first charging current based on the SOH value of the target charging device, the charging derating coefficient, and the initial charging current; wherein, the initial charging current is determined based on the maximum allowable charging current and the rated charging current of the target charging device and the maximum safe charging current of the grid; Determine the first discharge current based on the maximum allowable discharge current, the rated discharge current of the target charging device, and the SOH value.

3. The charge and discharge control method according to claim 2, characterized in that, Before determining the first charge-discharge control strategy of the charging pile based on the battery state parameters of the target charging device, it further includes: Based on the identity of the target charging device, search for the historical charging curve and / or historical discharge curve of the target charging device in the historical charge-discharge database; For each historical charging curve, intercept the constant current charging interval and calculate the charging amount by integration to obtain the battery capacity corresponding to the historical charging curve; For each historical discharge curve, intercept the constant current discharge interval and calculate the discharge amount by integration to obtain the battery capacity corresponding to the historical discharge curve; Based on the moments corresponding to each historical charging curve and / or historical discharge curve, combine each battery capacity into a battery capacity sequence; Input the battery capacity sequence into the LSTM network to obtain the battery capacity at the current moment.

4. The charge and discharge control method according to claim 1, wherein The health state parameters of the charging pile include contact resistance, cooling efficiency, and insulation resistance; the determining the second charge-discharge control strategy of the charging pile based on the health state of the charging pile includes: Determine the contact resistance derating coefficient based on the ratio of the contact resistance to the initial contact resistance; Determine the insulation resistance derating coefficient based on the insulation resistance, the safety threshold, and the danger threshold; Determine the cooling efficiency derating coefficient based on the ratio of the cooling efficiency to the rated cooling efficiency; Multiply the contact resistance derating coefficient, the insulation resistance derating coefficient, and the cooling efficiency derating coefficient by the initial charging power to obtain the charging power of the second charge-discharge control strategy; Multiply the contact resistance derating coefficient, the insulation resistance derating coefficient, and the cooling efficiency derating coefficient by the initial discharge power to obtain the discharge power of the second charge-discharge control strategy.

5. The charge and discharge control method according to claim 1, wherein The grid state parameters include the PCC point voltage sequence and the PCC point frequency sequence; The determining the third charge-discharge control strategy of the charging pile based on the grid state parameters includes: Calculate the cosine similarity between the PCC point voltage sequence and the PCC point voltage sequences of multiple preset grid standard states as the first cosine similarity; Calculate the cosine similarity between the PCC point frequency sequence and the PCC point frequency sequences of multiple preset grid standard states as the second cosine similarity; Calculate the difference between the average voltage of the PCC point voltage sequence and the average voltages of the PCC point voltage sequences of multiple preset grid standard states; Calculate the difference between the average frequency of the PCC point frequency sequence and the average frequencies of the PCC point frequency sequences of multiple preset grid standard states; For each grid standard state, perform normalization processing and weighted summation on the first cosine similarity, the second cosine similarity, the reciprocal of the average voltage difference, and the reciprocal of the average frequency difference corresponding to this grid standard state as the similarity between this grid standard state and the PCC point voltage sequence and the PCC point frequency sequence; Use the charge and discharge control strategy corresponding to the grid standard state with the highest similarity as the third charge and discharge control strategy of the charging pile.

6. The charge and discharge control method according to claim 5, characterized in that Before determining the third charge and discharge control strategy of the charging pile based on the grid state parameters, it further includes: Obtain the historical charge and discharge control strategies of multiple charging piles and the corresponding PCC point voltage sequences and PCC point frequency sequences; For each historical charge and discharge control strategy, cluster each group of PCC point voltage sequences and PCC point frequency sequences based on similarity to obtain multiple clustering clusters; Use each clustering cluster as a grid standard state, and use the PCC point voltage sequence and PCC point frequency sequence corresponding to the clustering center of this clustering cluster as the PCC point voltage sequence and PCC point frequency sequence corresponding to the grid standard state.

7. The charge and discharge control method according to claim 1, wherein The step of fusing the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy as the target charge and discharge control strategy of the charging pile includes: Calculate the weight of the first charge and discharge control strategy based on the SOC value of the target charging device and a preset SOC threshold; Calculate the weight of the second charge and discharge control strategy based on the contact resistance, cooling efficiency, insulation resistance of the charging pile and preset contact resistance threshold, cooling efficiency threshold, insulation resistance threshold; Calculate the weight of the third charge and discharge control strategy based on the grid load rate and a preset grid load rate threshold; Perform weighted summation on the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy based on each weight to obtain the target charge and discharge control strategy of the charging pile.

8. A charge and discharge control device, characterized in that It includes: A first determination module for determining the first charge and discharge control strategy of the charging pile based on the battery state parameters of the target charging device; A second determination module for determining the second charge and discharge control strategy of the charging pile based on the health state parameters of the charging pile; A third determination module for determining the third charge and discharge control strategy of the charging pile based on the grid state parameters; The fusion control module is used to fuse the first charge and discharge control strategy, the second charge and discharge control strategy, and the third charge and discharge control strategy as the target charge and discharge control strategy of the charging pile, so as to control the charging and discharging of the charging pile based on the target charge and discharge control strategy.

9. A terminal, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 7 above.

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