A high-precision closed-loop negative feedback control system
Patent Information
- Application Number
- CN202611426768.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-15
- Publication Date
- 2026-10-16
AI Technical Summary
[0006]现有技术缺少对执行单元实际输出状态的实时反馈调节,容易受到温度变化、电源波动及器件老化影响而产生输出偏差,现有误差补偿方式多采用固定参数或人工校准,无法根据运行过程中的实际误差变化进行自适应修正,导致长期运行精度降低,同时,高精度控制依赖高性能模拟器件,存在硬件成本高、生产校准复杂以及设备维护成本高等问题,难以满足工业控制系统对高精度、高稳定性和长期可靠运行的需求
本发明,通过反馈采样模块实时获取执行单元的实际输出量,并利用闭环调节模块计算实际输出量与目标输出参数之间的偏差,根据偏差结果动态调整数字控制指令,使输出误差能够被实时检测和修正,相比传统开环输出方式,可有效降低温度变化、电源波动、器件参数漂移等因素造成的输出偏移,提高系统长期运行过程中的控制精度和稳定性,利用自适应校准模块获取系统实际误差特征,并通过误差补偿参数对数字控制指令进行修正,使部分由硬件参数差异产生的误差能够通过软件补偿方式消除,从而降低对高成本精密器件的依赖,提高系统的成本控制能力,通过自适应校准模块自动获取系统运行过程中的误差变化,并根据实际误差特征更新误差补偿参数,无需依靠人工多次调整硬件参数完成校准,该方式能够减少人工校准过程中的操作差异,提高不同设备之间的输出一致性,有利于实现规模化生产;
Smart Images

