CN104104542A - Real-time intelligent debugging method based on RS485 - Google Patents

Real-time intelligent debugging method based on RS485 Download PDF

Info

Publication number
CN104104542A
CN104104542A CN201410339385.4A CN201410339385A CN104104542A CN 104104542 A CN104104542 A CN 104104542A CN 201410339385 A CN201410339385 A CN 201410339385A CN 104104542 A CN104104542 A CN 104104542A
Authority
CN
China
Prior art keywords
forbidding
communicating terminal
poll
fault
communication
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.)
Granted
Application number
CN201410339385.4A
Other languages
Chinese (zh)
Other versions
CN104104542B (en
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.)
SHENZHEN HIETECH ENERGY TECHNOLOGY Co Ltd
Original Assignee
SHENZHEN HIETECH ENERGY 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 SHENZHEN HIETECH ENERGY TECHNOLOGY Co Ltd filed Critical SHENZHEN HIETECH ENERGY TECHNOLOGY Co Ltd
Priority to CN201410339385.4A priority Critical patent/CN104104542B/en
Publication of CN104104542A publication Critical patent/CN104104542A/en
Application granted granted Critical
Publication of CN104104542B publication Critical patent/CN104104542B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Small-Scale Networks (AREA)
  • Maintenance And Management Of Digital Transmission (AREA)

Abstract

The invention provides a real-time intelligent debugging method based on RS485. The method includes the steps that (1) parameter information including the largest number of fault polling times and the longest forbidden time is configured on a communication device; (2) a communication signal is sent to an RS485 bus by means of the communication device to poll a connected RS485 communication terminal; (3) if the RS485 communication terminal cannot be communicated, a forbidden mechanism is started to test the connected RS485 communication terminal, and first, whether a forbidden identification exists on the communication terminal is judged. According to the method, a user can quickly and clearly find communication faults and detect fault points, communication efficiency can still be guaranteed after the faults occur, and according to the method, design is simple, processing speed is high, communication efficiency is high and the method is easy to use and popularize.

Description

