- fixed bugs in cncjob TclCommand

This commit is contained in:
Marius Stanciu 2020-03-20 17:12:20 +02:00 committed by Marius
parent ffaea546db
commit 7415ebc8af
3 changed files with 9 additions and 3 deletions

View File

@ -15,6 +15,7 @@ CAD program, and create G-Code for Isolation routing.
- added to Paint and NCC Tool a feature that allow polygon area selection when the reference is selected as Area Selection - added to Paint and NCC Tool a feature that allow polygon area selection when the reference is selected as Area Selection
- in Paint Tool and NCC Tool added ability to use Escape Tool to cancel Area Selection and for Paint Tool to cancel Polygon Selection - in Paint Tool and NCC Tool added ability to use Escape Tool to cancel Area Selection and for Paint Tool to cancel Polygon Selection
- fixed issue in "re-cut" feature when combined with multi-depth feature - fixed issue in "re-cut" feature when combined with multi-depth feature
- fixed bugs in cncjob TclCommand
13.03.2020 13.03.2020

View File

@ -3905,7 +3905,7 @@ class CNCjob(Geometry):
self.feedrate_rapid = float(feedrate_rapid) if feedrate_rapid is not None else \ self.feedrate_rapid = float(feedrate_rapid) if feedrate_rapid is not None else \
self.app.defaults["geometry_feedrate_rapid"] self.app.defaults["geometry_feedrate_rapid"]
self.spindlespeed = int(spindlespeed) if spindlespeed != 0 else None self.spindlespeed = int(spindlespeed) if spindlespeed != 0 and spindlespeed is not None else None
self.spindledir = spindledir self.spindledir = spindledir
self.dwell = dwell self.dwell = dwell
self.dwelltime = float(dwelltime) if dwelltime is not None else self.app.defaults["geometry_dwelltime"] self.dwelltime = float(dwelltime) if dwelltime is not None else self.app.defaults["geometry_dwelltime"]
@ -3919,7 +3919,7 @@ class CNCjob(Geometry):
"in the format (x, y) but now there is only one value, not two.")) "in the format (x, y) but now there is only one value, not two."))
return 'fail' return 'fail'
self.z_depthpercut = float(depthpercut) if depthpercut is not None else 0.0 self.z_depthpercut = float(depthpercut) if depthpercut is not None and depthpercut != 0 else abs(self.z_cut)
self.multidepth = multidepth self.multidepth = multidepth
self.z_toolchange = float(toolchangez) if toolchangez is not None else self.app.defaults["geometry_toolchangez"] self.z_toolchange = float(toolchangez) if toolchangez is not None else self.app.defaults["geometry_toolchangez"]
self.extracut_length = float(extracut_length) if extracut_length is not None else \ self.extracut_length = float(extracut_length) if extracut_length is not None else \

View File

@ -213,7 +213,12 @@ class TclCommandCncjob(TclCommandSignaled):
local_tools_dict[tool_uid]['data']['feedrate_rapid'] = args["feedrate_rapid"] local_tools_dict[tool_uid]['data']['feedrate_rapid'] = args["feedrate_rapid"]
local_tools_dict[tool_uid]['data']['multidepth'] = args["multidepth"] local_tools_dict[tool_uid]['data']['multidepth'] = args["multidepth"]
local_tools_dict[tool_uid]['data']['extracut'] = args["extracut"] local_tools_dict[tool_uid]['data']['extracut'] = args["extracut"]
local_tools_dict[tool_uid]['data']['extracut_length'] = args["extracut_length"]
if args["extracut"] is True:
local_tools_dict[tool_uid]['data']['extracut_length'] = args["extracut_length"]
else:
local_tools_dict[tool_uid]['data']['extracut_length'] = None
local_tools_dict[tool_uid]['data']['depthperpass'] = args["depthperpass"] local_tools_dict[tool_uid]['data']['depthperpass'] = args["depthperpass"]
local_tools_dict[tool_uid]['data']['toolchange'] = args["toolchange"] local_tools_dict[tool_uid]['data']['toolchange'] = args["toolchange"]
local_tools_dict[tool_uid]['data']['toolchangez'] = args["toolchangez"] local_tools_dict[tool_uid]['data']['toolchangez'] = args["toolchangez"]