CN105487948A - RS232 port test apparatus and test method - Google Patents

RS232 port test apparatus and test method Download PDF

Info

Publication number
CN105487948A
CN105487948A CN201510828596.9A CN201510828596A CN105487948A CN 105487948 A CN105487948 A CN 105487948A CN 201510828596 A CN201510828596 A CN 201510828596A CN 105487948 A CN105487948 A CN 105487948A
Authority
CN
China
Prior art keywords
test
port
signal
tll
microcontroller
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.)
Pending
Application number
CN201510828596.9A
Other languages
Chinese (zh)
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.)
Shanghai Feixun Data Communication Technology Co Ltd
Original Assignee
Shanghai Feixun Data Communication Technology 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 Shanghai Feixun Data Communication Technology Co Ltd filed Critical Shanghai Feixun Data Communication Technology Co Ltd
Priority to CN201510828596.9A priority Critical patent/CN105487948A/en
Publication of CN105487948A publication Critical patent/CN105487948A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2205Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested
    • G06F11/221Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested to test buses, lines or interfaces, e.g. stuck-at or open line faults

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Test And Diagnosis Of Digital Computers (AREA)

Abstract

The invention provides an RS232 port test apparatus and a test method therefor. The test apparatus comprises a connector, a level conversion module and a microcontroller, wherein the connector is connected with an RS232 port of a to-be-tested device and used for transmitting a signal sent by the to-be-tested device; the level conversion module is connected with the connector and used for receiving the test signal sent by the to-be-tested device and converting the test signal into a TLL level signal; and the microcontroller is connected with the level conversion module and used for comparing the TLL level signal formed by conversion of the level conversion module with a TLL level signal forwarded by the to-be-tested device to obtain a comparison result. Through the RS232 port test apparatus and method, a device with an RS232 port does not need to be purchased to match with a test, so that the test cost is reduced; and in addition, the test apparatus can not only test whether a sending signal of the RS232 port is good or not but also test whether a received signal of the RS232 port is good or not.

Description

