Machsupport Forum

Third party software and hardware support forums. => HiCON Motion Controller => Topic started by: lsgreen on June 22, 2018, 01:34:43 PM

Title: Following Error
Post by: lsgreen on June 22, 2018, 01:34:43 PM
I’m hoping someone can help me understand my following error. My system uses a Hicon 7766 with the closed loop option. I understand that the error is the difference between the commanded position and the actual position of a motor, (in my case it is steppers). My problem is that I repeatedly get a following error limit stoppage on motor 2 (Z axis) even at very slow speeds overall. The limit is set at 500 for that axis and i guess my question is what is a recommended allowance as well as other approaches to correct the error, i.e. motor settings such as acceleration ect. Any suggestions are welcome.
Thanks, Lou
Title: Re: Following Error
Post by: joeaverage on June 22, 2018, 03:18:16 PM
Hi,
I assume that you have encoders on the steppers?

If your stepper lags behind the commanded position the stepper driver will have to 'add some additional steps in the pulse stream' to have it catch
up. That would require an intelligent driver. What drivers are you using?

Note the HiCon can 'close the loop' and exert PID dynamics on servos but cannot insert steps into a pulse stream.

Craig
Title: Re: Following Error
Post by: lsgreen on June 22, 2018, 04:13:50 PM
Craig,
Thanks for the reply, My drivers are 2HSS86H Chinese closed loop drivers, and yes on encoders. I’m doubtful that they are “intelligent”, documentation is not very comprehensive. I understand it is a function of the Hicon to re-sync lost steps. What I don’t know is what is an acceptable range to set for a following error on the Hicon setup page. I don’t want to set the range so wide that the work gets sloppy but last night it stalled where the Z had to retract leave a simple tab on a straight cut. Like I said the machine was not moving very fast, only ~ 60 ipm. Seems really basic.
Thanks, Lou
Sorry about your friend
Title: Re: Following Error
Post by: joeaverage on June 22, 2018, 05:34:39 PM
Hi,
if your drivers are closed loop that means the loop is closed by the Driver and the Stepper,
the HiCon has nothing to do with it. The HiCon provides pulses to the driver at the behest of
Mach and then the driver/stepper moves to the correct position. If the stepper fails to arrive
at the correct location the driver will add or subtract steps to the stepper to bring it closer.
If it fails to do so because of overload or it gets just too far behind the it faults and produces an
alarm. (Section 3.1 page 7).

I am sorry to have to tell you that closed loop steppers are really very little better than ordinary open loop steppers.
They are still a stepper motor and their torque falls off very rapidly with speed. Most steppers will have 20%
or less of their rated torque at 1000 rpm. Closed loop steppers are exactly the same. If some manufacturer
tries to tell you otherwise they are lying....to get you to part with your money.

Another,if not a lie, a half truth is that the closed loop stepper will catch up lost steps. If your stepper is operating
at speed and it loses a step because its torque is no longer enough to keep up then a closed loop stepper driver
will insert another step in the pulse stream but because the stepper is overloaded it WONT catch up! If this is repeated
the driver will recognise that the stepper is lagging the commanded position by a too great a margin and 'fault'.
The truth is that a well designed, driven and specified open loop stepper will NOT lose steps, and if its overloaded
(speed/acceleration) to the extent it does start to lose steps a closed loop stepper will also lose steps....and for exactly
the same reason.

The manufacturers of closed loop steppers play the marketing card very well, they capitalise on your fear of losing steps.
One claim that they can make and is justified is that their devices can give you much higher resolution (4000 steps per rev
verses 200 step per rev openloop).

I personally am of the opinion that the premium paid for closed loop steppers bring too few advantages to justify the extra cost.
Just a little more and you can have genuine AC servos and they will KICK STEPPER ANUS ALL DAY LONG!!!

If you use proper AC servos then you don't need the 7766 extension board. All AC servos and their matching drive
close the loop, the HiCon controller is not required to do so. Typically the servo manufacturer, having control of the
design of the servo drive, have a closed loop performance better than you or I could achieve by programming
the HiCon.

Craig
Title: Re: Following Error
Post by: joeaverage on June 22, 2018, 05:59:30 PM
Hi,
I started reading up on the 7766 board, thinking it was the expansion board that made the HiCon
capable of closed loop control.....sorry. The 7766 IS the HiCon. The HiCon is not closed loop capable
without  software activation, an optional extra.

