Communication method, device and system based on GLINK-II bus protocol

By adopting a communication method based on the GLINK-II bus protocol in the automated control system, the problem of cumbersome wiring between controllers is solved, efficient signal transmission and processing is achieved, and cost is reduced.

CN119628995APending Publication Date: 2025-03-14SHAANXI GU HIGH-TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411827274.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-12
Publication Date
2025-03-14

AI Technical Summary

Technical Problem

In the prior art, the wiring process between controllers in an automated control system is too cumbersome, resulting in inconvenient signal transmission and high cost.

Method used

Using a communication method based on the GLINK-II bus protocol, the encoder value is received through the master controller and converted into absolute encoder value. The GLINK-II bus is efficiently transmitted to the slave controller, the slave controller performs compensation processing and subdivides the data, converts it into pulse signals and direction signals, and then accumulates the required encoder value.

Benefits of technology

This greatly simplifies the wiring process between controllers, improves wiring efficiency, and reduces the operating costs and time costs of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119628995A_ABST
    Figure CN119628995A_ABST
Patent Text Reader

Abstract

The invention provides a communication method, device and system based on a GLINK-II bus protocol, and particularly relates to the technical field of information transmission, and the method comprises the steps: receiving an encoder value through a master controller, converting the encoder value into an absolute encoder value, and then efficiently and accurately transmitting the absolute encoder value to a slave controller through the GLINK-II bus protocol. After the slave controller receives the signal, compensation processing of the position speed and the acceleration is carried out so as to improve the data precision. And then, subdividing the compensated data, converting the compensated data into pulse signals and direction signals, and obtaining the required encoder value again through accumulation processing. The technical problem that wiring between controllers is too tedious in the information transmission process in the prior art is solved. Therefore, the wiring process between the controllers is greatly simplified, and the wiring efficiency between the controllers is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of information transmission technology, and in particular to a communication method, device and system based on the GLINK-II bus protocol. Background Art

[0002] With the booming development of automation technology, the industrial manufacturing field is undergoing unprecedented changes. Enterprises have increasing requirements for the automation of production lines, aiming to enhance market competitiveness by reducing labor costs and improving production efficiency. In this context, automated control systems have become a core component of industrial production. However, with the increase in system complexity, signal transmission and compatibility issues between different devices have gradually become prominent. In particular, in scenarios where multiple controllers (or sites) are required to share encoder signals, traditional practices often face many challenges. On the one hand, encoders of different brands and models use their own unique communication protocols, making it difficult for signals to communicate directly. On the other hand, in order to achieve signal distribution and transmission, companies have to rely on dedicated encoder protocol converters, which are not only expensive, but also often not universal. Once the encoder brand or model is changed, it is necessary to re-purchase an adapted converter, which undoubtedly increases the company's operating costs and time costs. Therefore, how to solve the compatibility and cost issues of encoder signals while ensuring the efficient operation of the automated control system has become a key problem that the current industry needs to solve urgently.

[0003] In the face of the above challenges, traditional automation control systems have adopted a solution based on a dedicated encoder protocol converter. The core of this solution is to share encoder signals between different controllers (or sites) by introducing a converter that can identify and convert different encoder communication protocols. Specifically, when a controller needs to obtain encoder signals used by other controllers, it will first connect the encoder to a dedicated encoder protocol converter through an encoder line. Subsequently, the converter will convert the encoder signal into a format that can be recognized by the target controller according to the preset conversion rules, and transmit the converted signal to the target controller through another encoder line. If one-to-many signal distribution is required, multiple converters and corresponding encoder cables are required for connection. Although this solution solves the problem of signal compatibility to a certain extent, its inherent limitations are also significant: the non-universality of dedicated converters leads to high procurement and maintenance costs; at the same time, the complex wiring process not only increases the difficulty of construction, but also reduces the flexibility and scalability of the system. Therefore, exploring a more efficient, economical and universal solution is of great significance to promote the further development of automation control systems.

[0004] In summary, how to solve the technical problem that the wiring process between controllers during information transmission in the prior art is too complicated is a difficult problem that needs to be solved urgently in this technical field. Summary of the invention

[0005] The main purpose of the present invention is to provide a communication method, device and system based on the GLINK-II bus protocol to solve the technical problem that the wiring process between controllers in the process of information transmission in the prior art is too complicated, thereby greatly simplifying the wiring process between controllers and improving the wiring efficiency between controllers.

[0006] In order to achieve the above-mentioned purpose, the present invention provides a communication method, device and system based on the GLINK-II bus protocol.

[0007] In a first aspect, the present invention provides a communication method based on the GLINK-II bus protocol, comprising: The main controller receives the encoder value and converts it into an absolute encoder value; The master controller transmits the absolute encoder value to the corresponding slave controller via the GLINK-II bus; The slave controller receives the absolute encoder value and performs position velocity and position acceleration compensation processing on the absolute encoder value; The slave controller subdivides the absolute encoder value after compensation to convert it into a pulse signal and a direction signal; The slave controller accumulates the subdivided pulse signal and the direction signal to regain the required encoder value.

[0008] Optionally, the GLINK-II bus protocol is used to simplify the signal transmission process between the master controller and the slave controller.

[0009] In a second aspect, the present invention provides a communication device based on the GLINK-II bus protocol, the device is applied to the communication method described in the first aspect, and the device includes: A main controller module, for receiving encoder values ​​and converting them into absolute encoder values; The master controller module is further used to transmit the absolute encoder value to the corresponding slave controller via the GLINK-II bus; A slave controller module, used for receiving the absolute encoder value and performing position velocity and position acceleration compensation processing on the absolute encoder value; The slave controller module is also used to subdivide the absolute encoder value after compensation processing to convert it into a pulse signal and a direction signal; The slave controller module is also used to accumulate the subdivided pulse signal and direction signal to regain the required encoder value.

[0010] Optionally, both the master controller module and the slave controller module are configured with interfaces for executing GLINK-II bus protocol communication.

[0011] In a third aspect, the present invention provides a communication system based on the GLINK-II bus protocol, comprising: A communication device, wherein the communication device is the communication device described in the second aspect; A GLINK-II bus network is used to connect the master controller module and the slave controller module in the communication device to realize the transmission of the encoder signal, wherein the GLINK-II bus network is used to indicate a communication network constructed based on the GLINK-II bus protocol in the communication method described in the first aspect for realizing device interconnection.

[0012] In a fourth aspect, the present invention provides a computer program product, comprising a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program runs on a computer, it is used to execute the communication method described in the first aspect.

[0013] Optionally, the computer-readable storage medium is any one of a USB flash drive, a mobile hard disk, a read-only memory, a random access memory, a magnetic disk or an optical disk.

[0014] The communication method, device and system based on the GLINK-II bus protocol provided by the present application, the communication method provided by the present invention receives the encoder value through the main controller and converts it into an absolute encoder value, and then uses the GLINK-II bus to efficiently transmit these data to the slave controller. After receiving the data, the slave controller will perform compensation processing of position speed and position acceleration, further subdivide the processed absolute encoder value, convert it into a pulse signal and a direction signal, and re-acquire the required encoder value through an accumulation operation. The present invention also covers a corresponding communication device, which includes a main controller module and a slave controller module, both of which are equipped with an interface for executing GLINK-II bus protocol communication. In addition, the present invention proposes a communication system based on the GLINK-II bus protocol, which uses the above-mentioned device and the GLINK-II bus network to achieve fast and accurate transmission of encoder signals. Finally, the present invention also provides a computer program product, which can be run on a computer, execute the above-mentioned encoder communication method, support a variety of storage media, such as U disk, mobile hard disk, etc., and provide users with flexible use options. The present invention solves the technical problem that the wiring between controllers is too cumbersome in the process of information transmission in the prior art. Thereby greatly simplifying the wiring process between controllers and improving the wiring efficiency between controllers. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] The drawings constituting a part of the present application are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings: Figure 1 A flow chart of a communication method based on the GLINK-II bus protocol provided in this application; Figure 2 A schematic diagram of a communication device based on the GLINK-II bus protocol provided in this application; Figure 3 Schematic diagram of the communication system based on the GLINK-II bus protocol provided in this application.

[0016] The above drawings have shown clear embodiments of the present application, which will be described in more detail later. These drawings and text descriptions are not intended to limit the scope of the present application in any way, but to illustrate the concept of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0017] In order to make the purpose, technical solutions and advantages of this application clearer, the technical solutions in this application will be clearly and completely described below in conjunction with the drawings in this application. Obviously, the described embodiments are part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0018] The terms "first", "second", "third", "fourth", etc. (if any) in the description and claims of the present invention and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the terms used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in sequences other than those illustrated or described herein.

[0019] In the present invention, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in this application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.

[0020] The communication method, device and system based on the GLINK-II bus protocol provided by the present application receive and convert the encoder value through the master controller, and efficiently transmit it to the slave controller using the GLINK-II bus protocol. After the slave controller performs compensation processing, the data is subdivided and converted into pulse and direction signals, and then accumulated to obtain the required value. The technical problem of overly cumbersome wiring between controllers during information transmission in the prior art is solved. Thereby greatly simplifying the wiring process between controllers and improving the wiring efficiency between controllers.

[0021] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0022] Figure 1 The flow chart of the communication method based on the GLINK-II bus protocol provided in this application is intended to explain the communication method based on the GLINK-II bus protocol in detail, such as Figure 1 As shown, the communication method based on the GLINK-II bus protocol provided in this embodiment includes: S101: The main controller receives the encoder value and converts it into an absolute encoder value.

[0023] This embodiment will take the example of realizing effective transmission and processing of encoder signals from different stations in the automation control system of a satellite flexographic printing machine, and describe in detail the implementation steps of how the main controller receives the encoder value and converts it into an absolute encoder value to ensure the accuracy and efficiency of the entire transmission process.

[0024] The main controller receives the encoder value and converts it into an absolute encoder value, including: 1. Receiving encoder value Encoder signal acquisition: Each color group in the satellite flexographic printing machine is equipped with a motor encoder to monitor the motor's operating status and position information in real time.

[0025] The main controller (or station) is connected to the motor encoder of the specified color group through the built-in interface circuit to collect the signal sent by the encoder in real time.

[0026] Signal preprocessing: The collected encoder signals are usually analog signals or digital pulse signals. The main controller first performs preprocessing operations such as filtering and amplification on them to improve the stability and reliability of the signal.

[0027] The pre-processed signal is converted into a format that can be recognized by the main controller for subsequent processing.

[0028] 2. Convert encoder value to absolute encoder value Encoder value reading: The main controller obtains the encoder value of the current motor by reading the pre-processed encoder signal. This value usually indicates the position or rotation angle of the motor shaft.

[0029] Encoder value calibration: To ensure the accuracy of the encoder value, the main controller will calibrate the encoder value before conversion. This includes checking the encoder value range, resolution and other parameters to ensure that it meets the system requirements.

