# EMC controller parameters for a simulated machine.
# General note: Comments can either be preceded with a # or ; - either is
# acceptable, although # is in keeping with most linux config files.

# General section -------------------------------------------------------------
[EMC]
VERSION = 1.1
MACHINE =               silverdragon
DEBUG = 0


# Sections for display options ------------------------------------------------
[DISPLAY]
DISPLAY = gscreen -d -c silverdragon
# Cycle time, in milliseconds, that display will sleep between polls
CYCLE_TIME =            100
#PREFERENCE_FILE_PATH = /home/jim/linuxcnc/configs/sim.gscreen.gscreen_custom/silverdragon.pref
# Values that will be allowed for override, 1.0 = 100%
MAX_FEED_OVERRIDE    =  1.5
MAX_RAPID_OVERRIDE   =  1.0
MAX_SPINDLE_OVERRIDE =  1.2
MIN_SPINDLE_OVERRIDE =  0.5
DEFAULT_SPINDLE_SPEED = 24000
DEFAULT_LINEAR_VELOCITY = 4000
MAX_LINEAR_VELOCITY     = 5000

# USER MESSAGES
MESSAGE_BOLDTEXT = Attention!
MESSAGE_TEXT     = Is the router ON and workpiece ZERO set?
MESSAGE_TYPE     = yesnodialog
MESSAGE_PINNAME  = router_on

# Prefix to be used
PROGRAM_PREFIX = /home/jim/linuxcnc/nc_files

# Introductory graphic
INTRO_GRAPHIC = linuxcnc.gif
INTRO_TIME = 2

# list of selectable jog increments
INCREMENTS = 10.000 mm, 1.000 mm, 0.100 mm, 0.010 mm , 1.0 in, 0.1 in, 0.01 in, 0.001 in

# for details see nc_files/subroutines/maco_instructions.txt
[FILTER]
PROGRAM_EXTENSION = .png,.gif,.jpg Grayscale Depth Image
PROGRAM_EXTENSION = .py Python Script
png = image-to-gcode
gif = image-to-gcode
jpg = image-to-gcode
py = python

# Task controller section -----------------------------------------------------
[RS274NGC]
RS274NGC_STARTUP_CODE = G17 G21 G40 G43H0 G54 G64P0.005 G80 G90 G94 G97 M5 M9
PARAMETER_FILE = sim.var
SUBROUTINE_PATH = macros
ON_ABORT_COMMAND=O <on_abort> call
FEATURES=12
#REMAP = M6 modalgroup=6 prolog=change_prolog ngc=auto_zref epilog=change_epilog

# Motion control section ------------------------------------------------------
[EMCMOT]
EMCMOT =              motmod
COMM_TIMEOUT =          1.0
BASE_PERIOD  =          100000
SERVO_PERIOD =          1000000

# Hardware Abstraction Layer section --------------------------------------------------
[TASK]
TASK =                  milltask
CYCLE_TIME =            0.001

# Part program interpreter section --------------------------------------------
[HAL]
HALFILE = core_sim.hal
#HALFILE = spindle_sim.hal
HALFILE = simulated_home.hal

# Single file that is executed after the GUI has started.
#POSTGUI_HALFILE = silverdragon_postgui.hal
HALUI = halui

# Trajectory planner section --------------------------------------------------
[HALUI]
#No Content

[TOOLSENSOR]
X = 10.0
Y = 10.0
Z = -80.0
MAXPROBE = -10
SENSOR_HEIGHT = 25.0
SEARCH_VEL = 60
PROBE_VEL = 30

[LASER]
X = 106.9
Y = -16.85

[CHANGE_POSITION]
X = 20
Y = 20
Z = -4

[PYTHON]
#PATH_PREPEND = python
#TOPLEVEL = python/toplevel.py

[TRAJ]
COORDINATES =      X Y Z 
LINEAR_UNITS =     mm
ANGULAR_UNITS =    degree
DEFAULT_LINEAR_VELOCITY = 50
MAX_LINEAR_VELOCITY = 60
POSITION_FILE =  position.txt
#NO_FORCE_HOMING = 1

[EMCIO]
EMCIO = 		io
CYCLE_TIME =    0.100

# tool table file
TOOL_TABLE = tool.tbl
TOOL_CHANGE_POSITION = 100 100 -10
#TOOL_CHANGE_QUILL_UP = 1
#TOOL_CHANGE_AT_G30 = 1

[KINS]
KINEMATICS = trivkins coordinates=xyz
JOINTS = 3

[AXIS_X]
MIN_LIMIT = -.001
MAX_LIMIT = 520.0
MAX_VELOCITY = 60
MAX_ACCELERATION = 1500.0

[JOINT_0]
TYPE = LINEAR
MAX_VELOCITY = 60
MAX_ACCELERATION = 1500.0
BACKLASH = 0.000
INPUT_SCALE = 4000
OUTPUT_SCALE = 1.000
MIN_LIMIT = -.001
MAX_LIMIT = 520.0
FERROR = 0.050
MIN_FERROR = 0.010
HOME_OFFSET = 0.0
HOME = 10
HOME_SEARCH_VEL = 200.0
HOME_LATCH_VEL = 20.0
HOME_USE_INDEX = NO
HOME_IGNORE_LIMITS = NO
HOME_SEQUENCE = 2
HOME_IS_SHARED = 1

[AXIS_Y]
MIN_LIMIT = -.001
MAX_LIMIT = 630.0
MAX_VELOCITY = 60
MAX_ACCELERATION = 1500.0

[JOINT_1]
TYPE = LINEAR
MAX_VELOCITY = 60
MAX_ACCELERATION = 1500.0
BACKLASH = 0.000
INPUT_SCALE = 4000
OUTPUT_SCALE = 1.000
MIN_LIMIT = -.001
MAX_LIMIT = 630.0
FERROR = 0.050
MIN_FERROR = 0.010
HOME_OFFSET = 0.0
HOME = 10
HOME_SEARCH_VEL = 200.0
HOME_LATCH_VEL = 20.0
HOME_USE_INDEX = NO
HOME_IGNORE_LIMITS = NO
HOME_SEQUENCE = 1

# Third axis
[AXIS_Z]
MIN_LIMIT = -120.0
MAX_LIMIT = 10.0
MAX_VELOCITY = 60
MAX_ACCELERATION = 1500.0

[JOINT_2]
TYPE = LINEAR
MAX_VELOCITY = 60
MAX_ACCELERATION = 1500.0
BACKLASH = 0.000
INPUT_SCALE = 4000
OUTPUT_SCALE = 1.000
MIN_LIMIT = -120.0
MAX_LIMIT = 10.0
FERROR = 0.050
MIN_FERROR = 0.010
HOME_OFFSET = 1.0
HOME = -10
HOME_SEARCH_VEL = 200.0
HOME_LATCH_VEL = 20.0
HOME_USE_INDEX = NO
HOME_IGNORE_LIMITS = NO
HOME_SEQUENCE = 0
HOME_IS_SHARED = 1
