Stainless steel wire duct automatic welding device and automatic welding control method
By applying artificial fish school algorithm in the automatic welding device of stainless steel wire trough, the problem of relying on artificial technology for welding quality and efficiency is solved, an efficient and stable welding process is achieved, and the welding quality and production efficiency are improved.
Patent Information
- Application Number
- CN202510252061.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-05
- Publication Date
- 2025-04-29
AI Technical Summary
In the prior art, welding quality and production efficiency mainly rely on the technology and experience of the welder, and are greatly affected by human and environmental factors, resulting in unstable welding quality, especially in harsh environments, which will have great harm to the health of operators.
The automatic welding device of stainless steel wire trough is adopted, and the parameters of PID control are optimized in combination with artificial fish school algorithms to achieve stable speed of the welding torch motor during welding, and improve welding quality and efficiency.
Through the automatic welding device, the welding quality, production efficiency and welding uniformity are improved, manual intervention is reduced, and the harm to operators is reduced. The device is small in size, low in power consumption and good stability.
Smart Images

Figure CN119897649A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of electric railway automatic devices, relates to an automatic welding device for stainless steel wire troughs, and also relates to a control method for automatic welding using the automatic welding device for stainless steel wire troughs. Background Art
[0002] The automatic ticket vending and checking system (AFC system for short) uses welding to connect stainless steel wire ducts during subway construction, which has high requirements for welding process and quality, and the waterproof level is not less than IPX7 and the air tightness is high. Manual welding is generally used, and the welding quality and production efficiency mainly depend on the welder's skills and experience, which are greatly affected by human factors. Poor welding quality will cause the wire duct to be damaged. The wire duct is in a humid and harsh environment underground for a long time. If there is a welding quality problem, it will affect the safe operation of the power line in the wire duct. As an important load link in the power system, the failure of subway rail transit will have a significant impact on the safe operation of the power system. In addition, the welding working environment is generally poor, and the harmful smoke, noise and arc light generated during the operation will have an adverse effect on the operator's body. Because workers are disturbed by working conditions and their own factors, it is difficult to ensure the quality and speed of work.
[0003] Considering that the railway department still relies on manual welding for cable ducts, the welding quality is difficult to guarantee and the welding efficiency is low. Using automatic cable duct welding equipment is an effective means to ensure welding quality and safe operation of power lines. Especially in some narrow spaces, automatic cable duct welding equipment can effectively improve welding quality, production efficiency and save labor costs, while also ensuring welding uniformity and consistency and stability of welding quality. Summary of the invention
[0004] The purpose of the present invention is to provide an automatic welding device for stainless steel wire ducts, which solves the problem that welding quality and production efficiency mainly depend on the skills and experience of welders and are greatly affected by human factors and environmental factors.
[0005] The second object of the present invention is to provide a control method for automatic welding using the above-mentioned stainless steel wire trough automatic welding device.
[0006] The first technical solution adopted by the present invention is an automatic welding device for stainless steel wire trough, comprising a support bracket, a mechanical motion unit is provided on the support bracket, a welding unit is connected to the mechanical motion unit, and a welding gun is provided on the welding unit; A control platform is also provided on the supporting bracket, and a control unit is provided in the control platform. The control unit is electrically connected to the mechanical motion unit, and the control unit is signal-connected to the welding unit.
[0007] The present invention is also characterized in that: The mechanical motion unit is two moving sliders respectively arranged on both sides of the supporting bracket, and the first ball screw and the second ball screw are respectively threaded through the two moving sliders. The supporting bracket is also provided with a first positioning motor and a second positioning motor that cooperate with the first ball screw and the second ball screw. The first ball screw is connected to the output shaft of the first positioning motor through a coupling, and the second ball screw is connected to the output shaft of the second positioning motor through a coupling. The welding unit is connected to the two moving sliders respectively.
[0008] The welding unit includes an annular track, the two ends of which are respectively connected to two moving slide blocks, a matching rack is provided on the annular track, a mounting plate is fixed on the side wall of the rack, a signal receiving unit and a welding gun moving motor are also provided on the mounting plate, the output shaft of the welding gun moving motor rotates and penetrates the mounting plate and is connected to a gear, the gear is meshed with the rack, a buckle is also provided on the mounting plate, and the welding gun is set in the buckle; The signal receiving unit is signal-connected to the control unit, and the signal receiving unit is electrically connected to the welding gun motion motor.
[0009] Slide grooves are respectively arranged on both sides of the supporting bracket, and two moving slide blocks are respectively slidably arranged in the corresponding slide grooves.
[0010] Universal wheels are respectively arranged at the bottom ends of the four corners of the supporting bracket.
[0011] The control unit includes a switching power supply, which is electrically connected to an STM32 single-chip microcomputer. The STM32 single-chip microcomputer is respectively connected to two stepper motor drivers through a level conversion chip, and the two stepper motor drivers are respectively connected to a first positioning motor and a second positioning motor.
[0012] The second technical solution adopted by the present invention is a control method for automatic welding, which is performed using the above-mentioned stainless steel wire trough automatic welding device. The specific method is as follows: Step 1: Move the automatic welding device to the vicinity of the wire trough to be welded, and fix the welding gun on the buckle; Step 2: Support the wire duct to be welded at a suitable height, pass it through the circular track and align the weld; Step 3: Use the artificial fish school algorithm to optimize the motor speed parameters of the PID control, summarize the fish school movement behavior related to the optimization, find the fish school position, and control the motor speed to maintain a rated value; Step 4: Press the start button to start automatic welding, and stop working after welding all four sides of the weld.
[0013] The present invention is also characterized in that: The specific method of step 3 is: Step 3.1: Initialize a certain number of artificial fish. The position of each fish represents a set of PID controller parameters. K p, K i , K d , thereby controlling the speed of the welding gun motion motor, with parameters generated randomly or set based on prior knowledge; Step 3.2, setting foraging behavior, aggregation behavior, random behavior and tail-chasing behavior for the artificial fish; Step 3.3, evaluate the position of each artificial fish using the objective function, update the position of each fish according to the set behavior rules, until the maximum number of iterations is reached, and output the optimal parameters; Step 3.4: The selected optimal parameters are used as the final PID controller parameters. The controller receives the expected control value, obtains the current actual output value of the controlled object through the feedback link, compares the expected control value with the actual output value, obtains the error signal as input, makes inferences and decisions based on the control rules pre-stored in the knowledge base, and acts on the welding gun motion motor to achieve control of the welding speed during the welding process.
[0014] The specific method of step 3.2 is: The P, I, and D parameters in the welding gun motor speed control are defined as the spatial position of individual fish. , Gen is the number of iterations, Mg is the maximum number of iterations; the inverse of the product integral of the square of the stepper motor speed error and time (ISAE) during the simulation process is used as the performance index; this performance index can measure the control effect, and with the accumulation of time, it is more sensitive to larger errors. Z is the objective function;
[0015] Artificial fish i The individual status is X i , each state represents the PID control parameters of the welding gun motion motor, and ultimately controls the speed of the welding gun motion motor. The food concentration at the current position, i.e., the objective function, is Z = f ( X i ), W represents the artificial fish sensing distance, that is, the trial range of the motor PID parameters. The motor speed is set according to the actual welding speed, that is, the appropriate sensing distance is set so that the welding device can quickly stabilize near the rated speed during operation; X i,next is the state of the artificial fish at the next moment, each of which represents the new PID parameters of the welding gun motion motor at the next moment, and S represents the maximum step length of the artificial fish movement, that is, the maximum step length when selecting the new PID parameters of the welding gun motion motor; δ is the crowding factor; R is a (0, 1) random number, a isX i Random unit vectors of the same dimension need to be defined for various behaviors of artificial fish; Foraging behavior: The current state of the artificial fish is X i , represents the PID control parameters of the welding gun motion motor, and randomly selects a state within its sensing distance W X j ,like Y i < Y j , indicating that the welding gun motion motor control of the automatic welding device is more stable under the new parameters, then move forward a random distance in this direction; if the condition is not met, reselect the state X j , which means a new PID control parameter of the welding gun motion motor is selected until a suitable one is selected. X j , or perform random behavior after the selection times N reaches the limit times try_N. The selection times are set to a value according to the actual welding requirements. The appropriate value helps to improve the speed of welding completion. The mathematical expression is: ; Random behavior: As a supplement to foraging behavior, when the individual does not meet the foraging behavior conditions, it performs random movement, and its mathematical expression is: ; Aggregation behavior: The number of other individuals in the artificial fish's current neighborhood and central location ,like , indicating that there are more food in the center and it is not too crowded, which means that the PID parameters selected within this range have a better control effect on the welding gun motion motor and are closer to the expected rated speed. If it moves a random distance toward the center, it will perform foraging behavior otherwise. The mathematical expression is: ; Tail-chasing behavior: The artificial fish searches for other individuals with the highest food concentration in the current neighborhood ,like , it indicates If there is a high concentration of food and the surrounding area is not too crowded, Move a random distance in the direction, otherwise perform foraging behavior, the mathematical expression is: ; K p , K i , K dThe solution space is based on the PID parameters adjusted by the ZN method, and τ is taken as 0.04. .
[0016] The specific method of step 3.3 is: After setting parameters and initializing, simulating aggregation, random, tail-chasing and foraging behaviors, select the optimal behavior to execute, calculate the objective function value, evaluate the PID control effect through the set objective function value, and record the optimal value; after a behavior selection, the fish school will get a fish school state, which represents the selected PID control parameters. K p , K i , K d , compare the function value with the optimal value, record the optimal value, and then repeat the next cycle until the maximum number of iterations is completed and the optimal solution is output K p , K i , K d ,Through the optimal solution, the speed of the welding gun movement motor can be controlled during the welding process and the speed can be kept stable.
[0017] The beneficial effects of the present invention are: (1) The automatic welding device for stainless steel wire ducts for subways of the present invention is mainly composed of a welding gun, a circular welding track, a stepping motor and a control platform. The operator places the device on the ground, passes the wire duct to be welded through the circular track, places it at a suitable height and aligns the weld seam. After starting, efficient welding of the weld seams around the wire duct can be achieved, thereby improving welding quality, production efficiency and saving labor costs, and also ensuring welding uniformity and consistency and stability of welding quality; (2) The automatic welding device for stainless steel trunking in subways of the present invention has small size, low power consumption and good stability, which solves the problem that the quality and production efficiency of manual welding in the past mainly depend on the skills and experience of the welder and are greatly affected by human factors and environmental factors; (3) The present invention uses an artificial fish school algorithm to optimize the parameters of the PID control of the automatic welding device, so that the welding speed of the device remains stable during the welding process, thereby improving the welding quality. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 This is a schematic diagram of the overall structure of the automatic welding device for subway stainless steel wire ducts of the present invention; Figure 2 This is a front view of the overall structure of the automatic welding device for subway stainless steel wire duct of the present invention; Figure 3It is a top view of the overall structure of the automatic welding device for stainless steel wire ducts for subways of the present invention; Figure 4 This is a right side view of the overall structure of the automatic welding device for subway stainless steel wire duct of the present invention; Figure 5 It is a schematic diagram of the structure of the connection between the welding gun and the annular track in the automatic welding device for stainless steel wire trough of the present invention; Figure 6 It is a pin diagram of the main chip and the motor control circuit in the automatic welding device for stainless steel wire trough of the present invention; Figure 7 This is the overall working flow chart of the automatic welding device for stainless steel wire trough of the present invention; Figure 8 The present invention discloses a flow chart for optimizing the motor PID parameters of the automatic welding device for stainless steel wire troughs.
[0019] In the figure, 1. welding gun movement motor, 2. welding gun, 3. circular track, 4. first positioning motor, 5. first ball screw, 6. second positioning motor, 7. second ball screw, 8. control platform, 9. supporting bracket, 10. universal wheel, 11. signal receiving unit. DETAILED DESCRIPTION
[0020] The present invention is described in detail below with reference to the accompanying drawings and specific embodiments.
[0021] Stainless steel wire duct automatic welding device, such as Figure 1 As shown, it includes a support bracket 9, and universal wheels 10 are respectively provided at the bottom ends of the four corners of the support bracket 9 to facilitate movement. A mechanical motion unit is provided on the support bracket 9. The main function of the mechanical motion unit is to drive the welding gun to move back and forth according to the position of the weld. A welding unit is connected to the mechanical motion unit, and a welding gun 2 is provided on the welding unit. The welding unit can realize the surrounding movement of the welding gun 2 on the outer wall of the wire slot, and the welding unit automatically outputs wire to realize welding of the weld.
[0022] A control platform 8 is also provided on the support bracket 9, and a control unit is provided in the control platform 8. The control unit is electrically connected to the mechanical motion unit, and the control unit is also connected to the welding unit signal. When working, the control unit controls the welding gun 2 to move to the welding position, which is convenient for accurate welding and improves the welding quality. The control unit adopts a PID parameter optimization based on an artificial fish school algorithm to reduce the impact and optimize the welding effect.
[0023] The specific structure is: Figure 2 , 3As shown, the mechanical motion unit is two motion sliders respectively arranged on both sides of the support bracket 9, and the specific structure is: slide grooves are respectively provided on both sides of the support bracket 9, and the two motion sliders are respectively slidably arranged in the corresponding slide grooves, and the first ball screw 5 and the second ball screw 7 are respectively threaded through the two motion sliders, that is, the two motion sliders can move back and forth with the rotation of the first ball screw 5 and the second ball screw 7, and the support bracket 9 is also provided with a first positioning motor 4 and a second positioning motor 6 that cooperate with the first ball screw 5 and the second ball screw 7, the first ball screw 5 is connected to the output shaft of the first positioning motor 4 through a coupling, and the second ball screw 7 is connected to the output shaft of the second positioning motor 6 through a coupling, and the welding unit is connected to the two motion sliders respectively.
[0024] When in use, the control unit controls the first positioning motor 4 and the second positioning motor 6 to rotate synchronously, driving the first ball screw 5 and the second ball screw 7 to rotate, and the two moving sliders move accordingly, thereby driving the welding unit to move to the welding seam position.
[0025] like Figure 4 , 5 As shown, the welding unit includes an annular track 3, the two ends of the annular track 3 are respectively connected to two moving sliders, a matching rack is provided on the annular track 3, a mounting plate is fixed on the side wall of the rack, a signal receiving unit 11 and a welding gun motion motor 1 are also provided on the mounting plate, the output shaft of the welding gun motion motor 1 rotates through the mounting plate and is connected to a gear, the gear is meshed with the rack, a buckle is also provided on the mounting plate, and the welding gun 2 is arranged in the buckle. In the present application, the welding gun 2 is installed in the buckle in various ways, and the angle and height of the welding gun 2 can be adjusted, which belongs to the prior art and will not be described in detail here.
[0026] The signal receiving unit 11 is signal-connected to the control unit, and the signal receiving unit 11 is electrically connected to the welding gun motion motor 1 . The control unit sends the rotation speed and welding speed of the welding gun motion motor 1 to the signal receiving unit 11 via wireless transmission.
[0027] When in use, the signal receiving unit 11 controls the welding gun movement motor 1 to work after receiving the signal sent by the control unit. The welding gun movement motor 1 drives the gear to rotate, thereby driving the welding gun 2 on the mounting plate to move and carry out welding work.
[0028] like Figure 6 As shown, the control unit includes a switching power supply, which is electrically connected to an STM32 single-chip microcomputer. The STM32 single-chip microcomputer is connected to two stepper motor drivers respectively after a level conversion chip. The two stepper motor drivers are respectively connected to the first positioning motor 4 and the second positioning motor 6. The control unit also sends a signal to a signal receiving unit 11, and the signal receiving unit 11 is connected to the welding gun motion motor 1.
[0029] The operator places the device on the ground, passes the wire duct to be welded through the circular track 3, props it up with a bracket, places it at a suitable height, aligns the weld, and clamps it with the help of auxiliary tools. After starting, efficient welding of the welds around the wire duct can be achieved, and the work stops after completing one circle of welding.
[0030] The welding gun motion motor 1 and the welding gun 2 are both connected to an external power source through electric wires, and the external power source supplies power to them.
[0031] The automatic welding control method is performed using the above-mentioned stainless steel wire trough automatic welding device, such as Figure 7 As shown, the specific method is as follows: Step 1: Move the automatic welding device to the vicinity of the wire trough to be welded, and fix the welding gun on the buckle; Step 2: Support the wire duct to be welded at a suitable height, pass it through the circular track and align the weld; Step 3: Figure 8 As shown in the figure, the artificial fish school algorithm is used to optimize the motor speed parameters of PID control, summarize the fish school movement behavior related to optimization, find the fish school position, and finally control the motor speed to maintain a rated value. Finding the optimal fish school position means finding the optimal K p , K i , K d Three parameters are used to control the motor speed, and the speed is adjusted and controlled during the welding process.
[0032] The specific method is: Step 3.1: Initialize a certain number of artificial fish. The position of each fish represents a set of PID controller parameters. K p , K i , K d , thereby controlling the speed of the welding gun motion motor 1, the parameters can be randomly generated or set based on prior knowledge; Step 3.2: Set foraging, aggregation, randomization, and tail-chasing behaviors for the artificial fish. During the optimization process, foraging behavior helps find a better solution, aggregation behavior can explore the surrounding area and avoid local optimality, and tail-chasing behavior can accelerate convergence.
[0033] The specific method is: define the P, I, and D parameters in the speed control of the welding gun motion motor 1 as the spatial position of the individual fish , Gen is the number of iterations, Mg is the maximum number of iterations; the inverse of the product integral of the square of the stepper motor speed error and time (ISAE) during the simulation process is used as the performance index; this performance index can measure the control effect, and with the accumulation of time, it is more sensitive to larger errors. Z is the objective function; (1) Artificial fish i The individual status is X i , each state represents the PID control parameters of the welding gun motion motor 1, and finally controls the speed of the welding gun motion motor 1. The food concentration at the current position, i.e., the objective function, is Z = f ( X i ), W represents the artificial fish sensing distance, that is, the trial range of the motor PID parameters. The motor speed is set according to the actual welding speed, that is, the appropriate sensing distance is set so that the welding device can quickly stabilize near the rated speed during operation; X i,next is the state of the artificial fish at the next moment, each of which represents the new PID parameters of the welding gun motion motor 1 at the next moment, and S represents the maximum step length of the artificial fish movement, that is, the maximum step length when selecting the new PID parameters of the welding gun motion motor 1; δ is the crowding factor. Setting an appropriate crowding factor can avoid premature or local convergence of PID parameter optimization and improve the accuracy of maintaining the speed of the welding gun motor 1 during welding. R is a (0, 1) random number, and a is X i Random unit vectors of the same dimension need to be defined for various behaviors of artificial fish; Foraging behavior: The current state of the artificial fish is X i , represents the PID control parameters of the welding gun motion motor 1, and randomly selects a state within its sensing distance W X j ,like Y i < Y j , indicating that the control of the welding gun motion motor 1 of the automatic welding device is more stable under the new parameters, then move forward a random distance in this direction; if the condition is not met, reselect the state X j , which means a new PID control parameter of welding gun motion motor 1 is selected until a suitable one is selected. X j , or perform random behavior after the selection times N reaches the limit times try_N. The selection times are set to a value according to the actual welding requirements. The appropriate value helps to improve the speed of welding completion. The mathematical expression is: (2); Random behavior: As a supplement to foraging behavior, when the individual does not meet the foraging behavior conditions, it performs random movement. Its mathematical expression is: (3); Aggregation behavior: The number of other individuals in the artificial fish's current neighborhood and central location ,like , indicating that there is more food in the center and it is not too crowded, which means that the PID parameters selected within this range have a better control effect on the welding gun motion motor 1, which is closer to the expected rated speed. If it moves a random distance toward the center, it will perform foraging behavior otherwise. The mathematical expression is: (4); Tail-chasing behavior: The artificial fish searches for other individuals with the highest food concentration in the current neighborhood ,like , it indicates If there is a high concentration of food and the surrounding area is not too crowded, Move a random distance in the direction, otherwise perform foraging behavior, the mathematical expression is: (5); K p , K i , K d The solution space is based on the PID parameters tuned by the ZN method, and τ is taken as 0.04.
[0034] (6).
[0035] Step 3.3, evaluate the position of each artificial fish using the objective function, update the position of each fish according to the set behavior rules until the maximum number of iterations is reached, and output the optimal parameters; the specific method is: after setting the parameters and initializing, simulating aggregation, random, tail-chasing and foraging behaviors, select the optimal behavior to execute, calculate the objective function value, evaluate the PID control effect through the set objective function value, and record the optimal value; after a behavior selection, the fish school will obtain a fish school state, which represents the selected PID control parameters. K p , K i , K d , compare the function value with the optimal value, record the optimal value, and then repeat the next cycle until the maximum number of iterations is completed and the optimal solution is output K p , K i , K dThrough the optimal solution, the speed of the welding gun motion motor 1 can be controlled during the welding process and the speed can be kept stable. This parameter optimization method has a fast convergence speed and is suitable for finding PID parameters under complex working conditions.
[0036] Step 3.4: The selected optimal parameters are used as the final PID controller parameters. The controller receives the expected control value, obtains the current actual output value of the controlled object through the feedback link, compares the expected control value with the actual output value, obtains the error signal as input, makes inferences and decisions based on the control rules pre-stored in the knowledge base, and acts on the welding gun motion motor 1 to achieve control of the welding speed during the welding process.
[0037] Step 4: Press the start button to start automatic welding, and stop working after welding all four sides of the weld.
[0038] The present invention uses PID to control the motor speed, and uses an artificial fish school algorithm to optimize the parameters of the PID control. The artificial fish school algorithm observes the movement law of fish schools in nature and summarizes the fish school movement behaviors related to optimization, including: foraging behavior, grouping behavior, tail-chasing behavior and random behavior. Among them, the foraging behavior lays the foundation for the convergence of the algorithm, the grouping behavior enhances the stability and globality of the algorithm, and the tail-chasing behavior improves the rapidity and globality of the algorithm.
[0039] Example 1 Stainless steel wire duct automatic welding device, such as Figure 1 As shown, it includes a support bracket 9, on which a mechanical motion unit is provided. The main function of the mechanical motion unit is to drive the welding gun to move forward and backward according to the position of the weld. The mechanical motion unit is connected to a welding unit, on which a welding gun 2 is provided. The welding unit can realize the movement of the welding gun 2 around the outer wall of the wire groove, and the welding unit automatically outputs wire to realize welding of the weld.
[0040] A control platform 8 is also provided on the support bracket 9, and a control unit is provided in the control platform 8. The control unit is electrically connected to the mechanical motion unit. The control unit controls the welding gun to move to the welding position to facilitate accurate welding. At the same time, the control unit controls the rotation speed of the welding gun 2 through wireless transmission to improve the welding quality. The control unit uses a PID parameter optimization based on an artificial fish school algorithm to reduce impact and optimize the welding effect.
[0041] The specific structure is: Figure 2 , 3As shown, the mechanical motion unit is two motion sliders respectively arranged on both sides of the support bracket 9, and the specific structure is: slide grooves are respectively provided on both sides of the support bracket 9, and the two motion sliders are respectively slidably arranged in the corresponding slide grooves, and the first ball screw 5 and the second ball screw 7 are respectively threaded through the two motion sliders. The support bracket 9 is also provided with a first positioning motor 4 and a second positioning motor 6 that cooperate with the first ball screw 5 and the second ball screw 7. The first ball screw 5 is connected to the output shaft of the first positioning motor 4 through a coupling, and the second ball screw 7 is connected to the output shaft of the second positioning motor 6 through a coupling, and the welding unit is connected to the two motion sliders respectively.
[0042] Example 2 Stainless steel wire duct automatic welding device, such as Figure 1 As shown, it includes a support bracket 9, on which a mechanical motion unit is provided. The main function of the mechanical motion unit is to drive the welding gun to move forward and backward according to the position of the weld. The mechanical motion unit is connected to a welding unit, on which a welding gun 2 is provided, which can realize the welding gun 2 to move around the outer wall of the wire groove, and at the same time, the welding unit automatically produces wire to weld the weld.
[0043] A control platform 8 is also provided on the support bracket 9, and a control unit is provided in the control platform 8. The control unit is electrically connected to the mechanical motion unit, and the control unit is also connected to the welding unit signal. When working, the control unit controls the welding gun 2 to move to the welding position, which is convenient for accurate welding and improves the welding quality. The control unit adopts a PID parameter optimization based on an artificial fish school algorithm to reduce the impact and optimize the welding effect.
[0044] The specific structure is: Figure 2 , 3 As shown, the mechanical motion unit is two motion sliders respectively arranged on both sides of the support bracket 9, and the specific structure is: slide grooves are respectively provided on both sides of the support bracket 9, and the two motion sliders are respectively slidably arranged in the corresponding slide grooves, and the first ball screw 5 and the second ball screw 7 are respectively threaded through the two motion sliders. The support bracket 9 is also provided with a first positioning motor 4 and a second positioning motor 6 that cooperate with the first ball screw 5 and the second ball screw 7. The first ball screw 5 is connected to the output shaft of the first positioning motor 4 through a coupling, and the second ball screw 7 is connected to the output shaft of the second positioning motor 6 through a coupling, and the welding unit is connected to the two motion sliders respectively.
[0045] like Figure 4 , 5As shown, the welding unit includes an annular track 3, the two ends of the annular track 3 are respectively connected to two moving sliders, a matching rack is provided on the annular track 3, a mounting plate is fixed on the side wall of the rack, a signal receiving unit 11 and a welding gun motion motor 1 are also provided on the mounting plate, the output shaft of the welding gun motion motor 1 rotates through the mounting plate and is connected to a gear, the gear is meshed with the rack, a buckle is also provided on the mounting plate, and the welding gun 2 is arranged in the buckle. In the present application, the welding gun 2 is installed in the buckle in various ways, and the angle and height of the welding gun 2 can be adjusted, which belongs to the prior art and will not be described in detail here.
[0046] The signal receiving unit 11 is signal-connected to the control unit, and the signal receiving unit 11 is electrically connected to the welding gun motion motor 1 . The control unit sends a signal to the signal receiving unit 11 through wireless transmission to control the rotation speed and welding speed of the welding gun motion motor 1 .
[0047] When in use, the signal receiving unit 11 controls the welding gun movement motor 1 to work after receiving the signal sent by the control unit. The welding gun movement motor 1 drives the gear to rotate, thereby driving the welding gun 2 on the mounting plate to move and carry out welding work.
[0048] Example 3 Stainless steel wire duct automatic welding device, such as Figure 1 As shown, it includes a support bracket 9, on which a mechanical motion unit is provided. The main function of the mechanical motion unit is to drive the welding gun to move forward and backward according to the position of the weld. The mechanical motion unit is connected to a welding unit, on which a welding gun 2 is provided, which can realize the welding gun 2 to move around the outer wall of the wire groove, and at the same time, the welding unit automatically produces wire to weld the weld.
[0049] A control platform 8 is also provided on the support bracket 9. A control unit is provided inside the control platform 8. The control unit is electrically connected to the mechanical motion unit, and the control unit is also connected to the welding unit signal.
[0050] like Figure 6 As shown, the control unit includes a switching power supply, which is electrically connected to an STM32 single-chip microcomputer. The STM32 single-chip microcomputer is connected to two stepper motor drivers respectively after a level conversion chip. The two stepper motor drivers are respectively connected to the first positioning motor 4 and the second positioning motor 6. The control unit also sends a signal to a signal receiving unit 11, and the signal receiving unit 11 is connected to the welding gun motion motor 1.
[0051] Example 4 The automatic welding control method is performed using the above-mentioned stainless steel wire trough automatic welding device, such as Figure 7 As shown, the specific method is as follows: Step 1: Move the automatic welding device to the vicinity of the wire trough to be welded, and fix the welding gun on the buckle; Step 2: Support the wire duct to be welded at a suitable height, pass it through the circular track and align the weld; Step 3: Use the artificial fish school algorithm to optimize the motor speed parameters of the PID control, summarize the fish school movement behavior related to the optimization, find the fish school position, and control the motor speed to maintain a rated value; Step 4: Press the start button to start automatic welding, and stop working after welding all four sides of the weld.
[0052] Example 5 The automatic welding control method is performed using the above-mentioned stainless steel wire trough automatic welding device, such as Figure 7 As shown, the specific method is as follows: Step 1: Move the automatic welding device to the vicinity of the wire trough to be welded, and fix the welding gun on the buckle; Step 2: Support the wire duct to be welded at a suitable height, pass it through the circular track and align the weld; Step 3: Figure 8 As shown in the figure, the artificial fish school algorithm is used to optimize the motor speed parameters of PID control, summarize the fish school movement behavior related to optimization, find the fish school position, and finally control the motor speed to maintain a rated value. Finding the optimal fish school position means finding the optimal K p , K i , K d Three parameters are used to control the motor speed, and the speed is adjusted and controlled during the welding process.
[0053] The specific method is: Step 3.1: Initialize a certain number of artificial fish. The position of each fish represents a set of PID controller parameters. K p , K i , K d , thereby controlling the speed of the welding gun motion motor 1, the parameters can be randomly generated or set based on prior knowledge; Step 3.2: Set foraging, aggregation, randomization, and tail-chasing behaviors for the artificial fish. During the optimization process, foraging behavior helps find a better solution, aggregation behavior can explore the surrounding area and avoid local optimality, and tail-chasing behavior can accelerate convergence.
[0054] Step 3.3, evaluate the position of each artificial fish using the objective function, update the position of each fish according to the set behavior rules, until the maximum number of iterations is reached, and output the optimal parameters; Step 3.4: The selected optimal parameters are used as the final PID controller parameters. The controller receives the expected control value, obtains the current actual output value of the controlled object through the feedback link, compares the expected control value with the actual output value, obtains the error signal as input, makes inferences and decisions based on the control rules pre-stored in the knowledge base, and acts on the welding gun motion motor 1 to achieve control of the welding speed during the welding process.
[0055] Step 4: Press the start button to start automatic welding, and stop working after welding all four sides of the weld.
[0056] Example 6 The specific method of step 3.2 in Example 5 is: define the P, I, and D parameters in the speed control of the welding gun motion motor 1 as the spatial position of the individual fish , Gen is the number of iterations, Mg is the maximum number of iterations; the inverse of the product integral of the square of the stepper motor speed error and time (ISAE) during the simulation process is used as the performance index; this performance index can measure the control effect, and with the accumulation of time, it is more sensitive to larger errors. Z is the objective function; (1) Artificial fish i The individual status is X i , each state represents the PID control parameters of the welding gun motion motor 1, and finally controls the speed of the welding gun motion motor 1. The food concentration at the current position, i.e., the objective function, is Y = f ( X i ), W represents the artificial fish sensing distance, that is, the trial range of the motor PID parameters. The motor speed is set according to the actual welding speed, that is, the appropriate sensing distance is set so that the welding device can quickly stabilize near the rated speed during operation; X i,next is the state of the artificial fish at the next moment, each of which represents the new PID parameters of the welding gun motion motor 1 at the next moment, and S represents the maximum step length of the artificial fish movement, that is, the maximum step length when selecting the new PID parameters of the welding gun motion motor 1; δ is the crowding factor. Setting an appropriate crowding factor can avoid premature or local convergence of PID parameter optimization and improve the accuracy of maintaining the speed of the welding gun motion motor 1 during welding. R is a (0, 1) random number, and a is X i Random unit vectors of the same dimension need to be defined for various behaviors of artificial fish; Foraging behavior: The current state of the artificial fish is X i, represents the PID control parameters of the welding gun motion motor 1, and randomly selects a state within its sensing distance W X j ,like Y i < Y j , indicating that the control of the welding gun motion motor 1 of the automatic welding device is more stable under the new parameters, then move forward a random distance in this direction; if the condition is not met, reselect the state X j , which means a new PID control parameter of welding gun motion motor 1 is selected until a suitable one is selected. X j , or perform random behavior after the selection times N reaches the limit times try_N. The selection times are set to a value according to the actual welding requirements. The appropriate value helps to improve the speed of welding completion. The mathematical expression is: (2); Random behavior: As a supplement to foraging behavior, when the individual does not meet the foraging behavior conditions, it performs random movement, and its mathematical expression is: (3); Aggregation behavior: The number of other individuals in the artificial fish's current neighborhood and central location ,like , indicating that there is more food in the center and it is not too crowded, which means that the PID parameters selected within this range have a better control effect on the welding gun motion motor 1, which is closer to the expected rated speed. If it moves a random distance toward the center, it will perform foraging behavior otherwise. The mathematical expression is: (4); Tail-chasing behavior: The artificial fish searches for other individuals with the highest food concentration in the current neighborhood ,like , it indicates If there is a high concentration of food and the surrounding area is not too crowded, Move a random distance in the direction, otherwise perform foraging behavior, the mathematical expression is: (5); K p , K i , K d The solution space is based on the PID parameters tuned by the ZN method, and τ is taken as 0.04.
[0057] (6).
[0058] Example 7 The specific method of step 3.3 in Example 5 is: use the objective function to evaluate the position of each artificial fish, update the position of each fish according to the set behavior rules, until the maximum number of iterations is reached, and output the optimal parameters; the specific method is: after setting the parameters and initializing, simulating the aggregation, random, tail-chasing and foraging behaviors, select the optimal behavior to execute, calculate the objective function value, evaluate the PID control effect by the set objective function value, and record the optimal value; after the fish school has selected a behavior, a fish school state will be obtained, which represents the selected PID control parameters. K p , K i , K d , compare the function value with the optimal value, record the optimal value, and then repeat the next cycle until the maximum number of iterations is completed and the optimal solution is output K p , K i , K d Through the optimal solution, the speed of the welding gun motion motor 1 can be controlled during the welding process and the speed can be kept stable. This parameter optimization method has a fast convergence speed and is suitable for finding PID parameters under complex working conditions.
Claims
1. Automatic welding device for stainless steel wire trough, characterized in that: It comprises a support bracket (9), the support bracket (9) is provided with a mechanical motion unit, the mechanical motion unit is connected to a welding unit, and the welding unit is provided with a welding gun (2); A control platform (8) is also provided on the support bracket (9), and a control unit is provided inside the control platform (8), the control unit is electrically connected to the mechanical motion unit, and the control unit is signal-connected to the welding unit.
2. The automatic welding device for stainless steel wire trough according to claim 1 is characterized in that: The mechanical motion unit is two motion sliders respectively arranged on both sides of the support bracket (9), and the two motion sliders are respectively threaded with a first ball screw (5) and a second ball screw (7). The support bracket (9) is also provided with a first positioning motor (4) and a second positioning motor (6) that cooperate with the first ball screw (5) and the second ball screw (7). The first ball screw (5) is connected to the output shaft of the first positioning motor (4) through a coupling, and the second ball screw (7) is connected to the output shaft of the second positioning motor (6) through a coupling. The welding unit is respectively connected to the two motion sliders.
3. The automatic welding device for stainless steel wire trough according to claim 2 is characterized in that: The welding unit comprises an annular track (3), the two ends of the annular track (3) are respectively connected to two moving slide blocks, the annular track (3) is provided with a matching rack, a mounting plate is fixed to the side wall of the rack, a signal receiving unit (11) and a welding gun moving motor (1) are also provided on the mounting plate, the output shaft of the welding gun moving motor (1) rotates through the mounting plate and is connected to a gear, the gear is meshed with the rack, a buckle is also provided on the mounting plate, and the welding gun (2) is arranged in the buckle; The signal receiving unit (11) is signal-connected to the control unit, and the signal receiving unit (11) is electrically connected to the welding gun motion motor (1).
4. The automatic welding device for stainless steel wire trough according to claim 2 is characterized in that: Slide grooves are respectively provided on both sides of the support bracket (9), and the two moving slide blocks are respectively slidably arranged in the corresponding slide grooves.
5. The automatic welding device for stainless steel wire trough according to claim 1 is characterized in that: Universal wheels (10) are respectively provided at the bottom ends of the four corners of the support bracket (9).
6. The automatic welding device for stainless steel wire trough according to claim 1 is characterized in that: The control unit comprises a switching power supply, the switching power supply is electrically connected to an STM32 single-chip computer, the STM32 single-chip computer is respectively connected to two stepper motor drivers after being connected via a level conversion chip, and the two stepper motor drivers are respectively connected to a first positioning motor (4) and a second positioning motor (6).
7. A control method for automatic welding, characterized in that: The method is carried out by using the automatic welding device for stainless steel wire duct according to any one of claims 1 to 6, and the specific method is as follows: Step 1: Move the automatic welding device to the vicinity of the wire trough to be welded, and fix the welding gun on the buckle; Step 2: Support the wire duct to be welded at a suitable height, pass it through the circular track and align the weld; Step 3: Use the artificial fish school algorithm to optimize the motor speed parameters of the PID control, summarize the fish school movement behavior related to the optimization, find the fish school position, and control the motor speed to maintain a rated value; Step 4: Press the start button to start automatic welding, and stop working after welding all four sides of the weld.
8. The automatic welding control method according to claim 7, characterized in that: The specific method of step 3 is: Step 3.1: Initialize a certain number of artificial fish. The position of each fish represents a set of PID controller parameters. K p , K i , K d , thereby controlling the speed of the welding gun motion motor (1), the parameters of which are randomly generated or set based on prior knowledge; Step 3.2, setting foraging behavior, aggregation behavior, random behavior and tail-chasing behavior for the artificial fish; Step 3.3, evaluate the position of each artificial fish using the objective function, update the position of each fish according to the set behavior rules, until the maximum number of iterations is reached, and output the optimal parameters; Step 3.4: The selected optimal parameters are used as the final PID controller parameters. The controller receives the expected control value, obtains the current actual output value of the controlled object through the feedback link, compares the expected control value with the actual output value, obtains the error signal as input, makes inferences and decisions based on the control rules pre-stored in the knowledge base, and acts on the welding gun motion motor (1) to achieve control of the welding speed during the welding process.
9. The automatic welding control method according to claim 8, characterized in that: The specific method of step 3.2 is: The P, I, and D parameters in the speed control of the welding gun motion motor (1) are defined as the spatial position of the individual fish. , Gen is the number of iterations, Mg is the maximum number of iterations; The performance index is the inverse of the product integral of the square of the stepper motor speed error and time (ISAE) during the simulation process; this performance index can measure the control effect and is more sensitive to larger errors as time accumulates. Z is the objective function; (1) Artificial fish i The individual status is X i , each state represents the PID control parameters of the welding gun motion motor (1), and ultimately controls the speed of the welding gun motion motor (1). The food concentration at the current position, i.e., the objective function, is Z = f ( X i ), W represents the artificial fish sensing distance, that is, the trial range of the motor PID parameters. The motor speed is set according to the actual welding speed, that is, the appropriate sensing distance is set so that the welding device can quickly stabilize near the rated speed during operation; X i,next is the state of the artificial fish at the next moment, each of which represents the new PID parameters of the welding gun motion motor (1) at the next moment, and S represents the maximum step length of the artificial fish movement, that is, the maximum step length when selecting the new PID parameters of the welding gun motion motor (1); δ is the crowding factor; R is a (0, 1) random number, a is X i Random unit vectors of the same dimension need to be defined for various behaviors of artificial fish; Foraging behavior: The current state of the artificial fish is X i , represents the PID control parameters of the welding gun motion motor (1), and randomly selects a state within its sensing distance W X j ,like Y i < Y j , indicating that the control of the welding gun motion motor (1) of the automatic welding device is more stable under the new parameters, then it moves forward a random distance in this direction; if the condition is not met, the state is reselected X j , which means a new PID control parameter of the welding gun motion motor (1) is selected until a suitable one is selected. X j , or perform random behavior after the selection times N reaches the limit times try_N. The selection times are set to a value according to the actual welding requirements. The appropriate value helps to improve the speed of welding completion. The mathematical expression is: (2); Random behavior: As a supplement to foraging behavior, when the individual does not meet the foraging behavior conditions, it performs random movement, and its mathematical expression is: (3); Aggregation behavior: The number of other individuals in the artificial fish's current neighborhood and central location ,like , indicating that there is more food at the center and it is not too crowded, which means that the PID parameters selected within this range have a better control effect on the welding gun motion motor (1). If it is closer to the expected rated speed, it will move forward a random distance to the center, otherwise it will perform foraging behavior. The mathematical expression is: (4); Tail-chasing behavior: The artificial fish searches for other individuals with the highest food concentration in the current neighborhood ,like , it indicates If there is a high concentration of food and the surrounding area is not too crowded, Move a random distance in the direction, otherwise perform foraging behavior, the mathematical expression is: (5); K p , K i , K d The solution space is based on the PID parameters adjusted by the ZN method, and τ is taken as 0.
04. (6)。 10. The automatic welding control method according to claim 9, characterized in that: The specific method of step 3.3 is: After setting parameters and initializing, simulating aggregation, random, tail-chasing and foraging behaviors, select the optimal behavior to execute, calculate the objective function value, evaluate the PID control effect through the set objective function value, and record the optimal value; after a behavior selection, the fish school will get a fish school state, which represents the selected PID control parameters. K p , K i , K d , compare the function value with the optimal value, record the optimal value, and then repeat the next cycle until the maximum number of iterations is completed and the optimal solution is output K p , K i , K d , through the optimal solution, the speed of the welding gun motion motor (1) can be controlled during the welding process and the speed can be kept stable.