[EMC]
VERSION = 1.1
MACHINE = SCARA (genserkins,switchkins)
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
#DEBUG = 0

[DISPLAY]
DISPLAY = axis
CYCLE_TIME = 0.200
POSITION_OFFSET = RELATIVE
POSITION_FEEDBACK = ACTUAL
MAX_FEED_OVERRIDE = 2.0
PROGRAM_PREFIX = ../../nc_files/
INTRO_GRAPHIC = linuxcnc.gif
INTRO_TIME = 5
PYVCP = scara.xml
#EDITOR = geany

[RS274NGC]
SUBROUTINE_PATH = ./remap_subs
   HAL_PIN_VARS = 1
   HAL_PIN_VARS = 1
          REMAP = M428  modalgroup=10  ngc=428remap
          REMAP = M429  modalgroup=10  ngc=429remap
          REMAP = M430  modalgroup=10  ngc=430remap
PARAMETER_FILE = scara.var
# startup mm and offsets for axis.ngc demo file:
RS274NGC_STARTUP_CODE = G21 G10L2P0 x432 y65 z416 (debug, ini: startup offsets)

[EMCMOT]
EMCMOT = motmod
COMM_TIMEOUT = 1.0
SERVO_PERIOD = 1000000

[TASK]
TASK = milltask
CYCLE_TIME = 0.010

[KINS]
JOINTS = 6
# switchkins:
#   kinstype==0 (default scarakins)
#     j0,j1,j2,j3 -- implement scarakins for xyzc
#     j4 == world->a (scaragui j4 is table tilt (y))
#     j5 == world->b (scaragui j5 is table tilt (x))
#   kinstype==1 (identity, assign per coordinates=xyzcab)
#     letter x -- assigned to j0
#     letter y -- assigned to j1
#     letter z -- assigned to j2
#     letter c -- assigned to j3
#     letter a -- assigned to j4 (same as scarakins)
#     letter b -- assigned to j5 (same as scarakins)
#   kinstype==2 (userk, template is identity, user may specify)
#
# Note: coordinate= ordering for identity kins preserves ab relationships
KINEMATICS = scarakins coordinates=xyzcab

[HAL]
HALUI   = halui
HALFILE = LIB:basic_sim.tcl
HALCMD  = loadusr -W scaragui
HALCMD  = net :kinstype-select <= motion.analog-out-03 => motion.switchkins-type
POSTGUI_HALFILE = scara_postgui.hal

[HALUI]
# M428:scara kins    (kinstype==0 startupDEFAULT)
# M429:identity kins (kinstype==1)
# M430:userk kins    (kinstype==2)
MDI_COMMAND = M428
MDI_COMMAND = M429
MDI_COMMAND = M430

[TRAJ]
COORDINATES = XYZABC
LINEAR_UNITS = mm
DEFAULT_LINEAR_VELOCITY = 10.0
MAX_LINEAR_VELOCITY = 600.0
DEFAULT_LINEAR_ACCELERATION = 100.0
MAX_LINEAR_ACCELERATION = 200.0
ANGULAR_UNITS = degree
DEFAULT_ANGULAR_VELOCITY = 10.0
MAX_ANGULAR_VELOCITY = 600.0
DEFAULT_ANGULAR_ACCELERATION = 100.0
MAX_ANGULAR_ACCELERATION = 200.0

[EMCIO]
EMCIO = io
CYCLE_TIME = 0.100
TOOL_TABLE = scara.tbl

[AXIS_X]
MAX_VELOCITY = 30.0
MAX_ACCELERATION = 200.0
[AXIS_Y]
MAX_VELOCITY = 30.0
MAX_ACCELERATION = 200.0
[AXIS_Z]
MAX_VELOCITY = 30.0
MAX_ACCELERATION = 200.0
[AXIS_C]
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0

[JOINT_0]
NAME = shoulder
TYPE = ANGULAR
MAX_VELOCITY = 30.0
MAX_ACCELERATION = 200.0
MIN_LIMIT = -360.0
MAX_LIMIT = 360.0
HOME_OFFSET = 0.0
HOME = 0.000
HOME_SEQUENCE = 0

[JOINT_1]
NAME = elbow
TYPE = ANGULAR
MAX_VELOCITY = 30.0
MAX_ACCELERATION = 200.0
MIN_LIMIT = -360.0
MAX_LIMIT = 360.0
HOME_OFFSET = 0.0
HOME = 0.000
HOME_SEQUENCE = 0

[JOINT_2]
NAME = z-slide
TYPE = LINEAR
MAX_VELOCITY = 30.0
MAX_ACCELERATION = 200.0
MIN_LIMIT = 25.0
MAX_LIMIT = 300.0
HOME_OFFSET = 25.0
HOME = 25.000
HOME_SEQUENCE = 0

[JOINT_3]
NAME = wrist
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
MIN_LIMIT = -180.0
MAX_LIMIT = 180.0
HOME_OFFSET = 0.0
HOME = 0.000
HOME_SEQUENCE = 0

[JOINT_4]
NAME = table_rotate
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
MIN_LIMIT = -180.0
MAX_LIMIT =  180.0
HOME_OFFSET = 0.0
HOME = 0.000
HOME_SEQUENCE = 0

[JOINT_5]
NAME = table_rotate
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
MIN_LIMIT = -180.0
MAX_LIMIT =  180.0
HOME_OFFSET = 0.0
HOME = 0.000
HOME_SEQUENCE = 0
