14. Robotic Welding

14.1. Setting the welding process parameters

 1/**
 2* @brief Sets the welding process curve parameters.
 3* @param [in] id Welding process number (1-99)
 4* @param [in] startCurrent startCurrent(A)
 5* @param [in] startVoltage startVoltage(V)
 6* @param [in] startTime startTime(ms)
 7* @param [in] weldCurrent weldCurrent(A)
 8* @param [in] weldVoltage Welding voltage (V)
 9* @param [in] endCurrent Welding current(A)
10* @param [in] endVoltage weldVoltage(V)
11* @param [in] endTime Arc recovery time (ms)
12* @return Error code
13*/
14int WeldingSetProcessParam(int id, double startCurrent, double startVoltage, double startTime, double weldCurrent, double weldVoltage, double endCurrent, double endVoltage, double endTime);

14.2. Get weld process curve parameters

 1/**
 2* @brief Get weld process curve parameters.
 3* @param [in] id Welding process number (1-99)
 4* @param [out] startCurrent startCurrent (A)
 5* @param [out] startVoltage startVoltage(V)
 6* @param [out] startTime startTime(ms)
 7* @param [out] weldCurrent weldCurrent(A)
 8* @param [out] weldVoltage Welding voltage (V)
 9* @param [out] endCurrent Welding current(A)
10* @param [out] endVoltage weldVoltage(V)
11* @param [out] endTime Arc recovery time (ms)
12* @return Error code
13*/
14int WeldingGetProcessParam(int id, ref double startCurrent, ref double startVoltage, ref double startTime, ref double weldCurrent, ref double weldVoltage, ref double endCurrent, ref double endVoltage, ref double endTime);

14.3. Setting the weld current in relation to the output analog

New in version C#SDK-v1.0.4.

1/**
2* @brief Set weld current to output analog.
3* @param [in] currentMin Welding current-analog output linear relationship left point current value (A)
4* @param [in] currentMax Welding current - analog output linear relationship right point current value (A)
5* @param [in] outputVoltageMin Welding current - analog output linear relationship left point analog output voltage value (V)
6* @param [in] outputVoltageMax Welding current - analog output linear relationship of the right point analog output voltage value (V)
7* @return Error Code
8*/
9int WeldingSetCurrentRelation(double currentMin, double currentMax, double outputVoltageMin, double outputVoltageMax);

14.4. Set Welding Voltage and Output Analog Relation

New in version C#SDK-v1.0.4.

1/**
2* @brief Set weld voltage to output analog.
3* @param [in] weldVoltageMin weldVoltageMin Welding voltage-analog output linear relationship between the left point weld voltage value (A)
4* @param [in] weldVoltageMax Welding voltage - analog output linear relationship between the right point welding voltage value (A)
5* @param [in] outputVoltageMin Welding voltage-analog output linear relationship left point analog output voltage value (V)
6* @param [in] outputVoltageMax Welding voltage - analog output linear relationship of the right point analog output voltage value (V)
7* @return Error Code
8*/
9int WeldingSetVoltageRelation(double weldVoltageMin, double weldVoltageMax, double outputVoltageMin, double outputVoltageMax);

14.5. Get the relationship between the welding current and the output analog

New in version C#SDK-v1.0.4.

1/**
2* @brief Get weld current to output analog.
3* @param [out] currentMin Welding current-analog output linear relationship of the left point current value (A).
4* @param [out] currentMax Welding current - analog output linear relationship right point current value (A)
5* @param [out] outputVoltageMin Welding current - analog output linear relationship left point analog output voltage value (V)
6* @param [out] outputVoltageMax Welding current - analog output linear relationship between the right point analog output voltage value (V)
7* @return Error Code
8*/
9int WeldingGetCurrentRelation(ref double currentMin, ref double currentMax, ref double outputVoltageMin, ref double outputVoltageMax);

14.6. Get Welding Voltage Relation to Output Analog

New in version C#SDK-v1.0.4.

1/**
2* @brief Get weld voltage to output analog
3* @param [out] weldVoltageMin Welding Voltage - Analog Output Linear Relationship Left Point Welding Voltage Value (A)
4* @param [out] weldVoltageMax Welding Voltage - Analog Output Linear Relationship Welding Voltage Value (A) at the Right Point
5* @param [out] outputVoltageMin Welding voltage-analog output linear relationship left point analog output voltage value (V)
6* @param [out] outputVoltageMax Welding voltage - analog output linear relationship right point analog output voltage value (V)
7* @return Error Code
8*/
9int WeldingGetVoltageRelation(ref double weldVoltageMin, ref double weldVoltageMax, ref double outputVoltageMin, ref double outputVoltageMax);

14.7. Set weld current

New in version C#SDK-v1.0.4.

1/**
2* @brief Set weld current.
3* @param [in] ioType Control IO type 0-control box IO; 1-expansion IO
4* @param [in] current Welding current value (A)
5* @param [in] AOIndex Welding current control box analog output port (0-1)
6* @return Error Code
7*/
8int WeldingSetCurrent(int ioType, double current, int AOIndex);

14.8. Set Welding Voltage

New in version C#SDK-v1.0.4.

1/**
2* @brief Set the solder voltage.
3* @param [in] ioType Control IO type 0-Control box IO; 1-Extension IO
4* @param [in] voltage Welding voltage value (A)
5* @param [in] AOIndex Welding voltage control box analog output port (0-1)
6* @return Error Code
7*/
8int WeldingSetVoltage(int ioType, double voltage, int AOIndex);

14.9. Set the swing parameter

New in version C#SDK-V1.1.3: Web-3.8.2

 1/**
 2* @brief Set the swing parameter
 3* @param [in] weaveNum The configuration number of the weave parameter.
 4* @param [in] weaveType Oscillation type 0-planar triangular oscillation; 1-vertical L-shaped triangular oscillation; 2-clockwise circular oscillation; 3-counterclockwise circular oscillation; 4-planar sinusoidal oscillation; 5-vertical L-shaped sinusoidal oscillation; 6-vertical triangular oscillation; 7-vertical sine wave oscillation
 5* @param [in] weaveFrequency swing frequency (Hz)
 6* @param [in] weaveIncStayTime wait mode 0-cycle without wait time; 1-cycle with wait time
 7* @param [in] weaveRange Weave range (mm)
 8* @param [in] weaveLeftRange vertical triangle swing left chord length (mm)
 9* @param [in] weaveRightRange the length of the right chord of the vertical triangle swing (mm)
10* @param [in] additionalStayTime The stay time of the vertical triangle (mm).
11* @param [in] weaveLeftStayTime weaveLeftStayTime (ms)
12* @param [in] weaveRightStayTime weaveRightStayTime (ms)
13* @param [in] weaveCircleRadio Circle swing-back ratio (0-100%)
14* @param [in] weaveStationary swing position wait, 0 - wait time for position to continue moving; 1 - wait time for position to be stationary
15* @param [in] weaveYawAngle swing direction azimuth (rotation around swing Z-axis), in °.
16* @return Error code
17*/
18int WeaveSetPara(int weaveNum, int weaveType, double weaveFrequency, int weaveIncStayTime, double weaveRange, double weaveLeftRange, double weaveRightRange, int additionalStayTime, int weaveLeftStayTime, int weaveRightStayTime, int weaveCircleRadio, int weaveStationary, double weaveYawAngle, double weaveRotAngle=0);

14.10. Sample code for setting welding parameters