A kind of real-time intelligent troubleshooting method based on RS485
Technical field
The present invention relates to communication technique field, relate in particular to a kind of real-time intelligent troubleshooting method based on RS485.
Background technology
RS485 bus is because of advantages such as it is simple in structure, with low cost, traffic rate is high, long transmission distance, at industrial control field, be widely applied, RS485 adopts half-duplex operation, its communication system generally by a host node, a plurality ofly from node, form, adopt host node poll from the communication mode of node.
The general use based on RS485 communication, system generally all by 1 or N bar bus form, every total tape 1 or N device, and due to the feature of RS485 poll, often in system, have 1 or a plurality of device there is communication failure, can cause the communication efficiency of whole system sharply to reduce.In communication because network delay or other reason, easily cause communication instruction carry out-unsuccessful, for ensureing the complete execution of instruction, generally all can adopt overtime retransmission technique, communication instruction is unsuccessful, can be again 1 or N (common is 3) is inferior re-starts transmission.And under retransmission mechanism, the communication efficiency that fault affects can be more remarkable.
Current, solve the efficiency that fault affects, be generally find Communication or gather after time delay, go to change failed equipment, when jockey is more, be difficult to the position of failure judgement device, the patent No. 200910056041.1 provides the automatic debugging method of a kind of RS485, can when system occurs, time delay investigate in turn the automatic decision setting position of makeing mistakes to bus connected device, this invention has only solved after finding that there is Communication, fast finding fault point.But the method can not solve the efficiency of not getting rid of the period in fault point, and can not allow user know fast communication failure, get rid of.
How to find a kind of quick clear and definite communication failure of user that can allow, even and have fault, between age at failure, also can ensure communication efficiency, be the technological difficulties that RS485 communication efficiency faces.
Summary of the invention
Inventive principle communication device sends communication signal through RS485 bus RS485 communicating terminal is carried out to poll, whether return data judges that whether RS485 communicating terminal is normal to observe RS485 communicating terminal, if RS485 communicating terminal is without return data, for RS485 communicating terminal arranges fault poll sign, while surpassing regulation fault wrap count (being generally 3 times) still without response data, point out RS485 communicating terminal to occur communication abnormality and identify and forbid timer for RS485 communicating terminal arranges forbidding, communication device once will not carry out poll to this RS485 communicating terminal during poll on initiating, thereby reduced the time delay that this RS485 communicating terminal is carried out to invalid poll generation, meanwhile, mailing address in conjunction with abnormal RS485 communicating terminal, energy is locating terminal position automatically, and report to the police on communication device, after the communication of RS485 communicating terminal is normal, can take artificial removal or system automatically to eliminate two kinds of modes and remove forbidding sign and fault poll sign, and removing forbidding timer and fault poll counter device, make communication device recover the poll to RS485 communicating terminal.
In order to solve problem in prior art, the invention provides a kind of real-time intelligent troubleshooting method based on RS485, comprise the following steps:
Step 1: configuration parameter information on communication device, parameter information is fault wrap count maximum, the longest forbidding time;
Step 2: utilize communication device to send communication signal to RS485 bus the RS485 communicating terminal connecting is carried out to poll;
Step 3: if RS485 communicating terminal cannot be communicated with, enable forbidding mechanism and test to connecting RS485 communicating terminal, first, judge on this communicating terminal and whether exist forbidding to identify:
If there is forbidding sign, represent that this communicating terminal is disabled, more whether judgement forbidding timer value is 0, be 0, attempt this communicating terminal to initiate a poll, judge whether this terminal called recovers normal, if still undesired, continue this communicating terminal of forbidding;
If there is not forbidding sign and communicating terminal, do not beam back data, this RS485 terminal is arranged to fault poll sign, and fault poll counter device is set to 0, if the fault wrap count maximum arranging is N, the most multipair communicating terminal carries out fault poll N time, each time after poll, fault poll counter device value will add 1, if communicating terminal does not all recover communication after N poll, depending on communicating terminal, there is communication failure, for this communicating terminal arranges forbidding sign and forbidding timer, meanwhile, display alarm information on communication device, forbidding timer is will again initiate communication malfunction terminal to carry out poll after 0.
As a further improvement on the present invention, the fault wrap count maximum N of setting is 2 to 4.
As a further improvement on the present invention, the fault wrap count maximum N of setting is 3.
As a further improvement on the present invention, forbidding timer is 8 to 12 minutes.
As a further improvement on the present invention, forbidding timer is 10 minutes.
The invention has the beneficial effects as follows:
The invention provides a kind of real-time intelligent troubleshooting method based on RS485, can detect in real time communication state, anomalous communication is pointed out and reported to the police, communication failure equipment is arranged to real-time forbidding sign, when poll, faulty equipment is skipped to communication, solve after fault, automatically failure identification is cancelled, automatically add communication.The method can allow the quick clear and definite communication failure of user, finds fault point, and also can ensure communication efficiency between age at failure, and its design is succinct, processes rapidly, and communication efficiency is high, is easy to promote and use.
Accompanying drawing explanation
Fig. 1 is system framework figure of the present invention;
Fig. 2 is workflow diagram of the present invention;
Fig. 3 is communication flow diagram of the present invention;
Fig. 4 is that machine-processed realization flow is forbidden in the present invention.
Embodiment
Below in conjunction with accompanying drawing, the present invention will be further described.
The present invention adopts following scheme to be achieved:
On communication device, configure the parameter informations such as fault wrap count maximum, the longest forbidding time.
Utilize communication device to send communication signal to RS485 bus the RS485 communicating terminal connecting is carried out to poll.If cannot being communicated with the forbidding mechanism of enabling, RS485 communicating terminal tests to connecting RS485 communicating terminal.First, whether judge on this communicating terminal exists forbidding to identify, if there is forbidding sign, represent that this communicating terminal is disabled, whether judgement forbidding timer value is 0 again, is that 0 trial is initiated a poll to this communicating terminal, judges whether this terminal called recovers normal, if still undesired, continue this communicating terminal of forbidding.
If there is not forbidding sign and communicating terminal, do not beam back data, this RS485 terminal is arranged to fault poll sign, and fault poll counter device is set to 0, if the fault wrap count maximum arranging is N (being generally made as 3 times), the most multipair communicating terminal carries out fault poll N time.Each time after poll, fault poll counter device value will add 1, if communicating terminal does not all recover communication after N poll, depending on communicating terminal, there is communication failure, for this communicating terminal arranges forbidding sign and forbidding timer (being generally 10 minutes), meanwhile, display alarm information on communication device.Forbidding timer is will again initiate communication malfunction terminal to carry out poll after 0.
1,2,3 further describe by reference to the accompanying drawings, method provided by the invention and implementation thereof are mainly as described below:
Under normal circumstances, each RS485 communicating terminal can be at returning real-time data after poll each time to communication device, if communicating terminal generation communication abnormality, the present invention uses following methods to carry out troubleshooting:
1, when communication device carries out RS485 communicating terminal after a poll, the data that can beam back RS485 communicating terminal are tested, and judge whether each RS485 communicating terminal beams back data.
If do not beam back data, enable successively forbidding mechanism and fault polling mechanism RS485 communicating terminal tested:
Forbidding mechanism: judge whether to identify for RS485 communicating terminal arranges forbidding, and minute following two kinds of situations are processed:
Forbidding sign has been set, has checked whether forbidding timer is 0, if 0, remove forbidding sign, and be maximum for this communicating terminal arranges fault poll sign and sets fault poll counter device value, then forward fault polling mechanism to.
Forbidding sign is not set, forwards fault polling mechanism to.
Fault polling mechanism: judge whether to identify for communicating terminal arranges fault poll, and minute following two kinds of situations are processed:
Fault poll sign has been set, and whether failure judgement poll counter device value surpasses the maximum of setting, if do not surpass maximum, the value of fault poll counter device is added to 1, then carry out subsequent operation,
If surpassed maximum, remove fault poll sign and fault poll counter device, and forbidding identifies and forbidding timer value is set to Configuration Values (being generally 10 minutes) for this RS485 communicating terminal arranges.
Fault poll sign is not set, and for this RS485 communicating terminal arranges fault poll sign, and fault poll counter device value is set to 0.
If beamed back data, check to have or not this RS485 communicating terminal is enabled to fault polling mechanism, if enable, destroy fault polling mechanism, and eliminate warning message.Communication device is by the poll recovering this communication terminal.
Above content is in conjunction with concrete preferred implementation further description made for the present invention, can not assert that specific embodiment of the invention is confined to these explanations.For general technical staff of the technical field of the invention, without departing from the inventive concept of the premise, can also make some simple deduction or replace, all should be considered as belonging to protection scope of the present invention.

