Access dimensions of job from python
19 Jun 2018 06:17 #112567
by mistik1
Access dimensions of job from python was created by mistik1
I wrote a little subroutine to create repeated parts in an array fashion, example cut 10 along X spaced by a value and 5 along Y for 50 parts without stopping(poor man's nesting)
I however want to migrate this all to python so I can call named G-Code files (vs numbered files) without then having to be subs themselves also, since my sub takes the files as a parameter I can only pass numbers.
I have noticed that the preview has the dimensions of the job displayed.
How can I get access to those dimensions programmaticlly in python?
Thanks
I however want to migrate this all to python so I can call named G-Code files (vs numbered files) without then having to be subs themselves also, since my sub takes the files as a parameter I can only pass numbers.
I have noticed that the preview has the dimensions of the job displayed.
How can I get access to those dimensions programmaticlly in python?
Thanks
Please Log in or Create an account to join the conversation.
26 Jun 2018 12:56 #112884
by andypugh
Replied by andypugh on topic Access dimensions of job from python
github.com/LinuxCNC/linuxcnc/blob/master...cripts/axis.py#L1789
It looks like Axis uses ...canon.max_extents and min_extents.
I don't think that you can get to the "canon" object from a Python subroutine (you _can_ get to it from a remapped G-code )
It looks like Axis uses ...canon.max_extents and min_extents.
I don't think that you can get to the "canon" object from a Python subroutine (you _can_ get to it from a remapped G-code )
Please Log in or Create an account to join the conversation.
Time to create page: 0.080 seconds