Acramatic 2100 retrofit - Page 2

1. ## Re: Acramatic 2100 retrofit

Last test file

2. ## Re: Acramatic 2100 retrofit

Hi cwatson1982,

Yes, it moves 10 inches
Good now we know the resolution is 83230.72 counts per inch. This can be use to relate errors in counts to errors in inches.

Any higher "I" and it seems good at max velocity but feels very rough at slow speeds.
Yes always reduce gains to have smooth stable motion.

I'm not real sure what kind of position error I should be aiming for as I don't really have any kind of reference
Use the resolution to relate errors in counts to errors in inches (divide by cpi).

I didn't try to get anything too much higher as the machine can get pretty aggressive when oscillating starts.
Now that you have reasonable following you might reduce Max Following Error so that instability will cause the axis to simply disable before becoming too violent.

Your Acceleration setting is crazy high. 60e6 cnts/sec2 / 83230.72 cnts/in = 721 in/sec2 or almost 2G !

However with the Jerk setting of 105e6 cnts/sec3 the acceleration ramps up at a somewhat gradual rate and after ~0.1sec the acceleration reaches ~10e6 cnts/sec2 (123 in/sec2 or 0.32G) it must begin ramping down in order to prevent exceeding the max allowed velocity of 1e6 cnts/sec. So there is no move where the Acceleration limit will ever come into play. Its all pure Jerk limited motion.

A car analogy would be you are told to very gradually depress and release the accelerator and also not to exceed 40mph. After depressing the accelerator like an inch over several seconds, and at 20mph, you must begin gradually releasing the accelerator to avoid exceeding 40mph even though it may be possible to depress the accelerator 6 inches.

Here is an error plot of the large ~5 inch move:

Errors are within +/-30 counts or +/- 0.4 thousands of an inch. Probably not bad for a large (5inch), fast (720ipm), aggressive (0.3G) move.

There is some ringing at ~40Hz at the start of the move:

Since it happens at the beginning of the move and not at the end this would point to something mechanical and non-linear like stiction. Probably too fast to be corrected by the feedback. So you may need to reduce Acceleration and Jerk to balance performance vs shocking the mechanics depending on your application and requirements.

HTH

3. ## Re: Acramatic 2100 retrofit

Originally Posted by TomKerekes
Hi cwatson1982,

Good now we know the resolution is 83230.72 counts per inch. This can be use to relate errors in counts to errors in inches.

Yes always reduce gains to have smooth stable motion.

Use the resolution to relate errors in counts to errors in inches (divide by cpi).

Now that you have reasonable following you might reduce Max Following Error so that instability will cause the axis to simply disable before becoming too violent.

Your Acceleration setting is crazy high. 60e6 cnts/sec2 / 83230.72 cnts/in = 721 in/sec2 or almost 2G !

However with the Jerk setting of 105e6 cnts/sec3 the acceleration ramps up at a somewhat gradual rate and after ~0.1sec the acceleration reaches ~10e6 cnts/sec2 (123 in/sec2 or 0.32G) it must begin ramping down in order to prevent exceeding the max allowed velocity of 1e6 cnts/sec. So there is no move where the Acceleration limit will ever come into play. Its all pure Jerk limited motion.

A car analogy would be you are told to very gradually depress and release the accelerator and also not to exceed 40mph. After depressing the accelerator like an inch over several seconds, and at 20mph, you must begin gradually releasing the accelerator to avoid exceeding 40mph even though it may be possible to depress the accelerator 6 inches.

Here is an error plot of the large ~5 inch move:

Errors are within +/-30 counts or +/- 0.4 thousands of an inch. Probably not bad for a large (5inch), fast (720ipm), aggressive (0.3G) move.

There is some ringing at ~40Hz at the start of the move:

Since it happens at the beginning of the move and not at the end this would point to something mechanical and non-linear like stiction. Probably too fast to be corrected by the feedback. So you may need to reduce Acceleration and Jerk to balance performance vs shocking the mechanics depending on your application and requirements.

HTH
Thanks again Tom!