[0030] During the calibration process, the main controller may fine-tune or correct the encoder value according to the preset calibration parameters. The specific principle or process of fine-tuning or correcting the encoder value is as follows: 1. Calibration method (1) Use a multimeter to calibrate: When there is no indication error, the voltage drop between the encoder output terminal and the ground can be directly measured with the resistance block of the multimeter to determine the encoder's range and accuracy level.

[0031] (2) Calibration using a digital potentiometer: A digital potentiometer is a high-precision reference instrument that reflects the true value of the measured value through precise potential changes.

[0032] When the input signal is zero, the resistance of the potentiometer is infinite; when the input signal is greater than zero, the resistance of the potentiometer is 0.

[0033] Therefore, the accuracy level or measurement limit and other index parameters of the encoder signal to be tested can be determined by adjusting the on / off of the digital potentiometer.

[0034] (3) Test using an oscilloscope: When the frequency of the encoder signal to be tested is close to the carrier frequency or its multiple, an oscilloscope can be used to observe the displayed waveform to determine whether its accuracy level, measurement limit and other index parameters meet the requirements.

[0035] (4) Use the simulation method to verify the linearity of the encoder: Since most encoders used in practice are associated with linear, non-proportional systems (such as grating rulers), the encoder signal to be tested can be amplified and directly connected to the system's differential amplifier for detection to determine whether its linearity meets the specified requirements.

[0036] 2. Calibration parameters (1) Measuring range: Determine the maximum and minimum encoder value ranges that can be measured based on the encoder's design specifications and usage requirements.

[0037] (2) Resolution: The smallest unit value that the encoder can distinguish, that is, the degree of fineness of the encoder value change.

[0038] (3) Zero point offset: The encoder value at the initial position (i.e. when the motor shaft is not rotating) is used as the starting point for calibrating the encoder value.

[0039] (4) Gain adjustment: According to the actual measurement requirements, the encoder value is enlarged or reduced to ensure that the correspondence between it and the actual physical quantity (such as the rotation angle of the motor shaft) is accurate.

[0040] 3. Fine-tune or correct the process (1) Initial reception and conversion: The main controller collects the signal sent by the encoder in real time through the built-in interface circuit, and performs pre-processing operations such as filtering and amplification.

[0041] The pre-processed signal is converted into a format recognizable by the host controller, such as a digital signal.

[0042] (2) Encoder value reading and verification: The main controller reads the preprocessed encoder signal to obtain the encoder value of the current motor.

[0043] According to the preset parameters such as measuring range and resolution, the encoder value is verified to ensure that it is within a reasonable range.

[0044] (3) Calibration operation: If there is a deviation in the encoder value (such as exceeding the range, resolution mismatch or zero point offset, etc.), the main controller will make fine adjustments or corrections based on the preset calibration parameters.

[0045] The specific method of fine-tuning or correction may include adjusting the zero offset value, the gain adjustment coefficient, etc., to ensure that the corresponding relationship between the encoder value and the actual physical quantity is accurate.

[0046] (4) Re-verification and storage: After fine-tuning or correction, the main controller will re-check the encoder value to ensure that it meets the system requirements.

[0047] After verification, the main controller will store the calibrated encoder value for use in subsequent processing.

[0048] In summary, during the calibration process, the main controller will fine-tune or correct the encoder value according to the preset calibration parameters (such as range, resolution, zero offset and gain adjustment, etc.). This process ensures the accuracy of the encoder value, thereby ensuring the reliability and efficiency of the entire transmission and processing system.

[0049] Convert to absolute encoder value: The calibrated encoder value is further converted to an absolute encoder value by the main controller. The absolute encoder value is a value that uniquely identifies the motor shaft position and is affected by factors such as the motor's rotation direction and speed.

[0050] During the conversion process, the host controller uses a built-in algorithm or lookup table to convert the relative encoder value to the corresponding absolute encoder value. This usually involves comparing the encoder value to a reference point or zero point to determine the absolute position of the motor.

[0051] Data verification and storage: The converted absolute encoder value needs to be verified to ensure its accuracy and integrity. During the verification process, the main controller will perform redundancy checks, range checks, and other operations on the absolute encoder value.

[0052] Once verified, the absolute encoder value stored in the host controller's internal memory will be immediately transmitted and processed.

[0053] Through the above implementation steps, the main controller can accurately receive the encoder value and convert it into an absolute encoder value. This provides a reliable basis for subsequent encoder signal transmission and processing, and also ensures the stability and reliability of the satellite flexographic printing machine automation control system.

[0054] S102: The master controller transmits the absolute encoder value to the corresponding slave controller via the GLINK-II bus.

[0055] Specifically, when the master controller (or station) acquires the motor encoder signal, it first converts it into an absolute encoder value. This process ensures the accuracy and stability of the encoder signal, and provides a reliable basis for subsequent signal transmission and processing.

[0056] Next, the master controller (or site) uses the GLINK-II bus protocol to transmit the converted absolute encoder value. As an efficient and reliable communication protocol, the GLINK-II bus can achieve fast and accurate data transmission between different controllers (or sites). In this process, the master controller (or site) acts as the data transmitter, sends the absolute encoder value in the form of a data packet, and passes the data to the corresponding slave controller (or site) through the transmission channel of the GLINK-II bus.

[0057] After receiving the absolute encoder value from the master controller, the slave controller (or station) will process it accordingly. This process includes data analysis, verification and subsequent signal processing steps. Since the GLINK-II bus protocol has powerful data transmission capabilities and anti-interference performance, the slave controller (or station) can accurately and completely receive the absolute encoder value sent by the master controller, providing strong support for subsequent signal processing.

