1. Technical Field
Embodiments of the present disclosure relate generally to serial port testing, and more particularly, to a test device and method for testing serial ports of a computing device.
2. Description of Related Art
Most computing devices comprise one or more serial ports to connect with one or more peripherals. Each of the serial ports needs to be tested during the production of the computing devices. In a testing method of the serial ports, the serial ports are tested by connecting each of the serial ports to a terminal server. When one of the serial ports is tested, another one of the serial ports may be manually connected to the terminal server. This testing method is slow and inconvenient.
The disclosure, including the accompanying drawings, is illustrated by way of example and not by way of limitation. It should be noted that references to “an” or “one” embodiment in this disclosure are not necessarily to the same embodiment, and such references mean at least one.
The signal conversion unit 21 is connected to the USB interface 20, and connected to the serial port interfaces 25 through the multiplexer 24. During the process of testing the serial ports 11, the computing device 1 may send testing signals to the test device 2 for testing the serial ports 11. In one embodiment, the testing signals may include USB signals transmitted from the USB port 10, and serial signals transmitted from the serial ports 11. The signal conversion unit 21 is operable to convert the serial signals transmitted from the serial ports 11 into USB signals, or convert the USB signals transmitted from the USB port 10 into serial signals, so that testing signals can be transmitted between the USB port 10 and the serial ports 11.
The switch unit 22 is connected to the multiplexer 24. The switch unit 22 is operable to form a test channel between a serial port 11 and the USB port 10 by controlling the serial port 11 to communicate with the signal conversion unit 21 through the multiplexer 24. When the serial port 11 has been tested, the switch unit 22 is further operable to control the serial port 11 to connect to the output port 26 through the multiplexer 24, so that the computing device 1 can upload a testing result of the serial port 11 to the terminal server 3 through the output port 26.
The power management unit 23 is connected to the USB interface 20, the signal conversion unit 21, the switch unit 22, and the multiplexer 24. The power management unit 23 is operable to provide a voltage output from the USB interface 20 to the signal version unit 21, the switch unit 22, and the multiplexer 24.
In block S01, the switch unit 22 controls a serial port 11 to be tested to connect to the signal conversion unit 21, to form a test channel between the serial port 11 and the USB port 10.
In block S02, the computing device 1 sends a serial signal to the signal conversion unit 21 through the serial port 11, to test a signal sending function of the serial port 11.
In block S03, the signal conversion unit 21 converts the serial signal into a USB signal, and sends the converted USB signal to the computing device 1 through the USB port 10.
In block S04, the computing device 1 verifies the converted USB signal to determine whether the signal sending function of the serial port 11 is normal. In one embodiment, if the converted USB signal is identical to the sent serial signal according to the verification, the computing device 1 determines that the signal sending function of the serial port 11 is normal. Otherwise, if the USB signal is not identical to the sent serial signal according to the verification, the computing device 1 determines that the signal sending function of the serial port 11 is abnormal.
In block S05, the computing device 1 sends a USB signal to the signal conversion unit 21 through the USB port 10, to test a signal receiving function of the serial port 11.
In block S06, the signal conversion unit 21 converts the USB signal into a serial signal, and sends the converted serial signal to the computing device 1 through the serial port 11.
In block S07, the computing device 1 verifies the serial signal to determine whether the signal receiving function of the serial port 11 is normal. In one embodiment, if the converted serial signal is identical to the sent USB signal according to the verification, the computing device 1 determines that the signal receiving function of the serial port 11 is normal. Otherwise, if the serial signal is not identical to the sent USB signal according to the verification, the computing device 1 determines that the signal receiving function of the serial port 11 is abnormal.
In block S08, the switch unit 22 controls the serial port 11 to connect to the output port 26 through the multiplexer 24 when the signal sending and receiving function of the serial port 11 has been tested.
In block S09, the computing device 1 uploads test results of the serial port 11 to the terminal server 3 through the output port 26. In one embodiment, the block S01 to S09 may be repeated to test the other serial port 11 of the computing device 1.
Although certain embodiments of the present disclosure have been specifically described, the present disclosure is not to be construed as being limited thereto. Various changes or modifications may be made to the present disclosure without departing from the scope and spirit of the present disclosure.
Number | Date | Country | Kind |
---|---|---|---|
201110097296.X | Apr 2011 | CN | national |