I tweaked everything a little more today, including lowering accel and got it smoother at lower speeds with a little less error. I can still feel the servoing a bit more than the old control at ~2-3ipm but I am going to work on getting the Y and Z going and see how coordinated movement feels then adjust from there. I added a little dead band temporarily which seemed to smooth things out at lower speeds considerably without introducing any more position error. (can see the amplitude of the error oscillation shrink about half with dead band at 1-2 range and .25 gain)

The machine has always suffered from some level of stick slip.

I really appreciate the help, I have never tuned servos before and there is a lot to learn + experiment with.

4. ## Re: Acramatic 2100 retrofit

Put on hold temporarily; I discovered my X ball screw had dropped 2 return plugs going to have to fix it before I make any more headway.

5. ## Re: Acramatic 2100 retrofit

I got finally got the X ballnut fixed. The adhesive that was used to hold in the return "plugs" failed on 3 of the 8 circuits and dropped the balls in the saddle. Got it all re-packed and moving again. While I was waiting for things to show up for that I got the spindle moving which was fairly straight forward. It's controlled by +-10v and used to run open loop unless orienting or tapping on the old control. I currently have it set up to run closed loop all the time. Low P and some VFF did the trick. Accel and velocity were converted from degrees a second to counts a second from the old control. I tuned jerk by feel and timing when stopping.

I did some reading on tuning position loops with velocity loops and am probably going to play with the x axis a little more before moving on.

6. ## Re: Acramatic 2100 retrofit

Making good progress. I got Y moving and tuned, it was a bigger pain than X was. I copied over the drive parameters from the X drive to the Y drive thinking I would be close by just copying the values from the X channel to the Y channel in kmotion which just resulted in oscillation. Same motors, same drives, same screws, WAY different tuning. I seem to get better results by lowering the velocity integrator in the drives considerably compared to where it was with the old control. I read that a cascading velocity position loop should be tuned inside out (velocity loop first) because typically the velocity loop is faster than the position loop. If I understand correctly I am wondering if in this case the drives velocity loop is actually slower.

In any case I got it tuned to under 20 encoder counts at all speeds, will have to see how it cuts when I get that far. Couldn't get it under 180 counts without lowering the drives velocity integrator.

Tomorrow I will try to get the Z going and look in to homing.

7. ## Re: Acramatic 2100 retrofit

Well, new problem. I am running a test program trying to figure out what I can get away with acceleration wise in kmotioncnc. The performance I get out of the old control seems like it was very reliant on 3rd order motion control In any case my X axis is getting disabled due to following error at a particular spot in the program that consists of a lot of small fast x-z axis moves. Not really sure what is going on.

8. ## Re: Acramatic 2100 retrofit

Hi cwatson1982,

If you post a GCode fragment, your KFLOP and KMotionCNC settings we might be able to see something.

If you want to do a thorough analysis of what is happening you might capture data as Troy did in this Thread.

9. ## Re: Acramatic 2100 retrofit

Tom,

I narrowed it down to:

G19 G2 Y1.0838 Z-0.0306 J-0.0018 K0.0249
G0 Z0.2
X1.8847 Y1.3928
Z0.0501

Removing the G19 line lets the program complete; I don't actually have the Z axis hooked up or configured, so not sure if that's the issue but for whatever reason it causes a huge following error on the X channel instantly and disables it. Maybe an issue with the post processor? not real sure

I'll run the data capture program after I hook Z up and see what it does.

10. ## Re: Acramatic 2100 retrofit

Hi cwatson1982,

Hard to say without information or context but G19 G2 switches the plane to YZ and attempts an arc in that plane and also in any subsequent arcs.

11. ## Re: Acramatic 2100 retrofit

Looks like it was a post processor issue. I changed to another of the fusion 360 posts and it ran fine. I will dig in to it deeper later and figure out what it was precisely.

After adjusting acceleration to where it was acceptable, I ran a portion of a program I run regularly; the old control beat kmotion but only by about ~5% in a worst case scenario (lots of small circles in an HSM roughing tool path). 378 seconds vs 362. I can definitely live with that and was better than I expected. The table and saddle on this machine collectively weight almost 2500lbs. That's a lot of weight to be swinging around in tight circles at 100 IPM without jerk limiting.

