A startup test circuit and method for code reader
By designing a loop test circuit and a closed-loop test circuit, the automatic power-on test of the code reader is realized, which solves the problem of long-term and prone to errors in manual testing, and improves the efficiency and reliability of the test.
Patent Information
- Application Number
- CN202111603487.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-24
- Publication Date
- 2025-04-18
- Estimated Expiration
- 2041-12-24
AI Technical Summary
In the prior art, the power-up process using manual test code readers is long and prone to errors, which is difficult to meet the high requirements of industrial code readers for power-up success rate.
A code reader start-up test circuit including a cycle test circuit, a closed-loop test circuit and a test circuit switching module is designed. The MOS switch is driven by a rectangular wave signal, so that the reader periodically powers on and off, and the success rate is counted through a digital display counter; the closed-loop test circuit is used to detect the code reader's power on and delays power off.
It realizes automated testing, saves manual testing time, improves the reliability of test results, and can analyze the reasons for the failure of the code reader startup.
Smart Images

Figure CN114545111B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of circuit technology, and in particular to a startup test circuit of a code reader and a method thereof. Background Art
[0002] An industrial barcode reader is an electronic product that scans (takes photos and decodes) one-dimensional or two-dimensional codes on objects. It is usually used for automatic barcode scanning on factory assembly lines and is part of industrial automated testing and product / material full-process automated management systems.
[0003] As part of the automation series, industrial barcode readers have high requirements for their reliability. Among them, the power-on success rate is an important indicator. In industrial sites, the power supply of barcode readers is usually permanently fixed to the on-site DC power bus without a separate switch. If the startup fails, the entire system power supply can only be restarted, which is time-consuming and inconvenient. Furthermore, if the barcode reader fails to start and the user does not detect it, directly starting the production process will cause worse consequences. The standard for barcode readers is that the power-on success rate is greater than 99.999%, that is, the failure rate cannot be greater than 1 for an average of 100,000 power-on starts. The Linux system runs inside the barcode reader, and the startup time is nearly half a minute. Different models of barcode readers have different characteristic outputs after successful startup. Some operating indicator lights flash; some built-in lighting sources are turned on; and some user IO ports output signals. If manual testing is used, it will take a considerable amount of testing time and is prone to errors. Therefore, it is necessary to design a startup test circuit and method for barcode readers. Summary of the invention
[0004] Therefore, the technical problem to be solved by the present invention is to overcome the defects of the prior art that the power-on of the code reader is manually tested, which consumes a considerable amount of testing time and is prone to errors.
[0005] In order to solve the above technical problems, the present invention provides a startup test circuit of a code reader, comprising: a cycle test circuit, a closed-loop test circuit and a test circuit switching module;
[0006] The cycle test circuit is used to generate a rectangular wave signal to drive the MOS switch to periodically power on and off the code reader, and display the number of successful and failed startups of the code reader;
[0007] The closed-loop test circuit is used to power on the code reader and detect whether the code reader is powered on successfully. If the code reader is not powered on successfully, the current state is maintained to analyze the reason why the code reader is not powered on successfully. If the code reader is powered on successfully, the power is turned off and then powered on again after a preset delay time.
[0008] The test circuit switching module is used to switch and enable the loop test circuit or the closed-loop test circuit.
[0009] In one embodiment of the present invention, the cycle test circuit comprises:
[0010] A power on / off signal cycle generator, used to generate a rectangular wave signal, driving the MOS switch to close during a high level period to power on the code reader, and driving the MOS switch to open during a low level period to power off the code reader;
[0011] A first digital display counter, used for obtaining the number of startup times of the code reader by counting the number of times the code reader is powered on;
[0012] The second digital display counter is used to obtain the number of successful startups of the code reader by counting the number of times the output port of the code reader outputs an electrical signal.
[0013] In one embodiment of the present invention, the cycle test circuit further includes:
[0014] A first photoresistor sampling circuit, used to detect a built-in light source signal of the code reader;
[0015] The comparison / amplification circuit is used to extract and send the built-in light source signal to the second digital display counter, so that the second digital display counter can obtain the number of successful startups of the code reader by counting the number of times the built-in light source signal is lit.
[0016] In one embodiment of the present invention, the closed-loop test circuit comprises:
[0017] An RS-triggered latch, used to output a high level when the closed-loop test circuit is started, close the MOS switch, and power on the code reader;
[0018] A second photoresistor sampling circuit is used to detect a flashing signal of an operating indicator light of the code reader;
[0019] A comparator, used for extracting and sending the flashing signal of the operation indicator light to a delay detection circuit;
[0020] The delay detection circuit is used to detect whether the flashing signal of the operation indicator light reaches a preset number of times. If the flashing signal of the operation indicator light reaches the preset number of times, the delay detection circuit outputs a signal to disconnect the MOS switch to the RS trigger latch to power off the code reader;
[0021] The power-off delay circuit is used to output a signal for closing the MOS switch to the RS trigger latch after a preset delay when the code reader is powered off, so as to power on the code reader.
[0022] In one embodiment of the present invention, the second photoresistor sampling circuit is also used to detect the built-in light source signal of the code reader, so as to extract and send the built-in light source signal to the delay detection circuit through the comparator.
[0023] In one embodiment of the present invention, the delay detection circuit is also used to detect whether the built-in light source signal reaches a preset time. If the built-in light source signal reaches the preset time, a signal to disconnect the MOS switch is output to the RS trigger latch to power off the code reader.
[0024] In one embodiment of the present invention, the delay detection circuit is also used to detect whether the output port of the code reader outputs an electrical signal. If the output port of the code reader outputs an electrical signal, a signal for disconnecting the MOS switch is output to the RS trigger latch to power off the code reader.
[0025] The present invention provides a startup test method for a code reader, comprising:
[0026] Enable the loop test circuit or the closed-loop test circuit by switching the test circuit switching module;
[0027] When the cyclic test circuit is enabled, the cyclic test circuit is used to generate a rectangular wave signal to drive the MOS switch, so that the code reader is periodically powered on and off, and the number of successful and failed startups of the code reader is displayed;
[0028] When the closed-loop test circuit is enabled, the code reader is powered on using the closed-loop test circuit, and whether the code reader is powered on successfully is detected. If the code reader is not powered on successfully, the current state is maintained to analyze the reason why the code reader is not powered on successfully. If the code reader is powered on successfully, the power is turned off and delayed for a preset time before being powered on again.
[0029] In one embodiment of the present invention, when the cyclic test circuit is enabled, the cyclic test circuit is used to generate a rectangular wave signal to drive a MOS switch to periodically power on and off the code reader, and the number of successful and failed startups of the code reader is displayed, including:
[0030] When the cycle test circuit is enabled, the power on / off signal cycle generator in the cycle test circuit is used to drive the MOS switch to close, so that the code reader is powered on and off, and the number of code reader power-on times counted by the first digital display counter and the number of code reader power-on successes counted by the second digital display counter are displayed, and the number of successful and failed startups of the code reader are displayed.
[0031] In one embodiment of the present invention, when the closed-loop test circuit is enabled, the code reader is powered on by the closed-loop test circuit, and whether the code reader is powered on successfully is detected. If the code reader is not powered on successfully, the current state is maintained to analyze the reason why the code reader is not powered on successfully. If the code reader is powered on successfully, the power is turned off and delayed for a preset time before being powered on again, including:
[0032] When the closed-loop test circuit is enabled, the RS trigger latch in the closed-loop test circuit is used to power on the code reader, and the second photoresistor sampling circuit is used to detect whether the code reader is powered on successfully. If the code reader is not powered on successfully, the current state is maintained to analyze the reason why the code reader is not powered on successfully. If the code reader is powered on successfully, the power-off delay circuit is used to delay the preset time before powering on again.
[0033] The above technical solution of the present invention has the following advantages compared with the prior art:
[0034] The startup test circuit and method of the code reader of the present invention include: a cycle test circuit, a closed-loop test circuit and a test circuit switching module; the cycle test circuit is used to generate a rectangular wave signal, drive a MOS switch, make the code reader power on and off periodically, and display the number of successful and failed startups of the code reader; the closed-loop test circuit is used to power on the code reader and detect whether the code reader is successfully powered on. If the code reader is not successfully powered on, the current state is maintained to analyze the reason why the code reader is not successfully powered on. If the code reader is successfully powered on, the power is turned off and then powered on again after a preset time delay; the test circuit switching module is used to switch to enable the cycle test circuit or the closed-loop test circuit. The present invention can calculate the startup success rate of the code reader through the cycle test circuit, and can keep the code reader that has not been successfully powered on in the powered-on state through the closed-loop test circuit, so that the technician can analyze the reason why the code reader fails to start. The cycle test circuit and the closed-loop test circuit are used to automatically test whether the code reader is successfully started, saving labor costs and ensuring the reliability of the test results. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] In order to make the content of the present invention more clearly understood, the present invention is further described in detail below according to specific embodiments of the present invention in conjunction with the accompanying drawings, wherein:
[0036] Figure 1 A structural diagram of a startup test method for a code reader provided by the present invention;
[0037] Figure 2 A circuit diagram of a test circuit switching module of the present invention;
[0038] Figure 3 A circuit diagram of a cyclic test circuit of the present invention;
[0039] Figure 4 is a circuit diagram of a MOS switch of the present invention;
[0040] Figure 5 4 is a circuit diagram of a closed-loop test circuit of the present invention. DETAILED DESCRIPTION
[0041] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments so that those skilled in the art can better understand the present invention and implement it, but the embodiments are not intended to limit the present invention.
[0042] The startup test circuit of the code reader of the present invention comprises: a cyclic test circuit, a closed-loop test circuit and a test circuit switching module;
[0043] The cycle test circuit is used to generate a rectangular wave signal to drive the MOS switch to periodically power on and off the code reader, and display the number of successful and failed startups of the code reader;
[0044] The closed-loop test circuit is used to power on the code reader and detect whether the code reader is powered on successfully. If the code reader is not powered on successfully, the current state is maintained to analyze the reason why the code reader is not powered on successfully. If the code reader is powered on successfully, the power is turned off and then powered on again after a preset delay time.
[0045] The test circuit switching module is used to switch and enable the loop test circuit or the closed-loop test circuit.
[0046] The startup test circuit provided in this embodiment realizes the automatic test of the startup success rate of the code reader, greatly saves labor costs and ensures the reliability of the test results. The startup success rate of the code reader can be calculated through the loop test circuit, and the test can be suspended when the test fails through the closed-loop test circuit to protect the site and allow technicians to analyze the cause of the startup failure.
[0047] Based on the above embodiments, this embodiment further illustrates the cycle test circuit and the closed-loop test circuit. Figure 1 As shown;
[0048] The cycle test circuit comprises: a power on / off signal cycle generator, a first digital display counter, a first photoresistor sampling circuit, a comparison / amplification circuit, and a second digital display counter;
[0049] The power on / off signal cycle generator is used to generate a rectangular wave signal, which drives the MOS switch to close during a high level period to power on the code reader, and drives the MOS switch to open during a low level period to power off the code reader;
[0050] The first digital display counter is used to count the number of times the code reader is powered on;
[0051] The first photoresistor sampling circuit is used to detect the built-in light source signal of the code reader;
[0052] The comparison / amplification circuit is used to extract and send the built-in light source signal to the second digital display counter;
[0053] The second digital display counter is used to count the number of times the output port of the code reader outputs an electrical signal or the number of times the built-in light source signal is lit, so as to calculate the startup success rate of the code reader.
[0054] The closed-loop test circuit comprises: an RS trigger latch, a second photoresistor sampling circuit, a comparator, a delay detection circuit and a power-off delay circuit;
[0055] The RS triggered latch is used to output a high level when the closed-loop test circuit is started, close the MOS switch, and power on the code reader;
[0056] The second photoresistor sampling circuit is used to detect the flashing signal of the operating indicator light or the built-in light source signal of the code reader;
[0057] The comparator is used to extract and send the flashing signal of the operation indicator light or the built-in light source signal to the delay detection circuit;
[0058] The delay detection circuit is used to detect whether the flashing signal of the operation indicator light reaches a preset number of times, whether the built-in light source signal reaches a preset time, or whether the output port of the code reader outputs an electrical signal. If the flashing signal of the operation indicator light reaches a preset number of times, the built-in light source signal reaches a preset time, or the output port of the code reader outputs an electrical signal, a signal for disconnecting the MOS switch is output to the RS trigger latch to power off the code reader;
[0059] The power-off delay circuit is used to output the closing MOS switch signal to the RS trigger latch after a preset delay when the code reader is powered off, so as to power on the code reader.
[0060] The working process of the startup test circuit of the code reader is as follows: the test circuit is switched to a loop test circuit or a closed-loop test circuit by a test circuit switching module, such as Figure 2 As shown, the switch SW2 is used to select which one of the two test circuits to enable. When the cycle test circuit is powered, the closed-loop test circuit is powered off. When the closed-loop test circuit is powered, the cycle test circuit is powered off.
[0061] When the test circuit is switched to the cyclic test circuit, the power on / off signal cyclic generator outputs a low level, and the MOS switch is in an off state. When the start signal is sent, the clock signal is also sent at the same time, and the power on / off signal cyclic generator generates an extremely low frequency rectangular wave signal with a settable duty cycle to drive the MOS switch to operate, close the MOS switch during the high level period, and power on the code reader, and open the MOS switch during the low level period, and power off the code reader. The first digital display counter counts the number of times the code reader is powered on.
[0062] Based on the cyclic test circuit provided in the above embodiment, the method for obtaining the number of successful power-on times of the code reader may include the following two methods:
[0063] Method A1: Use the first photoresistor sampling circuit to detect the built-in light source signal of the code reader. If the code reader is successfully started, the built-in light source will be lit, and the first photoresistor sampling circuit can detect the light source signal, extract the signal through the comparator and send it to the second digital display counter, and the second digital display counter counts to obtain the number of successful power-on times of the code reader.
[0064] Method A2: Detect the status of the OUT1 port of the code reader. If the code reader is started successfully, the OUT1 will output an electrical signal, and the second digital display counter captures the signal and counts.
[0065] By comparing the counts of the first digital display counter and the second digital display counter, the startup success rate of the code reader can be calculated. When the stop signal is sent, the clock signal is also stopped at the same time, the power on / off signal cycle generator stops working, the output remains at a low level, the MOS switch is turned off, and the code reader is powered off.
[0066] When the test circuit is switched to the closed-loop test circuit, the RS trigger latch outputs a low level and the MOS switch is in an off state. When the circuit is started, the clock signal is delivered, the RS trigger latch outputs a high level, and the MOS switch is closed to power on the code reader.
[0067] Based on the closed-loop test circuit provided in the above embodiment, the method for obtaining the number of successful power-on times of the code reader may include the following three methods:
[0068] Method B1: Use the second photoresistor sampling circuit to detect the operating indicator light of the code reader. If the code reader is successfully started, the operating indicator light will flash, and the second photoresistor sampling circuit can detect the flashing signal. The comparator extracts the signal and sends it to the delay detection circuit. After the delay detection circuit detects that the operating indicator light flashes a certain number of times, it outputs a signal to the RS trigger latch to disconnect the MOS switch and power off the code reader.
[0069] Method B2: Use the second photoresistor sampling circuit to detect the built-in light source signal of the code reader. If the code reader is successfully started, the built-in light source will be lit, and the second photoresistor sampling circuit can detect the light source signal. The comparator extracts the signal and sends it to the delay detection circuit. After the delay detection circuit detects that the light source has been on for a period of time, it outputs a signal to the RS trigger latch, disconnects the MOS switch, and powers off the code reader.
[0070] Method B3: Detect the status of the OUT1 port of the code reader. If the code reader is successfully started, OUT1 will output an electrical signal. After the delay detection circuit detects that this signal is maintained for a certain period of time, it outputs a signal to the RS trigger-latch, disconnects the MOS switch, and powers off the code reader. When the code reader is powered off, the power-off delay circuit is activated. After a delay period, the power-off delay circuit outputs a signal to the RS trigger latch, closes the MOS switch, and powers on the code reader again, and the cycle repeats.
[0071] If the closed-loop test circuit does not detect a valid startup success signal or the signal duration does not meet the design requirements, the MOS switch will not be disconnected, and the code reader will remain powered on to maintain the scene.
[0072] like Figure 3 As shown, the cyclic test circuit is a circuit with a 4-bit counter U1 as the core, which cyclically generates an extremely low-frequency rectangular wave signal. When the ON / OFF signal (start / stop signal) is pulled high, the CLR pin of U1 changes from low to high and exits reset. At this time, the output port Q (AD) is low, so that the LOAD pin of U1 is also low, and U1 enters the loading mode, and automatically loads the set value (0001-1111) of SW1 at the rising edge of the next clock. After loading the set value, at least one output of the output port Q (AD) outputs a high level, causing the output network O1 to become a high level, and the MOS switch Q10 is turned on, as shown in FIG. Figure 4As shown, the barcode reader starts to be powered on. At the same time, the LOAD pin of U1 also changes from low to high, and U1 enters the counting mode from the loading mode. The output network O1 continues to be high until the count reaches Q(AD)=0000, and then O1 changes to a low level, turning off the MOS switch Q10, and the barcode reader is powered off, completing a cycle.
[0073] The power-on time of the code reader = (1111-SW1 setting value + 1) × clock cycle. The power-off time is fixed to 1 clock cycle. When O1 becomes low level, U1 enters the loading mode again, automatically loads the setting value of SW1 at the rising edge of the next clock and makes the output network O1 high, starting the next cycle. Diodes D1, D2, D3, D4 and resistor R7 form an OR logic. As long as one of the output ports Q (AD) outputs a high level, the output network O1 becomes high level.
[0074] In detection method A1, 3-4 of J1 is short-circuited, and the photoresistor RL1 is close to the built-in light source of the code reader. If the code reader is successfully started, the built-in light source will be lit, reducing the resistance of the photoresistor RL1, thereby reducing the voltage of pin 3 of the operational amplifier U3. After comparison by the operational amplifier U3 and reverse amplification by Q1, a high-level signal is given to the second digital display counter through J1, so that the value of the second digital display counter is increased by 1, indicating that the number of successful starts has increased once.
[0075] Under detection method A2, 1-2 of J1 is short-circuited; if the code reader is successfully started, the OUT1 port of the code reader outputs a 12V high level, which is sent to the second digital display counter through J1. The count value of the second digital display counter is equal to the number of successful power-on starts.
[0076] The signal O1 controlling the MOS switch is amplified by Q7 and Q5 and sent to the first digital display counter. The count value of the first digital display counter is equal to the number of power-on starts. The value of the startup success rate is the ratio of the value of the second digital display counter to the value of the first digital display counter.
[0077] like Figure 5As shown, the closed-loop test circuit is a core control circuit composed of a 4-bit counter U4, an RS trigger U5, and a 4-bit counter U7. When powered on, Q8 is in the off state, and the delay circuit composed of R37 and C28 resets U5, causing U5 to output a low level. Before the start button is pressed, the clock CLK_1HZ is continuously at a low level, U4 does not work, the entire circuit is in a standby state, the Q1 pin of U5 outputs a continuous low level, the MOS switch Q10 is in a disconnected state, and the code reader is not powered on. When the start button is pressed, the clock CLK_1HZ is output, and U4 starts counting. After counting to the set number of times, the QC pin of U4 outputs a high level, which triggers U5 after Q4 is reversed, causing the Q1 pin of U5 to output a high level (the O2 network becomes a high level), turning on the MOS switch Q10, and powering on the code reader. Then the circuit starts to detect the signal that the code reader is successfully started.
[0078] Under detection method B1, 1-2 and 3-4 of J4 are short-circuited; 3-4 of J5 is short-circuited; photoresistor RL2 is close to the operation indicator LED. If the code reader is successfully started, the operation indicator LED will flash, and the resistance of the photoresistor RL2 will change with the LED on and off, thereby generating a changing voltage signal on pin 3 of op amp U8. After comparison by op amp U8, a level signal with an amplitude of 0-5V that changes with the LED is output on pin 1 of op amp U8. This signal is sent to the CLK pin of U7 through J4, causing U7 to start counting (delay). After counting to the set number of times, the QC pin of U7 outputs a high level, which is reversed by Q8 and resets U5, causing the Q1 pin of U5 to output a low level, disconnecting the MOS switch Q10, and powering off the code reader.
[0079] Under detection method B2, 5-6 and 7-8 of J4 are short-circuited; 1-2 of J5 is short-circuited; photoresistor RL2 is close to the built-in light source of the code reader. If the code reader is successfully started, the built-in light source will be lit, and the resistance of photoresistor RL2 will decrease, which will increase the voltage on pin 3 of op amp U8. After comparison by op amp U8, a continuous high level with an amplitude of 5V is output on pin 1 of op amp U8. This signal is applied to the CLR pin of U7 through J4, causing U7 to exit reset and start counting (delay). After counting to the set number of times, the QC pin of U7 outputs a high level, which is reversed by Q8 and resets U5, causing the Q1 pin of U5 to output a low level, disconnecting the MOS switch Q10, and powering off the code reader.
[0080] Under detection method B3, 7-8 and 9-10 of J4 are short-circuited; if the code reader starts successfully, the OUT1 port of the code reader outputs a 12V high level, which is divided by R38 and R39 and then applied to the CLR pin of U7 through J4, causing U7 to exit reset and start counting (delay). After counting to the set number of times, the QC pin of U7 outputs a high level, which is reversed by Q8 and resets U5, causing the Q1 pin of U5 to output a low level, disconnecting the MOS switch Q10 and powering off the code reader.
[0081] When the barcode reader is powered off, network O2 becomes low level, and after being reversed by Q6, the CLR pin of U4 is pulled high, so that U4 exits reset and starts counting (delay). After counting to the set number of times, the QC pin of U4 outputs high level, which triggers U5 after being reversed by Q4, so that U5 outputs high level, and the MOS switch Q10 is turned on again to power on the barcode reader. The next cycle begins.
[0082] In any of the detection methods B1, B2 and B3, if the code reader fails to start, there will be no corresponding optical / electrical signal output, and the test circuit will not be powered off, so that the code reader remains in the current state. The signal O2 that controls the MOS switch is amplified by Q7 and Q5 and sent to the first digital display counter. The count value of the first digital display counter is equal to the number of successful power-on starts.
[0083] The cycle test circuit and the closed-loop test circuit board are provided with numerous 1nF capacitors and TVSs, wherein the 1nF capacitors are used to reduce line impedance and improve anti-interference capability, and the TVSs are used to protect the circuit from electrostatic damage.
[0084] The startup test circuit and method provided in this embodiment can identify whether the startup of the code reader is successful through various feedback signals of the code reader, and is compatible with various models of code readers of the company, and completely realizes the automatic test of the startup success rate of the code reader. The test process does not require manual intervention at all, which greatly saves labor costs and ensures the reliability of the test results. The test results are intuitively displayed through the LED digital tube, and the startup success rate can be directly calculated through the test data. When the test fails, the test can be paused to protect the site and provide technical personnel with the reason for the startup failure. In addition, the main circuit is implemented using a digital logic circuit, and the circuit is accurate and reliable. No software development is required, which saves development costs, avoids possible software bugs or hidden dangers of software running away, and improves stability. At the same time, the signal line is processed with low impedance to improve anti-interference performance and ensure long-term stable operation. All interfaces of the circuit are fully ESD protected to avoid damage caused by human operation and reduce the cost of later maintenance.
[0085] Obviously, the above embodiments are merely examples for the purpose of clear explanation and are not intended to limit the implementation methods. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the implementation methods here. The obvious changes or modifications derived therefrom are still within the scope of protection of the present invention.
Claims
1. A startup test circuit for a code reader, characterized in that: include: Loop test circuit, closed loop test circuit and test circuit switching module; The cyclic test circuit is used to generate a rectangular wave signal to drive the MOS switch to periodically power on and off the code reader and display the number of successful and failed startups of the code reader, including: A power on / off signal cycle generator, used to generate a rectangular wave signal, driving the MOS switch to close during a high level period to power on the code reader, and driving the MOS switch to open during a low level period to power off the code reader; The first digital display counter is used to obtain the number of startup times of the code reader by counting the number of times the code reader is powered on; The second digital display counter is used to obtain the number of successful startups of the code reader by counting the number of times the output port of the code reader outputs an electrical signal; The closed-loop test circuit is used to power on the code reader and detect whether the code reader is powered on successfully. If the power-on is unsuccessful, the current state is maintained to analyze the cause of the unsuccessful power-on. If the power-on is successful, the power is turned off and then powered on again after a preset delay time. The closed-loop test circuit includes: The RS trigger latch is used to output a high level when the closed-loop test circuit is started, closing the MOS switch to power on the code reader; The second photoresistor sampling circuit is used to detect the flashing signal of the operating indicator light of the code reader; A comparator, used for extracting and sending a flashing signal of the operation indicator light to a delay detection circuit; The delay detection circuit is used to detect whether the flashing signal of the operation indicator light reaches a preset number of times. If the preset number of times is reached, a signal to disconnect the MOS switch is output to the RS trigger latch to power off the code reader; The power-off delay circuit is used to output a signal of closing the MOS switch to the RS trigger latch after a preset delay when the code reader is powered off, so that the code reader is powered on; The test circuit switching module is used to switch and enable the loop test circuit or the closed-loop test circuit.
2. The startup test circuit according to claim 1, characterized in that: The cycle test circuit also includes: A first photoresistor sampling circuit, used to detect a built-in light source signal of the code reader; The comparison / amplification circuit is used to extract and send the built-in light source signal to the second digital display counter, so that the second digital display counter can obtain the number of successful startups of the code reader by counting the number of times the built-in light source signal is lit.
3. The startup test circuit according to claim 1, characterized in that: The second photoresistor sampling circuit is also used to detect the built-in light source signal of the code reader, so as to extract and send the built-in light source signal to the delay detection circuit through the comparator.
4. The startup test circuit according to claim 1, characterized in that: The delay detection circuit is also used to detect whether the built-in light source signal of the code reader reaches a preset time. If the built-in light source signal reaches the preset time, it outputs a signal to disconnect the MOS switch to the RS trigger latch to power off the code reader.
5. The startup test circuit according to claim 1, characterized in that: The delay detection circuit is also used to detect whether the output port of the code reader outputs an electrical signal. If the output port of the code reader outputs an electrical signal, it outputs a signal to disconnect the MOS switch to the RS trigger latch to power off the code reader.
6. A startup test method for a code reader, characterized in that: The startup test circuit according to any one of claims 1 to 5 comprises: Enable the loop test circuit or the closed-loop test circuit by switching the test circuit switching module; When the cyclic test circuit is enabled, the cyclic test circuit is used to generate a rectangular wave signal to drive the MOS switch, so that the code reader is periodically powered on and off, and the number of successful and failed startups of the code reader is displayed; When the closed-loop test circuit is enabled, the code reader is powered on using the closed-loop test circuit, and whether the code reader is powered on successfully is detected. If the code reader is not powered on successfully, the current state is maintained to analyze the reason why the code reader is not powered on successfully. If the code reader is powered on successfully, the power is turned off and delayed for a preset time before being powered on again.
7. The startup test method according to claim 6, characterized in that: When the cyclic test circuit is enabled, the cyclic test circuit is used to generate a rectangular wave signal to drive the MOS switch to periodically power on and off the code reader, and the number of successful and failed startups of the code reader is displayed, including: When the cycle test circuit is enabled, the power on / off signal cycle generator in the cycle test circuit is used to drive the MOS switch to close, so that the code reader is powered on and off, and the number of code reader power-on times counted by the first digital display counter and the number of code reader power-on successes counted by the second digital display counter are displayed, and the number of successful and failed startups of the code reader are displayed.
8. The startup test method according to claim 6, characterized in that: When the closed-loop test circuit is enabled, the code reader is powered on by the closed-loop test circuit, and whether the code reader is powered on successfully is detected. If the code reader is not powered on successfully, the current state is maintained to analyze the reason why the code reader is not powered on successfully. If the code reader is powered on successfully, the power is turned off and delayed for a preset time before being powered on again, including: When the closed-loop test circuit is enabled, the RS trigger latch in the closed-loop test circuit is used to power on the code reader, and the second photoresistor sampling circuit is used to detect whether the code reader is powered on successfully. If the code reader is not powered on successfully, the current state is maintained to analyze the reason why the code reader is not powered on successfully. If the code reader is powered on successfully, the power-off delay circuit is used to delay the preset time before powering on again.
Citation Information
Patent Citations
Auto powering on / off apparatus and method
CN101382570A
Method for testing starting reliability of equipment
CN102854423A