1.4. Custom Sections and Variables
21 Aug 2023 07:58 - 21 Aug 2023 09:29 #278592
by ikkuh
1.4. Custom Sections and Variables was created by ikkuh
My machine is a gantry type machine with two Y axis steppers. Lately I have been doing a lot of midifications to the machine and one thing that was a bit of a nuisance was that the since the steppers and hardware for both Y axis are exactly the same I still had to enter values for both in the .ini file.
In hal files it is possible to reuse the value from an .ini file. See: linuxcnc.org/docs/html/config/ini-config...sub:custom-variables
Would be nice if that could be done in the .ini file as well, would have saved a terrible crash and racking of the gantry
An example of that I am proposing:
#*** AXIS_Y *******************************
[AXIS_Y]
MAX_VELOCITY = 25.0
MAX_ACCELERATION = 750.0
MIN_LIMIT = -0.001
MAX_LIMIT = 200.0
[JOINT_1]
TYPE = LINEAR
HOME = 0.0
MIN_LIMIT = [AXIS_Y]MIN_LIMIT
MAX_LIMIT = [AXIS_Y]MAX_LIMIT
MAX_VELOCITY = 25.0
MAX_ACCELERATION = 750.0
STEPGEN_MAXACCEL = 937.5
SCALE = 80.0
FERROR = 1
MIN_FERROR = .25
HOME_OFFSET = 0.0
[JOINT_2]
TYPE = LINEAR
HOME = 0.0
MIN_LIMIT = [AXIS_Y]MIN_LIMIT
MAX_LIMIT = [AXIS_Y]MAX_LIMIT
MAX_VELOCITY = 25.0
MAX_ACCELERATION = 750.0
STEPGEN_MAXACCEL = 937.5
SCALE = 80.0
FERROR = 1
MIN_FERROR = .25
HOME_OFFSET = 0.0
In hal files it is possible to reuse the value from an .ini file. See: linuxcnc.org/docs/html/config/ini-config...sub:custom-variables
Would be nice if that could be done in the .ini file as well, would have saved a terrible crash and racking of the gantry
An example of that I am proposing:
#*** AXIS_Y *******************************
[AXIS_Y]
MAX_VELOCITY = 25.0
MAX_ACCELERATION = 750.0
MIN_LIMIT = -0.001
MAX_LIMIT = 200.0
[JOINT_1]
TYPE = LINEAR
HOME = 0.0
MIN_LIMIT = [AXIS_Y]MIN_LIMIT
MAX_LIMIT = [AXIS_Y]MAX_LIMIT
MAX_VELOCITY = 25.0
MAX_ACCELERATION = 750.0
STEPGEN_MAXACCEL = 937.5
SCALE = 80.0
FERROR = 1
MIN_FERROR = .25
HOME_OFFSET = 0.0
[JOINT_2]
TYPE = LINEAR
HOME = 0.0
MIN_LIMIT = [AXIS_Y]MIN_LIMIT
MAX_LIMIT = [AXIS_Y]MAX_LIMIT
MAX_VELOCITY = 25.0
MAX_ACCELERATION = 750.0
STEPGEN_MAXACCEL = 937.5
SCALE = 80.0
FERROR = 1
MIN_FERROR = .25
HOME_OFFSET = 0.0
Last edit: 21 Aug 2023 09:29 by ikkuh. Reason: unreadable due to the stupid editor of this BB
Please Log in or Create an account to join the conversation.
22 Aug 2023 01:34 #278669
by cmorley
Replied by cmorley on topic 1.4. Custom Sections and Variables
Interesting I didn't know you could do this.
It won't work with all entries - Python based screens seem not to honour that type of entry.
It won't work with all entries - Python based screens seem not to honour that type of entry.
Please Log in or Create an account to join the conversation.
Time to create page: 0.142 seconds