12. ## Re: Acramatic 2100 retrofit

Got Z done and tuned and have been trying to get homing working properly. The machine has a weird set up. The trigger for the home switch is inside the travels of the limit switches. Each trigger plate has an angled ramp on both sides. The homing sequence works by hitting the first ramp and setting the switch low, then continuing to move until the switch moves high as it runs down the ramp on the other side of the plate. As soon as the switch goes high, the axis moves .5 inches further, then moves in the negative direction until the index is hit.

Needless to say, the simpleHomingIndexFunction got me started, but required some modification. With the old control I had to make sure I was not on the home switch trigger plate before homing or the machine would just hit the limit switch and kill the drive power. I am going to see if I can get it to check if the home switch is already low and then move off of it before starting the homing of that axis.

Thought I had it working and then started tripping the limit switches for some reason, so gave up for the evening

Really enjoying the process and the hardware. I even got it to run faster than the old control on test programs using the coordinated motion filtering!

13. ## Re: Acramatic 2100 retrofit

Here is some fun. This is part of the Acramatic 2100 code for homing for anyone who thinks C is bad

Code:
```[SIZE=3]IF :-N_MCH_PWON OR +S_SV_ALARM OR [S1AXIS_UNALN = 0]: RETURN; END IF
BEGIN CONDITION +N_ALIGN_AXES AND +N_MCH_PWON AND -N_DRIP ON EXCEPTION BEGIN
SET N_AX_APPR_HM OFF
SET S1IS_CANCEL ON
WAIT +N1IS__STATE.AT_EOP
WAIT [N_N_MSG_ID = 0]; LET N_N_MSG_ID = 20
RETURN
END
SET S1AX_LIMITS OFF
* PERFORM APPROACH HOME MOVE
LET ..ALN_INX = 1
REPEAT WHILE [..ALN_INX < N1LST_LOGAXS + 2]
WAIT +N1RUN__SUB
LET N1TPA_CMD = 20
LET ..INX_TMP = 0
* RESET SEQUENCE COMMAND REGISTERS THAT COMMUNICATE WITH THE ALIGN ISUB
REPEAT WHILE [..INX_TMP < N1LST_LOGAXS + 1]
LET N1TPASEQ_CMD(..INX_TMP) = 0
LET ..INX_TMP = ..INX_TMP + 1
LOOP
* DETERMINE ALL AXES TO MOVE IN THIS SEQUENCE
SET [N1TPASEQ_CMD(X) BIT 0] TO -N_X_REF_SW AND [N1AX_ALNTYPE(X) = 0] AND [N1AX_ALNSEQ(X) =
..ALN_INX] AND [N1AXIS_PRES BIT X]
SET [N1TPASEQ_CMD(Y) BIT 0] TO -N_Y_REF_SW AND [N1AX_ALNTYPE(Y) = 0] AND [N1AX_ALNSEQ(Y) =
..ALN_INX] AND [N1AXIS_PRES BIT Y]
SET [N1TPASEQ_CMD(Z) BIT 0] TO -N_Z_REF_SW AND [N1AX_ALNTYPE(Z) = 0] AND [N1AX_ALNSEQ(Z) =
..ALN_INX] AND [N1AXIS_PRES BIT Z]
SET [N1TPASEQ_CMD(U) BIT 0] TO -N_U_REF_SW AND [N1AX_ALNTYPE(U) = 0] AND [N1AX_ALNSEQ(U) =
..ALN_INX] AND [N1AXIS_PRES BIT U]
SET [N1TPASEQ_CMD(V) BIT 0] TO -N_V_REF_SW AND [N1AX_ALNTYPE(V) = 0] AND [N1AX_ALNSEQ(V) =
..ALN_INX] AND [N1AXIS_PRES BIT V]
SET [N1TPASEQ_CMD(W) BIT 0] TO -N_W_REF_SW AND [N1AX_ALNTYPE(W) = 0] AND [N1AX_ALNSEQ(W) =
..ALN_INX] AND [N1AXIS_PRES BIT W]
SET [N1TPASEQ_CMD(A) BIT 0] TO -N_A_REF_SW AND [N1AX_ALNTYPE(A) = 0] AND [N1AX_ALNSEQ(A) =
..ALN_INX] AND [N1AXIS_PRES BIT A]
SET [N1TPASEQ_CMD(B) BIT 0] TO -N_B_REF_SW AND [N1AX_ALNTYPE(B) = 0] AND [N1AX_ALNSEQ(B) =
..ALN_INX] AND [N1AXIS_PRES BIT B]
SET [N1TPASEQ_CMD(C) BIT 0] TO -N_C_REF_SW AND [N1AX_ALNTYPE(C) = 0] AND [N1AX_ALNSEQ(C) =
..ALN_INX] AND [N1AXIS_PRES BIT C]
SET [N1TPASEQ_CMD(D) BIT 0] TO -N_D_REF_SW AND [N1AX_ALNTYPE(D) = 0] AND [N1AX_ALNSEQ(D) =
..ALN_INX] AND [N1AXIS_PRES BIT D]
SET [N1TPASEQ_CMD(E) BIT 0] TO -N_E_REF_SW AND [N1AX_ALNTYPE(E) = 0] AND [N1AX_ALNSEQ(E) =
..ALN_INX] AND [N1AXIS_PRES BIT E]
SET [N1TPASEQ_CMD(P) BIT 0] TO -N_P_REF_SW AND [N1AX_ALNTYPE(P) = 0] AND [N1AX_ALNSEQ(P) =
..ALN_INX] AND [N1AXIS_PRES BIT P]
SET [N1TPASEQ_CMD(Q) BIT 0] TO -N_Q_REF_SW AND [N1AX_ALNTYPE(Q) = 0] AND [N1AX_ALNSEQ(Q) =
..ALN_INX] AND [N1AXIS_PRES BIT Q]
SET [N1TPASEQ_CMD(R) BIT 0] TO -N_R_REF_SW AND [N1AX_ALNTYPE(R) = 0] AND [N1AX_ALNSEQ(R) =
..ALN_INX] AND [N1AXIS_PRES BIT R]
* DETERMINE IF ANY AXIS IS SET TO MOVE IN THIS SEQUENCE, POST ALARM IF AXIS IS INHIBITED
LET ..INX_TMP = 0
SET ..AX_SEL_FL OFF
REPEAT WHILE [..INX_TMP < N1LST_LOGAXS + 1]
IF :[S1AXIS_INH BIT ..INX_TMP]: BEGIN
SET N_AX_APPR_HM OFF
WAIT [N_N_ALM_ID = 0]; LET N_N_ALM_INS3 = N_AXS_LETTER(..INX_TMP); LET N_N_ALM_ID = 214
RETURN
END
END IF
IF :-..AX_SEL_FL: SET ..AX_SEL_FL TO [N1TPASEQ_CMD(..INX_TMP) BIT 0]; END IF
LET ..INX_TMP = ..INX_TMP + 1
LOOP
IF :+..AX_SEL_FL: BEGIN
SET N_AX_APPR_HM ON
WAIT [N_N_MSG_ID = 0]; LET N_N_MSG_ID = 43
LET N1IS_FOV_LIM = 100
SET N1IS_LIM_FOV ON
LET S1SUBROUTINE = 11
START N1RUN__SUB
DELAY 1 MSEC
WHEN
:+N1IS_FAIL: BEGIN
SET N_AX_APPR_HM OFF
WAIT [N_N_ALM_ID = 0]; LET N_N_ALM_INS1 = S1SUBROUTINE; LET N_N_ALM_ID = 219
WAIT [N_N_MSG_ID = 0]; LET N_N_MSG_ID = 20
RETURN
END
:+S1IS_RUN_ACK: BEGIN
WHEN
:+N1SUB_COMPL: *
:[N1TPASEQ_CMD(X) BIT 0] AND +N_X_REF_SW: *
:[N1TPASEQ_CMD(Y) BIT 0] AND +N_Y_REF_SW: *
:[N1TPASEQ_CMD(Z) BIT 0] AND +N_Z_REF_SW: *
:[N1TPASEQ_CMD(U) BIT 0] AND +N_U_REF_SW: *
:[N1TPASEQ_CMD(V) BIT 0] AND +N_V_REF_SW: *
:[N1TPASEQ_CMD(W) BIT 0] AND +N_W_REF_SW: *
:[N1TPASEQ_CMD(A) BIT 0] AND +N_A_REF_SW: *
:[N1TPASEQ_CMD(B) BIT 0] AND +N_B_REF_SW: *
:[N1TPASEQ_CMD(C) BIT 0] AND +N_C_REF_SW: *
:[N1TPASEQ_CMD(D) BIT 0] AND +N_D_REF_SW: *
:[N1TPASEQ_CMD(E) BIT 0] AND +N_E_REF_SW: *
:[N1TPASEQ_CMD(P) BIT 0] AND +N_P_REF_SW: *
:[N1TPASEQ_CMD(Q) BIT 0] AND +N_Q_REF_SW: *
:[N1TPASEQ_CMD(R) BIT 0] AND +N_R_REF_SW: *
END WHEN
IF :+N1SUB_COMPL: BEGIN
WAIT +N1IS__STATE.AT_EOP
WAIT [N_N_ALM_ID = 0]
IF
:[N1TPASEQ_CMD(X) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(X)
:[N1TPASEQ_CMD(Y) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(Y)
:[N1TPASEQ_CMD(Z) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(Z)
:[N1TPASEQ_CMD(U) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(U)
:[N1TPASEQ_CMD(V) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(V)
:[N1TPASEQ_CMD(W) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(W)
:[N1TPASEQ_CMD(A) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(A)
:[N1TPASEQ_CMD(B) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(B)
:[N1TPASEQ_CMD(C) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(C)
:[N1TPASEQ_CMD(D) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(D)
:[N1TPASEQ_CMD(E) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(E)
:[N1TPASEQ_CMD(P) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(P)
:[N1TPASEQ_CMD(Q) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(Q)
:[N1TPASEQ_CMD(R) BIT 0]: LET N_N_ALM_INS3 = N_AXS_LETTER(R)
END IF
SET N_AX_APPR_HM OFF
LET N_N_ALM_ID = 215
WAIT [N_N_MSG_ID = 0]; LET N_N_MSG_ID = 20
RETURN
END
:+ELSE: BEGIN
SET S1IS_CANCEL ON
WAIT +N1IS__STATE.AT_EOP
END
END IF
END
END WHEN
END
:+ELSE: BEGIN
* NO AXIS SELECTED TO MOVE IN THIS SEQUENCE
DELAY 1 MSEC
END
END IF
* DETERMINE IF ALL SELECTED AXIS TO MOVE IN THIS SEQUENCE HAVE REACHED THE SWITCH
IF
:[N1TPASEQ_CMD(X) BIT 0] AND -N_X_REF_SW: *
:[N1TPASEQ_CMD(Y) BIT 0] AND -N_Y_REF_SW: *
:[N1TPASEQ_CMD(Z) BIT 0] AND -N_Z_REF_SW: *
:[N1TPASEQ_CMD(U) BIT 0] AND -N_U_REF_SW: *
:[N1TPASEQ_CMD(V) BIT 0] AND -N_V_REF_SW: *
:[N1TPASEQ_CMD(W) BIT 0] AND -N_W_REF_SW: *
:[N1TPASEQ_CMD(A) BIT 0] AND -N_A_REF_SW: *
:[N1TPASEQ_CMD(B) BIT 0] AND -N_B_REF_SW: *
:[N1TPASEQ_CMD(C) BIT 0] AND -N_C_REF_SW: *
:[N1TPASEQ_CMD(D) BIT 0] AND -N_D_REF_SW: *
:[N1TPASEQ_CMD(E) BIT 0] AND -N_E_REF_SW: *
:[N1TPASEQ_CMD(P) BIT 0] AND -N_P_REF_SW: *
:[N1TPASEQ_CMD(Q) BIT 0] AND -N_Q_REF_SW: *
:[N1TPASEQ_CMD(R) BIT 0] AND -N_R_REF_SW: *
:+ELSE: LET ..ALN_INX = ..ALN_INX + 1
END IF
LOOP```

