Patent Abstract:
A printer interface detection device includes a printer interface connected to a printer interface of a computer to be detected, a microcontroller, and an indicator. The printer interface includes a number of input/output (I/O) pins and a data signal pin connected to the corresponding pins of the microcontroller. The microcontroller outputs a plurality of printing status signals to the computer according to instructions from the computer. The computer compares whether the number of printing statuses are consistent with printing statuses stored in the computer, to determine whether a printing function of the printer interface of the computer is normal. When the printing function of the printer interface of the computer is normal, the indicator is lit.

Full Description:
BACKGROUND 
       [0001]    1. Technical Field 
         [0002]    The present disclosure relates to detection devices, and particularly to a printer interface detection device. 
         [0003]    2. Description of Related Art 
         [0004]    Nowadays, as more databases and computer networks are interconnected, distributed multiple data systems and destinations are used to store information. Proper functioning of the printer interface of a computer becomes very important in such distributed resources. Generally, when a printer interface of a computer is tested for its functionality, a corresponding printer needs to be connected, which is inconvenient in a distributed arrangement. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0005]      FIG. 1  is a schematic, isometric view of one embodiment of a printer interface detection device. 
           [0006]      FIG. 2  is a schematic, isometric view of the printer interface detection device of  FIG. 1  detecting a computer. 
           [0007]      FIG. 3  is a circuit diagram of the printer interface detection device of  FIG. 1 . 
       
    
    
     DETAILED DESCRIPTION 
       [0008]    Referring to  FIGS. 1-3 , an exemplary embodiment of a printer interface detection device  100  is used to simulate a printer to determine whether a printing function of a printer interface  32  of a computer  30  to be detected is normal. The printer interface detection device  100  includes a shell  1 , a printer interface  5  mounted on the shell  1 , a detection circuit  10  received in the shell  1 , two switches K 1  and K 2  mounted on the shell  1 , and first to third light emitting diodes (LEDs) D 1 -D 3  mounted on the shell  1 . The two switches K 1  and K 2 , and the first to third LEDs D 1 -D 3  are connected to the detection circuit  10 . The first LED D 1 , displays a power status of the printer interface detection device  100 . The second LED D 2 , displays a printing status of the printer interface detection device  100 . The third LED D 3 , displays a detection result of the printer interface detection device  100 , to allow determination of whether a printing function of the printer interface  32  of the computer  30  is normal. 
         [0009]    The printer interface  5  is connects to the printer interface  32  of the computer  30 . 
         [0010]    The printer interface  5  of the printer interface detection device  100  includes an initialization signal pin NIT, an acknowledgement signal pin ACK, a busy signal pin BUSY, a data signal pin DATA, and a strobe signal pin STROBE, corresponding to an initialization signal pin, an acknowledgement signal pin, a busy signal pin, a data signal pin, and a strobe signal pin of the printer interface  32  of the computer  30  respectively. 
         [0011]    The detection circuit  10  includes a microcontroller  12 , resistors R 1 -R 4 , capacitors C 1 -C 3 , a crystal oscillator J, and a power source Vcc. The microcontroller  12  includes a reset pin RET, a power pin VCC, a ground pin GND, a plurality of input/output (I/O) pins P 1 . 0 , P 1 . 1 , P 1 . 2 , P 1 . 3 , P 1 . 6 , P 3 . 4 , and P 3 . 5 , an external crystal input pin XTAL 1 , and an external crystal output pin XTAL 2 . The reset pin RET of the microcontroller  12  is connected to a cathode of the capacitor C 1 , and is grounded via the resistor R 1 . An anode of the capacitor C 1  is connected to the power source Vcc. The switch K 1  is connected to the capacitor C 1  in parallel, to reset the microcontroller  12 . The power pin of the microcontroller  12  is connected to an anode of the first LED D 1 , and connected to the power source Vcc via the switch K 2 , to start the detection circuit  10 . A cathode of the first LED D 1  is grounded via the resistor R 2 . The I/O pin P 1 . 6  of the microcontroller  12  is connected to the initialization signal pin INIT of the printer interface  5 . The I/O pin P 1 . 3  of the microcontroller  12  is connected to the acknowledgement signal pin ACK of the printer interface  5 . The I/O pin P 1 . 2  of the microcontroller  12  is connected to the busy signal pin BUSY of the printer interface  5 . The I/O pin P 1 . 1  of the microcontroller  12  is connected to the strobe signal pin STROBE of the printer interface  5 . The I/O pin P 1 . 0  of the microcontroller  12  is connected to the data signal pin DATA of the printer interface  5 . The I/O pin P 3 . 4  of the microcontroller  12  is connected to an anode of the third LED D 3 . A cathode of the third LED D 3  is grounded via the resistor R 3 . The I/O pin P 3 . 5  of the microcontroller  12  is connected to an anode of the second LED D 2 . A cathode of the second LED D 2  is grounded via the resistor R 4 . The crystal oscillator J is connected between the external crystal input pin XTAL 1  and the external crystal output pin XTAL 2 . The external crystal input pin XTAL 1  is grounded via the capacitor C 2 . The external crystal output pin XTAL 2  is grounded via the capacitor C 3 . The crystal oscillator J, the capacitor C 2 , and the capacitor C 3  form a clock circuit. The ground pin GND is grounded. The initialization signal pin INIT, the acknowledgement signal pin ACK, the busy signal pin BUSY, and the strobe signal pin STROBE of the printer interface  5  can be triggered at a low level. 
         [0012]    In use, the printer interface  5  of the printer interface detection device  100  is connected to the printer interface  32  of the computer  30 . The switch K 2  is turned on to initialize the detection circuit  10 . When the computer  30  identifies the printer interface detection device  100 , the computer  30  transmits a printing demand instruction to the printer interface detection device  100  via the data signal pin DATA. The microcontroller  12  receives the printing demand instruction, and directs the I/O pin P 1 . 1  to output a low level signal, as a first printing status signal, to the computer  30  via the strobe signal pin STROBE of the printer interface  5 , to notify the computer  30  that the printer interface detection device  100  is awaiting print data. The computer  30  transmits print data to the microcontroller  12  via the data signal pin DATA of the printer interface  5 . When the I/O pin P 1 . 0  of the microcontroller  12  receives the print data, the microcontroller  12  directs the I/O pin P 3 . 5  to output a high level signal to turn on the second LED D 2  to denote that the printer interface detection device  100  has started receiving the print data, and directs the I/O pin P 1 . 3  to output a low level signal, as a second printing status signal, to the computer  30  to notify the computer  30  that the printer interface detection device  100  has started receiving the print data. The microcontroller  12  directs the I/O pin P 1 . 2  to output a low level signal, as a third printing status signal, to the computer  30  via the busy signal pin ACK of the printer interface  5  after finishing receiving the print data, to notify the computer  30  that the printer interface detection device  100  has successfully received all print data and start printing. 
         [0013]    When the printer interface detection device  100  has finished printing, the microcontroller  12  directs the I/O pin P 1 . 6  to output a low level signal, as a fourth printing status signal, to the computer  30  via the initialization signal pin NIT of the printer interface  5 , to notify the computer  30  that the printer interface detection device  100  has finished printing. The microcontroller  12  directs the I/O pin P 3 . 5  to output a low level signal to turn off the second LED D 2  to indicate that the printer interface detection device  100  has finished printing. The computer  30  determines whether the first to fourth printing statuses of the printer interface detection device  100  are consistent with printing statuses stored in the computer  30 . If so, the detection is successful and the computer  30  transmits an instruction to the microcontroller  12  via the data signal pin DATA of the printer interface  5 . The microcontroller  12  directs the I/O pin P 3 . 4  to output a high level signal to turn on the third LED D 3  to denote that the detection is successful and the printing function of the printer interface  32  of the computer  30  is normal. If the first to fourth printing statuses of the printer interface detection device  100  are not consistent with printing statuses stored in the computer  30 , the third LED D 3  remains unlit, denoting that the detection has failed and the printing function of the printer interface  32  of the computer  30  is abnormal. 
         [0014]    It is to be understood, however, that even though numerous characteristics and advantages of the embodiments have been set forth in the foregoing description, together with details of the structure and function of the embodiments, the disclosure is illustrative only, and changes may be made in details, especially in matters of shape, size, and arrangement of parts within the principles of the embodiments to the full extent indicated by the broad general meaning of the terms in which the appended claims are expressed.

Technology Classification (CPC): 6