[0058] It is worth noting that in actual applications, the master controller and the slave controller may be distributed in different physical locations or devices. However, through the GLINK-II bus protocol, efficient and stable data transmission can still be achieved between these controllers. This not only improves the overall performance of the automation control system, but also saves a lot of wiring and wiring costs for enterprises.

[0059] In summary, the present invention realizes encoder signal transmission between the master controller and the slave controller by using the GLINK-II bus protocol, which not only simplifies the wiring method of the traditional automation control system, but also significantly improves the accuracy and stability of data transmission. This innovative technical solution saves a lot of manpower, material and financial costs for enterprises, and has important economic value and market application prospects.

[0060] S103: The slave controller receives the absolute encoder value, and performs position velocity and position acceleration compensation processing on the absolute encoder value.

[0061] Among them, for the step of receiving the absolute encoder value from the slave controller and performing position speed and position acceleration compensation processing on the absolute encoder value, specifically, when the master controller completes the conversion of the absolute encoder value and sends it to the corresponding slave controller through the GLINK-II bus, the slave controller first receives this data through its built-in communication interface module. As an efficient and reliable communication protocol, the GLINK-II bus ensures the accuracy and integrity of data during transmission. After receiving the absolute encoder value, the slave controller will immediately start its internal compensation processing module. The compensation processing module will first compensate the position speed of the received absolute encoder value. Since in actual applications, there may be slight speed differences between the encoder signals of different controllers (or stations), if this difference is not compensated, it may lead to the accumulation of system errors. Therefore, the slave controller will adjust the speed of the received absolute encoder value according to the preset compensation algorithm to ensure that the encoder signals of each controller (or station) in the entire system are consistent in speed.

[0062] 1. The implementation steps of the above preset compensation algorithm include: 1. Data reception: The slave controller receives the absolute encoder value sent by the master controller through its built-in communication interface module.

[0063] 2. Speed ​​difference detection: A speed difference detection module is set inside the controller to monitor and compare the speed change between the absolute encoder value currently received and the value received at the previous time point in real time.

[0064] By calculating the difference between the encoder values ​​at adjacent time points, the current speed value can be obtained.

[0065] 3. Application of compensation algorithm: According to the preset compensation algorithm, the slave controller adjusts the speed of the received absolute encoder value.

[0066] The core of the compensation algorithm is to determine an appropriate compensation amount that can eliminate or reduce the speed difference so that the encoder signal of the entire system remains consistent in speed.

[0067] 4. Acceleration compensation: In addition to velocity compensation, acceleration compensation also needs to be considered.

[0068] The purpose of acceleration compensation is to ensure that the encoder signal remains consistent even when the acceleration changes.

[0069] The acceleration value can be obtained by calculating the difference in velocity values ​​at adjacent time points and adjusted according to a preset acceleration compensation algorithm.

[0070] 5. Output the encoder value after compensation: After velocity and acceleration compensation, the slave controller will output the compensated absolute encoder value.

[0071] These values ​​will be used in subsequent subdivision processing, conversion of pulse signals and direction signals, etc.

[0072] 2. Related parameters of compensation algorithm 1. Speed ​​difference threshold: The threshold used to determine whether the current speed difference needs to be compensated.

[0073] When the speed difference exceeds this threshold, the compensation algorithm is triggered.

[0074] 2. Compensation coefficient: A factor used to determine the amount of compensation.

[0075] The size of the compensation coefficient can be adjusted according to the actual situation of the system to achieve the best compensation effect.

[0076] 3. Acceleration compensation factor: Factor used for acceleration compensation.

[0077] The size of this factor depends on the acceleration characteristics and compensation requirements of the system.

[0078] 3. Calculation formula of compensation algorithm 1. Speed ​​compensation formula: Compensated encoder value = original encoder value + compensation coefficient × (current speed - target speed) The current speed is obtained by calculating the difference between the encoder values ​​at adjacent time points, and the target speed is the encoder signal speed expected by the system.

[0079] 2. Acceleration compensation formula: Acceleration compensation amount = acceleration compensation factor × (current acceleration - target acceleration) Compensated encoder value (taking acceleration into account) = speed compensated encoder value + acceleration compensation The current acceleration is obtained by calculating the difference in velocity values ​​at adjacent time points, and the target acceleration is the encoder signal acceleration expected by the system.

[0080] Next, the compensation processing module will also compensate the absolute encoder value for position acceleration. In industrial automation systems, the motion state of the motor is often not constant, but will change with changes in factors such as load and speed. Therefore, the slave controller needs to compensate the received absolute encoder value for acceleration based on the actual motion state of the motor to eliminate the error caused by the change in motion state.

[0081] During specific implementation, the compensation processing of position velocity and position acceleration can refer to the following implementation process: 1. Position and speed compensation Speed ​​difference detection: The compensation processing module inside the slave controller first detects the speed information represented by the received absolute encoder value and compares it with the speed information of other controllers (or stations) in the system.

[0082] This process may involve sampling, filtering and differential calculation of the encoder signal to accurately obtain speed information.

[0083] Speed ​​compensation algorithm application: According to the preset compensation algorithm, the slave controller will adjust the speed of the received absolute encoder value.

[0084] The compensation algorithm may be based on mathematical methods such as linear interpolation, least squares method, Kalman filtering, etc. to ensure that the adjusted speed information remains consistent throughout the system.

[0085] In practical applications, specific parameters of the compensation algorithm (such as interpolation coefficients, filter coefficients, etc.) may need to be debugged and optimized according to the actual situation of the system.

[0086] Speed ​​compensation result output: After speed compensation processing, the slave controller will output the adjusted absolute encoder value for subsequent position acceleration compensation processing.