14. ## Re: Acramatic 2100 retrofit

for anyone who thinks C is bad
LOL

15. ## Re: Acramatic 2100 retrofit

Originally Posted by TomKerekes
LOL
Indeed. I'm not sure what language it is; probably before my time. I spent most of college 15 years ago writing buffer overflows in assembly. I have forgotten almost all of it...but I think I would rather re-teach myself that than learn whatever this is!

It's weird, but when I learned C back in the MFC days, code was formatted:

Code:
```if (x==y)
{
//stuff
}```
Everything recent is:

Code:
```if (x==y) {
//stuff
}```
That all the kflop code is formatted the first way is telling and makes it easier for me to read

16. ## Re: Acramatic 2100 retrofit

Got homing all figured out. Last night I apparently didn't realize the Move function was relative to the axis zero; so it would appear to work and then either go backward or shoot off in to the limit switches depending on where the machine coordinates were at. Got it working by temporarily setting the axis 0 at the point the home ref switch went back to high, stopping the machine and then using Move to get it the last .5" before reversing to look for the index signal.

As of now, other than wiring up flood, flood motor overload signal, spindle/drive over temp signals, axis drive ready signals and figuring out if I need to send the original c-axis enable signal for the spindle to do rigid tapping...I am almost ready to try cutting some stuff!

