Merge pull request #2988 from larsbrubaker/design_tools

Improved the math around gcode time and jerk setting
This commit is contained in:
Lars Brubaker 2018-02-07 13:07:53 -08:00 committed by GitHub
commit 2ea60c9db0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 5 deletions

View file

@ -224,11 +224,17 @@ namespace MatterControl.Printing
Vector4 velocitySameAsStopMmPerS,
Vector4 speedMultiplierV4)
{
double startingVelocityMmPerS = velocitySameAsStopMmPerS.X;
double endingVelocityMmPerS = velocitySameAsStopMmPerS.X;
double maxVelocityMmPerSx = Math.Min(feedRateMmPerMin / 60, maxVelocityMmPerS.X);
double acceleration = maxAccelerationMmPerS2.X;
double lengthOfThisMoveMm = Math.Max(deltaPositionThisLine.Length, deltaEPositionThisLine);
if (lengthOfThisMoveMm == 0)
{
return 0;
}
double maxVelocityMmPerSx = Math.Min(feedRateMmPerMin / 60, maxVelocityMmPerS.X);
double startingVelocityMmPerS = Math.Min(velocitySameAsStopMmPerS.X, maxVelocityMmPerSx);
double endingVelocityMmPerS = startingVelocityMmPerS;
double acceleration = maxAccelerationMmPerS2.X;
double speedMultiplier = speedMultiplierV4.X;
double distanceToMaxVelocity = GetDistanceToReachEndingVelocity(startingVelocityMmPerS, maxVelocityMmPerSx, acceleration);

@ -1 +1 @@
Subproject commit f0ae8affbd243e7969eca8078db7a17daa19a1a6
Subproject commit 2932cc92a8d67fcfe5bbff3c762b1c43ec700ede