The HiCon unit passes commands to the drier in the form of Step/Direction pulses and the  driver/stepper take it
from there. The HiCon is not involed in closing the loop and has no control or even awareness that the
stepper cant keep up. If the stepper cant keep up, as measured by the difference between its actual encoder
position and its commanded position, the 2HSS86H  faults.

I guess that is the problem you are having....the Z axis driver signals a fault?

I noted in the manual  that there are a number of conditions that cause the fault. I suspect you will
have to experiment with them until you find which feature is causing you grief. It could be Position Error
but it could also be Over Current or Over Voltage.

I will do a little more reading and maybe we can come up with a plan to diagnose whats going on.

Craig
Title: Re: Following Error
Post by: joeaverage on June 22, 2018, 06:08:48 PM
Hi,

Quote
10.2 Have a red alarm after running a small angle
 In the parameter of the driver, phase motor phase
sequence is properly connected. Refer incorrectly identifies
the drive motor phase sequence corresponding
connection.
(section 10.1 page 34)

Is it possible that you have hooked up the phases in reverse. Easy enough to swap (just one winding) and try again.

Craig
Title: Re: Following Error
Post by: lsgreen on June 22, 2018, 08:39:30 PM
Craig,
Thanks again, yes, I am using the Vital Systems Hicon Integra 7766 with closed loop activation. It is the actual motion controller and not an addon board as you correctly concluded. In conjunction with it is a 7737 encoder board, also Vital Systems. The encoders report directly to the 7766 thru the 7737 making the 7766 aware of the precise motor positions at all times. All calculations with regard to encoder feedback, step generation, command position, and following error are handled internally by the 7766.  I am not having any faults arising within the drives themselves as their setting perimiters are intentionally much wider than 7766 thus avoiding driver faults. I am having some success with adjusting motor settings within Mach4, acceleration in particular so it looks like a path to follow. I totally agree that servos are far superior to steppers in an arrangment, but my best friend knows my wife far to well and is not about to leave with her, so there I am stuck steppers.

Thanks, Lou
Title: Re: Following Error
Post by: joeaverage on June 22, 2018, 09:35:44 PM
Hi,
closed loop steppers REQUIRE that the encoder be connected to the matching drives. Having the 7766 included in the loop is redundant.
The 7766 cannot arbitrarily decide to add or subtract a step, that is done by the stepper driver. The wiring diagram of the 2HSS86H clearly shows the
encoder hooked to the driver.  You are trying to insert the HiCon in the loop and yet the HiCon CANNOT control the stepper....servos yes....steppers no.

Additionally the manufacturer of the stepper also designed the driver. I rather think a manufacturer has the resources to do a much much better job than you or
even Vital Systems.

I use an ESS from Warp9 and it has never made any claim to being able to close a servo loop. I bought a second hand Allen Bradley AC servo of 1.8kW for a spindle motor.
Its the first time I've had a chance to play with an AC servo, very very impressed.  It beats the hell out of the servos we experimented with at University all those years ago.
The ESS provides the commanded position in the form of step/direction pulses just like the HiCon. Those pulses are feed to the Allen Bradley servo drive and the encoder
is hooked to the servo drive. Thus its the servo drive that closes the loop, not the ESS. This is the same arrangement you'll have to use because the HiCon cannot control the stepper
drive directly, that requires the programming and circuitry built into the drive and its not available for you to fiddle with. Both my ESS and your HiCon are being utilized as open loop
command generators and the driver/servo in my case or the driver/stepper in your case are closed loop. If the closed loop fails to accurately follow the commanded input it will signal
the ESS/HiCon with a 'following error' fault.

Craig
Title: Re: Following Error
Post by: joeaverage on June 22, 2018, 09:55:52 PM
Hi,

Quote
The 7766 cannot arbitrarily decide to add or subtract a step, that is done by the stepper driver. The wiring diagram of the 2HSS86H clearly shows the
encoder hooked to the driver.  You are trying to insert the HiCon in the loop and yet the HiCon CANNOT control the stepper....servos yes....steppers no.
I have the HiCon manual open in front of me and my previous statement may be wrong, maybe the HiCon can introduce extra steps as required.

However even if that is the case the 2HSS86H REQUIRES the encoder be plugged in, if you don't the drive has no way of knowing that the stepper is trying to follow the commanded
input and will produce a 'following error'.

