X-Axis jump, about 1,4mm February 14, 2014 11:51AM |
Registered: 9 years ago Posts: 57 |
Re: X-Axis jump, about 1,4mm February 14, 2014 11:59AM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 14, 2014 12:31PM |
Registered: 9 years ago Posts: 14,640 |
Re: X-Axis jump, about 1,4mm February 14, 2014 12:49PM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 14, 2014 01:17PM |
Registered: 9 years ago Posts: 14,640 |
Re: X-Axis jump, about 1,4mm February 14, 2014 01:25PM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 14, 2014 02:17PM |
Registered: 9 years ago Posts: 57 |
Quote
rayhicks
Quote
dc42
Adrian at RRP is making major changes to Move.cpp to sort out issues with combined XZ, YZ and XYZ moves
ah good that's encouraging
Re: X-Axis jump, about 1,4mm February 15, 2014 08:27AM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 15, 2014 04:27PM |
Registered: 9 years ago Posts: 57 |
Quote
rayhicks
I presume that the feedrates for X and Y are limited to 50mm/s in firmware, to mitigate the effect
Ray
Re: X-Axis jump, about 1,4mm February 17, 2014 07:47AM |
Registered: 9 years ago Posts: 57 |
Re: X-Axis jump, about 1,4mm February 17, 2014 08:09AM |
Registered: 9 years ago Posts: 578 |
{/edit2}Maybe so Frank - 20mm/s doesn't show a problem with the "snippet" I promised on my machine, however I've looked into it a little, and i think I've found the problem- rather than sending an as-sliced gcode, I've simplified the snippets - "nobang.gcode" is a simple backward and forward move in Y with a feedrate of 50mm/s between Y=100 and Y=75 (I've increased the feedrate caps on my machine and this doesn't bang at 100mm/s either as the acc/deceleration works as intended). "bang1.gcode" is similar, but includes a very short intermediate step (1mm before the original turning point at y=76). Essentially, the control code doesn't slow down the Y axis movement when it reaches 76, since the next segment is meant to be carried out at the same speed, it then processes the next segment and tries to do the full deceleration to 0 in one mm. Without the intermediate step, it slows down as it approaches 75, so that it can stop and accelerate back.Quote
Cash
But in my case I had this jump while using 20mm/s and I am not losing small single steps from layer to layer or so.
G1 X100 Y100 F3000.000 G1 X100 Y75.2 F3000.000;1 G1 X100 Y75 F3000.000 G1 X100 Y100 F3000.000 G1 X100 Y75.4 F3000.000;2 G1 X100 Y75 F3000.000 G1 X100 Y100 F3000.000 G1 X100 Y75.6 F3000.000;3 G1 X100 Y75 F3000.000 G1 X100 Y100 F3000.000 G1 X100 Y75.8 F3000.000;4 G1 X100 Y75 F3000.000 G1 X100 Y100 F3000.000 G1 X100 Y76 F3000.000;5 G1 X100 Y75 F3000.000 G1 X100 Y100 F3000.000 G1 X100 Y77 F3000.000;6 G1 X100 Y75 F3000.000 G1 X100 Y100 F3000.000 G1 X100 Y78 F3000.000;7 G1 X100 Y75 F3000.000 G1 X100 Y100 F3000.000marked ;1 to ;7 - ;1-5 bang increasingly hard, 6 and 7 don't bang at all - it looks like some fine-tuning of the lookahead functions are needed.
Re: X-Axis jump, about 1,4mm February 17, 2014 08:15AM |
Registered: 9 years ago Posts: 578 |
Quote
Cash
In my opinion, if there are velocity changes from positive to negative, there should be a deceleration to 0 and then an acceleration again in the other direction.
If this situation will be considered in the firmware, i think a much higher printing speed will be possible!
Re: X-Axis jump, about 1,4mm February 17, 2014 08:41AM |
Registered: 9 years ago Posts: 57 |
Re: X-Axis jump, about 1,4mm February 17, 2014 09:32AM |
Registered: 9 years ago Posts: 57 |
Quote
rayhicks
I'd presumed something like that from reading the code, but it does work if there's time for it to slow down (ie direction is accounted for elsewhere) - it's just that if the next move is too short for deceleration but at the same speed, the previous move doesn't seem to bother decelerating and it's all down to the last, potentially too short, move to get rid of all that momentum
Re: X-Axis jump, about 1,4mm February 17, 2014 10:41AM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 17, 2014 11:00AM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 17, 2014 11:27AM |
Registered: 9 years ago Posts: 57 |
Quote
rayhicks
[www.dropbox.com] <- this seems to be working, I'm printing with 75mm/s on perimeters and 100mm/s travel without bangs, I had to slow the same print down to 40mm/s for the bangs not to affect the print quality on the same model previously.
Re: X-Axis jump, about 1,4mm February 17, 2014 12:06PM |
Registered: 9 years ago Posts: 57 |
Re: X-Axis jump, about 1,4mm February 17, 2014 12:23PM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 17, 2014 01:02PM |
Registered: 9 years ago Posts: 265 |
Re: X-Axis jump, about 1,4mm February 17, 2014 01:05PM |
Registered: 9 years ago Posts: 578 |
MovementProfile DDA::AccelerationCalculation(float& u, float& v, MovementProfile result) { // At which DDA step should we stop accelerating? myLookAheadEntry->FeedRate() gives // the desired feedrate. float d = 0.5*(myLookAheadEntry->FeedRate()*myLookAheadEntry->FeedRate() - u*u)/acceleration; // d = (v1^2 - v0^2)/2a stopAStep = (long)roundf((d*totalSteps)/distance); // At which DDA step should we start decelerating? d = 0.5*(v*v - myLookAheadEntry->FeedRate()*myLookAheadEntry->FeedRate())/acceleration; // This should be 0 or negative... startDStep = totalSteps + (long)roundf((d*totalSteps)/distance); // If acceleration stop is at or after deceleration start, then the distance moved // is not enough to get to full speed. if(stopAStep >= startDStep) { result = noFlat; // Work out the point at which to stop accelerating and then // immediately start decelerating. float dCross = 0.5*(0.5*(v*v - u*u)/acceleration + distance); if(dCross < 0.0 || dCross > distance) { // With the acceleration available, it is not possible // to satisfy u and v within the distance; reduce u and v // proportionately to get ones that work and flag the fact. // The result is two velocities that can just be accelerated // or decelerated between over the distance to get // from one to the other. result = change; float k = v/u; u = 2.0*acceleration*distance/(k*k - 1); if(u >= 0.0) { u = sqrt(u); v = k*u; } else { ///////////////////////////v = sqrt(-u); this is the original line - it was increasing exit-speed rather than making it nearer 0 for small segment moves, doesn't get called for large ones///// v=1.0;///////////////my initial change, might be better to use instantDv? u = v/k; } dCross = 0.5*(0.5*(v*v - u*u)/acceleration + distance); } // The DDA steps at which acceleration stops and deceleration starts stopAStep = (long)((dCross*totalSteps)/distance); startDStep = stopAStep + 1; } return result; }
Re: X-Axis jump, about 1,4mm February 17, 2014 01:31PM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 17, 2014 01:47PM |
Registered: 9 years ago Posts: 2,472 |
Re: X-Axis jump, about 1,4mm February 17, 2014 01:54PM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 17, 2014 01:55PM |
Registered: 9 years ago Posts: 57 |
Re: X-Axis jump, about 1,4mm February 17, 2014 02:08PM |
Registered: 9 years ago Posts: 578 |
Re: X-Axis jump, about 1,4mm February 17, 2014 02:47PM |
Registered: 9 years ago Posts: 57 |
Re: X-Axis jump, about 1,4mm February 17, 2014 04:07PM |
Registered: 9 years ago Posts: 2,472 |
Re: X-Axis jump, about 1,4mm February 17, 2014 05:40PM |
Registered: 9 years ago Posts: 14,640 |
Re: X-Axis jump, about 1,4mm February 17, 2014 06:13PM |
Registered: 9 years ago Posts: 578 |
if(u >= 0.0) { u = sqrt(u); v = k*u; } else { snprintf(scratchString, STRING_LENGTH, "%f\n", u); platform->Message(HOST_MESSAGE, "old u"); platform->Message(HOST_MESSAGE, scratchString); snprintf(scratchString, STRING_LENGTH, "%f\n", v); platform->Message(HOST_MESSAGE, "old v"); platform->Message(HOST_MESSAGE, scratchString); v = sqrt(-u); // the original modifier for when dCross is 0 or negative and u is negative on entry //v=1.0; // my change in the code which sets v low and then allows u and dCross to be recalculated from this low end goal [edit 2 to remove "color" bleed] u = v/k; snprintf(scratchString, STRING_LENGTH, "%f\n", u); platform->Message(HOST_MESSAGE, "new u"); platform->Message(HOST_MESSAGE, scratchString); snprintf(scratchString, STRING_LENGTH, "%f\n", v); platform->Message(HOST_MESSAGE, "new v"); platform->Message(HOST_MESSAGE, scratchString); } dCross = 0.5*(0.5*(v*v - u*u)/acceleration + distance);