CN112306889B - Method and device for testing charging pile, storage medium and processor - Google Patents
Method and device for testing charging pile, storage medium and processor Download PDFInfo
- Publication number
- CN112306889B CN112306889B CN202011323867.2A CN202011323867A CN112306889B CN 112306889 B CN112306889 B CN 112306889B CN 202011323867 A CN202011323867 A CN 202011323867A CN 112306889 B CN112306889 B CN 112306889B
- Authority
- CN
- China
- Prior art keywords
- state
- test sequence
- migration
- sequence
- charging
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000012360 testing method Methods 0.000 title claims abstract description 153
- 238000000034 method Methods 0.000 title claims abstract description 44
- 238000013508 migration Methods 0.000 claims abstract description 51
- 230000005012 migration Effects 0.000 claims abstract description 47
- 238000004891 communication Methods 0.000 claims abstract description 17
- 230000008569 process Effects 0.000 claims description 20
- 230000005540 biological transmission Effects 0.000 claims description 19
- 230000003993 interaction Effects 0.000 claims description 8
- 230000000977 initiatory effect Effects 0.000 claims description 6
- 238000010998 test method Methods 0.000 claims description 5
- 238000000354 decomposition reaction Methods 0.000 claims description 4
- 238000010276 construction Methods 0.000 claims description 3
- 238000010586 diagram Methods 0.000 description 9
- 230000004044 response Effects 0.000 description 6
- 230000011664 signaling Effects 0.000 description 5
- 238000001514 detection method Methods 0.000 description 3
- 230000000694 effects Effects 0.000 description 3
- 230000001360 synchronised effect Effects 0.000 description 3
- 238000012795 verification Methods 0.000 description 3
- 230000009471 action Effects 0.000 description 2
- 230000008878 coupling Effects 0.000 description 2
- 238000010168 coupling process Methods 0.000 description 2
- 238000005859 coupling reaction Methods 0.000 description 2
- 230000006870 function Effects 0.000 description 2
- 230000007704 transition Effects 0.000 description 2
- 230000002159 abnormal effect Effects 0.000 description 1
- 230000006978 adaptation Effects 0.000 description 1
- 230000008901 benefit Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000009413 insulation Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000002360 preparation method Methods 0.000 description 1
- 238000012545 processing Methods 0.000 description 1
- 230000009467 reduction Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3684—Test management for test design, e.g. generating new test cases
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01R—MEASURING ELECTRIC VARIABLES; MEASURING MAGNETIC VARIABLES
- G01R31/00—Arrangements for testing electric properties; Arrangements for locating electric faults; Arrangements for electrical testing characterised by what is being tested not provided for elsewhere
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q50/00—Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
- G06Q50/06—Energy or water supply
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02T—CLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO TRANSPORTATION
- Y02T10/00—Road transport of goods or passengers
- Y02T10/60—Other road transportation technologies with climate change mitigation effect
- Y02T10/70—Energy storage systems for electromobility, e.g. batteries
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02T—CLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO TRANSPORTATION
- Y02T10/00—Road transport of goods or passengers
- Y02T10/60—Other road transportation technologies with climate change mitigation effect
- Y02T10/7072—Electromobility specific charging systems or methods for batteries, ultracapacitors, supercapacitors or double-layer capacitors
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02T—CLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO TRANSPORTATION
- Y02T90/00—Enabling technologies or technologies with a potential or indirect contribution to GHG emissions mitigation
- Y02T90/10—Technologies relating to charging of electric vehicles
- Y02T90/12—Electric charging stations
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Business, Economics & Management (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- General Engineering & Computer Science (AREA)
- Health & Medical Sciences (AREA)
- Economics (AREA)
- Public Health (AREA)
- Water Supply & Treatment (AREA)
- General Health & Medical Sciences (AREA)
- Human Resources & Organizations (AREA)
- Marketing (AREA)
- Primary Health Care (AREA)
- Strategic Management (AREA)
- Tourism & Hospitality (AREA)
- General Business, Economics & Management (AREA)
- Charge And Discharge Circuits For Batteries Or The Like (AREA)
Abstract
The application discloses a testing method and device of a charging pile, a storage medium and a processor. Wherein the method comprises the following steps: acquiring a Finite State Machine (FSM) model of a communication protocol between a charging control unit and a charging pile main control board, wherein the FSM model comprises: a state set and a migration set; performing Euler traversal according to a migration path in a migration set by taking an initial state in the state set as a starting point, and constructing a state sequence of a plurality of states in the state set; determining the test sequence according to the state sequence. The application solves the technical problem of lower test efficiency caused by the fact that the test sequence needs to be determined by relying on the experience of a tester.
Description
Technical Field
The application relates to the field of charging, in particular to a testing method and device of a charging pile, a storage medium and a processor.
Background
In the process of testing the charging pile, the existing test mode is as follows: based on experience of testers, establishing sequence in the testing process item by item, and determining the testing sequence of each testing step.
However, this method relies on the experience of the tester, and the test efficiency is low.
For the problem that the test sequence needs to be determined by relying on experience of a tester, so that the test efficiency is low, no effective solution has been proposed at present.
Disclosure of Invention
The embodiment of the application provides a testing method, a testing device, a storage medium and a processor for a charging pile, which at least solve the technical problem of low testing efficiency caused by the fact that a testing sequence needs to be determined by relying on experience of a tester.
According to an aspect of the embodiment of the present application, there is provided a method for testing a charging pile, including: acquiring a Finite State Machine (FSM) model of a communication protocol between a charging control unit and a charging pile main control board, wherein the FSM model comprises: a state set and a migration set; performing Euler traversal according to a migration path in the migration set by taking an initial state in the state set as a starting point, and constructing a state sequence of a plurality of states in the state set; and determining a test sequence according to the state sequence.
Optionally, after determining a test sequence from the state sequence, the method further comprises; decomposing the test sequence into: a charging start test sequence corresponding to a charging start process, an energy transmission test sequence corresponding to an energy transmission process, and a charging end test sequence corresponding to a charging end process.
Optionally, the charging initiation test sequence includes: heartbeat interaction forward/reverse test sequence, electronic lock control forward/reverse test sequence, version check forward/reverse test sequence, and start success/failure sequence.
Optionally, the energy transmission test sequence includes: and (5) forward/reverse testing of each item of charging data.
Optionally, the end-of-charge test sequence includes: an active end charge test sequence and a passive end charge test sequence caused by various faults.
According to an aspect of an embodiment of the present application, there is provided another test device for a charging pile, including: the acquisition unit is used for acquiring a finite state machine FSM model of a communication protocol between the charging control unit and the charging pile main control board, wherein the finite state machine FSM model comprises: a state set and a migration set; the construction unit is used for constructing a state sequence of a plurality of states in the state set by taking an initial state in the state set as a starting point and carrying out Euler traversal according to a migration path in the migration set; and the determining unit is used for determining a test sequence according to the state sequence.
Optionally, the apparatus further comprises: a decomposition unit, configured to decompose the test sequence into: a charging start test sequence corresponding to a charging start process, an energy transmission test sequence corresponding to an energy transmission process, and a charging end test sequence corresponding to a charging end process.
Optionally, the charging initiation test sequence includes: heartbeat interaction forward/reverse test sequence, electronic lock control forward/reverse test sequence, version check forward/reverse test sequence, and start success/failure sequence.
According to an aspect of an embodiment of the present application, there is provided still another "computer-readable storage medium" or "nonvolatile storage medium", which includes a stored program, wherein the device on which the "computer-readable storage medium" or "nonvolatile storage medium" is located is controlled to execute the above-described start-up test method of the charging stake when the program runs.
According to an aspect of the embodiment of the present application, there is provided a further processor, where the processor is configured to run a program, and the program executes the method for testing the start-up of the charging pile described above.
In the embodiment of the application, a finite state machine FSM model of a communication protocol between a charging control unit and a charging pile main control board is obtained, wherein the finite state machine FSM model comprises: a state set and a migration set; performing Euler traversal according to a migration path in the migration set by taking an initial state in the state set as a starting point, and constructing a state sequence of a plurality of states in the state set; the test sequence is determined according to the state sequence, the purpose that the test sequence is determined according to the state vector machine is achieved, and the dependence on experience of a tester is eliminated, so that the technical effect of improving the test efficiency is achieved, and the technical problem that the test efficiency is lower due to the fact that the test sequence is determined according to the experience of the tester is solved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this specification, illustrate embodiments of the application and together with the description serve to explain the application and do not constitute a limitation on the application. In the drawings:
fig. 1 is a flowchart of a test method of a charging pile according to an embodiment of the present application;
fig. 2 is a schematic diagram of an FSM directed graph of a communication protocol between a charging control unit and a charging pile main control board according to an embodiment of the present application;
fig. 3 is a schematic diagram of a directed symmetry graph G according to an embodiment of the application;
FIG. 4 is a schematic diagram of a "charge-on forward test" case according to an embodiment of the application;
fig. 5 is a schematic view of a testing device for a charging pile according to an embodiment of the present application.
Detailed Description
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, shall fall within the scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the application described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
According to an embodiment of the present application, there is provided a test method embodiment of a charging stake, it being noted that the steps shown in the flowchart of the figures may be performed in a computer system such as a set of computer executable instructions, and, although a logical sequence is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than what is shown or described herein.
Fig. 1 is a flowchart of a testing method of a charging pile according to an embodiment of the present application, as shown in fig. 1, the method includes the steps of:
step S102, a finite state machine FSM model of a communication protocol between a charging control unit and a charging pile main control board is obtained, wherein the finite state machine FSM model comprises: a state set and a migration set;
step S104, carrying out Euler traversal according to a migration path in a migration set by taking an initial state in the state set as a starting point, and constructing a state sequence of a plurality of states in the state set;
step S106, determining a test sequence according to the state sequence.
Through the steps, a finite state machine FSM model of a communication protocol between the charging control unit and the charging pile main control board is obtained, wherein the finite state machine FSM model comprises: a state set and a migration set; performing Euler traversal according to a migration path in the migration set by taking an initial state in the state set as a starting point, and constructing a state sequence of a plurality of states in the state set; the test sequence is determined according to the state sequence, the purpose that the test sequence is determined according to the state vector machine is achieved, and the dependence on experience of a tester is eliminated, so that the technical effect of improving the test efficiency is achieved, and the technical problem that the test efficiency is lower due to the fact that the test sequence is determined according to the experience of the tester is solved.
As an alternative embodiment, after determining the test sequence from the state sequence, the method further comprises; the test sequence is decomposed into: a charging start test sequence corresponding to a charging start process, an energy transmission test sequence corresponding to an energy transmission process, and a charging end test sequence corresponding to a charging end process.
As an alternative embodiment, the charge initiation test sequence comprises: a heartbeat interaction forward/reverse test sequence, an electronic lock control forward/reverse test sequence, a version check forward/reverse test sequence and a start success/failure sequence;
as an alternative embodiment, the energy transmission test sequence comprises: and (5) forward/reverse testing of each item of charging data.
As an alternative embodiment, the end-of-charge test sequence comprises: an active end charge test sequence and a passive end charge test sequence caused by various faults.
The application also provides a preferred embodiment which provides a link communication fault location diagnostic strategy.
The finite state machine is a formalized model representing a finite number of states and actions such as transition actions between the states. A finite state machine M may be represented as a directed graph, described by a six-tuple: m= { S, S 0 Delta, lambda, I, O }. Wherein S is a finite state set; s is S 0 E S is the initial state; delta is the state transition function; lambda is the output value; i is a finite input character set; o is a finite output character set (lambda E O).
According to the technical scheme provided by the application, modeling problems of specification are formed on the principle of testing basic steps and consistency testing of the CAN communication model, and a coverage criterion theory is tested; generating an algorithm based on the test of the model; the balance problem of test cost and test efficiency; model decomposition and test generation; redundancy reduction of test case sets; acquisition of executable test cases and test execution are automated.
Fig. 2 is a schematic diagram of an FSM directed graph of a communication protocol between a charging control unit and a charging pile main control board according to an embodiment of the present application, as shown in fig. 2, states of the FSM are described, where a state description corresponding to a state S0 is "off"; the state corresponding to the state S1 is illustrated as "data interaction"; the state corresponding to the state S2 is illustrated as "heartbeat detection"; the state corresponding to the state S3 is described as "version check"; the state corresponding to the state S4 is illustrated as "parameter matching"; the state corresponding to the state S5 is described as "electronic lock control"; the state corresponding to the state S6 is described as "time tick"; the state corresponding to the state S7 is illustrated as "start"; the state corresponding to the state S8 is illustrated as "running charge"; the state corresponding to the state S9 is illustrated as "failure detection"; the state corresponding to the state S10 is described as "error reporting"; the state corresponding to the state S11 is illustrated as "remote signaling"; the state corresponding to state S12 is illustrated as "telemetry"; the state corresponding to the state S13 is described as "stop charging"; the state corresponding to the state S14 is described as "restart".
Each edge in the FSM model represents a migration condition and a migration path as follows:
l1: closing K1 and K2, conducting a low-voltage auxiliary loop, and powering up and initializing; l2: detecting that the vehicle is connected with a charger, and the heartbeat frame message is normally received/sent; l3: abnormal heartbeat frame receiving/transmitting; l4: the heartbeat frame message is received for 3s overtime; l5: stopping receiving/transmitting all the messages except the heartbeat frame, and continuing the state for 30s; l6: the version check response frame is not received or the versions are different; l7: version verification is passed; l8: sending a charging parameter response frame to receive 5S overtime; l9: the parameter matching is successful, and the electronic lock needs to be controlled; l10: lock failure or 5s timeout; l11: the locking is successful; l12: the time response frame message sent from the CTR is not received; l13: sending the time response frame to receive for 5s overtime; l14: the charging control unit and the charging pile main control board are time synchronized or if the time is not synchronized, the time is synchronized as the self-recognition time of the controller; l15: the insulation detection is passed, the preparation is finished, the K1 and the K2 are closed, the direct current power supply loop is conducted, and the starting is successful; l16: failure of start-up; l17: detecting a failure reason; l18: the error frame message is normally received; l19: periodically sending a remote signaling frame message during charging operation; l20: the message receiving/transmitting of the remote signaling frame is normal; l21: periodically sending a telemetry frame message during charging operation; l22: the message receiving/transmitting of the telemetry frame is normal; l23: the message sending of the telemetry frame is overtime for 5 seconds; l24: the remote signaling frame message is sent for 5s overtime; l25: CTR fault (remote signaling frame message fault location 1); l26: completing charging requirements/receiving a platform charging service stop instruction; l27: receiving a charging stop frame message or a charging service start-stop frame message, and opening K3 and K4; l28: stopping charging in a normal state; l29: setting a corresponding fault position, and receiving an error frame for 5s overtime; l30: restarting.
The general procedure for generating a consistency test sequence based on the UIO sequence is as follows:
(1) Firstly, solving a UIO sequence of each state in the FSM;
(2) The FSM of the communication protocol between the charging control unit and the CTR is represented by a directed graph g= (V, E) shown in fig. 2, where v= { v_1, v_ … v_n } is a state set of the FSM; e= { (v_i, v_j; i_m/o_n) |v_i, v_j ε V, i_m ε I, o_n ε O } is a migration set of FSMs. For each migration there is e (v_i, v_j; i_m/o_n) = { i_m/o_n, UIO (v_j) }, this migration is referred to as a pseudo-migration. Wherein v_i represents the initial state of the test; v_j represents a state after execution of the migration path i_m/o_n; UIO (v_j) represents the UIO sequence of state v_j. The graph containing only the pseudo migration is referred to as a "pseudo graph", and is represented by G '= (V, E'). Wherein E' = { (v_i, v_j; i_m/o_n) |v_i, v_j E V, i_m E I, o_n E O } is a pseudo-migration set of FSMs. A pseudo graph G' is generated from the directed graph G of the FSM.
(3) And symmetrically expanding the pseudo graph G' to generate a directional symmetrical graph G= (V, E). Fig. 3 is a schematic diagram of a directional symmetry diagram G according to an embodiment of the present application, where e=e_e ', i.e. edges taken from E are added to the pseudo-diagram G', so as to obtain the directional symmetry diagram G.
(4) And constructing Euler traversal by taking the initial state as a starting point, wherein the obtained sequence is a test sequence for protocol consistency test. The consistency test sequence of the communication protocol between the charging control unit and the charging pile obtained by the method is as follows: l1, L3, L5, L7, L9, L11, L24, L5, L26, L27, L17, L29, L30, L2, L7, L9, L11, L14, L15, L26, L27, L17, L29, L30, L3, L5, L7, L9, L11, L14, L15, L21, L22, L23, L29, L30, L3, L5, L7, L9, L11, L24, L15, L19, L20, L25.
The test sequence is decomposed, and the charging process is primarily divided into a charging starting process, an energy transmission process and a charging ending process to comb test cases.
The test case set in the charging starting process mainly comprises a heartbeat interaction forward/reverse test, an electronic lock control forward/reverse test, a version verification forward/reverse test and starting success/failure; the energy transmission stage test case set mainly comprises forward/reverse tests of various charging data; the charge ending test case set mainly comprises an active charge ending test and a passive charge ending test caused by various faults.
Fig. 4 is a schematic diagram of a case of "charge start forward test" according to an embodiment of the present application, as shown in fig. 4, including the following steps:
and sending the version check frame message.
Judging whether to receive the version check response frame message; and (3) if not, returning to the step (1), and if so, executing the step (3).
Judging whether the version is V1.10 (namely, the appointed version); and (4) if not, returning to the step (1), and if so, executing the step (4).
And sending a version verification message and sending a charging parameter frame message.
Judging whether a message for sending a charging parameter response frame is received or not; if not, returning to the step 4), if yes, executing the step 6), and if the acceptance time is overtime (if more than 5 s), executing the step 9).
Judging whether the starting is successful; if yes, executing the step 7), otherwise executing the step 8).
And an energy transmission stage.
And detecting a failure reason.
And the total faults are the corresponding fault position bits, and error frame messages are sent.
The application also provides a computer readable storage medium or a nonvolatile storage medium, which comprises a stored program, wherein the device where the computer readable storage medium or the nonvolatile storage medium is located is controlled to execute the method for testing the start of the charging pile when the program runs.
The application also provides a processor, which is characterized in that the processor is used for running a program, wherein the program runs to execute the method for testing the starting of the charging pile.
According to the embodiment of the application, the embodiment of the device for testing the charging pile is also provided, and it is to be noted that the device for testing the charging pile can be used for executing the method for testing the charging pile in the embodiment of the application, and the method for testing the charging pile in the embodiment of the application can be executed in the device for testing the charging pile.
Fig. 5 is a schematic view of a testing apparatus of a charging pile according to an embodiment of the present application, and as shown in fig. 5, the apparatus may include: the obtaining unit 50 is configured to obtain a finite state machine FSM model of a communication protocol between the charging control unit and the charging pile main control board, where the finite state machine FSM model includes: a state set and a migration set; a construction unit 52, configured to perform euler traversal according to a migration path in the migration set with an initial state in the state set as a starting point, and construct a state sequence of a plurality of states in the state set; a determining unit 54 for determining a test sequence based on the state sequence.
It should be noted that, the acquiring unit 50 in this embodiment may be used to perform step S102 in the embodiment of the present application, the constructing unit 52 in this embodiment may be used to perform step S104 in the embodiment of the present application, and the determining unit 54 in this embodiment may be used to perform step S106 in the embodiment of the present application. The above modules are the same as examples and application scenarios implemented by the corresponding steps, but are not limited to what is disclosed in the above embodiments.
In the embodiment of the application, a finite state machine FSM model of a communication protocol between a charging control unit and a charging pile main control board is obtained, wherein the finite state machine FSM model comprises: a state set and a migration set; performing Euler traversal according to a migration path in the migration set by taking an initial state in the state set as a starting point, and constructing a state sequence of a plurality of states in the state set; the test sequence is determined according to the state sequence, the purpose that the test sequence is determined according to the state vector machine is achieved, and the dependence on experience of a tester is eliminated, so that the technical effect of improving the test efficiency is achieved, and the technical problem that the test efficiency is lower due to the fact that the test sequence is determined according to the experience of the tester is solved.
As an alternative embodiment, the apparatus further comprises: a decomposition unit, configured to decompose the test sequence into: a charging start test sequence corresponding to a charging start process, an energy transmission test sequence corresponding to an energy transmission process, and a charging end test sequence corresponding to a charging end process.
As an alternative embodiment, the charge initiation test sequence includes: heartbeat interaction forward/reverse test sequence, electronic lock control forward/reverse test sequence, version check forward/reverse test sequence, and start success/failure sequence.
As an alternative embodiment, the energy transmission test sequence comprises: and (5) forward/reverse testing of each item of charging data.
As an alternative embodiment, the end-of-charge test sequence includes: an active end charge test sequence and a passive end charge test sequence caused by various faults.
The foregoing embodiment numbers of the present application are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
In the foregoing embodiments of the present application, the descriptions of the embodiments are emphasized, and for a portion of this disclosure that is not described in detail in this embodiment, reference is made to the related descriptions of other embodiments.
In the several embodiments provided in the present application, it should be understood that the disclosed technology may be implemented in other manners. The above-described embodiments of the apparatus are merely exemplary, and the division of the units, for example, may be a logic function division, and may be implemented in another manner, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be through some interfaces, units or modules, or may be in electrical or other forms.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be embodied essentially or in part or all of the technical solution or in part in the form of a software product stored in a storage medium, including instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a removable hard disk, a magnetic disk, or an optical disk, or other various media capable of storing program codes.
The foregoing is merely a preferred embodiment of the present application and it should be noted that modifications and adaptations to those skilled in the art may be made without departing from the principles of the present application, which are intended to be comprehended within the scope of the present application.
Claims (10)
1. A method of testing a charging stake, comprising:
acquiring a Finite State Machine (FSM) model of a communication protocol between a charging control unit and a charging pile main control board, wherein the FSM model comprises: a state set and a migration set;
performing Euler traversal according to a migration path in the migration set by taking an initial state in the state set as a starting point, and constructing a state sequence of a plurality of states in the state set;
determining a test sequence according to the state sequence;
wherein the FSM model is represented by a directed graph g= (V, E), wherein v= { v_1, v_ … v_n } is the state set; e= { (v_i, v_j; i_m/o_n) |v_i, v_j E V, i_m E I, o_n E O } is the migration set, where v_i represents the initial state, v_j represents the state after execution of the migration path i_m/o_n, I is a limited input character set, and O is a limited output character set;
for each migration there is a pseudo-migration e (v_i, v_j; i_m/o_n) = { i_m/o_n, UIO (v_j) }, where UIO (v_j) represents a state sequence of states v_j;
representing a pseudo graph containing only pseudo migration with G ' = (V, E '), wherein E ' = { (v_i, v_j; i_m/o_n) |v_i, v_j E V, i_m E I, o_n E O } is a pseudo migration set of FSMs;
symmetrically expanding the pseudo graph G 'to generate a directional symmetrical graph G= (V, E), wherein E = E U E';
performing Euler traversal on the directed symmetrical graph to construct a state sequence of a plurality of states in the state set.
2. The method of claim 1, wherein after determining a test sequence from the sequence of states, the method further comprises:
decomposing the test sequence into: a charging start test sequence corresponding to a charging start process, an energy transmission test sequence corresponding to an energy transmission process, and a charging end test sequence corresponding to a charging end process.
3. The method of claim 2, wherein the charge initiation test sequence comprises:
heartbeat interaction forward/reverse test sequence, electronic lock control forward/reverse test sequence, version check forward/reverse test sequence, and start success/failure sequence.
4. The method of claim 2, wherein the energy transmission test sequence comprises:
and (5) forward/reverse testing of each item of charging data.
5. The method of claim 2, wherein the end-of-charge test sequence comprises:
an active end charge test sequence and a passive end charge test sequence caused by various faults.
6. A testing arrangement of electric pile fills, characterized in that includes:
the acquisition unit is used for acquiring a finite state machine FSM model of a communication protocol between the charging control unit and the charging pile main control board, wherein the finite state machine FSM model comprises: a state set and a migration set;
the construction unit is used for constructing a state sequence of a plurality of states in the state set by taking an initial state in the state set as a starting point and carrying out Euler traversal according to a migration path in the migration set;
a determining unit, configured to determine a test sequence according to the state sequence;
wherein the FSM model is represented by a directed graph g= (V, E), wherein v= { v_1, v_ … v_n } is the state set; e= { (v_i, v_j; i_m/o_n) |v_i, v_j E V, i_m E I, o_n E O } is the migration set, where v_i represents the initial state, v_j represents the state after execution of the migration path i_m/o_n, I is a limited input character set, and O is a limited output character set;
for each migration there is a pseudo-migration e (v_i, v_j; i_m/o_n) = { i_m/o_n, UIO (v_j) }, where UIO (v_j) represents a state sequence of states v_j;
representing a pseudo graph containing only pseudo migration with G ' = (V, E '), wherein E ' = { (v_i, v_j; i_m/o_n) |v_i, v_j E V, i_m E I, o_n E O } is a pseudo migration set of FSMs;
symmetrically expanding the pseudo graph G 'to generate a directional symmetrical graph G= (V, E), wherein E = E U E';
performing Euler traversal on the directed symmetrical graph to construct a state sequence of a plurality of states in the state set.
7. The apparatus of claim 6, wherein the apparatus further comprises:
a decomposition unit, configured to decompose the test sequence into: a charging start test sequence corresponding to a charging start process, an energy transmission test sequence corresponding to an energy transmission process, and a charging end test sequence corresponding to a charging end process.
8. The apparatus of claim 7, wherein the charge initiation test sequence comprises:
heartbeat interaction forward/reverse test sequence, electronic lock control forward/reverse test sequence, version check forward/reverse test sequence, and start success/failure sequence.
9. A "computer-readable storage medium" or a "nonvolatile storage medium", characterized in that the "computer-readable storage medium" or the "nonvolatile storage medium" includes a stored program, wherein the program, when run, controls the device in which the "computer-readable storage medium" or the "nonvolatile storage medium" is located to perform the start-up test method of the charging pile according to any one of claims 1 to 5.
10. A processor for running a program, wherein the program runs to perform the method of start-up testing of a charging stake according to any one of claims 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011323867.2A CN112306889B (en) | 2020-11-23 | 2020-11-23 | Method and device for testing charging pile, storage medium and processor |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011323867.2A CN112306889B (en) | 2020-11-23 | 2020-11-23 | Method and device for testing charging pile, storage medium and processor |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112306889A CN112306889A (en) | 2021-02-02 |
CN112306889B true CN112306889B (en) | 2023-10-20 |
Family
ID=74335374
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011323867.2A Active CN112306889B (en) | 2020-11-23 | 2020-11-23 | Method and device for testing charging pile, storage medium and processor |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112306889B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113872839B (en) * | 2021-08-27 | 2023-02-14 | 惠州市德赛西威汽车电子股份有限公司 | Real vehicle testing method based on CAN signal automatic transmission and storage medium |
CN113960390A (en) * | 2021-09-08 | 2022-01-21 | 浙江吉利控股集团有限公司 | Charging simulation test method and device |
CN115454013A (en) * | 2022-06-30 | 2022-12-09 | 国网北京市电力公司 | Testing device |
CN116170356B (en) * | 2023-02-22 | 2024-07-09 | 华中科技大学 | Communication compliance testing method and system for electric vehicle charging |
Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101507082A (en) * | 2006-06-30 | 2009-08-12 | 数据逻辑扫描集团有限公司 | Method and apparatus for charging batteries |
CN104487957A (en) * | 2012-07-18 | 2015-04-01 | 美光科技公司 | Methods and devices for programming a state machine engine |
CN104583935A (en) * | 2012-08-31 | 2015-04-29 | 美光科技公司 | Instruction insertion in state machine engines |
CN106708739A (en) * | 2016-12-30 | 2017-05-24 | 桂林电子科技大学 | Extended finite state machine (EFSM) model-based Web service case generation method and system |
CN107566377A (en) * | 2017-09-11 | 2018-01-09 | 北京智芯微电子科技有限公司 | The method and charging device of multi-protocols adaptation are carried out to charging device |
CN108038060A (en) * | 2017-12-28 | 2018-05-15 | 上海璞恒新能源科技有限公司 | A kind of test method, device, terminal and computer-readable medium |
CN108965044A (en) * | 2018-06-12 | 2018-12-07 | 南瑞集团有限公司 | A kind of electric car electrically-charging equipment universal data link health status test device, system and method |
CN109284092A (en) * | 2018-09-20 | 2019-01-29 | 山东电工电气集团新能科技有限公司 | A kind of software implementation method of direct-current charging post monitoring system |
CN109542783A (en) * | 2018-11-19 | 2019-03-29 | 北京航空航天大学 | A kind of extended finite state machine test data generating method based on variable segmentation |
CN111064735A (en) * | 2019-12-25 | 2020-04-24 | 南开大学 | SQL injection vulnerability detection method and system for power information system |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6944848B2 (en) * | 2001-05-03 | 2005-09-13 | International Business Machines Corporation | Technique using persistent foci for finite state machine based software test generation |
-
2020
- 2020-11-23 CN CN202011323867.2A patent/CN112306889B/en active Active
Patent Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101507082A (en) * | 2006-06-30 | 2009-08-12 | 数据逻辑扫描集团有限公司 | Method and apparatus for charging batteries |
CN104487957A (en) * | 2012-07-18 | 2015-04-01 | 美光科技公司 | Methods and devices for programming a state machine engine |
CN104583935A (en) * | 2012-08-31 | 2015-04-29 | 美光科技公司 | Instruction insertion in state machine engines |
CN106708739A (en) * | 2016-12-30 | 2017-05-24 | 桂林电子科技大学 | Extended finite state machine (EFSM) model-based Web service case generation method and system |
CN107566377A (en) * | 2017-09-11 | 2018-01-09 | 北京智芯微电子科技有限公司 | The method and charging device of multi-protocols adaptation are carried out to charging device |
CN108038060A (en) * | 2017-12-28 | 2018-05-15 | 上海璞恒新能源科技有限公司 | A kind of test method, device, terminal and computer-readable medium |
CN108965044A (en) * | 2018-06-12 | 2018-12-07 | 南瑞集团有限公司 | A kind of electric car electrically-charging equipment universal data link health status test device, system and method |
CN109284092A (en) * | 2018-09-20 | 2019-01-29 | 山东电工电气集团新能科技有限公司 | A kind of software implementation method of direct-current charging post monitoring system |
CN109542783A (en) * | 2018-11-19 | 2019-03-29 | 北京航空航天大学 | A kind of extended finite state machine test data generating method based on variable segmentation |
CN111064735A (en) * | 2019-12-25 | 2020-04-24 | 南开大学 | SQL injection vulnerability detection method and system for power information system |
Non-Patent Citations (4)
Title |
---|
Protocol Conformance Test Sequence Generation for Q/GDW11709.2 Based on FSM;Huijie Ge 等;《Proceedings of PURPLE MOUNTAIN FORUM 2019-International Forum on Smart Grid Protection and Control》;第585卷;825-836 * |
基于FSM模型的无线传感器网络数据收集协议测试;刘层层 等;《软件导刊》;第16卷(第9期);14-18 * |
浅谈充电桩的测试系统及相关研究;沈骏清;《科技创新导报》;第15卷(第11期);93-95 * |
电动汽车直流充电桩监测与管理系统研究与设计;宋红贺;《中国优秀硕士学位论文全文数据库 工程科技Ⅱ辑》(第3期);C042-1224 * |
Also Published As
Publication number | Publication date |
---|---|
CN112306889A (en) | 2021-02-02 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112306889B (en) | Method and device for testing charging pile, storage medium and processor | |
Tretmans | Model-based testing and some steps towards test-based modelling | |
Sarma et al. | Automatic test case generation from UML sequence diagram | |
CN105302554B (en) | A kind of android system automated procedures construction method and system | |
Tretmans | Test generation with inputs, outputs and repetitive quiescence | |
Cavalcante et al. | Supporting dynamic software architectures: From architectural description to implementation | |
Walkinshaw et al. | Increasing functional coverage by inductive testing: A case study | |
CN109274307A (en) | Motor rotation becomes initial angle scaling method, device, equipment and system | |
Sidhu et al. | Experience with formal methods in protocol development | |
CN109493226B (en) | A kind of intelligent contract condition monitoring system and monitoring method based on block chain | |
Wang et al. | Protocol testing techniques | |
CN116743809A (en) | Data simulation method, storage medium and test platform of Internet of things equipment | |
US8140897B2 (en) | Testing method for complex systems | |
Nokhbeh Zaeem et al. | Repair abstractions for more efficient data structure repair | |
CN110471767A (en) | A kind of dispatching method of equipment | |
Groz et al. | Using adaptive sequences for learning non-resettable FSMs | |
CN109144563A (en) | Application component constructs packaging method, device and computer storage medium | |
CN112104614B (en) | Agent monitoring method, device, equipment and storage medium for cipher machine | |
Kurtoglu et al. | Towards a framework for evaluating and comparing diagnosis algorithms | |
Karimoddini et al. | Fault diagnosis of Discrete Event Systems under uncertain initial conditions | |
CN112394945A (en) | System verification method for complex edge calculation | |
Popovic et al. | A statistical approach to model-based robustness testing | |
JP2002077071A (en) | Automatic fault diagnosis and correction method for private wireless network | |
Ahmadi | Testing models of reactive systems | |
CN111782499A (en) | Test case generation method and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |