Switch control method of time schedule controller

By collecting ambient temperature data in real time and adjusting the clock crystal oscillator frequency dynamically, the time measurement error problem caused by clock drift in the timing controller is solved, and more stable and accurate gate switch control is achieved, improving the quality of the finished product.

CN119773173AActive Publication Date: 2025-04-08ZHEJIANG HENGDAO TECH

Patent Information

Application Number
CN202510017361.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-06
Publication Date
2025-04-08
Estimated Expiration
2045-01-06

AI Technical Summary

Technical Problem

When the existing timing controller faces ambient temperature changes, clock drift causes time measurement errors, affecting the accuracy of gate switch operations, and thus affecting the quality of finished products.

Method used

By using a temperature sensor to collect ambient temperature data in real time, dynamically adjust the clock crystal oscillator frequency to compensate for clock drift, ensuring the switching control stability and accuracy of the timing controller.

Benefits of technology

It effectively reduces the time measurement error caused by clock drift, improves the accuracy of gate switch control, and improves the quality and production efficiency of finished products.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119773173A_ABST
    Figure CN119773173A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of time schedule controllers, and discloses an on-off control method of a time schedule controller, which comprises the following steps: electrically connecting the time schedule controller to a power supply, and starting the time schedule controller through an ON / OFF key to enable the time schedule controller to be in a standby state; then receiving a control mode selected by a user and input control parameters; then, a corresponding injection molding signal input mode is determined according to the type of an injection molding machine, and a proper output voltage form is selected according to the type of an electromagnetic valve; and finally, after an injection molding signal sent by the injection molding machine is received, the time sequence controller automatically controls opening and closing of the pouring gate based on the selected control mode and parameters. Particularly, the time schedule controller collects environment temperature data in real time based on a temperature sensor, and dynamically adjusts the frequency of a clock crystal oscillator to compensate clock drift, so that the stability and accuracy of on-off control of the time schedule controller are ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of timing controllers, and more specifically, to a switch control method of a timing controller. Background Art

[0002] In the needle valve hot runner injection molding system, the timing controller plays a vital role. It is responsible for accurately controlling the opening and closing time of the gate according to the injection signal of the injection molding machine, thereby affecting the process of the plastic melt filling the mold cavity. Correct timing control can not only ensure that the product has no weld line and improve the surface quality of the molded product, but also optimize the product quality by adjusting the injection volume of each gate to avoid problems such as defects or insufficient filling. However, in the prior art, the traditional timing controller has some limitations, which limit its performance and application range.

[0003] In actual application environments, one of the challenges facing timing controllers is the problem of clock drift. As the core component of timing inside electronic devices, the frequency stability of the clock crystal oscillator is directly affected by changes in ambient temperature. When the temperature rises or falls, the output frequency of the oscillator will change slightly, which will cause errors in time measurement. Although this error may not be obvious in a short period of time, in long-term operation or application scenarios that require extremely high time resolution, the accumulation may cause significant time deviations, thereby affecting the accuracy of the gate switch action and, in turn, the quality of the finished product.

[0004] Therefore, an optimized switching control method of a timing controller is desired. Summary of the invention

[0005] In order to solve the above technical problems, the present application is proposed. The embodiment of the present application provides a switch control method of a timing controller, which collects ambient temperature data in real time based on a temperature sensor, dynamically adjusts the frequency of a clock crystal oscillator to compensate for clock drift, thereby ensuring the stability and accuracy of the switch control of the timing controller.

[0006] According to one aspect of the present application, a switch control method of a timing controller is provided, comprising: electrically connecting the timing controller to a power supply, and turning on the timing controller through an ON / OFF key so that the timing controller is in a standby state; receiving a control mode selected by a user, and receiving control parameters input by the user; determining the type of injection signal input based on the type of injection molding machine; determining the type of output voltage based on the type of solenoid valve; after receiving the injection signal emitted by the injection molding machine, the timing controller automatically controls the opening and closing of the gate based on the control mode and the control parameters, wherein the timing controller adjusts the frequency of the clock crystal oscillator based on the ambient temperature data collected by the temperature sensor to compensate for the clock drift.

[0007] In the switch control method of the timing controller, the control mode includes a two-stage timing control mode and a four-stage timing control mode.

[0008] In the switch control method of the above-mentioned timing controller, when the control mode is a two-stage timing control mode, the control parameters include timing resolution, delay time and gate opening time; when the control mode is a four-stage timing control mode, the control parameters include timing resolution, first delay time, first gate opening time, second delay time and second gate opening time.

[0009] In the switch control method of the above-mentioned timing controller, after receiving the injection signal sent by the injection molding machine, the timing controller automatically controls the opening and closing of the gate based on the control mode and the control parameters, including: after receiving the injection signal, the timing controller performs preliminary verification on the injection signal to check whether the injection signal meets the preset standard format and logical conditions; after determining that the injection signal meets the preset standard format and logical conditions, loads the control mode and the control parameters; based on the ambient temperature data collected by the temperature sensor, adjusts the frequency of the clock crystal oscillator; based on the frequency of the clock crystal oscillator, determines the current determined time point as the starting time of the timing task; based on the control parameters, creates a timing task instance to obtain a queue of timing task instances; executes the queue of timing task instances to automatically control the opening and closing of the gate.

[0010] In the switch control method of the above-mentioned timing controller, the frequency of the clock crystal oscillator is adjusted based on the ambient temperature data collected by the temperature sensor, including: obtaining the ambient temperature values ​​of multiple sampling points collected by the temperature sensor; calculating the average of the ambient temperature values ​​of the multiple sampling points as the current ambient temperature value; determining the actual clock frequency value based on the current ambient temperature value; calculating the difference between the actual clock frequency value and the ideal clock frequency to obtain an error signal; and inputting the error signal into a PID controller to obtain a frequency control signal, and the frequency control signal is used to adjust the frequency of the clock crystal oscillator.

[0011] In the switch control method of the timing controller, determining the actual clock frequency value based on the current ambient temperature value includes: obtaining a temperature-frequency relationship curve; searching the temperature-frequency relationship curve for a clock frequency value corresponding to the current ambient temperature value as the actual clock frequency value.

[0012] In the switch control method of the above-mentioned timing controller, the error signal is input into a PID controller to obtain a frequency control signal, and the frequency control signal is used to adjust the frequency of the clock crystal oscillator, including: determining a frequency proportional gain part; determining a frequency integral gain part; determining a frequency differential gain part; adding the frequency proportional gain part, the frequency integral gain part and the frequency differential gain part to obtain a frequency increment; generating the frequency control signal based on the frequency increment, and the frequency control signal is a PWM signal.

[0013] Compared with the prior art, the switching control method of the timing controller provided in the present application collects ambient temperature data in real time based on a temperature sensor, and dynamically adjusts the frequency of the clock crystal oscillator to compensate for clock drift, thereby ensuring the stability and accuracy of the switching control of the timing controller. BRIEF DESCRIPTION OF THE DRAWINGS

[0014] By describing the embodiments of the present application in more detail in conjunction with the accompanying drawings, the above and other purposes, features and advantages of the present application will become more apparent. The accompanying drawings are used to provide a further understanding of the embodiments of the present application and constitute a part of the specification. Together with the embodiments of the present application, they are used to explain the present application and do not constitute a limitation of the present application. In the accompanying drawings, the same reference numerals generally represent the same components or steps.

[0015] Figure 1 The figure illustrates a flow chart of a switch control method of a timing controller according to an embodiment of the present application.

[0016] Figure 2 The figure shows a flow chart of the timing controller automatically controlling the opening and closing of the gate based on the control mode and the control parameters after receiving an injection signal sent by an injection molding machine according to an embodiment of the present application.

[0017] Figure 3 The figure illustrates a flow chart of adjusting the frequency of a clock crystal oscillator based on the ambient temperature data collected by the temperature sensor according to an embodiment of the present application. DETAILED DESCRIPTION

[0018] Below, the exemplary embodiments according to the present application will be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments of the present application, and it should be understood that the present application is not limited to the exemplary embodiments described here.

[0019] Figure 1The diagram shows a flow chart of a switch control method of a timing controller according to the present application, wherein the switch control method of the timing controller comprises the following steps: S1, electrically connecting the timing controller to a power supply, and turning on the timing controller through an ON / OFF key so that the timing controller is in a standby state; S2, receiving a control mode selected by a user, and receiving control parameters input by a user; S3, determining a type of injection signal input based on a type of an injection molding machine; S4, determining a type of output voltage based on a type of an electromagnetic valve; S5, after receiving an injection signal emitted by an injection molding machine, the timing controller automatically controls the opening and closing of a gate based on the control mode and the control parameters, wherein the timing controller adjusts the frequency of a clock crystal oscillator based on ambient temperature data collected by a temperature sensor to compensate for clock drift.

[0020] In step S1, the timing controller is electrically connected to the power supply, and the timing controller is turned on by the ON / OFF key so that the timing controller is in a standby state. Specifically, the timing controller is designed with one or more power interfaces for connecting to different types of power supplies such as AC220V, DC24V, etc. These interfaces not only need to meet safety standards, such as overvoltage protection, short circuit protection, etc., but also need to ensure good contact with the power supply to prevent unstable power supply caused by poor contact. Once the power cable is inserted into the power interface of the timing controller and ensures a firm connection, the first step of the electrical connection is completed. Next, when the power connection is completed, the device is started by pressing the ON / OFF key on the timing controller. This button is actually a mechanical button, which contains a set of circuits inside, which can change the state of the circuit when pressed. Specifically, when the user presses the ON / OFF key, it triggers a switch action, which can connect the power management module on the main control board, thereby activating the system initialization program. In this process, the power management module is responsible for monitoring whether the input voltage is stable, and after detecting the appropriate voltage level, gradually powering each subsystem, including but not limited to the microprocessor, memory, and various sensor interfaces. This gradual power-on method can prevent instantaneous large currents from damaging electronic components, and also help reduce electromagnetic interference (EMI) and improve system stability.

[0021] With the stable supply of power, the timing controller enters the standby state. At this time, a series of operations will be performed inside the timing controller. First, the microprocessor starts to load the pre-stored firmware code, which contains the operating system kernel and all necessary drivers to manage and coordinate the communication between various hardware components. Then, the system will check its own health, such as whether the memory is working properly, whether the sensor has abnormal readings, etc. These are to ensure that all functions can operate as expected once the working mode is officially entered. In addition, in the standby state, the timing controller will maintain a low power consumption level, only maintaining the most basic monitoring activities, waiting to receive further instructions from the user or the occurrence of specific events, such as the arrival of injection molding signals.

[0022] In step S2, a control mode selected by a user is received, and control parameters input by a user are received. That is, the diversity and complexity of the injection molding process, as well as the different requirements for product quality and production efficiency are taken into account. In practical applications, different injection molding products, mold designs, and material properties may require different gate opening and closing logics to ensure the best molding effect. Therefore, providing a variety of control modes can meet these diverse needs, so that the timing controller can more flexibly adapt to various injection molding tasks and achieve higher precision and efficiency.

[0023] In one example, the control mode includes a two-stage timing control mode and a four-stage timing control mode. Among them, the two-stage timing control mode is suitable for those application scenarios that are relatively simple but have high requirements for time control. In this mode, the user only needs to set two parameters, the delay time and the gate opening time, to meet the basic time control requirements. This simplified design reduces the difficulty of operation and is particularly suitable for small or standardized production environments, where the injection molding process is relatively simple and does not require too much complex adjustment. For example, on some small plastic product production lines, the use of a two-stage timing control mode can quickly adjust the equipment to adapt to frequently changing product types while ensuring the quality consistency of each product.

[0024] However, for more complex and changeable injection molding processes, the four-stage timing control mode provides more sophisticated time management capabilities. The four-stage timing control mode not only includes all the parameters in the two-stage mode, but also adds four additional time period settings: the first delay time, the first gate opening time, the second delay time, and the second gate opening time. For example, in a typical four-stage control scenario, T1 and T3 are delay time periods, which are mainly used to set the length of time during the gate closing period; while T2 and T4 correspond to the gate opening period, which are used to control the speed and amount of material injection. This design allows users to make subtle adjustments for different process stages to better match specific injection molding conditions. For example, in the production process of large injection molded parts or multi-cavity molds, due to the presence of multiple gates and long cooling time, the use of the four-stage timing control mode can help optimize the material flow throughout the injection molding cycle, reduce the occurrence of defects such as bubbles and shrinkage, and improve the yield rate.

[0025] Based on this, in a specific example, when the control mode is a two-stage timing control mode, the control parameters include timing resolution, delay time and gate opening time; when the control mode is a four-stage timing control mode, the control parameters include timing resolution, a first delay time, a first gate opening time, a second delay time and a second gate opening time.

[0026] Specifically, in the four-stage timing control mode, the dual conversion of delay-open and open-delay is involved, and there is a significant correlation between these two state transitions. In the embodiment of the present application, especially when it comes to delay-open-delay control of multiple gates, a suspend-activate-suspend state transition mechanism is used for control.

[0027] For the suspend-activate state transition, the suspend state is read and the activate state is written at the same time, that is, the open state is written while the delay state is read, and it is detected whether the read delay state and the written open state have the same state ID, that is, the same controlled subject. Thus, in response to the read delay state and the written open state originating from the same subject, the delay state interrupt is turned on, for example, the delay state is added to the interrupt instance, and the open state interrupt is turned off, for example, the open state is taken out from the interrupt instance.

[0028] Similarly, for the activation-suspend state transition, the activation state is read and the suspend state is written at the same time, that is, the delay state is written while the open state is read, and it is simultaneously detected whether the read open state and the written delay state have the same state ID, that is, the same controlled subject. Thus, in response to the fact that the read open state and the written delay state originate from the same subject, the open state interrupt is turned on, for example, the open state is re-added to the interrupt instance, and the delay state interrupt is turned off, for example, the delay state is taken out of the interrupt instance.

[0029] In a more specific example, the timing control card has two sets of control programs built in, namely, two-stage timing control mode and four-stage timing control mode. The factory default setting is two-stage timing control mode. Users can select and adjust these control modes and their related parameters through specific operation steps to meet different production needs.

[0030] When the timing control card is powered on, the user can press and hold the SET key and the up key for 2 seconds at the same time. At this time, the upper display will display "-TD-", and the lower display will display the current control mode: "-yvd0-" (indicating two-stage timing control mode) or "-165-" (indicating four-stage timing control mode). By pressing the up key or the down key, the user can choose to switch to "-yvd0-" (two-stage timing control mode) or "-165-" (four-stage timing control mode). Once the desired control mode is selected, press and hold the SET key for 1 second to exit the parameter setting mode and save the changes.

[0031] For two-stage timing control mode, users can enter parameter setting mode by pressing and holding the SET key for 1 second. At this time, the upper display will display "AB" and the lower display will display the current mode (A or B). Users can switch the mode to A or B by pressing the up or down key, and press the SET key again for 1 second to exit parameter setting and save the changes. In order to select the timing resolution, users can click the SET key once after entering the parameter setting mode. At this time, the upper display will display "dot" and the lower display will display the current resolution (0.01 or 0.1). Users can adjust the resolution to 0.1 or 0.01 by pressing the up or down key, and then press and hold the SET key for 1 second to exit parameter setting and save the changes. The delay time setting is achieved by entering the parameter setting mode and clicking the SET key twice. At this time, the upper display will display "delt" and the lower display will display the current delay time. Users can adjust the delay time by pressing the up or down key, and finally press and hold the SET key for 1 second to exit parameter setting and save the changes. The gate opening time setting requires the user to click the SET key 3 times after entering the parameter setting mode. At this time, the upper display will display "opnt" and the lower display will display the current opening time. The user can adjust the opening time by pressing the up or down key. Similarly, press and hold the SET key for 1 second to exit the parameter setting and save the changes. It should be noted that this setting menu can only be operated when the B mode is selected.

[0032] For the four-stage timing control mode, the user can also enter the parameter setting mode by pressing and holding the SET key for 1 second. At this time, the upper display will display "AB" and the lower display will display the current mode (A or B). The user can switch the mode to A or B by pressing the up or down key, and press the SET key again for 1 second to exit the parameter setting and save the changes. The method for selecting the timing resolution is the same as the two-stage timing control mode: after entering the parameter setting mode, the user clicks the SET key once, the upper display will display "dot", and the lower display will display the current resolution (0.01 or 0.1). The user can adjust the resolution to 0.1 or 0.01 by pressing the up or down key, and then press and hold the SET key for 1 second to exit the parameter setting and save the changes. The delay time T1 setting is to click the SET key twice after entering the parameter setting mode. At this time, the upper display will display "T1" and the lower display will display the current delay time. The user can adjust the delay time by pressing the up or down key, and finally press and hold the SET key for 1 second to exit the parameter setting and save the changes. The gate opening time T2 setting requires the user to click the SET key 3 times after entering the parameter setting mode. At this time, the upper display will display "T2" and the lower display will display the current opening time. The user can adjust the opening time by pressing the up or down key. Similarly, press and hold the SET key for 1 second to exit the parameter setting and save the changes. The delay time T3 setting requires the user to click the SET key 4 times after entering the parameter setting mode. At this time, the upper display will display "T3" and the lower display will display the current delay time. The user can adjust the delay time by pressing the up or down key, and finally press and hold the SET key for 1 second to exit the parameter setting and save the changes. The gate opening time T4 setting requires the user to click the SET key 5 times after entering the parameter setting mode. At this time, the upper display will display "T4" and the lower display will display the current opening time. The user can adjust the opening time by pressing the up or down key, and finally press and hold the SET key for 1 second to exit the parameter setting and save the changes.

[0033] In addition, providing multiple control modes can also enhance the compatibility and scalability of the system. With the continuous improvement of industrial automation level and technological progress, new injection molding technologies and materials are constantly emerging, which requires the control system to have sufficient flexibility to cope with changes. By introducing different control modes, the timing controller can adapt to the requirements of new models of injection molding machines or new processes only through software updates or parameter adjustments without changing the hardware structure.

[0034] Furthermore, during the entire parameter input process, the timing controller also provides a real-time feedback mechanism, that is, whenever the user modifies a parameter, the latest set value will be immediately displayed on the screen, allowing the user to understand the current status in a timely manner. In addition, in order to avoid data loss due to unexpected situations, the system will automatically save the new settings after each effective change to ensure that even emergencies such as power outages will not affect the existing configuration. At the same time, in order to ensure safety and stability, all input parameters will be verified by the system to ensure that they meet the preset range and logical conditions. If any abnormal values ​​are detected, the system will issue a warning to remind the user to recheck the input to prevent problems caused by incorrect configuration.

[0035] In step S3, based on the type of injection molding machine, the type of injection signal input is determined. Specifically, the timing controller has a variety of input interfaces to adapt to different types of injection molding machines. It should be understood that there are significant differences between different manufacturers and models of injection molding machines, especially in terms of signal output standards. Some older or specific brands of injection molding machines may use analog voltages (such as 0-10VDC) as injection signals, while modern equipment prefers digital signals (such as 24VDC switching signals or 220VAC switching signals). In addition, some injection molding machines provide pulse width modulation (PWM) signals or other forms of coded signals. These diverse signal types mean that the timing controller must have the ability to identify and adapt to various input signals to ensure that the instructions from the injection molding machine can be correctly parsed. If the timing controller cannot accurately understand the received signal, it may cause errors in the timing of gate opening and closing, thereby affecting the quality and production efficiency of the product.

[0036] Therefore, in order to adapt to different manufacturers and models of injection molding machines, the timing controller is designed to support multiple input interfaces so as to be compatible with the signals from different types of injection molding machines. In a specific example, the timing controller supports multiple forms of injection molding signal input, such as 24VDC, 220VAC, and switch signals. Users can select the appropriate signal input method according to the type of injection molding machine used, and complete the corresponding configuration through simple jumper cap settings. For example, for 24VDC signal input, the user needs to short-circuit the two jumper caps at positions 1, 2, and 3 of the first socket (JP1 socket), and the second socket (JP2 socket) remains suspended; for 220VAC signal input, the connection method of the first socket needs to be adjusted; if it is a switch signal input, the connection of the second socket should be adjusted. This flexible hardware design enables the timing controller to be widely compatible with various common injection molding machine models on the market without being limited to specific brands or models. At the same time, it also allows users to quickly switch different signal input types by adjusting external connections without changing the internal circuit.

[0037] When the interface is ready, the application will also start the initialization program to verify the validity of the input signal. Specifically, after receiving the injection signal, the timing controller will perform a preliminary verification of the signal to check whether it meets the preset standard format and logical conditions. For example, for a 24VDC switching signal, the system may check whether the level change of the signal is in line with expectations; for a 220VAC signal, it will focus on the quality of the voltage waveform and frequency stability.

[0038] In step S4, the type of output voltage is determined based on the type of solenoid valve. It should be understood that factors such as electromagnetic interference (EMI) and power supply fluctuations may affect the normal operation of electrical equipment. For the timing controller, selecting the correct output voltage type can effectively reduce the risk caused by voltage mismatch. For example, when using a 24V DC solenoid valve, the timing controller will output a 24V DC level at a predetermined time point to open or close the solenoid valve; if it is a 220V AC solenoid valve, it will output a 220V AC level at the same time point. Such output control not only ensures that the solenoid valve can work normally, but also avoids the risk of equipment damage caused by excessively high or low voltage, thereby improving the stability and reliability of the entire system.

[0039] In a specific example, the corresponding configuration can be completed through a simple jumper cap setting. Specifically, for a 24V DC solenoid valve, the user needs to short-circuit the 1st and 3rd positions of the third socket (JP3 socket) with two jumper caps, and keep the fourth socket (JP4 socket) and the fifth socket (JP5 socket) floating; for a 220V AC solenoid valve, the connection method of the fifth socket should be adjusted, that is, short-circuit its 1st and 3rd positions, and keep the third and fourth sockets floating; if it is a switch output, the connection of the fourth socket needs to be adjusted. This flexible hardware design enables the timing controller to be widely compatible with various solenoid valves commonly found on the market without being restricted to specific brands or models. At the same time, it also allows users to quickly switch different output voltage types by adjusting external connections without changing the internal circuit.

[0040] In step S5, after receiving the injection signal sent by the injection molding machine, the timing controller automatically controls the opening and closing of the gate based on the control mode and the control parameters, wherein the timing controller adjusts the frequency of the clock crystal oscillator based on the ambient temperature data collected by the temperature sensor to compensate for the clock drift.

[0041] It should be understood that the injection molding process has extremely high requirements for time control, especially for the opening and closing timing of the gate. The opening and closing of the gate directly affects the injection speed, pressure distribution, and the quality and output of the final product. Therefore, the timing controller must be able to accurately respond to the instructions from the injection molding machine and perform corresponding actions according to the pre-set control mode and parameters. In this way, it can be ensured that each injection cycle can be controlled with the most accurate time, so as to achieve consistency and efficiency. For example, in a multi-cavity mold or a multi-stage injection molding process, the injection time, pressure, temperature and other conditions of each stage are different. In order to achieve precise control of these nuances, the timing controller needs to have highly flexible time management capabilities. Users can choose a two-stage timing control mode or a four-stage timing control mode according to the specific injection molding machine type, and set key parameters such as delay time and open time for each stage. Doing so not only helps to optimize the material flow during the injection molding cycle, reduce the occurrence of defects such as bubbles and shrinkage, but also improves the yield rate and reduces the scrap rate. However, there are inevitably some factors in the industrial environment that will affect the clock crystal oscillator, causing its output frequency to drift. This drift directly affects the time accuracy of the timing task, which in turn affects the product quality. For example, in a high temperature environment, the frequency of the crystal oscillator may increase, causing the system to think that the time elapsed is longer than it actually is; while in a low temperature environment, the opposite is true. To avoid this, the timing controller uses an advanced temperature compensation mechanism.