New in version C#SDK-V1.1.3: Web-3.8.2

 1private void button7_Click(object sender, EventArgs e)
 2{
 3   robot.WeldingSetProcessParam(1, 177, 27, 1000, 178, 28, 176, 26, 1000);
 4   robot.WeldingSetProcessParam(2, 188, 28, 555, 199, 29, 133, 23, 333);
 5
 6   double startCurrent = 0;
 7   double startVoltage = 0;
 8   double startTime = 0;
 9   double weldCurrent = 0;
10   double weldVoltage = 0;
11   double endCurrent = 0;
12   double endVoltage = 0;
13   double endTime = 0;
14
15   robot.WeldingGetProcessParam(1, ref startCurrent, ref startVoltage, ref startTime, ref weldCurrent, ref weldVoltage, ref endCurrent, ref endVoltage, ref endTime);
16   Console.WriteLine("the Num 1 process param is " + startCurrent + " " + startVoltage + " " + startTime + " " + weldCurrent + " " + weldVoltage + " " + endCurrent + " " + endVoltage + " " + endTime);
17   robot.WeldingGetProcessParam(2, ref startCurrent, ref startVoltage, ref startTime, ref weldCurrent, ref weldVoltage, ref endCurrent, ref endVoltage, ref endTime);
18   Console.WriteLine("the Num 2 process param is " + startCurrent + " " + startVoltage + " " + startTime + " " + weldCurrent + " " + weldVoltage + " " + endCurrent + " " + endVoltage + " " + endTime);
19
20   int rtn = robot.WeldingSetCurrentRelation(0, 400, 0, 10, 0);
21   Console.WriteLine("WeldingSetCurrentRelation rtn is: " + rtn);
22
23   rtn = robot.WeldingSetVoltageRelation(0, 40, 0, 10, 1);
24   Console.WriteLine("WeldingSetVoltageRelation rtn is: " + rtn);
25
26   double current_min = 0;
27   double current_max = 0;
28   double vol_min = 0;
29   double vol_max = 0;
30   double output_vmin = 0;
31   double output_vmax = 0;
32   int curIndex = 0;
33   int volIndex = 0;
34   rtn = robot.WeldingGetCurrentRelation(ref current_min, ref current_max, ref output_vmin, ref output_vmax, ref curIndex);
35   Console.WriteLine("WeldingGetCurrentRelation rtn is: " + rtn);
36   Console.WriteLine("current min " + current_min + " current max " + current_max + " output vol min " + output_vmin + " output vol max " + output_vmax);
37
38   rtn = robot.WeldingGetVoltageRelation(ref vol_min, ref vol_max, ref output_vmin, ref output_vmax, ref volIndex);
39   Console.WriteLine("WeldingGetVoltageRelation rtn is: " + rtn);
40   Console.WriteLine("vol min " + vol_min + " vol max " + vol_max + " output vol min " + output_vmin + " output vol max " + output_vmax);
41
42   rtn = robot.WeldingSetCurrent(1, 100, 0, 0);
43   Console.WriteLine("WeldingSetCurrent rtn is: " + rtn);
44
45   System.Threading.Thread.Sleep(3000);
46
47   rtn = robot.WeldingSetVoltage(1, 10, 0, 0);
48   Console.WriteLine("WeldingSetVoltage rtn is: " + rtn);
49
50   rtn = robot.WeaveSetPara(0, 0, 2.000000, 0, 10.000000, 0.000000, 0.000000, 0, 0, 0, 0, 0, 60.000000);
51   Console.WriteLine("rtn is: " + rtn);
52
53   robot.WeaveOnlineSetPara(0, 0, 1, 0, 20, 0, 0, 0, 0);
54
55   rtn = robot.WeldingSetCheckArcInterruptionParam(1, 200);
56   Console.WriteLine("WeldingSetCheckArcInterruptionParam    " + rtn);
57   rtn = robot.WeldingSetReWeldAfterBreakOffParam(1, 5.7, 98.2, 0);
58   Console.WriteLine("WeldingSetReWeldAfterBreakOffParam    " + rtn);
59   int enable = 0;
60   double length = 0;
61   double velocity = 0;
62   int moveType = 0;
63   int checkEnable = 0;
64   int arcInterruptTimeLength = 0;
65   rtn = robot.WeldingGetCheckArcInterruptionParam(ref checkEnable, ref arcInterruptTimeLength);
66   Console.WriteLine("WeldingGetCheckArcInterruptionParam  checkEnable  " + checkEnable + "   arcInterruptTimeLength  " + arcInterruptTimeLength);
67   rtn = robot.WeldingGetReWeldAfterBreakOffParam(ref enable, ref length, ref velocity, ref moveType);
68   Console.WriteLine("WeldingGetReWeldAfterBreakOffParam  enable = " + enable + ", length = " + length + ", velocity = " + velocity + ", moveType = " + moveType);
69
70   robot.SetWeldMachineCtrlModeExtDoNum(17);
71   for (int i = 0; i < 5; i++)
72   {
73      robot.SetWeldMachineCtrlMode(0);
74      Thread.Sleep(1000);
75      robot.SetWeldMachineCtrlMode(1);
76      Thread.Sleep(1000);
77   }
78
79}

14.11. Setting the swing parameters on the fly

New in version C#SDK-v1.0.4.

 1/**
 2* @brief Instant setup of swing parameters
 3* @param [in] weaveNum The configuration number of the weave parameter.
 4* @param [in] weaveType Oscillation type 0-planar triangular oscillation; 1-vertical L-shaped triangular oscillation; 2-clockwise circular oscillation; 3-counterclockwise circular oscillation; 4-planar sinusoidal oscillation; 5-vertical L-shaped sinusoidal oscillation; 6-vertical triangular oscillation; 7-vertical sinusoidal oscillation
 5* @param [in] weaveFrequency swing frequency (Hz)
 6* @param [in] weaveIncStayTime wait mode 0-cycle without wait time; 1-cycle with wait time
 7* @param [in] weaveRange Weave range (mm)
 8* @param [in] weaveLeftStayTime weaveLeftStayTime (ms)
 9* @param [in] weaveRightStayTime weaveRightStayTime(ms)
10* @param [in] weaveCircleRadio Circle swing-back ratio (0-100%)
11* @param [in] weaveStationary swing position wait, 0 - wait time for position to continue moving; 1 - wait time for position to be stationary
12* @return error code
13*/
14int WeaveOnlineSetPara(int weaveNum, int weaveType, double weaveFrequency, int weaveIncStayTime, double weaveRange, int weaveLeftStayTime, int weaveRightStayTime, int weaveCircleRadio, int weaveStationary).

14.12. Set parameters for detecting unexpected interruptions of the robot’s welding arc

1/**
2* @brief Setting parameters for detecting unexpected interruptions of a robotic welding arc.
3* @param [in] checkEnable whether or not to enable detection; 0-don't enable; 1-enable
4* @param [in] arcInterruptTimeLength arcInterruptAcknowledgmentTimeLength(ms)
5* @return Error code
6*/
7int WeldingSetCheckArcInterruptionParam(int checkEnable, int arcInterruptTimeLength)

14.13. Get parameters for detecting accidental interruptions of the robot’s welding arc

1/**
2* @brief Get parameters for detecting unexpected interruptions of a robotic welding arc.
3* @param [out] checkEnable Whether to enable detection; 0-don't enable; 1-enable
4* @param [out] arcInterruptTimeLength arcInterruptAcknowledgmentTimeLength(ms)
5* @return Error code
6*/
7int WeldingGetCheckArcInterruptionParam(ref int checkEnable, ref int arcInterruptTimeLength)

14.14. Set the robot welding interruption recovery parameter

1/**
2* @brief Setting the robot weld interrupt recovery parameters
3* @param[in] enable Whether to enable weld interrupt recovery or not.
4* @param[in] length The overlap distance of the weld (mm).
5* @param[in] velocity the speed of the robot to return to the restart point (0-100)
6* @param[in] moveType Robot movement to restart point type; 0-LIN; 1-PTP
7* @return Error code
8*/
9int WeldingSetReWeldAfterBreakOffParam(int enable, double length, double velocity, int moveType)

14.15. Get the robot welding break recovery parameter

1/**
2* @brief Get robot weld interrupt recovery parameters.
3* @param [out] enable Whether to enable weld interrupt recovery.
4* @param [out] length The overlap distance of the weld (mm).
5* @param [out] velocity the speed of the robot to return to the restart point (0-100)
6* @param [out] moveType the way the robot moves to the restart point; 0-LIN; 1-PTP
7* @return Error code
8*/
9int WeldingGetReWeldAfterBreakOffParam(ref int enable, ref double length, ref double velocity, ref int moveType)

14.16. Set welder control mode extension DO port

1/**
2* @brief Set welder control mode extended DO port.
3* @param DONum Welder control mode DO port (0-127)
4* @return Error code
5*/
6int SetWeldMachineCtrlModeExtDoNum(int DONum).

14.17. Set Welding Machine Control Mode

1/**
2* @brief Set welding machine control mode
3* @param [in] mode Welding machine control mode; 0-DC one-knob mode; 1-Pulse one-knob mode; 2-JOB mode; 3-Local control mode; 4-Separate mode; 5-CC/CV mode; 6-TIG; 7-CMT
4* @param [in] ioType Control type; 0-Control box IO; 1-Digital communication protocol (UDP); 2-Digital communication protocol (ModbusTCP)
5* @return Error code
6*/
7public int SetWeldMachineCtrlMode(int mode,int ioType = 1)

14.18. Weld start

New in version C#SDK-v1.0.4.

1/**
2* @brief Welding start
3* @param [in] ioType io type 0-controller IO; 1-extended IO
4* @param [in] arcNum Welder profile number
5* @param [in] timeout Arc start timeout
6* @return Error code
7*/
8int ARCStart(int ioType, int arcNum, int timeout);

