CN104331062A - Test method for grinder controller serial port - Google Patents
Test method for grinder controller serial port Download PDFInfo
- Publication number
- CN104331062A CN104331062A CN201410521711.3A CN201410521711A CN104331062A CN 104331062 A CN104331062 A CN 104331062A CN 201410521711 A CN201410521711 A CN 201410521711A CN 104331062 A CN104331062 A CN 104331062A
- Authority
- CN
- China
- Prior art keywords
- serial ports
- controller
- serial
- data
- muller
- 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.)
- Withdrawn
Links
Classifications
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B19/00—Programme-control systems
- G05B19/02—Programme-control systems electric
- G05B19/04—Programme control other than numerical control, i.e. in sequence controllers or logic controllers
- G05B19/042—Programme control other than numerical control, i.e. in sequence controllers or logic controllers using digital processors
- G05B19/0423—Input/output
- G05B19/0425—Safety, monitoring
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B2219/00—Program-control systems
- G05B2219/20—Pc systems
- G05B2219/25—Pc structure of the system
- G05B2219/25153—Checking communication
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B2219/00—Program-control systems
- G05B2219/20—Pc systems
- G05B2219/25—Pc structure of the system
- G05B2219/25157—Checksum CRC
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B2219/00—Program-control systems
- G05B2219/20—Pc systems
- G05B2219/25—Pc structure of the system
- G05B2219/25176—RS485, differential data signals, xor
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Automation & Control Theory (AREA)
- Debugging And Monitoring (AREA)
- Tests Of Electronic Circuits (AREA)
Abstract
The invention discloses a test method for a grinder controller serial port. The method comprises the steps that communication connectivity of an RS232 serial port and an RS485 serial port is tested and a fault type is detected via a serial port debugging assistant interface, and an error message can be rapidly acquired via direct observation so that operation is simple, work efficiency is effectively enhanced and fault elimination and repair time is saved. Meanwhile, check bit data are calculated via a CRC checksum mode so that calculation amount of the mode is small, time is saved, accuracy of calculation is high, and test accuracy is effectively guaranteed.
Description
Technical field
The invention belongs to electronic apparatus application field, be specifically related to a kind of method of testing of muller controller serial ports.
Background technology
Twin grinder is mainly used in the parallel crystal in two sides or other mechanical component carry out twin grinding, particularly the processing of thin hard brittle material.Be applicable to plane lapping and the polishing of the metal material such as the mechanical seal ring of various material, potsherd, cylinder piston ring, oil pump blade bearing end face and silicon, germanium, quartz crystal, graphite, sapphire, optics crystal, glass, lithium niobate, wimet, stainless steel, powder ash metallurgy.
A kind of serial ports method of testing of the patent of invention that Yanxiang Intelligent Technology Co., Ltd applies on Dec 20th, 2012, system and device, application number is 201210558964.9, publication date is on June 25th, 2014, wherein, described method comprises: from serial ports to be measured, select communication serial port, and carries out serial ports test to described communication serial port; Obtain serial ports test instruction, switch the serial ports pattern of serial ports to be measured according to described serial ports test instruction, with described serial ports pattern, described serial ports to be measured is tested, record the test result of described test.Above-mentioned serial ports method of testing, system and device, by obtaining serial ports test instruction, the serial ports pattern of serial ports to be measured is switched according to serial ports test instruction, with this serial ports pattern, serial ports to be measured is tested, the test result of record test, can carry out serial ports test respectively according to the automatically switch pattern of serial ports to be measured of serial ports test instruction, and test result is carried out record, decrease manual operation, improve serial ports testing efficiency.
Application number is 201210273320.5, and the applying date is that the inventive embodiments of application on 08 02nd, 2012 discloses a kind of simulative serial port method of testing and device, and wherein method comprises: receive the Modem commands language AT instruction that client sends; Read and resolve each test data file prestored, obtaining the test instruction in test data file; Confirm that whether described test instruction is the result coded message URC instruction of active reporting, if, then described URC instruction is sent to described client, if not, then confirm whether described AT instruction is included in the test instruction in described test data file, if comprise, then the response contents of the test instruction corresponding with described AT instruction is sent to described client, otherwise send the expression information that the match is successful to described client.Above scheme adopts the exploitation of client can be debugged in time on stream with debugging, thus improves whole development progress.
Above-mentioned serial ports test is all from the communications field, to the scheme that the serial ports of routine application is tested, these serial ports method of testings can be used in some conventional application, at the control field of twin grinder, also often need to apply dissimilar serial ports, and above-mentioned serial ports method of testing and device be not suitable for the test of this kind of type specialized equipment, and in this specialized equipment application, neither one tests method or the equipment of serial ports specially, research staff can only be leaned on rule of thumb to detect, this inspection comprehensively can not check out the problem of serial ports, potential problem may be there is.Therefore, a kind of serial ports method of testing rapidly and efficiently or system is needed at twin grinder control field.
Summary of the invention
Technical matters to be solved by this invention is: the method for testing providing a kind of muller controller serial ports, solves the problem not having high-speed serial ports method of testing or system in prior art at muller specialized equipment control field.
The present invention is for solving the problems of the technologies described above by the following technical solutions:
A kind of serial ports method of testing of muller controller, described muller controller comprises control enclosure, power interface, input port, output port, State Transferring button, status indicator lamp, serial ports, AD port, described input port, output port, State Transferring button, status indicator lamp, serial ports, AD port are from left to right set in turn on the front panel of control enclosure, described power interface is arranged at the side of control enclosure, described serial ports comprises RS232 serial ports and RS485 serial ports
The method of testing of described RS232 serial ports comprises the steps:
Step 1, the RS232 serial ports of muller controller to be connected with operating terminal, to open the power supply of controller;
Step 2, operating terminal is opened download program terminal and download parameters is set, program writing operation is carried out to the central processing unit of controller, whether the download state on determining program download terminal completes, if completed, RS232 serial communication completes, otherwise, eject dialog box prompting, judge the fault type of RS232 serial communication according to dialog box information;
The method of testing of described RS485 serial ports comprises the steps:
Steps A, the RS232 serial ports of muller controller to be connected with operating terminal, RS485 serial ports to be connected with operating terminal by after RS232-RS485 converter, to open the power supply of controller;
Step B, on operating terminal, open COM Debug Assistant, RS485 serial ports parameter is set, sends serial data by COM Debug Assistant to RS485, read the data of RS485 feedback;
Step C, judge that whether data that RS485 feeds back are the serial data of 8, if so, perform step D, otherwise, check Serial Port Line annexation or more changer controller, return execution steps A;
Step D, judge that whether last two of 8 bit data strings are the summation of front 6 bit data, if so, RS485 serial communication is correct, otherwise, perform step e;
The data type of step e, position that front 6 bit data obtained in 8 bit data strings are not identical with the data defined in communication protocol, after mark, more changer controller returns execution steps A.
Described RS232 serial ports is connected with the Serial Port Line all having a DB9 joint by two ends between operating terminal.
Described State Transferring button comprises two buttons of left and right setting, in described step 2 to the central processing unit of controller carry out program writing operation detailed process as follows:
First press right state switching button, then press left state switching button, then unclamp right state switching button and left state switching button successively, enter programming state, finally press the program button in download program terminal, program starts to download.
In described step B, RS485 serial ports parameter is respectively: 16 system digital displays show, baud rate selects 9600, even effect position.
Everybody in described step C in the serial data of 8 is defined as a head pointer position, position, two test addresses, two data qualifier bits, a data readings position, two check bit successively.
The data of described two check bit by CRC check and mode obtain.
Compared with prior art, the present invention has following beneficial effect:
1, the method is by COM Debug Assistant interface detection RS232 serial ports and the communication connectivity of RS485 serial ports and the detection of fault type, direct observation gets final product quick obtaining error message, simple to operate, effectively improve work efficiency, save the time that fault is discharged and repaired.
2, by CRC check and mode calculation check bit data, this mode calculated amount is little, saves time, and meanwhile, the accuracy of calculating is high, effectively ensure that the accuracy rate of test.
Accompanying drawing explanation
Fig. 1 is signal wiring block diagram of the present invention.
Fig. 2 is the contour structures block diagram of muller controller of the present invention.
Fig. 3 is the form block diagram that RS485 serial ports feeds back 8 bit data strings.
Wherein, being designated in figure: 1-power interface; 2-State Transferring button; 3-first input end mouth; 4-second input port; 5-first output port; 6-second output port; 7-RS485 port; 8-status indicator lamp; 9-RS232 port; 10-AD port.
Embodiment
Below in conjunction with accompanying drawing, structure of the present invention and the course of work are described further.
The present embodiment for the central processing unit of controller for MSC1210 is described.
As Fig. 1, shown in Fig. 2, a kind of serial ports method of testing of muller controller, described muller controller comprises control enclosure, power interface 1, input port, output port, State Transferring button 2, status indicator lamp 8, serial ports, AD port one 0, described input port, output port, State Transferring button 2, status indicator lamp 8, serial ports, AD port one 0 is from left to right set in turn on the front panel of control enclosure, described power interface 1 is arranged at the side of control enclosure, described serial ports comprises RS232 serial ports 9 and RS485 serial ports 7, described input port comprises first input end mouth 3, second input port 4, described output port comprises the first output port 5, second output port 6, State Transferring button 2 comprises two buttons that left and right is arranged, status indicator lamp 8 comprises the different LED of four colors, various status informations in described status indicator lamp indicating control operational process, and the status information in programming process.
The method of testing of described RS232 serial ports comprises the steps:
Step 1, the RS232 serial ports of muller controller to be connected with operating terminal, to open the power supply of controller;
Step 2, operating terminal is opened download program terminal and download parameters is set, program writing operation is carried out to the central processing unit of controller, whether the download state on determining program download terminal completes, if completed, RS232 serial communication completes, otherwise, eject dialog box prompting, judge the fault type of RS232 serial communication according to dialog box information;
The method of testing of described RS485 serial ports comprises the steps:
Steps A, the RS232 serial ports of muller controller to be connected with operating terminal, RS485 serial ports to be connected with operating terminal by after RS232-RS485 converter, to open the power supply of controller;
Step B, on operating terminal, open COM Debug Assistant, RS485 serial ports parameter is set, sends serial data by COM Debug Assistant to RS485, read the data of RS485 feedback;
Step C, judge that whether data that RS485 feeds back are the serial data of 8, if so, perform step D, otherwise, check Serial Port Line annexation or more changer controller, return execution steps A;
Step D, judge that whether last two of 8 bit data strings are the summation of front 6 bit data, if so, RS485 serial communication is correct, otherwise, perform step e;
The data type of step e, position that front 6 bit data obtained in 8 bit data strings are not identical with the data defined in communication protocol, after mark, more changer controller returns execution steps A.
Described RS232 serial ports is connected with the Serial Port Line all having a DB9 joint by two ends between operating terminal.
Described State Transferring button comprises two of left and right setting, in described step 2 to the central processing unit of controller carry out program writing operation detailed process as follows:
First press right state switching button, then press left state switching button, then unclamp right state switching button and left state switching button successively, enter programming state, finally press the program button in download program terminal, program starts to download.
In described step B, RS485 serial ports parameter is respectively: 16 system digital displays show, baud rate selects 9600, even effect position.
Everybody in described step C in the serial data of 8 is defined as a head pointer position, position, two test addresses, two data qualifier bits, a data readings position, two check bit successively.
The data of described two check bit by CRC check and mode obtain.
RS485 serial ports feedback 8 bit data form block diagram as shown in Figure 3,
Wherein Idle is free time, and SD2 is head pointer, and ADR is test address, and TYP is data type, and PDU is data readings, and BCC is check bit.
Such as: 02 04 85 00 02 00 00 13 88 1A,
02 03 85 00 02 00 00 13 88 1D,
02 01 85 00 02 00 00 13 88 1F,
02 02 85 00 02 00 00 13 88 1C,
If reading is above class likelihood data, then illustrate that MAX485 port is normal.
The fault often occurred for RS232 serial ports is as follows:
1, contrast controller principle figure, check whether port has the place of rosin joint mistake weldering and corrected.
2, measure RS232 chip pin voltage with multimeter and whether have exception.
3, check whether K11.0592MHZ crystal shakes.
If more than 4 phenomenon all without exception but cannot write journey, reading, change MSC1210 chip, fault just can be got rid of.
The fault that RS485 serial ports often occurs is as follows:
The subject matter of RS485 is generally error in reading or not reading etc., please look into see if there is relevant vigour part damage, short circuit, open circuit situation and deal with problems.
The method is by COM Debug Assistant interface detection RS232 serial ports and the communication connectivity of RS485 serial ports and the detection of fault type, direct observation gets final product quick obtaining error message, simple to operate, effectively improve work efficiency, save the time that fault is discharged and repaired.
By CRC check and mode calculation check bit data, this mode calculated amount is little, saves time, and meanwhile, the accuracy of calculating is high, effectively ensure that the accuracy rate of test.
The above embodiment of the present invention is only for example of the present invention is clearly described, and is not the restriction to embodiments of the present invention.For those of ordinary skill in the field, can also make other changes in different forms on the basis of the above description.Here exhaustive without the need to also giving all embodiments.And these belong to connotation of the present invention the apparent change of extending out or variation still belong to protection scope of the present invention.
Claims (6)
1. the method for testing of a muller controller serial ports, described muller controller comprises control enclosure, power interface, input port, output port, State Transferring button, status indicator lamp, serial ports, AD port, described input port, output port, State Transferring button, status indicator lamp, serial ports, AD port are from left to right set in turn on the front panel of control enclosure, described power interface is arranged at the side of control enclosure, described serial ports comprises RS232 serial ports and RS485 serial ports, it is characterized in that:
The method of testing of described RS232 serial ports comprises the steps:
Step 1, the RS232 serial ports of muller controller to be connected with operating terminal, to open the power supply of controller;
Step 2, operating terminal is opened download program terminal and download parameters is set, program writing operation is carried out to the central processing unit of controller, whether the download state on determining program download terminal completes, if completed, RS232 serial communication completes, otherwise, eject dialog box prompting, judge the fault type of RS232 serial communication according to dialog box information;
The method of testing of described RS485 serial ports comprises the steps:
Steps A, the RS232 serial ports of muller controller to be connected with operating terminal, RS485 serial ports to be connected with operating terminal by after RS232-RS485 converter, to open the power supply of controller;
Step B, on operating terminal, open COM Debug Assistant, RS485 serial ports parameter is set, sends serial data by COM Debug Assistant to RS485, read the data of RS485 feedback;
Step C, judge that whether data that RS485 feeds back are the serial data of 8, if so, perform step D, otherwise, check Serial Port Line annexation or more changer controller, return execution steps A;
Step D, judge that whether last two of 8 bit data strings are the summation of front 6 bit data, if so, RS485 serial communication is correct, otherwise, perform step e;
The data type of step e, position that front 6 bit data obtained in 8 bit data strings are not identical with the data defined in communication protocol, after mark, more changer controller returns execution steps A.
2. the method for testing of muller controller serial ports according to claim 1, is characterized in that: described RS232 serial ports is connected with the Serial Port Line all having a DB9 joint by two ends between operating terminal.
3. the method for testing of muller controller serial ports according to claim 1, it is characterized in that: described State Transferring button comprises two buttons of left and right setting, in described step 2 to the central processing unit of controller carry out program writing operation detailed process as follows:
First press right state switching button, then press left state switching button, then unclamp right state switching button and left state switching button successively, enter programming state, finally press the program button in download program terminal, program starts to download.
4. the method for testing of muller controller serial ports according to claim 1, is characterized in that: in described step B, RS485 serial ports parameter is respectively: 16 system digital displays show, baud rate selects 9600, even effect position.
5. the method for testing of muller controller serial ports according to claim 1, is characterized in that: everybody in described step C in the serial data of 8 is defined as a head pointer position, position, two test addresses, two data qualifier bits, a data readings position, two check bit successively.
6. the method for testing of muller controller serial ports according to claim 5, is characterized in that: the data of described two check bit by CRC check and mode obtain.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410521711.3A CN104331062A (en) | 2014-09-30 | 2014-09-30 | Test method for grinder controller serial port |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410521711.3A CN104331062A (en) | 2014-09-30 | 2014-09-30 | Test method for grinder controller serial port |
Publications (1)
Publication Number | Publication Date |
---|---|
CN104331062A true CN104331062A (en) | 2015-02-04 |
Family
ID=52405808
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410521711.3A Withdrawn CN104331062A (en) | 2014-09-30 | 2014-09-30 | Test method for grinder controller serial port |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104331062A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104858770A (en) * | 2015-05-15 | 2015-08-26 | 苏州德锐朗智能科技有限公司 | Controller of plane lapping machine |
WO2019095124A1 (en) * | 2017-11-15 | 2019-05-23 | 深圳配天智能技术研究院有限公司 | Method and device for switching data transmission state of serial port |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20010002935A (en) * | 1999-06-18 | 2001-01-15 | 김영환 | Circuit for RS-232 port stability in each board of CDMA exchange unit |
CN1570877A (en) * | 2004-04-27 | 2005-01-26 | 中兴通讯股份有限公司 | Universal serial communication interface debugging device and method |
CN102541709A (en) * | 2010-12-27 | 2012-07-04 | 佛山市顺德区顺达电脑厂有限公司 | Serial port debugging tool and method |
-
2014
- 2014-09-30 CN CN201410521711.3A patent/CN104331062A/en not_active Withdrawn
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20010002935A (en) * | 1999-06-18 | 2001-01-15 | 김영환 | Circuit for RS-232 port stability in each board of CDMA exchange unit |
CN1570877A (en) * | 2004-04-27 | 2005-01-26 | 中兴通讯股份有限公司 | Universal serial communication interface debugging device and method |
CN102541709A (en) * | 2010-12-27 | 2012-07-04 | 佛山市顺德区顺达电脑厂有限公司 | Serial port debugging tool and method |
Non-Patent Citations (2)
Title |
---|
王兆宇: "串口的调试和软件实现", 《森林工程》 * |
王晓萍: "《微机原理与系统设计实验教程》", 31 May 2012, 浙江大学出版社 * |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104858770A (en) * | 2015-05-15 | 2015-08-26 | 苏州德锐朗智能科技有限公司 | Controller of plane lapping machine |
WO2019095124A1 (en) * | 2017-11-15 | 2019-05-23 | 深圳配天智能技术研究院有限公司 | Method and device for switching data transmission state of serial port |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104833942B (en) | Electric energy meter battery power consumption automonitor and application method | |
CN105466629A (en) | Force sensor automatic calibration device and method | |
CN101865946B (en) | Alternating current parameter testing system and method of programmable digital integrated circuit | |
CN104331062A (en) | Test method for grinder controller serial port | |
CN203522710U (en) | Signal converter multifunctional detection apparatus | |
CN201796119U (en) | Programmable digital integrated circuit alternating-current parameter testing system | |
CN206369789U (en) | A kind of multifunctional digital wafer prober | |
CN103200013B (en) | Transponder test macro and method of testing | |
CN103604453A (en) | Multifunctional testing device for CVT gearboxes | |
CN203433054U (en) | Constant-temperature crystal oscillator automatic electrical property testing system | |
CN100511622C (en) | Method for emending output current by amending semiconductor pin test voltage | |
CN115598445B (en) | Electrical fault detection method and device based on hardware-in-loop | |
CN201993421U (en) | System for automatically testing front ends of millimeter waves | |
KR101643187B1 (en) | Monitoring and evaluation apparatus for real-time arc welding | |
CN201281755Y (en) | Assay system for multichannel multi-parameter electric measuring meter | |
CN104215863A (en) | Testing method of AD port of 1U controller of grinding machine | |
CN106772174A (en) | A kind of Electronic Calibration part automatic marking method | |
JP2007147363A (en) | Electronic device having function of checking component mounted state and method for checking component mounted state | |
CN102169146A (en) | Method for detecting function of frequency converter | |
CN211427149U (en) | Automatic calibration test system of data acquisition equipment | |
CN108196211A (en) | A kind of number table automatic verification system | |
CN204129202U (en) | Resistor intelligent display module | |
CN104101855A (en) | Probe card electric leakage monitoring method and probe card electric leakage monitoring system | |
CN201867388U (en) | Full-automatic calibrating device for gas alarm | |
CN112947034B (en) | High-precision clock chip compensation production system and 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 | ||
C04 | Withdrawal of patent application after publication (patent law 2001) | ||
WW01 | Invention patent application withdrawn after publication |
Application publication date: 20150204 |