[0087] 2. Position acceleration compensation Motion status monitoring: The controller will monitor the motion status of the motor in real time, including factors such as load changes and speed fluctuations.

[0088] This may involve monitoring and analyzing parameters such as motor current and voltage to obtain the actual motion state of the motor.

[0089] Acceleration compensation algorithm application: According to the actual motion state of the motor, the slave controller will apply a preset acceleration compensation algorithm to compensate the received absolute encoder value.

[0090] The compensation algorithm may be based on dynamic models, machine learning algorithms, etc. to accurately predict and compensate for errors caused by changes in motion states.

[0091] In practical applications, the specific parameters and models of the compensation algorithm may need to be customized and optimized based on factors such as the type of motor and load characteristics.

[0092] Compensation result verification and output: After acceleration compensation processing, the slave controller will verify the compensation result to ensure its accuracy and reliability.

[0093] The verification process may involve resampling, filtering, and differencing the compensated encoder values ​​to check for abnormal fluctuations or error accumulation.

[0094] If the verification result is as expected, the slave controller will output the compensated absolute encoder value to the subsequent processing module (such as the subdivision processing module) for further processing.

[0095] After completing the compensation processing of position velocity and position acceleration, the slave controller will store the processed absolute encoder value in its internal memory for use in subsequent steps. At the same time, the slave controller will also feed back the processed absolute encoder value to the master controller or other controllers (or stations) that need the data through its communication interface module to achieve data sharing and collaborative work of the entire system.

[0096] To sum up, the slave controller in this embodiment receives the absolute encoder value transmitted by the master controller through the GLINK-II bus, and performs position velocity and position acceleration compensation processing on it, thereby effectively improving the accuracy and reliability of the encoder signal in the industrial automation system, and providing a strong guarantee for the production efficiency and product quality of the enterprise.

[0097] S104: The slave controller subdivides the compensated absolute encoder value to convert it into a pulse signal and a direction signal.

[0098] Among them, with respect to the step that the slave controller performs subdivision processing on the compensated absolute encoder value to convert it into a pulse signal and a direction signal, specifically, the slave controller is built with a fine subdivision processing module, which can receive the compensated absolute encoder value as input. During the subdivision processing, the module will first parse the value to identify the specific position and precision information it represents. Subsequently, according to the preset subdivision algorithm and parameters, the module will perform high-precision subdivision on the value to generate a series of more detailed encoding values.

[0099] The following is a detailed description of the subdivision processing module and its preset subdivision algorithm parameters, calculation formulas and principles: 1. Segmentation Processing Module The slave controller has a built-in fine subdivision processing module, which is a core component specially used for high-precision subdivision processing of absolute encoder values. This module has the following features: Input interface: Receives the compensated absolute encoder value as input signal.

[0100] Processing unit: Built-in high-performance processing unit for executing segmentation algorithms and parameter calculations.

[0101] Output interface: output subdivided pulse signal and direction signal.

[0102] 2. Preset Segmentation Algorithm Parameters The subdivision processing module performs subdivision processing on the absolute encoder value according to the preset subdivision algorithm and parameters. These parameters include: Subdivision multiple: Determines how many times the absolute encoder value is subdivided. For example, if the encoder value is subdivided into 1024 times, it means that each original code value will be subdivided into 1024 more detailed code values.

[0103] Subdivision accuracy: defines the accuracy of the subdivided encoder value. The higher the accuracy, the more accurately the subdivided encoder value can reflect the slight changes in the original encoder value.

[0104] Algorithm type: Select a suitable segmentation algorithm type, such as linear segmentation, nonlinear segmentation, etc. Different types of algorithms are suitable for different application scenarios and encoder types.

[0105] 3. Calculation formula and principle The subdivision processing module uses the following calculation formulas and principles during the subdivision process: Segment calculation formula: The subdivided encoding value = original encoding value × subdivision multiple + subdivision offset The subdivision offset is used to adjust the starting point of the subdivided encoding value to ensure that it corresponds correctly to the original encoder value.

[0106] Pulse signal generation principle: The frequency of the pulse signal is closely related to the accuracy and range of the subdivided encoder value. When the encoder value changes, the subdivision processing module generates a corresponding number of pulse signals based on the amount of change.

[0107] Pulse signal frequency = (encoder value change / encoder resolution) × pulse frequency coefficient Among them, the encoder resolution indicates the number of encoding values ​​corresponding to each unit length or angle of the encoder; the pulse frequency coefficient is used to adjust the frequency of the pulse signal to adapt to different application scenarios.

[0108] Direction signal generation principle: The direction signal is used to indicate the increase or decrease trend of the encoder value. When the encoder value increases, the direction signal is positive; when the encoder value decreases, the direction signal is negative.

[0109] The direction signal can be determined by comparing the current encoder value with the encoder value at the previous moment. If the current value is greater than the previous value, the direction signal is positive; otherwise, the direction signal is negative.

[0110] Principle of nonlinear subdivision algorithm (taking grating encoder as an example): For grating encoders, their output signals are usually two orthogonal square wave signals (sin and cos signals). After the two signals are processed by the subdivision processing module, they can be converted into higher-precision pulse signals and direction signals.

[0111] The nonlinear subdivision algorithm uses the phase relationship between the sin and cos signals to subdivide the encoder value. By calculating the amplitude and phase difference of the sin and cos signals, a more detailed encoder value can be obtained.

[0112] The subdivision processing module has built-in implementation logic of the nonlinear subdivision algorithm, which can automatically calculate the subdivided code value based on the input of sin and cos signals.