14.19. Weld End

New in version C#SDK-v1.0.4.

1/**
2* @brief End of welding.
3* @param [in] ioType io type 0-controller IO; 1-extended IO
4* @param [in] arcNum Welder profile number
5* @param [in] timeout Arc-off timeout timeout
6* @return Error code
7*/
8int ARCEnd(int ioType, int arcNum, int timeout).

14.20. Oscillation start

New in version C#SDK-v1.0.4.

1/**
2* @brief The start of the swing.
3* @param [in] weaveNum Pendulum weld parameter configuration number
4* @return ErrorCode
5*/
6int WeaveStart(int weaveNum).

14.21. WeaveStart(int weaveNum); int WeaveStart(int weaveNum).

New in version C#SDK-v1.0.4.

1/**
2* @brief End of swing
3* @param [in] weaveNum Pendulum weld parameter configuration number
4* @return ErrorCode
5*/
6int WeaveEnd(int weaveNum).

14.22. Forward Wire Feed

New in version C#SDK-v1.0.4.

1/**
2* @brief Forward wire feed
3* @param [in] ioType io type 0-controller IO; 1-extended IO
4* @param [in] wireFeed wire feed control 0-stop wire feed; 1-wire feed
5* @return Error code
6*/
7int SetForwardWireFeed(int ioType, int wireFeed).

14.23. Reverse wire feed

New in version C#SDK-v1.0.4.

1/**
2* @brief Reverse wire feed
3* @param [in] ioType ioType 0-Controller IO; 1-Extended IO
4* @param [in] wireFeed wireFeedControl 0-Stop wire feed; 1-Wire feed
5* @return Error code
6*/
7int SetReverseWireFeed(int ioType, int wireFeed).

14.24. Wire Feed

New in version C#SDK-v1.0.4.

1/**
2* @brief air delivery
3* @param [in] ioType io type 0-controller IO; 1-extended IO
4* @param [in] airControl airControl 0-stop air delivery; 1-feed air
5* @return Error code
6*/
7int SetAspirated(int ioType, int airControl).

14.25. Setting the robot to resume welding after an interruption

1/**
2* @brief Set the robot to resume welding after a weld interruption.
3* @return Error code
4*/
5int WeldingStartReWeldAfterBreakOff()

14.26. Sets the robot to exit welding after a weld break

1/**
2* @brief Set the robot to quit welding after a weld interruption.
3* @return Error code
4*/
5int WeldingAbortWeldAfterBreakOff()

14.27. Code example

 1private void button7_Click(object sender, EventArgs e)
 2{
 3   robot.WeldingSetCurrent(1, 230, 0, 0);
 4   robot.WeldingSetVoltage(1, 24, 0, 1);
 5
 6   DescPose p1Desc = new DescPose(228.879, -503.594, 453.984, -175.580, 8.293, 171.267);
 7   JointPos p1Joint = new JointPos(102.700, -85.333, 90.518, -102.365, -83.932, 22.134);
 8
 9   DescPose p2Desc = new DescPose(-333.302, -435.580, 449.866, -174.997, 2.017, 109.815);
10   JointPos p2Joint = new JointPos(41.862, -85.333, 90.526, -100.587, -90.014, 22.135);
11
12   ExaxisPos exaxisPos = new ExaxisPos(0, 0, 0, 0);
13   DescPose offdese = new DescPose(0, 0, 0, 0, 0, 0);
14
15   robot.MoveJ(p1Joint, p1Desc, 13, 0, 20, 100, 100, exaxisPos, -1, 0, offdese);
16   robot.ARCStart(1, 0, 10000);
17   robot.WeaveStart(0);
18   robot.MoveL (p2Joint, p2Desc, 13, 0, 20, 100, 100, -1, 0, exaxisPos, 0, 0, offdese);
19   robot.ARCEnd(1, 0, 10000);
20   robot.WeaveEnd(0);
21}

14.28. Start of segment welding

New in version C#SDK-v1.0.4.

 1/**
 2* @brief Start of segment welding
 3* @param [in] startDesePos start point Cartesian position
 4* @param [in] endDesePos end point Cartesian position
 5* @param [in] startJPos start point joint position
 6* @param [in] endJPos end point joint position
 7* @param [in] weldLength weldLength (mm)
 8* @param [in] noWeldLength length (mm)
 9* @param [in] weldIOType Weld IO type (0-control box IO; 1-expansion IO)
10* @param [in] arcNum Welder profile number
11* @param [in] weldTimeout start/recovery arc timeout time
12* @param [in] isWeave whether or not to wiggle
13* @param [in] weaveNum weave parameter configuration number
14* @param [in] tool tool number
15* @param [in] user Workpiece number
16* @param [in] vel velocity percentage, range [0~100] * @param [in] acc.
17* @param [in] acc Acceleration percentage, range [0~100], not open yet.
18* @param [in] ovl velocity scaling factor, range [0~100]
19* @param [in] blendR [-1.0]-motion in place (blocking), [0~1000.0]-smoothing radius (non-blocking) in mm
20* @param [in] epos Extended axis position in mm
21* @param [in] search 0-no wire seek, 1-wire seek
22* @param [in] offset_flag 0-no offset, 1-offset in base/work coordinate system, 2-offset in tool coordinate system
23* @param [in] offset_pos Position offset
24* @return Error code
25*/
26int SegmentWeldStart(DescPose startDesePos, DescPose endDesePos, JointPos startJPos, JointPos endJPos, double weldLength, double noWeldLength, int weldIOType, int arcNum, int weldTimeout,bool isWeave, int weaveNum, int tool, int user, float vel, float acc, float ovl, float blendR, ExaxisPos epos, byte search, byte offset_flag, DescPose offset_pos);

14.29. Robot segment welding code example

New in version C#SDK-v1.0.4.

 1private void btnWeldStart_Click(object sender, EventArgs e)
 2{
 3   robot.WeldingSetCurrent(1, 230, 0, 0);
 4   robot.WeldingSetVoltage(1, 24, 0, 1);
 5
 6   DescPose p1Desc = new DescPose(228.879, -503.594, 453.984, -175.580, 8.293, 171.267);
 7   JointPos p1Joint = new JointPos(102.700, -85.333, 90.518, -102.365, -83.932, 22.134);
 8
 9   DescPose p2Desc = new DescPose(-333.302, -435.580, 449.866, -174.997, 2.017, 109.815);
10   JointPos p2Joint = new JointPos(41.862, -85.333, 90.526, -100.587, -90.014, 22.135);
11
12   ExaxisPos exaxisPos = new ExaxisPos(0, 0, 0, 0);
13   DescPose offdese = new DescPose(0, 0, 0, 0, 0, 0);
14
15   int rtn = robot.SegmentWeldStart( p1Desc,  p2Desc,  p1Joint,  p2Joint, 20, 20, 0, 0, 5000, false, 0, 0, 0, 100, 100, 100, -1,  exaxisPos, 0, 0,  offdese);
16   Console.WriteLine("SegmentWeldStart rtn is {0}", rtn);
17}

14.30. Simulate the start of the swing

1/**
2* @brief Simulate swing start
3* @param [in] weaveNum swing parameter number
4* @return ErrorCode
5*/
6int WeaveStartSim(int weaveNum).

14.31. End of swing simulation

1/**
2* @brief Simulate end of swing
3* @param [in] weaveNum swing parameter number
4* @return ErrorCode
5*/
6int WeaveEndSim(int weaveNum).

14.32. Start trajectory detection warning (no motion)

1/**
2* @brief Start trajectory detection warning (no motion).
3* @param [in] weaveNum swing parameter number
4* @return Error code
5*/
6int WeaveInspectStart(int weaveNum).

14.33. End trajectory detection warning (no motion)

1/**
2* @brief End trajectory detection warning (no motion).
3* @param [in] weaveNum swing parameter number
4* @return Error code.
5*/
6int WeaveInspectEnd(int weaveNum).

14.34. Weave fading start

New in version C#SDK-V1.1.3: Web-3.8.2

1/**
2* @brief Swinging gradient start
3* @param [in] weaveChangeFlag 1-change swing parameter; 2-change swing parameter + weld speed
4* @param [in] weaveNum weaveNumber
5* @param [in] velStart Welding start speed, (cm/min)
6* @param [in] velEnd Weld end speed, (cm/min)
7* @return Error code
8*/
9int WeaveChangeStart(int weaveChangeFlag, int weaveNum, double velStart, double velEnd);

14.35. Weave fade end

1/**
2* @brief End of swing gradient
3* @return Error code
4*/
5int WeaveChangeEnd()