You have steppers and drivers that form a closed loop AND a HiCon which can also close the loop. While you might possibly arrange to have both operating if you don't have the encoder
feedback to 2HSS86H it will fault no matter what the HiCon does.

Craig
Title: Re: Following Error
Post by: lsgreen on June 22, 2018, 10:31:47 PM
What you are saying is correct, the encoders also report to the drives and the drives have preset perimeters (some user settable and others not) and handle their business accordingly. All I am saying is that with the 7766 sharing the encoder positions the pulse train is already modified before it is ever sent to the drives and if an out of tolerance position is detected (greater than the user set allowance which in my case is 500 pulses) the 7766 issues an out of tolerance following error followed by a stop command to Mach4. This happens before the drives ever exceed their presets. Thus the drives never enter a fault state. Short story made long, the adjustments in the motor tuning solved my problem. Everything is running fine, and as always if the machine makes a mistake I can always trace it back to the operator (that's me) error.

Thanks Craig, your input is valuable.

Lou
Title: Re: Following Error
Post by: lsgreen on June 22, 2018, 10:37:47 PM
If my reply seems confusing, I was writing while you were replying. Yes. absolutely the encoders are connected to the drives. Nothing would work if that wasn't true.
Title: Re: Following Error
Post by: lsgreen on June 22, 2018, 10:52:57 PM
Craig,
I would just like to add that you are a pit bull (and I mean that in the best possible way) in getting to the bottom of things. I mean I can see you've got the books out and really dug into this thing, spending more time than anyone would hope to expect.

Kudo's

Lou
Title: Re: Following Error
Post by: joeaverage on June 22, 2018, 11:06:28 PM
Hi,
kool, That was my concern that if you did not have the encoders hooked to the stepper drives everything else tips over.

The next question is why bother? You have two ways to close the loop, namely the drive and stepper  AND the 7766. Why have both? My question is that one
loop could be counteracting the other.

May I make a suggestion...just have the drive/stepper close the loop and have the 7766 as open loop command generator and use the scope facility built into the drive
software to watch the error. In order to do this you would have to increase the accel in Mach4 to an effective infinite and widen the following error window in the drive
to as wide as possible or even turn it off. Note that all of that can be done by programming, shouldn't have to rewire or buy extra bits.

Then you could issue a G0 Z100 say, an effective Step move. Initially the error would be 100 units and as the axis accelerated it would diminish and end when the stepper assumed position 100.
You could display this with the scope. Now try reducing the acceleration in Machs tuning and try again. Eventually you will reduce the acceleration so that the maximum error is some small
value, say 0.05mm say. You will then have found the maximum acceleration that your Z axis can attain AND remain within a given tolerance. The scope will allow you to view the results of changing
the PID parameters also. What the scope would not show you is if the 7766 changes the input command in response to its own feedback dynamics. Thus if the 7766 were not just an open loop
command generator then you tuning effort would be masked by the 7766 dynamics.

As far as the following window is concerned my only experience is my servo. It has a 2000 line encoder or 8000 count per revolution. The default following error is 20 counts or 0.9 degree and its zero window,
that is when its so close that it doesn't bother trying to reduce the error any more is 4 counts or 0.18 degree.

If your drive follows the same idea then your 1000 line, 4000 count encoder with a 500 wide following error would be 1/8 a revolution or 45 degrees, which seems awfully high to me. With a 5mm pitch ball screw
that would equate to 0.625mm, quite substantial.

Craig

Title: Re: Following Error
Post by: lsgreen on June 22, 2018, 11:55:25 PM
Craig,
I'm looking at your questions and suggestions one at a time and trying to answer so I might sound disjointed, but here goes.

  The reason have closed loop drives and the 7766 at the same time is an economic one. My motors are ~1800 oz. nema 34's and I could get them in a closed loop set cheaper than I could get just the motors and encoders, and cables alone. The drives were just a bonus if you could call it that. I didn't really need them, or want them. I already had drives for my old motors, but the motors where single shaft, problematic for mounting encoders, hence the new.

As far as implementing your suggestions, it will take me a while to digest all you have put in front me but at first glance makes sense. I'm gonna try.


As far as my following error settings being at 500 with my new acceleration settings the actual error during finishing of the project I was working on only reached 40 one time which was quickly compensated for and usually only 1-2 I just didn't want the machine to stop again. Super simple cutout of a cabinet where a mistake would be hard to find.


You've helped me immensly in undersatanding what I'm dealing with in this following error thing. Things can only get better but like all things, its a journey.


Thanks
Lou
Title: Re: Following Error
Post by: joeaverage on June 23, 2018, 01:02:58 AM
Hi,
OK that explains the origin of the different styles of loop closure.

I bought a big servo a while back for a spindle motor, 2.8kW and 14Nm. Its fitted with a resolver rather than an encoder so drives are a rare as rocking horse s*********t.
I decided to make one of my own, electronics is my thing and studied control engineering at University. I have had to learn and in many cases relearn stuff to do it.
I always maintain that the value of a hobby is best measured by the things you learn in pursuit of it. In which case my decision to make my own drive has been very valuable.

Amogst the things that you need to know about Field Oriented Control is control loops. There are some very good YouTube clips by Texas Instruments of Field Oriented Control, really well
done and a fascinating insight as to how AC servos work.....highly recommended.

The upshot is that for an AC servo to work you need three control loops. The innermost one is the acceleration (an expression of torque which is proportional to current) loop, then the next outer loop is the velocity control loop
and then the outer most one is the position loop. The advice is that if you are going to combine loops you have one loop per differential time. Thus the torque (or acceleration)loop is 'integrated'
(mathematically) to the velocity loop, which is in turn integrated (again in the mathematical sense) to the position loop.

Your drives AND the 7766 have three levels as well but you now have two acceleration loops, two velocity loops and two position loops. I suspect that the multiplicity of loops of the same
time 'dimension' will interact in a way that may be very hard to sort out.

I would certainly in the first instance reduce the complexity of your Z axis by having the one feedback control. Two different ways:
1) As I've already suggested use the 7766 as an open loop command generator and have the drive/stepper as the one feedback control element OR
2)Replace your drives with non-smart drives, ie just plain step/direction stepper drives like the AM882 from Leadshine and then have the 7766 close the loop.