[0113] On this basis, the subdivision processing module further converts these detailed code values ​​into pulse signals and direction signals. The frequency and number of pulse signals are closely related to the accuracy and range of the code value, and can accurately reflect the subtle changes in the absolute encoder value. At the same time, the direction signal is used to indicate the increase or decrease trend of the encoder value, ensuring the integrity and accuracy of the signal conversion.

[0114] During specific implementation, the detailed process of segmentation processing can refer to the following process: 1. Input analysis: The subdivision processing module first receives the compensated absolute encoder value as input.

[0115] This value contains the specific position information and accuracy information of the encoder and is the basis for subdivision processing.

[0116] The module will parse the input value, extract the position and accuracy information, and prepare for subsequent processing.

[0117] 2. Application of Segmentation Algorithm: According to the preset subdivision algorithm and parameters, the subdivision processing module will perform high-precision subdivision on the input value.

[0118] The subdivision algorithm may be based on mathematical methods such as interpolation, polynomial fitting, Fourier transform, etc. to ensure that the subdivided encoding value has higher accuracy and resolution.

[0119] In practical applications, the specific parameters of the subdivision algorithm (such as the number of interpolation points, fitting order, etc.) may need to be debugged and optimized according to factors such as the type of encoder and accuracy requirements.

[0120] 3. Generate detailed encoding value: After being processed by the subdivision algorithm, the module generates a series of more detailed encoding values.

[0121] These encoded values ​​have higher precision and resolution than the original input values ​​and more accurately reflect the actual position of the encoder.

[0122] 4. Convert to pulse signal: The subdivision processing module further converts these detailed code values ​​into pulse signals.

[0123] The frequency and number of pulse signals are closely related to the accuracy and variation range of the encoded value.

[0124] By adjusting the frequency and number of pulse signals, subtle changes in the absolute encoder value can be accurately reflected.

[0125] The generation of pulse signals may involve the coordinated work of hardware components such as counters and clock circuits.

[0126] 5. Generate direction signal: While converting the pulse signal, the subdivision processing module also generates a direction signal.

[0127] The direction signal is used to indicate the increasing or decreasing trend of the encoder value, that is, whether the encoder is rotating in the forward or reverse direction.

[0128] The generation of the direction signal may be based on a sign change in the encoder value or an algorithm such as comparison logic.

[0129] 6. Signal output and verification: The subdivision processing module outputs the generated pulse signal and direction signal to subsequent processing modules or devices.

[0130] Before output, the module may check and verify the signal to ensure its accuracy and reliability.

[0131] The verification process may involve the detection and analysis of parameters such as the frequency, quantity, direction and stability of the pulse signal.

[0132] Through this subdivision processing step, the slave controller can achieve high-precision conversion of the absolute encoder value, providing reliable guarantee for subsequent signal accumulation and encoder value acquisition. This processing process not only reflects the technical innovation and practicality of the present invention, but also further improves the performance and stability of industrial automation products.

[0133] It can be understood that in practical applications, the segmentation processing module can work stably and reliably from the controller, meeting the accuracy and real-time requirements of the encoder signal transmission of the industrial automation system, saving a lot of manpower and material costs for the enterprise, and improving production efficiency and market competitiveness.

[0134] S105: The slave controller accumulates the subdivided pulse signal and the direction signal to regain the required encoder value.

[0135] This step describes in detail how the slave controller accumulates the subdivided pulse signal and direction signal to regain the required encoder value.

[0136] Specifically, inside the slave controller, a dedicated processing unit is provided for performing the accumulation operation. The processing unit first receives the pulse signal and direction signal after the subdivision processing. Since the subdivision processing converts the original absolute encoder value into a more refined pulse + direction form, these pulse signals and direction signals can more accurately reflect the motion state of the encoder.

[0137] After receiving these signals, the processing unit will perform accumulation operations according to the preset algorithm. For pulse signals, the processing unit will accumulate them one by one to obtain the total number of pulses; for direction signals, the processing unit will adjust the accumulation direction according to the direction indicated by them (forward or reverse). Through such accumulation processing, the processing unit can accurately reconstruct the original encoder value, or generate an encoder value with a specific resolution or accuracy as required.

[0138] The following is a detailed description of the specific content and principle calculation formula of the preset algorithm in "the accumulation operation will be performed according to the preset algorithm": 1. Principle of preset algorithm The preset algorithm is the core method used by the controller's internal processing unit to re-accumulate the subdivided pulse signal and direction signal into the required encoder value. Its basic principle is to accurately reconstruct or generate the encoder value by accumulating each pulse signal one by one and adjusting the direction of accumulation according to the direction signal.

[0139] 2. Algorithm Content Pulse signal accumulation: The processing unit receives the pulse signal after subdivision processing.

[0140] Each received pulse signal is accumulated one by one to obtain the total number of pulses.

[0141] Direction signal processing: The processing unit simultaneously receives the direction signal.

[0142] According to the direction signal (forward or reverse), adjust the accumulated direction of the pulse signal. If the direction signal is forward, continue to accumulate the pulse signal in the current direction.

[0143] If the direction signal is reverse, the accumulation direction is changed, that is, the received pulse signal is subtracted.

[0144] 3. Calculation formula Pulse signal accumulation formula: Assume that the initial pulse number is 0, and perform accumulation operation each time a pulse signal is received.

[0145] The accumulation formula is: total number of pulses = total number of pulses last time + number of pulses received this time.

[0146] Direction signal adjustment formula: When accumulating pulse signals, the direction signal is also taken into account.

[0147] If the direction signal is positive, no additional calculation is performed and the pulse signal is directly accumulated.

