kcjengr / probe_basic

User interface for the LinuxCNC machine control.
https://kcjengr.github.io/probe_basic/
GNU General Public License v3.0
90 stars 58 forks source link

Subroutine cleanup #85

Closed dpslwk closed 11 months ago

dpslwk commented 11 months ago

this ended up a lot bigger changes than originally planed but I have synced the 4 copies to be almost identical now and done a huge refactor on the ATC pocket handling

the subroutines can now automatic handle a ATC up to 24 pockets in order to make more than 18 pockets work we need to move the numbered parameters used to store pocket data away from #5191

; Parameter #3989 is used to track if the carousel is homed (M13) (volatile)
; Parameter #3990 is used to track the current tool pocket (persistently)
; Parameter #3991 is used to track the current tool loaded it in the spindle (persistently)
; Parameters #4001 to #4024 are used to track which tool is in which pocket (persistently)
; Parameter #4000 is not populated just used in the maths to calculate the above numbers
; #<number_of_pockets>: The number of pockets in the ATC is automaticity pulled from the INI via #<_ini[atc]pockets>

users will need to make sure the add entries for #3990 to #4024 to the start of there configured PARAMETER_FILE (normally linuxcnc.var), one option is to copy configs/probe_basic/sim.var