If you already have plain ordinary drives 2) is perfectly doable but having to buy new drives just to avoid the complication of your current ones seems a real pain.
I am not aware that there is any advantage of one or the other. Having said that I would be tempted to guess that the manufacturer of your stepper and drive has made a combination
that works well together and would be easiest to achieve a good result. I do not mean any disparagement to the 7766 but it does lack the software driven scope and also its by
necessity more generalized in nature resulting in a more difficult tuning task.

I think this is the least confusing way forward. No matter how you work it out a good result is determined by the overall PID dynamics. Lets say you choose one of the above strategies
and find that the best performance of your machine is had with a P(roportional) gain of 1400, an I(ntegral) gain of 200 and a D(ifferential) gain of 175. If you now decide that you want
both the drive AND the 7766 to participate in the PID dynamics you at leat know the approximate distribution of gains required....so if you had the P gain of the 7766 at 14 then the
P gain of the driver would have to be about 100. (14 X 100 = 1400, our previously discovered sweet spot for Proportional gain) Alternatley you may decide the differential component
of the driver is numerically very noisy, a common problem with differentiators so you might set the drive D gain to 1 but have the 7766 D gain set to 175 and take advantage of the less noisy
differentiator Vital Systems built in.

Is your head spinning yet?.....mine sure as hell is!!!!

Craig
Title: Re: Following Error
Post by: lsgreen on June 23, 2018, 01:41:08 AM
Like a top ~~~~~~~~~~~~~~~
I do have four MA882's lay'n around doing nothing, might be worth a shot to give them a try. Much more complicated than I thought. I just figured those "smart" drives was just living the life, with the 7766 doing all the thinking.

You've got me thiking again, never a good thing, hope i don't see any smoke this time.

Lou



Title: Re: Following Error
Post by: joeaverage on June 23, 2018, 01:56:39 AM
Hi,
kool.

From the point of view of simplicity you could try the current drives but the 7766 open loop, after all that's only keystrokes.
If you have plain drives you could try those for the sake of wiring them in.

Two reasonably straight forward experiments you can try.

I suspect that if you take the time to learn to use the software scope you will learn a lot about your system and what an 'optimum' solution looks like
rather than 'by guess and by God' approach.

Craig
Title: Re: Following Error
Post by: jcoldon on June 29, 2018, 06:27:44 PM
why not just use clearpath servo the feedback is built in no need to add a option board to the hilcon 
Title: Re: Following Error
Post by: joeaverage on June 29, 2018, 07:14:24 PM
Hi,