[0148] If the direction signal is reverse, the number of pulses received this time is subtracted from the total number of pulses, that is: total number of pulses = total number of pulses last time - number of pulses received this time (when the direction is reverse).

[0149] Encoder value reconstruction formula: Based on the subdivided pulse signal and direction signal, the original encoder value can be reconstructed or an encoder value with a specific resolution or accuracy can be generated.

[0150] Encoder value = total number of pulses × pulse equivalent (the change in encoder value corresponding to each pulse).

[0151] The pulse equivalent is determined by the design and specifications of the encoder and is usually given in the encoder's technical documentation.

[0152] The following is the specific accumulation processing flow: 1. Signal reception: The processing unit first receives the pulse signal and direction signal after subdivision processing.

[0153] The pulse signal represents the motion state of the encoder at a certain frequency and quantity, while the direction signal indicates the rotation direction of the encoder (forward or reverse).

[0154] 2. Initialize the accumulator: Before starting accumulation, the processing unit will initialize one or more accumulators for storing the accumulation results of the pulse signal.

[0155] An accumulator can be a counter, register, or other hardware component that can store and update a value.

[0156] 3. Pulse signal accumulation: The processing unit receives the pulse signals one by one and accumulates them into the initialized accumulator.

[0157] The accumulation operation can be a simple addition of values ​​or a more complex algorithmic processing, such as weighted accumulation, filtering, etc.

[0158] The accumulated result reflects the total number of pulses of the encoder rotation, that is, the relative position change of the encoder.

[0159] 4. Direction signal processing: While accumulating the pulse signal, the processing unit also adjusts the direction of accumulation according to the indication of the direction signal.

[0160] If the direction signal indicates forward rotation, the value in the accumulator is increased normally; if the direction signal indicates reverse rotation, the value in the accumulator is decreased (or a negative number is added to achieve the effect of decrease).

[0161] The processing of the direction signal can be achieved through logic circuits, comparators or software algorithms.

[0162] 5. Encoder value reconstruction: By accumulating pulse signals and processing direction signals, the processing unit can accurately reconstruct the original encoder value, or generate encoder values ​​with a specific resolution or accuracy as required.

[0163] Reconstruction of the encoder value may involve scaling, offsetting or formatting the accumulated result.

[0164] The reconstructed encoder value can be used for tasks such as position control, velocity measurement, acceleration calculation, etc.

[0165] 6. Result output and verification: The processing unit outputs the reconstructed encoder value to a subsequent processing module or device.

[0166] Before output, the processing unit may check and verify the results to ensure their accuracy and reliability.

[0167] The verification process may involve boundary checking, overflow detection, etc. of the accumulated results.

[0168] It is worth noting that in practical applications, the accumulation operation may be affected by various factors, such as signal noise, transmission delay, etc. In order to overcome these problems, the present invention adopts advanced signal processing technology and error correction algorithm in the design of the slave controller to ensure the accuracy and reliability of the accumulation result.

[0169] It can be understood that through the detailed description of the above embodiments, it can be seen that the present invention has a high technical level and practicality in the accumulation processing of the subdivided pulse signal and direction signal from the controller. This processing step not only realizes the accurate reconstruction of the encoder value, but also provides a more efficient and accurate solution for encoder signal transmission in industrial automation control systems.

[0170] Specifically, the GLINK-II bus protocol described in this embodiment is used to simplify the signal transmission process between the master controller and the slave controller. Specifically, the GLINK-II bus protocol is a communication protocol designed specifically for the field of industrial automation, which has the characteristics of high efficiency, stability, and strong compatibility. In the application scenario of the present invention, the master controller needs to convert the encoder value into an absolute encoder value and transmit it to the slave controller in some way. The traditional transmission method may require complex line connections and dedicated protocol converters, which not only increases the cost, but also reduces the flexibility and reliability of the system. After adopting the GLINK-II bus protocol, the signal transmission between the master controller and the slave controller becomes extremely simple. The master controller only needs to encapsulate the absolute encoder value into a data packet that complies with the GLINK-II bus protocol, and then send it to the slave controller through the bus. After receiving the data packet, the slave controller will parse it according to the specification of the GLINK-II bus protocol to obtain the absolute encoder value. In addition, the GLINK-II bus protocol also supports a variety of data transmission modes and error detection mechanisms to ensure the accuracy and reliability of data transmission. Even in a complex industrial automation environment, stable communication between the master controller and the slave controller can be guaranteed.

[0171] In summary, the GLINK-II bus protocol described in this embodiment plays an important role in simplifying the signal transmission process between the master controller and the slave controller, and provides strong support for efficient and stable communication in the field of industrial automation.

[0172] The present embodiment provides a communication method based on the GLINK-II bus protocol. The method first receives the encoder value through the main controller and converts it into an absolute encoder value for subsequent transmission and processing. Subsequently, the main controller transmits the absolute encoder value to the corresponding slave controller efficiently and accurately through the GLINK-II bus, thereby realizing information exchange between the controllers. After receiving the absolute encoder value from the slave controller, it will perform compensation processing on the position speed and position acceleration to improve the accuracy and stability of the signal. Then, the slave controller subdivides the absolute encoder value after compensation processing and converts it into a pulse signal and a direction signal for subsequent signal processing and control. Finally, the slave controller accumulates the subdivided pulse signal and direction signal to regain the required encoder value, thereby realizing the transmission and processing of the encoder signal across controllers. In this embodiment, there is no need for a dedicated encoder protocol converter and an additional encoder connection line, which has the significant advantages of simple wiring and low cost, saving manpower and material costs for enterprises, and has broad application prospects in the field of industrial automation.

