How to change default values in the CAM Profile Toolpath dialog?

Discussions around the CAM Add-On of QCAD.

Moderator: andrew

Post Reply
Sprung
Junior Member
Posts: 11
Joined: Thu Jun 10, 2021 11:35 am

How to change default values in the CAM Profile Toolpath dialog?

Post by Sprung » Thu Jun 10, 2021 12:00 pm

Hello,
how can i set the preferences in the Cam Profile Toolpath Menu?
thanks
Matura

User avatar
andrew
Site Admin
Posts: 7818
Joined: Fri Mar 30, 2007 6:07 am

Re: How to set preferences in CAM Profile Toolpath?

Post by andrew » Thu Jun 10, 2021 12:19 pm

Unfortunately, I don't understand your question. Please elaborate, include screenshots, etc., thanks.

Sprung
Junior Member
Posts: 11
Joined: Thu Jun 10, 2021 11:35 am

Re: How to set preferences in CAM Profile Toolpath?

Post by Sprung » Thu Jun 10, 2021 12:53 pm

I want to set i.e. the cutting depth or the side/direction parameters to my requirements when open the Menu. I almost need 2mm cutting depth, preferece is 4mm.

thanks
Matura
Attachments
versionqcad.PNG
versionqcad.PNG (49.25 KiB) Viewed 1113 times
camprofiletoolpath.PNG
camprofiletoolpath.PNG (45.42 KiB) Viewed 1113 times

User avatar
andrew
Site Admin
Posts: 7818
Joined: Fri Mar 30, 2007 6:07 am

Re: How to change default values in the CAM Profile Toolpath dialog?

Post by andrew » Thu Jun 10, 2021 1:16 pm

Changing the default values is possible, yes.

Please indicate which post processor you are using, so we can assist you efficiently, thanks.

Sprung
Junior Member
Posts: 11
Joined: Thu Jun 10, 2021 11:35 am

Re: How to change default values in the CAM Profile Toolpath dialog?

Post by Sprung » Fri Jun 11, 2021 9:16 am

Hello Andrew,

iam using an adapted Gcodeoffset [mm] postprocessor.

thanks
Matura

User avatar
andrew
Site Admin
Posts: 7818
Joined: Fri Mar 30, 2007 6:07 am

Re: How to change default values in the CAM Profile Toolpath dialog?

Post by andrew » Tue Jun 15, 2021 12:28 pm

You can override initDialog in your post processor and change the default values, for example:

Code: Select all

GCodeOffsetMM.prototype.initDialog = function(dialog, di, resourceBlock) {
    // adjust profile toolpath dialog:
    if (dialog.objectName==="CamProfileToolpathDialog") {
        // change default cutting depth:
        var leCuttingDepth = dialog.findChild("CamZCuttingDepth");
        leCuttingDepth.setValue(20);

        // change default side:
        var cbSide = dialog.findChild("CamSide");
        cbSide.currentIndex = 0; // 0: none, 1: outside, 2: inside

        // change default direction:
        var cbDirection = dialog.findChild("CamDirection");
        cbDirection.currentIndex = 0; // 0: Left, 1: Right
    }
};
You can find more control widget names in the attached user interface definition file (XML).
Attachments
CamProfileToolpathDialog.ui
(21.78 KiB) Downloaded 23 times

Sprung
Junior Member
Posts: 11
Joined: Thu Jun 10, 2021 11:35 am

Re: How to change default values in the CAM Profile Toolpath dialog?

Post by Sprung » Wed Jun 23, 2021 8:49 am

Hello Andrew,
thanks!
regards
Matura

Post Reply

Return to “QCAD/CAM”