Quote
why not just use clearpath servo the feedback is built in no need to add a option board to the hilcon 

Clearpath  servos are expensive, very good certainly but represent anywhere between an extra 50% to 200% increase over DMM and/or Delta servos for the same power
AND DMM and Delta have way better encoders and electronic gearing.

The extra cost of servos is still considerably more than the activation fee of the HiCon. OP howver alredy has closed loop steppers and matching drivers so the HiCon activation is not
strictly required.

Having said that given that OP has both Hicon activation and some plain non-feedback stepper drivers there is the possibility for OP to experiment with the two ways of closing
the loop. That experimentation will markedly improve the prospect of arriving at an optimum solution.

Craig
Title: Re: Following Error
Post by: lsgreen on June 29, 2018, 07:59:18 PM
Craig,
I haven’t yet gotten around to swapping out the closed loop drives yet, but that is the way I intend to go. That seems to me to be really good advice.

Lou
Title: Re: Following Error
Post by: jcoldon on June 29, 2018, 08:06:12 PM
assume you mean dynamic motor motion stuff..  and the delta servo system.. your way more in price then a clearpath servo plus they are step direction they have built in drivers  and the feedback is built in  .. stepper killer ..  your motor selection would depend on what you are powering  mill plasma or a router
Title: Re: Following Error
Post by: lsgreen on June 29, 2018, 08:30:02 PM
No, sorry for not being more clear, what I meant was swapping my closed loop drivers for leadshine AM882 drivers (regular open loop) which I already own, thus avoiding closing the loop with to different devices which is what average Joe was advising against. Presently I have the loops closing within  the drives and the 7766, although the perimeters are set much closer in the 7766 than the drives. That being the case, the drives never get within an error condition. But as I understand from Craig’s explication is that this is far from ideal because of many reasons he described and probably more. It’s just simplifying an overly complex setup.

Thanks,
Lou
Title: Re: Following Error
Post by: joeaverage on June 29, 2018, 08:48:26 PM
Hi,

Both DMM and Delta are genuine AC servos but have a separate but matching drive, not built in like Clearpath. They are Step/Direction like Clearpath.

DMM= Dynamic Motor Motion

A DMM 60V servo drive $138
A DMM 200W servo      $137
Total                           $275

Clearpath CPM-SDSK-2331S-RLS (193W cont) $333

And if you want to get more power then you'll have to go to the SDHP series:
Clearpath CPM-SDHP-3421P-ELN  (350W cont)     $618

Whereas the DMM offering:
A DMM 60V servo drive   $138
A DMM 400W servo        $147
Total                             $285

So for a 350W/400W servo the clearpath offering is over twice the DMM equivalent.

The DMM have 16bit  absolute encoders whereas Clearpaths have 6000 count incrementals, and 16bit absolute beats 6000 count incremental any day of the week.

Make no mistake that Clearpaths are good, and they play the marketing card very well capturing customers who want to upgrade from steppers
but they are in fact nothing special. All good AC servos can claim all and more than Clearpath and for cheaper too.

Craig
Title: Re: Following Error
Post by: joeaverage on June 29, 2018, 08:52:18 PM
Hi,
to OP: still cant work out why you persist on using the 7766 to close the loop, the stepper/drive are a matched pair and will do better than the 7766.
Additionally if you use the closed loop stepper drive you'll have the software driven scope to tune your setup whereas you wont with the 7766.

Craig
Title: Re: Following Error
Post by: joeaverage on June 29, 2018, 09:08:32 PM
Hi,
right at the beginning of this thread you asked about following error, how it affected your setup and why it seemed to trip out to early.

The software scope in the tuning/setup software that accompanies your closed loop stepper drivers is by far  the best way to answer your question.
I you chose to close the loop with the 7766 then that opportunity is gone and you'll have to  do the 'by guess and by God' method.

Craig
Title: Re: Following Error
Post by: lsgreen on June 29, 2018, 09:34:10 PM
Craig,
I’m not opposed to using the drives to close the loop, but there is a bit of rewiring to go that way . The outputs j2 thru j4 would have to be used on the 7766 as opposed to j8 which carries all step and direction as well as all encoder signals. J8 connects through a 24 pin cable to a 7737 encoder board which collects encoder signals and outputs step and direction signals through rj45 Ethernet cable connections. (It is the j8 circuitry that is activated with the closed loop purchase from VSI.) Without the use of  j8 I’m not sure how to wire the encoders. Just simpler at my level to use the 7766, not saying that there isn’t a workaround for the encoder inputs, l just haven’t dug into it yet. It may be possible to output step and direction through j2 - j4 while collecting encoders through j8 thus not closings the loop in the 7766, but I don’t yet know that. As far as using the built in software scope, that has never displayed any motor information at all, are you suggesting that maybe that function only works with the 7766 in an open loop condition? That would be good news indeed.

