Import LinuxCNC source tree
This commit is contained in:
1
configs/by_interface/parport/.gitignore
vendored
Normal file
1
configs/by_interface/parport/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
core_stepper.hal
|
||||
3
configs/by_interface/parport/README
Normal file
3
configs/by_interface/parport/README
Normal file
@@ -0,0 +1,3 @@
|
||||
PC parallel port (printer port)
|
||||
|
||||
Standard printer port on motherboard or add-on pci card
|
||||
@@ -0,0 +1,84 @@
|
||||
# Generated by stepconf at Sat Sep 20 16:05:23 2008
|
||||
# If you make changes to this file, they will be
|
||||
# overwritten when you run stepconf again
|
||||
loadrt [KINS]KINEMATICS
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD traj_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
|
||||
loadrt hal_parport cfg=0x378
|
||||
setp parport.0.reset-time 5000
|
||||
loadrt stepgen step_type=0,0,0
|
||||
|
||||
addf parport.0.read base-thread
|
||||
addf stepgen.make-pulses base-thread
|
||||
addf parport.0.write base-thread
|
||||
addf parport.0.reset base-thread
|
||||
|
||||
addf stepgen.capture-position servo-thread
|
||||
addf motion-command-handler servo-thread
|
||||
addf motion-controller servo-thread
|
||||
addf stepgen.update-freq servo-thread
|
||||
|
||||
net estop-out => parport.0.pin-01-out
|
||||
net xstep => parport.0.pin-02-out
|
||||
setp parport.0.pin-02-out-reset 1
|
||||
net xdir => parport.0.pin-03-out
|
||||
net ystep => parport.0.pin-04-out
|
||||
setp parport.0.pin-04-out-reset 1
|
||||
net ydir => parport.0.pin-05-out
|
||||
net zstep => parport.0.pin-06-out
|
||||
setp parport.0.pin-06-out-reset 1
|
||||
net zdir => parport.0.pin-07-out
|
||||
|
||||
net both-home-x <= parport.0.pin-10-in
|
||||
net both-home-y <= parport.0.pin-11-in
|
||||
net both-home-z <= parport.0.pin-12-in
|
||||
|
||||
setp stepgen.0.position-scale [JOINT_0]SCALE
|
||||
setp stepgen.0.steplen 1
|
||||
setp stepgen.0.stepspace 0
|
||||
setp stepgen.0.dirhold 16000
|
||||
setp stepgen.0.dirsetup 16000
|
||||
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
|
||||
net xpos-cmd joint.0.motor-pos-cmd => stepgen.0.position-cmd
|
||||
net xpos-fb stepgen.0.position-fb => joint.0.motor-pos-fb
|
||||
net xstep <= stepgen.0.step
|
||||
net xdir <= stepgen.0.dir
|
||||
net xenable joint.0.amp-enable-out => stepgen.0.enable
|
||||
net both-home-x => joint.0.home-sw-in
|
||||
net both-home-x => joint.0.neg-lim-sw-in
|
||||
net both-home-x => joint.0.pos-lim-sw-in
|
||||
|
||||
setp stepgen.1.position-scale [JOINT_1]SCALE
|
||||
setp stepgen.1.steplen 1
|
||||
setp stepgen.1.stepspace 0
|
||||
setp stepgen.1.dirhold 16000
|
||||
setp stepgen.1.dirsetup 16000
|
||||
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
|
||||
net ypos-cmd joint.1.motor-pos-cmd => stepgen.1.position-cmd
|
||||
net ypos-fb stepgen.1.position-fb => joint.1.motor-pos-fb
|
||||
net ystep <= stepgen.1.step
|
||||
net ydir <= stepgen.1.dir
|
||||
net yenable joint.1.amp-enable-out => stepgen.1.enable
|
||||
net both-home-y => joint.1.home-sw-in
|
||||
net both-home-y => joint.1.neg-lim-sw-in
|
||||
net both-home-y => joint.1.pos-lim-sw-in
|
||||
|
||||
setp stepgen.2.position-scale [JOINT_2]SCALE
|
||||
setp stepgen.2.steplen 1
|
||||
setp stepgen.2.stepspace 0
|
||||
setp stepgen.2.dirhold 16000
|
||||
setp stepgen.2.dirsetup 16000
|
||||
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
|
||||
net zpos-cmd joint.2.motor-pos-cmd => stepgen.2.position-cmd
|
||||
net zpos-fb stepgen.2.position-fb => joint.2.motor-pos-fb
|
||||
net zstep <= stepgen.2.step
|
||||
net zdir <= stepgen.2.dir
|
||||
net zenable joint.2.amp-enable-out => stepgen.2.enable
|
||||
net both-home-z => joint.2.home-sw-in
|
||||
net both-home-z => joint.2.neg-lim-sw-in
|
||||
net both-home-z => joint.2.pos-lim-sw-in
|
||||
|
||||
# net estop-out <= iocontrol.0.user-enable-out
|
||||
# net estop-out => iocontrol.0.emc-enable-in
|
||||
|
||||
net tool-change-loopback iocontrol.0.tool-change => iocontrol.0.tool-changed
|
||||
net tool-prepare-loopback iocontrol.0.tool-prepare => iocontrol.0.tool-prepared
|
||||
129
configs/by_interface/parport/classicladder/cl-estop/cl-estop.ini
Normal file
129
configs/by_interface/parport/classicladder/cl-estop/cl-estop.ini
Normal file
@@ -0,0 +1,129 @@
|
||||
# Generated by stepconf at Sat Sep 20 16:05:23 2008
|
||||
# If you make changes to this file, they will be
|
||||
# overwritten when you run stepconf again
|
||||
|
||||
[EMC]
|
||||
# The version string for this INI file.
|
||||
VERSION = 1.1
|
||||
MACHINE = Stepper-CL-EStop
|
||||
DEBUG = 0
|
||||
|
||||
[DISPLAY]
|
||||
DISPLAY = axis
|
||||
#EDITOR = geany
|
||||
POSITION_OFFSET = RELATIVE
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
MAX_FEED_OVERRIDE = 1.2
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
#PROGRAM_PREFIX = /home/jet/emc2/nc_files
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
INCREMENTS = .1in .05in .01in .005in .001in .0005in .0001in
|
||||
PYVCP = panel.xml
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
PARAMETER_FILE = emc.var
|
||||
|
||||
[EMCMOT]
|
||||
EMCMOT = motmod
|
||||
COMM_TIMEOUT = 1.0
|
||||
BASE_PERIOD = 100000
|
||||
SERVO_PERIOD = 1000000
|
||||
|
||||
[TASK]
|
||||
TASK = milltask
|
||||
CYCLE_TIME = 0.010
|
||||
|
||||
[HAL]
|
||||
HALFILE = cl-estop.hal
|
||||
HALFILE = custom.hal
|
||||
POSTGUI_HALFILE = custom_postgui.hal
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
COORDINATES = X Y Z
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 0.10
|
||||
MAX_LINEAR_VELOCITY = 1.00
|
||||
|
||||
[EMCIO]
|
||||
TOOL_TABLE = tool.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -0.01
|
||||
MAX_LIMIT = 12.0
|
||||
MAX_VELOCITY = 1.0
|
||||
MAX_ACCELERATION = 30.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 1.0
|
||||
MAX_ACCELERATION = 30.0
|
||||
STEPGEN_MAXACCEL = 37.5
|
||||
SCALE = 8000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -0.01
|
||||
MAX_LIMIT = 12.0
|
||||
HOME_OFFSET = 0.000000
|
||||
HOME_SEARCH_VEL = 0.050000
|
||||
HOME_LATCH_VEL = 0.050000
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 1
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -0.01
|
||||
MAX_LIMIT = 8.0
|
||||
MAX_VELOCITY = 1.0
|
||||
MAX_ACCELERATION = 30.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 1.0
|
||||
MAX_ACCELERATION = 30.0
|
||||
STEPGEN_MAXACCEL = 37.5
|
||||
SCALE = 8000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -0.01
|
||||
MAX_LIMIT = 8.0
|
||||
HOME_OFFSET = 0.000000
|
||||
HOME_SEARCH_VEL = 0.050000
|
||||
HOME_LATCH_VEL = 0.050000
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 2
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -4.0
|
||||
MAX_LIMIT = 0.01
|
||||
MAX_VELOCITY = 1.0
|
||||
MAX_ACCELERATION = 30.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 1.0
|
||||
MAX_ACCELERATION = 30.0
|
||||
STEPGEN_MAXACCEL = 37.5
|
||||
SCALE = 8000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -4.0
|
||||
MAX_LIMIT = 0.01
|
||||
HOME_OFFSET = 0.000000
|
||||
HOME_SEARCH_VEL = 0.050000
|
||||
HOME_LATCH_VEL = 0.050000
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 0
|
||||
@@ -0,0 +1,12 @@
|
||||
# Include your customized HAL commands here
|
||||
# This file will not be overwritten when you run stepconf again
|
||||
|
||||
# Load ClassicLadder
|
||||
loadrt classicladder_rt
|
||||
|
||||
# Add the ClassicLadder refresh function to the servo thread
|
||||
addf classicladder.0.refresh servo-thread
|
||||
|
||||
# Load the ladder
|
||||
loadusr classicladder --nogui estop.clp
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
# Include your customized HAL commands here
|
||||
# The commands in this file are run after the AXIS GUI (including PyVCP panel)
|
||||
# starts
|
||||
# This file will not be overwritten when you run stepconf again
|
||||
|
||||
# External E-Stop pyVCP button for external use a normally closed contact
|
||||
loadrt not count=1
|
||||
addf not.0 servo-thread
|
||||
|
||||
# The not changes the normally open pyVCP button to normally closed
|
||||
net nc-gui-estop not.0.in <= pyvcp.py-estop
|
||||
net ext-estop classicladder.0.in-00 <= not.0.out
|
||||
|
||||
# Request E-Stop Enable from EMC
|
||||
net estop-all-ok iocontrol.0.emc-enable-in <= classicladder.0.out-00
|
||||
|
||||
# Request E-Stop Enable from pyVCP or external source
|
||||
net ext-estop-reset classicladder.0.in-03 <= pyvcp.py-reset
|
||||
|
||||
# This line resets the E-Stop from EMC
|
||||
net emc-reset-estop iocontrol.0.user-request-enable => classicladder.0.in-02
|
||||
|
||||
# This line enables EMC to unlatch the E-Stop in classicladder
|
||||
net emc-estop iocontrol.0.user-enable-out => classicladder.0.in-01
|
||||
|
||||
# This line turns on the green indicator when out of E-Stop
|
||||
net estop-all-ok => pyvcp.py-es-status
|
||||
198
configs/by_interface/parport/classicladder/cl-estop/estop.clp
Normal file
198
configs/by_interface/parport/classicladder/cl-estop/estop.clp
Normal file
@@ -0,0 +1,198 @@
|
||||
_FILES_CLASSICLADDER
|
||||
_FILE-general.txt
|
||||
PERIODIC_REFRESH=1
|
||||
SIZE_NBR_RUNGS=100
|
||||
SIZE_NBR_BITS=500
|
||||
SIZE_NBR_WORDS=100
|
||||
SIZE_NBR_TIMERS=10
|
||||
SIZE_NBR_MONOSTABLES=10
|
||||
SIZE_NBR_COUNTERS=10
|
||||
SIZE_NBR_TIMERS_IEC=10
|
||||
SIZE_NBR_PHYS_INPUTS=15
|
||||
SIZE_NBR_PHYS_OUTPUTS=15
|
||||
SIZE_NBR_ARITHM_EXPR=100
|
||||
SIZE_NBR_SECTIONS=10
|
||||
SIZE_NBR_SYMBOLS=100
|
||||
_/FILE-general.txt
|
||||
_FILE-timers.csv
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
_/FILE-timers.csv
|
||||
_FILE-monostables.csv
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
_/FILE-monostables.csv
|
||||
_FILE-counters.csv
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
_/FILE-counters.csv
|
||||
_FILE-timers_iec.csv
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
_/FILE-timers_iec.csv
|
||||
_FILE-arithmetic_expressions.csv
|
||||
#VER=2.0
|
||||
_/FILE-arithmetic_expressions.csv
|
||||
_FILE-rung_0.csv
|
||||
#VER=2.0
|
||||
#LABEL=
|
||||
#COMMENT=
|
||||
#PREVRUNG=-1
|
||||
#NEXTRUNG=0
|
||||
1-0-50/0 , 9-0-0/0 , 1-0-50/1 , 9-0-0/0 , 1-0-50/2 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 50-0-60/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-1-0/0 , 0-0-0/0 , 1-1-60/2 , 0-1-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 50-1-60/1
|
||||
0-0-0/0 , 0-0-0/0 , 0-1-0/0 , 0-0-0/0 , 1-1-60/0 , 0-1-0/0 , 0-1-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 1-1-50/3 , 9-0-0/0 , 9-0-0/0 , 0-1-0/0 , 0-1-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
_/FILE-rung_0.csv
|
||||
_FILE-sections.csv
|
||||
#VER=1.0
|
||||
#NAME000=Prog1
|
||||
000,0,-1,0,0,0
|
||||
_/FILE-sections.csv
|
||||
_FILE-sequential.csv
|
||||
#VER=1.0
|
||||
_/FILE-sequential.csv
|
||||
_FILE-ioconf.csv
|
||||
#VER=1.0
|
||||
_/FILE-ioconf.csv
|
||||
_FILE-modbusioconf.csv
|
||||
#VER=1.0
|
||||
_/FILE-modbusioconf.csv
|
||||
_FILE-symbols.csv
|
||||
#VER=1.0
|
||||
%I0,EStop,External E-Stop
|
||||
%I1,EMCReset,Auto named bit-in pin
|
||||
%I2,USRReset,Auto named bit-in pin
|
||||
%I3,CLinB3,Auto named bit-in pin
|
||||
%I4,CLinB4,Auto named bit-in pin
|
||||
%I5,CLinB5,Auto named bit-in pin
|
||||
%I6,CLinB6,Auto named bit-in pin
|
||||
%I7,CLinB7,Auto named bit-in pin
|
||||
%I8,CLinB8,Auto named bit-in pin
|
||||
%I9,CLinB9,Auto named bit-in pin
|
||||
%I10,CLinB10,Auto named bit-in pin
|
||||
%I11,CLinB11,Auto named bit-in pin
|
||||
%I12,CLinB12,Auto named bit-in pin
|
||||
%I13,CLinB13,Auto named bit-in pin
|
||||
%I14,CLinB14,Auto named bit-in pin
|
||||
%I15,CLinB15,Auto named bit-in pin
|
||||
%I16,CLinB16,Auto named bit-in pin
|
||||
%I17,CLinB17,Auto named bit-in pin
|
||||
%I18,CLinB18,Auto named bit-in pin
|
||||
%I19,CLinB19,Auto named bit-in pin
|
||||
%I20,CLinB20,Auto named bit-in pin
|
||||
%I21,CLinB21,Auto named bit-in pin
|
||||
%I22,CLinB22,Auto named bit-in pin
|
||||
%I23,CLinB23,Auto named bit-in pin
|
||||
%I24,CLinB24,Auto named bit-in pin
|
||||
%I25,CLinB25,Auto named bit-in pin
|
||||
%I26,CLinB26,Auto named bit-in pin
|
||||
%I27,CLinB27,Auto named bit-in pin
|
||||
%I28,CLinB28,Auto named bit-in pin
|
||||
%I29,CLinB29,Auto named bit-in pin
|
||||
%I30,CLinB30,Auto named bit-in pin
|
||||
%I31,CLinB31,Auto named bit-in pin
|
||||
%I32,CLinB32,Auto named bit-in pin
|
||||
%I33,CLinB33,Auto named bit-in pin
|
||||
%I34,CLinB34,Auto named bit-in pin
|
||||
%I35,CLinB35,Auto named bit-in pin
|
||||
%I36,CLinB36,Auto named bit-in pin
|
||||
%I37,CLinB37,Auto named bit-in pin
|
||||
%I38,CLinB38,Auto named bit-in pin
|
||||
%I39,CLinB39,Auto named bit-in pin
|
||||
%I40,CLinB40,Auto named bit-in pin
|
||||
%I41,CLinB41,Auto named bit-in pin
|
||||
%I42,CLinB42,Auto named bit-in pin
|
||||
%I43,CLinB43,Auto named bit-in pin
|
||||
%I44,CLinB44,Auto named bit-in pin
|
||||
%I45,CLinB45,Auto named bit-in pin
|
||||
%I46,CLinB46,Auto named bit-in pin
|
||||
%I47,CLinB47,Auto named bit-in pin
|
||||
%I48,CLinB48,Auto named bit-in pin
|
||||
%I49,CLinB49,Auto named bit-in pin
|
||||
%Q0,All OK,Enable EMC E-Stop
|
||||
%Q1,EnDrive,Auto named bit-out pin
|
||||
%Q2,CLoutB2,Auto named bit-out pin
|
||||
%Q3,CLoutB3,Auto named bit-out pin
|
||||
%Q4,CLoutB4,Auto named bit-out pin
|
||||
%Q5,CLoutB5,Auto named bit-out pin
|
||||
%Q6,CLoutB6,Auto named bit-out pin
|
||||
%Q7,CLoutB7,Auto named bit-out pin
|
||||
%Q8,CLoutB8,Auto named bit-out pin
|
||||
%Q9,CLoutB9,Auto named bit-out pin
|
||||
%Q10,CLoutB10,Auto named bit-out pin
|
||||
%Q11,CLoutB11,Auto named bit-out pin
|
||||
%Q12,CLoutB12,Auto named bit-out pin
|
||||
%Q13,CLoutB13,Auto named bit-out pin
|
||||
%Q14,CLoutB14,Auto named bit-out pin
|
||||
%Q15,CLoutB15,Auto named bit-out pin
|
||||
%Q16,CLoutB16,Auto named bit-out pin
|
||||
%Q17,CLoutB17,Auto named bit-out pin
|
||||
%Q18,CLoutB18,Auto named bit-out pin
|
||||
%Q19,CLoutB19,Auto named bit-out pin
|
||||
%Q20,CLoutB20,Auto named bit-out pin
|
||||
%Q21,CLoutB21,Auto named bit-out pin
|
||||
%Q22,CLoutB22,Auto named bit-out pin
|
||||
%Q23,CLoutB23,Auto named bit-out pin
|
||||
%Q24,CLoutB24,Auto named bit-out pin
|
||||
%Q25,CLoutB25,Auto named bit-out pin
|
||||
%Q26,CLoutB26,Auto named bit-out pin
|
||||
%Q27,CLoutB27,Auto named bit-out pin
|
||||
%Q28,CLoutB28,Auto named bit-out pin
|
||||
%Q29,CLoutB29,Auto named bit-out pin
|
||||
%Q30,CLoutB30,Auto named bit-out pin
|
||||
%Q31,CLoutB31,Auto named bit-out pin
|
||||
%Q32,CLoutB32,Auto named bit-out pin
|
||||
%Q33,CLoutB33,Auto named bit-out pin
|
||||
%Q34,CLoutB34,Auto named bit-out pin
|
||||
%Q35,CLoutB35,Auto named bit-out pin
|
||||
%Q36,CLoutB36,Auto named bit-out pin
|
||||
%Q37,CLoutB37,Auto named bit-out pin
|
||||
%Q38,CLoutB38,Auto named bit-out pin
|
||||
%Q39,CLoutB39,Auto named bit-out pin
|
||||
%Q40,CLoutB40,Auto named bit-out pin
|
||||
%Q41,CLoutB41,Auto named bit-out pin
|
||||
%Q42,CLoutB42,Auto named bit-out pin
|
||||
%Q43,CLoutB43,Auto named bit-out pin
|
||||
%Q44,CLoutB44,Auto named bit-out pin
|
||||
%Q45,CLoutB45,Auto named bit-out pin
|
||||
%Q46,CLoutB46,Auto named bit-out pin
|
||||
%Q47,CLoutB47,Auto named bit-out pin
|
||||
%Q48,CLoutB48,Auto named bit-out pin
|
||||
%Q49,CLoutB49,Auto named bit-out pin
|
||||
_/FILE-symbols.csv
|
||||
_/FILES_CLASSICLADDER
|
||||
@@ -0,0 +1,28 @@
|
||||
<?xml version='1.0' encoding='UTF-8'?>
|
||||
<!--
|
||||
Include your PyVCP panel here.
|
||||
The contents of this file will not be overwritten when you run stepconf again.
|
||||
-->
|
||||
<pyvcp>
|
||||
<vbox>
|
||||
<label><text>"E-Stop Demo"</text></label>
|
||||
<led>
|
||||
<halpin>"py-es-status"</halpin>
|
||||
<size>50</size>
|
||||
<on_color>"green"</on_color>
|
||||
<off_color>"red"</off_color>
|
||||
</led>
|
||||
<button>
|
||||
<halpin>"py-estop"</halpin>
|
||||
<text>"E-Stop"</text>
|
||||
</button>
|
||||
|
||||
</vbox>
|
||||
|
||||
<button>
|
||||
<halpin>"py-reset"</halpin>
|
||||
<text>"Reset"</text>
|
||||
</button>
|
||||
|
||||
|
||||
</pyvcp>
|
||||
@@ -0,0 +1,4 @@
|
||||
T1 P1 D0.125000 Z+0.511000 ;1/8 end mill
|
||||
T2 P2 D0.062500 Z+0.100000 ;1/16 end mill
|
||||
T3 P3 D0.201000 Z+1.273000 ;#7 tap drill
|
||||
T99999 P99999 Z+0.100000 ;big tool number
|
||||
@@ -0,0 +1,5 @@
|
||||
This config is "stepper" with the addition of ClassicLadder connections to some of the LinuxCNC IO.
|
||||
|
||||
The initial ladder program includes several possible estop arrangements and a timed lube coil. The lube ladder includes a sense run that watches lube level or lube pressure and warns of a lube condition failure.
|
||||
|
||||
This ladder integration with the HAL will allow you to expand the IO interface to a minimill with spindle and tool changer controls.
|
||||
@@ -0,0 +1,20 @@
|
||||
# first load realtime portion of classicladder, and create a 1mS thread
|
||||
loadrt classicladder_rt period=1000000
|
||||
|
||||
# hook functions to realtime thread
|
||||
addf classicladder.0.refresh classicladder.thread 1
|
||||
|
||||
# create some I/O signals
|
||||
|
||||
# connect I/O signals to classicladder
|
||||
net I0 => classicladder.0.in-00
|
||||
net I1 => classicladder.0.in-01
|
||||
net I2 => classicladder.0.in-02
|
||||
net Q0 <= classicladder.0.out-00
|
||||
net Q1 <= classicladder.0.out-01
|
||||
net Q2 <= classicladder.0.out-02
|
||||
|
||||
# set the input signals
|
||||
sets I0 0
|
||||
sets I1 0
|
||||
sets I2 0
|
||||
@@ -0,0 +1,167 @@
|
||||
_FILES_CLASSICLADDER
|
||||
_FILE-rung_1.csv
|
||||
#VER=2.0
|
||||
#LABEL=Rung 1
|
||||
#COMMENT=Stepper Estop Chain
|
||||
#PREVRUNG=0
|
||||
#NEXTRUNG=2
|
||||
0-0-50/0 , 1-0-50/0 , 9-0-50/0 , 9-0-50/1 , 9-0-0/0 , 9-0-0/0 , 9-0-60/0 , 9-0-0/0 , 9-0-0/0 , 50-0-60/0
|
||||
0-0-0/0 , 2-0-50/1 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-50/2 , 9-0-0/0 , 9-0-0/0 , 0-1-60/1
|
||||
0-0-50/0 , 1-0-50/0 , 2-0-50/1 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/1 , 9-0-0/0 , 0-1-60/1
|
||||
9-0-0/0 , 1-0-50/0 , 2-0-50/1 , 1-0-60/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 0-1-0/0
|
||||
0-0-60/1 , 0-0-0/0 , 0-0-0/0 , 1-1-50/2 , 0-1-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-60/6
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
_/FILE-rung_1.csv
|
||||
_FILE-symbols.csv
|
||||
#VER=1.0
|
||||
%I0,GUI-E,
|
||||
%I1,EXT-E,
|
||||
%I2,E-RESET,
|
||||
%I3,Lube_on,
|
||||
%I4,sensor,
|
||||
%I5,I5,
|
||||
%I6,I6,
|
||||
%I7,I7,
|
||||
%I8,I8,
|
||||
%I9, ,
|
||||
%Q0,EMC-E,
|
||||
%Q1,toggle,
|
||||
%Q2,Lube_low,
|
||||
%Q3,Q3,
|
||||
%Q4,Q4,
|
||||
%Q5,Q5,
|
||||
%Q6,Q6,
|
||||
%Q7,Q7,
|
||||
%Q8,Q8,
|
||||
%Q9,Q9,
|
||||
%T0,Time-on,Time lube pump is on
|
||||
%T1,Time-off,Time lube pump is off
|
||||
%T2,Time-warn,Time before low lube warning
|
||||
%B0,reset,reset off timer
|
||||
_/FILE-symbols.csv
|
||||
_FILE-rung_2.csv
|
||||
#VER=2.0
|
||||
#LABEL=
|
||||
#COMMENT=Intermittent Lube
|
||||
#PREVRUNG=1
|
||||
#NEXTRUNG=-1
|
||||
9-0-0/0 , 1-0-50/3 , 2-0-0/0 , 99-0-0/0 , 10-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 53-0-60/1
|
||||
0-0-0/0 , 0-0-0/0 , 0-1-0/0 , 99-1-0/0 , 99-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 52-0-60/1
|
||||
0-0-0/0 , 0-0-0/0 , 2-1-60/1 , 9-0-0/0 , 9-0-0/0 , 99-0-0/0 , 10-0-0/1 , 0-0-60/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-1-0/0 , 0-0-0/0 , 0-0-0/0 , 99-1-0/0 , 99-0-0/0 , 9-0-0/0 , 9-0-0/0 , 50-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 1-1-50/4 , 99-0-0/0 , 10-0-0/2 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-60/9
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 99-1-0/0 , 99-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 9-0-0/0 , 50-0-60/2
|
||||
_/FILE-rung_2.csv
|
||||
_FILE-modbusioconf.csv
|
||||
#VER=1.0
|
||||
_/FILE-modbusioconf.csv
|
||||
_FILE-com_params.txt
|
||||
MODBUS_MASTER_SERIAL_PORT=
|
||||
MODBUS_MASTER_SERIAL_SPEED=9600
|
||||
MODBUS_MASTER_SERIAL_DATABITS=8
|
||||
MODBUS_MASTER_SERIAL_STOPBITS=1
|
||||
MODBUS_MASTER_SERIAL_PARITY=0
|
||||
MODBUS_ELEMENT_OFFSET=0
|
||||
MODBUS_MASTER_SERIAL_USE_RTS_TO_SEND=0
|
||||
MODBUS_MASTER_TIME_INTER_FRAME=100
|
||||
MODBUS_MASTER_TIME_OUT_RECEIPT=500
|
||||
MODBUS_MASTER_TIME_AFTER_TRANSMIT=0
|
||||
MODBUS_DEBUG_LEVEL=0
|
||||
MODBUS_MAP_COIL_READ=0
|
||||
MODBUS_MAP_COIL_WRITE=0
|
||||
MODBUS_MAP_INPUT=0
|
||||
MODBUS_MAP_HOLDING=0
|
||||
MODBUS_MAP_REGISTER_READ=0
|
||||
MODBUS_MAP_REGISTER_WRITE=0
|
||||
_/FILE-com_params.txt
|
||||
_FILE-timers_iec.csv
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
1,0,0
|
||||
_/FILE-timers_iec.csv
|
||||
_FILE-timers.csv
|
||||
1,10
|
||||
1,20
|
||||
0,20
|
||||
2,1
|
||||
2,5
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
_/FILE-timers.csv
|
||||
_FILE-counters.csv
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
0
|
||||
_/FILE-counters.csv
|
||||
_FILE-sections.csv
|
||||
#VER=1.0
|
||||
#NAME000=Prog1
|
||||
000,0,-1,1,2,0
|
||||
_/FILE-sections.csv
|
||||
_FILE-arithmetic_expressions.csv
|
||||
#VER=2.0
|
||||
_/FILE-arithmetic_expressions.csv
|
||||
_FILE-rung_0.csv
|
||||
#VER=2.0
|
||||
#LABEL=
|
||||
#COMMENT=
|
||||
#PREVRUNG=0
|
||||
#NEXTRUNG=1
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0 , 0-0-0/0
|
||||
_/FILE-rung_0.csv
|
||||
_FILE-ioconf.csv
|
||||
#VER=1.0
|
||||
_/FILE-ioconf.csv
|
||||
_FILE-monostables.csv
|
||||
1,10
|
||||
1,20
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
1,0
|
||||
_/FILE-monostables.csv
|
||||
_FILE-sequential.csv
|
||||
#VER=1.0
|
||||
_/FILE-sequential.csv
|
||||
_FILE-general.txt
|
||||
PERIODIC_REFRESH=100
|
||||
SIZE_NBR_RUNGS=100
|
||||
SIZE_NBR_BITS=500
|
||||
SIZE_NBR_WORDS=100
|
||||
SIZE_NBR_TIMERS=10
|
||||
SIZE_NBR_MONOSTABLES=10
|
||||
SIZE_NBR_COUNTERS=10
|
||||
SIZE_NBR_TIMERS_IEC=10
|
||||
SIZE_NBR_PHYS_INPUTS=15
|
||||
SIZE_NBR_PHYS_OUTPUTS=25
|
||||
SIZE_NBR_ARITHM_EXPR=100
|
||||
SIZE_NBR_SECTIONS=10
|
||||
SIZE_NBR_SYMBOLS=100
|
||||
_/FILE-general.txt
|
||||
_/FILES_CLASSICLADDER
|
||||
@@ -0,0 +1,99 @@
|
||||
# HAL config file for using classic ladder
|
||||
# Loads the core_stepper.hal file first to set up motion and stepgen
|
||||
# This adds limits and home from limit to the motion module
|
||||
# adds the possibility of an external momentary or sustained NC estop button
|
||||
# includes intermittent lube pump and pressure or level sensing.
|
||||
# includes coolant and spindle forward, reverse
|
||||
|
||||
# from standard pinout config file for 3-axis steppers
|
||||
# using a parport for I/O
|
||||
|
||||
# load the parport driver
|
||||
loadrt hal_parport cfg="0x378"
|
||||
# next connect the parport functions to threads
|
||||
addf parport.0.read base-thread 1
|
||||
addf parport.0.write base-thread -1
|
||||
|
||||
# This configuration uses classicladder for machine logic
|
||||
# (load the realtime portion)
|
||||
# these classicladder parameters need to be optimized after ladder completion
|
||||
loadrt classicladder_rt numRungs=12 numBits=20 numWords=4 numTimers=5 numMonostables=2 numPhysInputs=10 numPhysOutputs=10 numArithmExpr=4 numSections=4
|
||||
# We kick ladder into a thread at the slower servo rate rather than base rate
|
||||
addf classicladder.0.refresh servo-thread 1
|
||||
|
||||
# invoke the user part of CL to silently load the program
|
||||
# later we will need to add the clp file mentioned below
|
||||
# to the ini file so that we do not need to hardcode it here.
|
||||
loadusr -w classicladder --nogui demo_step_cl.clp
|
||||
# load the GUI as well
|
||||
loadusr classicladder
|
||||
|
||||
# begin to connect physical pins to signals
|
||||
# this is EMC's standard motion pinouts
|
||||
net Xstep parport.0.pin-03-out
|
||||
net Xdir parport.0.pin-02-out
|
||||
net Ystep parport.0.pin-05-out
|
||||
net Ydir parport.0.pin-04-out
|
||||
net Zstep parport.0.pin-07-out
|
||||
net Zdir parport.0.pin-06-out
|
||||
|
||||
# three axis motion allows 6 other outputs on pins 8,9,1,14,16,17
|
||||
# five additional input pins are available 10,11,12,13,15
|
||||
# these are setup by the work they perform below
|
||||
|
||||
# estop signals
|
||||
# signal is the internal or gui estop command from EMC
|
||||
net user-enable-out iocontrol.0.user-enable-out classicladder.0.in-00
|
||||
# one-shot on timer when signal above goes high.
|
||||
net user-request-enable iocontrol.0.user-request-enable classicladder.0.in-02
|
||||
# this bit is an external estop button connected to parport pin 11 and ground
|
||||
net ext-estop parport.0.pin-10-in
|
||||
net ext-estop classicladder.0.in-01
|
||||
# This bit signal is command to estop from CL to EMC
|
||||
net emc-enable-in iocontrol.0.emc-enable-in classicladder.0.out-00
|
||||
|
||||
# lube signals
|
||||
# lube run command from emc to CL
|
||||
# for ease of reading we will make a new signal lube-run
|
||||
net lube-run classicladder.0.out-01
|
||||
net lube-run parport.0.pin-01-out
|
||||
|
||||
# The lube sense stuff runs from an external pin, through CL to iocontrol in
|
||||
# lube-up is the signal between the parport and cl
|
||||
net lube-up parport.0.pin-12-in
|
||||
net lube-up classicladder.0.in-04
|
||||
|
||||
# coolant signals
|
||||
# note that these do NOT represent proper IO signals from iocontrol
|
||||
# should separate command and status for production versions
|
||||
# and run these through CL to test conditions
|
||||
net flood iocontrol.0.coolant-flood parport.0.pin-08-out
|
||||
net mist iocontrol.0.coolant-mist parport.0.pin-09-out
|
||||
|
||||
# spindle signals
|
||||
# spindle status has not been resolved
|
||||
# a simple loop through is set here
|
||||
net spindle-forward spindle.0.forward parport.0.pin-16-out
|
||||
net spindle-reverse spindle.0.reverse parport.0.pin-17-out
|
||||
|
||||
# we will let loopbacks handle tool prepare and change commands
|
||||
# though we could index an external changer
|
||||
# create connections for tool loading loopback
|
||||
net tool-prep-loop iocontrol.0.tool-prepare iocontrol.0.tool-prepared
|
||||
net tool-change-loop iocontrol.0.tool-change iocontrol.0.tool-changed
|
||||
|
||||
# create a limit switch signal
|
||||
# read limit conditions from external normally open switches in parallel
|
||||
# this configuration allows the control to run but still test limit
|
||||
# for real use a normally closed series loop and reverse parport pin polarity
|
||||
# add all limits to a single parport pin
|
||||
# connect this signal to pin 10 on the parport
|
||||
net limit-reached parport.0.pin-10-in-not
|
||||
# connect this signal to all limit signals of relevant axes
|
||||
net limit-reached joint.0.neg-lim-sw-in
|
||||
net limit-reached joint.0.pos-lim-sw-in
|
||||
net limit-reached joint.1.neg-lim-sw-in
|
||||
net limit-reached joint.1.pos-lim-sw-in
|
||||
net limit-reached joint.2.neg-lim-sw-in
|
||||
#linksp limit-reached joint.2.pos-lim-sw-in
|
||||
|
||||
@@ -0,0 +1,181 @@
|
||||
# EMC controller parameters for generic controller. Make these what you need
|
||||
# for your system.
|
||||
# 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 of this INI file
|
||||
VERSION = 1.1
|
||||
# Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-DEMO-STEP-CL
|
||||
# Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
# DEBUG = 0x00000001
|
||||
# DEBUG = 0x00000007
|
||||
DEBUG = 0
|
||||
# Sections for display options ------------------------------------------------
|
||||
|
||||
[DISPLAY]
|
||||
# Name of display program, e.g., xlinuxcnc
|
||||
# DISPLAY = axis
|
||||
DISPLAY = tklinuxcnc
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
CYCLE_TIME = 0.200
|
||||
# Path to help file
|
||||
HELP_FILE = tklinuxcnc.txt
|
||||
# Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
# Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
# Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 1.2
|
||||
# Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
# Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 2
|
||||
# Task controller section -----------------------------------------------------
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
# File containing interpreter variables
|
||||
PARAMETER_FILE = demo_step_cl.var
|
||||
# Motion control section ------------------------------------------------------
|
||||
|
||||
[EMCMOT]
|
||||
EMCMOT = motmod
|
||||
# Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
# Base task period, in nanoseconds - this is the fastest thread in the machine
|
||||
BASE_PERIOD = 50000
|
||||
# Servo task period, in nanoseconds - will be rounded to an integer multiple
|
||||
# of BASE_PERIOD
|
||||
SERVO_PERIOD = 1000000
|
||||
# Hardware Abstraction Layer section --------------------------------------------------
|
||||
|
||||
[TASK]
|
||||
# Name of task controller program, e.g., milltask
|
||||
TASK = milltask
|
||||
# Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.010
|
||||
# Part program interpreter section --------------------------------------------
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# list of hal config files to run through halcmd
|
||||
# files are executed in the order in which they appear
|
||||
HALFILE = core_stepper.hal
|
||||
HALFILE = demo_step_cl.hal
|
||||
#HALFILE = xylotex_pinout.hal
|
||||
# HALFILE = standard_pinout.hal
|
||||
# HALFILE = simulated_limits.hal
|
||||
# list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
# Trajectory planner section --------------------------------------------------
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
# COORDINATES = X Y Z A B C
|
||||
COORDINATES = X Y Z
|
||||
HOME = 0 0 0
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 0.0167
|
||||
MAX_LINEAR_VELOCITY = 1.2
|
||||
DEFAULT_LINEAR_ACCELERATION = 15.0
|
||||
MAX_LINEAR_ACCELERATION = 20.0
|
||||
# Axes sections ---------------------------------------------------------------
|
||||
# First axis
|
||||
|
||||
[EMCIO]
|
||||
# tool table file
|
||||
TOOL_TABLE = demo_step_cl.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
# Second axis
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
# Third axis
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -2.0
|
||||
MAX_LIMIT = 4.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -2.0
|
||||
MAX_LIMIT = 4.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
# section for main IO controller parameters -----------------------------------
|
||||
@@ -0,0 +1,4 @@
|
||||
T1 P1 D0.125000 Z+0.511000 ;1/8 end mill
|
||||
T2 P2 D0.062500 Z+0.100000 ;1/16 end mill
|
||||
T3 P3 D0.201000 Z+1.273000 ;#7 tap drill
|
||||
T99999 P99999 Z+0.100000 ;big tool number
|
||||
6
configs/by_interface/parport/etch-servo/README
Normal file
6
configs/by_interface/parport/etch-servo/README
Normal file
@@ -0,0 +1,6 @@
|
||||
Etch-servo drives two servo motors using a simple parallel-port-attached circuit. 'pwmgen' produces an enable waveform to turn the servo motors at a variable speed, and 'encoder' reads TTL-level quadrature inputs to close the loop.
|
||||
|
||||
The circuit uses an L298 dual full-bridge driver to control two servo motors.
|
||||
|
||||
More information on the circuit is available:
|
||||
http://emergent.unpy.net/projects/01142347802
|
||||
116
configs/by_interface/parport/etch-servo/etch.hal
Normal file
116
configs/by_interface/parport/etch-servo/etch.hal
Normal file
@@ -0,0 +1,116 @@
|
||||
# load realtime modules
|
||||
# kinematics
|
||||
loadrt [KINS]KINEMATICS
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
|
||||
loadrt hal_parport cfg="0x378"
|
||||
loadrt encoder num_chan=2
|
||||
loadrt pid num_chan=2
|
||||
loadrt pwmgen output_type=1,1
|
||||
loadrt ddt count=4
|
||||
|
||||
# define the order of execution for RT code
|
||||
addf parport.0.read base-thread
|
||||
addf encoder.update-counters base-thread
|
||||
addf pwmgen.make-pulses base-thread
|
||||
addf parport.0.write base-thread
|
||||
|
||||
addf encoder.capture-position servo-thread
|
||||
addf motion-command-handler servo-thread
|
||||
addf motion-controller servo-thread
|
||||
addf pid.0.do-pid-calcs servo-thread
|
||||
addf pid.1.do-pid-calcs servo-thread
|
||||
addf pwmgen.update servo-thread
|
||||
addf ddt.0 servo-thread
|
||||
addf ddt.1 servo-thread
|
||||
addf ddt.2 servo-thread
|
||||
addf ddt.3 servo-thread
|
||||
|
||||
# hook stuff together
|
||||
|
||||
setp encoder.0.position-scale [JOINT_0]INPUT_SCALE
|
||||
setp encoder.1.position-scale [JOINT_1]INPUT_SCALE
|
||||
|
||||
net enc0A encoder.0.phase-A <= parport.0.pin-10-in
|
||||
net enc0B encoder.0.phase-B <= parport.0.pin-11-in
|
||||
net enc1A encoder.1.phase-A <= parport.0.pin-12-in
|
||||
net enc1B encoder.1.phase-B <= parport.0.pin-13-in
|
||||
|
||||
net Xpos-fb <= encoder.0.position
|
||||
net Ypos-fb <= encoder.1.position
|
||||
|
||||
|
||||
net Xpos-fb => pid.0.feedback
|
||||
net Ypos-fb => pid.1.feedback
|
||||
net Xpos-fb => joint.0.motor-pos-fb
|
||||
net Ypos-fb => joint.1.motor-pos-fb
|
||||
|
||||
net Xvel-cmd <= pid.0.output
|
||||
net Yvel-cmd <= pid.1.output
|
||||
|
||||
net Xvel-cmd => pwmgen.0.value
|
||||
net Yvel-cmd => pwmgen.1.value
|
||||
|
||||
net Xpwm pwmgen.0.pwm
|
||||
net Ypwm pwmgen.1.pwm
|
||||
|
||||
net Xdir <= pwmgen.0.dir
|
||||
net Ydir <= pwmgen.1.dir
|
||||
|
||||
net Xdir => parport.0.pin-02-out
|
||||
net Xdir => parport.0.pin-04-out
|
||||
setp parport.0.pin-04-out-invert TRUE
|
||||
net Xpwm => parport.0.pin-03-out
|
||||
|
||||
net Ydir => parport.0.pin-05-out
|
||||
net Ydir => parport.0.pin-07-out
|
||||
setp parport.0.pin-07-out-invert TRUE
|
||||
net Ypwm => parport.0.pin-06-out
|
||||
|
||||
setp pid.0.maxoutput 1.0
|
||||
setp pid.1.maxoutput 1.0
|
||||
|
||||
# the values below come from the ini
|
||||
setp pid.0.Pgain [JOINT_0]P
|
||||
setp pid.0.Igain [JOINT_0]I
|
||||
setp pid.0.Dgain [JOINT_0]D
|
||||
setp pid.0.bias [JOINT_0]BIAS
|
||||
setp pid.0.FF0 [JOINT_0]FF0
|
||||
setp pid.0.FF1 [JOINT_0]FF1
|
||||
setp pid.0.FF2 [JOINT_0]FF2
|
||||
# deadband should be just over 1 count
|
||||
setp pid.0.deadband [JOINT_0]DEADBAND
|
||||
|
||||
setp pid.1.Pgain [JOINT_1]P
|
||||
setp pid.1.Igain [JOINT_1]I
|
||||
setp pid.1.Dgain [JOINT_1]D
|
||||
setp pid.1.bias [JOINT_1]BIAS
|
||||
setp pid.1.FF0 [JOINT_1]FF0
|
||||
setp pid.1.FF1 [JOINT_1]FF1
|
||||
setp pid.1.FF2 [JOINT_1]FF2
|
||||
# deadband should be just over 1 count
|
||||
setp pid.1.deadband [JOINT_1]DEADBAND
|
||||
|
||||
net Xpos-cmd <= joint.0.motor-pos-cmd
|
||||
net Ypos-cmd <= joint.1.motor-pos-cmd
|
||||
net Xpos-cmd => pid.0.command
|
||||
net Ypos-cmd => pid.1.command
|
||||
net Xenable <= joint.0.amp-enable-out
|
||||
net Yenable <= joint.1.amp-enable-out
|
||||
net Xenable => pid.0.enable
|
||||
net Xenable => pwmgen.0.enable
|
||||
net Yenable => pid.1.enable
|
||||
net Yenable => pwmgen.1.enable
|
||||
|
||||
net estop-loop iocontrol.0.user-enable-out iocontrol.0.emc-enable-in
|
||||
|
||||
net Xpos-cmd => ddt.0.in
|
||||
net Xvel <= ddt.0.out
|
||||
net Xvel => ddt.1.in
|
||||
net Xacc <= ddt.1.out
|
||||
net Ypos-cmd => ddt.2.in
|
||||
net Yvel <= ddt.2.out
|
||||
net Yvel => ddt.3.in
|
||||
net Yacc <= ddt.3.out
|
||||
|
||||
net tool-prep-loop iocontrol.0.tool-prepare iocontrol.0.tool-prepared
|
||||
net tool-change-loop iocontrol.0.tool-change iocontrol.0.tool-changed
|
||||
191
configs/by_interface/parport/etch-servo/etch.ini
Normal file
191
configs/by_interface/parport/etch-servo/etch.ini
Normal file
@@ -0,0 +1,191 @@
|
||||
# EMC controller parameters for generic controller. Make these what you need
|
||||
# for your system.
|
||||
# General note: Comments can either be preceded with a # or ; - either is
|
||||
# acceptable, although # is in keeping with most linux config files.
|
||||
# Settings with a + at the front of the comment are likely needed to get
|
||||
# changed by the user.
|
||||
# Settings with a - at the front are highly unneeded to be changed
|
||||
###############################################################################
|
||||
# General section
|
||||
###############################################################################
|
||||
|
||||
[EMC]
|
||||
#- Version of this INI file
|
||||
VERSION = 1.1
|
||||
#+ Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-ETCH-SERVO
|
||||
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
DEBUG = 0
|
||||
# DEBUG = 0x00000007
|
||||
# DEBUG = 0x7FFFFFFF
|
||||
###############################################################################
|
||||
# Sections for display options
|
||||
###############################################################################
|
||||
|
||||
[DISPLAY]
|
||||
#+ Name of display program, e.g., axis
|
||||
DISPLAY = axis
|
||||
# DISPLAY = tklinuxcnc
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
CYCLE_TIME = 0.200
|
||||
#- Path to help file
|
||||
HELP_FILE = doc/help.txt
|
||||
#- Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
#- Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
#+ Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 10
|
||||
#- Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
#- Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
# Editor to be used with Axis
|
||||
#EDITOR = geany
|
||||
# Turn off splash screen as it won't load without a Z axis
|
||||
OPEN_FILE = ""
|
||||
###############################################################################
|
||||
# Task controller section
|
||||
###############################################################################
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
#- File containing interpreter variables
|
||||
PARAMETER_FILE = etch.var
|
||||
###############################################################################
|
||||
# Motion control section
|
||||
###############################################################################
|
||||
|
||||
[EMCMOT]
|
||||
#- Name of the motion controller to use (only one exists for nontrivkins)
|
||||
EMCMOT = motmod
|
||||
#- Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
#+ Base task period, in nanosecs - this is the fastest thread in the machine
|
||||
BASE_PERIOD = 20000
|
||||
#- Servo task period, in nanosecs - will be rounded to an int multiple of BASE_PERIOD
|
||||
SERVO_PERIOD = 1000000
|
||||
###############################################################################
|
||||
# Hardware Abstraction Layer section
|
||||
###############################################################################
|
||||
|
||||
[TASK]
|
||||
# Name of task controller program, e.g., milltask
|
||||
TASK = milltask
|
||||
#- Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.010
|
||||
###############################################################################
|
||||
# Part program interpreter section
|
||||
###############################################################################
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# list of hal config files to run through halcmd
|
||||
#+ files are executed in the order in which they appear
|
||||
HALFILE = etch.hal
|
||||
#- list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
###############################################################################
|
||||
# Trajectory planner section
|
||||
###############################################################################
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
#+ machine specific settings
|
||||
# COORDINATES = X Y Z A B C
|
||||
COORDINATES = X Y
|
||||
HOME = 0 0
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 1
|
||||
MAX_LINEAR_VELOCITY = 30
|
||||
DEFAULT_LINEAR_ACCELERATION = 15.0
|
||||
MAX_LINEAR_ACCELERATION = 20.0
|
||||
###############################################################################
|
||||
# Axes sections
|
||||
###############################################################################
|
||||
#+ First axis
|
||||
|
||||
[EMCIO]
|
||||
#- tool table file
|
||||
TOOL_TABLE = etch.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 2
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = 0.0
|
||||
MAX_LIMIT = 6.5
|
||||
MAX_VELOCITY = 4
|
||||
MAX_ACCELERATION = 50
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 4
|
||||
MAX_ACCELERATION = 50
|
||||
BACKLASH = 0.000
|
||||
INPUT_SCALE = 1700
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = 0.0
|
||||
MAX_LIMIT = 6.5
|
||||
FERROR = 0.2
|
||||
MIN_FERROR = 0.10
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
P = 150
|
||||
I = 100
|
||||
D = 0.1
|
||||
BIAS = 0.0
|
||||
FF0 = 0
|
||||
FF1 = 1
|
||||
FF2 = 0.0
|
||||
DEADBAND=.002
|
||||
#+ Second axis
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = 0
|
||||
MAX_LIMIT = 4.5
|
||||
MAX_VELOCITY = 3
|
||||
MAX_ACCELERATION = 50
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 3
|
||||
MAX_ACCELERATION = 50
|
||||
BACKLASH = 0.000
|
||||
INPUT_SCALE = 1700
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = 0
|
||||
MAX_LIMIT = 4.5
|
||||
FERROR = 0.200
|
||||
MIN_FERROR = 0.100
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
P = 150
|
||||
I = 100
|
||||
D = 0.1
|
||||
BIAS = 0.0
|
||||
FF0 = 0
|
||||
FF1 = 1
|
||||
FF2 = 0.0
|
||||
DEADBAND=.002
|
||||
###############################################################################
|
||||
# section for main IO controller parameters
|
||||
###############################################################################
|
||||
4
configs/by_interface/parport/etch-servo/etch.tbl
Normal file
4
configs/by_interface/parport/etch-servo/etch.tbl
Normal file
@@ -0,0 +1,4 @@
|
||||
T1 P1 D0.125000 Z+0.511000 ;1/8 end mill
|
||||
T2 P2 D0.062500 Z+0.100000 ;1/16 end mill
|
||||
T3 P3 D0.201000 Z+1.273000 ;#7 tap drill
|
||||
T99999 P99999 Z+0.100000 ;big tool number
|
||||
10
configs/by_interface/parport/gantry/README
Normal file
10
configs/by_interface/parport/gantry/README
Normal file
@@ -0,0 +1,10 @@
|
||||
Stepper Gantry basic configurations.
|
||||
|
||||
It is very important for gantry machines to set initial home switch positions before first homing so they reach home switches at a very similar time. To remove any skewing on the gantry adjust the home offset of one joint. After homing the configuration will switch from joint mode to world mode.
|
||||
|
||||
gantry_joints.ini uses the same .hal file but uses kinstype=BOTH which requires independently homing each joint axis.
|
||||
|
||||
gantry.ini implements a dual Y motor gantry. This is the configuration to use after you verify the directions and speeds of the individual joints using gantry_joints.ini.
|
||||
|
||||
These configs use switches for min-home on the X,Y,Y2 axis and max-home for Z. Pay attention to the parallel input pin assignment for the switches.
|
||||
|
||||
107
configs/by_interface/parport/gantry/gantry.hal
Normal file
107
configs/by_interface/parport/gantry/gantry.hal
Normal file
@@ -0,0 +1,107 @@
|
||||
# Generated by stepconf 1.1 at Mon Feb 28 16:28:49 2022
|
||||
# If you make changes to this file, they will be
|
||||
# overwritten when you run stepconf again
|
||||
loadrt [KINS]KINEMATICS
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
|
||||
loadrt hal_parport cfg="0 out"
|
||||
setp parport.0.reset-time 5000
|
||||
loadrt stepgen step_type=0,0,0,0
|
||||
|
||||
addf parport.0.read base-thread
|
||||
addf stepgen.make-pulses base-thread
|
||||
addf parport.0.write base-thread
|
||||
addf parport.0.reset base-thread
|
||||
|
||||
addf stepgen.capture-position servo-thread
|
||||
addf motion-command-handler servo-thread
|
||||
addf motion-controller servo-thread
|
||||
addf stepgen.update-freq servo-thread
|
||||
net spindle-cmd-rpm <= spindle.0.speed-out
|
||||
net spindle-cmd-rpm-abs <= spindle.0.speed-out-abs
|
||||
net spindle-cmd-rps <= spindle.0.speed-out-rps
|
||||
net spindle-cmd-rps-abs <= spindle.0.speed-out-rps-abs
|
||||
net spindle-at-speed => spindle.0.at-speed
|
||||
|
||||
net xstep => parport.0.pin-02-out
|
||||
setp parport.0.pin-02-out-reset 1
|
||||
net xdir => parport.0.pin-03-out
|
||||
net ystep => parport.0.pin-04-out
|
||||
setp parport.0.pin-04-out-reset 1
|
||||
net ydir => parport.0.pin-05-out
|
||||
net zstep => parport.0.pin-06-out
|
||||
setp parport.0.pin-06-out-reset 1
|
||||
net zdir => parport.0.pin-07-out
|
||||
net y2step => parport.0.pin-08-out
|
||||
setp parport.0.pin-08-out-reset 1
|
||||
net y2dir => parport.0.pin-09-out
|
||||
|
||||
#
|
||||
# Very likely that you will have wired your limit/home switches differently.
|
||||
#
|
||||
net min-home-y2 <= parport.0.pin-10-in
|
||||
net max-home-z <= parport.0.pin-11-in
|
||||
net min-home-y <= parport.0.pin-12-in
|
||||
net min-home-x <= parport.0.pin-13-in
|
||||
|
||||
setp stepgen.0.position-scale [JOINT_0]SCALE
|
||||
setp stepgen.0.steplen 1
|
||||
setp stepgen.0.stepspace 0
|
||||
setp stepgen.0.dirhold 40000
|
||||
setp stepgen.0.dirsetup 40000
|
||||
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
|
||||
net xpos-cmd joint.0.motor-pos-cmd => stepgen.0.position-cmd
|
||||
net xpos-fb stepgen.0.position-fb => joint.0.motor-pos-fb
|
||||
net xstep <= stepgen.0.step
|
||||
net xdir <= stepgen.0.dir
|
||||
net xenable joint.0.amp-enable-out => stepgen.0.enable
|
||||
net min-home-x => joint.0.home-sw-in
|
||||
net min-home-x => joint.0.neg-lim-sw-in
|
||||
|
||||
setp stepgen.1.position-scale [JOINT_1]SCALE
|
||||
setp stepgen.1.steplen 1
|
||||
setp stepgen.1.stepspace 0
|
||||
setp stepgen.1.dirhold 40000
|
||||
setp stepgen.1.dirsetup 40000
|
||||
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
|
||||
net ypos-cmd joint.1.motor-pos-cmd => stepgen.1.position-cmd
|
||||
net ypos-fb stepgen.1.position-fb => joint.1.motor-pos-fb
|
||||
net ystep <= stepgen.1.step
|
||||
net ydir <= stepgen.1.dir
|
||||
net yenable joint.1.amp-enable-out => stepgen.1.enable
|
||||
net min-home-y => joint.1.home-sw-in
|
||||
net min-home-y => joint.1.neg-lim-sw-in
|
||||
|
||||
setp stepgen.2.position-scale [JOINT_2]SCALE
|
||||
setp stepgen.2.steplen 1
|
||||
setp stepgen.2.stepspace 0
|
||||
setp stepgen.2.dirhold 40000
|
||||
setp stepgen.2.dirsetup 40000
|
||||
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
|
||||
net zpos-cmd joint.2.motor-pos-cmd => stepgen.2.position-cmd
|
||||
net zpos-fb stepgen.2.position-fb => joint.2.motor-pos-fb
|
||||
net zstep <= stepgen.2.step
|
||||
net zdir <= stepgen.2.dir
|
||||
net zenable joint.2.amp-enable-out => stepgen.2.enable
|
||||
net max-home-z => joint.2.home-sw-in
|
||||
net max-home-z => joint.2.pos-lim-sw-in
|
||||
|
||||
setp stepgen.3.position-scale [JOINT_3]SCALE
|
||||
setp stepgen.3.steplen 1
|
||||
setp stepgen.3.stepspace 0
|
||||
setp stepgen.3.dirhold 40000
|
||||
setp stepgen.3.dirsetup 40000
|
||||
setp stepgen.3.maxaccel [JOINT_3]STEPGEN_MAXACCEL
|
||||
net y2pos-cmd joint.3.motor-pos-cmd => stepgen.3.position-cmd
|
||||
net y2pos-fb stepgen.3.position-fb => joint.3.motor-pos-fb
|
||||
net y2step <= stepgen.3.step
|
||||
net y2dir <= stepgen.3.dir
|
||||
net y2enable joint.3.amp-enable-out => stepgen.3.enable
|
||||
net min-home-y2 => joint.3.home-sw-in
|
||||
net min-home-y2 => joint.3.neg-lim-sw-in
|
||||
|
||||
net estop-out <= iocontrol.0.user-enable-out
|
||||
net estop-out => iocontrol.0.emc-enable-in
|
||||
|
||||
net tool-number <= iocontrol.0.tool-prep-number
|
||||
net tool-change-loopback iocontrol.0.tool-change => iocontrol.0.tool-changed
|
||||
net tool-prepare-loopback iocontrol.0.tool-prepare => iocontrol.0.tool-prepared
|
||||
161
configs/by_interface/parport/gantry/gantry.ini
Normal file
161
configs/by_interface/parport/gantry/gantry.ini
Normal file
@@ -0,0 +1,161 @@
|
||||
# This configuration was created using Stepconf wizarda as a XYZA configuration.
|
||||
# Modified to a XYZY gantry.
|
||||
|
||||
[EMC]
|
||||
MACHINE = gantry
|
||||
DEBUG = 0
|
||||
VERSION = 1.1
|
||||
|
||||
[DISPLAY]
|
||||
DISPLAY = axis
|
||||
EDITOR = geany
|
||||
POSITION_OFFSET = RELATIVE
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
ARCDIVISION = 64
|
||||
GRIDS = 10mm 20mm 50mm 100mm 1in 2in 5in 10in
|
||||
MAX_FEED_OVERRIDE = 1.5
|
||||
MIN_SPINDLE_OVERRIDE = 0.5
|
||||
MAX_SPINDLE_OVERRIDE = 1.2
|
||||
DEFAULT_LINEAR_VELOCITY = 15.00
|
||||
MIN_LINEAR_VELOCITY = 0
|
||||
MAX_LINEAR_VELOCITY = 30.00
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
PROGRAM_PREFIX = ../../nc_files
|
||||
INCREMENTS = 5mm 1mm .5mm .1mm .05mm .01mm .005mm
|
||||
|
||||
[KINS]
|
||||
JOINTS = 4
|
||||
KINEMATICS = trivkins coordinates=XYZY
|
||||
|
||||
[FILTER]
|
||||
PROGRAM_EXTENSION = .png,.gif,.jpg Greyscale Depth Image
|
||||
PROGRAM_EXTENSION = .py Python Script
|
||||
PROGRAM_EXTENSION = .nc,.tap G-Code File
|
||||
png = image-to-gcode
|
||||
gif = image-to-gcode
|
||||
jpg = image-to-gcode
|
||||
py = python3
|
||||
|
||||
[TASK]
|
||||
TASK = milltask
|
||||
CYCLE_TIME = 0.010
|
||||
|
||||
[RS274NGC]
|
||||
PARAMETER_FILE = linuxcnc.var
|
||||
|
||||
[EMCMOT]
|
||||
EMCMOT = motmod
|
||||
COMM_TIMEOUT = 1.0
|
||||
BASE_PERIOD = 30000
|
||||
SERVO_PERIOD = 1000000
|
||||
|
||||
[HAL]
|
||||
HALUI = halui
|
||||
HALFILE = gantry.hal
|
||||
#HALFILE = custom.hal
|
||||
#POSTGUI_HALFILE = postgui_call_list.hal
|
||||
|
||||
[HALUI]
|
||||
# add halui MDI commands here (max 64)
|
||||
|
||||
[TRAJ]
|
||||
COORDINATES = X Y Z Y
|
||||
LINEAR_UNITS = mm
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 15.00
|
||||
MAX_LINEAR_VELOCITY = 30.00
|
||||
|
||||
[EMCIO]
|
||||
TOOL_TABLE = tool.tbl
|
||||
|
||||
[AXIS_X]
|
||||
MAX_VELOCITY = 20.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
MIN_LIMIT = -0.001
|
||||
MAX_LIMIT = 700.0
|
||||
|
||||
[AXIS_Y]
|
||||
MAX_VELOCITY = 10.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
MIN_LIMIT = -1.0
|
||||
MAX_LIMIT = 1000.0
|
||||
|
||||
[AXIS_Z]
|
||||
MAX_VELOCITY = 20.0
|
||||
MAX_ACCELERATION = 150.0
|
||||
MIN_LIMIT = -0.0
|
||||
MAX_LIMIT = 160.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
MIN_LIMIT = -3
|
||||
MAX_LIMIT = 700.0
|
||||
MAX_VELOCITY = 20.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
STEPGEN_MAXACCEL = 937.5
|
||||
SCALE = -400.0
|
||||
FERROR = 1
|
||||
MIN_FERROR = .25
|
||||
HOME = 0.0
|
||||
HOME_OFFSET = -1.0
|
||||
HOME_SEARCH_VEL = -15.0
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_FINAL_VEL = 15.0
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 1
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
MIN_LIMIT = -1.0
|
||||
MAX_LIMIT = 1000.0
|
||||
MAX_VELOCITY = 10.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
STEPGEN_MAXACCEL = 937.5
|
||||
SCALE = -787.4015
|
||||
FERROR = 1
|
||||
MIN_FERROR = .25
|
||||
HOME = 0.0
|
||||
HOME_OFFSET = -1.0
|
||||
HOME_SEARCH_VEL = -10.00000
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_FINAL_VEL = 8.0
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = -2
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
MAX_VELOCITY = 20.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
STEPGEN_MAXACCEL = 937.5
|
||||
SCALE = 400.0
|
||||
FERROR = 1
|
||||
MIN_FERROR = .25
|
||||
MIN_LIMIT = -0.0
|
||||
MAX_LIMIT = 160.0
|
||||
HOME = 155.0
|
||||
HOME_OFFSET = 160.0
|
||||
HOME_SEARCH_VEL = 15.0
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_FINAL_VEL = 15.0
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 0
|
||||
|
||||
[JOINT_3]
|
||||
TYPE = LINEAR
|
||||
MIN_LIMIT = -1.0
|
||||
MAX_LIMIT = 1000.0
|
||||
MAX_VELOCITY = 10.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
STEPGEN_MAXACCEL = 937.5
|
||||
SCALE = -787.4015
|
||||
FERROR = 1
|
||||
MIN_FERROR = .25
|
||||
HOME = 0.0
|
||||
HOME_OFFSET = -1.0
|
||||
HOME_SEARCH_VEL = -10.00000
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_FINAL_VEL = 8.0
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = -2
|
||||
|
||||
159
configs/by_interface/parport/gantry/gantry_joints.ini
Normal file
159
configs/by_interface/parport/gantry/gantry_joints.ini
Normal file
@@ -0,0 +1,159 @@
|
||||
# This configuration was created using Stepconf wizarda as a XYZA configuration.
|
||||
# Modified to a XYZY gantry.
|
||||
|
||||
[EMC]
|
||||
MACHINE = gantry_joints
|
||||
DEBUG = 0
|
||||
VERSION = 1.1
|
||||
|
||||
[DISPLAY]
|
||||
DISPLAY = axis
|
||||
EDITOR = geany
|
||||
POSITION_OFFSET = RELATIVE
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
ARCDIVISION = 64
|
||||
GRIDS = 10mm 20mm 50mm 100mm 1in 2in 5in 10in
|
||||
MAX_FEED_OVERRIDE = 1.5
|
||||
MIN_SPINDLE_OVERRIDE = 0.5
|
||||
MAX_SPINDLE_OVERRIDE = 1.2
|
||||
DEFAULT_LINEAR_VELOCITY = 15.00
|
||||
MIN_LINEAR_VELOCITY = 0
|
||||
MAX_LINEAR_VELOCITY = 30.00
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
PROGRAM_PREFIX = /home/cncbox/linuxcnc/nc_files
|
||||
INCREMENTS = 5mm 1mm .5mm .1mm .05mm .01mm .005mm
|
||||
|
||||
[KINS]
|
||||
JOINTS = 4
|
||||
KINEMATICS = trivkins coordinates=XYZY kinstype=BOTH
|
||||
|
||||
[FILTER]
|
||||
PROGRAM_EXTENSION = .png,.gif,.jpg Greyscale Depth Image
|
||||
PROGRAM_EXTENSION = .py Python Script
|
||||
PROGRAM_EXTENSION = .nc,.tap G-Code File
|
||||
png = image-to-gcode
|
||||
gif = image-to-gcode
|
||||
jpg = image-to-gcode
|
||||
py = python3
|
||||
|
||||
[TASK]
|
||||
TASK = milltask
|
||||
CYCLE_TIME = 0.010
|
||||
|
||||
[RS274NGC]
|
||||
PARAMETER_FILE = linuxcnc.var
|
||||
|
||||
[EMCMOT]
|
||||
EMCMOT = motmod
|
||||
COMM_TIMEOUT = 1.0
|
||||
BASE_PERIOD = 30000
|
||||
SERVO_PERIOD = 1000000
|
||||
|
||||
[HAL]
|
||||
HALUI = halui
|
||||
HALFILE = gantry.hal
|
||||
|
||||
[HALUI]
|
||||
# add halui MDI commands here (max 64)
|
||||
|
||||
[TRAJ]
|
||||
COORDINATES = X Y Z Y
|
||||
LINEAR_UNITS = mm
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 15.00
|
||||
MAX_LINEAR_VELOCITY = 30.00
|
||||
|
||||
[EMCIO]
|
||||
TOOL_TABLE = tool.tbl
|
||||
|
||||
[AXIS_X]
|
||||
MAX_VELOCITY = 20.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
MIN_LIMIT = -0.001
|
||||
MAX_LIMIT = 700.0
|
||||
|
||||
[AXIS_Y]
|
||||
MAX_VELOCITY = 10.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
MIN_LIMIT = -1.0
|
||||
MAX_LIMIT = 1000.0
|
||||
|
||||
[AXIS_Z]
|
||||
MAX_VELOCITY = 20.0
|
||||
MAX_ACCELERATION = 150.0
|
||||
MIN_LIMIT = -0.0
|
||||
MAX_LIMIT = 160.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
MIN_LIMIT = -3
|
||||
MAX_LIMIT = 700.0
|
||||
MAX_VELOCITY = 20.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
STEPGEN_MAXACCEL = 937.5
|
||||
SCALE = -400.0
|
||||
FERROR = 1
|
||||
MIN_FERROR = .25
|
||||
HOME = 0.0
|
||||
HOME_OFFSET = -1.0
|
||||
HOME_SEARCH_VEL = -15.0
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_FINAL_VEL = 15.0
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
#HOME_SEQUENCE = 1
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
MIN_LIMIT = -1.0
|
||||
MAX_LIMIT = 1000.0
|
||||
MAX_VELOCITY = 10.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
STEPGEN_MAXACCEL = 937.5
|
||||
SCALE = -787.4015
|
||||
FERROR = 1
|
||||
MIN_FERROR = .25
|
||||
HOME = 0.0
|
||||
HOME_OFFSET = -1.0
|
||||
HOME_SEARCH_VEL = -10.00000
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_FINAL_VEL = 8.0
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
#HOME_SEQUENCE = -2
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
MAX_VELOCITY = 20.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
STEPGEN_MAXACCEL = 937.5
|
||||
SCALE = 400.0
|
||||
FERROR = 1
|
||||
MIN_FERROR = .25
|
||||
MIN_LIMIT = -0.0
|
||||
MAX_LIMIT = 160.0
|
||||
HOME = 155.0
|
||||
HOME_OFFSET = 160.0
|
||||
HOME_SEARCH_VEL = 15.0
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_FINAL_VEL = 15.0
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
#HOME_SEQUENCE = 0
|
||||
|
||||
[JOINT_3]
|
||||
TYPE = LINEAR
|
||||
MIN_LIMIT = -1.0
|
||||
MAX_LIMIT = 1000.0
|
||||
MAX_VELOCITY = 10.0
|
||||
MAX_ACCELERATION = 750.0
|
||||
STEPGEN_MAXACCEL = 937.5
|
||||
SCALE = -787.4015
|
||||
FERROR = 1
|
||||
MIN_FERROR = .25
|
||||
HOME = 0.0
|
||||
HOME_OFFSET = -1.0
|
||||
HOME_SEARCH_VEL = -10.00000
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_FINAL_VEL = 8.0
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
#HOME_SEQUENCE = -2
|
||||
|
||||
3
configs/by_interface/parport/gantry/postgui.hal
Normal file
3
configs/by_interface/parport/gantry/postgui.hal
Normal file
@@ -0,0 +1,3 @@
|
||||
# Include your customized HAL commands here
|
||||
# The commands in this file are run after the AXIS GUI (including PyVCP panel) starts
|
||||
|
||||
@@ -0,0 +1,82 @@
|
||||
# Generated by stepconf at Wed Sep 26 07:50:40 2012
|
||||
# If you make changes to this file, they will be
|
||||
# overwritten when you run stepconf again
|
||||
loadrt [KINS]KINEMATICS
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
|
||||
loadrt hal_parport cfg="0x378 out "
|
||||
setp parport.0.reset-time 1000
|
||||
loadrt stepgen step_type=0,0,0
|
||||
loadrt charge_pump
|
||||
net estop-out charge-pump.enable iocontrol.0.user-enable-out
|
||||
net charge-pump <= charge-pump.out
|
||||
|
||||
addf parport.0.read base-thread
|
||||
addf stepgen.make-pulses base-thread
|
||||
addf charge-pump base-thread
|
||||
addf parport.0.write base-thread
|
||||
addf parport.0.reset base-thread
|
||||
|
||||
addf stepgen.capture-position servo-thread
|
||||
addf motion-command-handler servo-thread
|
||||
addf motion-controller servo-thread
|
||||
addf stepgen.update-freq servo-thread
|
||||
net spindle-cmd <= spindle.0.speed-out
|
||||
|
||||
net xstep => parport.0.pin-02-out
|
||||
setp parport.0.pin-02-out-reset 1
|
||||
net xdir => parport.0.pin-03-out
|
||||
net ystep => parport.0.pin-04-out
|
||||
setp parport.0.pin-04-out-reset 1
|
||||
net ydir => parport.0.pin-05-out
|
||||
net zstep => parport.0.pin-06-out
|
||||
setp parport.0.pin-06-out-reset 1
|
||||
net zdir => parport.0.pin-07-out
|
||||
net charge-pump => parport.0.pin-16-out
|
||||
|
||||
|
||||
|
||||
|
||||
setp stepgen.0.position-scale [JOINT_0]SCALE
|
||||
setp stepgen.0.steplen 1
|
||||
setp stepgen.0.stepspace 0
|
||||
setp stepgen.0.dirhold 15200
|
||||
setp stepgen.0.dirsetup 15200
|
||||
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
|
||||
net xpos-cmd joint.0.motor-pos-cmd => stepgen.0.position-cmd
|
||||
net xpos-fb stepgen.0.position-fb => joint.0.motor-pos-fb
|
||||
net xstep <= stepgen.0.step
|
||||
net xdir <= stepgen.0.dir
|
||||
net xenable joint.0.amp-enable-out => stepgen.0.enable
|
||||
|
||||
setp stepgen.1.position-scale [JOINT_1]SCALE
|
||||
setp stepgen.1.steplen 1
|
||||
setp stepgen.1.stepspace 0
|
||||
setp stepgen.1.dirhold 15200
|
||||
setp stepgen.1.dirsetup 15200
|
||||
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
|
||||
net ypos-cmd joint.1.motor-pos-cmd => stepgen.1.position-cmd
|
||||
net ypos-fb stepgen.1.position-fb => joint.1.motor-pos-fb
|
||||
net ystep <= stepgen.1.step
|
||||
net ydir <= stepgen.1.dir
|
||||
net yenable joint.1.amp-enable-out => stepgen.1.enable
|
||||
|
||||
setp stepgen.2.position-scale [JOINT_2]SCALE
|
||||
setp stepgen.2.steplen 1
|
||||
setp stepgen.2.stepspace 0
|
||||
setp stepgen.2.dirhold 15200
|
||||
setp stepgen.2.dirsetup 15200
|
||||
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
|
||||
net zpos-cmd joint.2.motor-pos-cmd => stepgen.2.position-cmd
|
||||
net zpos-fb stepgen.2.position-fb => joint.2.motor-pos-fb
|
||||
net zstep <= stepgen.2.step
|
||||
net zdir <= stepgen.2.dir
|
||||
net zenable joint.2.amp-enable-out => stepgen.2.enable
|
||||
|
||||
net estop-out <= iocontrol.0.user-enable-out
|
||||
net estop-out => iocontrol.0.emc-enable-in
|
||||
|
||||
loadusr -W hal_manualtoolchange
|
||||
net tool-change iocontrol.0.tool-change => hal_manualtoolchange.change
|
||||
net tool-changed iocontrol.0.tool-changed <= hal_manualtoolchange.changed
|
||||
net tool-number iocontrol.0.tool-prep-number => hal_manualtoolchange.number
|
||||
net tool-prepare-loopback iocontrol.0.tool-prepare => iocontrol.0.tool-prepared
|
||||
120
configs/by_interface/parport/gecko/Gecko_540B3/Gecko_540B3.ini
Normal file
120
configs/by_interface/parport/gecko/Gecko_540B3/Gecko_540B3.ini
Normal file
@@ -0,0 +1,120 @@
|
||||
# Generated by stepconf at Wed Sep 26 07:50:40 2012
|
||||
# If you make changes to this file, they will be
|
||||
# overwritten when you run stepconf again
|
||||
|
||||
[EMC]
|
||||
# The version string for this INI file.
|
||||
VERSION = 1.1
|
||||
MACHINE = Gecko_540B3
|
||||
DEBUG = 0
|
||||
|
||||
[DISPLAY]
|
||||
DISPLAY = axis
|
||||
#EDITOR = geany
|
||||
POSITION_OFFSET = RELATIVE
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
MAX_FEED_OVERRIDE = 1.2
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
INCREMENTS = .1in .05in .01in .005in .001in .0005in .0001in
|
||||
|
||||
[FILTER]
|
||||
PROGRAM_EXTENSION = .png,.gif,.jpg Greyscale Depth Image
|
||||
PROGRAM_EXTENSION = .py Python Script
|
||||
png = image-to-gcode
|
||||
gif = image-to-gcode
|
||||
jpg = image-to-gcode
|
||||
py = python3
|
||||
|
||||
[RS274NGC]
|
||||
PARAMETER_FILE = linuxcnc.var
|
||||
|
||||
[EMCMOT]
|
||||
EMCMOT = motmod
|
||||
COMM_TIMEOUT = 1.0
|
||||
BASE_PERIOD = 23000
|
||||
SERVO_PERIOD = 1000000
|
||||
|
||||
[TASK]
|
||||
TASK = milltask
|
||||
CYCLE_TIME = 0.010
|
||||
|
||||
[HAL]
|
||||
HALFILE = Gecko_540B3.hal
|
||||
HALFILE = custom.hal
|
||||
POSTGUI_HALFILE = custom_postgui.hal
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
COORDINATES = X Y Z
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 0.10
|
||||
MAX_LINEAR_VELOCITY = 1.00
|
||||
|
||||
[EMCIO]
|
||||
TOOL_TABLE = tool.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 2.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 2.0
|
||||
STEPGEN_MAXACCEL = 2.5
|
||||
SCALE = 200000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
HOME_OFFSET = 0.0
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 1.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 1.0
|
||||
STEPGEN_MAXACCEL = 1.25
|
||||
SCALE = 200000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
HOME_OFFSET = 0.0
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 2.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 2.0
|
||||
STEPGEN_MAXACCEL = 2.5
|
||||
SCALE = 200000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
HOME_OFFSET = 0.0
|
||||
@@ -0,0 +1,140 @@
|
||||
<?xml version="1.0" ?>
|
||||
<stepconf>
|
||||
<property name="ahomepos" type="int" value="0"/>
|
||||
<property name="ahomesw" type="int" value="0"/>
|
||||
<property name="ahomevel" type="float" value="0.0"/>
|
||||
<property name="alatchdir" type="int" value="0"/>
|
||||
<property name="aleadscrew" type="int" value="100"/>
|
||||
<property name="amaxacc" type="int" value="2"/>
|
||||
<property name="amaxlim" type="int" value="100"/>
|
||||
<property name="amaxvel" type="int" value="0"/>
|
||||
<property name="amicrostep" type="int" value="1"/>
|
||||
<property name="aminlim" type="int" value="-100"/>
|
||||
<property name="apulleyden" type="int" value="1"/>
|
||||
<property name="apulleynum" type="int" value="1"/>
|
||||
<property name="ascale" type="int" value="0"/>
|
||||
<property name="asteprev" type="int" value="200"/>
|
||||
<property name="axes" type="int" value="0"/>
|
||||
<property name="classicladder" type="bool" value="False"/>
|
||||
<property name="createshortcut" type="bool" value="False"/>
|
||||
<property name="createsymlink" type="bool" value="False"/>
|
||||
<property name="customhal" type="int" value="1"/>
|
||||
<property name="digitsin" type="float" value="15.0"/>
|
||||
<property name="digitsout" type="float" value="15.0"/>
|
||||
<property name="dirhold" type="float" value="200.0"/>
|
||||
<property name="dirsetup" type="float" value="200.0"/>
|
||||
<property name="drivertype" type="string" value="gecko540"/>
|
||||
<property name="floatsin" type="float" value="10.0"/>
|
||||
<property name="floatsout" type="float" value="10.0"/>
|
||||
<property name="halui" type="bool" value="False"/>
|
||||
<property name="ioaddr" type="string" value="0x378"/>
|
||||
<property name="ioaddr2" type="string" value="Enter Address"/>
|
||||
<property name="ioaddr3" type="string" value="Enter Address"/>
|
||||
<property name="ladderconnect" type="bool" value="True"/>
|
||||
<property name="ladderhaltype" type="int" value="0"/>
|
||||
<property name="laddername" type="string" value="custom.clp"/>
|
||||
<property name="latency" type="float" value="15000.0"/>
|
||||
<property name="machinename" type="string" value="Gecko_540B3"/>
|
||||
<property name="manualtoolchange" type="bool" value="True"/>
|
||||
<property name="md5sums" type="eval" value="[('/home/john/linuxcnc/configs/Gecko_540B3/README', '41d8b103383504a95edf5bba747eab2f'), ('/home/john/linuxcnc/configs/Gecko_540B3/Gecko_540B3.ini', 'ea0cbc019a82cd2b5822d1d06d8df34f'), ('/home/john/linuxcnc/configs/Gecko_540B3/Gecko_540B3.hal', 'f8e0198425bda5dad47783f56cedb946')]"/>
|
||||
<property name="modbus" type="bool" value="False"/>
|
||||
<property name="number_pports" type="int" value="1"/>
|
||||
<property name="period" type="int" value="25000"/>
|
||||
<property name="pin1" type="string" value="unused-output"/>
|
||||
<property name="pin10" type="string" value="unused-input"/>
|
||||
<property name="pin10inv" type="bool" value="False"/>
|
||||
<property name="pin11" type="string" value="unused-input"/>
|
||||
<property name="pin11inv" type="bool" value="False"/>
|
||||
<property name="pin12" type="string" value="unused-input"/>
|
||||
<property name="pin12inv" type="bool" value="False"/>
|
||||
<property name="pin13" type="string" value="unused-input"/>
|
||||
<property name="pin13inv" type="bool" value="False"/>
|
||||
<property name="pin14" type="string" value="unused-output"/>
|
||||
<property name="pin14inv" type="bool" value="False"/>
|
||||
<property name="pin15" type="string" value="unused-input"/>
|
||||
<property name="pin15inv" type="bool" value="False"/>
|
||||
<property name="pin16" type="string" value="charge-pump"/>
|
||||
<property name="pin16inv" type="bool" value="False"/>
|
||||
<property name="pin17" type="string" value="unused-output"/>
|
||||
<property name="pin17inv" type="bool" value="False"/>
|
||||
<property name="pin1inv" type="bool" value="False"/>
|
||||
<property name="pin2" type="string" value="xstep"/>
|
||||
<property name="pin2inv" type="bool" value="False"/>
|
||||
<property name="pin3" type="string" value="xdir"/>
|
||||
<property name="pin3inv" type="bool" value="False"/>
|
||||
<property name="pin4" type="string" value="ystep"/>
|
||||
<property name="pin4inv" type="bool" value="False"/>
|
||||
<property name="pin5" type="string" value="ydir"/>
|
||||
<property name="pin5inv" type="bool" value="False"/>
|
||||
<property name="pin6" type="string" value="zstep"/>
|
||||
<property name="pin6inv" type="bool" value="False"/>
|
||||
<property name="pin7" type="string" value="zdir"/>
|
||||
<property name="pin7inv" type="bool" value="False"/>
|
||||
<property name="pin8" type="string" value="unused-output"/>
|
||||
<property name="pin8inv" type="bool" value="False"/>
|
||||
<property name="pin9" type="string" value="unused-output"/>
|
||||
<property name="pin9inv" type="bool" value="False"/>
|
||||
<property name="pp2_direction" type="int" value="0"/>
|
||||
<property name="pp3_direction" type="int" value="0"/>
|
||||
<property name="pyvcp" type="bool" value="False"/>
|
||||
<property name="pyvcpconnect" type="bool" value="False"/>
|
||||
<property name="pyvcphaltype" type="int" value="0"/>
|
||||
<property name="pyvcpname" type="string" value="blank.xml"/>
|
||||
<property name="s32in" type="float" value="10.0"/>
|
||||
<property name="s32out" type="float" value="10.0"/>
|
||||
<property name="spindlecarrier" type="float" value="100.0"/>
|
||||
<property name="spindlecpr" type="float" value="100.0"/>
|
||||
<property name="spindlefiltergain" type="float" value="0.01"/>
|
||||
<property name="spindlenearscale" type="float" value="1.5"/>
|
||||
<property name="spindlepwm1" type="float" value="0.2"/>
|
||||
<property name="spindlepwm2" type="float" value="0.8"/>
|
||||
<property name="spindlespeed1" type="float" value="100.0"/>
|
||||
<property name="spindlespeed2" type="float" value="800.0"/>
|
||||
<property name="stepspace" type="float" value="2000.0"/>
|
||||
<property name="steptime" type="float" value="1000.0"/>
|
||||
<property name="tempexists" type="int" value="0"/>
|
||||
<property name="units" type="int" value="0"/>
|
||||
<property name="usespindleatspeed" type="bool" value="False"/>
|
||||
<property name="xhomepos" type="float" value="0.0"/>
|
||||
<property name="xhomesw" type="float" value="0.0"/>
|
||||
<property name="xhomevel" type="float" value="0.05"/>
|
||||
<property name="xlatchdir" type="int" value="0"/>
|
||||
<property name="xleadscrew" type="float" value="100.0"/>
|
||||
<property name="xmaxacc" type="float" value="2.0"/>
|
||||
<property name="xmaxlim" type="float" value="100.0"/>
|
||||
<property name="xmaxvel" type="float" value="1.0"/>
|
||||
<property name="xmicrostep" type="float" value="10.0"/>
|
||||
<property name="xminlim" type="float" value="-100.0"/>
|
||||
<property name="xpulleyden" type="float" value="1.0"/>
|
||||
<property name="xpulleynum" type="float" value="1.0"/>
|
||||
<property name="xscale" type="float" value="200000.0"/>
|
||||
<property name="xsteprev" type="float" value="200.0"/>
|
||||
<property name="yhomepos" type="float" value="0.0"/>
|
||||
<property name="yhomesw" type="float" value="0.0"/>
|
||||
<property name="yhomevel" type="float" value="0.05"/>
|
||||
<property name="ylatchdir" type="int" value="0"/>
|
||||
<property name="yleadscrew" type="float" value="100.0"/>
|
||||
<property name="ymaxacc" type="float" value="1.0"/>
|
||||
<property name="ymaxlim" type="float" value="100.0"/>
|
||||
<property name="ymaxvel" type="float" value="1.0"/>
|
||||
<property name="ymicrostep" type="float" value="10.0"/>
|
||||
<property name="yminlim" type="float" value="-100.0"/>
|
||||
<property name="ypulleyden" type="float" value="1.0"/>
|
||||
<property name="ypulleynum" type="float" value="1.0"/>
|
||||
<property name="yscale" type="float" value="200000.0"/>
|
||||
<property name="ysteprev" type="float" value="200.0"/>
|
||||
<property name="zhomepos" type="float" value="0.0"/>
|
||||
<property name="zhomesw" type="float" value="0.0"/>
|
||||
<property name="zhomevel" type="float" value="0.05"/>
|
||||
<property name="zlatchdir" type="int" value="0"/>
|
||||
<property name="zleadscrew" type="float" value="100.0"/>
|
||||
<property name="zmaxacc" type="float" value="2.0"/>
|
||||
<property name="zmaxlim" type="float" value="100.0"/>
|
||||
<property name="zmaxvel" type="float" value="1.0"/>
|
||||
<property name="zmicrostep" type="float" value="10.0"/>
|
||||
<property name="zminlim" type="float" value="-100.0"/>
|
||||
<property name="zpulleyden" type="float" value="1.0"/>
|
||||
<property name="zpulleynum" type="float" value="1.0"/>
|
||||
<property name="zscale" type="float" value="200000.0"/>
|
||||
<property name="zsteprev" type="float" value="200.0"/>
|
||||
</stepconf>
|
||||
12
configs/by_interface/parport/gecko/Gecko_540B3/README
Normal file
12
configs/by_interface/parport/gecko/Gecko_540B3/README
Normal file
@@ -0,0 +1,12 @@
|
||||
Gecko_540B3 configuration for a 3 axis machine with X Y Z axes.
|
||||
|
||||
To use the charge pump on a G540 your base period must be set to 50,000 or lower. Otherwise disable the charge pump feature.
|
||||
|
||||
The Stepconf Wizard XML file is included so you can open it up and customize the configuration to suit your machine. After installing this configuration move the Gecko_540B3.stepconf file to the configs directory, then run the Stepconf Wizard and select Modify a configuration already created with this program.
|
||||
|
||||
Run the latency test to determine your max jitter and enter that in the Stepconf Wizard.
|
||||
|
||||
Set the axis limits, gearing for each axis.
|
||||
|
||||
Customize as needed to suit your machine.
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
# Include your customized HAL commands here
|
||||
# This file will not be overwritten when you run stepconf again
|
||||
@@ -0,0 +1,3 @@
|
||||
# Include your customized HAL commands here
|
||||
# The commands in this file are run after the AXIS GUI (including PyVCP panel) starts
|
||||
|
||||
4
configs/by_interface/parport/gecko/Gecko_540B3/tool.tbl
Normal file
4
configs/by_interface/parport/gecko/Gecko_540B3/tool.tbl
Normal file
@@ -0,0 +1,4 @@
|
||||
T1 P1 D0.125000 Z+0.511000 ;1/8 end mill
|
||||
T2 P2 D0.062500 Z+0.100000 ;1/16 end mill
|
||||
T3 P3 D0.201000 Z+1.273000 ;#7 tap drill
|
||||
T99999 P99999 Z+0.100000 ;big tool number
|
||||
@@ -0,0 +1,85 @@
|
||||
# Generated by stepconf at Wed Sep 26 07:51:20 2012
|
||||
# If you make changes to this file, they will be
|
||||
# overwritten when you run stepconf again
|
||||
loadrt [KINS]KINEMATICS
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
|
||||
loadrt hal_parport cfg="0x378 out "
|
||||
setp parport.0.reset-time 1000
|
||||
loadrt stepgen step_type=0,0,0
|
||||
loadrt charge_pump
|
||||
net estop-out charge-pump.enable iocontrol.0.user-enable-out
|
||||
net charge-pump <= charge-pump.out
|
||||
|
||||
addf parport.0.read base-thread
|
||||
addf stepgen.make-pulses base-thread
|
||||
addf charge-pump base-thread
|
||||
addf parport.0.write base-thread
|
||||
addf parport.0.reset base-thread
|
||||
|
||||
addf stepgen.capture-position servo-thread
|
||||
addf motion-command-handler servo-thread
|
||||
addf motion-controller servo-thread
|
||||
addf stepgen.update-freq servo-thread
|
||||
net spindle-cmd <= spindle.0.speed-out
|
||||
|
||||
net xstep => parport.0.pin-02-out
|
||||
setp parport.0.pin-02-out-reset 1
|
||||
net xdir => parport.0.pin-03-out
|
||||
net ystep => parport.0.pin-04-out
|
||||
setp parport.0.pin-04-out-reset 1
|
||||
net ydir => parport.0.pin-05-out
|
||||
net zstep => parport.0.pin-06-out
|
||||
setp parport.0.pin-06-out-reset 1
|
||||
net zdir => parport.0.pin-07-out
|
||||
net astep => parport.0.pin-08-out
|
||||
setp parport.0.pin-08-out-reset 1
|
||||
net adir => parport.0.pin-09-out
|
||||
net charge-pump => parport.0.pin-16-out
|
||||
|
||||
|
||||
|
||||
|
||||
setp stepgen.0.position-scale [JOINT_0]SCALE
|
||||
setp stepgen.0.steplen 1
|
||||
setp stepgen.0.stepspace 0
|
||||
setp stepgen.0.dirhold 15200
|
||||
setp stepgen.0.dirsetup 15200
|
||||
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
|
||||
net xpos-cmd joint.0.motor-pos-cmd => stepgen.0.position-cmd
|
||||
net xpos-fb stepgen.0.position-fb => joint.0.motor-pos-fb
|
||||
net xstep <= stepgen.0.step
|
||||
net xdir <= stepgen.0.dir
|
||||
net xenable joint.0.amp-enable-out => stepgen.0.enable
|
||||
|
||||
setp stepgen.1.position-scale [JOINT_1]SCALE
|
||||
setp stepgen.1.steplen 1
|
||||
setp stepgen.1.stepspace 0
|
||||
setp stepgen.1.dirhold 15200
|
||||
setp stepgen.1.dirsetup 15200
|
||||
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
|
||||
net ypos-cmd joint.1.motor-pos-cmd => stepgen.1.position-cmd
|
||||
net ypos-fb stepgen.1.position-fb => joint.1.motor-pos-fb
|
||||
net ystep <= stepgen.1.step
|
||||
net ydir <= stepgen.1.dir
|
||||
net yenable joint.1.amp-enable-out => stepgen.1.enable
|
||||
|
||||
setp stepgen.2.position-scale [JOINT_2]SCALE
|
||||
setp stepgen.2.steplen 1
|
||||
setp stepgen.2.stepspace 0
|
||||
setp stepgen.2.dirhold 15200
|
||||
setp stepgen.2.dirsetup 15200
|
||||
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
|
||||
net zpos-cmd joint.2.motor-pos-cmd => stepgen.2.position-cmd
|
||||
net zpos-fb stepgen.2.position-fb => joint.2.motor-pos-fb
|
||||
net zstep <= stepgen.2.step
|
||||
net zdir <= stepgen.2.dir
|
||||
net zenable joint.2.amp-enable-out => stepgen.2.enable
|
||||
|
||||
net estop-out <= iocontrol.0.user-enable-out
|
||||
net estop-out => iocontrol.0.emc-enable-in
|
||||
|
||||
loadusr -W hal_manualtoolchange
|
||||
net tool-change iocontrol.0.tool-change => hal_manualtoolchange.change
|
||||
net tool-changed iocontrol.0.tool-changed <= hal_manualtoolchange.changed
|
||||
net tool-number iocontrol.0.tool-prep-number => hal_manualtoolchange.number
|
||||
net tool-prepare-loopback iocontrol.0.tool-prepare => iocontrol.0.tool-prepared
|
||||
120
configs/by_interface/parport/gecko/Gecko_540B4/Gecko_540B4.ini
Normal file
120
configs/by_interface/parport/gecko/Gecko_540B4/Gecko_540B4.ini
Normal file
@@ -0,0 +1,120 @@
|
||||
# Generated by stepconf at Wed Sep 26 07:51:20 2012
|
||||
# If you make changes to this file, they will be
|
||||
# overwritten when you run stepconf again
|
||||
|
||||
[EMC]
|
||||
# The version string for this INI file.
|
||||
VERSION = 1.1
|
||||
MACHINE = Gecko_540B4
|
||||
DEBUG = 0
|
||||
|
||||
[DISPLAY]
|
||||
DISPLAY = axis
|
||||
#EDITOR = geany
|
||||
POSITION_OFFSET = RELATIVE
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
MAX_FEED_OVERRIDE = 1.2
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
INCREMENTS = .1in .05in .01in .005in .001in .0005in .0001in
|
||||
|
||||
[FILTER]
|
||||
PROGRAM_EXTENSION = .png,.gif,.jpg Greyscale Depth Image
|
||||
PROGRAM_EXTENSION = .py Python Script
|
||||
png = image-to-gcode
|
||||
gif = image-to-gcode
|
||||
jpg = image-to-gcode
|
||||
py = python3
|
||||
|
||||
[RS274NGC]
|
||||
PARAMETER_FILE = linuxcnc.var
|
||||
|
||||
[EMCMOT]
|
||||
EMCMOT = motmod
|
||||
COMM_TIMEOUT = 1.0
|
||||
BASE_PERIOD = 23000
|
||||
SERVO_PERIOD = 1000000
|
||||
|
||||
[TASK]
|
||||
TASK = milltask
|
||||
CYCLE_TIME = 0.010
|
||||
|
||||
[HAL]
|
||||
HALFILE = Gecko_540B4.hal
|
||||
HALFILE = custom.hal
|
||||
POSTGUI_HALFILE = custom_postgui.hal
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
COORDINATES = X Y Z
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 0.10
|
||||
MAX_LINEAR_VELOCITY = 1.00
|
||||
|
||||
[EMCIO]
|
||||
TOOL_TABLE = tool.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 2.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 2.0
|
||||
STEPGEN_MAXACCEL = 2.5
|
||||
SCALE = 200000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
HOME_OFFSET = 0.0
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 1.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 1.0
|
||||
STEPGEN_MAXACCEL = 1.25
|
||||
SCALE = 200000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
HOME_OFFSET = 0.0
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 2.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 0.20652173913
|
||||
MAX_ACCELERATION = 2.0
|
||||
STEPGEN_MAXACCEL = 2.5
|
||||
SCALE = 200000.0
|
||||
FERROR = 0.05
|
||||
MIN_FERROR = 0.01
|
||||
MIN_LIMIT = -100.0
|
||||
MAX_LIMIT = 100.0
|
||||
HOME_OFFSET = 0.0
|
||||
@@ -0,0 +1,140 @@
|
||||
<?xml version="1.0" ?>
|
||||
<stepconf>
|
||||
<property name="ahomepos" type="int" value="0"/>
|
||||
<property name="ahomesw" type="int" value="0"/>
|
||||
<property name="ahomevel" type="float" value="0.0"/>
|
||||
<property name="alatchdir" type="int" value="0"/>
|
||||
<property name="aleadscrew" type="int" value="100"/>
|
||||
<property name="amaxacc" type="int" value="2"/>
|
||||
<property name="amaxlim" type="int" value="100"/>
|
||||
<property name="amaxvel" type="int" value="0"/>
|
||||
<property name="amicrostep" type="int" value="1"/>
|
||||
<property name="aminlim" type="int" value="-100"/>
|
||||
<property name="apulleyden" type="int" value="1"/>
|
||||
<property name="apulleynum" type="int" value="1"/>
|
||||
<property name="ascale" type="int" value="0"/>
|
||||
<property name="asteprev" type="int" value="200"/>
|
||||
<property name="axes" type="int" value="0"/>
|
||||
<property name="classicladder" type="bool" value="False"/>
|
||||
<property name="createshortcut" type="bool" value="False"/>
|
||||
<property name="createsymlink" type="bool" value="False"/>
|
||||
<property name="customhal" type="int" value="1"/>
|
||||
<property name="digitsin" type="float" value="15.0"/>
|
||||
<property name="digitsout" type="float" value="15.0"/>
|
||||
<property name="dirhold" type="float" value="200.0"/>
|
||||
<property name="dirsetup" type="float" value="200.0"/>
|
||||
<property name="drivertype" type="string" value="gecko540"/>
|
||||
<property name="floatsin" type="float" value="10.0"/>
|
||||
<property name="floatsout" type="float" value="10.0"/>
|
||||
<property name="halui" type="bool" value="False"/>
|
||||
<property name="ioaddr" type="string" value="0x378"/>
|
||||
<property name="ioaddr2" type="string" value="Enter Address"/>
|
||||
<property name="ioaddr3" type="string" value="Enter Address"/>
|
||||
<property name="ladderconnect" type="bool" value="True"/>
|
||||
<property name="ladderhaltype" type="int" value="0"/>
|
||||
<property name="laddername" type="string" value="custom.clp"/>
|
||||
<property name="latency" type="float" value="15000.0"/>
|
||||
<property name="machinename" type="string" value="Gecko_540B4"/>
|
||||
<property name="manualtoolchange" type="bool" value="True"/>
|
||||
<property name="md5sums" type="eval" value="[('/home/john/linuxcnc/configs/Gecko_540B4/README', 'd6795c1e5c02e4d01df374bed0ecb468'), ('/home/john/linuxcnc/configs/Gecko_540B4/Gecko_540B4.ini', 'afbe6ca64d782a9c579a7e28220e24b2'), ('/home/john/linuxcnc/configs/Gecko_540B4/Gecko_540B4.hal', '0b77650d27113f38df9ab36c05e6f2f5')]"/>
|
||||
<property name="modbus" type="bool" value="False"/>
|
||||
<property name="number_pports" type="int" value="1"/>
|
||||
<property name="period" type="int" value="25000"/>
|
||||
<property name="pin1" type="string" value="unused-output"/>
|
||||
<property name="pin10" type="string" value="unused-input"/>
|
||||
<property name="pin10inv" type="bool" value="False"/>
|
||||
<property name="pin11" type="string" value="unused-input"/>
|
||||
<property name="pin11inv" type="bool" value="False"/>
|
||||
<property name="pin12" type="string" value="unused-input"/>
|
||||
<property name="pin12inv" type="bool" value="False"/>
|
||||
<property name="pin13" type="string" value="unused-input"/>
|
||||
<property name="pin13inv" type="bool" value="False"/>
|
||||
<property name="pin14" type="string" value="unused-output"/>
|
||||
<property name="pin14inv" type="bool" value="False"/>
|
||||
<property name="pin15" type="string" value="unused-input"/>
|
||||
<property name="pin15inv" type="bool" value="False"/>
|
||||
<property name="pin16" type="string" value="charge-pump"/>
|
||||
<property name="pin16inv" type="bool" value="False"/>
|
||||
<property name="pin17" type="string" value="unused-output"/>
|
||||
<property name="pin17inv" type="bool" value="False"/>
|
||||
<property name="pin1inv" type="bool" value="False"/>
|
||||
<property name="pin2" type="string" value="xstep"/>
|
||||
<property name="pin2inv" type="bool" value="False"/>
|
||||
<property name="pin3" type="string" value="xdir"/>
|
||||
<property name="pin3inv" type="bool" value="False"/>
|
||||
<property name="pin4" type="string" value="ystep"/>
|
||||
<property name="pin4inv" type="bool" value="False"/>
|
||||
<property name="pin5" type="string" value="ydir"/>
|
||||
<property name="pin5inv" type="bool" value="False"/>
|
||||
<property name="pin6" type="string" value="zstep"/>
|
||||
<property name="pin6inv" type="bool" value="False"/>
|
||||
<property name="pin7" type="string" value="zdir"/>
|
||||
<property name="pin7inv" type="bool" value="False"/>
|
||||
<property name="pin8" type="string" value="astep"/>
|
||||
<property name="pin8inv" type="bool" value="False"/>
|
||||
<property name="pin9" type="string" value="adir"/>
|
||||
<property name="pin9inv" type="bool" value="False"/>
|
||||
<property name="pp2_direction" type="int" value="0"/>
|
||||
<property name="pp3_direction" type="int" value="0"/>
|
||||
<property name="pyvcp" type="bool" value="False"/>
|
||||
<property name="pyvcpconnect" type="bool" value="False"/>
|
||||
<property name="pyvcphaltype" type="int" value="0"/>
|
||||
<property name="pyvcpname" type="string" value="blank.xml"/>
|
||||
<property name="s32in" type="float" value="10.0"/>
|
||||
<property name="s32out" type="float" value="10.0"/>
|
||||
<property name="spindlecarrier" type="float" value="100.0"/>
|
||||
<property name="spindlecpr" type="float" value="100.0"/>
|
||||
<property name="spindlefiltergain" type="float" value="0.01"/>
|
||||
<property name="spindlenearscale" type="float" value="1.5"/>
|
||||
<property name="spindlepwm1" type="float" value="0.2"/>
|
||||
<property name="spindlepwm2" type="float" value="0.8"/>
|
||||
<property name="spindlespeed1" type="float" value="100.0"/>
|
||||
<property name="spindlespeed2" type="float" value="800.0"/>
|
||||
<property name="stepspace" type="float" value="2000.0"/>
|
||||
<property name="steptime" type="float" value="1000.0"/>
|
||||
<property name="tempexists" type="int" value="0"/>
|
||||
<property name="units" type="int" value="0"/>
|
||||
<property name="usespindleatspeed" type="bool" value="False"/>
|
||||
<property name="xhomepos" type="float" value="0.0"/>
|
||||
<property name="xhomesw" type="float" value="0.0"/>
|
||||
<property name="xhomevel" type="float" value="0.05"/>
|
||||
<property name="xlatchdir" type="int" value="0"/>
|
||||
<property name="xleadscrew" type="float" value="100.0"/>
|
||||
<property name="xmaxacc" type="float" value="2.0"/>
|
||||
<property name="xmaxlim" type="float" value="100.0"/>
|
||||
<property name="xmaxvel" type="float" value="1.0"/>
|
||||
<property name="xmicrostep" type="float" value="10.0"/>
|
||||
<property name="xminlim" type="float" value="-100.0"/>
|
||||
<property name="xpulleyden" type="float" value="1.0"/>
|
||||
<property name="xpulleynum" type="float" value="1.0"/>
|
||||
<property name="xscale" type="float" value="200000.0"/>
|
||||
<property name="xsteprev" type="float" value="200.0"/>
|
||||
<property name="yhomepos" type="float" value="0.0"/>
|
||||
<property name="yhomesw" type="float" value="0.0"/>
|
||||
<property name="yhomevel" type="float" value="0.05"/>
|
||||
<property name="ylatchdir" type="int" value="0"/>
|
||||
<property name="yleadscrew" type="float" value="100.0"/>
|
||||
<property name="ymaxacc" type="float" value="1.0"/>
|
||||
<property name="ymaxlim" type="float" value="100.0"/>
|
||||
<property name="ymaxvel" type="float" value="1.0"/>
|
||||
<property name="ymicrostep" type="float" value="10.0"/>
|
||||
<property name="yminlim" type="float" value="-100.0"/>
|
||||
<property name="ypulleyden" type="float" value="1.0"/>
|
||||
<property name="ypulleynum" type="float" value="1.0"/>
|
||||
<property name="yscale" type="float" value="200000.0"/>
|
||||
<property name="ysteprev" type="float" value="200.0"/>
|
||||
<property name="zhomepos" type="float" value="0.0"/>
|
||||
<property name="zhomesw" type="float" value="0.0"/>
|
||||
<property name="zhomevel" type="float" value="0.05"/>
|
||||
<property name="zlatchdir" type="int" value="0"/>
|
||||
<property name="zleadscrew" type="float" value="100.0"/>
|
||||
<property name="zmaxacc" type="float" value="2.0"/>
|
||||
<property name="zmaxlim" type="float" value="100.0"/>
|
||||
<property name="zmaxvel" type="float" value="1.0"/>
|
||||
<property name="zmicrostep" type="float" value="10.0"/>
|
||||
<property name="zminlim" type="float" value="-100.0"/>
|
||||
<property name="zpulleyden" type="float" value="1.0"/>
|
||||
<property name="zpulleynum" type="float" value="1.0"/>
|
||||
<property name="zscale" type="float" value="200000.0"/>
|
||||
<property name="zsteprev" type="float" value="200.0"/>
|
||||
</stepconf>
|
||||
13
configs/by_interface/parport/gecko/Gecko_540B4/README
Normal file
13
configs/by_interface/parport/gecko/Gecko_540B4/README
Normal file
@@ -0,0 +1,13 @@
|
||||
Gecko_540B4 configuration for a 4 axis machine with X Y Z A axes.
|
||||
|
||||
To use the charge pump on a G540 your base period must be set to 50,000 or lower. Otherwise disable the charge pump feature.
|
||||
|
||||
The Stepconf Wizard XML file is included so you can open it up and customize the configuration to suit your machine. After installing this configuration move the Gecko_540B4.stepconf file to the configs directory, then run the Stepconf Wizard and select Modify a configuration already created with this program.
|
||||
|
||||
Run the latency test to determine your max jitter and enter that in the Stepconf Wizard.
|
||||
|
||||
Set the axis limits, gearing for each axis.
|
||||
|
||||
Customize as needed to suit your machine.
|
||||
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
# Include your customized HAL commands here
|
||||
# This file will not be overwritten when you run stepconf again
|
||||
@@ -0,0 +1,3 @@
|
||||
# Include your customized HAL commands here
|
||||
# The commands in this file are run after the AXIS GUI (including PyVCP panel) starts
|
||||
|
||||
4
configs/by_interface/parport/gecko/Gecko_540B4/tool.tbl
Normal file
4
configs/by_interface/parport/gecko/Gecko_540B4/tool.tbl
Normal file
@@ -0,0 +1,4 @@
|
||||
T1 P1 D0.125000 Z+0.511000 ;1/8 end mill
|
||||
T2 P2 D0.062500 Z+0.100000 ;1/16 end mill
|
||||
T3 P3 D0.201000 Z+1.273000 ;#7 tap drill
|
||||
T99999 P99999 Z+0.100000 ;big tool number
|
||||
5
configs/by_interface/parport/gecko/README
Normal file
5
configs/by_interface/parport/gecko/README
Normal file
@@ -0,0 +1,5 @@
|
||||
Basic Configurations for Gecko Drives
|
||||
|
||||
Gecko_540B3 configuration for a 3 axis machine with X Y Z axes. To use the charge pump on a G540 your base period must be set to 50,000 or lower. Otherwise disable the charge pump feature.
|
||||
|
||||
Gecko_540B4 configuration for a 4 axis machine with X Y Z A axes. To use the charge pump on a G540 your base period must be set to 50,000 or lower. Otherwise disable the charge pump feature.
|
||||
1
configs/by_interface/parport/nc_files
Symbolic link
1
configs/by_interface/parport/nc_files
Symbolic link
@@ -0,0 +1 @@
|
||||
../../../nc_files
|
||||
5
configs/by_interface/parport/nist-lathe/README
Normal file
5
configs/by_interface/parport/nist-lathe/README
Normal file
@@ -0,0 +1,5 @@
|
||||
This is the config for the stepper-driven Sherline lathe which is generously on loan from NIST.
|
||||
|
||||
It has spindle speed control by analog input, which is driven by software-generated PWM on a parallel port pin. The motors are driven with step/dir and the spindle encoder (for synchronized motion/threading) is counted by software on the parallel port too.
|
||||
|
||||
This all makes for a fully functional lathe using simple hardware. The power is all in HAL; the hardware is just a single parallel port interface and simple stepper drivers.
|
||||
212
configs/by_interface/parport/nist-lathe/inch.ini
Normal file
212
configs/by_interface/parport/nist-lathe/inch.ini
Normal file
@@ -0,0 +1,212 @@
|
||||
# EMC controller parameters for generic controller. Make these what you need
|
||||
# for your system.
|
||||
# General note: Comments can either be preceded with a # or ; - either is
|
||||
# acceptable, although # is in keeping with most linux config files.
|
||||
# Settings with a + at the front of the comment are likely needed to get
|
||||
# changed by the user.
|
||||
# Settings with a - at the front are highly unneeded to be changed
|
||||
###############################################################################
|
||||
# General section
|
||||
###############################################################################
|
||||
|
||||
[EMC]
|
||||
#- Version of this INI file
|
||||
VERSION = 1.1
|
||||
#+ Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-NIST-LATHE-IN
|
||||
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
DEBUG = 0
|
||||
# DEBUG = 0x00000007
|
||||
# DEBUG = 0x7FFFFFFF
|
||||
###############################################################################
|
||||
# Sections for display options
|
||||
###############################################################################
|
||||
|
||||
[DISPLAY]
|
||||
#+ Name of display program, e.g., axis
|
||||
DISPLAY = axis
|
||||
# DISPLAY = tklinuxcnc
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
LATHE = 1
|
||||
CYCLE_TIME = 0.200
|
||||
#- Path to help file
|
||||
HELP_FILE = doc/help.txt
|
||||
#- Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
#- Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
#+ Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 1.4
|
||||
#- Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
#- Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
# Editor to be used with Axis
|
||||
#EDITOR = geany
|
||||
###############################################################################
|
||||
# Task controller section
|
||||
###############################################################################
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
#- File containing interpreter variables
|
||||
PARAMETER_FILE = nist-lathe.var
|
||||
###############################################################################
|
||||
# Motion control section
|
||||
###############################################################################
|
||||
|
||||
[EMCMOT]
|
||||
#- Name of the motion controller to use (only one exists for nontrivkins)
|
||||
EMCMOT = motmod
|
||||
#- Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
#+ Base task period, in nanosecs - this is the fastest thread in the machine
|
||||
BASE_PERIOD = 20000
|
||||
#- Servo task period, in nanosecs - will be rounded to an int multiple of BASE_PERIOD
|
||||
SERVO_PERIOD = 1000000
|
||||
###############################################################################
|
||||
# Hardware Abstraction Layer section
|
||||
###############################################################################
|
||||
|
||||
[TASK]
|
||||
# Name of task controller program, e.g., milltask
|
||||
TASK = milltask
|
||||
#- Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.010
|
||||
###############################################################################
|
||||
# Part program interpreter section
|
||||
###############################################################################
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# list of hal config files to run through halcmd
|
||||
#+ files are executed in the order in which they appear
|
||||
HALFILE = nist-lathe.hal
|
||||
#- list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
###############################################################################
|
||||
# Trajectory planner section
|
||||
###############################################################################
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
#+ machine specific settings
|
||||
# COORDINATES = X Y Z R P W
|
||||
COORDINATES = X Y Z
|
||||
HOME = 0 0 0
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = .5
|
||||
MAX_LINEAR_VELOCITY = .5
|
||||
DEFAULT_LINEAR_ACCELERATION = 20.0
|
||||
MAX_LINEAR_ACCELERATION = 20.0
|
||||
###############################################################################
|
||||
# Axes sections
|
||||
###############################################################################
|
||||
#+ First axis
|
||||
|
||||
[EMCIO]
|
||||
#- tool table file
|
||||
TOOL_TABLE = nist-lathe.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -0.54
|
||||
MAX_LIMIT = 1.11
|
||||
MAX_VELOCITY = 0.383333
|
||||
MAX_ACCELERATION = 5.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.5
|
||||
MAX_VELOCITY = 0.383333
|
||||
# NOTE: the step generator module applies its own limits to
|
||||
# acceleration and velocity. We have discovered that it needs
|
||||
# to have a little "headroom" over the accel by the trajectory
|
||||
# planner, otherwise it can fall slightly behind during accel
|
||||
# and later overshoot as it catches up. In the long term we
|
||||
# hope to come up with a clean fix for this problem. In the
|
||||
# meantime, please set STEPGEN_MAXACCEL below to a few percent
|
||||
# higher than the regular acceleration limit MAX_ACCELERATION
|
||||
MAX_ACCELERATION = 5.0
|
||||
STEPGEN_MAXACCEL = 7.7
|
||||
BACKLASH = 0.000
|
||||
SCALE = -8000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -0.54
|
||||
MAX_LIMIT = 1.11
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = .1111
|
||||
HOME_SEARCH_VEL = -0.5
|
||||
HOME_LATCH_VEL = -0.025
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
HOME_SEQUENCE=1
|
||||
#+ Second axis
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.0
|
||||
MAX_ACCELERATION = 12.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.0
|
||||
MAX_ACCELERATION = 12.0
|
||||
STEPGEN_MAXACCEL = 13.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Third axis
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -0.001
|
||||
MAX_LIMIT = 4.0
|
||||
MAX_VELOCITY = 0.433333
|
||||
MAX_ACCELERATION = 5.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 1.0
|
||||
MAX_VELOCITY = 0.433333
|
||||
MAX_ACCELERATION = 5.0
|
||||
STEPGEN_MAXACCEL = 5.7
|
||||
BACKLASH = 0.000
|
||||
SCALE = -8000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -0.001
|
||||
MAX_LIMIT = 4.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.5
|
||||
HOME_SEARCH_VEL = -0.5
|
||||
HOME_LATCH_VEL = -0.025
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
HOME_SEQUENCE = 0
|
||||
###############################################################################
|
||||
# section for main IO controller parameters
|
||||
###############################################################################
|
||||
245
configs/by_interface/parport/nist-lathe/nist-lathe.hal
Normal file
245
configs/by_interface/parport/nist-lathe/nist-lathe.hal
Normal file
@@ -0,0 +1,245 @@
|
||||
# HAL config file for MAX NC test machine
|
||||
#######################################################
|
||||
# first load all the HAL modules we're going to need
|
||||
#######################################################
|
||||
# kinematics
|
||||
loadrt [KINS]KINEMATICS
|
||||
# main motion controller module
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
|
||||
# using steppers....
|
||||
loadrt stepgen step_type=0,0,0
|
||||
# I/O thru the parport
|
||||
loadrt hal_parport cfg="0x0378"
|
||||
# counting the spindle counter in software
|
||||
loadrt counter num_chan=1
|
||||
# misc blocks needed to do fun things
|
||||
loadrt ddt count=6
|
||||
# spindle speed pwm
|
||||
loadrt pwmgen output_type=0
|
||||
# spindle speed feedback
|
||||
loadrt lowpass count=1
|
||||
loadrt mult2 count=1
|
||||
loadrt scale count=1
|
||||
|
||||
#######################################################
|
||||
# add realtime functions to the threads
|
||||
# first the high speed thread
|
||||
#######################################################
|
||||
# first we read parport inputs
|
||||
addf parport.0.read base-thread
|
||||
# update counter
|
||||
addf counter.update-counters base-thread
|
||||
# generate step and dir signals
|
||||
addf stepgen.make-pulses base-thread
|
||||
# generate spindle pwm
|
||||
addf pwmgen.make-pulses base-thread
|
||||
# write to outputs
|
||||
addf parport.0.write base-thread
|
||||
|
||||
|
||||
|
||||
# now the servo thread
|
||||
########################################################
|
||||
# capture axis and spindle positions
|
||||
addf stepgen.capture-position servo-thread
|
||||
addf counter.capture-position servo-thread
|
||||
# process motion commands coming from user space
|
||||
addf motion-command-handler servo-thread
|
||||
# run main motion controller
|
||||
addf motion-controller servo-thread
|
||||
# differentiators to make vel and acc signals
|
||||
addf ddt.0 servo-thread
|
||||
addf ddt.1 servo-thread
|
||||
addf ddt.2 servo-thread
|
||||
addf ddt.3 servo-thread
|
||||
addf ddt.4 servo-thread
|
||||
addf ddt.5 servo-thread
|
||||
# other misc blocks
|
||||
addf scale.0 servo-thread
|
||||
addf pwmgen.update servo-thread
|
||||
# update output info, axis and spindle
|
||||
addf stepgen.update-freq servo-thread
|
||||
addf lowpass.0 servo-thread
|
||||
addf mult2.0 servo-thread
|
||||
|
||||
|
||||
#######################################################
|
||||
# interconnections
|
||||
#
|
||||
# first, the basic stepper machine connections
|
||||
#######################################################
|
||||
|
||||
# connect position commands from motion module to step generator
|
||||
net Xpos-cmd <= joint.0.motor-pos-cmd
|
||||
net Xpos-cmd => stepgen.0.position-cmd
|
||||
net Ypos-cmd <= joint.1.motor-pos-cmd
|
||||
net Ypos-cmd => stepgen.1.position-cmd
|
||||
net Zpos-cmd <= joint.2.motor-pos-cmd
|
||||
net Zpos-cmd => stepgen.2.position-cmd
|
||||
|
||||
# connect position feedback from step generators
|
||||
# to motion module
|
||||
net Xpos-fb <= stepgen.0.position-fb
|
||||
net Xpos-fb => joint.0.motor-pos-fb
|
||||
net Ypos-fb <= stepgen.1.position-fb
|
||||
net Ypos-fb => joint.1.motor-pos-fb
|
||||
net Zpos-fb <= stepgen.2.position-fb
|
||||
net Zpos-fb => joint.2.motor-pos-fb
|
||||
|
||||
# connect enable signals for step generators
|
||||
net Xen <= joint.0.amp-enable-out
|
||||
net Xen => stepgen.0.enable
|
||||
net Yen <= joint.1.amp-enable-out
|
||||
net Yen => stepgen.1.enable
|
||||
net Zen <= joint.2.amp-enable-out
|
||||
net Zen => stepgen.2.enable
|
||||
|
||||
# connect signals to step pulse generator outputs
|
||||
net Xstep <= stepgen.0.step
|
||||
net Xdir <= stepgen.0.dir
|
||||
net Ystep <= stepgen.1.step
|
||||
net Ydir <= stepgen.1.dir
|
||||
net Zstep <= stepgen.2.step
|
||||
net Zdir <= stepgen.2.dir
|
||||
|
||||
#############################################################################
|
||||
# Spindle Speed
|
||||
# The spindle goes forward only
|
||||
net spindle-forward <= spindle.0.forward
|
||||
net spindle-forward => pwmgen.0.enable
|
||||
|
||||
# PID is not used to give closed-loop spindle speed control, because at the
|
||||
# highest speeds the software-based counter cannot keep up (note: with 'counter',
|
||||
# it can)
|
||||
# Instead, this offset and scale have been determined empirically
|
||||
# -- if these numbers are accurate, then top speed at this gearing is about
|
||||
# 1200 rpm
|
||||
#
|
||||
# gain = 1/1128 ~ .00089
|
||||
# offset = .07
|
||||
# PWM Measured RPM
|
||||
# 25% 200
|
||||
# 50% 482
|
||||
# 60% 595
|
||||
setp scale.0.gain .00089
|
||||
setp scale.0.offset .07
|
||||
|
||||
net spindle-speed-cmd <= spindle.0.speed-out
|
||||
net spindle-speed-cmd => scale.0.in
|
||||
net spindle-speed-pwm <= scale.0.out
|
||||
net spindle-speed-pwm => pwmgen.0.value
|
||||
|
||||
# Spindle speed feedback -- spindle-speed-fb-rpm can be metered or scoped
|
||||
# but beware that at the highest speeds the software-based counter cannot
|
||||
# keep up, and the speed is estimated incorrectly
|
||||
|
||||
# The gain of the lowpass filter is a trade-off: Higher numbers track spindle
|
||||
# speed better when the speed changes. Lower numbers give a more steady
|
||||
# estimate of average spindle speed when the speed is nominally constant
|
||||
setp lowpass.0.gain 0.01
|
||||
net spindle-speed-fb-raw <= counter.0.velocity
|
||||
net spindle-speed-fb-raw => lowpass.0.in
|
||||
net spindle-speed-fb-filtered <= lowpass.0.out
|
||||
|
||||
setp mult2.0.in0 60
|
||||
net spindle-speed-fb-filtered mult2.0.in1
|
||||
net spindle-speed-fb-rpm mult2.0.out
|
||||
#############################################################################
|
||||
|
||||
# create a signal for the estop loopback
|
||||
net estop-loop iocontrol.0.user-enable-out iocontrol.0.emc-enable-in
|
||||
|
||||
# create signals for tool loading loopback
|
||||
net tool-prep-loop iocontrol.0.tool-prepare iocontrol.0.tool-prepared
|
||||
net tool-change-loop iocontrol.0.tool-change iocontrol.0.tool-changed
|
||||
|
||||
# create a signal for "spindle on"
|
||||
net spindle_on <= spindle.0.on
|
||||
|
||||
# connect physical pins to the signals
|
||||
net Xstep => parport.0.pin-03-out
|
||||
net Xdir => parport.0.pin-02-out
|
||||
net Ystep => parport.0.pin-05-out
|
||||
net Ydir => parport.0.pin-04-out
|
||||
net Zstep => parport.0.pin-07-out
|
||||
net Zdir => parport.0.pin-06-out
|
||||
# amp enable (active lo)
|
||||
#linksp Xen => parport.0.pin-01-out
|
||||
#setp parport.0.pin-01-out-invert 1
|
||||
|
||||
# spindle enable
|
||||
net spindle_on => parport.0.pin-01-out
|
||||
setp parport.0.pin-01-out-invert 1
|
||||
|
||||
net pwm pwmgen.0.pwm => parport.0.pin-14-out
|
||||
|
||||
#######################################################
|
||||
# set scaling and other parameters of the basic machine
|
||||
|
||||
# set stepgen module scaling - get values from ini file
|
||||
setp stepgen.0.position-scale [JOINT_0]SCALE
|
||||
setp stepgen.1.position-scale [JOINT_1]SCALE
|
||||
setp stepgen.2.position-scale [JOINT_2]SCALE
|
||||
|
||||
# set stepgen module accel limits - get values from ini file
|
||||
# jmk said to set these to ini value + 5% to avoid stepgen bug
|
||||
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
|
||||
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
|
||||
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
|
||||
|
||||
# end of basic machine
|
||||
|
||||
net homeswitches <= parport.0.pin-10-in
|
||||
net homeswitches => joint.0.home-sw-in
|
||||
net homeswitches => joint.2.home-sw-in
|
||||
|
||||
#######################################################
|
||||
# Beginning of threading-related stuff
|
||||
#######################################################
|
||||
|
||||
# spindle counter
|
||||
# connect encoder signals to counter counter
|
||||
# B is not used because it is the counter module, not encoder
|
||||
net spindle-phase-A => counter.0.phase-A
|
||||
net spindle-phase-Z => counter.0.phase-Z
|
||||
|
||||
net spindle-phase-A <= parport.0.pin-11-in
|
||||
net spindle-phase-B <= parport.0.pin-12-in
|
||||
net spindle-phase-Z <= parport.0.pin-13-in
|
||||
|
||||
# (that way thread pitches can be straightforward,
|
||||
# a 20 tpi thread would multiply the counter output
|
||||
# by 1/20, etc)
|
||||
setp counter.0.position-scale 1024
|
||||
|
||||
# hook up motion controller's spindle indexing pin
|
||||
net spindle-index-enable <= spindle.0.index-enable
|
||||
net spindle-index-enable <=> counter.0.index-enable
|
||||
|
||||
# report our revolution count to the motion controller
|
||||
net spindle-pos <= counter.0.position
|
||||
net spindle-pos => spindle.0.revs
|
||||
|
||||
|
||||
#######################################################
|
||||
# make vel and accel sigs for testing
|
||||
#######################################################
|
||||
|
||||
# send the position commands thru differentiators to
|
||||
# generate velocity and accel signals (for testing)
|
||||
|
||||
# define the signals, and hook them up
|
||||
net Xpos-cmd => ddt.0.in
|
||||
net Xvel <= ddt.0.out
|
||||
net Xvel => ddt.1.in
|
||||
net Xacc <= ddt.1.out
|
||||
|
||||
net Ypos-cmd => ddt.2.in
|
||||
net Yvel <= ddt.2.out
|
||||
net Yvel => ddt.3.in
|
||||
net Yacc <= ddt.3.out
|
||||
|
||||
net Zpos-cmd => ddt.4.in
|
||||
net Zvel <= ddt.4.out
|
||||
net Zvel => ddt.5.in
|
||||
net Zacc <= ddt.5.out
|
||||
9
configs/by_interface/parport/nist-lathe/nist-lathe.tbl
Normal file
9
configs/by_interface/parport/nist-lathe/nist-lathe.tbl
Normal file
@@ -0,0 +1,9 @@
|
||||
T1 P1 D0.100000 Z+0.100000 I+95.000000 J+155.000000 Q1 ;
|
||||
T2 P2 D0.100000 I+85.000000 J+25.000000 Q2 ;
|
||||
T3 P3 D0.100000 I+275.000000 J+335.000000 Q3 ;
|
||||
T4 P4 D0.100000 I+265.000000 J+205.000000 Q4 ;
|
||||
T5 P5 D0.100000 I+210.000000 J+150.000000 Q5 ;
|
||||
T6 P6 D0.100000 X+0.500000 Z+0.500000 I+120.000000 J+60.000000 Q6 ;
|
||||
T7 P7 D0.100000 I-30.000000 J+30.000000 Q7 ;
|
||||
T8 P8 D0.100000 I+240.000000 J+300.000000 Q8 ;
|
||||
T9 P9 D0.100000 Q9 ;
|
||||
7
configs/by_interface/parport/plasma-thc-sim/README
Normal file
7
configs/by_interface/parport/plasma-thc-sim/README
Normal file
@@ -0,0 +1,7 @@
|
||||
This is a config for a gantry style plasma cutting machine using stepper motors.
|
||||
|
||||
The configuration includes a Torch Height Control system which should be compatible with systems from SoundLogic, CandCNC and Bob Campbell.
|
||||
|
||||
The stepper and limit pinouts are compatible with Breakout Combo boards from Bob Campbell. This configuration is identical to plasma-thc except all input/output signals are simulated.
|
||||
|
||||
Don't forget to home the simulator before running a program, it needs to home before starting, otherwise there will be limit errors
|
||||
10
configs/by_interface/parport/plasma-thc-sim/estop.hal
Normal file
10
configs/by_interface/parport/plasma-thc-sim/estop.hal
Normal file
@@ -0,0 +1,10 @@
|
||||
################################ Other ##########################################
|
||||
#Connect Estop and ChargePump
|
||||
|
||||
loadrt estop_latch
|
||||
addf estop-latch.0 base-thread
|
||||
|
||||
# External Estop Signal handled by THC
|
||||
net EstopRequestEnable iocontrol.0.user-request-enable => estop-latch.0.reset
|
||||
net EstopEnableOut iocontrol.0.user-enable-out => estop-latch.0.ok-in
|
||||
net EstopOKOut estop-latch.0.ok-out => iocontrol.0.emc-enable-in
|
||||
12
configs/by_interface/parport/plasma-thc-sim/kinematics.hal
Normal file
12
configs/by_interface/parport/plasma-thc-sim/kinematics.hal
Normal file
@@ -0,0 +1,12 @@
|
||||
############################## Kinematics & Motion Controller ####################################
|
||||
# Kinematics
|
||||
loadrt [KINS]KINEMATICS
|
||||
|
||||
# Settings for gantrykins
|
||||
setp gantrykins.joint-0 0
|
||||
setp gantrykins.joint-1 1
|
||||
setp gantrykins.joint-2 2
|
||||
setp gantrykins.joint-3 1
|
||||
|
||||
# motion controller, get name and thread periods from ini file
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD
|
||||
284
configs/by_interface/parport/plasma-thc-sim/plasma_mm.ini
Normal file
284
configs/by_interface/parport/plasma-thc-sim/plasma_mm.ini
Normal file
@@ -0,0 +1,284 @@
|
||||
# EMC controller parameters for a plasma controller. Make these what you need
|
||||
# for your system.
|
||||
# General note: Comments can either be preceded with a # or ; - either is
|
||||
# acceptable, although # is in keeping with most linux config files.
|
||||
# Settings with a + at the front of the comment are likely needed to get
|
||||
# changed by the user.
|
||||
# Settings with a - at the front are highly unneeded to be changed
|
||||
###############################################################################
|
||||
# General section
|
||||
###############################################################################
|
||||
|
||||
[EMC]
|
||||
#- Version of this INI file
|
||||
VERSION = 1.1
|
||||
#+ Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-PLASMA-THC
|
||||
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
DEBUG = 0
|
||||
#DEBUG = 0x00000007
|
||||
#DEBUG = 0x7FFFFFFF
|
||||
# Enable Adaptive Feedrate for THC
|
||||
# Used to pause execution of gcode for setup,
|
||||
# pierce delay and manual verification of pierce height
|
||||
# Set spindle speed to 1
|
||||
# Set up to use metric mm
|
||||
RS274NGC_STARTUP_CODE = M52 P1 G21 S1
|
||||
###############################################################################
|
||||
# Sections for display options
|
||||
###############################################################################
|
||||
|
||||
[DISPLAY]
|
||||
#Plasma Control Panel
|
||||
PYVCP = thc_vcp.xml
|
||||
#+ Name of display program, e.g., axis
|
||||
DISPLAY = axis
|
||||
#DISPLAY = tklinuxcnc
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
CYCLE_TIME = 0.200
|
||||
#- Path to help file
|
||||
HELP_FILE = doc/help.txt
|
||||
#HELP_FILE = tklinuxcnc.txt
|
||||
#- Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
#- Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
#+ Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 1.5
|
||||
#- Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
#- Text Editor
|
||||
EDITOR = geany
|
||||
#- Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 3
|
||||
#Increments for the JOB Section
|
||||
INCREMENTS = 1000 10 1 0.1 0.01
|
||||
###############################################################################
|
||||
# Task controller section
|
||||
###############################################################################
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
#- File containing interpreter variables
|
||||
PARAMETER_FILE = plasma.var
|
||||
###############################################################################
|
||||
# Motion control section
|
||||
###############################################################################
|
||||
|
||||
[EMCMOT]
|
||||
#- Name of the motion controller to use (only one exists for nontrivkins)
|
||||
EMCMOT = motmod
|
||||
#- Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
#+ Base task period, in nanosecs - this is the fastest thread in the machine
|
||||
#BASE_PERIOD = 15000
|
||||
#BASE_PERIOD = 18000
|
||||
#BASE_PERIOD = 20000
|
||||
#BASE_PERIOD = 35000
|
||||
BASE_PERIOD = 50000
|
||||
#- Servo task period, in nanosecs - will be rounded to an int multiple of BASE_PERIOD
|
||||
#SERVO_PERIOD = 10000
|
||||
SERVO_PERIOD = 100000
|
||||
#SERVO_PERIOD = 100000
|
||||
#- Trajectory Planner task period, in nanosecs - will be rounded to an
|
||||
# integer multiple of SERVO_PERIOD
|
||||
#TRAJ_PERIOD = 100000
|
||||
TRAJ_PERIOD = 1000000
|
||||
###############################################################################
|
||||
# Hardware Abstraction Layer section
|
||||
###############################################################################
|
||||
|
||||
[TASK]
|
||||
#- Name of task controller program, e.g., bridgeporttask
|
||||
TASK = milltask
|
||||
#- Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.100
|
||||
###############################################################################
|
||||
# Part program interpreter section
|
||||
###############################################################################
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# HALUI to interact with NML
|
||||
# Run before any other HALFILE
|
||||
HALUI = halui
|
||||
# list of hal config files to run through halcmd
|
||||
#+ files are executed in the order in which they appear
|
||||
HALFILE = kinematics.hal
|
||||
HALFILE = stepper.hal
|
||||
HALFILE = stepper_parport.hal
|
||||
HALFILE = estop.hal
|
||||
HALFILE = thc.hal
|
||||
HALFILE = axis_manualtoolchange.hal
|
||||
HALFILE = simulator.hal
|
||||
# A file to hook pyvcp to hal signals
|
||||
POSTGUI_HALFILE = thc_vcp.hal
|
||||
#- list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
###############################################################################
|
||||
# Trajectory planner section
|
||||
###############################################################################
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
#+ machine specific settings
|
||||
COORDINATES = X Y Z A
|
||||
LINEAR_UNITS = mm
|
||||
ANGULAR_UNITS = deg
|
||||
#DEFAULT_VELOCITY = 100
|
||||
DEFAULT_LINEAR_VELOCITY = 40
|
||||
#MAX_VELOCITY = 180
|
||||
MAX_LINEAR_VELOCITY = 63
|
||||
DEFAULT_LINEAR_ACCELERATION = 600
|
||||
MAX_LINEAR_ACCELERATION = 2400
|
||||
#POSITION_FILE = last_position.txt
|
||||
###############################################################################
|
||||
# Axes sections
|
||||
###############################################################################
|
||||
#+ First axis (X)
|
||||
|
||||
[EMCIO]
|
||||
#- Tool table file, torches and consumables
|
||||
TOOL_TABLE = torches.tbl
|
||||
#+ Tool Change Position, if this is set the torch will move the the specified position before requesting a tool change
|
||||
#TOOL_CHANGE_POSITION = 0 0 50
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins coordinates=xyza kinematics=BOTH
|
||||
JOINTS = 4
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 2055
|
||||
MAX_VELOCITY = 63
|
||||
MAX_ACCELERATION = 2400
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
#MAX_VELOCITY = 170
|
||||
MAX_VELOCITY = 63
|
||||
MAX_ACCELERATION = 2400
|
||||
STEPGEN_MAXACCEL = 2960
|
||||
BACKLASH = 0.000
|
||||
SCALE = 150.333
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 2055
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = -50.0
|
||||
HOME_LATCH_VEL = 1.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 1
|
||||
#+ Second axis (Y)
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 6050.0
|
||||
MAX_VELOCITY = 63
|
||||
MAX_ACCELERATION = 2400
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
#MAX_VELOCITY = 170
|
||||
MAX_VELOCITY = 63
|
||||
MAX_ACCELERATION = 2400
|
||||
STEPGEN_MAXVEL = 65
|
||||
STEPGEN_MAXACCEL = 2960
|
||||
BACKLASH = 0.000
|
||||
SCALE = 150.333
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 6050.0
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = -50.0
|
||||
HOME_LATCH_VEL = 1.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 1
|
||||
#+ Third axis (Z)
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 56.0
|
||||
MAX_VELOCITY = 8
|
||||
MAX_ACCELERATION = 600
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 55.000
|
||||
MAX_VELOCITY = 8
|
||||
MAX_ACCELERATION = 600
|
||||
STEPGEN_MAXACCEL = 650
|
||||
#STEPGEN_MAXACCEL = 2960
|
||||
BACKLASH = 0.000
|
||||
SCALE = 200
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 56.0
|
||||
FERROR = 1.270
|
||||
#MIN_FERROR = 0.254
|
||||
# This is done so Z axis can be operated with a HAL closed loop (plasma THC)
|
||||
MIN_FERROR = 500
|
||||
HOME_OFFSET = 55.0
|
||||
HOME_SEARCH_VEL = 10.0
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 0
|
||||
#+ Second axis (A)
|
||||
|
||||
[AXIS_A]
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 6050.0
|
||||
MAX_VELOCITY = 63
|
||||
MAX_ACCELERATION = 2400
|
||||
|
||||
[JOINT_3]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
#MAX_VELOCITY = 170
|
||||
MAX_VELOCITY = 63
|
||||
MAX_ACCELERATION = 2400
|
||||
STEPGEN_MAXACCEL = 2960
|
||||
BACKLASH = 0.000
|
||||
SCALE = 150.333
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 6050.0
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = -50.0
|
||||
HOME_LATCH_VEL = 1.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 1
|
||||
###############################################################################
|
||||
# section for main IO controller parameters
|
||||
###############################################################################
|
||||
|
||||
[PLASMA]
|
||||
# Note that setting Ignition timeout to high can cause issues with very short cuts, problems can arise when the timeout has not expired and starting to cut a new part
|
||||
#- Ignition fault timeout, the time allowed from TorchOn until ArcOK before re-probing and re-initiating, in seconds
|
||||
IGNITION_TIMEOUT = 3
|
||||
#- ArcOK timeout, a filter, for a signal to be valid it needs to exceed the specified time period, in seconds
|
||||
ARC_OK_FILTER_TIME = 0.2
|
||||
#- Ignition Retries before abort, the number of attempts to re-probe and start the torch before estop
|
||||
MAX_FAILED_IGNITIONS = 5
|
||||
#- Extinguish Timeout, a grace period after losing ArcOK before shutting off the torch and re-probing, in seconds
|
||||
EXTINGUISH_TIMEOUT = 0.2
|
||||
68
configs/by_interface/parport/plasma-thc-sim/simulator.hal
Normal file
68
configs/by_interface/parport/plasma-thc-sim/simulator.hal
Normal file
@@ -0,0 +1,68 @@
|
||||
# A simulator to simulate all components of a gantry based plasma cutting table with THC
|
||||
|
||||
# Load realtime wcomp components
|
||||
loadrt wcomp count=6
|
||||
|
||||
# Add components to servo-thread
|
||||
addf and2.9 servo-thread
|
||||
addf and2.10 servo-thread
|
||||
addf and2.11 servo-thread
|
||||
addf not.3 servo-thread
|
||||
addf or2.9 servo-thread
|
||||
addf wcomp.0 servo-thread
|
||||
addf wcomp.1 servo-thread
|
||||
addf wcomp.2 servo-thread
|
||||
addf wcomp.3 servo-thread
|
||||
addf wcomp.4 servo-thread
|
||||
addf wcomp.5 servo-thread
|
||||
|
||||
# Use machine position feedback for simulated limit calculations
|
||||
net PosX-fb => wcomp.0.in
|
||||
net PosY-fb => wcomp.1.in
|
||||
net PosZ-fb => wcomp.2.in
|
||||
net PosA-fb => wcomp.3.in
|
||||
net PosZ-fb => wcomp.4.in
|
||||
|
||||
# Use the time left from oneshot1 to determine when to simulate ArcOK along with TorchOn
|
||||
net TimeLeft oneshot.1.time-left => wcomp.5.in
|
||||
|
||||
# Simulate limits with wcomps
|
||||
net LimitX wcomp.0.out => joint.0.neg-lim-sw-in joint.0.pos-lim-sw-in joint.0.home-sw-in
|
||||
net LimitY wcomp.1.out => joint.1.neg-lim-sw-in joint.1.pos-lim-sw-in joint.1.home-sw-in
|
||||
net LimitZ or2.9.out => or2.2.in0
|
||||
net LimitA wcomp.3.out => joint.3.neg-lim-sw-in joint.3.pos-lim-sw-in joint.3.home-sw-in
|
||||
|
||||
# Hook up other simulated signals
|
||||
net FloatSwitch and2.9.out => or2.1.in1 and2.4.in0 and2.5.in1 and2.6.in1
|
||||
net ArcOK and2.10.out => or2.4.in1 xor2.1.in1 oneshot.2.in
|
||||
net IgnDebugTimer wcomp.5.out and2.10.in0
|
||||
net ArcOKSwitch and2.11.out and2.10.in1
|
||||
|
||||
# Fix the problem with the float switch being triggered during homing because machine starts at pos 0
|
||||
net MachineIsHoming joint.2.homing => not.3.in
|
||||
net InvertedMachineIsHoming not.3.out => and2.9.in0
|
||||
net OriginalFloatSignal wcomp.4.out => and2.9.in1
|
||||
|
||||
# Set defaults to pass signals through as normal so that ArcOK lights
|
||||
net HomeAndLimitZ wcomp.2.out => or2.9.in0
|
||||
net TorchOn => and2.11.in0
|
||||
|
||||
# To test what happens when ArcOK never arrives we can set and2.11.in1 to 0
|
||||
setp and2.11.in1 1
|
||||
# To simulate the float switch triggering at other machine coordinates than standard we use or2.9.in0 and set it manually
|
||||
setp or2.9.in1 0
|
||||
|
||||
# Set windows for comparison
|
||||
setp wcomp.0.max -10
|
||||
setp wcomp.0.min -15
|
||||
setp wcomp.1.max -10
|
||||
setp wcomp.1.min -15
|
||||
setp wcomp.2.max 50
|
||||
setp wcomp.2.min 40
|
||||
setp wcomp.3.max -10
|
||||
setp wcomp.3.min -15
|
||||
setp wcomp.4.max 15
|
||||
setp wcomp.4.min 10
|
||||
# ArcOK comparator, uses ignition timeout
|
||||
setp wcomp.5.max 4
|
||||
setp wcomp.5.min -1
|
||||
54
configs/by_interface/parport/plasma-thc-sim/stepper.hal
Normal file
54
configs/by_interface/parport/plasma-thc-sim/stepper.hal
Normal file
@@ -0,0 +1,54 @@
|
||||
############################ Step Generators #########################################
|
||||
|
||||
# Stepper module, four step generators, all using step/dir
|
||||
loadrt stepgen step_type=0,0,0,0
|
||||
|
||||
# Load realtime ddt for velocity calculations used for CHL
|
||||
loadrt ddt count=2
|
||||
|
||||
# Hook functions to base thread (high speed thread for step generation)
|
||||
addf stepgen.make-pulses base-thread
|
||||
|
||||
# Hook functions to servo thread
|
||||
addf stepgen.capture-position servo-thread
|
||||
addf motion-command-handler servo-thread
|
||||
addf motion-controller servo-thread
|
||||
addf stepgen.update-freq servo-thread
|
||||
addf ddt.0 servo-thread
|
||||
addf ddt.1 servo-thread
|
||||
|
||||
# Configure signals for Z axis to be twice the size of the signals for other axis because
|
||||
# Z axis has a slo-syn driver which can't handle smaller step sizes
|
||||
setp stepgen.2.steplen 35200
|
||||
setp stepgen.2.stepspace 35200
|
||||
setp stepgen.2.dirsetup 35200
|
||||
setp stepgen.2.dirhold 35200
|
||||
|
||||
# Set stepgen module scaling - get values from ini file
|
||||
setp stepgen.0.position-scale [JOINT_0]SCALE
|
||||
setp stepgen.1.position-scale [JOINT_1]SCALE
|
||||
setp stepgen.2.position-scale [JOINT_2]SCALE
|
||||
setp stepgen.3.position-scale [JOINT_3]SCALE
|
||||
|
||||
# Set stepgen module accel limits - get values from ini file
|
||||
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
|
||||
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
|
||||
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
|
||||
setp stepgen.3.maxaccel [JOINT_3]STEPGEN_MAXACCEL
|
||||
|
||||
# Hook up stepgen to motion modules
|
||||
net PosX-cmd joint.0.motor-pos-cmd => stepgen.0.position-cmd
|
||||
net PosX-fb stepgen.0.position-fb => joint.0.motor-pos-fb ddt.0.in
|
||||
net PosY-cmd joint.1.motor-pos-cmd => stepgen.1.position-cmd
|
||||
net PosY-fb stepgen.1.position-fb => joint.1.motor-pos-fb ddt.1.in
|
||||
# Z Axis Position and feedback signals handled by THC, see thc.hal
|
||||
#net PosZ-cmd joint.2.motor-pos-cmd => stepgen.2.position-cmd
|
||||
#net PosZ-fb stepgen.2.position-fb => joint.2.motor-pos-fb
|
||||
net PosA-cmd joint.3.motor-pos-cmd => stepgen.3.position-cmd
|
||||
net PosA-fb stepgen.3.position-fb => joint.3.motor-pos-fb
|
||||
|
||||
# Hook up enable signals for step generators
|
||||
net EnableX joint.0.amp-enable-out => stepgen.0.enable
|
||||
net EnableY joint.1.amp-enable-out => stepgen.1.enable
|
||||
net EnableZ joint.2.amp-enable-out => stepgen.2.enable
|
||||
net EnableA joint.3.amp-enable-out => stepgen.3.enable
|
||||
@@ -0,0 +1,13 @@
|
||||
############################# Parallel Ports ##############################################
|
||||
|
||||
# Load Driver for Two Parallel Ports, one for Breakout Board, other for Plasma Torch Height Control
|
||||
|
||||
# Connect both Parallel Ports to Threads for Read / Write
|
||||
|
||||
# Invert pins to make motors move in right direction
|
||||
|
||||
# Axis A and Y are the same axis but different motors
|
||||
|
||||
# Hook up limit and home switches, each axis shares a common pin for homing, limit min and limit max
|
||||
# Limit switches handled by simulator code, see simulator.hal
|
||||
# Z axis Limit switch handled by THC, see thc.hal
|
||||
198
configs/by_interface/parport/plasma-thc-sim/thc.hal
Normal file
198
configs/by_interface/parport/plasma-thc-sim/thc.hal
Normal file
@@ -0,0 +1,198 @@
|
||||
###################### Torch Height Control ##########################
|
||||
|
||||
# Load realtime hal components for THC
|
||||
#3 extra ands for simulator
|
||||
loadrt and2 count=12
|
||||
loadrt comp count=3
|
||||
loadrt updown
|
||||
loadrt flipflop count=3
|
||||
loadrt hypot
|
||||
loadrt logic personality=0x203
|
||||
loadrt minmax
|
||||
loadrt mult2 count=2
|
||||
loadrt mux2 count=7
|
||||
#1 extra not for simulator
|
||||
loadrt not count=4
|
||||
loadrt oneshot count=4
|
||||
#1 extra or for simulator
|
||||
loadrt or2 count=10
|
||||
loadrt scale
|
||||
loadrt sum2 count=5
|
||||
loadrt xor2 count=4
|
||||
loadrt conv_s32_float
|
||||
loadrt edge count=2
|
||||
|
||||
# Attach realtime hal components to a realtime thread
|
||||
addf and2.0 servo-thread
|
||||
addf and2.1 servo-thread
|
||||
addf and2.2 servo-thread
|
||||
addf and2.3 servo-thread
|
||||
addf and2.4 servo-thread
|
||||
addf and2.5 servo-thread
|
||||
addf and2.6 servo-thread
|
||||
addf and2.7 servo-thread
|
||||
addf and2.8 servo-thread
|
||||
addf comp.0 servo-thread
|
||||
addf comp.1 servo-thread
|
||||
addf comp.2 servo-thread
|
||||
addf conv-s32-float.0 servo-thread
|
||||
addf edge.0 servo-thread
|
||||
addf edge.1 servo-thread
|
||||
addf flipflop.0 servo-thread
|
||||
addf flipflop.1 servo-thread
|
||||
addf flipflop.2 servo-thread
|
||||
addf hypot.0 servo-thread
|
||||
addf logic.0 servo-thread
|
||||
addf minmax.0 servo-thread
|
||||
addf mult2.0 servo-thread
|
||||
addf mult2.1 servo-thread
|
||||
addf mux2.0 servo-thread
|
||||
addf mux2.1 servo-thread
|
||||
addf mux2.2 servo-thread
|
||||
addf mux2.3 servo-thread
|
||||
addf mux2.4 servo-thread
|
||||
addf mux2.5 servo-thread
|
||||
addf mux2.6 servo-thread
|
||||
addf not.0 servo-thread
|
||||
addf not.1 servo-thread
|
||||
addf not.2 servo-thread
|
||||
addf oneshot.0 servo-thread
|
||||
addf oneshot.1 servo-thread
|
||||
addf oneshot.2 servo-thread
|
||||
addf oneshot.3 servo-thread
|
||||
addf or2.0 servo-thread
|
||||
addf or2.1 servo-thread
|
||||
addf or2.2 servo-thread
|
||||
addf or2.3 servo-thread
|
||||
addf or2.4 servo-thread
|
||||
addf or2.5 servo-thread
|
||||
addf or2.6 servo-thread
|
||||
addf or2.7 servo-thread
|
||||
addf or2.8 servo-thread
|
||||
addf updown.0 servo-thread
|
||||
addf scale.0 servo-thread
|
||||
addf sum2.0 servo-thread
|
||||
addf sum2.1 servo-thread
|
||||
addf sum2.2 servo-thread
|
||||
addf sum2.3 servo-thread
|
||||
addf sum2.4 servo-thread
|
||||
addf xor2.0 servo-thread
|
||||
addf xor2.1 servo-thread
|
||||
addf xor2.2 servo-thread
|
||||
|
||||
# Set static values and default values
|
||||
setp oneshot.1.width [PLASMA]IGNITION_TIMEOUT
|
||||
setp oneshot.2.width [PLASMA]ARC_OK_FILTER_TIME
|
||||
setp oneshot.3.width [PLASMA]EXTINGUISH_TIMEOUT
|
||||
setp oneshot.3.falling 1
|
||||
setp oneshot.3.rising 0
|
||||
setp comp.2.in0 [PLASMA]MAX_FAILED_IGNITIONS
|
||||
setp mux2.1.in0 -1
|
||||
setp mux2.1.in1 1
|
||||
setp mux2.3.in0 0
|
||||
|
||||
# Set the lowest value the THC will try to move the torch
|
||||
setp sum2.4.in0 [JOINT_2]MIN_LIMIT
|
||||
|
||||
# Set default gains for sum, positive for addition and negative for subtraction
|
||||
# Setting positive gains will become implicit and those can be removed safely in a later version
|
||||
setp sum2.0.gain0 1
|
||||
setp sum2.0.gain1 1
|
||||
setp sum2.1.gain0 1
|
||||
setp sum2.1.gain1 1
|
||||
setp sum2.2.gain0 1
|
||||
setp sum2.2.gain1 -1
|
||||
setp sum2.3.gain0 1
|
||||
setp sum2.3.gain1 -1
|
||||
setp sum2.4.gain0 1
|
||||
setp sum2.4.gain1 -1
|
||||
|
||||
# Set Hysterisis for float comp
|
||||
setp comp.1.hyst 0.001
|
||||
|
||||
# Set percentage multiplier for scale
|
||||
setp scale.0.gain 0.01
|
||||
|
||||
# Set edge detectors to work on falling edges to detect Ignition Timeouts
|
||||
setp edge.0.in-edge 1
|
||||
setp edge.1.in-edge 1
|
||||
|
||||
# Hook up parallel port pins
|
||||
net MoveDown => or2.0.in0
|
||||
net MoveUp => or2.0.in1 mux2.1.sel
|
||||
|
||||
# Floatswitch and ArcOK signals handled by simulator, see simulator.hal
|
||||
#net FloatSwitch parport.1.pin-13-in => or2.1.in1 and2.4.in0 and2.5.in1 and2.6.in1
|
||||
#net ArcOK => or2.4.in1 xor2.1.in1 oneshot.2.in
|
||||
|
||||
net FilteredArcOK xor2.1.out => or2.1.in0 or2.6.in0 not.1.in and2.4.in1 flipflop.1.set oneshot.3.in flipflop.2.set and2.2.in0
|
||||
net TimersOrArcOK or2.4.out => or2.5.in0 or2.3.in0
|
||||
|
||||
# Hook up component pins using the net command
|
||||
net LockHeight and2.0.out => xor2.2.in0
|
||||
net EnabledAdjustHeight and2.1.out => mux2.3.sel
|
||||
net ReleaseFeedHold and2.2.out => xor2.0.in1
|
||||
net TorchOn => and2.3.out oneshot.1.in not.2.in
|
||||
net FloatSwitchEstop and2.4.out => logic.0.in-02
|
||||
net FloatAndTorchOn and2.5.out => or2.2.in1
|
||||
net TorchAndFloat and2.6.out => flipflop.0.set
|
||||
net PosAndFloat and2.7.out => or2.5.in1
|
||||
net IgnitionEstop comp.2.out => logic.0.in-01
|
||||
net StartTorchOn and2.8.out => and2.3.in0
|
||||
net OriginalPosZ-cmd joint.2.motor-pos-cmd => mux2.5.in0 sum2.2.in1
|
||||
net JointPoz-cmd joint.2.pos-cmd => sum2.2.in0
|
||||
net CHLTriggered comp.0.out => and2.0.in0
|
||||
net AtPosition comp.1.equal => and2.7.in0
|
||||
net VelX ddt.0.out => hypot.0.in0
|
||||
net VelY ddt.1.out => hypot.0.in1
|
||||
net FloatSwitchSet flipflop.0.out => or2.3.in1 and2.7.in1
|
||||
net ModeIsAuto halui.mode.is-auto => mux2.5.sel
|
||||
net VelXY hypot.0.out => minmax.0.in comp.0.in0
|
||||
net TriggerEStop logic.0.or => estop-latch.0.fault-in
|
||||
net MaximumVelocity minmax.0.max => mult2.1.in0
|
||||
net TurnTorchOn spindle.0.forward => xor2.0.in0 and2.8.in0 and2.6.in0 mux2.4.sel not.0.in
|
||||
net HeightAdjustment mult2.0.out => mux2.3.in1
|
||||
net VelocityThreshold mult2.1.out => comp.0.in1
|
||||
net HeightOffset mux2.0.out => sum2.1.in1
|
||||
net AdjustmentDirection mux2.1.out => mult2.0.in1
|
||||
net PositionSnapshot mux2.2.out => sum2.1.in0 mux2.2.in0
|
||||
net SelectedAdjustment mux2.3.out => mux2.0.in1
|
||||
net PosZ-cmd mux2.4.out => stepgen.2.position-cmd comp.1.in1
|
||||
net PosSelectB mux2.5.out => mux2.4.in0
|
||||
net PosSelectC mux2.6.out => mux2.4.in1
|
||||
net TurnTorchOff not.0.out => and2.5.in0 or2.7.in0 updown.0.reset
|
||||
net ReversedArcOK not.1.out => minmax.0.reset
|
||||
net PierceDelayElapsed oneshot.0.out-not => and2.2.in1
|
||||
net IgnitionTimer oneshot.1.out => edge.0.in or2.8.in0
|
||||
net AdjustHeight or2.0.out => xor2.2.in1 and2.1.in0
|
||||
net TakeSnapshot or2.1.out => mux2.2.sel
|
||||
net TriggerLimit or2.2.out => joint.2.neg-lim-sw-in joint.2.pos-lim-sw-in joint.2.home-sw-in
|
||||
net ProbeOrArcOK or2.3.out => mux2.6.sel
|
||||
net PAFOrArcOK or2.5.out => and2.3.in1
|
||||
net EstopOrArcOK or2.6.out => flipflop.0.reset
|
||||
# Estop signal handled by simulator, see simulator.hal
|
||||
#net ExtEStop parport.0.pin-10-in => logic.0.in-00
|
||||
net ExtEStop => logic.0.in-00
|
||||
# Z limit handled by simulator, see simulator.hal
|
||||
#net LimitZ parport.0.pin-13-in => or2.2.in0
|
||||
net ThresholdPercentage scale.0.out => mult2.1.in1
|
||||
net PosZ-fb stepgen.2.position-fb => joint.2.motor-pos-fb mux2.2.in1 comp.1.in0
|
||||
net PierceOffset sum2.0.out => mux2.0.in0
|
||||
net DestinationHeight sum2.1.out => mux2.6.in1
|
||||
net JointAxisDiff sum2.2.out => sum2.3.in1 sum2.4.in1
|
||||
net StepCordsTH sum2.3.out => mux2.5.in1
|
||||
net StepCordsML sum2.4.out => mux2.6.in0
|
||||
net FeedHold xor2.0.out => motion.feed-hold
|
||||
net CHLSwitched xor2.2.out => and2.1.in1
|
||||
net ArcOKTimer oneshot.2.out => xor2.1.in0
|
||||
net PierceLatch flipflop.1.out => mux2.0.sel oneshot.0.in
|
||||
net IgnitionCounterS32 updown.0.count => conv-s32-float.0.in
|
||||
net IgnitionCounterFloat conv-s32-float.0.out => comp.2.in1
|
||||
net IgnitionTimerOff oneshot.1.out-not => updown.0.countup
|
||||
net TorchOff not.2.out => flipflop.1.reset
|
||||
net TorchTurnedOffOrTimeout or2.7.out => or2.6.in1
|
||||
net IgnitionTimeout edge.0.out => or2.7.in1
|
||||
net ExtinguishTimer oneshot.3.out edge.1.in
|
||||
net ExtinguishLatch flipflop.2.out or2.8.in1
|
||||
net ExtinguishTimeout edge.1.out flipflop.2.reset
|
||||
net Timers or2.8.out => or2.4.in0
|
||||
21
configs/by_interface/parport/plasma-thc-sim/thc_vcp.hal
Normal file
21
configs/by_interface/parport/plasma-thc-sim/thc_vcp.hal
Normal file
@@ -0,0 +1,21 @@
|
||||
############### Torch Height Control Python Widgets ####################
|
||||
|
||||
# Hook up PyVCP pins using the net command
|
||||
net CHLThreshold pyvcp.Scale-CHLThreshold-f => scale.0.in
|
||||
net CHLEnable pyvcp.Check-CHLEnable => and2.0.in1
|
||||
net TravelHeight pyvcp.Spin-TravelHeight => sum2.3.in0
|
||||
net PierceDelay pyvcp.Spin-PierceDelay => oneshot.0.width
|
||||
net THCStepSize pyvcp.Spin-THCStepSize => mult2.0.in0
|
||||
net PierceGap pyvcp.Spin-PierceGap => sum2.0.in1
|
||||
net SwitchTravel pyvcp.Spin-SwitchTravel => sum2.0.in0
|
||||
net Autostart pyvcp.Check-AutoStart and2.8.in1
|
||||
|
||||
# Hook up pins connecting to PyVCP objects
|
||||
net MoveDown => pyvcp.Led-MoveDown
|
||||
net MoveUp => pyvcp.Led-MoveUp
|
||||
net FloatSwitch => pyvcp.Led-FloatSwitch
|
||||
net ArcOK => pyvcp.Led-ArcOK
|
||||
net LockHeight => pyvcp.Led-HeightLocked
|
||||
net TorchOn => pyvcp.Led-TorchOn
|
||||
net ExtEStop => pyvcp.Led-ExtEStop
|
||||
net PierceDelayTimer oneshot.0.time-left => pyvcp.Num-PierceDelayTimer
|
||||
222
configs/by_interface/parport/plasma-thc-sim/thc_vcp.xml
Normal file
222
configs/by_interface/parport/plasma-thc-sim/thc_vcp.xml
Normal file
@@ -0,0 +1,222 @@
|
||||
<?xml version='1.0' encoding='UTF-8'?>
|
||||
<pyvcp>
|
||||
<labelframe text="Signals">
|
||||
<hbox>
|
||||
<vbox>
|
||||
<led>
|
||||
<halpin>"Led-FloatSwitch"</halpin>
|
||||
<size>20</size>
|
||||
<on_color>"blue"</on_color>
|
||||
<off_color>"grey"</off_color>
|
||||
</led>
|
||||
<led>
|
||||
<halpin>"Led-TorchOn"</halpin>
|
||||
<size>20</size>
|
||||
<on_color>"yellow"</on_color>
|
||||
<off_color>"grey"</off_color>
|
||||
</led>
|
||||
<led>
|
||||
<halpin>"Led-ArcOK"</halpin>
|
||||
<size>20</size>
|
||||
<on_color>"green"</on_color>
|
||||
<off_color>"grey"</off_color>
|
||||
</led>
|
||||
<led>
|
||||
<halpin>"Led-ExtEStop"</halpin>
|
||||
<size>20</size>
|
||||
<on_color>"red"</on_color>
|
||||
<off_color>"grey"</off_color>
|
||||
</led>
|
||||
</vbox>
|
||||
<vbox>
|
||||
<label text="Float Switch"/>
|
||||
<label text="Torch On"/>
|
||||
<label text="Arc OK"/>
|
||||
<label text="External EStop"/>
|
||||
</vbox>
|
||||
</hbox>
|
||||
</labelframe>
|
||||
<labelframe text="Adjustments">
|
||||
<vbox>
|
||||
<hbox>
|
||||
<vbox>
|
||||
<led>
|
||||
<halpin>"Led-MoveUp"</halpin>
|
||||
<size>20</size>
|
||||
<on_color>"green"</on_color>
|
||||
<off_color>"grey"</off_color>
|
||||
</led>
|
||||
<led>
|
||||
<halpin>"Led-MoveDown"</halpin>
|
||||
<size>20</size>
|
||||
<on_color>"green"</on_color>
|
||||
<off_color>"grey"</off_color>
|
||||
</led>
|
||||
</vbox>
|
||||
|
||||
<vbox>
|
||||
<label text="Move UP"/>
|
||||
<label text="Move Down"/>
|
||||
</vbox>
|
||||
</hbox>
|
||||
<hbox>
|
||||
<relief>RIDGE</relief>
|
||||
<bd>1</bd>
|
||||
<label text="Step Size"/>
|
||||
<spinbox>
|
||||
<halpin>"Spin-THCStepSize"</halpin>
|
||||
<min_>0.0001</min_>
|
||||
<max_>1</max_>
|
||||
<initval>0.0005</initval>
|
||||
<width>"6"</width>
|
||||
<resolution>.0001</resolution>
|
||||
<format>"5.4f"</format>
|
||||
<justify>RIGHT</justify>
|
||||
</spinbox>
|
||||
</hbox>
|
||||
<hbox>
|
||||
<relief>RIDGE</relief>
|
||||
<bd>1</bd>
|
||||
<label text="Travel Height"/>
|
||||
<spinbox>
|
||||
<halpin>"Spin-TravelHeight"</halpin>
|
||||
<min_>1</min_>
|
||||
<max_>99</max_>
|
||||
<initval>54</initval>
|
||||
<width>"3"</width>
|
||||
<resolution>1</resolution>
|
||||
<format>"3.0f"</format>
|
||||
<justify>RIGHT</justify>
|
||||
</spinbox>
|
||||
</hbox>
|
||||
<hbox>
|
||||
<relief>RIDGE</relief>
|
||||
<bd>1</bd>
|
||||
<label text="Sw. Travel"/>
|
||||
<spinbox>
|
||||
<halpin>"Spin-SwitchTravel"</halpin>
|
||||
<min_>-50</min_>
|
||||
<max_>50</max_>
|
||||
<initval>7</initval>
|
||||
<width>"5"</width>
|
||||
<resolution>.01</resolution>
|
||||
<format>"5.2f"</format>
|
||||
<justify>RIGHT</justify>
|
||||
</spinbox>
|
||||
</hbox>
|
||||
|
||||
</vbox>
|
||||
</labelframe>
|
||||
<labelframe text="Piercing">
|
||||
<vbox>
|
||||
<vbox>
|
||||
<hbox>
|
||||
<relief>RIDGE</relief>
|
||||
<bd>1</bd>
|
||||
<label text="Delay Timer"/>
|
||||
<number>
|
||||
<halpin>"Num-PierceDelayTimer"</halpin>
|
||||
<format>"+4.2f"</format>
|
||||
</number>
|
||||
</hbox>
|
||||
<hbox>
|
||||
<vbox>
|
||||
<label text="Delay"/>
|
||||
<label text="Gap"/>
|
||||
<label text="AutoStart"/>
|
||||
</vbox>
|
||||
<vbox>
|
||||
<spinbox>
|
||||
<halpin>"Spin-PierceDelay"</halpin>
|
||||
<min_>0.00</min_>
|
||||
<max_>10</max_>
|
||||
<initval>0.50</initval>
|
||||
<width>"6"</width>
|
||||
<resolution>.01</resolution>
|
||||
<format>"5.2f"</format>
|
||||
<justify>RIGHT</justify>
|
||||
</spinbox>
|
||||
<spinbox>
|
||||
<halpin>"Spin-PierceGap"</halpin>
|
||||
<min_>0.01</min_>
|
||||
<max_>10</max_>
|
||||
<initval>5</initval>
|
||||
<width>"6"</width>
|
||||
<resolution>.01</resolution>
|
||||
<format>"5.2f"</format>
|
||||
<justify>RIGHT</justify>
|
||||
</spinbox>
|
||||
<checkbutton>
|
||||
<halpin>"Check-AutoStart"</halpin>
|
||||
<initval>1</initval>
|
||||
<bd>1</bd>
|
||||
</checkbutton>
|
||||
</vbox>
|
||||
</hbox>
|
||||
</vbox>
|
||||
</vbox>
|
||||
</labelframe>
|
||||
<labelframe text="Corner Height Lock">
|
||||
<vbox>
|
||||
<hbox>
|
||||
<vbox>
|
||||
<led>
|
||||
<halpin>"Led-HeightLocked"</halpin>
|
||||
<size>20</size>
|
||||
<on_color>"green"</on_color>
|
||||
<off_color>"grey"</off_color>
|
||||
</led>
|
||||
<checkbutton>
|
||||
<halpin>"Check-CHLEnable"</halpin>
|
||||
<bd>1</bd>
|
||||
</checkbutton>
|
||||
</vbox>
|
||||
<vbox>
|
||||
<label text="Locked"/>
|
||||
<label text="Enable"/>
|
||||
</vbox>
|
||||
</hbox>
|
||||
<vbox>
|
||||
<relief>RIDGE</relief>
|
||||
<bd>1</bd>
|
||||
<label text="Threshold %"/>
|
||||
<scale>
|
||||
<halpin>"Scale-CHLThreshold"</halpin>
|
||||
<min_>10</min_>
|
||||
<max_>99</max_>
|
||||
<initval>60</initval>
|
||||
<resolution>1</resolution>
|
||||
<orient>HORIZONTAL</orient>
|
||||
</scale>
|
||||
</vbox>
|
||||
</vbox>
|
||||
</labelframe>
|
||||
<labelframe text="THC Voltage">
|
||||
<vbox>
|
||||
<hbox>
|
||||
<vbox>
|
||||
<label text="Current Voltage"/>
|
||||
<label text="Target Voltage"/>
|
||||
</vbox>
|
||||
<vbox>
|
||||
<number>
|
||||
<halpin>"Num-THCCurrentVoltage"</halpin>
|
||||
<format>"3.0f"</format>
|
||||
</number>
|
||||
<spinbox>
|
||||
<halpin>"Spin-THCTargetVoltage"</halpin>
|
||||
<min_>1</min_>
|
||||
<max_>255</max_>
|
||||
<initval>100</initval>
|
||||
<width>"3"</width>
|
||||
<resolution>1</resolution>
|
||||
<format>"3.0f"</format>
|
||||
<justify>RIGHT</justify>
|
||||
</spinbox>
|
||||
</vbox>
|
||||
|
||||
</hbox>
|
||||
</vbox>
|
||||
</labelframe>
|
||||
|
||||
</pyvcp>
|
||||
4
configs/by_interface/parport/plasma-thc-sim/torches.tbl
Normal file
4
configs/by_interface/parport/plasma-thc-sim/torches.tbl
Normal file
@@ -0,0 +1,4 @@
|
||||
T1 P1 D0.125000 Z+0.511000 ;1/8 end mill
|
||||
T2 P2 D0.062500 Z+0.100000 ;1/16 end mill
|
||||
T3 P3 D0.201000 Z+1.273000 ;#7 tap drill
|
||||
T99999 P99999 Z+0.100000 ;big tool number
|
||||
5
configs/by_interface/parport/stepper-gantry/README
Normal file
5
configs/by_interface/parport/stepper-gantry/README
Normal file
@@ -0,0 +1,5 @@
|
||||
This config is for a XYZ setup where the Y axis is a gantry style system driven by two motors.
|
||||
|
||||
The config uses stepper motors with metric units and includes a charge pump. The pinout is consistent with the breakout/combo boards from Bob Campbell.
|
||||
|
||||
The plasma-thc config is based on this config but has torch height control and external estop in addition to this config
|
||||
12
configs/by_interface/parport/stepper-gantry/estop.hal
Normal file
12
configs/by_interface/parport/stepper-gantry/estop.hal
Normal file
@@ -0,0 +1,12 @@
|
||||
################################ Other ##########################################
|
||||
#Connect Estop and ChargePump
|
||||
|
||||
loadrt estop_latch
|
||||
addf estop-latch.0 base-thread
|
||||
|
||||
# External Estop Signal handled by THC
|
||||
net ExtEStop parport.0.pin-10-in => estop-latch.0.fault-in
|
||||
net EstopLatchWatchDog estop-latch.0.watchdog => parport.0.pin-17-out parport.1.pin-17-out
|
||||
net EstopRequestEnable iocontrol.0.user-request-enable => estop-latch.0.reset
|
||||
net EstopEnableOut iocontrol.0.user-enable-out => estop-latch.0.ok-in
|
||||
net EstopOKOut estop-latch.0.ok-out => iocontrol.0.emc-enable-in
|
||||
12
configs/by_interface/parport/stepper-gantry/kinematics.hal
Normal file
12
configs/by_interface/parport/stepper-gantry/kinematics.hal
Normal file
@@ -0,0 +1,12 @@
|
||||
############################## Kinematics & Motion Controller ####################################
|
||||
# Kinematics
|
||||
loadrt [KINS]KINEMATICS
|
||||
|
||||
# Settings for gantrykins
|
||||
setp gantrykins.joint-0 0
|
||||
setp gantrykins.joint-1 1
|
||||
setp gantrykins.joint-2 2
|
||||
setp gantrykins.joint-3 1
|
||||
|
||||
# motion controller, get name and thread periods from ini file
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD
|
||||
50
configs/by_interface/parport/stepper-gantry/stepper.hal
Normal file
50
configs/by_interface/parport/stepper-gantry/stepper.hal
Normal file
@@ -0,0 +1,50 @@
|
||||
############################ Step Generators #########################################
|
||||
|
||||
# Stepper module, four step generators, all using step/dir
|
||||
loadrt stepgen step_type=0,0,0,0
|
||||
|
||||
# Hook functions to base thread (high speed thread for step generation)
|
||||
addf stepgen.make-pulses base-thread
|
||||
|
||||
# Hook functions to servo thread
|
||||
addf stepgen.capture-position servo-thread
|
||||
addf motion-command-handler servo-thread
|
||||
addf motion-controller servo-thread
|
||||
addf stepgen.update-freq servo-thread
|
||||
|
||||
# Configure signals for Z axis to be twice the size of the signals for other axis because
|
||||
# Z axis has a slo-syn driver which can't handle smaller step sizes
|
||||
setp stepgen.2.steplen 35200
|
||||
setp stepgen.2.stepspace 35200
|
||||
setp stepgen.2.dirsetup 35200
|
||||
setp stepgen.2.dirhold 35200
|
||||
|
||||
# Set stepgen module scaling - get values from ini file
|
||||
setp stepgen.0.position-scale [JOINT_0]SCALE
|
||||
setp stepgen.1.position-scale [JOINT_1]SCALE
|
||||
setp stepgen.2.position-scale [JOINT_2]SCALE
|
||||
setp stepgen.3.position-scale [JOINT_3]SCALE
|
||||
|
||||
# Set stepgen module velocity limits - get values from ini file
|
||||
|
||||
# Set stepgen module accel limits - get values from ini file
|
||||
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
|
||||
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
|
||||
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
|
||||
setp stepgen.3.maxaccel [JOINT_3]STEPGEN_MAXACCEL
|
||||
|
||||
# Hook up stepgen to motion modules
|
||||
net PosX-cmd joint.0.motor-pos-cmd => stepgen.0.position-cmd
|
||||
net PosX-fb stepgen.0.position-fb => joint.0.motor-pos-fb
|
||||
net PosY-cmd joint.1.motor-pos-cmd => stepgen.1.position-cmd
|
||||
net PosY-fb stepgen.1.position-fb => joint.1.motor-pos-fb
|
||||
net PosZ-cmd joint.2.motor-pos-cmd => stepgen.2.position-cmd
|
||||
net PosZ-fb stepgen.2.position-fb => joint.2.motor-pos-fb
|
||||
net PosA-cmd joint.3.motor-pos-cmd => stepgen.3.position-cmd
|
||||
net PosA-fb stepgen.3.position-fb => joint.3.motor-pos-fb
|
||||
|
||||
# Hook up enable signals for step generators
|
||||
net EnableX joint.0.amp-enable-out => stepgen.0.enable
|
||||
net EnableY joint.1.amp-enable-out => stepgen.1.enable
|
||||
net EnableZ joint.2.amp-enable-out => stepgen.2.enable
|
||||
net EnableA joint.3.amp-enable-out => stepgen.3.enable
|
||||
4
configs/by_interface/parport/stepper-gantry/stepper.tbl
Normal file
4
configs/by_interface/parport/stepper-gantry/stepper.tbl
Normal file
@@ -0,0 +1,4 @@
|
||||
T1 P1 D0.125000 Z+0.511000 ;1/8 end mill
|
||||
T2 P2 D0.062500 Z+0.100000 ;1/16 end mill
|
||||
T3 P3 D0.201000 Z+1.273000 ;#7 tap drill
|
||||
T99999 P99999 Z+0.100000 ;big tool number
|
||||
248
configs/by_interface/parport/stepper-gantry/stepper_mm.ini
Normal file
248
configs/by_interface/parport/stepper-gantry/stepper_mm.ini
Normal file
@@ -0,0 +1,248 @@
|
||||
# EMC controller parameters for a plasma controller. Make these what you need
|
||||
# for your system.
|
||||
# General note: Comments can either be preceded with a # or ; - either is
|
||||
# acceptable, although # is in keeping with most linux config files.
|
||||
# Settings with a + at the front of the comment are likely needed to get
|
||||
# changed by the user.
|
||||
# Settings with a - at the front are highly unneeded to be changed
|
||||
###############################################################################
|
||||
# General section
|
||||
###############################################################################
|
||||
|
||||
[EMC]
|
||||
#- Version of this INI file
|
||||
VERSION = 1.1
|
||||
#+ Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-STEPPER-GANTRY
|
||||
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
DEBUG = 0
|
||||
#DEBUG = 0x00000007
|
||||
#DEBUG = 0x7FFFFFFF
|
||||
# Enable Adaptive Feedrate for THC
|
||||
# Used to pause execution of gcode for setup,
|
||||
# pierce delay and manual verification of pierce height
|
||||
# Set spindle speed to 1
|
||||
# Set up to use metric mm
|
||||
RS274NGC_STARTUP_CODE = M52 P1 G21 S1
|
||||
###############################################################################
|
||||
# Sections for display options
|
||||
###############################################################################
|
||||
|
||||
[DISPLAY]
|
||||
#+ Name of display program, e.g., axis
|
||||
DISPLAY = axis
|
||||
#DISPLAY = tklinuxcnc
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
CYCLE_TIME = 0.200
|
||||
#- Path to help file
|
||||
HELP_FILE = doc/help.txt
|
||||
#HELP_FILE = tklinuxcnc.txt
|
||||
#- Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
#- Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
#+ Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 1.5
|
||||
#- Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
#- Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 3
|
||||
#Increments for the JOB Section
|
||||
INCREMENTS = 1000 10 1 0.1 0.01
|
||||
# Editor to be used with Axis
|
||||
#EDITOR = geany
|
||||
###############################################################################
|
||||
# Task controller section
|
||||
###############################################################################
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
#- File containing interpreter variables
|
||||
PARAMETER_FILE = stepper.var
|
||||
###############################################################################
|
||||
# Motion control section
|
||||
###############################################################################
|
||||
|
||||
[EMCMOT]
|
||||
#- Name of the motion controller to use (only one exists for nontrivkins)
|
||||
EMCMOT = motmod
|
||||
#- Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
#+ Base task period, in nanosecs - this is the fastest thread in the machine
|
||||
#BASE_PERIOD = 15000
|
||||
#BASE_PERIOD = 18000
|
||||
#BASE_PERIOD = 20000
|
||||
BASE_PERIOD = 35000
|
||||
#BASE_PERIOD = 50000
|
||||
#- Servo task period, in nanosecs - will be rounded to an int multiple of BASE_PERIOD
|
||||
SERVO_PERIOD = 100000
|
||||
###############################################################################
|
||||
# Hardware Abstraction Layer section
|
||||
###############################################################################
|
||||
|
||||
[TASK]
|
||||
# Name of task controller program, e.g., milltask
|
||||
TASK = milltask
|
||||
#- Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.100
|
||||
###############################################################################
|
||||
# Part program interpreter section
|
||||
###############################################################################
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# HALUI to interact with NML
|
||||
# Run before any other HALFILE
|
||||
HALUI = halui
|
||||
# list of hal config files to run through halcmd
|
||||
#+ files are executed in the order in which they appear
|
||||
HALFILE = kinematics.hal
|
||||
HALFILE = stepper.hal
|
||||
HALFILE = stepper_parport.hal
|
||||
HALFILE = estop.hal
|
||||
#- list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
###############################################################################
|
||||
# Trajectory planner section
|
||||
###############################################################################
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
#+ machine specific settings
|
||||
COORDINATES = X Y Z A
|
||||
LINEAR_UNITS = mm
|
||||
ANGULAR_UNITS = deg
|
||||
DEFAULT_LINEAR_VELOCITY = 100
|
||||
MAX_LINEAR_VELOCITY = 180
|
||||
DEFAULT_LINEAR_ACCELERATION = 600
|
||||
MAX_LINEAR_ACCELERATION = 2400
|
||||
###############################################################################
|
||||
# Axes sections
|
||||
###############################################################################
|
||||
#+ First axis (X)
|
||||
|
||||
[EMCIO]
|
||||
# A Tooltable file
|
||||
TOOL_TABLE = stepper.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins coordinates=XYZA kinstype=BOTH
|
||||
JOINTS = 4
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 2055
|
||||
MAX_VELOCITY = 170
|
||||
MAX_ACCELERATION = 2400
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 170
|
||||
MAX_ACCELERATION = 2400
|
||||
STEPGEN_MAXACCEL = 2960
|
||||
BACKLASH = 0.000
|
||||
SCALE = 150.333
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 2055
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = -50.0
|
||||
HOME_LATCH_VEL = 1.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 1
|
||||
#+ Second axis (Y)
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 6050.0
|
||||
MAX_VELOCITY = 170
|
||||
MAX_ACCELERATION = 2400
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 170
|
||||
MAX_ACCELERATION = 2400
|
||||
STEPGEN_MAXACCEL = 2960
|
||||
BACKLASH = 0.000
|
||||
SCALE = 150.333
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 6050.0
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = -50.0
|
||||
HOME_LATCH_VEL = 1.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 1
|
||||
#+ Third axis (Z)
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 56.0
|
||||
MAX_VELOCITY = 8
|
||||
MAX_ACCELERATION = 600
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 55.000
|
||||
MAX_VELOCITY = 8
|
||||
MAX_ACCELERATION = 600
|
||||
STEPGEN_MAXACCEL = 650
|
||||
#STEPGEN_MAXACCEL = 2960
|
||||
BACKLASH = 0.000
|
||||
SCALE = 200
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 56.0
|
||||
FERROR = 1.270
|
||||
#MIN_FERROR = 0.254
|
||||
# This is done so Z axis can be operated with a HAL closed loop (plasma THC)
|
||||
MIN_FERROR = 500
|
||||
HOME_OFFSET = 55.0
|
||||
HOME_SEARCH_VEL = 10.0
|
||||
HOME_LATCH_VEL = -2.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 0
|
||||
#+ Second axis (A)
|
||||
|
||||
[AXIS_A]
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 6050.0
|
||||
MAX_VELOCITY = 170
|
||||
MAX_ACCELERATION = 2400
|
||||
|
||||
[JOINT_3]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 170
|
||||
MAX_ACCELERATION = 2400
|
||||
STEPGEN_MAXACCEL = 2960
|
||||
BACKLASH = 0.000
|
||||
SCALE = 150.333
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -1
|
||||
MAX_LIMIT = 6050.0
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = -50.0
|
||||
HOME_LATCH_VEL = 1.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = YES
|
||||
HOME_SEQUENCE = 1
|
||||
###############################################################################
|
||||
# section for main IO controller parameters
|
||||
###############################################################################
|
||||
@@ -0,0 +1,34 @@
|
||||
############################# Parallel Ports ##############################################
|
||||
|
||||
# Load Driver for Two Parallel Ports, one for Breakout Board, other for Plasma Torch Height Control
|
||||
loadrt hal_parport cfg="0xa400 0xac00"
|
||||
|
||||
# Connect both Parallel Ports to Threads for Read / Write
|
||||
addf parport.0.read base-thread 1
|
||||
addf parport.0.write base-thread -1
|
||||
addf parport.1.read base-thread 1
|
||||
addf parport.1.write base-thread -1
|
||||
|
||||
# Invert pins to make motors move in right direction
|
||||
setp parport.0.pin-06-out-invert 1
|
||||
setp parport.0.pin-07-out-invert 1
|
||||
|
||||
# Hook up the step and dir signals to the parport pins
|
||||
# Axis A and Y are the same axis but different motors
|
||||
net StepX stepgen.0.step => parport.0.pin-02-out
|
||||
net StepY stepgen.1.step => parport.0.pin-03-out
|
||||
net StepZ stepgen.2.step => parport.0.pin-04-out
|
||||
net StepA stepgen.3.step => parport.0.pin-05-out
|
||||
net DirX stepgen.0.dir => parport.0.pin-06-out
|
||||
net DirY stepgen.1.dir => parport.0.pin-07-out
|
||||
net DirZ stepgen.2.dir => parport.0.pin-08-out
|
||||
net DirA stepgen.3.dir => parport.0.pin-09-out
|
||||
|
||||
# Hook up limit and home switches, each axis shares a common pin for homing, limit min and limit max
|
||||
net LimitX parport.0.pin-11-in-not => joint.0.neg-lim-sw-in joint.0.pos-lim-sw-in joint.0.home-sw-in
|
||||
net LimitY parport.0.pin-12-in-not => joint.1.neg-lim-sw-in joint.1.pos-lim-sw-in joint.1.home-sw-in
|
||||
#net LimitZ parport.0.pin-13-in => joint.2.neg-lim-sw-in joint.2.pos-lim-sw-in joint.2.home-sw-in
|
||||
net LimitA parport.0.pin-15-in-not => joint.3.neg-lim-sw-in joint.3.pos-lim-sw-in joint.3.home-sw-in
|
||||
|
||||
# Hook up the spindle signal
|
||||
net SpindleOn spindle.0.forward => parport.1.pin-01-out
|
||||
@@ -0,0 +1,34 @@
|
||||
############################# Parallel Ports ##############################################
|
||||
|
||||
# Load Driver for Two Parallel Ports, one for Breakout Board, other for Plasma Torch Height Control
|
||||
loadrt hal_parport cfg="0xa400 0xac00"
|
||||
|
||||
# Connect both Parallel Ports to Threads for Read / Write
|
||||
addf parport.0.read base-thread 1
|
||||
addf parport.0.write base-thread -1
|
||||
addf parport.1.read base-thread 1
|
||||
addf parport.1.write base-thread -1
|
||||
|
||||
# Invert pins to make motors move in right direction
|
||||
setp parport.0.pin-06-out-invert 1
|
||||
setp parport.0.pin-07-out-invert 1
|
||||
|
||||
# Hook up the step and dir signals to the parport pins
|
||||
# Axis A and Y are the same axis but different motors
|
||||
net StepX stepgen.0.step => parport.0.pin-02-out
|
||||
net StepY stepgen.1.step => parport.0.pin-03-out
|
||||
net StepZ stepgen.2.step => parport.0.pin-04-out
|
||||
net StepA stepgen.3.step => parport.0.pin-05-out
|
||||
net DirX stepgen.0.dir => parport.0.pin-06-out
|
||||
net DirY stepgen.1.dir => parport.0.pin-07-out
|
||||
net DirZ stepgen.2.dir => parport.0.pin-08-out
|
||||
net DirA stepgen.3.dir => parport.0.pin-09-out
|
||||
|
||||
# Hook up limit and home switches, each axis shares a common pin for homing, limit min and limit max
|
||||
net LimitX parport.0.pin-11-in-not => joint.0.neg-lim-sw-in joint.0.pos-lim-sw-in joint.0.home-sw-in
|
||||
net LimitY parport.0.pin-12-in-not => joint.1.neg-lim-sw-in joint.1.pos-lim-sw-in joint.1.home-sw-in
|
||||
net LimitZ parport.0.pin-13-in => joint.2.neg-lim-sw-in joint.2.pos-lim-sw-in joint.2.home-sw-in
|
||||
net LimitA parport.0.pin-15-in-not => joint.3.neg-lim-sw-in joint.3.pos-lim-sw-in joint.3.home-sw-in
|
||||
|
||||
# Hook up the spindle signal
|
||||
net SpindleOn motion.spindle-forward => parport.1.pin-01-out
|
||||
19
configs/by_interface/parport/stepper-xyza/README
Normal file
19
configs/by_interface/parport/stepper-xyza/README
Normal file
@@ -0,0 +1,19 @@
|
||||
This configuration step is intended for basic stepper machines with a rotary table.
|
||||
|
||||
You can have standard pinout (LinuxCNC style), look at stepper/ for a 'xylotex standard' example. Certainly you could make a new one which would suit your own custom cabling.
|
||||
|
||||
Detailed description:
|
||||
|
||||
* ini files
|
||||
|
||||
-- inch.ini - inch setup for a stepper machine
|
||||
|
||||
* nml files
|
||||
|
||||
-- it uses a default nml file (found in configs/common/linuxcnc.nml)
|
||||
|
||||
* hal files
|
||||
|
||||
-- it uses a default stepper hal file (configs/common/core_stepper.hal)
|
||||
|
||||
-- standard_pinout.hal - include this from the ini to get you a standard pinout
|
||||
240
configs/by_interface/parport/stepper-xyza/inch.ini
Normal file
240
configs/by_interface/parport/stepper-xyza/inch.ini
Normal file
@@ -0,0 +1,240 @@
|
||||
# EMC controller parameters for generic controller. Make these what you need
|
||||
# for your system.
|
||||
# General note: Comments can either be preceded with a # or ; - either is
|
||||
# acceptable, although # is in keeping with most linux config files.
|
||||
# Settings with a + at the front of the comment are likely needed to get
|
||||
# changed by the user.
|
||||
# Settings with a - at the front are highly unneeded to be changed
|
||||
###############################################################################
|
||||
# General section
|
||||
###############################################################################
|
||||
|
||||
[EMC]
|
||||
#- Version of this INI file
|
||||
VERSION = 1.1
|
||||
#+ Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-HAL-STEP-XYZA-IN
|
||||
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
DEBUG = 0
|
||||
# DEBUG = 0x00000007
|
||||
# DEBUG = 0x7FFFFFFF
|
||||
###############################################################################
|
||||
# Sections for display options
|
||||
###############################################################################
|
||||
|
||||
[DISPLAY]
|
||||
#+ Name of display program, e.g., axis
|
||||
DISPLAY = axis
|
||||
# DISPLAY = tklinuxcnc
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
CYCLE_TIME = 0.200
|
||||
#- Path to help file
|
||||
HELP_FILE = tklinuxcnc.txt
|
||||
#- Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
#- Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
#+ Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 9.0
|
||||
#- Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
#- Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
# Editor to be used with Axis
|
||||
#EDITOR = geany
|
||||
GEOMETRY = AXYZ
|
||||
###############################################################################
|
||||
# Task controller section
|
||||
###############################################################################
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
#- File containing interpreter variables
|
||||
PARAMETER_FILE = stepper.var
|
||||
###############################################################################
|
||||
# Motion control section
|
||||
###############################################################################
|
||||
|
||||
[EMCMOT]
|
||||
#- Name of the motion controller to use (only one exists for nontrivkins)
|
||||
EMCMOT = motmod
|
||||
#- Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
#+ Base task period, in nanosecs - this is the fastest thread in the machine
|
||||
BASE_PERIOD = 50000
|
||||
#- Servo task period, in nanosecs - will be rounded to an int multiple of BASE_PERIOD
|
||||
SERVO_PERIOD = 1000000
|
||||
###############################################################################
|
||||
# Hardware Abstraction Layer section
|
||||
###############################################################################
|
||||
|
||||
[TASK]
|
||||
# Name of task controller program, e.g., milltask
|
||||
TASK = milltask
|
||||
#- Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.010
|
||||
###############################################################################
|
||||
# Part program interpreter section
|
||||
###############################################################################
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# list of hal config files to run through halcmd
|
||||
#+ files are executed in the order in which they appear
|
||||
HALFILE = stepper_xyza.hal
|
||||
#HALFILE = xylotex_pinout.hal
|
||||
HALFILE = standard_pinout.hal
|
||||
#- list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
###############################################################################
|
||||
# Trajectory planner section
|
||||
###############################################################################
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
#+ machine specific settings
|
||||
# COORDINATES = X Y Z R P W
|
||||
COORDINATES = X Y Z A
|
||||
HOME = 0 0 0
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = .2
|
||||
DEFAULT_ANGULAR_VELOCITY = 30
|
||||
MAX_LINEAR_VELOCITY = 1.2
|
||||
MAX_ANGULAR_VELOCITY = 90
|
||||
DEFAULT_LINEAR_ACCELERATION = 20.0
|
||||
MAX_LINEAR_ACCELERATION = 400.0
|
||||
###############################################################################
|
||||
# Axes sections
|
||||
###############################################################################
|
||||
#+ First axis
|
||||
|
||||
[EMCIO]
|
||||
#- tool table file
|
||||
TOOL_TABLE = stepper.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 4
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.2
|
||||
# NOTE: the step generator module applies its own limits to
|
||||
# acceleration and velocity. We have discovered that it needs
|
||||
# to have a little "headroom" over the accel by the trajectory
|
||||
# planner, otherwise it can fall slightly behind during accel
|
||||
# and later overshoot as it catches up. In the long term we
|
||||
# hope to come up with a clean fix for this problem. In the
|
||||
# meantime, please set STEPGEN_MAXACCEL below to a few percent
|
||||
# higher than the regular acceleration limit MAX_ACCELERATION
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 20.2
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Second axis
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 20.2
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Third axis
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -2.0
|
||||
MAX_LIMIT = 4.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 20.2
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -2.0
|
||||
MAX_LIMIT = 4.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Third axis
|
||||
|
||||
[AXIS_A]
|
||||
MIN_LIMIT = -36000.0
|
||||
MAX_LIMIT = 36000.0
|
||||
MAX_VELOCITY = 90.0
|
||||
MAX_ACCELERATION = 360.0
|
||||
|
||||
[JOINT_3]
|
||||
TYPE = ANGULAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 90.0
|
||||
MAX_ACCELERATION = 360.0
|
||||
STEPGEN_MAXACCEL = 396.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 40
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -36000.0
|
||||
MAX_LIMIT = 36000.0
|
||||
FERROR = 5.0
|
||||
MIN_FERROR = 1.0
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
###############################################################################
|
||||
# section for main IO controller parameters
|
||||
###############################################################################
|
||||
@@ -0,0 +1,39 @@
|
||||
# standard pinout config file for 3-axis steppers
|
||||
# using a parport for I/O
|
||||
#
|
||||
# first load the parport driver
|
||||
loadrt hal_parport cfg="0x0378"
|
||||
#
|
||||
# next connect the parport functions to threads
|
||||
# read inputs first
|
||||
addf parport.0.read base-thread 1
|
||||
# write outputs last
|
||||
addf parport.0.write base-thread -1
|
||||
#
|
||||
# finally connect physical pins to the signals
|
||||
net Xstep parport.0.pin-03-out
|
||||
net Xdir parport.0.pin-02-out
|
||||
net Ystep parport.0.pin-05-out
|
||||
net Ydir parport.0.pin-04-out
|
||||
net Zstep parport.0.pin-07-out
|
||||
net Zdir parport.0.pin-06-out
|
||||
net Astep parport.0.pin-09-out
|
||||
net Adir parport.0.pin-08-out
|
||||
|
||||
|
||||
# create a signal for the estop loopback
|
||||
net estop-loop iocontrol.0.user-enable-out iocontrol.0.emc-enable-in
|
||||
|
||||
# create signals for tool loading loopback
|
||||
net tool-prep-loop iocontrol.0.tool-prepare iocontrol.0.tool-prepared
|
||||
net tool-change-loop iocontrol.0.tool-change iocontrol.0.tool-changed
|
||||
|
||||
# create a signal for "spindle on"
|
||||
|
||||
# commented out till we resolve this issue
|
||||
# connect it to the iocontroller
|
||||
net spindle_on spindle.0.on
|
||||
# connect it to a physical pin
|
||||
net spindle_on parport.0.pin-01-out
|
||||
|
||||
|
||||
4
configs/by_interface/parport/stepper-xyza/stepper.tbl
Normal file
4
configs/by_interface/parport/stepper-xyza/stepper.tbl
Normal file
@@ -0,0 +1,4 @@
|
||||
T1 P1 D0.125000 Z+0.511000 ;1/8 end mill
|
||||
T2 P2 D0.062500 Z+0.100000 ;1/16 end mill
|
||||
T3 P3 D0.201000 Z+1.273000 ;#7 tap drill
|
||||
T99999 P99999 Z+0.100000 ;big tool number
|
||||
100
configs/by_interface/parport/stepper-xyza/stepper_xyza.hal
Normal file
100
configs/by_interface/parport/stepper-xyza/stepper_xyza.hal
Normal file
@@ -0,0 +1,100 @@
|
||||
# core HAL config file for steppers
|
||||
|
||||
# first load the core RT modules that will be needed
|
||||
# kinematics
|
||||
loadrt [KINS]KINEMATICS
|
||||
# motion controller, get name and thread periods from ini file
|
||||
loadrt [EMCMOT]EMCMOT base_period_nsec=[EMCMOT]BASE_PERIOD servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
|
||||
# stepper module
|
||||
loadrt stepgen step_type=0,0,0,0
|
||||
|
||||
# hook its functions to realtime threads
|
||||
addf stepgen.make-pulses base-thread
|
||||
addf stepgen.capture-position servo-thread
|
||||
addf motion-command-handler servo-thread
|
||||
addf motion-controller servo-thread
|
||||
addf stepgen.update-freq servo-thread
|
||||
|
||||
# connect position commands from motion module to step generator
|
||||
net Xpos-cmd <= joint.0.motor-pos-cmd
|
||||
net Xpos-cmd => stepgen.0.position-cmd
|
||||
net Ypos-cmd <= joint.1.motor-pos-cmd
|
||||
net Ypos-cmd => stepgen.1.position-cmd
|
||||
net Zpos-cmd <= joint.2.motor-pos-cmd
|
||||
net Zpos-cmd => stepgen.2.position-cmd
|
||||
net Apos-cmd <= joint.3.motor-pos-cmd
|
||||
net Apos-cmd => stepgen.3.position-cmd
|
||||
|
||||
# connect position feedback from step generators
|
||||
# to motion module
|
||||
net Xpos-fb <= stepgen.0.position-fb
|
||||
net Xpos-fb => joint.0.motor-pos-fb
|
||||
net Ypos-fb <= stepgen.1.position-fb
|
||||
net Ypos-fb => joint.1.motor-pos-fb
|
||||
net Zpos-fb <= stepgen.2.position-fb
|
||||
net Zpos-fb => joint.2.motor-pos-fb
|
||||
net Apos-fb <= stepgen.3.position-fb
|
||||
net Apos-fb => joint.3.motor-pos-fb
|
||||
|
||||
# send the position commands thru differentiators to
|
||||
# generate velocity and accel signals
|
||||
# first 8 differentiators
|
||||
loadrt ddt count=8
|
||||
# link the differentiator functions into the code
|
||||
addf ddt.0 servo-thread
|
||||
addf ddt.1 servo-thread
|
||||
addf ddt.2 servo-thread
|
||||
addf ddt.3 servo-thread
|
||||
addf ddt.4 servo-thread
|
||||
addf ddt.5 servo-thread
|
||||
addf ddt.6 servo-thread
|
||||
addf ddt.7 servo-thread
|
||||
# define the signals, and hook them up
|
||||
net Xpos-cmd => ddt.0.in
|
||||
net Xvel <= ddt.0.out
|
||||
net Xvel => ddt.1.in
|
||||
net Xacc <= ddt.1.out
|
||||
net Ypos-cmd => ddt.2.in
|
||||
net Yvel <= ddt.2.out
|
||||
net Yvel => ddt.3.in
|
||||
net Yacc <= ddt.3.out
|
||||
net Zpos-cmd => ddt.4.in
|
||||
net Zvel <= ddt.4.out
|
||||
net Zvel => ddt.5.in
|
||||
net Zacc <= ddt.5.out
|
||||
net Apos-cmd => ddt.6.in
|
||||
net Avel <= ddt.6.out
|
||||
net Avel => ddt.7.in
|
||||
net Aacc <= ddt.7.out
|
||||
|
||||
# connect enable signals for step generators
|
||||
net Xen <= joint.0.amp-enable-out
|
||||
net Xen => stepgen.0.enable
|
||||
net Yen <= joint.1.amp-enable-out
|
||||
net Yen => stepgen.1.enable
|
||||
net Zen <= joint.2.amp-enable-out
|
||||
net Zen => stepgen.2.enable
|
||||
net Aen <= joint.3.amp-enable-out
|
||||
net Aen => stepgen.3.enable
|
||||
|
||||
# connect signals to step pulse generator outputs
|
||||
net Xstep stepgen.0.step
|
||||
net Xdir stepgen.0.dir
|
||||
net Ystep stepgen.1.step
|
||||
net Ydir stepgen.1.dir
|
||||
net Zstep stepgen.2.step
|
||||
net Zdir stepgen.2.dir
|
||||
net Astep stepgen.3.step
|
||||
net Adir stepgen.3.dir
|
||||
|
||||
# set stepgen module scaling - get values from ini file
|
||||
setp stepgen.0.position-scale [JOINT_0]SCALE
|
||||
setp stepgen.1.position-scale [JOINT_1]SCALE
|
||||
setp stepgen.2.position-scale [JOINT_2]SCALE
|
||||
setp stepgen.3.position-scale [JOINT_3]SCALE
|
||||
|
||||
# set stepgen module accel limits - get values from ini file
|
||||
setp stepgen.0.maxaccel [JOINT_0]STEPGEN_MAXACCEL
|
||||
setp stepgen.1.maxaccel [JOINT_1]STEPGEN_MAXACCEL
|
||||
setp stepgen.2.maxaccel [JOINT_2]STEPGEN_MAXACCEL
|
||||
setp stepgen.3.maxaccel [JOINT_3]STEPGEN_MAXACCEL
|
||||
28
configs/by_interface/parport/stepper/README
Normal file
28
configs/by_interface/parport/stepper/README
Normal file
@@ -0,0 +1,28 @@
|
||||
This configuration step is intended for basic stepper machines.
|
||||
You can have either standard pinout (LinuxCNC style) or xylotex pinout, by including either one of those 2 .hal files. Certainly you could make a new one which would suit your own custom cabling.
|
||||
|
||||
There are 3 ini files, one for inch setups (stepper_in.ini) and one for metric setups (stepper_mm.ini). Additionally there is one (sim_inch.ini) which doesn't output steps to the parport but to the PC speaker. That way you can "hear" if it's running OK.
|
||||
|
||||
Detailed description:
|
||||
|
||||
* ini files
|
||||
|
||||
-- stepper_inch.ini - inch setup for a stepper machine
|
||||
|
||||
-- stepper_mm.ini - metric setup for a stepper machine
|
||||
|
||||
-- sim_inch.ini - inch setup with steps routed to the PC speaker instead of parport
|
||||
|
||||
* nml files
|
||||
|
||||
-- it uses a default nml file (found in configs/common/linuxcnc.nml)
|
||||
|
||||
* hal files
|
||||
|
||||
-- it uses a default stepper hal file (configs/common/core_stepper.hal)
|
||||
|
||||
-- standard_pinout.hal - include this from the ini to get you a standard pinout
|
||||
|
||||
-- xylotex_pinout.hal - include this from the ini to get you a xylotex pinout (e.g. step/dir are inverted)
|
||||
|
||||
-- sim_pinout.hal - include this in your ini to route step/dir signals to the PC speaker not parport
|
||||
211
configs/by_interface/parport/stepper/sim_inch.ini
Normal file
211
configs/by_interface/parport/stepper/sim_inch.ini
Normal file
@@ -0,0 +1,211 @@
|
||||
# EMC controller parameters for generic controller. Make these what you need
|
||||
# for your system.
|
||||
# General note: Comments can either be preceded with a # or ; - either is
|
||||
# acceptable, although # is in keeping with most linux config files.
|
||||
# Settings with a + at the front of the comment are likely needed to get
|
||||
# changed by the user.
|
||||
# Settings with a - at the front are highly unneeded to be changed
|
||||
###############################################################################
|
||||
# General section
|
||||
###############################################################################
|
||||
|
||||
[EMC]
|
||||
#- Version of this INI file
|
||||
VERSION = 1.1
|
||||
#+ Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-HAL-STEP-SIM
|
||||
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
DEBUG = 0
|
||||
# DEBUG = 0x00000007
|
||||
# DEBUG = 0x7FFFFFFF
|
||||
###############################################################################
|
||||
# Sections for display options
|
||||
###############################################################################
|
||||
|
||||
[DISPLAY]
|
||||
#+ Name of display program, e.g., axis
|
||||
# DISPLAY = axis
|
||||
DISPLAY = axis
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
CYCLE_TIME = 0.200
|
||||
#- Path to help file
|
||||
HELP_FILE = doc/help.txt
|
||||
#- Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
#- Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
#+ Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 1.2
|
||||
#- Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
#- Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
# Editor to be used with Axis
|
||||
#EDITOR = geany
|
||||
###############################################################################
|
||||
# Task controller section
|
||||
###############################################################################
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
#- File containing interpreter variables
|
||||
PARAMETER_FILE = stepper.var
|
||||
###############################################################################
|
||||
# Motion control section
|
||||
###############################################################################
|
||||
|
||||
[EMCMOT]
|
||||
#- Name of the motion controller to use (only one exists for nontrivkins)
|
||||
EMCMOT = motmod
|
||||
#- Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
#+ Base task period, in nanosecs - this is the fastest thread in the machine
|
||||
BASE_PERIOD = 50000
|
||||
#- Servo task period, in nanosecs - will be rounded to an int multiple of BASE_PERIOD
|
||||
SERVO_PERIOD = 1000000
|
||||
###############################################################################
|
||||
# Hardware Abstraction Layer section
|
||||
###############################################################################
|
||||
|
||||
[TASK]
|
||||
# Name of task controller program, e.g., milltask
|
||||
TASK = milltask
|
||||
#- Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.010
|
||||
###############################################################################
|
||||
# Part program interpreter section
|
||||
###############################################################################
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# list of hal config files to run through halcmd
|
||||
#+ files are executed in the order in which they appear
|
||||
HALFILE = core_stepper.hal
|
||||
#HALFILE = xylotex_pinout.hal
|
||||
HALFILE = sim_pinout.hal
|
||||
#- list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
###############################################################################
|
||||
# Trajectory planner section
|
||||
###############################################################################
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
#+ machine specific settings
|
||||
# COORDINATES = X Y Z A B C
|
||||
COORDINATES = X Y Z
|
||||
HOME = 0 0 0
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 1.2
|
||||
MAX_LINEAR_VELOCITY = 1.2
|
||||
DEFAULT_LINEAR_ACCELERATION = 15.0
|
||||
MAX_LINEAR_ACCELERATION = 20.0
|
||||
###############################################################################
|
||||
# Axes sections
|
||||
###############################################################################
|
||||
#+ First axis
|
||||
|
||||
[EMCIO]
|
||||
#- tool table file
|
||||
TOOL_TABLE = stepper.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.2
|
||||
# NOTE: the step generator module applies its own limits to
|
||||
# acceleration and velocity. We have discovered that it needs
|
||||
# to have a little "headroom" over the accel by the trajectory
|
||||
# planner, otherwise it can fall slightly behind during accel
|
||||
# and later overshoot as it catches up. In the long term we
|
||||
# hope to come up with a clean fix for this problem. In the
|
||||
# meantime, please set STEPGEN_MAXACCEL below to a few percent
|
||||
# higher than the regular acceleration limit MAX_ACCELERATION
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Second axis
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Third axis
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -2.0
|
||||
MAX_LIMIT = 4.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -2.0
|
||||
MAX_LIMIT = 4.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
###############################################################################
|
||||
# section for main IO controller parameters
|
||||
###############################################################################
|
||||
24
configs/by_interface/parport/stepper/sim_pinout.hal
Normal file
24
configs/by_interface/parport/stepper/sim_pinout.hal
Normal file
@@ -0,0 +1,24 @@
|
||||
# standard pinout config file for 3-axis steppers
|
||||
# using a parport for I/O
|
||||
#
|
||||
# first load the parport driver
|
||||
loadrt hal_speaker
|
||||
#
|
||||
# next connect the parport functions to threads
|
||||
# write outputs last
|
||||
addf speaker.0.write base-thread 1
|
||||
#
|
||||
# finally connect physical pins to the signals
|
||||
net Xstep => speaker.0.pin-03-out
|
||||
net Xdir => speaker.0.pin-02-out
|
||||
net Ystep => speaker.0.pin-05-out
|
||||
net Ydir => speaker.0.pin-04-out
|
||||
net Zstep => speaker.0.pin-07-out
|
||||
net Zdir => speaker.0.pin-06-out
|
||||
|
||||
# create a signal for the estop loopback
|
||||
net estop-loop iocontrol.0.user-enable-out => iocontrol.0.emc-enable-in
|
||||
|
||||
# create signals for tool loading loopback
|
||||
net tool-prep-loop iocontrol.0.tool-prepare => iocontrol.0.tool-prepared
|
||||
net tool-change-loop iocontrol.0.tool-change => iocontrol.0.tool-changed
|
||||
77
configs/by_interface/parport/stepper/standard_pinout.hal
Normal file
77
configs/by_interface/parport/stepper/standard_pinout.hal
Normal file
@@ -0,0 +1,77 @@
|
||||
# standard pinout config file for 3-axis steppers
|
||||
# using a parport for I/O
|
||||
#
|
||||
# first load the parport driver
|
||||
loadrt hal_parport cfg="0x0378"
|
||||
#
|
||||
# next connect the parport functions to threads
|
||||
# read inputs first
|
||||
addf parport.0.read base-thread 1
|
||||
# write outputs last
|
||||
addf parport.0.write base-thread -1
|
||||
#
|
||||
# finally connect physical pins to the signals
|
||||
net Xstep => parport.0.pin-03-out
|
||||
net Xdir => parport.0.pin-02-out
|
||||
net Ystep => parport.0.pin-05-out
|
||||
net Ydir => parport.0.pin-04-out
|
||||
net Zstep => parport.0.pin-07-out
|
||||
net Zdir => parport.0.pin-06-out
|
||||
|
||||
# create a signal for the estop loopback
|
||||
net estop-loop iocontrol.0.user-enable-out iocontrol.0.emc-enable-in
|
||||
|
||||
# create signals for tool loading loopback
|
||||
net tool-prep-loop iocontrol.0.tool-prepare iocontrol.0.tool-prepared
|
||||
net tool-change-loop iocontrol.0.tool-change iocontrol.0.tool-changed
|
||||
|
||||
# connect "spindle on" motion controller pin to a physical pin
|
||||
net spindle-on spindle.0.on => parport.0.pin-09-out
|
||||
|
||||
###
|
||||
### You might use something like this to enable chopper drives when machine ON
|
||||
### the Xen signal is defined in core_stepper.hal
|
||||
###
|
||||
|
||||
# net Xen => parport.0.pin-01-out
|
||||
|
||||
###
|
||||
### If you want active low for this pin, invert it like this:
|
||||
###
|
||||
|
||||
# setp parport.0.pin-01-out-invert 1
|
||||
|
||||
###
|
||||
### A sample home switch on the X axis (axis 0). make a signal,
|
||||
### link the incoming parport pin to the signal, then link the signal
|
||||
### to EMC's axis 0 home switch input pin
|
||||
###
|
||||
|
||||
# net Xhome parport.0.pin-10-in => joint.0.home-sw-in
|
||||
|
||||
###
|
||||
### Shared home switches all on one parallel port pin?
|
||||
### that's ok, hook the same signal to all the axes, but be sure to
|
||||
### set HOME_IS_SHARED and HOME_SEQUENCE in the ini file. See the
|
||||
### user manual!
|
||||
###
|
||||
|
||||
# net homeswitches <= parport.0.pin-10-in
|
||||
# net homeswitches => joint.0.home-sw-in
|
||||
# net homeswitches => joint.1.home-sw-in
|
||||
# net homeswitches => joint.2.home-sw-in
|
||||
|
||||
###
|
||||
### Sample separate limit switches on the X axis (axis 0)
|
||||
###
|
||||
|
||||
# net X-neg-limit parport.0.pin-11-in => joint.0.neg-lim-sw-in
|
||||
# net X-pos-limit parport.0.pin-12-in => joint.0.pos-lim-sw-in
|
||||
|
||||
###
|
||||
### Just like the shared home switches example, you can wire together
|
||||
### limit switches. Beware if you hit one, EMC will stop but can't tell
|
||||
### you which switch/axis has faulted. Use caution when recovering from this.
|
||||
###
|
||||
|
||||
# net Xlimits parport.0.pin-13-in => joint.0.neg-lim-sw-in joint.0.pos-lim-sw-in
|
||||
1
configs/by_interface/parport/stepper/stepper.tbl
Normal file
1
configs/by_interface/parport/stepper/stepper.tbl
Normal file
@@ -0,0 +1 @@
|
||||
T1 P1 D2 ;Added 20120119
|
||||
211
configs/by_interface/parport/stepper/stepper_inch.ini
Normal file
211
configs/by_interface/parport/stepper/stepper_inch.ini
Normal file
@@ -0,0 +1,211 @@
|
||||
# EMC controller parameters for generic controller. Make these what you need
|
||||
# for your system.
|
||||
# General note: Comments can either be preceded with a # or ; - either is
|
||||
# acceptable, although # is in keeping with most linux config files.
|
||||
# Settings with a + at the front of the comment are likely needed to get
|
||||
# changed by the user.
|
||||
# Settings with a - at the front are highly unneeded to be changed
|
||||
###############################################################################
|
||||
# General section
|
||||
###############################################################################
|
||||
|
||||
[EMC]
|
||||
#- Version of this INI file
|
||||
VERSION = 1.1
|
||||
#+ Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-HAL-STEP-IN
|
||||
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
DEBUG = 0
|
||||
# DEBUG = 0x00000007
|
||||
# DEBUG = 0x7FFFFFFF
|
||||
###############################################################################
|
||||
# Sections for display options
|
||||
###############################################################################
|
||||
|
||||
[DISPLAY]
|
||||
#+ Name of display program, e.g., axis
|
||||
DISPLAY = axis
|
||||
# DISPLAY = tklinuxcnc
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
CYCLE_TIME = 0.200
|
||||
#- Path to help file
|
||||
HELP_FILE = tklinuxcnc.txt
|
||||
#- Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
#- Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
#+ Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 1.2
|
||||
#- Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
#- Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
# Editor to be used with Axis
|
||||
#EDITOR = geany
|
||||
###############################################################################
|
||||
# Task controller section
|
||||
###############################################################################
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
#- File containing interpreter variables
|
||||
PARAMETER_FILE = stepper.var
|
||||
###############################################################################
|
||||
# Motion control section
|
||||
###############################################################################
|
||||
|
||||
[EMCMOT]
|
||||
#- Name of the motion controller to use (only one exists for nontrivkins)
|
||||
EMCMOT = motmod
|
||||
#- Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
#+ Base task period, in nanosecs - this is the fastest thread in the machine
|
||||
BASE_PERIOD = 50000
|
||||
#- Servo task period, in nanosecs - will be rounded to an int multiple of BASE_PERIOD
|
||||
SERVO_PERIOD = 1000000
|
||||
###############################################################################
|
||||
# Hardware Abstraction Layer section
|
||||
###############################################################################
|
||||
|
||||
[TASK]
|
||||
# Name of task controller program, e.g., milltask
|
||||
TASK = milltask
|
||||
#- Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.010
|
||||
###############################################################################
|
||||
# Part program interpreter section
|
||||
###############################################################################
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# list of hal config files to run through halcmd
|
||||
#+ files are executed in the order in which they appear
|
||||
HALFILE = core_stepper.hal
|
||||
#HALFILE = xylotex_pinout.hal
|
||||
HALFILE = standard_pinout.hal
|
||||
#- list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
###############################################################################
|
||||
# Trajectory planner section
|
||||
###############################################################################
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
#+ machine specific settings
|
||||
# COORDINATES = X Y Z A B C
|
||||
COORDINATES = X Y Z
|
||||
HOME = 0 0 0
|
||||
LINEAR_UNITS = inch
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 0.0167
|
||||
MAX_LINEAR_VELOCITY = 1.2
|
||||
DEFAULT_LINEAR_ACCELERATION = 15.0
|
||||
MAX_LINEAR_ACCELERATION = 20.0
|
||||
###############################################################################
|
||||
# Axes sections
|
||||
###############################################################################
|
||||
#+ First axis
|
||||
|
||||
[EMCIO]
|
||||
#- tool table file
|
||||
TOOL_TABLE = stepper.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.2
|
||||
# NOTE: the step generator module applies its own limits to
|
||||
# acceleration and velocity. We have discovered that it needs
|
||||
# to have a little "headroom" over the accel by the trajectory
|
||||
# planner, otherwise it can fall slightly behind during accel
|
||||
# and later overshoot as it catches up. In the long term we
|
||||
# hope to come up with a clean fix for this problem. In the
|
||||
# meantime, please set STEPGEN_MAXACCEL below to a few percent
|
||||
# higher than the regular acceleration limit MAX_ACCELERATION
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Second axis
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -10.0
|
||||
MAX_LIMIT = 10.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Third axis
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -2.0
|
||||
MAX_LIMIT = 4.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 1.2
|
||||
MAX_ACCELERATION = 20.0
|
||||
STEPGEN_MAXACCEL = 21.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 4000
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -2.0
|
||||
MAX_LIMIT = 4.0
|
||||
FERROR = 0.050
|
||||
MIN_FERROR = 0.010
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
###############################################################################
|
||||
# section for main IO controller parameters
|
||||
###############################################################################
|
||||
209
configs/by_interface/parport/stepper/stepper_mm.ini
Normal file
209
configs/by_interface/parport/stepper/stepper_mm.ini
Normal file
@@ -0,0 +1,209 @@
|
||||
# EMC controller parameters for generic controller. Make these what you need
|
||||
# for your system.
|
||||
# General note: Comments can either be preceded with a # or ; - either is
|
||||
# acceptable, although # is in keeping with most linux config files.
|
||||
# Settings with a + at the front of the comment are likely needed to get
|
||||
# changed by the user.
|
||||
# Settings with a - at the front are highly unneeded to be changed
|
||||
###############################################################################
|
||||
# General section
|
||||
###############################################################################
|
||||
|
||||
[EMC]
|
||||
#- Version of this INI file
|
||||
VERSION = 1.1
|
||||
#+ Name of machine, for use with display, etc.
|
||||
MACHINE = LinuxCNC-HAL-STEP-MM
|
||||
#+ Debug level, 0 means no messages. See src/emc/nml_int/emcglb.h for others
|
||||
DEBUG = 0
|
||||
# DEBUG = 0x00000007
|
||||
# DEBUG = 0x7FFFFFFF
|
||||
###############################################################################
|
||||
# Sections for display options
|
||||
###############################################################################
|
||||
|
||||
[DISPLAY]
|
||||
#+ Name of display program, e.g., axis
|
||||
DISPLAY = axis
|
||||
# DISPLAY = tklinuxcnc
|
||||
# Cycle time, in seconds, that display will sleep between polls
|
||||
CYCLE_TIME = 0.200
|
||||
#- Path to help file
|
||||
HELP_FILE = tklinuxcnc.txt
|
||||
#- Initial display setting for position, RELATIVE or MACHINE
|
||||
POSITION_OFFSET = RELATIVE
|
||||
#- Initial display setting for position, COMMANDED or ACTUAL
|
||||
POSITION_FEEDBACK = ACTUAL
|
||||
#+ Highest value that will be allowed for feed override, 1.0 = 100%
|
||||
MAX_FEED_OVERRIDE = 1.2
|
||||
#- Prefix to be used
|
||||
PROGRAM_PREFIX = ../../nc_files/
|
||||
#- Introductory graphic
|
||||
INTRO_GRAPHIC = linuxcnc.gif
|
||||
INTRO_TIME = 5
|
||||
###############################################################################
|
||||
# Task controller section
|
||||
###############################################################################
|
||||
|
||||
[FILTER]
|
||||
#No Content
|
||||
|
||||
[RS274NGC]
|
||||
#- File containing interpreter variables
|
||||
PARAMETER_FILE = stepper.var
|
||||
###############################################################################
|
||||
# Motion control section
|
||||
###############################################################################
|
||||
|
||||
[EMCMOT]
|
||||
#- Name of the motion controller to use (only one exists for nontrivkins)
|
||||
EMCMOT = motmod
|
||||
#- Timeout for comm to emcmot, in seconds
|
||||
COMM_TIMEOUT = 1.0
|
||||
#+ Base task period, in nanosecs - this is the fastest thread in the machine
|
||||
BASE_PERIOD = 50000
|
||||
#- Servo task period, in nanosecs - will be rounded to an int multiple of BASE_PERIOD
|
||||
SERVO_PERIOD = 1000000
|
||||
###############################################################################
|
||||
# Hardware Abstraction Layer section
|
||||
###############################################################################
|
||||
|
||||
[TASK]
|
||||
# Name of task controller program, e.g., milltask
|
||||
TASK = milltask
|
||||
#- Cycle time, in seconds, that task controller will sleep between polls
|
||||
CYCLE_TIME = 0.010
|
||||
###############################################################################
|
||||
# Part program interpreter section
|
||||
###############################################################################
|
||||
|
||||
[HAL]
|
||||
# The run script first uses halcmd to execute any HALFILE
|
||||
# files, and then to execute any individual HALCMD commands.
|
||||
#
|
||||
# list of hal config files to run through halcmd
|
||||
#+ files are executed in the order in which they appear
|
||||
HALFILE = core_stepper.hal
|
||||
#HALFILE = xylotex_pinout.hal
|
||||
HALFILE = standard_pinout.hal
|
||||
#- list of halcmd commands to execute
|
||||
# commands are executed in the order in which they appear
|
||||
#HALCMD = save neta
|
||||
###############################################################################
|
||||
# Trajectory planner section
|
||||
###############################################################################
|
||||
|
||||
[HALUI]
|
||||
#No Content
|
||||
|
||||
[TRAJ]
|
||||
#+ machine specific settings
|
||||
# COORDINATES = X Y Z A B C
|
||||
COORDINATES = X Y Z
|
||||
HOME = 0 0 0
|
||||
LINEAR_UNITS = mm
|
||||
ANGULAR_UNITS = degree
|
||||
DEFAULT_LINEAR_VELOCITY = 0.424
|
||||
MAX_LINEAR_VELOCITY = 30.48
|
||||
DEFAULT_LINEAR_ACCELERATION = 300.0
|
||||
MAX_LINEAR_ACCELERATION = 500.0
|
||||
###############################################################################
|
||||
# Axes sections
|
||||
###############################################################################
|
||||
#+ First axis
|
||||
|
||||
[EMCIO]
|
||||
#- tool table file
|
||||
TOOL_TABLE = stepper.tbl
|
||||
|
||||
[KINS]
|
||||
KINEMATICS = trivkins
|
||||
JOINTS = 3
|
||||
|
||||
[AXIS_X]
|
||||
MIN_LIMIT = -1000.0
|
||||
MAX_LIMIT = 1000.0
|
||||
MAX_VELOCITY = 30.48
|
||||
MAX_ACCELERATION = 500.0
|
||||
|
||||
[JOINT_0]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 30.48
|
||||
# NOTE: the step generator module applies its own limits to
|
||||
# acceleration and velocity. We have discovered that it needs
|
||||
# to have a little "headroom" over the accel by the trajectory
|
||||
# planner, otherwise it can fall slightly behind during accel
|
||||
# and later overshoot as it catches up. In the long term we
|
||||
# hope to come up with a clean fix for this problem. In the
|
||||
# meantime, please set STEPGEN_MAXACCEL below to a few percent
|
||||
# higher than the regular acceleration limit MAX_ACCELERATION
|
||||
MAX_ACCELERATION = 500.0
|
||||
STEPGEN_MAXACCEL = 520.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 200
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -1000.0
|
||||
MAX_LIMIT = 1000.0
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Second axis
|
||||
|
||||
[AXIS_Y]
|
||||
MIN_LIMIT = -1000.0
|
||||
MAX_LIMIT = 1000.0
|
||||
MAX_VELOCITY = 30.48
|
||||
MAX_ACCELERATION = 500.0
|
||||
|
||||
[JOINT_1]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.000
|
||||
MAX_VELOCITY = 30.48
|
||||
MAX_ACCELERATION = 500.0
|
||||
STEPGEN_MAXACCEL = 520.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 200
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -1000.0
|
||||
MAX_LIMIT = 1000.0
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
#+ Third axis
|
||||
|
||||
[AXIS_Z]
|
||||
MIN_LIMIT = -1000.0
|
||||
MAX_LIMIT = 1000.0
|
||||
MAX_VELOCITY = 30.48
|
||||
MAX_ACCELERATION = 500.0
|
||||
|
||||
[JOINT_2]
|
||||
TYPE = LINEAR
|
||||
HOME = 0.0
|
||||
MAX_VELOCITY = 30.48
|
||||
MAX_ACCELERATION = 500.0
|
||||
STEPGEN_MAXACCEL = 520.0
|
||||
BACKLASH = 0.000
|
||||
SCALE = 200
|
||||
OUTPUT_SCALE = 1.000
|
||||
MIN_LIMIT = -1000.0
|
||||
MAX_LIMIT = 1000.0
|
||||
FERROR = 1.270
|
||||
MIN_FERROR = 0.254
|
||||
HOME_OFFSET = 0.0
|
||||
HOME_SEARCH_VEL = 0.0
|
||||
HOME_LATCH_VEL = 0.0
|
||||
HOME_USE_INDEX = NO
|
||||
HOME_IGNORE_LIMITS = NO
|
||||
###############################################################################
|
||||
# section for main IO controller parameters
|
||||
###############################################################################
|
||||
29
configs/by_interface/parport/stepper/xylotex_pinout.hal
Normal file
29
configs/by_interface/parport/stepper/xylotex_pinout.hal
Normal file
@@ -0,0 +1,29 @@
|
||||
# pinout config file for 3 channel Xylotex drive
|
||||
# using a parport for I/O
|
||||
#
|
||||
# first load the parport driver
|
||||
loadrt hal_parport cfg="0x0378"
|
||||
#
|
||||
# next connect the parport functions to threads
|
||||
# read inputs first
|
||||
addf parport.0.read base-thread 1
|
||||
# write outputs last
|
||||
addf parport.0.write base-thread -1
|
||||
#
|
||||
# finally connect physical pins to the signals
|
||||
net Xstep <= parport.0.pin-02-out
|
||||
net Xdir <= parport.0.pin-03-out
|
||||
net Ystep <= parport.0.pin-04-out
|
||||
net Ydir <= parport.0.pin-05-out
|
||||
net Zstep <= parport.0.pin-06-out
|
||||
net Zdir <= parport.0.pin-07-out
|
||||
|
||||
# create a signal for the estop loopback
|
||||
net estop-loop iocontrol.0.user-enable-out => iocontrol.0.emc-enable-in
|
||||
|
||||
# create signals for tool loading loopback
|
||||
net tool-prep-loop iocontrol.0.tool-prepare => iocontrol.0.tool-prepared
|
||||
net tool-change-loop iocontrol.0.tool-change => iocontrol.0.tool-changed
|
||||
|
||||
# For guidance connecting spindle control, limit switches, and the like
|
||||
# see the file standard_pinout.hal
|
||||
Reference in New Issue
Block a user