Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion configs/sim/axis/vismach/5axis/bridgemill/5axis.ini
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ CYCLE_TIME = 0.010
HALUI = halui
HALFILE = LIB:basic_sim.tcl
HALFILE = 5axisgui.hal
HALCMD = net :kinstype-select <= motion.analog-out-03 => motion.switchkins-type
POSTGUI_HALFILE = 5axis_postgui.hal

[HALUI]
Expand Down
17 changes: 3 additions & 14 deletions configs/sim/axis/vismach/5axis/bridgemill/remap_subs/428remap.ngc
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
;M428 by remap: select kinstype=0 genhexkins
o<428remap>sub
#<kinstype> = 0
#<SWITCHKINS_PIN> = 3 ; set N as required: motion.analog-out-0N

o1 if [exists [#<_hal[motion.switchkins-type]>]]
o1 else
(debug,M428:Missing [RS274NGC]HAL_PIN_VARS=1)
(debug,STOP)
M2
o1 endif

M68 E#<SWITCHKINS_PIN> Q#<kinstype> ; set kinstype value
M66 E0 L0 ; force synch
G13.1 ; back to kinstype 0, syncs interp and motion

o2 if [[#<_task> EQ 1] AND [#<_hal[motion.switchkins-type]> NE #<kinstype>]]
(debug,M428: Wrong motion.switchkins-type)
(debug,or missing hal net to analog-out-0x)
o2 if [[#<_task> EQ 1] AND [#<_kins_type> NE #<kinstype>]]
(debug,M428: Wrong kinematics type)
(debug,STOP)
M2
o2 else
o2 endif

o<428remap>endsub
17 changes: 3 additions & 14 deletions configs/sim/axis/vismach/5axis/bridgemill/remap_subs/429remap.ngc
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
;M429 by remap: select kinstype==1 Identity kinematics
o<429remap>sub
#<kinstype> = 1
#<SWITCHKINS_PIN> = 3 ; set N as required: motion.analog-out-0N

o1 if [exists [#<_hal[motion.switchkins-type]>]]
o1 else
(debug,M429:Missing [RS274NGC]HAL_PIN_VARS=1)
(debug,STOP)
M2
o1 endif

M68 E#<SWITCHKINS_PIN> Q#<kinstype> ; set kinstype value
M66 E0 L0 ; force synch
G12.1 P#<kinstype> ; select kinstype, syncs interp and motion

o2 if [[#<_task> EQ 1] AND [#<_hal[motion.switchkins-type]> NE #<kinstype>]]
(debug,M429:Wrong motion.switchkins-type)
(debug,or missing hal net to analog-out-0x)
o2 if [[#<_task> EQ 1] AND [#<_kins_type> NE #<kinstype>]]
(debug,M429:Wrong kinematics type)
(debug,STOP)
M2
o2 else
o2 endif

o<429remap>endsub
17 changes: 3 additions & 14 deletions configs/sim/axis/vismach/5axis/bridgemill/remap_subs/430remap.ngc
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
;M430 by remap: select kinstype==2 userk kins
o<430remap>sub
#<kinstype> = 2
#<SWITCHKINS_PIN> = 3 ; set N as required: motion.analog-out-0N

o1 if [exists [#<_hal[motion.switchkins-type]>]]
o1 else
(debug,M30:Missing [RS274NGC]HAL_PIN_VARS=1)
(debug,STOP)
M2
o1 endif

M68 E#<SWITCHKINS_PIN> Q#<kinstype> ; set kinstype value
M66 E0 L0 ; force synch
G12.1 P#<kinstype> ; select kinstype, syncs interp and motion

o2 if [[#<_task> EQ 1] AND [#<_hal[motion.switchkins-type]> NE #<kinstype>]]
(debug,M430:Wrong motion.switchkins-type)
(debug,or missing hal net to analog-out-0x)
o2 if [[#<_task> EQ 1] AND [#<_kins_type> NE #<kinstype>]]
(debug,M430:Wrong kinematics type)
(debug,STOP)
M2
o2 else
o2 endif

o<430remap>endsub
3 changes: 0 additions & 3 deletions configs/sim/axis/vismach/5axis/table-dual-rotary/README
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ For proper tool-path preview RELOAD THE CGODE after startup and after changing o
***********************************************
Note: IMPORTANT ini file requirements:

[HAL]
HALCMD = net :kinstype-select <= motion.analog-out-0N => motion.switchkins-type

[RS274NGC]
SUBROUTINE_PATH = ./remap_subs
REMAP = M428 modalgroup=10 ngc=428remap
Expand Down
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
;M428 by remap: kinstype==1 (xyzac,xyzbc) (note: sparm=identityfirst)
;M428 by remap: kinstype==1 (xyzab-tdr kinematics)
o<428remap>sub
#<kinstype> = 1 ; xyzac,xyzbc
#<SWITCHKINS_PIN> = 3 ; set N as required: motion.analog-out-0N
#<kinstype> = 1 ; xyzab-tdr

o1 if [exists [#<_hal[motion.switchkins-type]>]]
o1 else
(debug,M428:Missing [RS274NGC]HAL_PIN_VARS=1)
(debug,STOP)
M2
o1 endif

M68 E#<SWITCHKINS_PIN> Q#<kinstype> ; set kinstype value
M66 E0 L0 ; force synch
G12.1 P#<kinstype> ; select kinstype, syncs interp and motion

o2 if [[#<_task> EQ 1] AND [#<_hal[motion.switchkins-type]> NE #<kinstype>]]
(debug,M428: Wrong motion.switchkins-type)
(debug,or missing hal net to analog-out-0x)
o2 if [[#<_task> EQ 1] AND [#<_kins_type> NE #<kinstype>]]
(debug,M428: Wrong kinematics type)
(debug,STOP)
M2
o2 else
o2 endif

o<428remap>endsub
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
;M429 by remap: kinstype==0 Identity kinematics
o<429remap>sub
#<kinstype> = 0
#<SWITCHKINS_PIN> = 3 ; set N as required: motion.analog-out-0N

o1 if [exists [#<_hal[motion.switchkins-type]>]]
o1 else
(debug,M429:Missing [RS274NGC]HAL_PIN_VARS=1)
(debug,STOP)
M2
o1 endif

M68 E#<SWITCHKINS_PIN> Q#<kinstype> ; set kinstype value
M66 E0 L0 ; force synch
G13.1 ; back to kinstype 0, syncs interp and motion

o2 if [[#<_task> EQ 1] AND [#<_hal[motion.switchkins-type]> NE #<kinstype>]]
(debug,M429:Wrong motion.switchkins-type)
(debug,or missing hal net to analog-out-0x)
o2 if [[#<_task> EQ 1] AND [#<_kins_type> NE #<kinstype>]]
(debug,M429: Wrong kinematics type)
(debug,STOP)
M2
o2 else
o2 endif

o<429remap>endsub
10 changes: 4 additions & 6 deletions configs/sim/axis/vismach/5axis/table-dual-rotary/xyzab-tdr.ini
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ SUBROUTINE_PATH = ./remap_subs

[KINS]
#NOTE:
# switchkins-type == 0 is identity kins
# switchkins-type == 1 is xyzab-tdr-kins
# kinstype 0 is identity kins
# kinstype 1 is xyzab-tdr-kins

KINEMATICS = xyzab_tdr_kins
JOINTS = 5
Expand All @@ -36,8 +36,6 @@ KINEMATICS = xyzab_tdr_kins
HALFILE = LIB:basic_sim.tcl
POSTGUI_HALFILE = xyzab-tdr-postgui.hal

# net for control of motion.switchkins-type
HALCMD = net :kinstype-select <= motion.analog-out-03 => motion.switchkins-type

# Values '(x,z)-offsets' for geometric offset of the rotary-assembly and the
# values '(x,y,z)-rot-point' that describe the position of the
Expand Down Expand Up @@ -76,8 +74,8 @@ HALCMD = sets :x-offset -20
HALCMD = sets :z-offset -10

[HALUI]
# M429:identity kins (motion.switchkins-type==0 startupDEFAULT)
# M428:xyzab-tdr kins (motion.switchkins-type==1)
# M429:identity kins (kinstype 0, startupDEFAULT)
# M428:xyzab-tdr kins (kinstype 1)
MDI_COMMAND = M429
MDI_COMMAND = M428

Expand Down
3 changes: 0 additions & 3 deletions configs/sim/axis/vismach/5axis/table-rotary-tilting/README
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,6 @@ Demonstrations:
***********************************************
Note: IMPORTANT ini file requirements:

[HAL]
HALCMD = net :kinstype-select <= motion.analog-out-0N => motion.switchkins-type

[RS274NGC]
SUBROUTINE_PATH = ./remap_subs
REMAP = M428 modalgroup=10 ngc=428remap
Expand Down
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
;M428 by remap: kinstype==1 (xyzac,xyzbc) (note: sparm=identityfirst)
o<428remap>sub
#<kinstype> = 1 ; xyzac,xyzbc
#<SWITCHKINS_PIN> = 3 ; set N as required: motion.analog-out-0N

o1 if [exists [#<_hal[motion.switchkins-type]>]]
o1 else
(debug,M428:Missing [RS274NGC]HAL_PIN_VARS=1)
(debug,STOP)
M2
o1 endif

M68 E#<SWITCHKINS_PIN> Q#<kinstype> ; set kinstype value
M66 E0 L0 ; force synch
G12.1 P#<kinstype> ; select kinstype, syncs interp and motion

o2 if [[#<_task> EQ 1] AND [#<_hal[motion.switchkins-type]> NE #<kinstype>]]
(debug,M428: Wrong motion.switchkins-type)
(debug,or missing hal net to analog-out-0x)
o2 if [[#<_task> EQ 1] AND [#<_kins_type> NE #<kinstype>]]
(debug,M428: Wrong kinematics type)
(debug,STOP)
M2
o2 else
o2 endif

o<428remap>endsub
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
;M429 by remap: kinstype==0 Identity kinematics
o<429remap>sub
#<kinstype> = 0
#<SWITCHKINS_PIN> = 3 ; set N as required: motion.analog-out-0N

o1 if [exists [#<_hal[motion.switchkins-type]>]]
o1 else
(debug,M429:Missing [RS274NGC]HAL_PIN_VARS=1)
(debug,STOP)
M2
o1 endif

M68 E#<SWITCHKINS_PIN> Q#<kinstype> ; set kinstype value
M66 E0 L0 ; force synch
G13.1 ; back to kinstype 0, syncs interp and motion

o2 if [[#<_task> EQ 1] AND [#<_hal[motion.switchkins-type]> NE #<kinstype>]]
(debug,M429:Wrong motion.switchkins-type)
(debug,or missing hal net to analog-out-0x)
o2 if [[#<_task> EQ 1] AND [#<_kins_type> NE #<kinstype>]]
(debug,M429:Wrong kinematics type)
(debug,STOP)
M2
o2 else
o2 endif

o<429remap>endsub
Original file line number Diff line number Diff line change
@@ -1,24 +1,13 @@
;M430 by remap: kinstype==2 userk kins
o<430remap>sub
#<kinstype> = 2
#<SWITCHKINS_PIN> = 3 ; set N as required: motion.analog-out-0N

o1 if [exists [#<_hal[motion.switchkins-type]>]]
o1 else
(debug,M430:Missing [RS274NGC]HAL_PIN_VARS=1)
(debug,STOP)
M2
o1 endif

M68 E#<SWITCHKINS_PIN> Q#<kinstype> ; set kinstype value
M66 E0 L0 ; force synch
G12.1 P#<kinstype> ; select kinstype, syncs interp and motion

o2 if [[#<_task> EQ 1] AND [#<_hal[motion.switchkins-type]> NE #<kinstype>]]
(debug,M430:Wrong motion.switchkins-type)
(debug,or missing hal net to analog-out-0x)
o2 if [[#<_task> EQ 1] AND [#<_kins_type> NE #<kinstype>]]
(debug,M430:Wrong kinematics type)
(debug,STOP)
M2
o2 else
o2 endif

o<430remap>endsub
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
pin+motion.analog-out-03
pin+motion.switchkins-type
pin+motion.kins-type

pin+joint.0.pos-cmd
pin+joint.1.pos-cmd
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ SUBROUTINE_PATH = ./remap_subs

[KINS]
#NOTE: for backwrds compatibility !!!!!!!!!!!!!!!!!!!
# default switchkins-type == 0 is xyzac-trt-kins
# here switchkins-type == 0 is identity kins
# default kinstype 0 is xyzac-trt-kins
# here kinstype 0 is identity kins
KINEMATICS = xyzac-trt-kins sparm=identityfirst
JOINTS = 5

Expand All @@ -48,8 +48,6 @@ KINEMATICS = xyzac-trt-kins sparm=identityfirst
HALFILE = LIB:basic_sim.tcl
POSTGUI_HALFILE = switchkins_postgui.hal

# net for control of motion.switchkins-type
HALCMD = net :kinstype-select <= motion.analog-out-03 => motion.switchkins-type

# vismach xyzac-trt-gui items
HALCMD = loadusr -W xyzac-trt-gui
Expand All @@ -73,9 +71,9 @@ HALCMD = setp xyzac-trt-kins.conventional-directions 0

[HALUI]
# NOTE: kinstype==0 is identity kins because sparm=identityfirst
# M429:identity kins (motion.switchkins-type==0 startupDEFAULT)
# M428:xyzac kins (motion.switchkins-type==1)
# M430:userk kins (motion.switchkins-type==2)
# M429:identity kins (kinstype 0, startupDEFAULT)
# M428:xyzac kins (kinstype 1)
# M430:userk kins (kinstype 2)
MDI_COMMAND = M429
MDI_COMMAND = M428
MDI_COMMAND = M430
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,9 @@ Uses remapped user m codes for kins switch:
M428: XYZAC (TCP)
M430: userk Kinematics

A hal net is required to connect the
analog out pin N, Example (for N=3):

net :kinstype-select <= motion.analog-out-03
net :kinstype-select => motion.switchkins-type
The kinematics type is selected with
G12.1 and G13.1, no hal connection is
required.

Hal Input pins:
xyzac-trt-kins.y-offset
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ SUBROUTINE_PATH = ./remap_subs

[KINS]
#NOTE: for backwrds compatibility !!!!!!!!!!!!!!!!!!!
# default switchkins-type == 0 is xyzbc-trt-kins
# here switchkins-type == 0 is identity kins
# default kinstype 0 is xyzbc-trt-kins
# here kinstype 0 is identity kins
KINEMATICS = xyzbc-trt-kins sparm=identityfirst
JOINTS = 5

Expand All @@ -48,8 +48,6 @@ KINEMATICS = xyzbc-trt-kins sparm=identityfirst
HALFILE = LIB:basic_sim.tcl
POSTGUI_HALFILE = switchkins_postgui.hal

# net for control of motion.switchkins-type
HALCMD = net :kinstype-select <= motion.analog-out-03 => motion.switchkins-type

# vismach xyzbc-trt-gui items
HALCMD = loadusr -W xyzbc-trt-gui
Expand All @@ -73,9 +71,9 @@ HALCMD = setp xyzbc-trt-kins.conventional-directions 0

[HALUI]
# NOTE: kinstype==0 is identity kins because sparm=identityfirst
# M429:identity kins (motion.switchkins-type==0 startupDEFAULT)
# M428:xyzbc kins (motion.switchkins-type==1)
# M430:userk kins (motion.switchkins-type==2)
# M429:identity kins (kinstype 0, startupDEFAULT)
# M428:xyzbc kins (kinstype 1)
# M430:userk kins (kinstype 2)
MDI_COMMAND = M429
MDI_COMMAND = M428
MDI_COMMAND = M430
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,9 @@ Uses remapped user m codes for kins switch:
M428: XYZBC (TCP)
M430: userk Kinematics

A hal net is required to connect the
analog out pin N, Example (for N=3):

net :kinstype-select <= motion.analog-out-03
net :kinstype-select => motion.switchkins-type
The kinematics type is selected with
G12.1 and G13.1, no hal connection is
required.

Hal Input pins:
xyzbc-trt-kins.x-offset
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -871,7 +871,7 @@ def g53x_core(self):
# switch to the dedicated TWP work offsets
self.execute("G59", lineno())
# activate TOOL kinematics
self.execute("M68 E3 Q2")
self.execute("G12.1 P2")
if (x,y,z) != (None,None,None):
log.debug('G53.3 called')
self.execute("G0 X%s Y%s Z%s %s%f %s%f" % (x, y, z, joint_letter_secondary, degrees(theta_2), joint_letter_primary, degrees(theta_1)), lineno())
Expand Down
Loading