[0042] In one example, if Figure 2 As shown, after receiving the injection signal sent by the injection molding machine, the timing controller automatically controls the opening and closing of the gate based on the control mode and the control parameters, including: S51, after receiving the injection signal, the timing controller preliminarily verifies the injection signal to check whether the injection signal meets the preset standard format and logical conditions; S52, after determining that the injection signal meets the preset standard format and logical conditions, loads the control mode and the control parameters; S53, based on the ambient temperature data collected by the temperature sensor, adjusts the frequency of the clock crystal oscillator; S54, based on the frequency of the clock crystal oscillator, determines the current determined time point as the starting time of the timing task; S55, based on the control parameters, creates a timing task instance to obtain a queue of timing task instances; S56, executes the queue of the timing task instance to automatically control the opening and closing of the gate.

[0043] In step S51, after receiving the injection molding signal, the timing controller performs a preliminary verification of the injection molding signal to check whether the injection molding signal conforms to the preset standard format and logical conditions. It should be understood that the injection molding signal needs to ensure that only signals that conform to the preset standard format and logical conditions will be used to start subsequent timing tasks. For example, in some cases, the injection molding machine may send an error signal due to a malfunction or other abnormal situation. If all signals are accepted without discrimination, the timing controller may respond incorrectly, thereby affecting the entire production process and even causing equipment damage. Therefore, by strictly checking the received injection molding signal, such problems can be effectively prevented from occurring, thereby improving the reliability and safety of the system.

[0044] In a specific example, the timing controller will first perform a level detection on the received injection signal to confirm whether its voltage level is within the preset range. For example, for a 24V DC signal, the system will check whether the high level of the signal is stable between 20V and 28V, and whether the low level is close to 0V. Such detection can eliminate false triggers caused by power supply fluctuations or line noise. Next, the timing controller will measure the pulse width of the signal to ensure that it conforms to the standard format sent by the injection molding machine. Normally, the injection molding machine will send a pulse signal with a certain width to indicate the start time of injection, and this pulse width value is pre-defined. If the received signal pulse width does not match the preset value, it will be regarded as an invalid signal and ignored.

[0045] In addition, the timing controller will verify the logical conditions of the signal. Specifically, the interval time and sequence relationship between multiple consecutive pulses are checked. For example, in some complex multi-stage injection molding processes, the injection molding machine may continuously send multiple different types of signals to indicate different operation stages. The timing controller needs to ensure that these signals arrive in the correct order and the interval time between each signal is within the allowable range. Doing so not only ensures the validity of the signal, but also enhances the anti-interference ability of the system. In order to achieve the above verification function, a special signal processing module is integrated into the timing controller. This module is responsible for real-time monitoring of the state changes of the input port and checks each signal one by one according to the preset standard format and logical conditions. Once a signal that does not meet the requirements is found, the system will immediately stop further processing and record relevant error information for reference by maintenance personnel. On the contrary, if the signal passes all verification steps, it will be considered valid and trigger subsequent operations, such as loading control modes and parameters, starting timed tasks, etc.

[0046] In step S52, once the confirmation signal is valid, the timing controller will load the control mode and related parameters pre-set by the user. These parameters may include delay time, opening time, etc., which directly determine the specific timing of gate opening and closing. For the two-stage timing control mode, the user sets the delay time and gate opening time; for the four-stage timing control mode, the first delay time, the first gate opening time, the second delay time and the second gate opening time need to be additionally configured. This multi-stage time management method greatly improves the adaptability and controllability of the system, so that even complex and changeable injection molding tasks can be handled with ease.

[0047] In a specific example, under the two-stage control mode, the timing controller supports two different working modes: simple delay control (A working mode) and delay plus open time control (B working mode). The specific operating logic of these two modes is as follows: In simple delay control (A working mode), after receiving the injection molding signal, the gate is closed during the delay time (T1). Once the delay time ends, the gate opens and remains open until the injection molding time signal ends. For example, if the injection molding time is 10 seconds and the delay time is set to 3 seconds, the gate will open 3 seconds after receiving the injection molding signal, and will last for 7 seconds before finally closing. This mode is suitable for scenarios where the gate operation needs to be started after a certain delay to ensure that the material has enough time to prepare for injection into the mold. In delay plus open time control (B working mode), after receiving the injection molding machine signal, the gate remains closed during the delay time (T1). After the delay time ends, the gate opens and remains open according to the set open time (T2); after the open time ends, the gate begins to close and remains closed. For example, if the injection time is 10 seconds, the delay time is 2 seconds, and the open time is 5 seconds, then when the injection signal is received and the delay is 2 seconds, the gate opens and remains open for 5 seconds before closing. This mode provides more precise time control and is suitable for situations where precise control of the gate opening and closing timing is required.

[0048] In a specific example, for the four-stage control mode, each mode contains four stages of time control (T1, T2, T3, T4) to achieve more complex process requirements. In a specific example, the A working mode (timing cycle control) under the four-stage control mode means that once the control card starts the injection cycle, it will strictly execute the four stages in sequence according to the set timing time until the entire four-stage set time is completed, regardless of whether the injection time signal exists, it will follow the preset schedule. For example, the gate is closed in the T1 stage, the gate is opened in the T2 stage, the gate is closed again in the T3 stage, and the gate is opened again in the T4 stage, and finally the gate is closed after all stages are completed. In contrast, the B working mode (signal trigger control) under the four-stage control mode is more flexible. In this mode, when the injection time signal disappears, no matter which time period the control card is in, its timing working cycle will end immediately and the gate will also be closed. For example, at any stage, if the injection time signal ends early, the current timing cycle will end immediately and the gate will be closed. This mode allows the system to dynamically adjust according to the actual production situation, improving the ability to respond to emergencies.