Claims (5)

1. the real-time intelligent troubleshooting method based on RS485, is characterized in that:
Step 1: configuration parameter information on communication device, parameter information is fault wrap count maximum, the longest forbidding time;
Step 2: utilize communication device to send communication signal to RS485 bus the RS485 communicating terminal connecting is carried out to poll;
Step 3: if RS485 communicating terminal cannot be communicated with, enable forbidding mechanism and test to connecting RS485 communicating terminal, first, judge on this communicating terminal and whether exist forbidding to identify:
If there is forbidding sign, represent that this communicating terminal is disabled, more whether judgement forbidding timer value is 0, be 0, attempt this communicating terminal to initiate a poll, judge whether this terminal called recovers normal, if still undesired, continue this communicating terminal of forbidding;
If there is not forbidding sign and communicating terminal, do not beam back data, this RS485 terminal is arranged to fault poll sign, and fault poll counter device is set to 0, if the fault wrap count maximum arranging is N, the most multipair communicating terminal carries out fault poll N time, each time after poll, fault poll counter device value will add 1, if communicating terminal does not all recover communication after N poll, depending on communicating terminal, there is communication failure, for this communicating terminal arranges forbidding sign and forbidding timer, meanwhile, display alarm information on communication device, forbidding timer is will again initiate communication malfunction terminal to carry out poll after 0.
2. a kind of real-time intelligent troubleshooting method based on RS485 according to claim 1, is characterized in that: the fault wrap count maximum N of setting is 2 to 4.
3. a kind of real-time intelligent troubleshooting method based on RS485 according to claim 2, is characterized in that: the fault wrap count maximum N of setting is 3.
4. a kind of real-time intelligent troubleshooting method based on RS485 according to claim 1, is characterized in that: forbidding timer is 8 to 12 minutes.
5. a kind of real-time intelligent troubleshooting method based on RS485 according to claim 4, is characterized in that: forbidding timer is 10 minutes.
CN201410339385.4A 2014-07-16 2014-07-16 RS 485-based real-time intelligent obstacle removing method Active CN104104542B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410339385.4A CN104104542B (en) 2014-07-16 2014-07-16 RS 485-based real-time intelligent obstacle removing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410339385.4A CN104104542B (en) 2014-07-16 2014-07-16 RS 485-based real-time intelligent obstacle removing method