14.36. Sample Welding Code for Robot Weave Change

New in version C#SDK-V1.1.3: Web-3.8.2

 1private void btnweld_Click(object sender, EventArgs e)
 2{
 3   DescPose p1Desc = new DescPose(228.879, -503.594, 453.984, -175.580, 8.293, 171.267);
 4   JointPos p1Joint = new JointPos(102.700, -85.333, 90.518, -102.365, -83.932, 22.134);
 5
 6   DescPose p2Desc = new DescPose(-333.302, -435.580, 449.866, -174.997, 2.017, 109.815);
 7   JointPos p2Joint = new JointPos(41.862, -85.333, 90.526, -100.587, -90.014, 22.135);
 8
 9   ExaxisPos exaxisPos = new ExaxisPos(0, 0, 0, 0);
10   DescPose offdese = new DescPose(0, 0, 0, 0, 0, 0);
11
12   robot.MoveJ(p1Joint, p1Desc, 13, 0, 20, 100, 100, exaxisPos, -1, 0, offdese);
13   robot.WeaveStartSim(0);
14   robot.MoveL(p2Joint, p2Desc, 13, 0, 20, 100, 100, -1, 0, exaxisPos, 0, 0, offdese);
15   robot.WeaveEndSim(0);
16   robot.MoveJ(p1Joint, p1Desc, 13, 0, 20, 100, 100, exaxisPos, -1, 0, offdese);
17   robot.WeaveInspectStart(0);
18   robot.MoveL(p2Joint, p2Desc, 13, 0, 20, 100, 100, -1, 0, exaxisPos, 0, 0, offdese);
19   robot.WeaveInspectEnd(0);
20
21   robot.WeldingSetVoltage(1, 19, 0, 0);
22   robot.WeldingSetCurrent(1, 190, 0, 0);
23   robot.MoveL( p1Joint,  p1Desc, 1, 1, 100, 100, 50, -1,  exaxisPos, 0, 0,  offdese);
24   robot.ARCStart(1, 0, 10000);
25   robot.ArcWeldTraceControl(1, 0, 1, 0.06, 5, 5, 60, 1, 0.06, 5, 5, 80, 0, 0, 4, 1, 10, 0, 0);
26   robot.WeaveStart(0);
27   robot.WeaveChangeStart(1, 0, 50, 30);
28   robot.MoveL( p2Joint,  p2Desc, 1, 1, 100, 100, 1, -1,  exaxisPos, 0, 0,  offdese);
29   robot.WeaveChangeEnd();
30   robot.WeaveEnd(0);
31   robot.ArcWeldTraceControl(0, 0, 1, 0.06, 5, 5, 60, 1, 0.06, 5, 5, 80, 0, 0, 4, 1, 10, 0, 0);
32   robot.ARCEnd(1, 0, 10000);
33}

14.37. Extended IO-Configuration of Welder Gas Detection Signal

1/**
2* @brief Extended IO-Configuration Welder Gas Detection Signal
3* @param [in] DONum Gas detection signal extended DO number
4* @return error-code
5*/
6int SetAirControlExtDoNum(int DONum).

14.38. Extended IO-Configuration of the welder arc start signal

1/**
2* @brief Extended IO-Configuration Welder Arc Start Signal
3* @param [in] DONum Welder arc start signal extended DO number
4* @return Error code.
5*/
6int SetArcStartExtDoNum(int DONum).

14.39. Extended IO-Configuring the Welder Reverse Wire Feed Signal

1/**
2* @brief Extended IO-Configuration of the welder reverse wire feed signal.
3* @param [in] DONum Reverse Wire Feed Signal Extension DO Number
4* @return Error code.
5*/
6int SetWireReverseFeedExtDoNum(int DONum).

14.40. Extended IO-Configuration Welder Forward Wire Feed Signal

1/**
2* @brief Extended IO-Configuration of the welder's forward wire feed signal.
3* @param [in] DONum Forward Wire Feed Signal Extension DO Number
4* @return Error code.
5*/
6int SetWireForwardFeedExtDoNum(int DONum);

14.41. Extended IO-Configuration Welder Arc Start Success Signal

1/**
2* @brief Extended IO-Configuration Welder Arc Start Success Signal
3* @param [in] DINum Extended DI number for arc success signaling.
4* @return Error code.
5*/
6int SetArcDoneExtDiNum(int DINum).

14.42. Extended IO-Configuration Welder Ready Signal

1/**
2* @brief Extended IO-Configuration Welder Ready Signal
3* @param [in] DINum Welder ready signal extended DI number
4* @return error-code
5*/
6int SetWeldReadyExtDiNum(int DINum).

14.43. Extended IO-Configure weld interrupt recovery signal

1/**
2* @brief Extended IO-Configuration Weld Interrupt Recovery Signal
3* @param [in] reWeldDINum Resume Weld Signal after Weld Interrupt Extended DI Number
4* @param [in] abortWeldDINum Exit Weld Signal Extended DI Number after a Weld Interrupt
5* @return Error Code
6*/
7int SetExtDIWeldBreakOffRecover(int reWeldDINum, int abortWeldDINum);

14.44. Set Extended IO Weld Signal Code Example

 1private void button51_Click(object sender, EventArgs e)
 2{
 3   robot.SetArcStartExtDoNum(10);
 4   robot.SetAirControlExtDoNum(20);
 5   robot.SetWireForwardFeedExtDoNum(30);
 6   robot.SetWireReverseFeedExtDoNum(40);
 7
 8   robot.SetWeldReadyExtDiNum(50);
 9   robot.SetArcDoneExtDiNum(60);
10   robot.SetExtDIWeldBreakOffRecover(70, 80);
11   robot.SetWireSearchExtDIONum(0, 1);
12}

14.45. Arc tracking control

 1 /**
 2 * @brief Arc tracking control
 3 * @param [in] flag switch, 0-off; 1-on
 4 * @param [in] dalayTime hysteresis time, in ms
 5 * @param [in] isLeftRight left-right deviation compensation
 6 * @param [in] klr left/right adjustment factor (sensitivity)
 7 * @param [in] tStartLr left/right start time cyc
 8 * @param [in] stepMaxLr Maximum compensation in mm per pass * @param [in] stepMaxLr Maximum compensation in mm per pass
 9 * @param [in] sumMaxLr total max compensation mm
10 * @param [in] isUpLow Compensation for up and down deviation
11 * @param [in] kud up/down adjustment factor (sensitivity)
12 * @param [in] tStartUd up/down compensation time cyc
13 * @param [in] stepMaxUd Maximum compensation in mm for each step.
14 * @param [in] sumMaxUd up and down total max. compensation mm
15 * @param [in] axisSelect upper and lower coordinate system selection, 0-swing; 1-tool; 2-base
16 * @param [in] referenceType upper and lower reference current setting mode, 0-feedback; 1-constant
17 * @param [in] referSampleStartUd upper and lower reference current sample start count (feedback), cyc
18 * @param [in] referSampleCountUd upper and lower reference current sampling cycle count (feedback), cyc
19 * @param [in] referenceCurrent upper and lower reference current mA
20 * @param [in] offsetType offset tracking type, 0-no offset; 1-sample; 2-percentage /version 3.7.9
21 * @param [in] offsetParameter offset parameter; sampling (offset sampling start time, default one cycle); percentage (offset percentage (-100 ~ 100)) /version 3.7.9
22 * @return Error code
23 */
24 int ArcWeldTraceControl(int flag, double delaytime, int isLeftRight, double klr, double tStartLr, double stepMaxLr, double sumMaxLr, int isUpLow, double kud, double tStartUd, double stepMaxUd, double sumMaxUd, int axisSelect, int referenceType, double referSampleStartUd, double referSampleCountUd, double referenceCurrent, int offsetType, int offsetParameter).

14.46. Arc tracking AI passband selection

1/**
2* @brief Arc-tracking AI passband selection.
3* @param [in] channel Arc-tracking AI passband selection, [0-3].
4* @return Error code.
5*/
6int ArcWeldTraceExtAIChannelConfig(int channel).

14.47. Arc Trace + Multi-Layer Multi-Channel Compensation on

1/**
2* @brief Arc tracing + multilayer compensation on.
3* @return Error code
4*/
5int ArcWeldTraceReplayStart();

14.48. ArcWeldTrace + MultiLayerMultiChannelCompensation OFF

1/**
2* @brief Arc tracing + multilayer multichannel compensation off .
3* @return Error code
4*/
5int ArcWeldTraceReplayEnd();

14.49. Offset Coordinate Change - Multi-Layer Multi-Pass Welding

 1 /**
 2 * @brief Offset Coordinate Change - Multi-Layer Multi-Pass Weld
 3 * @param [in] pointO Cartesian orientation of datum.
 4 * @param [in] pointX Cartesian position of datum X in offset direction.
 5 * @param [in] pointZ Cartesian position of the datum Z to the offset direction point.
 6 * @param [in] dx x-direction offset (mm)
 7 * @param [in] z offset (mm)
 8 * @param [in] offset around y-axis (°)
 9 * @param [out] Calculation result offset (mm)
10 * @return Error Code
11 */
12int MultilayerOffsetTrsfToBase(DescTran pointO, DescTran pointX, DescTran pointZ, double dx, double dy, double db, ref DescPose offset);

14.50. Multi-layer multi-pass welding arc tracking code example

  1private void button52_Click(object sender, EventArgs e)
  2{
  3   JointPos mulitilineorigin1_joint = new JointPos(-24.090, -63.501, 84.288, -111.940, -93.426, 57.669);
  4   DescPose mulitilineorigin1_desc = new DescPose(-677.559, 190.951, -1.205, 1.144, -41.482, -82.577);
  5
  6   DescTran mulitilineX1_desc = new DescTran();
  7   mulitilineX1_desc.x = -677.556;
  8   mulitilineX1_desc.y = 211.949;
  9   mulitilineX1_desc.z = -1.206;
 10
 11   DescTran mulitilineZ1_desc = new DescTran();
 12   mulitilineZ1_desc.x = -677.564;
 13   mulitilineZ1_desc.y = 190.956;
 14   mulitilineZ1_desc.z = 19.817;
 15
 16   JointPos mulitilinesafe_joint = new JointPos(-25.734, -63.778, 81.502, -108.975, -93.392, 56.021);
 17   DescPose mulitilinesafe_desc = new DescPose(-677.561, 211.950, 19.812, 1.144, -41.482, -82.577);
 18   JointPos mulitilineorigin2_joint = new JointPos(-29.743, -75.623, 101.241, -116.354, -94.928, 55.735);
 19   DescPose mulitilineorigin2_desc = new DescPose(-563.961, 215.359, -0.681, 2.845, -40.476, -87.443);
 20
 21   DescTran mulitilineX2_desc = new DescTran();
 22   mulitilineX2_desc.x = -563.965;
 23   mulitilineX2_desc.y = 220.355;
 24   mulitilineX2_desc.z = -0.680;
 25
 26   DescTran mulitilineZ2_desc = new DescTran();
 27   mulitilineZ2_desc.x = -563.968;
 28   mulitilineZ2_desc.y = 215.362;
 29   mulitilineZ2_desc.z = 4.331;
 30
 31   ExaxisPos epos = new ExaxisPos(0, 0, 0, 0);
 32   DescPose offset = new DescPose(0, 0, 0, 0, 0, 0);
 33
 34   Thread.Sleep(10);
 35   int error = robot.MoveJ( mulitilinesafe_joint,  mulitilinesafe_desc, 13, 0, 10, 100, 100,  epos, -1, 0,  offset);
 36   Console.WriteLine("MoveJ return: {0}", error);
 37
 38   error = robot.MoveL( mulitilineorigin1_joint,  mulitilineorigin1_desc, 13, 0, 10, 100, 100, -1,  epos, 0, 0,  offset, 0, 100);
 39   Console.WriteLine("MoveL return: {0}", error);
 40
 41   error = robot.MoveJ(mulitilinesafe_joint, mulitilinesafe_desc, 13, 0, 10, 100, 100, epos, -1, 0, offset);
 42   Console.WriteLine("MoveJ return: {0}", error);
 43
 44   error = robot.MoveL(mulitilineorigin2_joint, mulitilineorigin2_desc, 13, 0, 10, 100, 100, -1,  epos, 0, 0,  offset, 0, 100);
 45   Console.WriteLine("MoveL return: {0}", error);
 46
 47   error = robot.MoveJ(mulitilinesafe_joint, mulitilinesafe_desc, 13, 0, 10, 100, 100, epos, -1, 0, offset);
 48   Console.WriteLine("MoveJ return: {0}", error);
 49
 50   error = robot.MoveL( mulitilineorigin1_joint,  mulitilineorigin1_desc, 13, 0, 10, 100, 100, -1,  epos, 0, 0,  offset, 0, 100);
 51   Console.WriteLine("MoveL return: {0}", error);
 52
 53   error = robot.ARCStart(1, 0, 3000);
 54   Console.WriteLine("ARCStart return: {0}", error);
 55
 56   error = robot.WeaveStart(0);
 57   Console.WriteLine("WeaveStart return: {0}", error);
 58
 59   error = robot.ArcWeldTraceControl(1, 0, 1, 0.06, 5, 5, 50, 1, 0.06, 5, 5, 55, 0, 0, 4, 1, 10);
 60   Console.WriteLine("ArcWeldTraceControl return: {0}", error);
 61
 62   error = robot.MoveL( mulitilineorigin2_joint,  mulitilineorigin2_desc, 13, 0, 1, 100, 100, -1,  epos, 0, 0,  offset, 0, 100);
 63   Console.WriteLine("MoveL return: {0}", error);
 64
 65   error = robot.ArcWeldTraceControl(0, 0, 1, 0.06, 5, 5, 50, 1, 0.06, 5, 5, 55, 0, 0, 4, 1, 10);
 66   Console.WriteLine("ArcWeldTraceControl return: {0}", error);
 67
 68   error = robot.WeaveEnd(0);
 69   Console.WriteLine("WeaveEnd return: {0}", error);
 70
 71   error = robot.ARCEnd(1, 0, 10000);
 72   Console.WriteLine("ARCEnd return: {0}", error);
 73
 74   error = robot.MoveJ(mulitilinesafe_joint, mulitilinesafe_desc, 13, 0, 10, 100, 100, epos, -1, 0, offset);
 75   Console.WriteLine("MoveJ return: {0}", error);
 76
 77   error = robot.MultilayerOffsetTrsfToBase(mulitilineorigin1_desc.tran, mulitilineX1_desc, mulitilineZ1_desc, 10.0, 0.0, 0.0, ref offset);
 78   Console.WriteLine("MultilayerOffsetTrsfToBase return: {0}  offect is {1} {2} {3}", error, offset.tran.x, offset.tran.y, offset.tran.z);
 79
 80   error = robot.MoveL( mulitilineorigin1_joint,  mulitilineorigin1_desc, 13, 0, 10, 100, 100, -1,  epos, 0, 1,  offset, 0, 100);
 81   Console.WriteLine("MoveL return: {0}", error);
 82
 83   error = robot.ARCStart(1, 0, 3000);
 84   Console.WriteLine("ARCStart return: {0}", error);
 85
 86   error = robot.MultilayerOffsetTrsfToBase(mulitilineorigin2_desc.tran, mulitilineX2_desc, mulitilineZ2_desc, 10, 0, 0, ref offset);
 87   Console.WriteLine("MultilayerOffsetTrsfToBase return: {0}  offect is {1} {2} {3}", error, offset.tran.x, offset.tran.y, offset.tran.z);
 88
 89   error = robot.ArcWeldTraceReplayStart();
 90   Console.WriteLine("ArcWeldTraceReplayStart return: {0}", error);
 91
 92   error = robot.MoveL( mulitilineorigin2_joint,  mulitilineorigin2_desc, 13, 0, 2, 100, 100, -1,  epos, 0, 1,  offset, 0, 100);
 93   Console.WriteLine("MoveL return: {0}", error);
 94
 95   error = robot.ArcWeldTraceReplayEnd();
 96   Console.WriteLine("ArcWeldTraceReplayEnd return: {0}", error);
 97
 98   error = robot.ARCEnd(1, 0, 10000);
 99   Console.WriteLine("ARCEnd return: {0}", error);
100
101   error = robot.MoveJ(mulitilinesafe_joint, mulitilinesafe_desc, 13, 0, 10, 100, 100, epos, -1, 0, offset);
102   Console.WriteLine("MoveJ return: {0}", error);
103
104   error = robot.MultilayerOffsetTrsfToBase(mulitilineorigin1_desc.tran, mulitilineX1_desc, mulitilineZ1_desc, 0, 10, 0, ref offset);
105   Console.WriteLine("MultilayerOffsetTrsfToBase return: {0}  offect is {1} {2} {3}", error, offset.tran.x, offset.tran.y, offset.tran.z);
106
107   error = robot.MoveL( mulitilineorigin1_joint,  mulitilineorigin1_desc, 13, 0, 10, 100, 100, -1,  epos, 0, 1,  offset, 0, 100);
108   Console.WriteLine("MoveL return: {0}", error);
109
110   error = robot.ARCStart(1, 0, 3000);
111   Console.WriteLine("ARCStart return: {0}", error);
112
113   error = robot.MultilayerOffsetTrsfToBase(mulitilineorigin2_desc.tran, mulitilineX2_desc, mulitilineZ2_desc, 0, 10, 0, ref offset);
114   Console.WriteLine("MultilayerOffsetTrsfToBase return: {0}  offect is {1} {2} {3}", error, offset.tran.x, offset.tran.y, offset.tran.z);
115
116   error = robot.ArcWeldTraceReplayStart();
117   Console.WriteLine("MoveJ return: {0}", error);
118
119   error = robot.MoveL(mulitilineorigin2_joint, mulitilineorigin2_desc, 13, 1, 2, 100, 100, -1, epos, 1, 1, offset, 1, 100);
120   Console.WriteLine("MoveL return: {0}", error);
121
122   error = robot.ArcWeldTraceReplayEnd();
123   Console.WriteLine("ArcWeldTraceReplayEnd return: {0}", error);
124
125   error = robot.ARCEnd(1, 0, 3000);
126   Console.WriteLine("ARCEnd return: {0}", error);
127
128   error = robot.MoveJ(mulitilinesafe_joint, mulitilinesafe_desc, 13, 0, 10, 100, 100, epos, -1, 0, offset);
129   Console.WriteLine("MoveJ return: {0}", error);
130}

14.51. Arc Tracking Welder Current Feedback AI Channel Selection

New in version C#SDK-V1.1.3: Web-3.8.2

1 /**
2 * @brief Arc tracking welder current feedback AI channel selection
3 * @param [in] channel channel; 0-extension AI0; 1-extension AI1; 2-extension AI2; 3-extension AI3; 4-control box AI0; 5-control box AI1
4 * @return error code
5 */
6 int ArcWeldTraceAIChannelCurrent(int channel).

14.52. Arc tracking welder voltage feedback AI channel selection

New in version C#SDK-V1.1.3: Web-3.8.2

1 /**
2 * @brief Arc Tracking Welder Voltage Feedback AI Channel Selection
3 * @param [in] channel channel; 0-extension AI0; 1-extension AI1; 2-extension AI2; 3-extension AI3; 4-control box AI0; 5-control box AI1
4 * @return error code
5 */
6 int ArcWeldTraceAIChannelVoltage(int channel).

14.53. Arc tracking welder current feedback conversion parameters

New in version C#SDK-V1.1.3: Web-3.8.2

1 /**
2 * @brief Arc tracking welder current feedback conversion parameters
3 * @param [in] AILow AI channel lower limit, default value 0V, range [0-10V].
4 * @param [in] AIHigh AI channel upper limit, default value 10V, range [0-10V]
5 * @param [in] currentLow AI channel lower limit corresponds to the welder current value, default value 0V, range [0-200V].
6 * @param [in] currentHigh AI channel upper limit corresponds to the welder current value, default value 100V, range [0-200V].
7 * @return Error code
8 */
9 int ArcWeldTraceCurrentPara(float AILow, float AIHigh, float currentLow, float currentHigh);

14.54. Arc Trace Welder Voltage Feedback Conversion Parameters

New in version C#SDK-V1.1.3: Web-3.8.2

1 /**
2 * @brief Arc Tracker Welder Voltage Feedback Conversion Parameters
3 * @param [in] AILow AI channel lower limit, default value 0V, range [0-10V].
4 * @param [in] AIHigh AI channel upper limit, default value 10V, range [0-10V].
5 * @param [in] voltageLow AI channel lower limit corresponds to the welder voltage value, default value 0V, range [0-200V].
6 * @param [in] voltageHigh AI channel upper limit corresponds to the welder voltage value, default value 100V, range [0-200V] * @param [in] voltageHigh AI channel upper limit corresponds to the welder voltage value, default value 100V, range [0-200V
7 * @return Error code
8 */
9 int ArcWeldTraceVoltagePara(float AILow, float AIHigh, float voltageLow, float voltageHigh);

14.55. Arc Trace Code Example

New in version C#SDK-V1.1.3: Web-3.8.2

 1private void btnweld_Click(object sender, EventArgs e)
 2{
 3   DescPose safetydescPose = new DescPose(-504.043, 275.181, 40.908, -28.002, -42.025, -14.044);
 4   JointPos safetyjointPos = new JointPos(-39.078, -76.732, 87.227, -99.47, -94.301, 18.714);
 5   DescPose startdescPose = new DescPose(-473.86, 257.879, -20.849, -37.317, -42.021, 2.543);
 6   JointPos startjointPos = new JointPos(-43.487, -76.526, 95.568, -104.445, -89.356, 3.72);
 7
 8
 9
10   DescPose enddescPose = new DescPose(-499.844, 141.225, 7.72, -34.856, -40.17, 13.13);
11   JointPos endjointPos = new JointPos(-31.305, -82.998, 99.401, -104.426, -89.35, 3.696);
12
13   ExaxisPos exaxisPos = new ExaxisPos(0, 0, 0, 0);
14   DescPose offdese = new DescPose(0, 0, 0, 0, 0, 0);
15   robot.MoveJ(safetyjointPos, safetydescPose, 1, 0, 20, 100, 100, exaxisPos, -1, 0, offdese);
16
17   robot.WeldingSetCurrentRelation(0, 495, 1, 10, 0);
18   robot.WeldingSetVoltageRelation(10, 45, 1, 10, 1);
19   robot.WeldingSetVoltage(0, 25, 1, 0);// ----设置电压
20   robot.WeldingSetCurrent(0, 260, 0, 0);// ----设置电流
21
22   int rtn = robot.ArcWeldTraceAIChannelCurrent(4);
23   Console.WriteLine("ArcWeldTraceAIChannelCurrent rtn is " + rtn);
24   rtn = robot.ArcWeldTraceAIChannelVoltage(5);
25   Console.WriteLine("ArcWeldTraceAIChannelVoltage rtn is " + rtn);
26   rtn = robot.ArcWeldTraceCurrentPara((float)0, (float)5, (float)0, (float)500);
27   Console.WriteLine("ArcWeldTraceCurrentPara rtn is " + rtn);
28   rtn = robot.ArcWeldTraceVoltagePara((float)1.018, (float)10, (float)0, (float)50);
29   Console.WriteLine("ArcWeldTraceVoltagePara rtn is " + rtn);
30
31   robot.MoveJ(startjointPos, startdescPose, 1, 0, 20, 100, 100, exaxisPos, -1, 0, offdese);
32   robot.ArcWeldTraceControl(1, 0, 1, 0.08, 5, 5, 300, 1, 0.06, 4, 4, 300, 1, 0, 4, 1, 10, 0, 0);
33   robot.ARCStart(0, 0, 10000);
34   robot.WeaveStart(0);
35   // robot.MoveL(endjointPos, enddescPose, 1, 0, 100, 100, 2, -1, exaxisPos, 0, 0, offdese);
36   robot.ARCEnd(0, 0, 10000);
37   robot.WeaveEnd(0);
38   robot.ArcWeldTraceControl(0, 0, 1, 0.08, 5, 5, 300, 1, 0.06, 4, 4, 300, 1, 0, 4, 1, 10, 0, 0);
39   robot.MoveJ(safetyjointPos, safetydescPose, 1, 0, 20, 100, 100, exaxisPos, -1, 0, offdese);
40}

14.56. Start of wire position finding

 1 /**
 2 * @brief Welding wire seek start.
 3 * @param [in] refPos 1-datum point 0-contact point
 4 * @param [in] searchVel SearchVelocity %.
 5 * @param [in] searchDis Search distance mm
 6 * @param [in] autoBackFlag autoBackFlag, 0 - not auto; - auto
 7 * @param [in] autoBackVel autoBackVelocity % * @param [in] searchDis searchDistance mm
 8 * @param [in] autoBackDis autoBack distance mm
 9 * @param [in] offectFlag 1-with offset seek; 0-teach point seek
10 * @return error code
11 */
12 int WireSearchStart(int refPos, double searchVel, int searchDis, int autoBackFlag, double autoBackVel, int autoBackDis, int offectFlag);

14.58. Calculate the wire seek offset

 1/**
 2* @brief Calculate wire-seeking offsets.
 3* @param [in] seamType weldType
 4* @param [in] method Calculate the method.
 5* @param [in] varNameRef datums 1-6, "#" means no point variable
 6* @param [in] varNameRes contact points 1-6, "#" means no point variable
 7* @param [out] offectFlag 0-offset directly superimposed on the command point; 1-offset requires a coordinate transformation of the command point
 8* @param [out] offect Offset pose [x, y, z, a, b, c]
 9* @return Error code
10*/
11int GetWireSearchOffset(int seamType, int method, string[] varNameRef, string[] varNameRes, ref int offsetFlag, ref DescPose offset);;