I need to wire up a monitor and a wireless keyboard temporarily as I have been doing all of this on a laptop from the back of the machine where I can't see anything at all I don't want to start ripping out the old control until I am 100% sure I can run my products.

17. ## Re: Acramatic 2100 retrofit

Homing (trying to crush my light!) and a test cut in some scrap s30v stainless. I need to re-align the X screw; it's off after I fixed it and is causing a little resonance. Also need to up the spindle acceleration/jerk a bit. Seems to cut smooth though, it's nice having the spindle not bounce around 30-50 RPM like the old control would.

I bought this machine about 11 years ago not running for about 4k. I repaired the control and have been running the crap out of it since then. It has been through a couple of ballscrew rebuilds, turcite replacement on the table, rebuild of the lubrication system and 3 control board replacements. I make knives for a living.

The circle has the faintest of quadrant marks but was within .001 measured across x y and diagonally. This machine has always had a good bit of stick slip so setting backlash is trial and error. Surface finish looks better than the old control already though and it SOUNDS better.

I still have a lot of work to do but I may try to run some handles for some of my knives and see how it goes.

18. Got everything else wired up/coded (coolant, spindle temp and drive fault signals, etc) and the boards mounted to some 1/8 6061. I wish I had planned the actual wiring better but it is what it is now. I used kflop to drill/tap the plate; all went well other than not noticing one of my collets had developed about .008 of run-out and ruined some 4-40 threads.

I 3d printed the hold down for the servo break out connector boards and the board spacers.

Everything seems to be running pretty well.

These servos seem to like a 400hz filter and a 100hz filter. The Z axis has a counterweight and can run from 10-400 IPM with less than 8 counts of total error. The x and y are 20 counts at 400 IPM and 1-2 counts under 100IPM

These drives allow changes to voltage scaling so I changed it to 10v=1300 RPM instead of 2200 RPM which is about 10% over my max rapid rate. It had a pretty significant impact tuning for some reason.

I need to make some parts soon, if all goes well I will build a new operator console, wire up a pendent and remove the old parts next month.

19. ## Re: Acramatic 2100 retrofit

Finally ran some steel parts today. I ran 1 bar out of 10 to verify everything and was very happy with the results. 3d and sidewall surface finish is definitely improved over the old control.

This is a 1/4" Garr H45 high feed mill running full slot, 150 IPM, 6k RPM and .015 DOC in S30v Stainless.

20. ## Re: Acramatic 2100 retrofit

Nice!

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•