Figure CN122923970A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of closed-loop feedback control technology, specifically relating to a high-precision closed-loop negative feedback control system. Background Technology
[0002] With the rapid development of industrial automation, intelligent manufacturing, and industrial process control technologies, the requirements for the accuracy of detection signal acquisition, control response speed, and long-term operational stability in industrial settings are constantly increasing. In industrial applications such as petrochemicals, energy, power, metallurgy, and environmental protection, numerous industrial sensors need to continuously monitor target objects such as temperature, pressure, liquid level, and gas concentration, and control equipment to perform corresponding actions based on the detection results. To achieve reliable signal interaction between detection and control equipment, analog control methods are widely used in industrial settings. Among these, the 4-20mA current loop signal has long been the primary signal transmission method in industrial sensor transmitters and automated control systems due to its advantages such as long transmission distance, strong anti-electromagnetic interference capability, stable signal transmission, and power supply and signal multiplexing.
[0003] Existing industrial control systems typically employ a structure of sensing, signal conditioning, control output, and execution drive to achieve target object control. Specifically, sensors acquire analog detection signals corresponding to the target object, such as voltage, current, or resistance changes resulting from variations in gas concentration, pressure, temperature, or liquid level. The acquired signals are then filtered, amplified, and bias-corrected by an analog conditioning circuit. Based on the detection results, corresponding control parameters are determined, and the output drive circuit generates the corresponding control signal, causing the execution unit to produce the target control quantity. For example, in an industrial 4-20mA signal output scenario, the control system determines the target output current based on the detection parameters, outputs a corresponding loop current through a current drive circuit, and transmits it to external control equipment to achieve industrial process parameter monitoring and control.
[0004] As industrial equipment evolves towards higher precision, higher reliability, and greater intelligence, traditional control methods can no longer fully meet the control demands of complex industrial environments. To improve control accuracy, some control systems are gradually introducing digital control technology. Microcontrollers process detection data and generate digital control commands based on preset control parameters, which are then converted into analog output signals to drive the execution equipment. Simultaneously, some systems are beginning to employ feedback detection methods. By collecting the actual output state of the execution unit and comparing it with the target output state, the control signal is adjusted based on the output error to achieve closed-loop control, improving the system's adaptability to external disturbances and equipment changes.
[0005] However, in actual industrial operation, the actuators, sensors, and control circuits are all affected by factors such as changes in ambient temperature, power fluctuations, electromagnetic interference, and long-term aging of components, causing the system output state to gradually deviate from the theoretical control target. Therefore, a high-precision closed-loop negative feedback control system is needed that can detect the actual output state of the actuator in real time, dynamically correct it according to the output error, and automatically update the compensation parameters according to the error changes generated during long-term operation, so as to ensure long-term stability and control accuracy in industrial control processes.
[0006] Existing technologies lack real-time feedback adjustment of the actual output state of the execution unit, making them susceptible to output deviations caused by temperature changes, power fluctuations, and device aging. Existing error compensation methods mostly use fixed parameters or manual calibration, which cannot adaptively correct for actual error changes during operation, resulting in reduced long-term operating accuracy. At the same time, high-precision control relies on high-performance analog devices, which has problems such as high hardware costs, complex production calibration, and high equipment maintenance costs, making it difficult to meet the requirements of industrial control systems for high precision, high stability, and long-term reliable operation. Summary of the Invention
[0007] The purpose of this invention is to provide a high-precision closed-loop negative feedback control system that can achieve high-precision, long-term stable operation of control output through real-time closed-loop feedback adjustment and adaptive error compensation, thereby reducing hardware costs and maintenance complexity, and improving the reliability and intelligence level of industrial control systems.
[0008] The specific technical solution adopted by this invention is as follows: A high-precision closed-loop negative feedback control system includes: The signal acquisition module is used to acquire the analog detection signal corresponding to the target detection object, and to condition and process the analog detection signal to obtain the corresponding digital detection data; The digital control module is used to determine the target output parameters based on the digital detection data and generate corresponding digital control instructions based on the target output parameters. The signal output module is used to generate corresponding output drive signals according to digital control instructions and drive the execution unit to output the target control quantity. The feedback sampling module is used to collect the actual output of the execution unit in real time and convert the actual output into feedback detection data. The closed-loop control module is used to compare the feedback detection data with the target output parameters to obtain the output deviation, and adjust the digital control commands according to the output deviation. The adaptive calibration module is used to acquire actual error characteristics during system operation, obtain corresponding error correction parameters based on the actual error characteristics, and update the error compensation parameters.
[0009] In a preferred embodiment, the signal acquisition module includes: The sensing and detection unit is used to acquire the analog detection signal corresponding to the target object. The analog detection processing unit is used to preprocess the analog detection signal to obtain the preprocessed analog detection signal; The analog-to-digital conversion unit is used to sample the preprocessed analog detection signal at a preset sampling frequency and convert it into digital sampled data; The digital sampling processing unit is used to perform data correction and data filtering on the digital sampling data according to preset digital signal processing rules to obtain the corresponding digital detection data.
[0010] In a preferred embodiment, the analog detection signal includes a voltage signal, a current signal, and a resistance change signal.
[0011] In a preferred embodiment, the preprocessing includes signal filtering, amplitude adjustment, and bias correction.
[0012] In a preferred embodiment, the digital control module includes: The state feature parameter acquisition unit is used to parse and process digital detection data to obtain the state feature parameters corresponding to the target detection object. The output parameter quantization unit is used to determine the target output parameter based on the state characteristic parameters, and to quantize the target output parameter to obtain the corresponding digital control quantity. The control command conversion unit is used to call pre-stored error compensation parameters during the generation of digital control commands, correct the digital control quantity, and convert the corrected digital control quantity into the corresponding digital control command.
[0013] In a preferred embodiment, the signal output module includes: The control instruction parsing unit is used to parse digital control instructions and obtain the corresponding output control parameters; The analog control conversion unit is used to generate a corresponding drive control signal based on the output control parameters, convert the drive control signal into a corresponding analog control signal, and generate a corresponding output drive signal based on the analog control signal. The target control quantity generation unit is used to apply the output drive signal to the execution unit and control the execution unit to generate the target control quantity corresponding to the target output parameter.
[0014] In a preferred embodiment, the feedback sampling module includes: The actual output conversion unit is used to obtain the actual output currently generated by the execution unit, perform sampling conversion processing on the actual output, and convert it into the corresponding sampling signal. The feedback detection acquisition unit is used to perform signal conditioning processing on the sampled signal. The signal conditioning processing includes filtering, amplitude adjustment and deviation correction to obtain the conditioned sampled signal. The conditioned sampled signal is then digitally converted to obtain the corresponding feedback detection data.
[0015] In a preferred embodiment, the closed-loop control module includes: The deviation determination unit is used to obtain the current actual output state parameter based on the feedback detection data, and to determine the output deviation between the actual output and the target output based on the actual output state parameter and the target output parameter. The control accuracy judgment unit is used to determine whether the current output state meets the preset allowable range based on the output deviation. When the output deviation exceeds the preset allowable range, a corresponding control correction amount is generated based on the output deviation amount, and the current digital control command is adjusted based on the control correction amount to obtain the adjusted digital control command. The control command adjustment unit is used to change the output state corresponding to the output drive signal according to the adjusted digital control command, so that the actual output of the execution unit gradually approaches the target output parameter.
[0016] In a preferred embodiment, the adaptive calibration module includes: The feedback output parameter acquisition unit is used to acquire feedback detection data under different output states during system operation, and to acquire the actual output state parameters corresponding to the feedback detection data. The actual error characteristic determination unit is used to compare the actual output state parameters with the corresponding target output parameters to determine the actual error characteristics during system operation. The actual error characteristics include zero-point offset error, gain change error, and output drift error. The error correction unit is used to obtain the corresponding error correction parameters based on the actual error characteristics and determine the corresponding correction amount for the error correction parameters. The parameter update unit updates the currently stored error compensation parameters based on the error correction parameters, generates new error compensation parameters, and calls the updated error compensation parameters in subsequent control processes to compensate and correct digital control commands.
[0017] And, a high-precision closed-loop negative feedback control terminal, comprising: One or more processors; A storage device on which one or more programs are stored; When one or more programs are executed by one or more processors, the one or more processors can implement a high-precision closed-loop negative feedback control system.
[0018] The technical effects achieved by this invention are as follows: This invention acquires the actual output of the execution unit in real time through a feedback sampling module and calculates the deviation between the actual output and the target output parameters using a closed-loop adjustment module. Based on the deviation results, the digital control commands are dynamically adjusted, enabling real-time detection and correction of output errors. Compared to traditional open-loop output methods, this effectively reduces output offset caused by factors such as temperature changes, power fluctuations, and device parameter drift, improving the control accuracy and stability of the system during long-term operation. An adaptive calibration module acquires the actual error characteristics of the system and corrects the digital control commands through error compensation parameters, allowing some errors caused by hardware parameter differences to be eliminated through software compensation. This reduces reliance on high-cost precision components and improves the system's cost control capabilities. The adaptive calibration module automatically acquires error changes during system operation and updates error compensation parameters based on actual error characteristics, eliminating the need for multiple manual adjustments of hardware parameters for calibration. This method reduces operational differences during manual calibration, improves output consistency between different devices, and facilitates large-scale production. This invention can acquire the actual output status in real time and dynamically correct control parameters based on feedback results. Therefore, it can effectively adapt to temperature changes, voltage fluctuations, electromagnetic interference, and performance changes caused by long-term operation of equipment in industrial environments, improving the system's reliable operation capability in complex environments. By continuously acquiring the actual error characteristics during operation and updating compensation parameters, the system can proactively correct for component aging and output drift, avoiding the need for shutdown and factory calibration due to accuracy degradation caused by long-term operation of traditional equipment. This reduces equipment maintenance frequency and extends equipment lifespan. Employing a digital closed-loop control method, the system uses feedback detection data to participate in control decisions in real time, enabling the system to quickly adjust control commands according to changes in output status. Compared with traditional analog adjustment methods, it has higher control flexibility and adjustability, meeting the application needs of high-precision industrial testing equipment, analog output devices, and intelligent sensor systems. Attached Figure Description
[0019] Figure 1 This is a system module diagram provided by the present invention. Detailed Implementation
[0020] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
[0021] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.
[0022] Secondly, the term "an embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in a preferred embodiment" appearing in different places throughout this specification does not necessarily refer to the same embodiment, nor is it a single or selective embodiment that mutually excludes other embodiments.
[0023] Furthermore, the present invention will be described in detail with reference to the schematic diagrams. When describing the embodiments of the present invention in detail, the schematic diagrams are merely examples for ease of explanation and should not limit the scope of protection of the present invention.
[0024] Please see the appendix Figure 1 As shown, a high-precision closed-loop negative feedback control system is provided, including: The signal acquisition module is used to acquire the analog detection signal corresponding to the target detection object, and to condition and process the analog detection signal to obtain the corresponding digital detection data; The digital control module is used to determine the target output parameters based on the digital detection data and generate corresponding digital control instructions based on the target output parameters. The signal output module is used to generate corresponding output drive signals according to digital control instructions and drive the execution unit to output the target control quantity. The feedback sampling module is used to collect the actual output of the execution unit in real time and convert the actual output into feedback detection data. The closed-loop control module is used to compare the feedback detection data with the target output parameters to obtain the output deviation, and adjust the digital control commands according to the output deviation. The adaptive calibration module is used to acquire actual error characteristics during system operation, obtain corresponding error correction parameters based on the actual error characteristics, and update the error compensation parameters.
[0025] As described above, when the system is running, it first acquires the analog detection signal corresponding to the target detection object through the signal acquisition module, and performs conditioning processing such as filtering, amplitude adjustment, and bias correction on the analog detection signal. At the same time, it converts the continuous analog signal into digital detection data through analog-to-digital conversion, so that the control process can perform accurate calculations based on digital data. After receiving digital detection data, the digital control module analyzes the current state of the target object, determines the corresponding target output parameters, and generates digital control instructions based on the target output parameters. During the generation of digital control instructions, the system calls pre-stored error compensation parameters to correct the digital control quantity, so as to compensate for errors caused by electronic component parameter deviations, temperature changes and long-term operation during signal acquisition, signal conversion and output driving, thereby improving the accuracy of control instructions. After receiving the digital control command, the signal output module parses the control command and converts it into a corresponding output drive signal. The output drive unit controls the execution unit to work, so that the execution unit generates the target control quantity corresponding to the target output parameter. For example, in the industrial analog output scenario, the corresponding current or voltage signal can be output by controlling the drive circuit to achieve precise control of external equipment or sensor circuits. During the process of the execution unit outputting the target control quantity, the feedback sampling module acquires the actual output quantity generated by the execution unit in real time and converts the actual output quantity into feedback detection data. This feedback detection data is used to reflect the current true output state of the system, enabling the control system to get rid of the problem of relying solely on the set value output in traditional open-loop control and realize real-time monitoring of the actual output result. After the closed-loop control module acquires the feedback detection data, it compares the actual output state parameters corresponding to the feedback detection data with the target output parameters, calculates the output deviation between the actual output and the target output, and when the output deviation exceeds the preset control range, the closed-loop control module generates a control correction amount based on the output deviation and adjusts the digital control command to make the signal output module readjust the output drive signal, thereby reducing the deviation between the actual output and the target output parameters and making the system output state continuously approach the target state. During system operation, the adaptive calibration module continuously acquires feedback detection data under different output states and determines the actual error characteristics based on the difference between the actual output state and the target output state. The system calculates the corresponding error correction parameters based on error characteristics such as zero-point offset error, gain change error, and output drift error, and updates the stored error compensation parameters. In subsequent control processes, the system calls the updated error compensation parameters to compensate for digital control commands, thereby achieving autonomous correction of output offset caused by component aging, environmental changes, and long-term operation. The actual output of the execution unit is obtained in real time by the feedback sampling module, and the deviation between the actual output and the target output parameter is calculated by the closed-loop adjustment module. The digital control command is dynamically adjusted according to the deviation result, so that the output error can be detected and corrected in real time. Compared with the traditional open-loop output method, it can effectively reduce the output offset caused by factors such as temperature change, power fluctuation and device parameter drift, and improve the control accuracy and stability of the system during long-term operation. The actual error characteristics of the system are obtained by the adaptive calibration module, and the digital control command is corrected by the error compensation parameter. Some errors caused by hardware parameter differences can be eliminated by software compensation, thereby reducing the dependence on high-cost precision components and improving the cost control capability of the system. The error change during the system operation is automatically obtained by the adaptive calibration module, and the error compensation parameter is updated according to the actual error characteristics. There is no need to rely on manual adjustment of hardware parameters to complete the calibration. This method can reduce the operational differences in the manual calibration process, improve the output consistency between different devices, and facilitate the realization of mass production. It can acquire the actual output status in real time and dynamically correct the control parameters based on the feedback results. Therefore, it can effectively adapt to temperature changes, voltage fluctuations, electromagnetic interference, and performance changes caused by long-term operation of equipment in industrial environments, improving the system's reliable operation capability in complex environments. By continuously acquiring the actual error characteristics during operation and updating the compensation parameters, the system can actively correct for component aging and output drift, avoiding the problem of traditional equipment needing to be shut down and returned to the factory for calibration after the accuracy decline due to long-term operation. This reduces the frequency of equipment maintenance and extends the service life of the equipment. It adopts a digital closed-loop control method, which uses feedback detection data to participate in control decisions in real time, enabling the system to quickly adjust control commands according to changes in output status. Compared with traditional analog adjustment methods, it has higher control flexibility and adjustability, and can meet the application needs of high-precision industrial testing equipment, analog output equipment, and intelligent sensor systems.
[0026] In a preferred embodiment, the signal acquisition module includes: The sensing and detection unit is used to acquire the analog detection signal corresponding to the target object. The analog detection processing unit is used to preprocess the analog detection signal to obtain the preprocessed analog detection signal; The analog-to-digital conversion unit is used to sample the preprocessed analog detection signal at a preset sampling frequency and convert it into digital sampled data; The digital sampling processing unit is used to perform data correction and data filtering on the digital sampling data according to preset digital signal processing rules to obtain the corresponding digital detection data.
[0027] It should be noted that the simulated detection signals include voltage signals, current signals, and resistance change signals.
[0028] It is worth mentioning that the preprocessing includes signal filtering, amplitude adjustment, and bias correction.
[0029] The aforementioned sensing and detection unit selects the corresponding sensing element based on the detection type of the target object. When the target object is a gas concentration, a gas sensor is used to acquire the electrical signal corresponding to the change in gas concentration. When the target object is a pressure state, a pressure sensor is used to acquire the resistance, voltage, or current change signal caused by the pressure change. When the target object is a temperature state, a thermistor, thermocouple, or temperature detection chip is used to acquire the analog signal corresponding to the temperature change. When the target object is a liquid level state, a liquid level sensor is used to acquire the analog output signal corresponding to the change in liquid level height. Taking a hydrogen sulfide detector as an example, the sensing and detection unit uses an electrochemical gas sensor as the detection element. When hydrogen sulfide gas in the air enters the sensor detection area, the hydrogen sulfide gas reacts with the internal electrodes of the sensor through oxidation and reduction reactions. The original reaction causes the sensor output to generate a weak current signal corresponding to the hydrogen sulfide concentration. For example, when the hydrogen sulfide concentration in the detection environment is 0 ppm, the sensor output current is about 4 mA. When the hydrogen sulfide concentration increases to 100 ppm, the sensor output current gradually increases to 20 mA. The sensing unit obtains the analog detection signal corresponding to the target object by acquiring this continuously changing current signal. For different types of sensors, the form of the analog detection signal is different. For example, pressure sensors output voltage signals that vary in the range of 0V-5V, thermistors output resistance signals that vary with temperature, and industrial two-wire transmitters output current signals that vary in the range of 4 mA-20 mA. The sensing unit acquires the above voltage signals, current signals, or resistance change signals by setting the corresponding acquisition interface. The analog detection processing unit first performs signal filtering on the analog detection signal. This is done by setting up an analog filtering circuit to remove high-frequency noise interference generated during the acquisition process. For example, when acquiring a 4mA-20mA current signal from a hydrogen sulfide sensor in an industrial setting, high-frequency electromagnetic interference is generated by the operation of motors, power modules, and other equipment. The analog detection processing unit uses a low-pass filter to allow only the low-frequency change signal corresponding to the target detection signal to pass through. For example, setting the cutoff frequency to 100Hz attenuates interference signals with frequencies higher than 100Hz, while retaining the valid signal corresponding to the gas concentration change. Secondly, the analog detection processing unit performs amplitude adjustment. Since different sensors have different output signal ranges, the input signal needs to be adjusted to a voltage range that the analog-to-digital converter (ADC) can recognize. For example, if a pressure sensor outputs a 0V-2V voltage signal, while the ADC input range is 0V-3.3V, then the amplitude adjustment is achieved through an operational amplifier circuit. The 0V-2V signal is amplified to 0V-3.3V, allowing the entire detection range to fully utilize the resolution of the analog-to-digital converter. Next, the analog detection processing unit performs bias correction. By acquiring the initial output value of the sensor in a no-input state, the zero-point offset is determined and compensated for in subsequent signal acquisition. For example, in the absence of hydrogen sulfide gas in the detection environment, the theoretical output current should be 4mA, but due to sensor error, the actual detected output current is 4.05mA. The analog detection processing unit records a 0.05mA offset and performs reverse correction in subsequent signal processing, making the processed analog detection signal closer to the actual detection state. After the above filtering, amplitude adjustment, and bias correction processing, for example, the original 4mA-20mA current signal is converted to a 0.66V-3.3V voltage signal, and high-frequency noise and zero-point deviation are removed, resulting in the pre-processed analog detection signal. The analog-to-digital conversion unit (ADC) acquires the current amplitude of the analog detection signal at fixed time intervals through the ADC chip, and converts the continuously changing analog quantity into a data sequence composed of multiple discrete digital values. The preset sampling frequency is set according to the rate of change of the target object and the response requirements of the control system. For example, for hydrogen sulfide gas detection, since the gas concentration changes on the order of seconds, the sampling frequency can be set to 100Hz, that is, 100 analog signals are acquired per second. For rapidly changing objects such as pressure detection, the sampling frequency can be set to 1000Hz, that is, 1000 signals are acquired per second. For slowly changing objects such as temperature detection, the sampling frequency can be set to 10Hz, that is, 10 signals are acquired per second. Taking a sampling frequency of 100Hz as an example, the ADC acquires the preprocessed analog detection signal every 10 milliseconds. At the first sampling time point, a voltage value of 0.66V is acquired, and at the second sampling time point... The system acquires a voltage value of 0.67V at the first sampling point, and a voltage value of 0.68V at the third sampling point, continuously acquiring continuous sampling values. After sampling, the analog-to-digital converter (ADC) converts the analog voltage into digital code according to its own resolution. For example, using a 16-bit ADC chip, it can divide the 0V-3.3V input range into 65536 digital levels. When the input voltage is 1.65V, since 1.65V accounts for about half of the 3.3V input range, it converts to approximately 32768 digital sampling values. When the input voltage is 3.3V, it converts to approximately 65535 digital sampling values. Through the above conversion process, the continuously changing analog detection signal is converted into digital sampling data composed of multiple digital sampling values. For example, the continuously acquired data sequence is 32768, 32850, 32920, 33010, etc. This digital sampling data can be further processed by the digital control module. The digital sampling processing unit utilizes digital algorithms to further eliminate quantization errors, random noise, and data offsets caused by long-term operation during analog-to-digital conversion, improving the accuracy of digital detection data. Preset digital signal processing rules include digital correction rules and digital filtering rules. The digital correction rules are set based on error parameters obtained during system calibration, including zero-point error parameters and gain error parameters. For example, during the initial system calibration, standard signals of 0mA, 4mA, 12mA, and 20mA are input to the detection input terminal, and the digital sampled values after analog-to-digital conversion are recorded respectively. If the theoretical digital value corresponding to 4mA is 13107, while the actual acquired digital value is 13200, a zero-point offset error of 93 digital units is calculated and stored as a correction parameter. In subsequent acquisition processes, the digital sampling processing unit subtracts 93 from the actual acquired value to obtain the corrected digital data. The digital filtering rules are used to reduce the error during sampling. The random fluctuations generated can be mitigated by using a moving average method, which averages five consecutively acquired digital sampling data. If the five consecutive sampling data are 1000, 1010, 990, 1020, and 980, then 1000 is first added to 1010 to get 2010, then added to 990 to get 3000, then added to 1020 to get 4020, then added to 980 to get 5000, and finally 5000 is divided by 5 to get 1000. 1000 is used as the current digital detection data, thereby reducing the impact of a single abnormal sampling value on the detection result. After data correction and digital filtering, for example, if the original digital sampling data is 13200, after zero-point error correction, it becomes 13107, and after filtering, it becomes 13105. The digital sampling processing unit outputs 13105 as the final digital detection data to the digital control module, so that the subsequent control process can calculate the target output parameters based on more accurate and stable data. It can convert the physical state changes of the target object into stable and accurate digital detection data, realize high-precision conversion from analog signal acquisition to digital control input, effectively reduce the impact of electromagnetic interference, sensor drift and device error on the detection results in industrial field, improve the accuracy and stability of the acquired signal, and improve the system adaptability by setting the corresponding sampling frequency according to different detection objects and the detection needs of fast-response objects and slow-changing objects.
[0030] In a preferred embodiment, the digital control module includes: The state feature parameter acquisition unit is used to parse and process digital detection data to obtain the state feature parameters corresponding to the target detection object. The output parameter quantization unit is used to determine the target output parameter based on the state characteristic parameters, and to quantize the target output parameter to obtain the corresponding digital control quantity. The control command conversion unit is used to call pre-stored error compensation parameters during the generation of digital control commands, correct the digital control quantity, and convert the corrected digital control quantity into the corresponding digital control command.
[0031] As described above, the state characteristic parameter acquisition unit first receives digital detection data, which includes continuously acquired digital sampling values, such as data sequences like 13105, 13200, and 13350. Then, it acquires the corresponding data conversion parameters based on the sensor type corresponding to the digital detection data. These data conversion parameters are obtained during the equipment factory calibration phase. For example, in a hydrogen sulfide detection scenario, during equipment calibration, standard gas concentrations of 0ppm, 50ppm, 100ppm, and 200ppm are input to the sensor, and the corresponding digital detection data are recorded. For instance, 0ppm corresponds to the digital value 13105, 50ppm to 25000, 100ppm to 36800, and 200ppm to 60000. The corresponding conversion parameters between the digital detection data and the actual detection concentration are established through these standard input and digital output values. In actual operation, after receiving the digital detection data, the state characteristic parameter acquisition unit converts the digital detection data into state characteristic parameters corresponding to the target detection object according to the conversion parameters obtained from the calibration above. For example, if the currently acquired digital detection data is 36800, the hydrogen sulfide concentration corresponding to this digital detection data can be determined by querying the calibration data to be approximately 100ppm. Therefore, the obtained state characteristic parameter is the current hydrogen sulfide concentration value of 100ppm. For pressure detection objects, when the sensor output voltage corresponding to the digital detection data is 2.5V, the corresponding pressure value is determined by the pressure sensor calibration parameters. For example, 0V corresponds to 0MPa, 5V corresponds to 10MPa, and 2.5V corresponds to 5MPa. The state characteristic parameter is the current pressure value of 5MPa. Through the above parsing process, the digital detection data is converted from a simple digital code into state characteristic parameters that can reflect the actual state of the target detection object. The output parameter quantization unit first determines the corresponding target output parameter based on the state characteristic parameter. The target output parameter represents the final output state that the execution unit needs to achieve. For example, in a 4-20mA industrial signal output scenario, if the state characteristic parameter indicates that the hydrogen sulfide concentration is 0ppm, then according to the industrial transmission standard, the target output parameter is determined to be 4mA; if the hydrogen sulfide concentration is 100ppm, then the target output parameter is determined to be 12mA; and if the hydrogen sulfide concentration is 200ppm, then the target output parameter is determined to be 20mA. The process of determining the target output parameter can be performed through pre-set output conversion data. For example, during the equipment debugging phase, the corresponding output parameter settings are established according to the sensor's range. The detection range is 0ppm-200ppm, corresponding to an output range of 4mA-20mA. When the detected concentration increases by 50ppm, the output current increases by 4mA. Therefore, 50ppm corresponds to 8mA, 100ppm corresponds to 12mA, 150ppm corresponds to 16mA, and 200ppm corresponds to 16mA. For a target output of 20mA, once the target output parameter is determined, the output parameter quantization unit further quantizes the target output parameter, converting the analog output quantity into a digital control quantity. The digital quantization range is determined based on the resolution of the digital-to-analog converter. For example, using a 16-bit digital control chip, its digital control range is 0-65535, corresponding to an output range of 4mA-20mA. Therefore, the 16mA output range is divided into 65536 digital levels. When the target output parameter is 12mA, since 12mA is in the middle of the 4mA-20mA range, the corresponding digital control quantity is approximately 32768. When the target output parameter is 20mA, the corresponding digital control quantity is approximately 65535. When the target output parameter is 4mA, the corresponding digital control quantity is approximately 0. Converting the target output parameter into a digital control quantity, for example, 32768 for a target output parameter of 12mA, allows the subsequent control instruction conversion unit to generate the corresponding digital control instruction based on this digital control quantity. The control command conversion unit corrects output deviations caused by electronic component errors, temperature changes, and long-term operation during the control process through digital compensation. This ensures that the final generated digital control commands can more accurately control the output module to produce the target control quantity. Pre-stored error compensation parameters are acquired during the system calibration phase and are used to describe the fixed and variable errors present in the current control system. The acquisition process involves the control system outputting multiple standard control points during the initial equipment startup, such as three calibration points: 4mA, 12mA, and 20mA. The actual output values are then collected through a feedback sampling module. If the theoretical output is 4mA and the feedback sampling yields an actual output of 4.05mA, then a zero-point offset error of 0.05mA is determined in the current system. If the theoretical output is 20mA and the actual output is 19.8mA, then a gain error of 0.2mA is determined. The system calculates error compensation parameters based on the actual output deviations at multiple calibration points and stores them in the internal storage area of the control chip. For example, if the zero-point compensation parameter after calibration is a reduction of 50 digital control units and the gain compensation parameter is an increase of 100 digital control units, then these parameters will be called for correction when generating subsequent digital control instructions. During the correction process... The control command conversion unit first acquires the digital control quantity generated by the output parameter quantization unit, for example, the target digital control quantity is 32768. Then, it calls the error compensation parameters, for example, if the current zero-point compensation value is reduced by 50 and the gain compensation value is increased by 100, then 32768 is first subtracted by 50 to get 32718, and then 32718 is increased by 100 to get 32818, finally obtaining the corrected digital control quantity 32818. Subsequently, the control command conversion unit converts the corrected digital control quantity into a digital control command, for example, according to the digital-to-analog converter communication protocol, converting the digital control quantity 32818 into... The corresponding binary control code is encapsulated into a control instruction data packet according to the set communication format, including the control address, control data, and check data. For example, the control address represents the output channel number, the control data represents the digital control quantity 32818, and the check data is used to determine whether the data transmission is correct. Finally, a complete digital control instruction is formed and sent to the signal output module, so that the signal output module generates the corresponding output drive signal according to the digital control instruction. It can use software compensation to correct the inherent error of the hardware, improve the accuracy of the digital control instruction, and realize high-precision control output under low-cost hardware conditions. It can convert the acquired digital detection data into state characteristic parameters with actual physical meaning, and further into digital control commands after error compensation, realizing the precise conversion from detection data to control output. Compared with traditional analog control methods, this module does not rely on the pure hardware precision to determine the output. Instead, it improves the accuracy of control parameter calculation by combining state analysis, parameter quantization and error compensation. Through pre-stored and continuously updated error compensation parameters, it can effectively reduce the control errors caused by component discreteness, temperature changes and long-term aging, so that the system has higher output stability and environmental adaptability.
[0032] In a preferred embodiment, the signal output module includes: The control instruction parsing unit is used to parse digital control instructions and obtain the corresponding output control parameters; The analog control conversion unit is used to generate a corresponding drive control signal based on the output control parameters, convert the drive control signal into a corresponding analog control signal, and generate a corresponding output drive signal based on the analog control signal. The target control quantity generation unit is used to apply the output drive signal to the execution unit and control the execution unit to generate the target control quantity corresponding to the target output parameter.
[0033] As described above, the digital control command is generated by the digital control module based on the target output parameters. It typically includes a control channel identifier, target output value data, and a data verification field. The control channel identifier identifies the output channel that needs to be controlled, the target output value data represents the desired output state, and the data verification field determines whether the received digital control command is complete and valid. The control command parsing unit first performs an integrity check on the received data, such as checking if the data length of the digital control command meets the preset requirements. If the system specifies that each control command consists of 8 bytes, then after receiving 8 bytes of data, the parsing process begins. Subsequently, control information is extracted according to the preset data arrangement order. For example, if the received digital control command is 01-80-00-7F-A2-00-00-35, the first byte 01 indicates the control output channel number, and the second to fourth bytes 80-00-00-35... 0-7F represent digital control quantities, and bytes 5 to 8 represent verification and communication status information. The control instruction parsing unit first reads the channel number to determine that the current controlled object is the first output channel. Then, it extracts the digital control quantity 32767 and converts it into output control parameters according to the control instruction encoding method. For example, in a 4-20mA output scenario, the digital control quantity range 0-65535 corresponds to an output current of 4mA-20mA. When the digital control quantity 32768 is parsed, since 32768 is in the middle of the 0-65535 range, the corresponding output control parameter is determined to be 12mA. When the digital control quantity 65535 is parsed, the corresponding output control parameter is determined to be 20mA. The digital control instruction output by the digital control module is converted into specific output control parameters so that the subsequent analog control conversion unit can generate the corresponding drive control signal based on the parameters. The analog control conversion unit first determines the drive control signal based on the output control parameters output by the control instruction parsing unit. For example, when the output control parameter is 12mA, the analog control conversion unit generates the corresponding digital control code based on the current output range of 4mA-20mA, controlling the digital-to-analog converter (DAC) to output a control voltage proportional to the current. Taking a 16-bit DAC as an example, its output digital range is 0-65535. First, the digital control quantity corresponding to the target output parameter is determined. When the target output current is 12mA, since the total range of 4mA-20mA is 16mA, 12mA is 8mA higher than the initial value of 4mA, accounting for half of the total output range. Therefore, the corresponding digital control quantity is approximately 32768. The analog control conversion unit sends the digital control quantity 32768 to the DAC. The DAC generates the corresponding analog voltage based on this digital input. For example, in the output range of 0V-3.3V, 32768 corresponds to an output voltage of approximately 1.65V. Subsequently, the analog control conversion unit inputs this analog control signal to the output drive. The output drive circuit adjusts the output current or voltage based on the analog voltage to generate the final output drive signal. For example, in a 4-20mA current output scenario, the output drive circuit includes an operational amplifier, a power transistor, and a sampling resistor. When the analog control signal is 1.65V, the output drive circuit adjusts the conduction level of the power transistor to stabilize the current in the output circuit at 12mA. When the analog control signal rises to 3.3V, the output drive circuit further increases the output current to reach 20mA. To improve output accuracy, the analog control conversion unit can also correct the drive control signal based on pre-stored output compensation parameters. For example, if the system calibration process determines that the output drive circuit has a 0.1mA deviation, the corresponding compensation amount is added when generating the drive control signal to make the actual output drive signal closer to the target output parameters. The analog control conversion unit completes the conversion from digital control commands to analog drive signals, enabling the system to achieve high-precision analog output using digital control. The target control quantity generation unit uses the output drive signal to drive the actual actuator, causing the actuator's state to change and achieve the preset control target. Depending on the specific application scenario, the actuator can be a current output load, valve control mechanism, motor drive mechanism, heating control module, or other equipment requiring control. For example, in an industrial 4-20mA signal output scenario, the actuator can be a current acquisition module in an external control device. After receiving the output drive signal, this module identifies the corresponding detection information based on the current magnitude. In a valve control scenario, the actuator can be an electric regulating valve, with the output drive signal being control voltage or control current. The drive circuit changes the position of the valve actuator, causing the valve opening to reach the target value. In a motor control scenario, the actuator can be a motor driver, adjusting the motor speed or torque through the input drive signal. Specifically, taking a 4-20mA industrial output as an example, when the target output parameter is determined to be 12mA, the analog control conversion unit generates... The corresponding output drive signal causes the output circuit to actually generate a 12mA current. After this current signal is applied to the external actuator, the actuator performs the corresponding action according to the control meaning corresponding to 12mA. For example, a liquid level control device specifies that 4mA represents 0% liquid level and 20mA represents 100% liquid level. Then, 12mA corresponds to a 50% liquid level control quantity. After receiving the 12mA signal, the actuator adjusts the current control state to the state corresponding to 50% liquid level. The target control quantity generation unit continuously receives the output drive signal during operation and detects the actual output state through the feedback sampling module. Based on the detection result, it determines whether the actuator has reached the target control quantity. When the actual output quantity does not reach the target value, the subsequent closed-loop adjustment module adjusts the digital control command according to the feedback deviation, causing the output drive signal to change, which further drives the actuator to adjust the output state. The target control quantity generation unit converts the digital control process into an actual physical control process, realizing precise adjustment of external equipment or controlled objects. This system achieves a high-precision conversion process from digital control commands to actual target control quantities. The control command parsing unit accurately converts digital control information into output control parameters, avoiding output errors caused by fixed proportional relationships in traditional analog circuits. The analog control conversion unit converts digital control quantities into stable analog output signals through digital-to-analog conversion and drive adjustment, while reducing conversion errors by combining compensation parameters. The target control quantity generation unit applies the output drive signal to the actual execution device and continuously optimizes the output state by combining subsequent feedback adjustment. It can improve output accuracy by combining digital control and analog drive, and reduce the impact of component discreteness, temperature changes, and long-term aging on output results. This makes the system suitable for high-precision control scenarios such as industrial 4-20mA transmitter output, sensor control, and automated execution equipment control.
[0034] In a preferred embodiment, the feedback sampling module includes: The actual output conversion unit is used to obtain the actual output currently generated by the execution unit, perform sampling conversion processing on the actual output, and convert it into the corresponding sampling signal. The feedback detection acquisition unit is used to perform signal conditioning processing on the sampled signal. The signal conditioning processing includes filtering, amplitude adjustment and deviation correction to obtain the conditioned sampled signal. The conditioned sampled signal is then digitally converted to obtain the corresponding feedback detection data.
[0035] As described above, the sampling method is set according to the type of the execution unit. For example, when the execution unit is an industrial 4-20mA signal output circuit, the actual output quantity is the current value in the output circuit. The actual output quantity conversion unit obtains the actual output current by connecting a high-precision sampling resistor in series in the output circuit. When the output circuit current flows through the sampling resistor, according to the characteristic that the current passing through the resistor generates a voltage change, a sampling voltage signal that changes proportionally to the output current is formed across the sampling resistor. For example, if the sampling resistor value is set to 100Ω, when the execution unit output current is 4mA, a voltage signal of approximately 0.4V is generated across the sampling resistor; when the execution unit output current is 12mA, a voltage signal of approximately 1.2V is generated across the sampling resistor; and when the execution unit output current is 20mA, a voltage signal of approximately 2V is generated across the sampling resistor. The actual output quantity conversion unit can determine the current actual output current of the execution unit by detecting this sampling voltage. For applications where the execution unit is a motor-driven device, the actual output quantity can be the motor speed. The actual output quantity conversion unit collects the pulse signal generated by the rotation of the motor shaft through an encoder. For example, if a motor generates 1000 pulses per revolution, and 5000 pulses are detected within a unit of time, the current motor speed can be calculated based on the number of pulses. In applications where the actuator is a regulating valve, the actual output can be the valve opening. The actual output conversion unit detects changes in valve stem displacement through a position sensor. For example, if the valve stem movement distance is detected to be 5mm, the current opening is determined to be 50% based on the valve's maximum stroke of 10mm. After acquiring the actual output, the actual output conversion unit further performs sampling and conversion processing, converting the continuously changing actual output into a sampling signal that can be acquired by subsequent circuits. Taking a 4-20mA output scenario as an example, the actual output current of 12mA is converted by a 100Ω sampling resistor to obtain a 1.2V sampling voltage signal. This 1.2V voltage signal is the sampling signal corresponding to the actual output. If the actual output current changes, for example, from 12mA to 15mA, the voltage across the sampling resistor increases from 1.2V to 1.5V. The actual output conversion unit continuously acquires this change process, thereby achieving real-time acquisition of the actual output state of the actuator. The feedback detection and acquisition unit first filters the sampled signal to reduce industrial interference during the sampling process. For example, in a 4-20mA industrial signal transmission environment, electromagnetic interference generated by motors, power modules, and relays can cause high-frequency noise signals in the sampled signal. The feedback detection and acquisition unit processes the sampled signal by setting a low-pass filter circuit, for example, setting the filter cutoff frequency to 100Hz. This preserves effective output variation signals below 100Hz while attenuating interference signals above 100Hz. When the sampled signal contains normal variation signals in the range of 0.5V-1.5V, coupled with a 0.05V high-frequency interference signal, the filtering process can reduce the noise level. The 0.05V interference makes the output signal closer to the actual sampled value. Secondly, the feedback detection and acquisition unit performs amplitude adjustment. Since different sampling signal amplitude ranges may not directly match the input range of the analog-to-digital converter (ADC), the signal amplitude needs to be adjusted through amplification or attenuation. For example, if the ADC with a 3.3V power supply has an input range of 0V-3.3V, while the sampling signal range is 0V-2V, then the amplification circuit adjusts the maximum 2V sampling signal to 3.3V, allowing the sampling signal to fully utilize the ADC's detection range and improving detection resolution. If the sampling signal range is 0V-5V, then the attenuation circuit reduces the 5V signal to below 3.3V to avoid exceeding the ADC's input range. Next, the feedback detection and acquisition unit performs deviation correction processing to eliminate detection offsets caused by sampling resistor errors, amplifier circuit errors, and conversion device errors. For example, during system calibration, a standard 12mA current is input to the output circuit. The actual sampling voltage obtained through sampling resistor detection is 1.21V, while the theoretical value should be 1.20V. This indicates a 0.01V deviation in the current sampling link. The feedback detection and acquisition unit records this deviation correction parameter. In subsequent detection processes, when a 1.21V signal is acquired, the 0.01V deviation is subtracted to obtain the corrected 1.20V sampling signal. After filtering, amplitude adjustment, and deviation correction processing, the conditioned sampling signal is obtained, which is then fed back for detection. The acquisition unit inputs the sampled signal into the analog-to-digital converter (ADC) for digital conversion. During the digital conversion process, the continuous analog signal is converted into digital code according to the resolution of the ADC. For example, using a 16-bit ADC chip with an input range of 0V-3.3V, it can be divided into 0-65535 digital levels. When the conditioned sampled signal is 1.65V, since 1.65V accounts for half of the 3.3V input range, a feedback digital value of approximately 32768 is obtained. When the sampled signal is 1.2V, a digital value of approximately 23831 is obtained through proportional conversion. The feedback detection acquisition unit continues to execute the above sampling, conditioning, and conversion process to finally obtain feedback detection data that can represent the actual output state of the execution unit. It can acquire the actual output status of the execution unit in real time and convert the actual output into feedback detection data that can be processed by the digital control system, realizing the real-time monitoring of the output results by the control system. Compared with the traditional open-loop control method, which only controls the output based on the set value, it forms a feedback channel by collecting the actual output, enabling the system to identify the deviation between the actual output and the target output. It reduces industrial environmental interference through filtering, improves signal utilization through amplitude adjustment, and reduces the sampling link error through deviation correction, making the feedback detection data more accurate and reliable. It can effectively suppress the output drift caused by output driving device errors, temperature changes, power fluctuations, and long-term aging, and improve the control accuracy, operational stability, and long-term reliability of the entire high-precision closed-loop negative feedback control system.
[0036] In a preferred embodiment, the closed-loop control module includes: The deviation determination unit is used to obtain the current actual output state parameter based on the feedback detection data, and to determine the output deviation between the actual output and the target output based on the actual output state parameter and the target output parameter. The control accuracy judgment unit is used to determine whether the current output state meets the preset allowable range based on the output deviation. When the output deviation exceeds the preset allowable range, a corresponding control correction amount is generated based on the output deviation amount, and the current digital control command is adjusted based on the control correction amount to obtain the adjusted digital control command. The control command adjustment unit is used to change the output state corresponding to the output drive signal according to the adjusted digital control command, so that the actual output of the execution unit gradually approaches the target output parameter.
[0037] As described above, the deviation determination unit first receives feedback detection data. This feedback detection data is digital data obtained by the feedback sampling module after sampling, filtering, correction, and analog-to-digital conversion. For example, if the feedback detection data is 23831, this digital value represents the digital code corresponding to the current output state of the execution unit. The deviation determination unit then converts the digital feedback data into actual output state parameters based on the feedback conversion parameters obtained during the system calibration phase. These feedback conversion parameters are obtained through the equipment's factory calibration process. The acquisition steps involve inputting multiple standard output states to the execution unit. For example, in a 4-20mA output system, these states are used to control the execution unit... The execution unit outputs standard currents of 4mA, 12mA, and 20mA and records the corresponding digital detection values generated by the feedback sampling module. For example, 4mA corresponds to the digital value 7943, 12mA to 23831, and 20mA to 39719. A corresponding conversion relationship is established between these standard output values and the digital feedback values. In actual operation, when the feedback detection data is 23831, the deviation determination unit determines the current actual output state parameter as 12mA based on the calibration parameters, meaning the actual output current of the execution unit is 12mA. For other execution units, such as motor control... The control system uses feedback detection data to correspond to the number of encoder pulses. Calibration establishes the relationship between pulse count and rotational speed; for example, 1000 pulses correspond to 100 revolutions per minute. When the feedback detection data is 5000 pulses, the actual output state parameter is determined to be 500 revolutions per minute. After obtaining the actual output state parameter, the deviation determination unit further determines the output deviation based on the actual output state parameter and the target output parameter. Specifically, the actual output value is compared with the target output value to obtain the difference. For example, the digital control module determines the target output parameter to be 12mA, while... If the feedback detection shows that the actual output status parameter is 11.8mA, the deviation determination unit compares the actual output value of 11.8mA with the target output value of 12mA. Subtracting 11.8mA from 12mA yields an output deviation of 0.2mA, indicating that the current actual output of the execution unit is 0.2mA lower than the target output. If the actual output status parameter is 12.3mA, subtracting 12mA from 12.3mA yields an output deviation of 0.3mA, indicating that the current actual output exceeds the target output by 0.3mA. The deviation determination unit can obtain the degree of deviation between the actual output and the target output in real time. The control accuracy judgment unit compares the currently detected output deviation with a preset allowable error range to determine whether the current closed-loop control state meets the system's specified control accuracy. The preset control accuracy requirements are set based on the system application scenario, output signal type, and control target accuracy requirements, and are stored within the control chip during the system design phase. For example, in a high-precision 4-20mA industrial signal output scenario, to meet the control requirements of industrial instruments, the output control accuracy requirement can be set to ±0.1%FS, where FS represents the full-scale range, i.e., 4... The effective output range between mA and 20mA is 16mA. Therefore, the maximum allowable error is 16mA multiplied by 0.1%, which calculates to 0.016mA. This means the actual output deviation is within 0.016mA of the target output value. For example, if the target output parameter is 12mA, the allowable actual output range is between 11.984mA and 12.016mA. When the deviation determination unit calculates an output deviation of 0.01mA, since 0.01mA is less than 0.016mA, the control accuracy judgment unit determines the current output... If the output state meets the preset control accuracy requirements, no adjustment of the digital control instructions is needed. When the calculated output deviation is 0.05mA, since 0.05mA exceeds the allowable range of 0.016mA, it is determined that the current output state does not meet the control accuracy requirements and closed-loop correction is required. For different application scenarios, the preset control accuracy requirements can be adjusted according to actual needs. For example, ordinary industrial control equipment can be set to ±0.5%FS, corresponding to an allowable error of 0.08mA when the full scale range is 16mA. High-precision detection equipment can be set to ±0.05%FS, corresponding to an allowable error of 0.008mA. The preset control accuracy requirements are obtained during the equipment design stage based on the response capability of the execution unit, the detection accuracy of the sensor, and the system control objectives, and verified through experimental testing. For example, 100 sets of standard control signals are continuously output, the actual output deviation range is statistically analyzed, and the maximum error value that meets the stable operation requirements is taken as the preset allowable range. The control accuracy judgment unit can identify whether the current output has reached the control objective and only start the correction process when the output deviation exceeds the allowable range, avoiding frequent adjustments that cause system output fluctuations. When the control accuracy judgment unit determines that the output deviation exceeds the allowable range, the control correction processing unit first determines the direction of the deviation, that is, whether the actual output is lower than or higher than the target output. For example, if the target output parameter is 12mA and the actual feedback output is 11.8mA, then the actual output is 0.2mA lower than the target output. In this case, the digital control quantity needs to be increased to increase the output current. If the actual output is 12.3mA, then the actual output is 0.3mA higher than the target output, and the digital control quantity needs to be decreased to reduce the output current. Subsequently, the control correction quantity is determined according to the output deviation. The control correction quantity is determined based on the conversion ratio between the digital control quantity and the actual output quantity. For example, in the system, the 4mA-20mA output corresponds to the digital control range of 0-65535, then the 16mA output range corresponds to 65536 digital levels. Each increase of 1mA corresponds to approximately 4096 digital control units. When an output deviation of 0.2mA is detected, By multiplying 0.2 by 4096, approximately 819 digital control units are obtained. Therefore, the control correction amount is set to increase by 819 digital control units. If the digital control quantity corresponding to the current digital control instruction is 32768, then during the adjustment process, 32768 is increased by 819 to obtain 33587 as the new digital control quantity. Subsequently, the control correction processing unit regenerates the digital control instruction based on the new digital control quantity. For example, if the control data field in the original digital control instruction represents 32768, after correction, the control data field is updated to 33587, while keeping the control address field and communication verification field unchanged. The adjusted digital control instruction is then repackaged and formed. After the adjusted digital control instruction is sent to the signal output module, the output drive signal is increased accordingly, thereby increasing the actual output of the execution unit. The control correction processing unit can automatically adjust the control instruction according to the actual output error, realizing closed-loop error correction without manual intervention. The control command adjustment unit first parses the adjusted digital control command to obtain the new digital control quantity. For example, if the original target output parameter is 12mA, corresponding to digital control quantity 32768, and feedback detection finds that the actual output is only 11.8mA, a new digital control quantity 33587 is obtained after control correction processing. The control command adjustment unit sends 33587 to the signal output module. The signal output module adjusts the digital-to-analog converter output voltage according to the new digital control quantity. For example, if the original digital control quantity 32768 corresponds to a DAC output voltage of 1.65V, the adjusted digital control quantity 33587 corresponds to a DAC output voltage of approximately 1.69V. The output drive circuit increases the output current according to this voltage change, making the original 1 The output increases from 1.8mA to nearly 12mA. Subsequently, the feedback sampling module collects the actual output of the execution unit again and sends the new feedback detection data to the closed-loop adjustment module, forming a continuous cyclic adjustment process. For example, after the first adjustment, the actual output increases from 11.8mA to 11.98mA, but there is still a deviation of 0.02mA. Since this deviation exceeds the allowable range of 0.016mA, the control command adjustment unit continues to make small corrections. After multiple adjustments, the actual output reaches around 12.00mA, which meets the control accuracy requirements. The control command adjustment unit makes the output of the execution unit gradually approach the target output parameter, realizes the dynamic elimination of output error, and improves the system's anti-interference ability and long-term stability. It can detect the actual output status of the execution unit in real time and automatically adjust the control command according to the deviation between the actual output and the target output. It realizes a closed-loop control process of target setting, output execution, feedback detection, error correction, and re-output. It does not rely on the accuracy of the execution unit itself to maintain the output. Instead, it identifies the output deviation through real-time feedback data and uses digital correction to compensate for the output drift caused by device error, temperature change, power fluctuation and long-term aging. By setting a control accuracy judgment mechanism, it only makes adjustments when the error exceeds the allowable range, avoiding output oscillation caused by frequent system adjustments and improving control stability. It can effectively improve the control accuracy in application scenarios such as 4-20mA industrial signal output, motor control, valve regulation, etc., and enable the system to have high precision, fast response and long-term reliable operation capabilities.
[0038] In a preferred embodiment, the adaptive calibration module includes: The feedback output parameter acquisition unit is used to acquire feedback detection data under different output states during system operation, and to acquire the actual output state parameters corresponding to the feedback detection data. The actual error characteristic determination unit is used to compare the actual output state parameters with the corresponding target output parameters to determine the actual error characteristics during system operation. The actual error characteristics include zero-point offset error, gain change error, and output drift error. The error correction unit is used to obtain the corresponding error correction parameters based on the actual error characteristics and determine the corresponding correction amount for the error correction parameters. The parameter update unit updates the currently stored error compensation parameters based on the error correction parameters, generates new error compensation parameters, and calls the updated error compensation parameters in subsequent control processes to compensate and correct digital control commands.
[0039] As described above, during system operation, the feedback output parameter acquisition unit initiates the data acquisition process according to a preset calibration cycle or trigger conditions. The calibration cycle is set based on the system operating environment, output stability requirements, and device aging rate. For example, for an industrial 4-20mA output system, automatic calibration can be set to be performed every 24 hours; for industrial environments with large temperature variations, automatic calibration can be set to be performed every 12 hours; and for equipment with a stable operating environment, calibration can be set to be performed every 7 days. After entering the calibration process, the feedback output parameter acquisition unit controls the system to output multiple preset output states, such as five calibration output points: 4mA, 8mA, 12mA, 16mA, and 20mA. After each output state stabilizes, corresponding feedback detection data is collected. The collection process is as follows: First, the target output value of the control system is 4mA. The system waits for the output to stabilize for a period of time, such as 500 milliseconds, allowing the execution unit to reach a stable state. Then, the current feedback detection data is obtained through the feedback sampling module, for example, a digital feedback value of 8200 is obtained. Subsequently, the control output is adjusted to 8mA, and feedback detection data is collected again, for example, a digital feedback value of 16400 is obtained. The system continues to output at 12mA, 16mA, and 20mA, obtaining digital feedback values of 24550, 32700, and 40900 respectively. By obtaining feedback detection data corresponding to multiple different output states in the above manner, a complete set of operational feedback data is formed. After acquiring the feedback detection data, the feedback output parameter acquisition unit further converts the feedback detection data into actual output state parameters. The specific conversion process is based on the feedback conversion parameters obtained during the initial system calibration phase. For example, during factory calibration, standard output currents of 4mA, 12mA, and 20mA are input respectively, and the corresponding feedback detection data is recorded. If 4mA corresponds to a digital value of 8200, 12mA to a digital value of 24576, and 20mA to a digital value of 40950, then a conversion relationship between the digital feedback value and the actual output current is established. During actual operation, when the feedback detection data of 24550 is acquired, it is compared with the calibration data to determine that the digital value corresponds to approximately [missing information - likely a specific value]. The feedback detection data is 11.98mA. When the feedback detection data is 40900, the actual output state parameter is determined to be approximately 19.98mA. For other types of execution units, such as motor control systems, the feedback detection data can be the number of encoder pulses. The correspondence between the number of pulses and the rotational speed is obtained through the initial calibration of the equipment. For example, every 1000 pulses corresponds to 100 revolutions per minute. When the feedback detection data is 5000 pulses, 5000 is divided by 1000 to get 5, and then 5 is multiplied by 100 to get 500 revolutions per minute, which gives the actual output state parameter. The feedback output parameter acquisition unit can acquire real operating data under different output states and convert the feedback digital signal into actual physical output parameters. The actual error characteristic determination unit first acquires the actual output state parameters of the feedback output parameter acquisition unit and the corresponding target output parameters of the system. For example, if the system sets the target output to 4mA, 8mA, 12mA, 16mA, and 20mA, the corresponding actual output values are acquired as follows: 4.05mA, 8.08mA, 12.10mA, 16.12mA, and 20.15mA. Then, the actual error characteristic determination unit compares each output point and determines the single-point output error by the difference between the actual output value and the target output value. For example, the target output... If the target output is 4mA and the actual output is 4.05mA, then subtracting 4mA from 4.05mA yields an error of 0.05mA. If the target output is 20mA and the actual output is 20.15mA, then subtracting 20mA from 20.15mA yields an error of 0.15mA. After calculating the error at multiple output points, the actual error characteristic determination unit further analyzes the error variation pattern and determines the actual error characteristics. Among these, the zero-point offset error represents the fixed offset generated at the starting position of the entire output range. It is determined by observing the error at the lowest output point; for example, when the theoretical output is 4mA, the actual output... If the voltage stabilizes at 4.05mA, then the system has a 0.05mA zero-point offset error. Gain variation error represents how the error changes as the output amplitude increases during output range expansion. It is determined by comparing the error changes at high and low output points. For example, if the error is 0.05mA at 4mA output and 0.15mA at 20mA output, subtracting 0.05mA from 0.15mA yields a change of 0.10mA, indicating a gain deviation, i.e., a change in the output ratio. Output drift error represents the change in output over time during long-term system operation. The unstable offset is determined by acquiring and comparing data with the same output state over multiple time periods. For example, if the system outputs 12mA at 10:00 AM but the actual detected value is 12.02mA, and outputs 12mA again at 6:00 PM but the actual detected value is 12.08mA, then the change of 0.06mA is obtained by subtracting 12.02mA from 12.08mA. This indicates that there is a 0.06mA output drift error. The actual error characteristic determination unit can distinguish different types of error sources and determine whether the current system error mainly comes from zero-point offset, gain change, or long-term drift. The error correction unit first determines the corresponding error correction parameters based on the actual error characteristics. These parameters include zero-point correction parameters, gain correction parameters, and drift correction parameters. The error correction parameters are derived from data collected during actual calibration. For example, during initial equipment calibration, the system stores zero-point compensation parameters and gain compensation parameters as 0. After running for a period of time, if the actual error characteristic determination unit detects a 4mA output but the actual output is 4.05mA, it indicates that the system has generated a 0.05mA zero-point offset, requiring the generation of corresponding zero-point correction parameters. Since the digital control range of 0-65535 corresponds to the 4mA-20mA output range, 16mA corresponds to 65536 digital units, and each 1mA corresponds to approximately 4096 digital units. The digital correction amount corresponding to 0.05mA is obtained by multiplying 0.05 by 4096, resulting in approximately 205 digital units. Therefore, the zero-point correction parameter is generated by reducing the digital control unit by 205. For gain variation errors, for example, the error is 0.05mA at 4mA and 0.15mA at 20mA. The output ratio change is determined by comparing the high and low end errors. The entire output range is proportionally corrected. For example, if the output range requires a 0.1% gain compensation, the gain correction parameter is generated by increasing the current digital control value by the corresponding proportional value. For output drift error, for example, if the same output state produces a 0.06mA change after 24 hours of monitoring, approximately 246 digital units are calculated based on the digital units corresponding to 0.06mA. This value is used as the drift correction parameter. After determining the error correction parameter, the error correction unit further determines the corresponding correction amount, that is, determines the specific value that the digital control command needs to increase or decrease. If the current digital control quantity is 32768, corresponding to a target output of 12mA, and the actual output is found to be 0.05mA lower than the target value, then the correction quantity is calculated based on 205 digital units corresponding to 0.05mA, and increased by 205, resulting in 32973 as the new control digital quantity. If the actual output is higher than the target value of 0.05mA, then 205 is subtracted from 32768 to obtain 32563. The error correction unit can automatically calculate the compensation direction and compensation magnitude based on the actual error, achieving precise correction for different error types. The parameter update unit first reads the original error compensation parameters from the current storage area. For example, in the initial state of the device, the zero-point compensation parameter is 0, the gain compensation parameter is 0, and the drift compensation parameter is 0. Then, it receives the new error correction parameters output by the error correction unit. For example, if the detected zero-point correction parameter is reduced by 205 digital units, the gain correction parameter is increased by 50 digital units, and the drift correction parameter is reduced by 20 digital units, the parameter update unit performs cumulative updates based on the current compensation parameters and the newly added correction parameters. For example, if the original zero-point compensation parameter is 0, writing a correction parameter that reduces by 205 digital units changes the new zero-point compensation parameter to -205; if the original gain compensation parameter is 0, increasing by 50 digital units changes the new gain compensation parameter to 50; and if the original drift compensation parameter is 0, reducing by 20 digital units changes the new drift compensation parameter to -20. After the update is complete, the new error compensation... The parameters are stored in the non-volatile memory area inside the control chip, such as EEPROM or Flash memory area, so that the latest compensation data can still be called after the device is powered off and restarted. In the subsequent control process, when the digital control module generates new digital control instructions, the parameter update unit calls the latest error compensation parameters for compensation and correction. For example, the target output of 12mA corresponds to a digital control quantity of 32768. The currently stored zero-point compensation parameter is -205 and the gain compensation parameter is 50. Then, 32768 is first subtracted from 205 to get 32563, and then 50 is added to get 32613. Finally, the compensated digital control quantity of 32613 is generated, and this control quantity is converted into a digital control instruction and sent to the signal output module. By continuously updating the error compensation parameters, the system can automatically adapt to component aging, temperature changes and performance changes caused by long-term operation, and achieve long-term high-precision operation without manual recalibration. It can proactively detect output errors during long-term system operation and automatically generate and update compensation parameters based on actual error characteristics, achieving automatic calibration throughout the entire lifecycle of the control system. It can automatically identify different error sources such as zero-point offset, gain change, and output drift, and generate corresponding correction values for different error types, enabling the system to maintain high output accuracy. By applying the updated error compensation parameters to the subsequent digital control command generation process, it can effectively offset parameter changes caused by long-term operation of sensors, resistors, operational amplifiers, and driving devices, improve the system's resistance to temperature drift and long-term stability, reduce equipment maintenance frequency, and achieve autonomous calibration and reliable operation of a high-precision closed-loop negative feedback control system.
[0040] And, a high-precision closed-loop negative feedback control terminal, comprising: One or more processors; A storage device on which one or more programs are stored; When one or more programs are executed by one or more processors, the one or more processors can implement a high-precision closed-loop negative feedback control system.
[0041] The above description is merely a preferred embodiment of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention. Structures, devices, and operating methods not specifically described or explained in this invention are implemented according to conventional methods in the art unless otherwise specified or limited.
Claims
1. A high-precision closed-loop negative feedback control system, characterized in that, include: The signal acquisition module is used to acquire the analog detection signal corresponding to the target detection object, and to condition and process the analog detection signal to obtain the corresponding digital detection data; The digital control module is used to determine the target output parameters based on the digital detection data and generate corresponding digital control instructions based on the target output parameters. The signal output module is used to generate corresponding output drive signals according to digital control instructions and drive the execution unit to output the target control quantity. The feedback sampling module is used to collect the actual output of the execution unit in real time and convert the actual output into feedback detection data. The closed-loop control module is used to compare the feedback detection data with the target output parameters to obtain the output deviation, and adjust the digital control commands according to the output deviation. The adaptive calibration module is used to acquire actual error characteristics during system operation, obtain corresponding error correction parameters based on the actual error characteristics, and update the error compensation parameters.
2. The high-precision closed-loop negative feedback control system according to claim 1, characterized in that, The signal acquisition module includes: The sensing and detection unit is used to acquire the analog detection signal corresponding to the target object. The analog detection processing unit is used to preprocess the analog detection signal to obtain the preprocessed analog detection signal; The analog-to-digital conversion unit is used to sample the preprocessed analog detection signal at a preset sampling frequency and convert it into digital sampled data; The digital sampling processing unit is used to perform data correction and data filtering on the digital sampling data according to preset digital signal processing rules to obtain the corresponding digital detection data.
3. The high-precision closed-loop negative feedback control system according to claim 2, characterized in that, The analog detection signals include voltage signals, current signals, and resistance change signals.
4. The high-precision closed-loop negative feedback control system according to claim 2, characterized in that, Preprocessing includes signal filtering, amplitude adjustment, and bias correction.
5. The high-precision closed-loop negative feedback control system according to claim 1, characterized in that, The digital control module includes: The state feature parameter acquisition unit is used to parse and process digital detection data to obtain the state feature parameters corresponding to the target detection object. The output parameter quantization unit is used to determine the target output parameter based on the state characteristic parameters, and to quantize the target output parameter to obtain the corresponding digital control quantity. The control command conversion unit is used to call pre-stored error compensation parameters during the generation of digital control commands, correct the digital control quantity, and convert the corrected digital control quantity into the corresponding digital control command.
6. The high-precision closed-loop negative feedback control system according to claim 1, characterized in that, The signal output module includes: The control instruction parsing unit is used to parse digital control instructions and obtain the corresponding output control parameters; The analog control conversion unit is used to generate a corresponding drive control signal based on the output control parameters, convert the drive control signal into a corresponding analog control signal, and generate a corresponding output drive signal based on the analog control signal. The target control quantity generation unit is used to apply the output drive signal to the execution unit and control the execution unit to generate the target control quantity corresponding to the target output parameter.
7. The high-precision closed-loop negative feedback control system according to claim 1, characterized in that, The feedback sampling module includes: The actual output conversion unit is used to obtain the actual output currently generated by the execution unit, perform sampling conversion processing on the actual output, and convert it into the corresponding sampling signal. The feedback detection acquisition unit is used to perform signal conditioning processing on the sampled signal. The signal conditioning processing includes filtering, amplitude adjustment and deviation correction to obtain the conditioned sampled signal. The conditioned sampled signal is then digitally converted to obtain the corresponding feedback detection data.
8. The high-precision closed-loop negative feedback control system according to claim 1, characterized in that, The closed-loop control module includes: The deviation determination unit is used to obtain the current actual output state parameter based on the feedback detection data, and to determine the output deviation between the actual output and the target output based on the actual output state parameter and the target output parameter. The control accuracy judgment unit is used to determine whether the current output state meets the preset allowable range based on the output deviation. When the output deviation exceeds the preset allowable range, a corresponding control correction amount is generated based on the output deviation amount, and the current digital control command is adjusted based on the control correction amount to obtain the adjusted digital control command. The control command adjustment unit is used to change the output state corresponding to the output drive signal according to the adjusted digital control command, so that the actual output of the execution unit gradually approaches the target output parameter.
9. The high-precision closed-loop negative feedback control system according to claim 1, characterized in that, The adaptive calibration module includes: The feedback output parameter acquisition unit is used to acquire feedback detection data under different output states during system operation, and to acquire the actual output state parameters corresponding to the feedback detection data. The actual error characteristic determination unit is used to compare the actual output state parameters with the corresponding target output parameters to determine the actual error characteristics during system operation. The actual error characteristics include zero-point offset error, gain change error, and output drift error. The error correction unit is used to obtain the corresponding error correction parameters based on the actual error characteristics and determine the corresponding correction amount for the error correction parameters. The parameter update unit updates the currently stored error compensation parameters based on the error correction parameters, generates new error compensation parameters, and calls the updated error compensation parameters in subsequent control processes to compensate and correct digital control commands.
10. A high-precision closed-loop negative feedback control terminal, characterized in that, include: One or more processors; A storage device on which one or more programs are stored; When one or more programs are executed by one or more processors, the one or more processors implement the high-precision closed-loop negative feedback control system according to any one of claims 1 to 9.