A kind of RS232 port testing device and method of testing
Technical field
The present invention relates to electronic technology field, particularly relate to a kind of RS232 port testing device and method of testing.
Background technology
RS232 is one of communication interface on personal computer, the standard for serial communication that Bell System, modulator-demodular unit producer and terminal manufacturer formulate jointly is combined by Electronic Industries Association (ElectronicIndustriesAssociation, EIA).Usual RS-232 interface occurs with 9 pins (DB-9) or the kenel of 25 pins (DB-25), and the RS-232 mouth of Industry Control generally only uses RXD, TXD, GND tri-lines.
Because RS-232 has low price, programming is easy and can uses longer wire than other interface, make it in such as monitoring and controlling system, obtain general application.In order to ensure that RS232 port quality is good, need test the RS232 port on electronic product before plant produced shipment.Common way directly uses the equipment with RS232 port to be directly plugged into RS232 port to be measured to test, such as the RS232 port on a printer is directly plugged on the RS232 port of host computer to be measured, print command is sent to printer by computer, normally work if print function, illustrate that the function of the RS232 port transmission signal of host computer to be measured is good.But existing method of testing utilizes the equipment with RS232 port to test, RS232 port can only be tested and whether well to send signal, its Received signal strength cannot be tested whether good.
Summary of the invention
In view of the above problems, the application describes a kind of RS232 port testing device, and described proving installation comprises:
Connector, is connected with the RS232 port of Devices to test, in order to transmit the signal that described Devices to test sends;
Level switch module, is connected with described connector, in order to receive the test signal that described Devices to test sends, and is converted to TLL level signal to described test signal;
Microcontroller, is connected with described level switch module, in order to contrast TLL level signal that described level switch module changes into and the TLL level signal that described Devices to test is forwarded back to carries out contrasting to obtain comparing result.
Preferably, described proving installation also comprises the display be connected with described microcontroller, in order to show described test signal and described comparing result.
Preferably, described connector is DB9 connector or RJ45 connector or USB connector.
Present invention also offers a kind of method of testing of RS232 port testing device, described method comprises step:
Devices to test sends test massage to described proving installation;
Described test signal is converted into TLL level signal by level switch module;
Described TLL level signal is transferred to described Devices to test by microcontroller;
Described Devices to test transfers to described microcontroller after receiving described TLL level signal;
Described microcontroller contrasts the TLL level signal of described level switch module conversion and the TLL level signal of described Devices to test forwarding, and whether both judgements are consistent;
If consistent, then judge that described RS232 port is normal; Otherwise, then judge that described RS232 port is abnormal.
Preferably, when described TLL level signal is transferred to described Devices to test by described microcontroller, display shows described TLL level signal.
Preferably, described microcontroller by comparing result display on the display.
Technique scheme tool has the following advantages or beneficial effect: in the present invention, by RS232 port testing device and method, has the equipment of RS232 port to coordinate test, reduce testing cost without the need to purchase.In addition, whether this proving installation not only can test the transmission signal of RS232 port can be good, and whether the Received signal strength can also testing RS232 port is good.Comparing result is shown by display, makes user directly can observe comparing result.
Accompanying drawing explanation
With reference to appended accompanying drawing, to describe embodiments of the invention more fully.But, appended accompanying drawing only for illustration of and elaboration, do not form limitation of the scope of the invention.
Fig. 1 is the structural representation of a kind of RS232 port testing device of the present invention;
Fig. 2 is the process flow diagram of the method for testing of a kind of RS232 port testing device of the present invention.
Embodiment
Below in conjunction with the drawings and specific embodiments, a kind of RS232 port testing device of the present invention and method of testing are described in detail.
Embodiment one
As shown in Figure 1, a kind of RS232 port testing device, comprising:
Connector, is connected with the RS232 port of Devices to test, in order to transmit the test signal that described RS232 port sends;
Level switch module, is connected with described connector, in order to receive the described test signal that described connector transmission comes, and is converted to TLL level signal to described test signal;
Microcontroller, is connected with described level switch module, and the TLL level signal be again forwarded back in order to the TLL level signal that converted to by level switch module and described Devices to test carries out contrasting to obtain comparing result;
Display, is connected with described microcontroller, in order to show described test signal and comparing result.
Specifically, although RS232 port definition nine pins, Tx, Rx and GND tri-signal wires just can meet most needs, described level switch module is level transferring chip.Therefore, in the present embodiment, the level signal Tx_232 that the RS232 that connector receives sends and Rx_232 is connected respectively to T1_out and the R1_in pin of level transferring chip MAX232, and level Tx_ttl and Rx_ttl being converted to TTL receives on RS232 pin corresponding to MCU by level transferring chip MAX232 respectively.Be worth pointing out time, described connector can be DB9, RJ45 or USB connector.
When testing, be connected by the RS232 port of Devices to test with connector, Devices to test sends test massage and is converted to TLL level through microcontroller, and is delivered in microcontroller by this TLL level.The test signal received is delivered in display and is shown by microcontroller.Then the test signal received is forwarded back to Devices to test by microcontroller again, and it is delivered in microcontroller by connector after receiving this test signal by Devices to test again.Microcontroller compares its test signal sent and the forward signal that again receives, both always, illustrate the RS232 port of Devices to test send and receiving function normal; Otherwise, then abnormal.Finally, comparing result is delivered on display.
In the present embodiment, by RS232 port testing device, there is the equipment of RS232 port to coordinate test without the need to purchase, reduce testing cost.In addition, whether this proving installation not only can test the transmission signal of RS232 port can be good, and whether the Received signal strength can also testing RS232 port is good.Comparing result is shown by display, makes user directly can observe comparing result.
Embodiment two
According to a kind of RS232 port testing device that above-described embodiment proposes, the present embodiment proposes a kind of method of testing of RS232 port testing device.
As shown in Figure 2, a kind of method of testing of RS232 port testing device, comprises step:
Devices to test sends test massage to described proving installation;
Described test signal is converted into TLL level signal by level switch module;
Described TLL level signal is transferred to described Devices to test and by this Signal aspects over the display by microcontroller;
Devices to test is forwarded to described microcontroller after receiving described TLL level signal;
Described microcontroller contrasts TLL level signal that described test signal changes into and the TLL level signal that Devices to test forwards, and whether both judgements are consistent;
If consistent, then judge that described RS232 port is normal;
If inconsistent, then judge that described RS232 port is abnormal.
Specifically, in the present embodiment, first Devices to test sends test massage to proving installation, and described test signal is converted into TLL level signal by the level switch module in proving installation.Then, described TLL level signal is transferred to described Devices to test and by this Signal aspects over the display, Devices to test is forwarded to described microcontroller after receiving described TLL level signal by microcontroller.Described microcontroller contrasts TLL level signal that described test signal changes into and the TLL level signal that Devices to test forwards, and whether both judgements are consistent.If consistent, then judge that described RS232 port is normal; Otherwise, then judge that described RS232 port is abnormal.Finally, microcontroller by comparing result display over the display.
For a person skilled in the art, after reading above-mentioned explanation, various changes and modifications undoubtedly will be apparent.Therefore, appending claims should regard the whole change and correction of containing true intention of the present invention and scope as.In Claims scope, the scope of any and all equivalences and content, all should think and still belong to the intent and scope of the invention.

Claims (6)