14.59. Wait for the wire search to complete

1/**
2* @brief Waiting for wire seek to complete.
3* @return Error code.
4*/
5int WireSearchWait(string name).

14.60. Write wire search contact to database.

1/**
2* @brief Welding wire seek contacts written to database.
3* @param [in] varName Contact name "RES0" ~ "RES99".
4* @param [in] pos contact data [x, y, x, a, b, c]
5* @return Error Code
6*/
7int SetPointToDatabase(string varName, DescPose pos);

14.61. Robot Welding Wire Position Finding Code Example

 1private void button53_Click(object sender, EventArgs e)
 2{
 3   DescPose toolCoord=new DescPose(0, 0, 200, 0, 0, 0);
 4   robot.SetToolCoord(1, toolCoord, 0, 0, 1, 0);
 5   DescPose wobjCoord=new DescPose(0, 0, 0, 0, 0, 0);
 6   robot.SetWObjCoord(1, wobjCoord, 0);
 7
 8   int rtn0, rtn1, rtn2 = 0;
 9   ExaxisPos exaxisPos = new ExaxisPos(0, 0, 0, 0);
10   DescPose offdese = new DescPose(0, 0, 0, 0, 0, 0);
11
12   DescPose descStart = new DescPose(216.543, 445.175, 93.465, 179.683, 1.757, -112.641);
13   JointPos jointStart = new JointPos(-128.345, -86.660, 114.679, -119.625, -89.219, 74.303);
14
15   DescPose descEnd = new DescPose(111.143, 523.384, 87.659, 179.703, 1.835, -97.750);
16   JointPos jointEnd = new JointPos(-113.454, -81.060, 109.328, -119.954, -89.218, 74.302);
17
18   robot.MoveL(jointStart, descStart, 1, 1, 100, 100, 100, -1, exaxisPos, 0, 0, offdese);
19   robot.MoveL(jointEnd, descEnd, 1, 1, 100, 100, 100, -1, exaxisPos, 0, 0, offdese);
20
21   DescPose descREF0A = new DescPose(142.135, 367.604, 86.523, 179.728, 1.922, -111.089);
22   JointPos jointREF0A = new JointPos(-126.794, -100.834, 128.922, -119.864, -89.218, 74.302);
23
24   DescPose descREF0B = new DescPose(254.633, 463.125, 72.604, 179.845, 2.341, -114.704);
25   JointPos jointREF0B = new JointPos(-130.413, -81.093, 112.044, -123.163, -89.217, 74.303);
26
27   DescPose descREF1A = new DescPose(92.556, 485.259, 47.476, -179.932, 3.130, -97.512);
28   JointPos jointREF1A = new JointPos(-113.231, -83.815, 119.877, -129.092, -89.217, 74.303);
29
30   DescPose descREF1B = new DescPose(203.103, 583.836, 63.909, 179.991, 2.854, -103.372);
31   JointPos jointREF1B = new JointPos(-119.088, -69.676, 98.692, -121.761, -89.219, 74.303);
32
33   rtn0 = robot.WireSearchStart(0, 10, 100, 0, 10, 100, 0);
34   robot.MoveL(jointREF0A, descREF0A, 1, 1, 100, 100, 100, -1, exaxisPos, 0, 0, offdese);  //起点
35   robot.MoveL(jointREF0B, descREF0B, 1, 1, 100, 100, 100, -1, exaxisPos, 1, 0, offdese);  //方向点
36   rtn1 = robot.WireSearchWait("REF0");
37   rtn2 = robot.WireSearchEnd(0, 10, 100, 0, 10, 100, 0);
38
39   rtn0 = robot.WireSearchStart(0, 10, 100, 0, 10, 100, 0);
40   robot.MoveL(jointREF1A, descREF1A, 1, 1, 100, 100, 100, -1, exaxisPos, 0, 0, offdese);  //起点
41   robot.MoveL(jointREF1B, descREF1B, 1, 1, 100, 100, 100, -1, exaxisPos, 1, 0, offdese);  //方向点
42   rtn1 = robot.WireSearchWait("REF1");
43   rtn2 = robot.WireSearchEnd(0, 10, 100, 0, 10, 100, 0);
44
45   rtn0 = robot.WireSearchStart(0, 10, 100, 0, 10, 100, 0);
46   robot.MoveL(jointREF0A, descREF0A, 1, 1, 100, 100, 100, -1, exaxisPos, 0, 0, offdese);  //起点
47   robot.MoveL(jointREF0B, descREF0B, 1, 1, 100, 100, 100, -1, exaxisPos, 1, 0, offdese);  //方向点
48   rtn1 = robot.WireSearchWait("RES0");
49   rtn2 = robot.WireSearchEnd(0, 10, 100, 0, 10, 100, 0);
50
51   rtn0 = robot.WireSearchStart(0, 10, 100, 0, 10, 100, 0);
52   robot.MoveL(jointREF1A, descREF1A, 1, 1, 100, 100, 100, -1, exaxisPos, 0, 0, offdese);  //起点
53   robot.MoveL(jointREF1B, descREF1B, 1, 1, 100, 100, 100, -1, exaxisPos, 1, 0, offdese);  //方向点
54   rtn1 = robot.WireSearchWait("RES1");
55   rtn2 = robot.WireSearchEnd(0, 10, 100, 0, 10, 100, 0);
56
57   string[] varNameRef = { "REF0", "REF1", "#", "#", "#", "#" };
58   string[] varNameRes = { "RES0", "RES1", "#", "#", "#", "#" };
59   int offectFlag = 0;
60   DescPose offectPos = new DescPose(0, 0, 0, 0, 0, 0);
61   rtn0 = robot.GetWireSearchOffset(0, 0, varNameRef, varNameRes, ref offectFlag, ref offectPos);
62   robot.PointsOffsetEnable(0, offectPos);
63   robot.MoveL(jointStart, descStart, 1, 1, 100, 100, 100, -1, exaxisPos, 0, 0, offdese);
64   robot.MoveL(jointEnd, descEnd, 1, 1, 100, 100, 100, -1, exaxisPos, 1, 0, offdese);
65   robot.PointsOffsetDisable();
66}

14.62. Setting the end of the welding voltage gradient

New in version C#SDK-V1.1.3: Web-3.8.2

 1/**
 2* @brief Sets the weld voltage gradient to start.
 3* @param [in] IOType Control type; 0-control box IO; 1-digital communication protocol (UDP); 2-digital communication protocol (ModbusTCP)
 4* @param [in] voltageStart Start welding voltage (V)
 5* @param [in] voltageEnd End weld voltage (V)
 6* @param [in] AOIndex control box AO port number (0-1)
 7* @param [in] blend Whether smooth or not 0-not smooth; 1-smooth
 8* @return Error code
 9*/
10int WeldingSetVoltageGradualChangeStart(int IOType, double voltageStart, double voltageEnd, int AOIndex, int blend);

14.63. Set weld voltage gradual change end

New in version C#SDK-V1.1.3: Web-3.8.2

1/**
2* @brief Setting the end of the welding voltage gradient.
3* @return Error Code
4*/
5int WeldingSetVoltageGradualChangeEnd();

14.64. Sets the weld current gradual change end

New in version C#SDK-V1.1.3: Web-3.8.2

 1/**
 2* @brief Setting the weld current gradient to start.
 3* @param [in] IOType Control type; 0-control box IO; 1-digital communication protocol (UDP); 2-digital communication protocol (ModbusTCP)
 4* @param [in] voltageStart Start welding current (A)
 5* @param [in] voltageEnd End weld current (A)
 6* @param [in] AOIndex Control box AO port number (0-1)
 7* @param [in] blend Whether smooth or not 0-not smooth; 1-smooth
 8* @return Error code
 9*/
10int WeldingSetCurrentGradualChangeStart(int IOType, double currentStart, double currentEnd, int AOIndex, int blend);

14.65. Set weld current gradual change end

New in version C#SDK-V1.1.3: Web-3.8.2

1/**
2* @brief Setting the end of the welding current gradient.
3* @return Error code
4*/
5int WeldingSetCurrentGradualChangeEnd();

14.66. Robot Welding Current Voltage Gradual Change Code Example

New in version C#SDK-V1.1.3: Web-3.8.2

 1  private void btnweld_Click(object sender, EventArgs e)
 2  {
 3     DescPose startdescPose = new DescPose(-319.303, -240.689, 116.379, -175.879, -0.337, 148.239);
 4     JointPos startjointPos = new JointPos(20.474, -103.554, 126.774, -116.682, -87.746, -37.709);
 5
 6     DescPose enddescPose = new DescPose(-454.166, -327.159, 62.217, 177.199, -2.276, 154.955);
 7     JointPos endjointPos = new JointPos(27.176, -74.423, 104.557, -119.315, -93.514, -37.698);
 8
 9     DescPose safedescPose = new DescPose(-375.533, -543.319, 19.798, 177.486, -2.489, 175.825);
10     JointPos safejointPos = new JointPos(48.074, -59.714, 89.955, -119.777, -93.508, -37.683);
11
12     ExaxisPos exaxisPos = new ExaxisPos(0, 0, 0, 0);
13     DescPose offdese = new DescPose(0, 0, 0, 0, 0, 0);
14
15     robot.WeldingSetCurrentRelation(0, 495, 1, 10, 0);
16     robot.WeldingSetVoltageRelation(10, 45, 1, 10, 1);
17
18     robot.WeldingSetVoltage(0, 25, 1, 0);//
19     robot.WeldingSetCurrent(0, 260, 0, 0);//
20
21     robot.MoveJ(safejointPos, safedescPose, 1, 0, 5, 100, 100, exaxisPos, -1, 0, offdese);
22
23     int rtn = robot.WeldingSetCurrentGradualChangeStart(0, 260, 220, 0, 0);
24     Console.WriteLine($"WeldingSetCurrentGradualChangeStart rtn is {rtn}");
25     rtn = robot.WeldingSetVoltageGradualChangeStart(0, 25, 22, 1, 0);
26     Console.WriteLine($"WeldingSetVoltageGradualChangeStart rtn is {rtn}");
27
28     rtn = robot.ArcWeldTraceControl(1, 0, 1, 0.08, 5, 5, 300, 1, 0.06, 4, 4, 300, 1, 0, 4, 1, 10, 0, 0);
29     Console.WriteLine($"ArcWeldTraceControl rtn is {rtn}");
30
31     robot.MoveJ(startjointPos, startdescPose, 1, 0, 5, 100, 100, exaxisPos, -1, 0, offdese);
32
33     robot.ARCStart(0, 0, 10000);
34     robot.WeaveStart(0);
35     rtn = robot.WeaveChangeStart(2, 1, 24, 36);
36     Console.WriteLine($"WeaveChangeStart rtn is {rtn}");
37     //robot.MoveL(endjointPos, enddescPose, 1, 0, 100, 100, 2, -1, exaxisPos, 0, 0, offdese);
38     robot.ARCEnd(0, 0, 10000);
39     robot.WeaveChangeEnd();
40     robot.WeaveEnd(0);
41     robot.ArcWeldTraceControl(0, 0, 1, 0.08, 5, 5, 300, 1, 0.06, 4, 4, 300, 1, 0, 4, 1, 10, 0, 0);
42     robot.WeldingSetCurrentGradualChangeEnd();
43     robot.WeldingSetVoltageGradualChangeEnd();
44  }

14.67. Set custom weaving parameters

New in version C#SDK-V1.1.8: Web-3.8.6

 1/**
 2* @brief Set custom weaving parameters
 3* @param [in] id Custom weaving number: 0-2
 4* @param [in] pointNum Number of weaving points: 0-10
 5* @param [in] point Moving endpoint data x,y,z
 6* @param [in] stayTime Weaving dwell time in ms
 7* @param [in] frequency Weaving frequency in Hz
 8* @param [in] incStayType Wait mode: 0-cycle does not include wait time; 1-cycle includes wait time
 9* @param [in] stationary Weaving position wait: 0-continue motion during wait time; 1-position static during wait time
10* @return  Error code
11*/
12public int CustomWeaveSetPara(int id, int pointNum, DescTran[] points, double[] stayTimes, double frequency, int incStayType, int stationary)

14.68. Get custom weaving parameters

New in version C#SDK-V1.1.8: Web-3.8.6

 1/**
 2* @brief Get custom weaving parameters
 3* @param [in] id Custom weaving number: 0-2
 4* @param [out] pointNum Number of weaving points: 0-10
 5* @param [out] point Moving endpoint data x,y,z
 6* @param [out] stayTime Weaving dwell time in ms
 7* @param [out] frequency Weaving frequency in Hz
 8* @param [out] incStayType Wait mode: 0-cycle does not include wait time; 1-cycle includes wait time
 9* @param [out] stationary Weaving position wait: 0-continue motion during wait time; 1-position static during wait time
10* @return  Error code
11*/
12public int CustomWeaveGetPara(int id, ref int pointNum, ref DescTran[] points, ref double[] stayTimes, ref double frequency, ref int incStayType, ref int stationary)

14.69. Custom Weaving Parameters Code Example

New in version C#SDK-V1.1.8: Web-3.8.6

 1public void TestCoordMain5()
 2{
 3    DescTran[] points = new DescTran[10];
 4    for (int i = 0; i < 10; i++)
 5    {
 6        points[i] = new DescTran();
 7    }
 8    points[0].x = -3;
 9    points[0].y = -3;
10    points[0].z = 0;
11    points[1].x = -6;
12    points[1].y = 0;
13    points[1].z = 0;
14    points[2].x = -3;
15    points[2].y = 3;
16    points[2].z = 0;
17    points[3].x = 0;
18    points[3].y = 0;
19    points[3].z = 0;
20    double[] stayTimes = new double[10] { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
21    int rtn = robot.CustomWeaveSetPara(2, 4, points, stayTimes, 1.000, 0, 0);
22    Console.WriteLine($"CustomWeaveSetPara rtn is {rtn}");
23    System.Threading.Thread.Sleep(1000);
24    int pointNum = 0;
25    double frequency = 0;
26    int incStayType = 0;
27    int stationary = 0;
28    rtn = robot.CustomWeaveGetPara(2, ref pointNum, ref points, ref stayTimes, ref frequency, ref incStayType, ref stationary);
29    Console.WriteLine($"pointNum is {pointNum}");
30    for (int i = 0; i < pointNum; i++)
31    {
32        Console.WriteLine($"point {i}, point x y z {points[i].x:F6} {points[i].y:F6} {points[i].z:F6}");
33    }
34    Console.WriteLine($"fre is {frequency:F6}, stay is {incStayType} {stationary}");
35    robot.WeaveSetPara(0, 9, 1.000000, 1, 5.000000, 6.000000, 5.000000, 50, 100, 100, 0, 1, 0.000000, 0.000000);
36    DescPose desc_p1 = new DescPose(-288.650, 367.807, 288.404, 0.000, -0.001, 0.001);
37    DescPose desc_p2 = new DescPose(-431.714, 367.815, 288.415, 0.001, 0.001, 0.000);
38    DescPose desc_p3 = new DescPose(-348.666, 427.798, 288.404, -0.000, -0.000, 0.001);
39    JointPos j1 = new JointPos(140.656,  -84.560,  -91.707, -93.734,  90.000,50.655 );
40    JointPos j2 = new JointPos ( 149.873, -98.298, -77.599,  -94.103,  90.000,  59.873 );
41    JointPos j3 = new JointPos (139.773,  -96.173, -80.014,  -93.814,  90.000,  49.772 );
42    ExaxisPos epos = new ExaxisPos(0,0,0,0);
43    DescPose offset_pos = new DescPose(0,0,0,0,0,0);
44    robot.MoveJ(j1, desc_p1, 3, 0, 100, 100, 100, epos, -1, 0, offset_pos);
45    robot.WeaveStart(0);
46    robot.Circle(j3, desc_p3, 3, 0, 100, 100, epos, j2, desc_p2, 3, 0, 100, 100, epos, 10, -1, offset_pos, 100, -1, 0);
47    robot.WeaveEnd(0);
48    robot.MoveJ(j1, desc_p1, 3, 0, 100, 100, 100, epos, -1, 0, offset_pos);
49    robot.WeaveStart(0);
50    robot.MoveC(j3, desc_p3, 3, 0, 100, 100, epos, 0, offset_pos, j2, desc_p2, 3, 0, 100, 100, epos, 0, offset_pos, 10, -1, 0);
51    robot.WeaveEnd(0);
52    robot.MoveJ(j1, desc_p1, 3, 0, 100, 100, 100, epos, -1, 0, offset_pos);
53    robot.WeaveStart(0);
54    robot.MoveL(j2, desc_p2, 3, 0, 100, 100, 10, -1, epos, 0, 0, offset_pos, 0, 0, 10);
55    robot.WeaveEnd(0);
56}