[0173] Figure 2 A schematic diagram of a communication device based on the GLINK-II bus protocol provided in this application, such as Figure 2 As shown, the communication device 200 based on the GLINK-II bus protocol provided in this embodiment includes: The main controller module 201 is used to receive the encoder value and convert it into an absolute encoder value; The master controller module 201 is also used to transmit the absolute encoder value to the corresponding slave controller via the GLINK-II bus; A slave controller module 202, for receiving the absolute encoder value and performing position velocity and position acceleration compensation processing on the absolute encoder value; The slave controller module 202 is further used to subdivide the absolute encoder value after compensation processing to convert it into a pulse signal and a direction signal; The slave controller module 202 is also used to accumulate the subdivided pulse signal and direction signal to regain the required encoder value.

[0174] Specifically, the master controller module 201 and the slave controller module 202 are both configured with interfaces for executing GLINK-II bus protocol communication.

[0175] The present embodiment provides a communication device 200 based on the GLINK-II bus protocol, the device includes a main controller module 201 and a slave controller module 202, the main controller module 201 is used to receive the encoder value, convert it into an absolute encoder value, and send it to the corresponding slave controller module 202 through the GLINK-II bus; the slave controller module 202 is used to receive the absolute encoder value from the main controller module 201, perform position speed and position acceleration compensation processing on it, subdivide the compensated absolute encoder value to convert it into a pulse signal and a direction signal, and accumulate the subdivided pulse signal and direction signal to regain the encoder value. The device does not require a dedicated encoder protocol converter and an additional encoder connection line, and has significant advantages such as simple wiring and low cost.

[0176] Figure 3 The schematic diagram of the communication system based on the GLINK-II bus protocol provided for this application is as follows: Figure 3 As shown, the communication system 300 based on the GLINK-II bus protocol provided in this embodiment includes: The communication device 200 is Figure 2 The communication device 200 described in the embodiment; The GLINK-II bus network 302 is used to connect the master controller module and the slave controller module in the communication device 200 to realize the transmission of the encoder signal, wherein the GLINK-II bus network is used to indicate the Figure 1 The communication method described in the embodiment uses the GLINK-II bus protocol to construct a communication network for interconnecting devices.

[0177] The present invention also provides a computer program product, comprising a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is run on a computer, is used to execute Figure 1 The encoder communication method described in the embodiment. Specifically, the computer-readable storage medium is any one of a USB flash drive, a mobile hard disk, a read-only memory, a random access memory, a magnetic disk or an optical disk.

[0178] It will be appreciated by those skilled in the art that all or some of the steps, systems, and functional modules / units in the methods disclosed above may be implemented as software, firmware, hardware, and appropriate combinations thereof. In hardware implementations, the division between the functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, a physical component may have multiple functions, or a function or step may be performed by several physical components in cooperation. Some or all physical components may be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or implemented as hardware, or implemented as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or non-transitory medium) and a communication medium (or transient medium). As is known to those skilled in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to store the desired information and can be accessed by a computer. In addition, it is well known to those skilled in the art that communication media typically contain computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.

[0179] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the invention disclosed herein. The present application is intended to cover any modification, use or adaptation of the present application, which follows the general principles of the present application and includes common knowledge or customary techniques in the art that are not disclosed in the present application. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the following claims.

[0180] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.

Claims

1. A communication method based on the GLINK-II bus protocol, characterized in that: include: The main controller receives the encoder value and converts it into an absolute encoder value; The master controller transmits the absolute encoder value to the corresponding slave controller via the GLINK-II bus; The slave controller receives the absolute encoder value and performs position velocity and position acceleration compensation processing on the absolute encoder value; The slave controller subdivides the absolute encoder value after compensation to convert it into a pulse signal and a direction signal; The slave controller accumulates the subdivided pulse signal and the direction signal to regain the required encoder value.

2. The method according to claim 1, characterized in that The GLINK-II bus protocol is used to simplify the signal transmission process between the master controller and the slave controller.

3. A communication device based on the GLINK-II bus protocol, characterized in that: The device is applied to the communication method according to any one of claims 1 to 2, and the device includes: A master controller module, configured to receive encoder values, convert them into absolute encoder values, and transmit the absolute encoder values ​​to corresponding slave controllers via a GLINK-II bus; The slave controller module is used to receive the absolute encoder value, and perform position velocity and position acceleration compensation processing on the absolute encoder value; and subdivide the compensated absolute encoder value to convert it into a pulse signal and a direction signal; and accumulate the subdivided pulse signal and direction signal to regain the required encoder value.

4. The device according to claim 3, characterized in that The master controller module and the slave controller module are both configured with interfaces for executing GLINK-II bus protocol communication.

5. A communication system based on the GLINK-II bus protocol, characterized in that: include: A communication device, wherein the communication device is the communication device according to claim 3; A GLINK-II bus network is used to connect the master controller module and the slave controller module in the communication device to realize the transmission of the encoder signal, wherein the GLINK-II bus network is used to indicate a communication network constructed based on the GLINK-II bus protocol in the communication method as described in any one of claims 1 to 2 for realizing device interconnection.

6. A computer program product, characterized in that The invention comprises a computer-readable storage medium on which a computer program is stored. When the computer program is run on a computer, the computer program is used to execute the communication method according to any one of claims 1 or 2.

7. The computer program product according to claim 6, characterized in that The computer-readable storage medium is any one of a USB flash drive, a mobile hard disk, a read-only memory, a random access memory, a magnetic disk or an optical disk.