vilemduha / blendercam

Automatically exported from code.google.com/p/blendercam
GNU General Public License v3.0
473 stars 119 forks source link

Modify plunge speed to independent number instead of percentage of feedrate #240

Open eastshores opened 1 year ago

eastshores commented 1 year ago

Original issue was raised regarding the time calculations and the plunge speed not being accounted for. Currently plunge speed is a percentage 1-100 of feedrate. This issue is to investigate changing this property to an independent number.

Code analysis:

35 instances of variable plunge_feedrate across 33 files (two of which are definitions)

Defined in /scripts/cam/init.py as line 764 under #feeds plunge_feedrate: FloatProperty(name="Plunge speed ", description="% of feedrate", min=0.1, max=100.0, default=50.0, precision=1, subtype='PERCENTAGE', update=updateRest) Defined in /scripts/init.py as line 834 under #feeds plunge_feedrate: FloatProperty(name="Plunge speed ", description="% of feedrate", min=0.1, max=100.0, default=50.0, precision=1, subtype='PERCENTAGE', update=updateRest)

Why is it defined twice?

Values are set for tool presets: Value is set to 30.0 for all tool presets except Finishing_3mm_ballnose which is set to 50.0 (not sure why this one is different?)

Percentage value is set in gcodepath.py on line 293: plungefeedrate = millfeedrate * o.plunge_feedrate / 100

plungefeedrate is only in gcodepath.py (1 definition and 2 references)

Findings:

image

pppalain commented 1 year ago

possible problem is backward compatibility... old files will have to flag plunge speed <= 100 and adjust accordingly

eastshores commented 1 year ago

Good point. Do you know if any blendercam release information is saved in the blend file? That would be the ideal way to handle it. I don't know if there would be any cases where someone wants a plunge speed lower than 100. If there is no release info that might be another issue to look at, it would be simple to implement and give us a lot of flexibility on updates like this.