1. a RS232 port testing device, is characterized in that, comprising:
Connector, is connected with the RS232 port of Devices to test, in order to transmit the signal that described Devices to test sends;
Level switch module, is connected with described connector, in order to receive the test signal that described Devices to test sends, and is converted to TLL level signal to described test signal;
Microcontroller, is connected with described level switch module, in order to contrast TLL level signal that described level switch module changes into and the TLL level signal that described Devices to test is forwarded back to carries out contrasting to obtain comparing result.
2. RS232 port testing device according to claim 1, is characterized in that, described RS232 port testing device also comprises the display be connected with described microcontroller, in order to show described test signal and described comparing result.
3. RS232 port testing device according to claim 1, is characterized in that, described connector is DB9 connector or RJ45 connector or USB connector.
4. a method of testing for RS232 port testing device, is characterized in that, comprises step:
Devices to test sends test massage to described proving installation;
Described test signal is converted into TLL level signal by level switch module;
Described TLL level signal is transferred to described Devices to test by microcontroller;
Described Devices to test transfers to described microcontroller after receiving described TLL level signal;
The TLL level signal that described microcontroller transforms described level switch module and the TLL level signal that described Devices to test forwards contrast, and whether both judgements are consistent;
If consistent, then judge that described RS232 port is normal; Otherwise, then judge that described RS232 port is abnormal.
5. the method for testing of RS232 port testing device according to claim 4, is characterized in that, when described TLL level signal is transferred to described Devices to test by described microcontroller, display shows described TLL level signal.
6. the method for testing of RS232 port testing device according to claim 5, is characterized in that, described microcontroller by comparing result display on the display.
CN201510828596.9A 2015-11-24 2015-11-24 RS232 port test apparatus and test method Pending CN105487948A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510828596.9A CN105487948A (en) 2015-11-24 2015-11-24 RS232 port test apparatus and test method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510828596.9A CN105487948A (en) 2015-11-24 2015-11-24 RS232 port test apparatus and test method

Publications (1)

Publication Number Publication Date
CN105487948A true CN105487948A (en) 2016-04-13

Family

ID=55674941

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510828596.9A Pending CN105487948A (en) 2015-11-24 2015-11-24 RS232 port test apparatus and test method

Country Status (1)

Country Link
CN (1) CN105487948A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107086899A (en) * 2017-04-19 2017-08-22 东莞铭基电子科技集团有限公司 Serial ports intelligent test device and method of testing
CN109387766A (en) * 2017-08-08 2019-02-26 许继集团有限公司 Relay protection cpu motherboard method for testing performance and system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101140557A (en) * 2007-10-23 2008-03-12 中兴通讯股份有限公司 System and method of RS232/RS48 compatibility interface
CN102122260A (en) * 2010-01-08 2011-07-13 鸿富锦精密工业(深圳)有限公司 Test device and test method for universal serial bus (USB) port
CN102298550A (en) * 2010-06-23 2011-12-28 鸿富锦精密工业(深圳)有限公司 Test device for recommended standard 485 (RS 485) port

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101140557A (en) * 2007-10-23 2008-03-12 中兴通讯股份有限公司 System and method of RS232/RS48 compatibility interface
CN102122260A (en) * 2010-01-08 2011-07-13 鸿富锦精密工业(深圳)有限公司 Test device and test method for universal serial bus (USB) port
CN102298550A (en) * 2010-06-23 2011-12-28 鸿富锦精密工业(深圳)有限公司 Test device for recommended standard 485 (RS 485) port

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107086899A (en) * 2017-04-19 2017-08-22 东莞铭基电子科技集团有限公司 Serial ports intelligent test device and method of testing
CN107086899B (en) * 2017-04-19 2023-05-26 广东铭基高科电子股份有限公司 Intelligent serial port testing device and testing method
CN109387766A (en) * 2017-08-08 2019-02-26 许继集团有限公司 Relay protection cpu motherboard method for testing performance and system

Similar Documents

Publication Publication Date Title
CN103344863B (en) The method of testing of mobile terminal and test system
CN108111382B (en) Communication device based on I3C bus and communication method thereof
US7971110B2 (en) System and method for testing a serial attached small computer system interface
CN107105175B (en) A kind of interface circuit, signal transmission apparatus and method
CN102789073A (en) Testing method for MIPI liquid crystal screen
TWI440571B (en) Communication interface conversion device
CN104516798A (en) Wireless one-to-many test system
CN101499892A (en) Communication interface detection method and electronic device
CN112269120A (en) Interface signal loop test method and device, computer equipment and storage medium
CN105487948A (en) RS232 port test apparatus and test method
US8607101B2 (en) RS-485 port test apparatus
CN101692105B (en) Device for real-time detecting product of production line of remote control
CN101661419A (en) Testing equipment with multiple testing ports and testing method thereof
CN203722640U (en) Electric loopback light module
CN107086899B (en) Intelligent serial port testing device and testing method
CN106406154B (en) debugging system and control method thereof
CN208588479U (en) A kind of temperature sensor using single bus technology
TWI486595B (en) Wireless one-to-many testing system
CN108235005A (en) Utility function automatic test approach before television set manufacture
CN104243968A (en) Testing device and high-definition digital multimedia interface function testing method
CN104393934B (en) RS232 serial ports tests the bidirectional monitoring device of system
CN102739611A (en) Protocol analysis device and method
CN114579372A (en) Serial port testing method and system
CN111176922B (en) Docking station testing device, testing system and testing method
CN201514442U (en) Real-time detecting device of remote controller production line products

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
AD01 Patent right deemed abandoned

Effective date of abandoning: 20200124

AD01 Patent right deemed abandoned