Thanks for your interest and any input you have to offer is much appreciated,
Lou
Title: Re: Following Error
Post by: joeaverage on June 29, 2018, 10:24:00 PM
Hi,
the scope software is a part of the tuning software and it derives its data from the closed loop stepper drive. No closed loop stepper drive...no scope.

If you use the 7766 as the loop closing device, and contrary to simplicity sake retained the closed loop drives so you can use the scope, the scope would display
the error between the stepper drive input and the stepper encoder, ie it would NOT tell you anything about the dynamics of the 7766 nor would it be able to display the commanded input to
the 7766.

If you wish to use the software scope then the 7766 has to be open loop, ie just a command generator.  If it has dynamics of its own then the scope wont help you tune much as part of the tuning effort
is not observable.

An ordinary scope wont help you either as one input to the scope would be the encoder output which as you know is two signals in phase quadrature. Likewise the input to the control loop,
if the 7766 even makes it available is step/direction. Step/direction is similar to Delta modulation familiar to most communication engineers. A Delta de-modulator would be simple enough
to build. The encoder output would have to be converted to step/direction and that result feed through another Delta de-modulator.

How's you electronics? It is possible but there would be quite an effort to produce signals that could usefully be displayed on a scope.

I still think your best alternative is let the stepper driver close the loop, not the 7766. Either will work but one alternative lets you use the diagnostic smarts built in whereas to other
alternative does not.

Running the 7766 in open loop manner will be easy, after all everyone who has bought one but who has not bought the closed loop activation HAS to run open loop!
If you do run open loop the encoders don't have to be plugged into the 7766 AT ALL! All in all it should be a simpler wiring than what you have at the moment.

Craig.
Title: Re: Following Error
Post by: lsgreen on June 29, 2018, 11:03:36 PM
Craig,
Your correct on all points as usual, and it might be that you have won me over completely. It’s just an attempt on my part to justify the money I spent on this product to start with, notwithstanding explaining to my wife why I didn’t need to do that (as I said briefly before, my best friend has NOT run away with my wife).
 
I understand that I don’t need to give the 7766 any encoder info at all but if I do then the DRO’S in Mach4 will display the actual machine position based on encoder input as opposed the commanded position. Just seems there has to be some value in that.

Thanks
Lou
Title: Re: Following Error
Post by: joeaverage on June 30, 2018, 12:12:27 AM
Hi Lou,

Quote
I understand that I don’t need to give the 7766 any encoder info at all but if I do then the DRO’S in Mach4 will display the actual machine position based on encoder input as opposed the commanded position. Just seems there has to be some value in that.
Sorry to burst your bubble but Mach is not a feedback controller. The Hicon unit does not routinely relay information back to Mach. If it were to do so the communication lag
would mean the DROs would always be out of date. Mach can read an MPG or encoder and display it in a DRO provided you don't mind it being a tenth of a second out of date.

Hooking the encoders to the 7766 is for the 7766's benefit only. The 7766 can use that to close a loop in realtime whereas Mach cannot, its way way WAY TO SLOW!
A communication loop in Mach3 is of the order of 25ms one way! Mach4 can do a lot better than that, about 10ms as default and you can push it to probably less than 5ms
but that is still to slow for genuine feedback control.

Just to give you some background:  a feedback loop has a refresh rate (sometimes called bandwidth and various other terms). So every so often the control loops get a measurement
of the current error between commanded position verses actual position. Lets say that happens 100 times a second, ie every 10 ms.

The Nyquist sampling theorem assures us that the maximum frequency signal that can be represented by a 100 sample/second stream is half that or 50Hz.  As a control engineer you
yawn, yes its theoretically possible to represent a 50 Hz signal with 100 sample/second but you get no 'discrimination', that is to say the fideility is very poor. You might get fair
representation of a 5 Hz signal with 100 samples per second, but even that would be very grainy or poor resolution. A feedback control loop with a 100 Hz refresh rate will have
at best a 5Hz bandwidth, ie it will be as slow as a wet week! And even a 5Hz bandwidth is pretty sketchy and grainy.....

