Unlock instant, AI-driven research and patent intelligence for your innovation.

Method and device for detecting connection state of serial port, and communication system

A technology of connection state and detection method, which is applied in the field of communication, can solve problems such as the inability to realize the detection of serial port connection state

Inactive Publication Date: 2011-06-15
HUAWEI TECH CO LTD
View PDF3 Cites 11 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0006] Existing technology cannot realize the detection of serial port connection status

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and device for detecting connection state of serial port, and communication system
  • Method and device for detecting connection state of serial port, and communication system
  • Method and device for detecting connection state of serial port, and communication system

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0033] The embodiment of the present invention provides a serial port connection state detection and application method, including the following steps:

[0034] Detect whether the data output signal of the serial port at the opposite end is a valid signal corresponding to the normal connection of the serial port;

[0035] If yes, output a connection state valid signal; if not, output a connection state invalid signal.

[0036] The opposite end here can be a computer device such as a PC or a laptop connected to the embedded system. When these devices are connected to the embedded system, they will also perform level conversion through the RS232 level converter; at this time, the opposite end can be detected Whether the output signal is the valid signal corresponding to the normal connection of the serial port. Generally, the level range of RS232 is ±5V~±15V; and in practical applications, there will be two positive and negative levels with the same absolute value. For example,...

Embodiment 2

[0049] The embodiment of the present invention provides a serial port connection state detection method for monitoring the serial port connection state, see figure 2 , is a schematic diagram of a serial port connection state detection circuit corresponding to this embodiment.

[0050] like figure 2As shown, the PC is connected to the embedded system through the RS232 level converter; among them, the RS232 level converter is used to convert the level output by the serial port of the PC (generally using negative logic, voltage ±5V~±15V) into TTL level;

[0051] The signal Rx_232 represents the serial port data output signal of the PC, and after passing through the RS232 level converter, the Rx_TTL signal is output as the data input signal of the embedded system;

[0052] The signal Tx_TTL represents the serial port data output signal of the embedded system. After passing through the RS232 level converter, the Tx_232 signal is output as the data input signal of the PC.

[00...

Embodiment 3

[0068] In addition to the discrete component detection circuit used in the second embodiment, other detection circuits may also be used to detect the PC serial port data output signal Rx_232. see image 3 , the embodiment of the present invention provides a serial port connection state detection method, which is used for detecting the serial port connection state.

[0069] In the embodiment of the present invention, AD sampling is combined with logical judgment to detect the serial port connection state; wherein, the input terminal of AD sampling is Rx_232 signal, and the Rx_232 level is obtained through AD sampling; AD sampling can be through a dedicated AD sampling chip, Or you can also use a processor with AD sampling function;

[0070] After the level value is obtained through AD sampling, then logical judgment is made. For example, when the level value is ±5V, it is judged that the serial port is in the connected state; when the level value is 0V, it is judged that the s...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The embodiment of the invention discloses a method and a device for detecting a connection state of a serial port, and a communication system. The method for detecting the connection state of the serial port comprises the following steps of: detecting whether a data output signal of the serial port of an opposite end is a corresponding effective signal during the normal connection of the serial port; and if the data output signal of the serial port of the opposite end is the corresponding effective signal during the normal connection of the serial port, outputting a connection state effective signal; and if the data output signal of the serial port of the opposite end is not the corresponding effective signal during the normal connection of the serial port, outputting a connection state ineffective signal. Through the embodiment of the invention, the connection state of the serial port can be detected.

Description

technical field [0001] The invention relates to the technical field of communication, in particular to a serial port connection state detection and application method. Background technique [0002] RS232 (Recommended Standard 232, recommended standard 232) is a serial communication standard introduced by the Electronic Industries Association (EIA) in 1962. It defines electrical characteristics, data formats, connector specifications, etc., mainly Including: using unbalanced transmission mode, there are multiple standard rates to choose from, such as 9600, 19200, 38400, 115200, etc., and the maximum transmission distance is 15 meters; using character-oriented asynchronous communication mode, each data frame includes a start bit , data bits, optional parity bits, and stop bits; it adopts negative logic mode, that is, the level of logic 0 is 5V to 15V, and the level of logic 1 is -5V to -15V; both DB25 and DB9 are used Connectors, of which the latter are smaller in size, are v...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F11/26
Inventor 郑飞张盛彬
Owner HUAWEI TECH CO LTD