Publications (2)

Publication Number Publication Date
CN104104542A true CN104104542A (en) 2014-10-15
CN104104542B CN104104542B (en) 2017-11-03

Family

ID=51672363

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410339385.4A Active CN104104542B (en) 2014-07-16 2014-07-16 RS 485-based real-time intelligent obstacle removing method

Country Status (1)

Country Link
CN (1) CN104104542B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105007197A (en) * 2015-07-29 2015-10-28 南车株洲电力机车研究所有限公司 Method and device for monitoring communication state of MVB bus
CN106411655A (en) * 2016-11-04 2017-02-15 合肥工业大学 Communication processing method based on state diagnosis of serial communication equipment
CN107517533A (en) * 2017-08-11 2017-12-26 四川华体照明科技股份有限公司 A kind of self-adapting type street lamp loop ownership rapid detection system and method based on NB IoT
CN109088753A (en) * 2018-07-27 2018-12-25 江苏航天大为科技股份有限公司 The circuit and method of automatic detection RS485 communication failure
CN111287442A (en) * 2020-01-20 2020-06-16 北京韬盛科技发展有限公司 Intelligent communication fault warning system and method for climbing frame
CN111464372A (en) * 2019-01-18 2020-07-28 广东天创同工大数据应用有限公司 Method for improving communication refreshing speed

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101056202A (en) * 2007-05-31 2007-10-17 武汉虹信通信技术有限责任公司 A method for realizing the multi-task polling in the network management monitoring system
CN101989932A (en) * 2009-08-07 2011-03-23 巨尔(上海)光电照明有限公司 RS485-based automatic error detection method
CN102692912A (en) * 2012-06-11 2012-09-26 成都瑞特数字科技有限责任公司 Onsite-level low-cost redundancy measuring and controlling network based on wired and wireless hot spare redundancy communication
CA2787867A1 (en) * 2011-07-14 2013-01-14 Southwest Electronic Energy Corporation Short detection in battery cells
CN103023715A (en) * 2012-11-23 2013-04-03 北京广利核***工程有限公司 Fault monitoring method based on RS485 bus communication link
CN103095509A (en) * 2011-10-27 2013-05-08 贵州英特利智能控制工程研究有限责任公司 Method for quickly testing recommended standard 485 (RS485) bus breakdown

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101056202A (en) * 2007-05-31 2007-10-17 武汉虹信通信技术有限责任公司 A method for realizing the multi-task polling in the network management monitoring system
CN101989932A (en) * 2009-08-07 2011-03-23 巨尔(上海)光电照明有限公司 RS485-based automatic error detection method
CA2787867A1 (en) * 2011-07-14 2013-01-14 Southwest Electronic Energy Corporation Short detection in battery cells
CN103095509A (en) * 2011-10-27 2013-05-08 贵州英特利智能控制工程研究有限责任公司 Method for quickly testing recommended standard 485 (RS485) bus breakdown
CN102692912A (en) * 2012-06-11 2012-09-26 成都瑞特数字科技有限责任公司 Onsite-level low-cost redundancy measuring and controlling network based on wired and wireless hot spare redundancy communication
CN103023715A (en) * 2012-11-23 2013-04-03 北京广利核***工程有限公司 Fault monitoring method based on RS485 bus communication link

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105007197A (en) * 2015-07-29 2015-10-28 南车株洲电力机车研究所有限公司 Method and device for monitoring communication state of MVB bus
CN106411655A (en) * 2016-11-04 2017-02-15 合肥工业大学 Communication processing method based on state diagnosis of serial communication equipment
CN106411655B (en) * 2016-11-04 2019-08-02 合肥工业大学 Communication processing method based on the diagnosis of serial communication equipment state
CN107517533A (en) * 2017-08-11 2017-12-26 四川华体照明科技股份有限公司 A kind of self-adapting type street lamp loop ownership rapid detection system and method based on NB IoT
CN109088753A (en) * 2018-07-27 2018-12-25 江苏航天大为科技股份有限公司 The circuit and method of automatic detection RS485 communication failure
CN111464372A (en) * 2019-01-18 2020-07-28 广东天创同工大数据应用有限公司 Method for improving communication refreshing speed
CN111464372B (en) * 2019-01-18 2021-09-24 广东天创同工大数据应用有限公司 Method for improving communication refreshing speed
CN111287442A (en) * 2020-01-20 2020-06-16 北京韬盛科技发展有限公司 Intelligent communication fault warning system and method for climbing frame