A servo loop will have refresh rates of the order of 20kHz, for a Nyquist rate of 10 kHz, and an acceleration loop bandwidth of about 1kHz and a position loop bandwidth of about 100Hz.
Thus you can see Mach3 with a refresh rate of about 25 per second and even Mach4 at 100 per second is a long LONG way short of the speed necessary for a high fideility closed loop
control system.

I do understand the inclination to use the activation that you paid for and especially doing what is politic as far as 'her indoors' is concerned..... I would try the method I have outlined
given that it is mainly keystrokes and maybe a bit of wiring. Using the scope feature will teach you stuff in one afternoon that 100 books/videos/forum posts will never do.
Once you have that knowledge/understanding under your belt THEN try using the 7766 to close the loop, either with or without the closed loop stepper drive. That experience based
understanding of feedback control will allow you to dial in the 7766 really well, maybe as good as the stepper and its even remotely possible you could do better. Without that knowledge
you may find as many others have found that PID loop tuning is a Black Art never to be mastered!

Years ago at University I studied this stuff. We had whole labs set up with various servo systems and all manner of measuring and test gear. We were required to do certain experiments
but were encouraged to do a whole lot more than that. Basically we could fiddle with things as much as we liked....all of it adding to the intuitive understanding of feedback control.
Add that intuitive understanding to the mathematics, and there was a s*********t load of that....

Craig
Title: Re: Following Error
Post by: lsgreen on June 30, 2018, 12:34:23 AM
Craig

Got it, it’ll take some time. Do you want to know how it comes out?
Thanks
Lou
Title: Re: Following Error
Post by: joeaverage on June 30, 2018, 12:47:49 AM
Hi,
sure do, feedback control and all the maths that go with it are pretty close to the high water mark as far as my expertise and
education go. It is very much a challenge to get involved in it all over again, a welcome challenge. I thank you for the
opportunity to do so.

Craig
Title: Re: Following Error
Post by: lsgreen on June 30, 2018, 02:16:41 AM
Craig, your welcome, and thank you.
We’ll pick this up at a later date. “Her inside” has a list about yeh long. Prioritize, that’s word of the day. It’s worth it, 45years and counting.

Lou
Title: Re: Following Error
Post by: jcoldon on June 30, 2018, 08:31:35 AM
if price is a factor then just use a stepper for get the closed loop I have a scratch built plasma with large stepper gear reduction vampire drives and a hilcon controller running mach 4 plasma it never misses a step my gantry is over 100 pounds  just use the right size motor 
Title: Re: Following Error
Post by: joeaverage on June 30, 2018, 04:15:57 PM
Hi,
as OP explained in an earlier post the feedback steppers and drives were cheaper than two shaft steppers and encoders, so in a sense price was a factor and
closed loop steppers and drives resulted.

Like you jcoldon my open loop steppers haven't missed a step in four years. Correctly sized/driven/specified steppers used within their limits DON"T lose steps, they are
remarkably simple, reliable, powerful and very economically priced. They certainly are a boon to hobby CNCers.

I do recall though when I was fist building and operating my mill very concerned about losing steps. At that time I had some cheap drivers and missing steps was a distinct
possibility. As I have 5 phase Vexta steppers good drives are not cheap. I did in the end get proper Vexta 5 phase drivers, they are powered offline 230VAC and have a DC link voltage
of about 150VDC. My steppers now sing along and never even look like missing a step.

None the less the manufacturers trolling their 'closed loop steppers...never miss a step' wares were very seductive. Many a hobbyist have stumped up the dollars to buy. The
manufacturers must be congratulated for their marketing effort, they have made millions by playing on a hobbyists fear of losing steps.

In very similar fashion Tecknics have done a great job marketing their 'stepper killer' servos. Their servos are good but there are better for less. Congratulations to Tecknics.

Craig
Title: Re: Following Error
Post by: Sparkman2 on July 19, 2019, 08:05:41 AM
I had following errors and, after watching the real-time numbers change in the HiCON test page, I changed the gain on the command and encoder so that they would match. The encoder was changed to have a gain of -1 as the encoder responded opposite of the command signal. I also changed the gain of the command to 2. Finally, I had to lower the acceleration and velocity to allow the motors to run without any 'slippage'.