Charging metering port switching method and circuit
By introducing a channel selection and switching module into the charging pile, combined with RS485 and optocoupler conversion modules, the problems of inconsistent charging pile interface standards and protocol incompatibility are solved, achieving efficient compatibility and safe charging for different electricity meters.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- XIAN LINCHR NEW ENERGY TECH CO LTD
- Filing Date
- 2025-10-31
- Publication Date
- 2026-06-26
AI Technical Summary
Existing charging stations suffer from inconsistent interface standards and incompatible communication protocols, making it difficult to charge electric vehicles of different brands, thus affecting charging efficiency and safety.
A charging metering port switching method and circuit are adopted. Through a channel selection module and a channel switching module, the charging metering port switching between the target electricity meter and the charging pile processor is realized. An RS485 conversion module and an optocoupler conversion module are used to convert different types of electricity meter signals, and a protection filtering module is used to enhance the anti-interference capability.
It improves the compatibility of charging piles, reduces the design cost of charging piles, and enhances communication reliability and security.
Smart Images

Figure CN121291183B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of charging pile technology, and more specifically, to a charging metering port switching method and circuit. Background Technology
[0002] With the rapid development of electric vehicles and charging pile technology, charging piles have been deployed on a large scale in various locations to meet users' charging needs.
[0003] With the increasing charging demand driven by the widespread adoption of electric vehicles, existing charging stations face compatibility issues, such as inconsistent interface standards and incompatible communication protocols. This leads to charging difficulties for electric vehicles of different brands, affecting charging efficiency and safety. To address these problems, researchers have proposed optimization strategies aimed at improving charging station compatibility, reducing design costs, and promoting the healthy development of the electric vehicle industry by unifying standards and specifications. Summary of the Invention
[0004] The purpose of this application is to address the shortcomings of the prior art by providing a charging metering port switching method and circuit to achieve high compatibility between different types of electricity meters.
[0005] To achieve the above objectives, the technical solutions adopted in the embodiments of this application are as follows:
[0006] In a first aspect, embodiments of this application provide a charging metering port switching method, applied to a charging pile processor in a charging metering port switching circuit. The charging metering port switching circuit further includes: a channel selection module, multiple signal conversion modules, and a channel switching module. The method includes:
[0007] Obtain the meter type of the target meter;
[0008] Based on the type of the target electricity meter, determine the signal type and signal protocol format of the target electricity meter;
[0009] Based on the signal type of the target meter, a first control signal is generated and the first target channel of the channel selection module is turned on, so that the target meter is connected to the target signal conversion module through the first target channel, and the meter signal of the target meter is converted by the target signal conversion module to obtain the converted meter signal.
[0010] According to the signal protocol format of the target meter, a second control signal is generated and the second target path of the channel switching module is turned on, so as to send the converted meter signal through the second target path and complete the switching of the charging metering port.
[0011] Optionally, obtaining the meter type of the target meter includes:
[0012] If the charging pile is detected to be connected to the target electricity meter, the signal feature vector of the target electricity meter is obtained;
[0013] The type of the target meter is determined based on the signal feature vector.
[0014] Optionally, the charging metering port switching circuit further includes: a signal detection module, wherein acquiring the signal feature vector of the target meter includes:
[0015] The original waveform data is sampled by the signal detection module.
[0016] Based on the multi-dimensional features of the original waveform data, the signal feature vector is generated. The multi-dimensional features include at least: signal amplitude, frequency, and data frame format.
[0017] Optionally, determining the signal type and signal protocol format of the target electricity meter based on its meter type includes:
[0018] The meter type is sent to a cloud database, which stores meter parameter information corresponding to various meter types, so as to determine the meter parameter information of the target meter from the cloud database according to the meter type.
[0019] The meter parameter information sent by the cloud database is received. The meter parameter information includes at least the signal type and the signal protocol format.
[0020] Optionally, the meter parameter information further includes: data parsing rules, and the method further includes:
[0021] The converted meter signal is analyzed according to the data parsing rules.
[0022] Secondly, embodiments of this application also provide a charging metering port switching circuit, the charging metering port switching comprising: a charging pile processor, a channel selection module, multiple signal conversion modules, and a channel switching module. The input terminal of the channel selection module is used to connect to the target electricity meter connected to the charging pile. The multiple output terminals of the channel selection module are respectively connected to the multiple signal conversion modules. The multiple signal conversion modules are connected to the channel switching module. The output terminal of the channel switching module is connected to the charging pile processor. The charging pile processor is also connected to the control terminal of the channel selection module and the control terminal of the channel switching module. The charging pile processor executes the charging metering port switching method as described in any of the first aspects to realize signal transmission between the target electricity meter and the charging pile processor.
[0023] Optionally, the plurality of signal conversion modules include: an RS485 conversion module, which is used to convert digital meter signals into serial port signals.
[0024] Optionally, the plurality of signal conversion modules include: an optocoupler conversion module, which is used to convert analog meter signals into serial port signals. The optocoupler conversion module includes: an optocoupler, a first resistor, a second resistor, a third resistor, a fourth resistor, a transistor, and a positive feedback unit. The positive feedback unit includes: a fifth resistor and a first capacitor connected in parallel.
[0025] One end of the first resistor serves as the positive input terminal of the optocoupler conversion module, and the other end of the first resistor is connected to the anode of the diode of the optocoupler. The cathode of the diode of the optocoupler serves as the negative input terminal of the optocoupler conversion module.
[0026] The collector of the phototransistor in the optocoupler is connected to one end of the second resistor and the base of the transistor, and the collector of the transistor and the other end of the second resistor are connected to the power supply.
[0027] The base of the phototransistor is grounded through the third resistor, the emitter of the phototransistor and one end of the fourth resistor are connected to the output terminal of the optocoupler conversion module, and the other end of the fourth resistor and the emitter of the phototransistor are grounded.
[0028] The base of the phototransistor is also connected to the output of the optocoupler module through the positive feedback unit.
[0029] Optionally, the charging metering port switching circuit further includes: a protection filtering module, which is connected between the plurality of signal conversion modules and the channel switching module; the protection filtering module includes: a current limiting resistor unit, a transient protection unit, a filtering unit, and a common mode inductor; the current limiting resistor unit includes: a sixth resistor and a seventh resistor; the transient protection unit includes: a TVS diode, a first ESD diode, and a second ESD diode; the filtering unit includes: a second capacitor and a third capacitor.
[0030] The sixth resistor is connected to the first input terminal of the common-mode inductor, the seventh resistor is connected to the second input terminal of the common-mode inductor, the second capacitor is connected between the first output terminal of the common-mode inductor and ground, the third capacitor is connected between the second output terminal of the common-mode inductor and ground, the TVS diode is connected between the first input terminal and the second input terminal of the common-mode inductor, the first ESD diode is connected between the second input terminal of the common-mode inductor and ground, and the second ESD diode is connected between the first input terminal of the common-mode inductor and ground.
[0031] Optionally, the channel selection module is a magnetic latching relay, the input terminal of the magnetic latching relay is used to connect to the target meter, and the multiple output terminals of the magnetic latching relay are respectively connected to the multiple signal conversion modules;
[0032] The channel switching module is a multiplexer, each input terminal of which is connected to the output terminal of the multiple signal conversion modules, and the output terminal of which is connected to the charging pile processor.
[0033] The beneficial effects of this application are:
[0034] The charging metering port switching method and circuit provided in this application realize the switching of the charging metering port between the target electricity meter and the charging pile processor through a channel selection module and a channel switching module. This allows the electricity meter signal of the target electricity meter to be sent to the charging pile processor through the first target channel and the second target channel. Based on the channel selection module, multiple signal switching circuits and the channel switching module, the charging metering port switching circuit can be adapted to various types of electricity meters without considering the differences in the interfaces of different electricity meters, thereby improving the compatibility of the charging pile and reducing the cost of the charging pile. Attached Figure Description
[0035] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0036] Figure 1 A schematic block diagram of the charging metering port switching circuit provided in an embodiment of this application;
[0037] Figure 2 A schematic diagram of the RS485 conversion module provided in an embodiment of this application;
[0038] Figure 3 A schematic diagram of the optical coupler conversion module provided in an embodiment of this application;
[0039] Figure 4 A schematic diagram of the protection filtering module provided in an embodiment of this application;
[0040] Figure 5 A schematic diagram of the channel selection module provided in an embodiment of this application;
[0041] Figure 6 A schematic diagram of the channel switching module provided in an embodiment of this application;
[0042] Figure 7This is a flowchart illustrating the charging metering port switching method provided in an embodiment of this application. Detailed Implementation
[0043] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are some embodiments of this application, but not all embodiments.
[0044] Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0045] Furthermore, the terms "first," "second," etc., used in the specification, claims, 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. Additionally, the terms "comprising" and "having," and any variations thereof, are intended to cover a 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.
[0046] It should be noted that, where there is no conflict, the features in the embodiments of this application can be combined with each other.
[0047] To better understand the charging metering port switching method provided in this application, the specific implementation of the charging metering port switching circuit provided in this application will be explained below.
[0048] Figure 1 This is a schematic block diagram of the charging metering port switching circuit provided in an embodiment of this application, as shown below. Figure 1 As shown, the charging metering port switching circuit may include: a charging pile processor 10, a channel selection module 20, multiple signal conversion modules 30, and a channel switching module 40. The input terminal of the channel selection module 20 is used to connect to the target electricity meter connected to the charging pile. The multiple output terminals of the channel selection module 20 are respectively connected to the multiple signal conversion modules 30. The multiple signal conversion modules 30 are connected to the channel switching module 40. The output terminal of the channel switching module 40 is connected to the charging pile processor 10. The charging pile processor 10 is also connected to the control terminal of the channel selection module 20 and the control terminal of the channel switching module 40.
[0049] The channel selection module 20 has multiple channels between its input and multiple output terminals. Each output terminal is connected to a signal conversion module 30, so that different types of meter signals can enter different signal conversion modules 30 through different channels for signal conversion, so as to convert different types of meter signals into the same type of meter signal.
[0050] After conversion, the meter signal enters the channel switching module 40. The channel switching module 40 also forms multiple channels between the signal conversion module 30 and the charging pile processor 10. Unlike the multiple channels of the channel selection module 20, the multiple channels of the channel switching module 40 are not for different types of meter signals, but for meter signals with different protocol formats. The different channels provided by the channel switching module 40 transmit meter signals with different protocol formats, ensuring that the processor can correctly receive and parse the meter signal.
[0051] The charging pile processor 10 controls the first target channel of the channel selection module 20 to be turned on and the second target channel of the channel switching module 40 to be turned on, according to the type of electricity meter, so as to realize the switching of the charging metering port between the target electricity meter and the charging pile processor 10, so that the electricity meter signal of the target electricity meter can be sent to the charging pile processor 10 through the first target channel and the second target channel.
[0052] The charging metering port switching circuit provided in the above embodiments realizes the switching of the charging metering port between the target meter and the charging pile processor through the channel selection module and the channel switching module, so that the meter signal of the target meter can be sent to the charging pile processor through the first target channel and the second target channel. Based on the channel selection module, multiple signal switching circuits and the channel switching module, the charging metering port switching circuit can be adapted to various types of meters without considering the differences in the interfaces of different meters, thereby improving the compatibility of the charging pile and reducing the cost of the charging pile.
[0053] In one possible implementation, the target meter is a digital signal meter. For a digital signal meter, an RS485 conversion module can be used to convert the digital meter signal into an asynchronous serial communication signal, i.e., a serial port signal, that can be recognized by the processor's hardware interface. The multiple signal conversion modules 30 may include at least an RS485 conversion module. Figure 2 This is a schematic diagram of the RS485 conversion module provided in an embodiment of this application, as shown below. Figure 2As shown, the RS485 conversion module includes: an RS485 transceiver, with each power terminal of the RS485 transceiver connected to a power supply, and each ground terminal grounded; capacitor C4 connected between the first power terminal VDD1 and the first ground terminal GND1 of the RS485 transceiver, and capacitor C5 connected between the second power terminal VDD2 and the second ground terminal GND2 of the RS485 transceiver; the B terminal and A terminal of the RS485 transceiver serve as the positive and negative input terminals of the RS485 conversion module, respectively; the B terminal of the RS485 transceiver also... The RS485 transceiver is grounded via resistor R11. Its A terminal is also connected to power supply VCC1 via resistor R12. The RS485 transceiver's R terminal is connected to power supply VCC2 via resistor R8. The RS485 transceiver's / RE terminal is also connected to power supply VCC2 via resistor R9, and is also connected to the collector of transistor Q2. The base of transistor Q2 is connected to resistor R10, and the emitter of transistor Q2 is grounded. The RS485 transceiver can receive external serial port signals via its R terminal, and can output serial port signals via its / RE terminal through resistor R10.
[0054] During the process of the RS485 conversion module converting the meter signal of the target meter and sending it to the processor, the RS485 conversion module receives the differential signal from the target meter through the channel selection module 20. Specifically, the differential signal can be determined by the voltage difference between the two input terminals. Based on the differential signal, the module outputs a logic low level or a logic high level to convert the digital meter signal into a serial port signal.
[0055] In another possible implementation, the target meter is an analog signal meter. For analog signal meters, an optocoupler conversion module can be used to convert the analog meter signal into a serial port signal. The multiple signal conversion modules 30 may also include an optocoupler conversion module. Figure 3 This is a schematic diagram of the optocoupler conversion module provided in an embodiment of this application, as shown below. Figure 3 As shown, the optocoupler conversion module includes: optocoupler U1, first resistor R1, second resistor R2, third resistor R3, fourth resistor R4, transistor Q1, and positive feedback unit. The positive feedback unit includes: fifth resistor R5 connected in parallel and first capacitor C1.
[0056] One end of the first resistor R1 serves as the positive input terminal of the optocoupler conversion module, and the other end of the first resistor R1 is connected to the anode of the diode of the optocoupler U1. The cathode of the diode of the optocoupler U1 serves as the negative input terminal of the optocoupler conversion module.
[0057] The collector of the phototransistor in optocoupler U1 is connected to one end of the second resistor R2 and the base of transistor Q1. The collector of transistor Q1 and the other end of the second resistor R2 are connected to the power supply VCC.
[0058] The base of the phototransistor is grounded through the third resistor R3. The emitter of the phototransistor Q3 and one end of the fourth resistor R4 are connected to the output of the optocoupler module, and the other end of the fourth resistor R4 and the emitter of the phototransistor are grounded. The base of the phototransistor is also connected to the output of the optocoupler module through a positive feedback unit.
[0059] In this embodiment, the first resistor R1 acts as a current-limiting resistor to control the current flowing into the diode of the optocoupler U1. When the positive input terminal is positively charged relative to the negative input terminal, the diode emits light, the phototransistor conducts, the collector of the phototransistor is at a low level, the transistor Q1 is turned off, the voltage of the emitter of the transistor Q1 is pulled high by the second resistor R2, and the optocoupler conversion module outputs a high level. When the positive input terminal is negatively charged relative to the negative input terminal, the diode does not emit light, the phototransistor is turned off, the collector of the phototransistor is at a high level, the transistor Q1 conducts, the voltage of the emitter of the transistor Q1 is pulled low to ground, and the optocoupler conversion module outputs a low level.
[0060] The fifth resistor R5 and the first capacitor C1 connected in parallel form a positive feedback unit. When the voltage at the emitter of transistor Q1 is pulled high by the second resistor R2, the positive feedback unit feeds back to the base of the phototransistor, enabling the phototransistor to turn on faster. When the voltage at the emitter of transistor Q1 is pulled low to ground, the positive feedback unit feeds back to the base of the phototransistor, enabling the phototransistor to turn off faster. This accelerates the turn-on and turn-off of the phototransistor, reduces the possibility of signal distortion, improves the quality of the converted meter signal, and increases the efficiency of the optocoupler conversion module.
[0061] The charging metering port switching circuit provided in the above embodiments can convert different types of meter signals through RS485 conversion module and optocoupler conversion module to meet the needs of different meter types. When the types of meter types are more abundant, the types of signal conversion modules can be expanded, resulting in higher compatibility.
[0062] In one possible implementation, such as Figure 1 As shown, the charging metering port switching circuit may further include a protection filter module 50, which is connected between multiple signal conversion modules 30 and channel switching module 40. Figure 4 A schematic diagram of the protection filtering module provided in the embodiments of this application is shown below. Figure 4 As shown, the protection filtering module 50 may include: a current limiting resistor unit 51, a transient protection unit 52, a filtering unit 53, and a common mode inductor L1. The current limiting resistor unit 51 may include: a sixth resistor R6 and a seventh resistor R7. The transient protection unit 52 may include: a TVS diode D1, a first ESD diode D2, and a second ESD diode D3. The filtering unit 53 includes: a second capacitor C2 and a third capacitor C3.
[0063] The sixth resistor R6 is connected to the first input terminal of the common-mode inductor L1, the seventh resistor R7 is connected to the second input terminal of the common-mode inductor L1, the second capacitor C2 is connected between the first output terminal of the common-mode inductor L1 and ground, the third capacitor C3 is connected between the second output terminal of the common-mode inductor L1 and ground, the TVS diode D1 is connected between the first input terminal and the second input terminal of the common-mode inductor L1, the first ESD diode D2 is connected between the second input terminal of the common-mode inductor L1 and ground, and the second ESD diode D3 is connected between the first input terminal of the common-mode inductor L1 and ground.
[0064] In this embodiment, the sixth resistor R6 and the seventh resistor R7 are connected in series in the two input branches of the common mode inductor L1 to limit the surge current or short-circuit current, prevent the TVS diode from burning out, and work together with the TVS diode to form a current limiting and clamping protection combination.
[0065] TVS diode D1 is used to suppress the voltage difference between the two input branches of common-mode inductor L1 from rising. First ESD diode D2 is used to discharge overvoltage in this branch, and second ESD diode D3 is used to discharge overvoltage in this branch, thus achieving ground protection. First ESD diode D2 and second ESD diode D3 together constitute bidirectional ground protection.
[0066] The common-mode inductor L1 is used to suppress common-mode noise. The second capacitor C2 and the third capacitor C3 form a Y-type capacitor filter network, which can filter out the remaining high-frequency noise after it has been attenuated by the common-mode inductor L1.
[0067] The charging metering port switching circuit provided in the above embodiments forms multi-level protection including current limiting, transient voltage suppression, common-mode noise suppression, and filtering, which enhances the switching circuit's resistance to various electrical interferences and improves safety. The filtering measures reduce noise in the signal and improve the anti-interference capability of the converted meter signal, thereby improving communication reliability.
[0068] In one possible implementation, Figure 5 A schematic diagram of the channel selection module provided in the embodiments of this application is shown below. Figure 5 As shown, the channel selection module is a magnetic latching relay. The input terminal of the magnetic latching relay is used to connect to the target meter, and the multiple output terminals of the magnetic latching relay are respectively connected to multiple signal conversion modules.
[0069] In this embodiment, the magnetic latching relay provides two channels: a digital signal channel and an analog signal channel. When the magnetic latching relay is in a closed state or one of the states, the signal line is routed to the RS-485 conversion module. When the magnetic latching relay is in an open state or another state, the signal line is routed to the optocoupler conversion module.
[0070] In some embodiments, if the multiple signal conversion circuits include at least three signal conversion circuits, other switching structures may also be used as channel selection modules.
[0071] In one possible implementation, Figure 6 This is a schematic diagram of the channel switching module provided in an embodiment of this application, as shown below. Figure 6 As shown, the channel switching module is a multi-select multiplexer. Each input terminal of the multi-select multiplexer is connected to the output terminals of multiple signal conversion modules, and the output terminal of the multi-select multiplexer is connected to the charging pile processor.
[0072] In this embodiment, the number of multiplexed switches is determined based on the number of meter types. For example, the digital signal meters involved in this solution include RS485 meters, and the analog signal meters include P1PORT meters and LINKY meters. Therefore, at least three-to-one multiplexed switches are required. Typically, a 4-to-1 CMOS analog signal multiplexing chip can be used. In this way, when the number of meter types increases, the chip can be directly reused, reserving expansion space for the subsequent possible addition of meter types.
[0073] In some embodiments, such as Figure 1 As shown, the charging metering port switching circuit may further include a communication module 60, which is located between the channel switching module 40 and the charging pile processor 10, and is used to transmit the converted meter signal to the hardware interface of the charging pile processor 10.
[0074] Based on the charging metering port switching circuit provided in the above embodiments, the specific implementation of the charging metering port switching method provided in this application will be described below in conjunction with the embodiments.
[0075] Figure 7 This is a flowchart illustrating the charging metering port switching method provided in an embodiment of this application, as shown below. Figure 7 As shown, the method may include:
[0076] S101. Obtain the meter type of the target meter.
[0077] In this embodiment, the charging pile processor can determine the meter type of the target meter by the configuration command sent by the user, or by acquiring the test signal of the target meter and determining the meter type based on the signal characteristics.
[0078] Users can send configuration commands wirelessly via an application or webpage that is compatible with the charging station, or they can send configuration commands locally via a settings button or touchscreen on the charging station.
[0079] S102. Determine the signal type and signal protocol format of the target meter based on its meter type.
[0080] In this embodiment, the local database or cloud database of the charging pile processor stores the mapping relationship between meter type and signal type and signal protocol format. The signal type can include at least: digital differential signal, analog pulse signal, etc., and the signal protocol format can include at least RS485 communication protocol format, P1PORT protocol, LINKY protocol, etc.
[0081] After determining the type of the target electricity meter, the charging pile processor queries the signal type and signal protocol format corresponding to the electricity meter type.
[0082] S103. Based on the signal type of the target meter, generate a first control signal and control the first target channel of the channel selection module to be turned on, so that the target meter is connected to the target signal conversion module through the first target channel, and the meter signal of the target meter is converted by the target signal conversion module to obtain the converted meter signal.
[0083] In this embodiment, the charging pile processor pre-stores the mapping relationship between signal types and control signals. Each control signal is used to control the corresponding channel to be turned on, while other channels are turned off. Each channel is connected to a signal conversion module. According to the signal type of the target meter, a corresponding first control signal is generated. The first target channel in the channel selection module is turned on according to the first control signal, so that the target meter can send the meter signal through the first target channel to the target signal conversion module corresponding to the meter type of the target meter. The target signal conversion module converts the original type of meter signal into a unified type of meter signal, that is, a serial port type meter signal.
[0084] In some embodiments, if the channel selection module is a magnetic latching relay, the charging pile processor can control the magnetic latching relay to close or open according to the first control signal to connect to the corresponding RS485 conversion module or optocoupler conversion module. If the signal type of the target meter is a digital differential signal, the magnetic latching relay connects the target meter to the RS485 conversion module to convert the digital differential signal into a serial port signal. If the signal type of the target meter is an analog pulse signal, the magnetic latching relay connects the target meter to the optocoupler conversion module to convert the analog pulse signal into a serial port signal.
[0085] S104. Based on the signal protocol format of the target meter, generate a second control signal and control the second target path of the channel switching module to be turned on, so as to send the converted meter signal through the second target path and complete the switching of the charging metering port.
[0086] In this embodiment, the charging pile processor pre-stores the mapping relationship between signal protocol format and control signal. Each control signal is used to control the corresponding channel to be turned on and other channels to be turned off. The charging pile controller generates a corresponding second control signal according to the signal protocol format, and controls the second target channel in the channel switching module to be turned on according to the second control signal, so as to send the converted meter signal to the charging pile processor through the second target channel.
[0087] By connecting the first target channel and the second target channel, the switching of the charging metering port between the target meter and the charging pile processor is achieved.
[0088] In some embodiments, a data configuration library is established in the software program of the charging pile processor, which contains signal protocol formats and corresponding IO status information. For example, the IO status corresponding to the RS485 protocol format is 00, the IO status corresponding to the P1PORT protocol format is 01, and the IO status corresponding to the LINKY protocol format is 10.
[0089] The charging pile processor locates the corresponding IO state based on the signal protocol format of the target meter and controls the channel switching module to close the corresponding channel. For example, if the target meter is a P1PORT meter, the charging pile processor searches the data configuration library, outputs an IO state of "01", and then controls the channel switching module to switch to the corresponding channel.
[0090] The charging metering port switching method provided in the above embodiments realizes the switching of the charging metering port between the target meter and the charging pile processor through the channel selection module and the channel switching module, so that the meter signal of the target meter can be sent to the charging pile processor through the first target channel and the second target channel. Based on the channel selection module, multiple signal switching circuits and the channel switching module, the charging metering port switching circuit can be adapted to various types of meters without considering the differences in the interfaces of different meters, thereby improving the compatibility of the charging pile and reducing the cost of the charging pile.
[0091] In one possible implementation, the process of obtaining the meter type of the target meter in step S101 above may include:
[0092] If a charging pile is detected to be connected to the target meter, the signal feature vector of the target meter is obtained; based on the signal feature vector, the meter type of the target meter is determined.
[0093] In this embodiment, after the charging pile processor detects that the target meter is connected to the charging pile, it enters the detection mode to obtain the signal feature vector of the target meter. The signal feature vector can characterize the electrical interface features, timing features, and protocol layer features of the meter signal. Electrical interface features may include, for example, static level and peak-to-peak amplitude of the signal. Timing features may include, for example, signal transition frequency, pulse width and interval pattern. Protocol layer features may include, for example, the start symbol of the data frame, frame length, checksum algorithm features, etc.
[0094] The charging pile processor determines the type of the target meter by feature matching based on the correspondence between meter types and signal feature vectors stored in a local or cloud database.
[0095] In some embodiments, if at least one candidate meter type is matched by the signal feature vector, the channel selection module and the channel switching module can perform a protocol handshake with the target meter according to the candidate meter type, and determine the meter type of the target meter based on the response result.
[0096] In other embodiments, if the meter type is not matched by the signal feature vector, a notification can be sent to the maintenance personnel, who can then manually configure the meter type of the target meter. If the target meter type is a newly added meter type, the maintenance personnel can update the information in the local database or the cloud database.
[0097] In some embodiments, the charging metering port switching circuit further includes: a signal detection module, wherein the process of acquiring the signal feature vector of the target meter may include:
[0098] The original waveform data is sampled by the signal detection module; based on the multi-dimensional characteristics of the original waveform data, a signal feature vector is generated. The multi-dimensional characteristics include at least: signal amplitude, frequency, and data frame format.
[0099] In this embodiment, as Figure 1 As shown, the charging metering port switching circuit also includes a signal detection module 70. After detecting that the target meter is connected to the charging pile, the charging pile controller obtains the original waveform data of the target meter without signal conversion through the signal detection module 70. Through timing analysis and frequency domain analysis, the electrical amplitude characteristics and frequency characteristics of the signal are determined. By attempting to synchronize bytes at different baud rates and capturing data frames, the data frame format, such as start frame, end frame, and frame length, is determined by searching for the signature bytes of a specific protocol in the data frames. Based on these characteristics, a signal feature vector is generated.
[0100] The charging metering port switching method provided in the above embodiments generates a signal feature vector based on the multi-dimensional characteristics of the meter signal, so as to determine the meter type of the target meter based on the signal feature vector, thereby improving the accuracy of meter type identification.
[0101] In one possible implementation, the process of determining the signal type and signal protocol format of the target electricity meter based on the meter type of the target electricity meter in step S102 may include:
[0102] Send the meter type to the cloud database, which stores meter parameter information corresponding to various meter types, so as to determine the meter parameter information of the target meter from the cloud database according to the meter type; receive the meter parameter information sent by the cloud database, which includes at least: signal type and signal protocol format.
[0103] In this embodiment, the cloud database stores different types of meter parameter information. If the local database does not store the meter parameter information of the target meter, the charging pile processor can send a query request to the cloud database. The query request includes the meter type identifier in order to obtain the meter parameter information corresponding to the meter type from the cloud.
[0104] In some embodiments, after the charging pile processor obtains the meter parameter information from the cloud, it stores the meter parameter information locally so that when the same type of meter is connected again, the meter parameter information can be queried in milliseconds without having to query the meter parameter information from the cloud database via the network.
[0105] The charging metering port switching method provided in the above embodiments stores meter parameter information corresponding to various meter types in a cloud database. When the meter type is updated, there is no need to upgrade the firmware of existing charging piles; only the database needs to be updated in the cloud, which greatly reduces maintenance costs.
[0106] In one possible implementation, the meter parameter information also includes: data parsing rules, and the method may further include:
[0107] The converted meter signal is analyzed according to the data parsing rules.
[0108] In this embodiment, after receiving the converted meter signal, the charging pile processor parses the converted meter signal according to the data parsing rules corresponding to the meter type of the target meter to obtain the meter data and realize the transmission of the meter data.
[0109] Based on the charging metering port switching method and circuit provided in the above embodiments, this application also provides a charging pile, which may include the charging metering port switching circuit of the above embodiments.
[0110] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for switching charging metering ports, characterized in that, A charging pile processor is applied in a charging metering port switching circuit, wherein the charging metering port switching circuit further includes: a channel selection module, multiple signal conversion modules, and a channel switching module, and the method includes: Obtain the meter type of the target meter; Based on the type of the target electricity meter, determine the signal type and signal protocol format of the target electricity meter; Based on the signal type of the target meter, a first control signal is generated and the first target channel of the channel selection module is turned on, so that the target meter is connected to the target signal conversion module through the first target channel, and the meter signal of the target meter is converted by the target signal conversion module to obtain the converted meter signal. According to the signal protocol format of the target meter, a second control signal is generated and the second target path of the channel switching module is turned on, so as to send the converted meter signal through the second target path and complete the switching of the charging metering port; The step of obtaining the meter type of the target meter includes: If it is detected that the charging pile is connected to the target electricity meter, the signal feature vector of the target electricity meter is obtained; Based on the signal feature vector, determine the type of the target meter; The charging metering port switching circuit further includes: a signal detection module, wherein acquiring the signal feature vector of the target meter includes: The original waveform data is sampled by the signal detection module. Based on the multi-dimensional features of the original waveform data, the signal feature vector is generated. The multi-dimensional features include at least: signal amplitude, frequency, and data frame format.
2. The method as described in claim 1, characterized in that, The step of determining the signal type and signal protocol format of the target electricity meter based on the meter type includes: The meter type is sent to a cloud database, which stores meter parameter information corresponding to various meter types, so as to determine the meter parameter information of the target meter from the cloud database according to the meter type. The meter parameter information sent by the cloud database is received. The meter parameter information includes at least the signal type and the signal protocol format.
3. The method as described in claim 2, characterized in that, The meter parameter information also includes: data parsing rules, and the method further includes: The converted meter signal is analyzed according to the data parsing rules.
4. A charging metering port switching circuit, characterized in that, The charging metering port switching method includes: a charging pile processor, a channel selection module, multiple signal conversion modules, and a channel switching module. The input terminal of the channel selection module is used to connect to the target electricity meter connected to the charging pile. The multiple output terminals of the channel selection module are respectively connected to the multiple signal conversion modules. The multiple signal conversion modules are connected to the channel switching module. The output terminal of the channel switching module is connected to the charging pile processor. The charging pile processor is also connected to the control terminal of the channel selection module and the control terminal of the channel switching module. The charging pile processor executes the charging metering port switching method as described in any one of claims 1-3 to realize the signal transmission between the target electricity meter and the charging pile processor.
5. The charging metering port switching circuit as described in claim 4, characterized in that, The plurality of signal conversion modules include: an RS485 conversion module, which is used to convert digital meter signals into serial port signals.
6. The charging metering port switching circuit as described in claim 4, characterized in that, The plurality of signal conversion modules include: an optocoupler conversion module, which is used to convert analog meter signals into serial port signals. The optocoupler conversion module includes: an optocoupler, a first resistor, a second resistor, a third resistor, a fourth resistor, a transistor, and a positive feedback unit. The positive feedback unit includes: a fifth resistor and a first capacitor connected in parallel. One end of the first resistor serves as the positive input terminal of the optocoupler conversion module, and the other end of the first resistor is connected to the anode of the diode of the optocoupler. The cathode of the diode of the optocoupler serves as the negative input terminal of the optocoupler conversion module. The collector of the phototransistor in the optocoupler is connected to one end of the second resistor and the base of the transistor, and the collector of the transistor and the other end of the second resistor are connected to the power supply. The base of the phototransistor is grounded through the third resistor, the emitter of the phototransistor and one end of the fourth resistor are connected to the output terminal of the optocoupler conversion module, and the other end of the fourth resistor and the emitter of the phototransistor are grounded. The base of the phototransistor is also connected to the output of the optocoupler module through the positive feedback unit.
7. The charging metering port switching circuit as described in claim 4, characterized in that, The charging metering port switching circuit further includes a protection filtering module, which is connected between the plurality of signal conversion modules and the channel switching module; the protection filtering module includes a current limiting resistor unit, a transient protection unit, a filtering unit and a common mode inductor; the current limiting resistor unit includes a sixth resistor and a seventh resistor; the transient protection unit includes a TVS diode, a first ESD diode and a second ESD diode; the filtering unit includes a second capacitor and a third capacitor. The sixth resistor is connected to the first input terminal of the common-mode inductor, the seventh resistor is connected to the second input terminal of the common-mode inductor, the second capacitor is connected between the first output terminal of the common-mode inductor and ground, the third capacitor is connected between the second output terminal of the common-mode inductor and ground, the TVS diode is connected between the first input terminal and the second input terminal of the common-mode inductor, the first ESD diode is connected between the second input terminal of the common-mode inductor and ground, and the second ESD diode is connected between the first input terminal of the common-mode inductor and ground.
8. The charging metering port switching circuit as described in claim 4, characterized in that, The channel selection module is a magnetic latching relay. The input terminal of the magnetic latching relay is used to connect to the target meter, and the multiple output terminals of the magnetic latching relay are respectively connected to the multiple signal conversion modules. The channel switching module is a multiplexer, each input terminal of which is connected to the output terminal of the multiple signal conversion modules, and the output terminal of which is connected to the charging pile processor.