Position vs Velocity mode
26 Jun 2024 13:14 #303829
by rodw
Replied by rodw on topic Position vs Velocity mode
Thanks, it was interesting to hear somebody else's take on homing.i had actually forgotten about the home offset in the drive.
Different machines will have different stiffness. I was horrified when I racked my plasma gantry to see it twist at least 6 inches out of alignment, then fully correct itself when homed. And I thought it was stiff!
Getting drives to home all together won't be a problem. The lcec driver reads all pdos at the beginning of the servo loop and writes out all pdos at the end after Linuxcnc has updated anything heading for the ethercat bus. Even a modest PC completes the servo thread in about 200 usec, then sleeps for about 800usec until the thread is fired again. So at a guess, all drives will commence homing within a 50 usec time slot.
Also be aware that a router or plasma should mark out 4 points forming a rectangle or square on the table and the diagonals measured to ensure they are the same length as part of the squareness calibration.
Different machines will have different stiffness. I was horrified when I racked my plasma gantry to see it twist at least 6 inches out of alignment, then fully correct itself when homed. And I thought it was stiff!
Getting drives to home all together won't be a problem. The lcec driver reads all pdos at the beginning of the servo loop and writes out all pdos at the end after Linuxcnc has updated anything heading for the ethercat bus. Even a modest PC completes the servo thread in about 200 usec, then sleeps for about 800usec until the thread is fired again. So at a guess, all drives will commence homing within a 50 usec time slot.
Also be aware that a router or plasma should mark out 4 points forming a rectangle or square on the table and the diagonals measured to ensure they are the same length as part of the squareness calibration.
The following user(s) said Thank You: zmrdko
Please Log in or Create an account to join the conversation.
27 Jun 2024 10:57 #303884
by Donb9261
Replied by Donb9261 on topic Position vs Velocity mode
Depending on the design the motor end effect torque can be substantial and will break stuff. A 10mm pitch ball screw with a 2.9nm(750W) servo can generate near 1500nm or force. That is a lot. Most major industrial CNC machines have at least 5000nm of end effect force. Therefore, using tandem axis control must be set up very accurately.
There is a caveat to my prior statements in regard to home to index in the drive with a tandem drive. That is the index pulse alignment. This is where things can get harry quick. If the index pulses are 180 degrees out from each other, then you home to the index for each motor you will be out of square by the pitch of your driven axis. A 10mm pitch ball screw would be out by at least 5mm when final home is complete. If your machine is real stiff this could break a bolt, warp a ball screw, etc.
Even an ABS encoder has a one per rotation pulse aka index pulse. On an incremental encoder this is the Z pulse. On an ABS serial encoder this is the turn data marker. They do the same thing but have different meanings. Regardless, it would be wise to know where the 2 motors are in relation to their respective index pulse locations. Every situation is different in how to find that pulse sync location. But, it is well worth the time and effort. Usually, a few degrees from exact sync is acceptable.
Hope that helps...
There is a caveat to my prior statements in regard to home to index in the drive with a tandem drive. That is the index pulse alignment. This is where things can get harry quick. If the index pulses are 180 degrees out from each other, then you home to the index for each motor you will be out of square by the pitch of your driven axis. A 10mm pitch ball screw would be out by at least 5mm when final home is complete. If your machine is real stiff this could break a bolt, warp a ball screw, etc.
Even an ABS encoder has a one per rotation pulse aka index pulse. On an incremental encoder this is the Z pulse. On an ABS serial encoder this is the turn data marker. They do the same thing but have different meanings. Regardless, it would be wise to know where the 2 motors are in relation to their respective index pulse locations. Every situation is different in how to find that pulse sync location. But, it is well worth the time and effort. Usually, a few degrees from exact sync is acceptable.
Hope that helps...
Please Log in or Create an account to join the conversation.
27 Jun 2024 11:35 #303889
by Donb9261
Replied by Donb9261 on topic Position vs Velocity mode
A possible scenario to locate the mechanics of your 2 motors would be to do the following.
Home the 2 motors with zero offsets. Then measure your square determine the difference. Say 3mm out of square. Choose an appropriate motor to adjust. Place an indicator on that chosen motors frame to read the travel. Release the motor coupling and rotate the ball screw amount required to square the 2 sides +-.150mm or .007~.008" then lock the coupling. Rehome the tandem axis. Then measure and adjust the home offset parameters to complete the setup until your square is within .005~.025mm based on your acceptable tolerance. Then, to ensure that the reversal timing is aligned, once the homes are "squared" move the axis until at least 1 home switch activates. Then move the inactive switch until it makes at the same place. This will eliminate racking at reversal which will over time cause wear and issues that are preventable.
I only use compression type motor couplings. Keyed couplings cannot be used for the above alignment for obvious reasons.
The same would apply for rack and pinion designs as far as the connection type using compression couplings and the procedure listed above.
Remember that .001" out of square on the gantry axis will be exponential as the perpendicular axis(if X is your tandem axis then Y would be the P axis) axis moves from it's reference position. Meaning that over a 10" travel the tool tip will not be .001" out of position or CL of expected location, it will the rise of the triangle out. Here possibly .0025 or so. At 20", even more. Ideally you want the tandem square to be zero in perpendicularity to the P axis. This will also help with concentricity when interpolation of holes is performed.
I may do a post on using ISO standards of machine tool squareness and how the ISO describes the measurement of the parallelism, perpendicularity, and total square of the full cartesian coordinate system for both 3+2 and true 5x machines soon. I think it would be helpful for those unlike me who have 30+ years of nerding on CNC at the highest levels to understand how to get the most out your equipment and save themselves from many many headaches. Give me a week or 2 to put the documents and graphics together. After following the course, you will be able to have a machine that is aligned to ISO standards. It may sound trivial to do so, but doing so saves businesses annually well over $10B in maintenance and production loss costs. As you already know, the parts for CNC are not cheap. And time is money.
I was asked recently why I would just freely give away trade secrets. The answer is clear. The world has slowly stop making things and economic growth is showing that net effect. I am hoping that in sharing my experience, a flower will open up and a new manufacturing business will contribute to the equation driving economic growth in market economies. This benefits every single living being. Any notion otherwise, would be ill advised. Lol. I am a charitable guy, but I am also a strong capitalist.
Kinda nerdy, but I hope that helps.
Home the 2 motors with zero offsets. Then measure your square determine the difference. Say 3mm out of square. Choose an appropriate motor to adjust. Place an indicator on that chosen motors frame to read the travel. Release the motor coupling and rotate the ball screw amount required to square the 2 sides +-.150mm or .007~.008" then lock the coupling. Rehome the tandem axis. Then measure and adjust the home offset parameters to complete the setup until your square is within .005~.025mm based on your acceptable tolerance. Then, to ensure that the reversal timing is aligned, once the homes are "squared" move the axis until at least 1 home switch activates. Then move the inactive switch until it makes at the same place. This will eliminate racking at reversal which will over time cause wear and issues that are preventable.
I only use compression type motor couplings. Keyed couplings cannot be used for the above alignment for obvious reasons.
The same would apply for rack and pinion designs as far as the connection type using compression couplings and the procedure listed above.
Remember that .001" out of square on the gantry axis will be exponential as the perpendicular axis(if X is your tandem axis then Y would be the P axis) axis moves from it's reference position. Meaning that over a 10" travel the tool tip will not be .001" out of position or CL of expected location, it will the rise of the triangle out. Here possibly .0025 or so. At 20", even more. Ideally you want the tandem square to be zero in perpendicularity to the P axis. This will also help with concentricity when interpolation of holes is performed.
I may do a post on using ISO standards of machine tool squareness and how the ISO describes the measurement of the parallelism, perpendicularity, and total square of the full cartesian coordinate system for both 3+2 and true 5x machines soon. I think it would be helpful for those unlike me who have 30+ years of nerding on CNC at the highest levels to understand how to get the most out your equipment and save themselves from many many headaches. Give me a week or 2 to put the documents and graphics together. After following the course, you will be able to have a machine that is aligned to ISO standards. It may sound trivial to do so, but doing so saves businesses annually well over $10B in maintenance and production loss costs. As you already know, the parts for CNC are not cheap. And time is money.
I was asked recently why I would just freely give away trade secrets. The answer is clear. The world has slowly stop making things and economic growth is showing that net effect. I am hoping that in sharing my experience, a flower will open up and a new manufacturing business will contribute to the equation driving economic growth in market economies. This benefits every single living being. Any notion otherwise, would be ill advised. Lol. I am a charitable guy, but I am also a strong capitalist.
Kinda nerdy, but I hope that helps.
Please Log in or Create an account to join the conversation.
27 Jun 2024 11:53 #303890
by Donb9261
Replied by Donb9261 on topic Position vs Velocity mode
For the super nerdy, you can read all about it in the ISO standards for Geometric Accuracy by looking up CSN ISO 230-1(Linear Accuracy) and CSN 230-7(Rotary Accuracy). Or simply save the money it costs and wait for me to tell you about the ISO's and how to actually test them. There are other accuracy tests but they are expensive to test and as long as the above is satisfied, you can forego them and still have a solid .025mm total accuracy tolerance as long as your backlash is small. Usually within .075mm/per axis is ideal. Then, a compensation can be be properly made in the control to account for that .075mm/per axis.
Please Log in or Create an account to join the conversation.
02 Jul 2024 06:22 #304206
by zmrdko
Replied by zmrdko on topic Position vs Velocity mode
Hello Don,
you seem like you are an expert in servos field, so I will try my luck with this question:
I have both delta B3-L and B3-Ethercat drives
B3-L (step-dir) are currently hooked up to my machine using mesa card 7i95t and they are tuned via delta software to practically zero following error when checking scope in delta software (except for some minor when starting and stopping. like 0.006mm on 5mm ball screw).
However I am unable to accomplish the same results on EtherCAT drives, even though I compared all parameters. The filters are all off or minimum, but i have approximately 12000PUU following error on EtherCAT drives even though the motors are running freely without any load - they are only on the test bench.
The only difference is load inertia ratio which is ~5 when on machine and 0 in case of unconnected motors.
Might it be, that unconnected motors are unable to be tuned properly?
you seem like you are an expert in servos field, so I will try my luck with this question:
I have both delta B3-L and B3-Ethercat drives
B3-L (step-dir) are currently hooked up to my machine using mesa card 7i95t and they are tuned via delta software to practically zero following error when checking scope in delta software (except for some minor when starting and stopping. like 0.006mm on 5mm ball screw).
However I am unable to accomplish the same results on EtherCAT drives, even though I compared all parameters. The filters are all off or minimum, but i have approximately 12000PUU following error on EtherCAT drives even though the motors are running freely without any load - they are only on the test bench.
The only difference is load inertia ratio which is ~5 when on machine and 0 in case of unconnected motors.
Might it be, that unconnected motors are unable to be tuned properly?
Please Log in or Create an account to join the conversation.
02 Jul 2024 08:38 - 02 Jul 2024 11:06 #304213
by endian
Hello gentelmen,
it is very interesting reading over this topic around timing and control modes etc... but I can strongly recommend to not calculate servo powerrate to power factor of servo drive. I can recommend to calculate torque or intertia mass(which are in the end torque) which are in the end current...but no every servo drivers running at same voltage and there schould be difference finally at power output, which make a sense for final user... old japanesse servos running on low voltage but high current... nowday are solutions different
I have talking about open servo solution with local Siemens 840D expert the he recommend me maximum 1/4 of motor as reserve for final solution... It is great compromise about final tunning and overoscillation factor...
regards
Replied by endian on topic Position vs Velocity mode
Of course.
Well that is simple yet complex to explain. First, is the following error in the drive a match to the one derived in LCNC. The TP is in the drive so LCNC is not the ideal place to see the true FE.
In position mode, the controller should only need to send position commands as needed. It does not need to even know whether the following error exists given the actual position is dynamically controlled locally in the drive. Now, there are considerations in excess error. Time delay of the cyclic updates. Properly sized servo motors for the load(this is vital to ensure you have a 125% power to load ratio - see final note below), and the FF forward parameters which will ensure enough torque is available to maintain P/T or velocity until the loop position becomes zero. The position control loop receives a command to move 1" at 10 IPM. It will then take that 1" and use the Delta to start positioning the servo via the position FB loop to drive the motor from 1" to zero. The error is calculated within the Delta. The job of the Position loop is to make it to zero in the T requested. If it sees that the T is being stretched it will request more torque to compensate and if to early it will remove torque to comp that. The issue can be in many cases that the LI or load inertia is too great in both ACC/DEC states and continuous travel.
Most higher level drives have several params that adjust the servo response time, power levels, and FF(Aka Loop Gain). These drives also have dynamic auto tuning and if the input calcs for your inertial loads are accurately calculated will allow the auto tuner to account for the calculated load while tuning for you. But, that is the caveat. You must ensure that you have properly calculated the true inertial load of your axis.
Final Note -
The axis has a load characteristic before it actually starts cutting. Cutting requires additional torque to ensure the loop is maintained else you may have a perfectly tuned machine and fined out later while milling a slot that the error is pretty wide and may even see issues with blending or ovular interpolations. It is key to ensure that you know the static load(unloaded machine not cutting) and the dynamic load(machine moving the static while cutting adding a variable load). The math can be a bit much but there are many calcs out there in the ether to help. Once you know that value of what is specifically required, as a rule engineers like myself add 10-25% additional motor KW to ensure that the motion can maintain P/T and make targets without under shoot or overshoot and minimize oscillations at idle.
So if my calc says I need .75kw to handle S and D loads, then I install a 1kw servo. Keep my FF low, and use minor filter adjustments to cancel out ACC/DEC response at higher V.
Following error is more a measure of the servo response not the command response of the controller if in ECAT mode. ECAT can be used in closed loop of course, but that is redundant and increases chances of issues of imbalance of power. ECAT wants to separate concerns. Controller decides where the servo should go, tells the servo go here, the servo does it's job and next. If the servo has an issue, it has its' own ability to stop before disaster. Like I said, ECAT is better at point and shoot than have a controller try to manage everything. That would be like racing a Ferrari while hooked to a tow truck. It works, but the tow truck(controller) is never going to be a Ferrari(servo).
Hope that helps.
PS - Closed loop stepper drives and motors are not Ferrari's. More like a Lota. Lol. But, you can put a spoiler on a Lota and it looks pretty cool.
Hello gentelmen,
it is very interesting reading over this topic around timing and control modes etc... but I can strongly recommend to not calculate servo powerrate to power factor of servo drive. I can recommend to calculate torque or intertia mass(which are in the end torque) which are in the end current...but no every servo drivers running at same voltage and there schould be difference finally at power output, which make a sense for final user... old japanesse servos running on low voltage but high current... nowday are solutions different
I have talking about open servo solution with local Siemens 840D expert the he recommend me maximum 1/4 of motor as reserve for final solution... It is great compromise about final tunning and overoscillation factor...
regards
Last edit: 02 Jul 2024 11:06 by endian. Reason: 640 to 840
Please Log in or Create an account to join the conversation.
02 Jul 2024 10:20 #304219
by Donb9261
Replied by Donb9261 on topic Position vs Velocity mode
I doubt it. It is a hard question to answer without seeing the settings for both sides. The B3 manual is a very lengthy one. I would start with ensuring the electronic gear ratios are set correctly and that the values match on both LCNC and the drive.
I am not too familiar with Delta products to be honest.
I would check that the motor type settings are correct, then EGR values. If the results are the same, then you may need to send a tech support ticket to Delta with the drive model and motor model with encoder type.
If you are running the motors unconnected to LCNC and the results are drawn from the Delta tuning software then I suspect the motor/drive settings are not correct. PPR for inc encoders or bit specs for abs encoders must be set correctly. Also verify the drive/motor current is compatible. I assume these have no brakes on the motors that are still engaged.
I am not too familiar with Delta products to be honest.
I would check that the motor type settings are correct, then EGR values. If the results are the same, then you may need to send a tech support ticket to Delta with the drive model and motor model with encoder type.
If you are running the motors unconnected to LCNC and the results are drawn from the Delta tuning software then I suspect the motor/drive settings are not correct. PPR for inc encoders or bit specs for abs encoders must be set correctly. Also verify the drive/motor current is compatible. I assume these have no brakes on the motors that are still engaged.
The following user(s) said Thank You: zmrdko
Please Log in or Create an account to join the conversation.
02 Jul 2024 10:43 #304228
by Donb9261
Replied by Donb9261 on topic Position vs Velocity mode
Servo current is always calculated from the the end effect torque requirements and load inertia.
Velocity, weight, rigidity, and friction coefficients must be calculated +=2%. There are other factors to consider such as gear, belt, ballscrew driven axis. Whether one uses a precision gearbox to increase torque.
In the case of CNC, the cutting tool will add additional torque requirements but are variable sometimes needing higher response rates to remain on P/T path. In these cases, an appropriate safety factor for torque requirements is needed. The cutting will either try to pull the tool or push the tool which the servo must respond to. If I incorrectly size to a machine without the cutting tool consideration the drive may not have the excess power to control the dynamic load and will cause indeterminate cutting conditions especially through an interpolation move where one axis cannot stay in sync due to the dynamic load condition.
The drives available today have higher dynamic response rates. In many cases they have a 3x peak load that can be accessed in the dynamic range for a n time value based on the drive characteristics. But, this type of drive is more expensive.
Regardless, every drive has a specific set of characteristics and every motor has the same. The calculations for the axis are the same and your choice should be based on your specific application. In general, if the true dynamic load is unknown, it is best to choose a power range above the known values to account for your actual application. 125% of net need is usually a solid safety factor to assist with the dynamic loads for CNC machining.
If using Chinese servo motors and drives, I have found that in most cases the values given for the actual drive/motor combo are well, over blown. I always use a 135% to 150% safety factor for these motors to account for the variability of the actual specs.
Do your homework before you buy. Know your specific application. If unsure, then many servo OEM's will assist with the calculations if you can give them relatively accurate values for your machine axis. The math is not easy for sure.
Velocity, weight, rigidity, and friction coefficients must be calculated +=2%. There are other factors to consider such as gear, belt, ballscrew driven axis. Whether one uses a precision gearbox to increase torque.
In the case of CNC, the cutting tool will add additional torque requirements but are variable sometimes needing higher response rates to remain on P/T path. In these cases, an appropriate safety factor for torque requirements is needed. The cutting will either try to pull the tool or push the tool which the servo must respond to. If I incorrectly size to a machine without the cutting tool consideration the drive may not have the excess power to control the dynamic load and will cause indeterminate cutting conditions especially through an interpolation move where one axis cannot stay in sync due to the dynamic load condition.
The drives available today have higher dynamic response rates. In many cases they have a 3x peak load that can be accessed in the dynamic range for a n time value based on the drive characteristics. But, this type of drive is more expensive.
Regardless, every drive has a specific set of characteristics and every motor has the same. The calculations for the axis are the same and your choice should be based on your specific application. In general, if the true dynamic load is unknown, it is best to choose a power range above the known values to account for your actual application. 125% of net need is usually a solid safety factor to assist with the dynamic loads for CNC machining.
If using Chinese servo motors and drives, I have found that in most cases the values given for the actual drive/motor combo are well, over blown. I always use a 135% to 150% safety factor for these motors to account for the variability of the actual specs.
Do your homework before you buy. Know your specific application. If unsure, then many servo OEM's will assist with the calculations if you can give them relatively accurate values for your machine axis. The math is not easy for sure.
The following user(s) said Thank You: endian
Please Log in or Create an account to join the conversation.
02 Jul 2024 10:58 #304237
by endian
your thread in the linuxcnc are running at oversample 8kHz .. what is your confing for them ? hardware and else.. ethercat has which time period ?
Replied by endian on topic Position vs Velocity mode
hello zmrdko,Thank you for explaining. So basically we are better off with position mode. Because servo drive is better at handling position commands from linuxcnc. I am running 8kHz linuxcnc servo thread which is the same as 8kHz cycle in B3 drives. The following error showed in servo drive is basically zero with proper tuned servo drive. The linuxcnc shows following error 0.22mm at 3000mm/s speed and 0.44mm at 6000mm/s and 0.88 at 12000mm/s. Does it mean that I should just set MINFERROR in linuxcnc with some room (so that I dont get following error errors), because the the following error which lonuxcnc shows is not the true following error? I will come back with screenshots and exact values later.
your thread in the linuxcnc are running at oversample 8kHz .. what is your confing for them ? hardware and else.. ethercat has which time period ?
Please Log in or Create an account to join the conversation.
02 Jul 2024 11:21 #304238
by endian
Replied by endian on topic Position vs Velocity mode
Delta products are great but servos and VFDs are really budget solutions.. delta asda with underestimated EEPROM which you have to overwrite before you want to use the ethercat is joke... if you want to use that as PTP manipulator or plasma with no expert tunning - ok... but for critical applications I do not recomend it ... there is more sophisticated solutions on the marketI doubt it. It is a hard question to answer without seeing the settings for both sides. The B3 manual is a very lengthy one. I would start with ensuring the electronic gear ratios are set correctly and that the values match on both LCNC and the drive.
I am not too familiar with Delta products to be honest.
I would check that the motor type settings are correct, then EGR values. If the results are the same, then you may need to send a tech support ticket to Delta with the drive model and motor model with encoder type.
If you are running the motors unconnected to LCNC and the results are drawn from the Delta tuning software then I suspect the motor/drive settings are not correct. PPR for inc encoders or bit specs for abs encoders must be set correctly. Also verify the drive/motor current is compatible. I assume these have no brakes on the motors that are still engaged.
Please Log in or Create an account to join the conversation.
Time to create page: 0.089 seconds