The research on G-code analysis algorithm of series-parallel mechanism motion control based on regular expression
ZHAO Junwei
LI Hanchao
DAI Jun
CHEN Guoqiang
HUANG Junjie
Abstract:Aiming at problems that it's hard to control the movement in numerical control application uniformly and effectively result from movement control instructions are various in different movement control platforms,one algorithm of G-code analysis based on regular expression in VC++ is proposed.According to the control hardware and software of existing mechanism,cooperated with the motion control card,the analytical mechanism with ability of examination,translation and transform between motion control card and NC G-code is designed.The compile of G-code which is input and executed is realized and the G-code is transformed into the instruction can be recognized by motion control card.Meanwhile the motion parameters are transformed to control the mechanism for controlling machine.Through the experiment on the motor of 3-PRS-XY series-parallel mechanism,and records and diagrams of feedback pulses are used to verify the accuracy and effectiveness of the algorithm.The accuracy of G-code inspection is improved by analysis string by string.The efficiency of codes translate is improved by keywords searching.The research and development of G-code interpretation is meaningful to development of numerical control system of series-parallel mechanism.
Keywords:regular expressionanalysis algorithmmotion control cardG-codecompile
Publication Date:2017-05-02
Online Publishing Date:2025-08-15(First online date of this platform, not the publication date of the document)
Pages:6( 86-91 )
Journal of Henan Polytechnic University(Natural Science)

Journal of Henan Polytechnic University(Natural Science)

ISTICPKU
ISSN:1673-9787
Year, Vol.(Issue):2017,36(3)