CN107609434B - Method and system for testing performance of code scanning equipment - Google Patents

Method and system for testing performance of code scanning equipment Download PDF

Info

Publication number
CN107609434B
CN107609434B CN201710631360.5A CN201710631360A CN107609434B CN 107609434 B CN107609434 B CN 107609434B CN 201710631360 A CN201710631360 A CN 201710631360A CN 107609434 B CN107609434 B CN 107609434B
Authority
CN
China
Prior art keywords
time point
code scanning
module
image
testing machine
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
Application number
CN201710631360.5A
Other languages
Chinese (zh)
Other versions
CN107609434A (en
Inventor
吴卫东
张征
刘礼建
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujian Landi Commercial Equipment Co Ltd
Original Assignee
Fujian Landi Commercial Equipment Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Fujian Landi Commercial Equipment Co Ltd filed Critical Fujian Landi Commercial Equipment Co Ltd
Priority to CN201710631360.5A priority Critical patent/CN107609434B/en
Publication of CN107609434A publication Critical patent/CN107609434A/en
Application granted granted Critical
Publication of CN107609434B publication Critical patent/CN107609434B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention relates to a method and a system for testing the performance of code scanning equipment; in the method for testing the performance of the scanning equipment, the time is automatically measured in a circulating manner, and the scanning equipment is randomly dormant for a period of time before a tester refreshes and displays a two-dimensional code, so that the code scanning starting time point of each circulating measurement corresponds to the random state of the scanning equipment to be tested, therefore, the result of each measurement is ensured to be different, and the measured minimum value approaches to the true value of the code scanning time infinitely along with the increase of the measurement times; because the whole circulation automatic measurement process does not need manual participation, the automation of measurement is realized; compared with the traditional timing method by auxiliary equipment such as a timing watch and the like, the timing result is more accurate; compared with the method for testing the code scanning time based on respective platform programs, the code scanning device to be tested does not need to be additionally provided with a test function on the code scanning program, so that the method is not influenced by the platform performance and the program resource distribution condition, is convenient to operate, and is small in implementation workload.

Description

Method and system for testing performance of code scanning equipment
Technical Field
The invention relates to a method and a system for testing performance of code scanning equipment.
Background
The performance of the code scanning equipment needs to be tested before the code scanning equipment leaves a factory, wherein the code scanning time of the code scanning equipment is an important index reflecting the performance of the code scanning equipment.
Currently, methods for testing code scanning time mainly include a timing method using an auxiliary device such as a timer and a method for testing code scanning time based on a platform program of the code scanning device.
The timing method by the aid of auxiliary equipment such as a timing meter is not accurate enough, and repeated implementation of experiments is difficult to guarantee.
And if the code scanning time is tested based on the respective platform programs, each code scanning device to be tested is required to add a test function on the code scanning program, and the code scanning device is influenced by the platform performance and the program resource allocation condition, so that the operation is inconvenient, the workload is large, and the code scanning device cannot be unified.
Disclosure of Invention
The technical problem to be solved by the invention is as follows: the method and the system for testing the performance of the code scanning equipment are provided, the measurement of the performance of the code scanning time is completed in a mode that a testing machine is connected and interacted with the code scanning equipment to be tested, and the problem that a test result in the existing method for testing the performance of the code scanning equipment is not accurate enough is solved.
In order to solve the technical problems, the invention adopts the technical scheme that: a method for testing code scanning time of code scanning equipment comprises the following steps:
s1: entering a continuous code scanning mode by code scanning equipment to be detected; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
s2: the test machine displays the two-dimensional code image;
s3: the test machine records the time point of finishing displaying the two-dimensional code image as a time point 1;
s4: collecting and decoding a two-dimensional code image displayed by a testing machine by code scanning equipment to be tested;
s5: when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine, the code scanning equipment to be tested sends feedback information to the testing machine;
s6: when the test machine receives feedback information sent by the code scanning equipment to be tested, the test machine records a time point as a time point 2;
s7: the testing machine clears the displayed two-dimensional code image;
s8: the testing machine sleeps for 0-T milliseconds; the value range of the T is between 10 and 200;
s9: loop S2-S8; the number of the circulation is more than 1000;
s10: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
The invention has the beneficial effects that: the invention relates to a method for testing the performance of scanning equipment, through circulating the automatic measurement time, before refreshing and displaying the two-dimensional code in the tester, sleep for a period of time at random, make the code scanning starting time point that each time circulates and measures correspond to the random state of the code scanning equipment to be measured, therefore guarantee that the result of every measurement is all different, with the increase of the number of times of measurement, the measured minimum value approaches to the true value of the code scanning time infinitely; because the whole circulation automatic measurement process does not need manual participation, the automation of measurement is realized; compared with the traditional timing method by auxiliary equipment such as a timing watch and the like, the timing result is more accurate; compared with the method for testing the code scanning time based on respective platform programs, the code scanning device to be tested does not need to be additionally provided with a test function on the code scanning program, so that the method is not influenced by the platform performance and the program resource distribution condition, is convenient to operate, and is small in implementation workload.
Drawings
FIG. 1 is a flowchart of a method for testing performance of a code scanning device according to an embodiment of the present invention;
FIG. 2 is a block diagram of a system for testing performance of a code scanning device according to an embodiment of the present invention;
description of reference numerals:
1. a code scanning device acquisition module; 2. a code scanning device image processing module; 3. a code scanning device decoding module; 4. a display module of a testing machine; 5. a recording module of a testing machine; 6. a test machine starting module; 7. a code scanning device sending module; 8. a testing machine dormancy module; 9. and a circulation module.
Detailed Description
In order to explain technical contents, achieved objects, and effects of the present invention in detail, the following description is made with reference to the accompanying drawings in combination with the embodiments.
The most key concept of the invention is as follows: the code scanning time performance is measured in a mode that a testing machine is connected and interacted with code scanning equipment to be tested, more than 1000 times of cycle testing are set, and random sleep time is added at each cycle interval, so that the minimum value of a test result is infinitely close to a true value.
Referring to fig. 1, a method for testing code scanning time of a code scanning device includes the following steps:
s1: entering a continuous code scanning mode by code scanning equipment to be detected; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
s2: the test machine displays the two-dimensional code image;
s3: the test machine records the time point of finishing displaying the two-dimensional code image as a time point 1;
s4: collecting and decoding a two-dimensional code image displayed by a testing machine by code scanning equipment to be tested;
s5: when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine, the code scanning equipment to be tested sends feedback information to the testing machine;
s6: when the test machine receives feedback information sent by the code scanning equipment to be tested, the test machine records a time point as a time point 2;
s7: the testing machine clears the displayed two-dimensional code image;
s8: the testing machine sleeps for 0-T milliseconds; the value range of the T is between 10 and 200;
s9: loop S2-S8; the number of the circulation is more than 1000;
s10: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
The test principle of the method for testing the performance of the code scanning device is described as follows: the tester is equipment with a display function, an operating system and an external interface, and comprises ARM, DSP, PC, a mobile phone, common PDA equipment and the like; fixing the tester at a position, and communicating by using an RS232 interface through a USB data line;
firstly, a to-be-detected code scanning device is set to be in a continuous code scanning mode, in the state, the to-be-detected code scanning device automatically and circularly acquires and decodes images, the to-be-detected code scanning device and a testing machine are fixed on a frame, and a camera of the to-be-detected code scanning device aligns with a display screen of the testing machine; when the test is started, the display screen of the test machine refreshes and displays the two-dimensional code image, the time point after the display is finished is recorded as a time point 1 which is equivalent to the time when the code scanning equipment to be tested starts to scan the code, and the code scanning equipment to be tested collects and decodes the two-dimensional code image displayed by the test machine; when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine, the code scanning equipment to be tested sends feedback information to the testing machine; when the test machine receives feedback information sent by the code scanning equipment to be tested, the test machine records a time point as a time point 2; the time equivalent to the time point 2-the time point 1 is the code scanning time of the code scanning equipment to be detected; the time point generally has errors, because the optimal situation is that when the tester records the time point 1, the code scanning equipment to be tested just enters the acquisition state of successfully decoding the image, but because the code scanning process time is very short, the ideal situation is difficult to realize; when a testing machine starts to display a two-dimensional code image, the running time point of a program of code scanning equipment to be tested may be the starting point of the acquisition state of an image which just enters a non-successfully-decodable state (the image in a data buffer area is a non-two-dimensional code image source), the time point of time point 1 may be the state of any one moment in any period in the cyclic code scanning process of the code scanning equipment to be tested, and the time point of time point 1 may also be the processing decoding state of the image which is not successfully decodable, so that under the general condition, the time from time point 2 to time point 1 is longer than the actual code scanning time of the code scanning equipment to be tested;
because the code scanning time of the code scanning equipment is very short, the time point of refreshing the two-dimensional code by the testing machine cannot accurately correspond to the acquisition state of the image which can be successfully decoded, only through continuous and repeated simulation approximation, the minimum measurement time is continuously calculated along with the increase of the simulation running times, namely the optimum approaching code scanning time, and the confidence coefficient that the obtained minimum measurement time is the reliable code scanning time of the code scanning equipment is higher along with the increase of the simulation running times;
therefore, after the test machine receives the signal after the scanning is successful, the displayed two-dimensional code image can be cleared, after the short-time random dormancy is carried out for 0-T milliseconds, the screen refreshes and displays a new two-dimensional code image, and the code scanning test process is continuously and repeatedly circulated; the random dormancy 0-T milliseconds are set according to the time period of the code scanning equipment to be tested, T is generally 10-200 ms, the value of T is the code scanning period of the code scanning equipment to be tested, in the actual test environment, in the face of common code scanning equipment in the market, the current code scanning performance is generally close, the fluctuation of the main comparison time range is in the level of dozens of milliseconds, therefore, generally T is in the value range, and the code scanning performance test of most of the code scanning equipment can be ensured by taking 5ms as the adjustment step length; because the T values of different to-be-detected code scanning devices are possibly different (for example, the HONEYWELL MS9540 laser bar code scanning gun T is about 14MS, the Motorola symbol ls2208ap bar code scanner T is about 32MS for the 10MS New continent NLS-HR1030 bar code scanning gun T, and the Motorola Clarigo C11 one-dimensional scanning gun T is about 100 MS), the value of the T is required to be adjusted according to the actual situation, so that the situation that a tester is periodically started to display a two-dimensional code, and the to-be-detected code scanning devices repeatedly display the same value in the follow-up process after the code scanning time is firstly measured by the to-be-detected code scanning devices is avoided; after the random dormancy, the host computer can be ensured to start displaying the two-dimensional code, and the code scanning equipment program to be tested is in a random state.
The cycle times are generally more than 1000-10000 times, enough times are the minimum value which is guaranteed to continuously approach the code scanning time of measurement, and after the enough times are simulated and run, more times are only slightly improved without necessity, so the times are generally more than 1000 times.
According to the law of large numbers, the minimum value of the obtained time point 2-time point 1 values is continuously close to the true value of the code scanning time through multiple times of cyclic measurement, and therefore the relatively accurate code scanning time is measured.
In the method for testing the performance of the scanning equipment, the time is automatically measured in a circulating manner, and the scanning equipment is randomly dormant for a period of time before a tester refreshes and displays a two-dimensional code, so that the code scanning starting time point of each circulating measurement corresponds to the random state of the scanning equipment to be tested, therefore, the result of each measurement is ensured to be different, and the measured minimum value approaches to the true value of the code scanning time infinitely along with the increase of the measurement times; because the whole circulation automatic measurement process does not need manual participation, the automation of measurement is realized; compared with the traditional timing method by auxiliary equipment such as a timing watch and the like, the timing result is more accurate; compared with the method for testing the code scanning time based on respective platform programs, the code scanning device to be tested does not need to be additionally provided with a test function on the code scanning program, so that the method is not influenced by the platform performance and the program resource distribution condition, is convenient to operate, and is small in implementation workload.
In the method for testing performance of code scanning device, after S7, the method further includes:
the screen clearing state of the tester is kept for 1-3 seconds.
The screen of the testing machine is cleared for 1-3 seconds, so that the slave machine can only successfully decode one frame of image frame containing the two-dimensional code at most in one code scanning period, and the code scanning time performance of the code scanning equipment is measured and counted more reliably; the screen clearing time is 1 second, so that the code scanning equipment to be tested can effectively acquire two-dimensional codes in an image acquisition state, and the condition that a plurality of two-dimensional code image data which can be successfully decoded exist in a buffer area of the code scanning equipment to be tested is avoided, so that the condition that a host continuously receives a plurality of same signals due to the fact that the decoding time of misdetection is 0 due to the fact that the signals which are successfully decoded are immediately received once the test machine is started is avoided.
In the method for testing the performance of the code scanning equipment, the screen clearing state of the testing machine is kept for 1 second.
In the method for testing performance of a code scanning device, before the step S2, the method further includes the steps of:
the test machine records the time point of starting displaying the two-dimensional code image as a time point 0.
In the method for testing performance of the code scanning device, the step of recording the time point for starting displaying the two-dimensional code image as the time point 0 by the testing machine is specifically as follows:
triggering and starting a testing machine;
when a test machine is triggered and started, a drawing display function is immediately called;
and recording the time point of the previous position of the calling drawing display function as the time point 0.
In the method for testing performance of the code scanning device, the S3 specifically includes the following steps:
the point in time after the call to the charting display function is recorded as point in time 1.
In the method for testing performance of code scanning equipment, after "recording a time point of a position after calling a drawing display function as a time point 1", the method further comprises the following steps:
and recording the values from the time point 1 to the time point 0, wherein the values from the time point 1 to the time point 0 are the time for calling the image display function by the function.
In the method for testing performance of the code scanning device, the single code scanning process includes the following steps:
s101: collecting an image;
s102: graying the acquired image;
s103: and decoding the grayed image.
In the method for testing performance of the code scanning device, the step S8 is specifically:
the tester randomly sleeps for 0-100 milliseconds.
The method for testing the performance of the code scanning equipment comprises the following steps:
s1: entering a continuous code scanning mode by code scanning equipment to be detected; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
s101: collecting an image;
s102: graying the acquired image;
s103: decoding the grayed image;
s2: the test machine displays the two-dimensional code image;
s3: the test machine records the time point of starting displaying the two-dimensional code image as a time point 0;
s31: triggering and starting a testing machine;
s32: when a test machine is triggered and started, a drawing display function is immediately called;
s33: recording the time point of the previous position of the calling drawing display function as a time point 0;
s4: recording the time point of a position behind the calling drawing display function as a time point 1;
s5: recording values from time point 1 to time point 0, wherein the values from time point 1 to time point 0 are the time for calling the image display function by the function;
s6: collecting and decoding a two-dimensional code image displayed by a testing machine by code scanning equipment to be tested;
s7: when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine, the code scanning equipment to be tested sends feedback information to the testing machine;
s8: when the test machine receives feedback information sent by the code scanning equipment to be tested, the test machine records a time point as a time point 2;
s9: the testing machine clears the displayed two-dimensional code image;
s10: keeping the screen clearing state of the testing machine for 1-3 seconds;
s11: the testing machine sleeps for 0-100 milliseconds;
s12: loop S2-S11; the number of cycles is 2000;
s13: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
Referring to fig. 2, a system for testing performance of a code scanning apparatus includes:
sweep a yard equipment collection module 1: the device for scanning the code to be detected enters a continuous code scanning mode; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
the test machine display module 4: the test machine is used for displaying the two-dimensional code image;
the test machine recording module 5: the time point for recording the completion of displaying the two-dimensional code image by the testing machine is a time point 1;
code scanning device decoding module 3: the two-dimensional code scanning device is used for collecting and decoding a two-dimensional code image displayed by the testing machine by the code scanning device to be tested;
code scanning device sending module 7: the device is used for sending feedback information to the testing machine when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine;
the test machine recording module 5: the device is used for recording the time point as a time point 2 when the test machine receives the feedback information sent by the code scanning equipment to be tested;
the test machine display module 4: the test machine is used for clearing the displayed two-dimensional code image;
the testing machine dormancy module 8: the device is used for sleeping for 0-T milliseconds by the tester; the value range of the T is between 10 and 200;
the circulation module 9: loop S2-S8; the number of the circulation is more than 1000;
the test machine recording module 5: for recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
In the system for testing performance of a code scanning device, the method includes:
the test machine display module 4: the state of the screen clearing of the tester is kept for 1-3 seconds.
In the system for testing performance of a code scanning device, the method includes:
the test machine recording module 5: the time point for the tester to record and start displaying the two-dimensional code image is time point 0.
In the system for testing performance of a code scanning device, the method includes:
the test machine recording module 5: the time point for the tester to record and start displaying the two-dimensional code image is time point 0.
In the system for testing performance of a code scanning device, the method includes:
the test machine starting module 6: the device is used for triggering and starting the testing machine;
the test machine display module 4: the device is used for calling a drawing display function immediately when the test machine is triggered and started;
the test machine recording module 5: and recording the time point of the previous position of the calling drawing display function as a time point 0.
In the system for testing performance of a code scanning device, the method includes:
the test machine recording module 5: the time point for recording a position after the calling of the drawing display function is the time point 1.
In the system for testing performance of a code scanning device, the method includes:
the test machine recording module 5: the method is used for recording the values from time point 1 to time point 0, and the values from time point 1 to time point 0 are the time for calling the image display function by the function.
In the system for testing performance of a code scanning device, the method includes:
sweep a yard equipment collection module 1: for acquiring an image;
code scanning device image processing module 2: for graying the acquired image;
code scanning device decoding module 3: for decoding the grayed image.
In the system for testing performance of a code scanning device, the method includes:
the testing machine dormancy module 8: for random sleep of the tester for 0-100 milliseconds.
In the system for testing performance of a code scanning device, the method includes:
sweep a yard equipment collection module 1: the device for scanning the code to be detected enters a continuous code scanning mode; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
sweep a yard equipment collection module 1: for acquiring an image;
code scanning device image processing module 2: for graying the acquired image;
code scanning device decoding module 3: for decoding the grayed image;
the test machine display module 4: the test machine is used for displaying the two-dimensional code image;
the test machine recording module 5: the test machine is used for recording the time point of starting displaying the two-dimensional code image as a time point 0;
the test machine starting module 6: the device is used for triggering and starting the testing machine;
the test machine display module 4: the device is used for calling a drawing display function immediately when the test machine is triggered and started;
the test machine recording module 5: the time point used for recording the previous position of the calling drawing display function is the time point 0;
the test machine recording module 5: the time point used for recording the position after the calling of the drawing display function is the time point 1;
the test machine recording module 5: the system comprises a function calling module, a storage module and a display module, wherein the function calling module is used for recording values from time point 1 to time point 0, and the values from time point 1 to time point 0 are the time for calling the image display function by the function;
code scanning device decoding module 3: the two-dimensional code scanning device is used for collecting and decoding a two-dimensional code image displayed by the testing machine by the code scanning device to be tested;
code scanning device sending module 7: the device is used for sending feedback information to the testing machine when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine;
the test machine recording module 5: the device is used for recording the time point as a time point 2 when the test machine receives the feedback information sent by the code scanning equipment to be tested;
the test machine display module 4: the test machine is used for clearing the displayed two-dimensional code image;
the test machine display module 4: the screen clearing state is kept for 1-3 seconds for the testing machine;
the testing machine dormancy module 8: the device is used for sleeping for 0-100 milliseconds for the tester;
the circulation module 9: for cycles S2 through S11; the number of cycles is 2000;
the test machine recording module 5: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
Example 1
Referring to fig. 1, a method for testing performance of a code scanning apparatus includes the following steps:
s1: entering a continuous code scanning mode by code scanning equipment to be detected; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
s101: collecting an image;
s102: graying the acquired image;
s103: decoding the grayed image;
s2: the test machine displays the two-dimensional code image;
s3: the test machine records the time point of starting displaying the two-dimensional code image as a time point 0;
s31: triggering and starting a testing machine;
s32: when a test machine is triggered and started, a drawing display function is immediately called;
s33: recording the time point of the previous position of the calling drawing display function as a time point 0;
s4: recording the time point of a position behind the calling drawing display function as a time point 1;
s5: recording values from time point 1 to time point 0, wherein the values from time point 1 to time point 0 are the time for calling the image display function by the function;
s6: collecting and decoding a two-dimensional code image displayed by a testing machine by code scanning equipment to be tested;
s7: when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine, the code scanning equipment to be tested sends feedback information to the testing machine;
s8: when the test machine receives feedback information sent by the code scanning equipment to be tested, the test machine records a time point as a time point 2;
s9: the testing machine clears the displayed two-dimensional code image;
s10: keeping the screen clearing state of the testing machine for 1-3 seconds;
s11: the testing machine sleeps for 0-100 milliseconds;
s12: loop S2-S11; the number of cycles is 2000;
s13: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
Referring to fig. 2, a system for testing performance of a code scanning apparatus includes:
sweep a yard equipment collection module 1: the device for scanning the code to be detected enters a continuous code scanning mode; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
sweep a yard equipment collection module 1: for acquiring an image;
code scanning device image processing module 2: for graying the acquired image;
code scanning device decoding module 3: for decoding the grayed image;
the test machine display module 4: the test machine is used for displaying the two-dimensional code image;
the test machine recording module 5: the test machine is used for recording the time point of starting displaying the two-dimensional code image as a time point 0;
the test machine starting module 6: the device is used for triggering and starting the testing machine;
the test machine display module 4: the device is used for calling a drawing display function immediately when the test machine is triggered and started;
the test machine recording module 5: the time point used for recording the previous position of the calling drawing display function is the time point 0;
the test machine recording module 5: the time point used for recording the position after the calling of the drawing display function is the time point 1;
the test machine recording module 5: the system comprises a function calling module, a storage module and a display module, wherein the function calling module is used for recording values from time point 1 to time point 0, and the values from time point 1 to time point 0 are the time for calling the image display function by the function;
code scanning device decoding module 3: the two-dimensional code scanning device is used for collecting and decoding a two-dimensional code image displayed by the testing machine by the code scanning device to be tested;
code scanning device sending module 7: the device is used for sending feedback information to the testing machine when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine;
the test machine recording module 5: the device is used for recording the time point as a time point 2 when the test machine receives the feedback information sent by the code scanning equipment to be tested;
the test machine display module 4: the test machine is used for clearing the displayed two-dimensional code image;
the test machine display module 4: the screen clearing state is kept for 1-3 seconds for the testing machine;
the testing machine dormancy module 8: the device is used for sleeping for 0-100 milliseconds for the tester;
the circulation module 9: for cycles S2 through S11; the number of cycles is 2000;
the test machine recording module 5: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
In summary, in the method for testing the performance of the scanning device according to the present invention, the time is automatically measured in a loop, and before the tester refreshes and displays the two-dimensional code, the two-dimensional code is randomly dormant for a period of time, so that the start time point of the code scanning measured in each loop corresponds to the random state of the code scanning device to be tested, thereby ensuring that the results of each measurement are different, and the measured minimum value approaches the true value of the code scanning time infinitely as the number of times of measurement increases; because the whole circulation automatic measurement process does not need manual participation, the automation of measurement is realized; compared with the traditional timing method by auxiliary equipment such as a timing watch and the like, the timing result is more accurate; compared with the method for testing the code scanning time based on respective platform programs, the code scanning device to be tested does not need to be additionally provided with a test function on the code scanning program, so that the method is not influenced by the platform performance and the program resource distribution condition, is convenient to operate, and is small in implementation workload. The screen of the testing machine is cleared for 1-3 seconds, so that the slave machine can only successfully decode one frame of image frame containing the two-dimensional code at most in one code scanning period, and the code scanning time performance of the code scanning equipment is measured and counted more reliably; the screen clearing time is 1 second, so that the code scanning equipment to be tested can effectively acquire two-dimensional codes in an image acquisition state, and the condition that a plurality of two-dimensional code image data which can be successfully decoded exist in a buffer area of the code scanning equipment to be tested is avoided, so that the condition that a host continuously receives a plurality of same signals due to the fact that the decoding time of misdetection is 0 due to the fact that the signals which are successfully decoded are immediately received once the test machine is started is avoided.
The above description is only an embodiment of the present invention, and not intended to limit the scope of the present invention, and all equivalent changes made by using the contents of the present specification and the drawings, or applied directly or indirectly to the related technical fields, are included in the scope of the present invention.

Claims (19)

1. A method for testing performance of code scanning equipment is characterized by comprising the following steps:
s1: entering a continuous code scanning mode by code scanning equipment to be detected; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
s2: the test machine displays the two-dimensional code image;
s3: the test machine records the time point of finishing displaying the two-dimensional code image as a time point 1;
s4: collecting and decoding a two-dimensional code image displayed by a testing machine by code scanning equipment to be tested;
s5: when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine, the code scanning equipment to be tested sends feedback information to the testing machine;
s6: when the test machine receives feedback information sent by the code scanning equipment to be tested, the test machine records a time point as a time point 2;
s7: the testing machine clears the displayed two-dimensional code image;
s8: the testing machine sleeps for 0-T milliseconds; the value range of the T is between 10 and 200;
s9: loop S2-S8; the number of the circulation is more than 1000;
s10: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
2. The method for testing performance of a code scanning device according to claim 1, wherein after S7, the method further comprises the steps of:
the screen clearing state of the tester is kept for 1-3 seconds.
3. The method of claim 1, wherein the tester is kept in a clear state for 1 second.
4. The method for testing performance of a code scanning device according to claim 1, wherein said S2 is preceded by the steps of:
the test machine records the time point of starting displaying the two-dimensional code image as a time point 0.
5. The method for testing performance of a code scanning device according to claim 4, wherein the step of recording, by the testing machine, that the time point at which the two-dimensional code image is started to be displayed is time point 0 specifically comprises:
triggering and starting a testing machine;
when a test machine is triggered and started, a drawing display function is immediately called;
and recording the time point of the previous position of the calling drawing display function as the time point 0.
6. The method for testing performance of a code scanning device according to claim 5, wherein the step S3 specifically comprises the steps of:
the point in time after the call to the charting display function is recorded as point in time 1.
7. The method for testing the performance of a code scanning device according to claim 6, wherein after the step of recording the time point of the position after the calling of the drawing display function as the time point 1, the method further comprises the steps of:
and recording the values from the time point 1 to the time point 0, wherein the values from the time point 1 to the time point 0 are the time for calling the image display function by the function.
8. The method for testing performance of code scanning device according to claim 1, wherein said step S1 includes the following steps:
s101: collecting an image;
s102: graying the acquired image;
s103: and decoding the grayed image.
9. The method for testing performance of a code scanning device according to claim 1, wherein the step S8 is specifically as follows:
the tester randomly sleeps for 0-100 milliseconds.
10. The method for testing performance of a code scanning device according to claim 1, comprising the steps of:
s1: entering a continuous code scanning mode by code scanning equipment to be detected; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
s101: collecting an image;
s102: graying the acquired image;
s103: decoding the grayed image;
s2: the test machine displays the two-dimensional code image;
s3: the test machine records the time point of starting displaying the two-dimensional code image as a time point 0;
s31: triggering and starting a testing machine;
s32: when a test machine is triggered and started, a drawing display function is immediately called;
s33: recording the time point of the previous position of the calling drawing display function as a time point 0;
s4: recording the time point of a position behind the calling drawing display function as a time point 1;
s5: recording values from time point 1 to time point 0, wherein the values from time point 1 to time point 0 are the time for calling the image display function by the function;
s6: collecting and decoding a two-dimensional code image displayed by a testing machine by code scanning equipment to be tested;
s7: when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine, the code scanning equipment to be tested sends feedback information to the testing machine;
s8: when the test machine receives feedback information sent by the code scanning equipment to be tested, the test machine records a time point as a time point 2;
s9: the testing machine clears the displayed two-dimensional code image;
s10: keeping the screen clearing state of the testing machine for 1-3 seconds;
s11: the testing machine sleeps for 0-100 milliseconds;
s12: loop S2-S11; the number of cycles is 2000;
s13: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
11. A system for testing performance of a code scanning device, comprising:
sweep a yard equipment acquisition module: the device for scanning the code to be detected enters a continuous code scanning mode; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
a display module of the testing machine: the test machine is used for displaying the two-dimensional code image;
a recording module of the testing machine: the time point for recording the completion of displaying the two-dimensional code image by the testing machine is a time point 1;
code scanning equipment decoding module: the two-dimensional code scanning device is used for collecting and decoding a two-dimensional code image displayed by the testing machine by the code scanning device to be tested;
sweep a yard equipment sending module: the device is used for sending feedback information to the testing machine when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine;
a recording module of the testing machine: the device is used for recording the time point as a time point 2 when the test machine receives the feedback information sent by the code scanning equipment to be tested;
a display module of the testing machine: the test machine is used for clearing the displayed two-dimensional code image;
a testing machine dormancy module: the device is used for sleeping for 0-T milliseconds by the tester; the value range of the T is between 10 and 200;
a circulation module: loop S2-S8; the number of the circulation is more than 1000;
a recording module of the testing machine: for recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
12. The system for testing performance of a code scanning device of claim 11, comprising:
a display module of the testing machine: the state of the screen clearing of the tester is kept for 1-3 seconds.
13. The system for testing performance of a code scanning device of claim 11, comprising:
a recording module of the testing machine: the time point for the tester to record and start displaying the two-dimensional code image is time point 0.
14. The system for testing performance of a code scanning device of claim 11, comprising:
the test machine starting module: the device is used for triggering and starting the testing machine;
a display module of the testing machine: the device is used for calling a drawing display function immediately when the test machine is triggered and started;
a recording module of the testing machine: and recording the time point of the previous position of the calling drawing display function as a time point 0.
15. The system for testing performance of a code scanning device of claim 11, comprising:
a recording module of the testing machine: the time point for recording a position after the calling of the drawing display function is the time point 1.
16. The system for testing performance of a code scanning device of claim 11, comprising:
a recording module of the testing machine: the method is used for recording the values from time point 1 to time point 0, and the values from time point 1 to time point 0 are the time for calling the image display function by the function.
17. The system for testing performance of a code scanning device of claim 11, comprising:
sweep a yard equipment acquisition module: for acquiring an image;
sweep yard equipment image processing module: for graying the acquired image;
code scanning equipment decoding module: for decoding the grayed image.
18. The system for testing performance of a code scanning device of claim 11, comprising:
a testing machine dormancy module: for random sleep of the tester for 0-100 milliseconds.
19. The system for testing performance of a code scanning device of claim 11, comprising:
sweep a yard equipment acquisition module: the device for scanning the code to be detected enters a continuous code scanning mode; when the machine to be tested enters a continuous code scanning mode, the image collecting and decoding process is automatically and circularly acquired;
sweep a yard equipment acquisition module: for acquiring an image;
sweep yard equipment image processing module: for graying the acquired image;
code scanning equipment decoding module: for decoding the grayed image;
a display module of the testing machine: the test machine is used for displaying the two-dimensional code image;
a recording module of the testing machine: the test machine is used for recording the time point of starting displaying the two-dimensional code image as a time point 0;
the test machine starting module: the device is used for triggering and starting the testing machine;
a display module of the testing machine: the device is used for calling a drawing display function immediately when the test machine is triggered and started;
a recording module of the testing machine: the time point used for recording the previous position of the calling drawing display function is the time point 0;
a recording module of the testing machine: the time point used for recording the position after the calling of the drawing display function is the time point 1;
a recording module of the testing machine: the system comprises a function calling module, a storage module and a display module, wherein the function calling module is used for recording values from time point 1 to time point 0, and the values from time point 1 to time point 0 are the time for calling the image display function by the function;
code scanning equipment decoding module: the two-dimensional code scanning device is used for collecting and decoding a two-dimensional code image displayed by the testing machine by the code scanning device to be tested;
sweep a yard equipment sending module: the device is used for sending feedback information to the testing machine when the code scanning equipment to be tested finishes decoding the two-dimensional code image displayed by the testing machine;
a recording module of the testing machine: the device is used for recording the time point as a time point 2 when the test machine receives the feedback information sent by the code scanning equipment to be tested;
a display module of the testing machine: the test machine is used for clearing the displayed two-dimensional code image;
a display module of the testing machine: the screen clearing state is kept for 1-3 seconds for the testing machine;
a testing machine dormancy module: the device is used for sleeping for 0-100 milliseconds for the tester;
a circulation module: for cycles S2 through S11; the number of cycles is 2000;
a recording module of the testing machine: recording time point 2-time point 1 values in each cycle; the minimum value obtained is the measured code scanning time.
CN201710631360.5A 2017-07-28 2017-07-28 Method and system for testing performance of code scanning equipment Active CN107609434B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710631360.5A CN107609434B (en) 2017-07-28 2017-07-28 Method and system for testing performance of code scanning equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710631360.5A CN107609434B (en) 2017-07-28 2017-07-28 Method and system for testing performance of code scanning equipment

Publications (2)

Publication Number Publication Date
CN107609434A CN107609434A (en) 2018-01-19
CN107609434B true CN107609434B (en) 2020-05-19

Family

ID=61060048

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710631360.5A Active CN107609434B (en) 2017-07-28 2017-07-28 Method and system for testing performance of code scanning equipment

Country Status (1)

Country Link
CN (1) CN107609434B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110032903A (en) * 2019-04-25 2019-07-19 迅镭智能(广州)科技有限公司 A kind of performance testing device and system of barcode scanning mould group
CN111914574A (en) * 2019-05-10 2020-11-10 神讯电脑(昆山)有限公司 Bar code scanner detection device and method thereof
CN111291578A (en) * 2020-03-10 2020-06-16 北京意锐新创科技有限公司 Production test method and system of mobile payment equipment
CN111539235A (en) * 2020-03-18 2020-08-14 苏州摩比信通智能系统有限公司 Method for preventing bar code from being scanned by two-dimensional bar code scanning engine by mistake and decoder applying same
CN113916576B (en) * 2021-10-08 2023-07-14 无锡宇宁智能科技有限公司 Test equipment and test method for testing screen-free code scanning machine by using same

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103593637A (en) * 2013-11-20 2014-02-19 深圳市太和物联信息技术有限公司 Two-dimension code scanning system and scanning and calibration method and system thereof
CN104123221A (en) * 2013-04-28 2014-10-29 腾讯科技(深圳)有限公司 Response time test method and device
CN105654012A (en) * 2015-12-30 2016-06-08 福建联迪商用设备有限公司 POS code scanning payment method and device
CN106934318A (en) * 2017-03-13 2017-07-07 东软集团股份有限公司 Barcode scanning processing method, apparatus and system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
DE102012103495B8 (en) * 2012-03-29 2014-12-04 Sick Ag Optoelectronic device for measuring structure or object sizes and method for calibration

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104123221A (en) * 2013-04-28 2014-10-29 腾讯科技(深圳)有限公司 Response time test method and device
CN103593637A (en) * 2013-11-20 2014-02-19 深圳市太和物联信息技术有限公司 Two-dimension code scanning system and scanning and calibration method and system thereof
CN105654012A (en) * 2015-12-30 2016-06-08 福建联迪商用设备有限公司 POS code scanning payment method and device
CN106934318A (en) * 2017-03-13 2017-07-07 东软集团股份有限公司 Barcode scanning processing method, apparatus and system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于证书的二维码生成和认证系统的研究;王望羊;《中国优秀硕士学位论文全文数据库 信息科技辑》;20170116;第69页 *

Also Published As

Publication number Publication date
CN107609434A (en) 2018-01-19

Similar Documents

Publication Publication Date Title
CN107609434B (en) Method and system for testing performance of code scanning equipment
CN108140297B (en) Suspicious person detection system and suspicious person detection method
CN106778955B (en) The system and method for realizing that car-mounted terminal is tested automatically is identified based on two dimensional code
CN102655585B (en) Video conference system and time delay testing method, device and system thereof
CN104714009A (en) Immunoassay detection system and detection method
CN112529129A (en) Method, device, system, equipment and medium for processing information of mobile sampling point
CN107784649B (en) Image recognition-based mandrel testing remote alarm system and method
CN103729105A (en) Unhealthy posture detection method and device for mobile terminal
CN103839301A (en) Working method of intelligent attendance system based on video tracking and face recognition
CN105513150A (en) Attendance registration method and device
CN109213683A (en) Method for generating test case and device
CN111159042A (en) Fluency testing method and device and electronic equipment
CN109446040A (en) A kind of acquisition methods, device and the terminal device of application interface starting duration
CN111083018B (en) Production detection method and device for wireless equipment
CN113143193A (en) Intelligent vision testing method, device and system
CN111128139B (en) Non-invasive voice test method and device
CN110113630B (en) Video detection method and device, electronic equipment and storage medium
CN101763029B (en) Electronic apparatus, imaging device, method for time correction, and program
CN102300116B (en) Rapid detection method of video resolution and apparatus thereof
CN103179429B (en) Test method and device for television system
CN112995650A (en) Method and device for detecting video continuity of camera
Choe et al. Design Of Attendance Information System Using Rfid
CN106448523A (en) Method and system for testing display screens
CN111291578A (en) Production test method and system of mobile payment equipment
CN103186753B (en) A kind of detection method of initial rate of PSAM card and device

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