[0049] In step S53, in order to ensure the accurate execution of the timing task, the timing controller adjusts the frequency of the internal clock crystal oscillator according to the ambient temperature data collected by the temperature sensor. This is because in an industrial environment, changes in ambient temperature will have a significant impact on the clock crystal oscillator, causing its output frequency to drift. If not compensated, this drift will directly affect the time accuracy of the timing task, and thus affect the quality of the product. For example, in a high temperature environment, the frequency of the crystal oscillator may increase, causing the system to believe that the time elapsed is longer than it actually is; while in a low temperature environment, the situation is just the opposite. To avoid this situation, the timing controller adopts an advanced temperature compensation mechanism.

[0050] In one example, if Figure 3 As shown, based on the ambient temperature data collected by the temperature sensor, the frequency of the clock crystal oscillator is adjusted, including: S531, obtaining the ambient temperature values ​​of multiple sampling points collected by the temperature sensor; S532, calculating the average of the ambient temperature values ​​of the multiple sampling points as the current ambient temperature value; S533, determining the actual clock frequency value based on the current ambient temperature value; S534, calculating the difference between the actual clock frequency value and the ideal clock frequency to obtain an error signal; S535, inputting the error signal into a PID controller to obtain a frequency control signal, and the frequency control signal is used to adjust the frequency of the clock crystal oscillator.

[0051] Specifically, the built-in temperature sensor samples the ambient temperature at a preset time interval (for example, once per second). This time interval depends on the balance between the required accuracy and response speed. In order to reduce noise interference and improve the accuracy of the measurement, the timing controller may use the average of multiple samples as the current temperature reading, which can obtain more stable and reliable temperature information. The timing controller then stores the temperature data over a period of time, which not only helps to establish a historical record of temperature change trends, but can also be used to detect abnormal conditions or predict future temperature trends.

[0052] Based on the temperature-frequency relationship curve provided by the manufacturer or obtained through experimental calibration, the timing controller can convert the current temperature into a corresponding temperature compensation coefficient. This curve describes the change in the frequency of the clock crystal oscillator at different temperatures. With the arrival of new temperature data, the temperature compensation coefficient will also be updated in real time to ensure that it always reflects the latest temperature status. In one example, determining the actual clock frequency value based on the current ambient temperature value includes: obtaining a temperature-frequency relationship curve; searching the temperature-frequency relationship curve for a clock frequency value corresponding to the current ambient temperature value as the actual clock frequency value.

[0053] In this way, the timing controller can always maintain high-precision time measurement capabilities even if the ambient temperature changes. At the same time, this dynamic adjustment mechanism can not only effectively cope with short-term temperature fluctuations, but also adapt to long-term environmental changes to ensure the long-term stability of the system. For example, in an industrial environment, due to the heat generated by the operation of the equipment or other factors that cause the temperature to rise or fall slowly, this mechanism can ensure that the clock frequency remains within an ideal range, thereby maintaining the accuracy of the timing task.

[0054] However, relying solely on the lookup table cannot completely eliminate the impact of clock drift, because the temperature changes in actual applications are often continuous and complex. For this reason, the timing controller also introduces a PID controller to further optimize the clock frequency adjustment process. The PID controller is a classic feedback control system that is widely used in various automation fields. It continuously monitors the difference between the actual clock frequency and the ideal clock frequency (that is, the error signal), and adjusts the output signal accordingly to eventually reach a stable state. In this case, the role of the PID controller is to generate a frequency control signal based on the calculated error signal to adjust the frequency of the clock crystal oscillator.

[0055] In one example, the error signal is input into a PID controller to obtain a frequency control signal, and the frequency control signal is used to adjust the frequency of the clock crystal oscillator, including: determining a frequency proportional gain part; determining a frequency integral gain part; determining a frequency differential gain part; adding the frequency proportional gain part, the frequency integral gain part and the frequency differential gain part to obtain a frequency increment; generating the frequency control signal based on the frequency increment, and the frequency control signal is a PWM signal.

[0056] Specifically, the PID controller obtains two key values: one is the ideal clock frequency (i.e., the expected frequency at standard temperature), and the other is the actual clock frequency calculated based on the current temperature coefficient. The ideal clock frequency is usually the frequency value calibrated by the manufacturer before leaving the factory under standard environmental conditions (such as 25°C). The actual clock frequency is calculated by the real-time temperature data collected by the built-in temperature sensor and the pre-stored temperature-frequency relationship curve. Subtract the actual value from the ideal value to obtain an error signal. This error represents the degree to which the current clock frequency deviates from the ideal state. For example, if the ideal frequency is 16MHz, but the actual frequency becomes 15.9MHz due to changes in ambient temperature, the error is 0.1MHz. This error signal is the basic input of the PID controller and is used for subsequent adjustment calculations.

[0057] Next, the proportional part of the PID controller acts directly on the error, and its output is proportional to the error size. This means that if the error is large, the output will be correspondingly large, and vice versa. Proportional control can provide immediate corrective action, helping to quickly reduce the error. However, proportional control alone may not completely eliminate the steady-state error (i.e., the residual error after a long period of operation) because proportional control only corrects the error at the current moment, without considering the historical accumulated errors. Therefore, the PID controller also introduces an integral part, which considers the cumulative effect of all errors over a period of time in the past. The integral part attempts to eventually reach a state of zero error by gradually increasing or decreasing the output. Integral control can effectively solve the steady-state error problem that may occur in proportional control and ensure accuracy in long-term operation. However, too high an integral gain may cause the system to become unstable and oscillate. In addition, the derivative part focuses on the rate of change of the error, that is, the speed at which the current error changes compared to the previous moment. It can help the system predict future errors and react in advance, thereby speeding up the system's response and suppressing oscillations. Derivative control helps to achieve a smooth adjustment process and avoid oscillations caused by overcorrection.

[0058] Furthermore, the three control methods of proportional, integral and differential are combined. Each part has its own unique gain coefficient (Kp, Ki, Kd), which determines the degree of influence of each on the total output. The key to comprehensive adjustment is to find the appropriate Kp, Ki and Kd values, which is an iterative process involving experimental testing, observing behavior and making subtle adjustments according to specific application scenarios. Good parameter settings can enable the system to reach the required clock frequency quickly and stably. The output value calculated according to the above PID formula is the clock frequency increment that needs to be adjusted . This increment is expressed as: ;in, is the error signal, is the error signal, is the variable within the integration interval. This formula combines the contributions of the proportional, integral, and differential parts to determine the final frequency increment. Finally, the calculated frequency increment is applied to the internal clock generator to adjust its operating frequency. At the same time, considering the actual limitations of the hardware, each adjustment will be made in the smallest adjustable unit to ensure that the adjusted frequency is as close to the target value as possible without exceeding the range. For example, if the clock crystal oscillator supports adjustment in units of 1kHz, the calculated frequency increment will be rounded to the nearest integer multiple of 1kHz.

[0059] After each adjustment, a short-cycle high-precision counter is used to measure the new clock frequency to confirm whether it meets expectations. This step is to verify the effectiveness of the adjustment and provide feedback for further optimization. The high-precision counter can complete multiple measurements in a short period of time to ensure the accuracy of the results. In long-term operation, even if each adjustment is small, there may be a problem of error accumulation. Therefore, the system also needs to monitor this potential error and make corrections in a timely manner, such as recalibration or adjustment of PID parameters. To achieve this, the system can regularly record the frequency deviation over a period of time and trigger an automatic calibration procedure when necessary to ensure that the clock frequency is always in the best state.

[0060] In another preferred embodiment, as described above, in the actual four-stage timing control mode, it is usually necessary to ensure the total gate opening time. Therefore, when the first gate opening time plus the second gate opening time are determined, there will be a first delay state interruption instance time T1, a first open state interruption instance time T2 and a second delay state interruption instance time T3. In order to achieve more accurate control of state-related tasks in the interruption instance, it is expected to calibrate the proportional gain coefficient of the PID controller in this way. , integral gain coefficient and the differential gain coefficient .

[0061] Specifically, the proportional gain coefficient is calibrated based on the interrupt instance task ratio, that is, the proportional parameter ,but .

[0062] For the integral gain coefficient, based on the proportional parameter and the integral relationship, we have .

[0063] And for the differential coefficient, according to the differential relationship based on the proportional parameter, we have ,in and They are all weighted parameters related to the natural frequency of the clock crystal oscillator, which improves the error behavior of the PID controller's queue response adaptability to the interrupt instance, thereby obtaining the control accuracy of the PID controller under nonlinearity.

[0064] In step S54, the crystal oscillator reaches the ideal frequency after temperature compensation. The next key step is to generate an accurate timestamp as the starting time of the timing task. This timestamp is not just a simple count value, but the result of multiple layers of calibration and verification. Specifically, the timing controller uses a high-precision counter to track each pulse generated by the crystal oscillator and converts it into time units (such as milliseconds or microseconds). At the same time, the system will periodically synchronize with an external standard time source (such as a GPS clock or other network time protocol server) to ensure that the local timestamp is consistent with the global standard time. When receiving a valid injection signal from the injection molding machine, the timing controller will immediately record the timestamp at this time and use it as the current determined time point.

[0065] In step S55 and step S56, based on the generated timestamp, the timing controller creates a timed task instance according to the control parameters. Each instance contains a specific execution time and an operation instruction, such as opening or closing a solenoid valve. In order to ensure that these tasks can be carried out strictly according to the predetermined schedule, the timing controller adopts a scheduling mechanism called "event-driven". Under this mechanism, whenever a preset time point is reached, the corresponding timed task will be triggered and executed. Specifically, the timing controller maintains a queue of timed task instances and processes these tasks in chronological order. When the preset time point is reached, the timing controller takes out the corresponding timed task instance from the queue and performs the corresponding action according to the operation instruction therein, such as sending a signal to the solenoid valve to control the opening and closing of the gate. This "event-driven" scheduling mechanism ensures that all timed tasks can be executed at the correct time point, thereby achieving precise control of the opening and closing of the gate.

[0066] The present invention has the following advantages: High-precision time control: By using advanced temperature compensation mechanism and PID algorithm to dynamically adjust the frequency of the clock crystal oscillator, it is ensured that the timing controller can maintain highly stable timing performance under various temperature conditions. This high-precision time control is crucial for production processes with extremely high time requirements such as injection molding, and can significantly improve product quality and production efficiency.

[0067] Flexible task scheduling mechanism: Based on the generated timestamp, the timing controller will create a scheduled task instance according to the control parameters, and adopt an "event-driven" scheduling mechanism to ensure that each task can be executed strictly according to the predetermined schedule. This mechanism not only improves the flexibility of production, but also enhances the adaptability of the system, allowing users to flexibly configure delay time and open time according to different production process requirements, thereby achieving more sophisticated time control.

[0068] Powerful adaptive capability: The system supports multiple control modes (such as two-stage timing control mode and four-stage timing control mode), and allows users to adjust task priorities or add new task instances according to actual conditions. This design not only solves the limitations of the original control system, but also reserves sufficient expansion space for new equipment and technologies that may be introduced in the future, ensuring the long-term applicability and upgrade potential of the system.

[0069] The basic principles of the present application are described above in conjunction with specific embodiments. However, it should be noted that the advantages, strengths, effects, etc. mentioned in the present application are only examples and not limitations, and it cannot be considered that these advantages, strengths, effects, etc. are required by each embodiment of the present application. In addition, the specific details disclosed above are only for the purpose of illustration and ease of understanding, not for limitation, and the above details do not limit the present application to being implemented by adopting the above specific details.

[0070] The block diagrams of the devices, apparatuses, equipment, and systems involved in this application are only illustrative examples and are not intended to require or imply that they must be connected, arranged, and configured in the manner shown in the block diagram. As will be appreciated by those skilled in the art, these devices, apparatuses, equipment, and systems can be connected, arranged, and configured in any manner. Words such as "including", "comprising", "having", etc. are open words, referring to "including but not limited to", and can be used interchangeably with them. The words "or" and "and" used here refer to the words "and / or" and can be used interchangeably with them, unless the context clearly indicates otherwise. The words "such as" used here refer to the phrase "such as but not limited to", and can be used interchangeably with them.

[0071] It should also be noted that in the apparatus, device and method of the present application, each component or each step can be decomposed and / or recombined. Such decomposition and / or recombination should be regarded as equivalent solutions of the present application.

[0072] The above description of the disclosed aspects is provided to enable any person skilled in the art to make or use the present application. Various modifications to these aspects will be readily apparent to those skilled in the art, and the general principles defined herein may be applied to other aspects without departing from the scope of the present application. Therefore, the present application is not intended to be limited to the aspects shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.

[0073] The above description has been given for the purpose of illustration and description. In addition, this description is not intended to limit the embodiments of the present application to the forms disclosed herein. Although multiple example aspects and embodiments have been discussed above, those skilled in the art will recognize certain variations, modifications, changes, additions and sub-combinations thereof.

Claims

1. A switch control method of a timing controller, characterized in that: include: The timing controller is electrically connected to a power source, and the timing controller is turned on by an ON / OFF key so that the timing controller is in a standby state; Receiving a control mode selected by a user and receiving a control parameter input by a user; determining a type of injection signal input based on a type of the injection molding machine; Based on the type of the solenoid valve, the type of output voltage is determined; after receiving the injection signal sent by the injection molding machine, the timing controller automatically controls the opening and closing of the gate based on the control mode and the control parameters, wherein the timing controller adjusts the frequency of the clock crystal oscillator based on the ambient temperature data collected by the temperature sensor to compensate for the clock drift.

2. The switch control method of the timing controller according to claim 1, characterized in that: The control mode includes a two-stage timing control mode and a four-stage timing control mode.

3. The switch control method of the timing controller according to claim 2, characterized in that: When the control mode is a two-stage timing control mode, the control parameters include timing resolution, delay time and gate opening time; when the control mode is a four-stage timing control mode, the control parameters include timing resolution, first delay time, first gate opening time, second delay time and second gate opening time.

4. The switch control method of the timing controller according to claim 1, characterized in that: After receiving the injection signal sent by the injection molding machine, the timing controller automatically controls the opening and closing of the gate based on the control mode and the control parameters, including: after receiving the injection signal, the timing controller preliminarily verifies the injection signal to check whether the injection signal meets the preset standard format and logical conditions; after determining that the injection signal meets the preset standard format and logical conditions, loads the control mode and the control parameters; based on the ambient temperature data collected by the temperature sensor, adjusts the frequency of the clock crystal oscillator; based on the frequency of the clock crystal oscillator, determines the current determined time point as the starting time of the timing task; based on the control parameters, creates a timing task instance to obtain a queue of timing task instances; executes the queue of timing task instances to automatically control the opening and closing of the gate.

5. The switch control method of the timing controller according to claim 4, characterized in that: Based on the ambient temperature data collected by the temperature sensor, the frequency of the clock crystal oscillator is adjusted, including: obtaining ambient temperature values ​​of multiple sampling points collected by the temperature sensor; calculating the average of the ambient temperature values ​​of the multiple sampling points as the current ambient temperature value; determining the actual clock frequency value based on the current ambient temperature value; calculating the difference between the actual clock frequency value and the ideal clock frequency to obtain an error signal; inputting the error signal into a PID controller to obtain a frequency control signal, and the frequency control signal is used to adjust the frequency of the clock crystal oscillator.

6. The switch control method of the timing controller according to claim 5, characterized in that: The actual clock frequency value is determined based on the current ambient temperature value, including: obtaining a temperature-frequency relationship curve; and searching the temperature-frequency relationship curve for a clock frequency value corresponding to the current ambient temperature value as the actual clock frequency value.

7. The switch control method of the timing controller according to claim 6, characterized in that: The error signal is input into a PID controller to obtain a frequency control signal, and the frequency control signal is used to adjust the frequency of the clock crystal oscillator, including: determining a frequency proportional gain part; determining a frequency integral gain part; determining a frequency differential gain part; adding the frequency proportional gain part, the frequency integral gain part and the frequency differential gain part to obtain a frequency increment; generating the frequency control signal based on the frequency increment, and the frequency control signal is a PWM signal.

8. The switch control method of the timing controller according to claim 6, characterized in that: The frequency determining proportional gain part, the frequency determining integral gain part and the frequency determining differential gain part include: extracting the first delay state interruption instance time, the first open state interruption instance time and the second delay state interruption instance time; calculating the first proportional parameter and the second proportional parameter based on the first delay state interruption instance time, the first open state interruption instance time and the second delay state interruption instance time; and adjusting the proportional gain coefficient, the integral gain coefficient and the differential gain coefficient based on the first proportional parameter and the second proportional parameter.

Citation Information

Patent Citations

  • Time-keeping method of time synchronization device

    CN103269262A

  • Output time sequence self-adaptive adjustment method of an image size conversion module and system thereof

    CN113645497A

  • Glue injection control method based on multiple groups of PID (Proportion Integration Differentiation)

    CN118721650A

  • Multi-point glue feeding mold with timing sequence valve needle opening and closing function

    CN118789765A

  • Device capable of realizing closed-loop temperature compensation of clock crystal oscillator based on high-frequency crystals

    CN202059372U

Cited By

  • Large-gradient long inclined shaft concrete conveying system

    CN120537573A

  • A concrete conveying system for long inclined shafts with steep slopes

    CN120537573B