Also Published As

Publication number Publication date
CN104104542B (en) 2017-11-03

Similar Documents

Publication Publication Date Title
CN104104542A (en) Real-time intelligent debugging method based on RS485
CN104440923B (en) A kind of emergent stop signal control system for robot and robot thereof
CN111224818B (en) Road side unit alarming method and device, electronic equipment and storage medium
CN108429629A (en) Equipment fault restoration methods and device
CN104518914B (en) Link switch-over method and equipment
CN203269252U (en) Automatic timed detecting device of elevator blackout emergency power source
CN103227662A (en) Safety detection method and system of electric power communication equipment based on state control
CN110794805A (en) Robot safety circuit and control method thereof
CN102752145A (en) Novel detecting and isolating system for fault of RS-485 port and method thereof
CN104283718A (en) Network device and hardware fault diagnosis method used for network device
CN103188113A (en) Failure processing method of communication equipment
CN106532690B (en) A kind of substation secondary device state is checked online and intelligent diagnosing method
CN202735418U (en) Power quality monitoring system
CN103997126B (en) A kind of fault diagnosis stage division based on on-off state and system
CN104590584B (en) Satellite is embedded test system in-orbit
CN107342789A (en) A kind of group-net communication method of cable anti-theft monitoring system
CN103761157A (en) Method for implementing system fault-tolerant mechanism on basis of multitask patrol strategy
CN106559247A (en) Alarm management method and NMS in NMS
CN106199369B (en) A kind of method and system of OR-ing MOSFET On-line Fault Detections
CN104007758A (en) Self-diagnosis method and system for gateway communication abnormity in distributed control system of nuclear power plant
CN110932391B (en) Method and system for identifying tripping of feeder switch in station
CN103812744A (en) Bidirectional double-loop alarm communication control system based on RS-422 bus structure
CN109067567B (en) Network communication interruption diagnosis method
WO2014040470A1 (en) Alarm message processing method and device
CN104237782A (en) Starting relay durability system with safety protection and fault reminding functions and test method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant