[ Dodano: 2017-03-09, 09:59 ]
W tej kinematyce, jeśli ustawię pozycję home na 0 0 0 to wywala
kinematicsinverse gave non-finite join location on joint 0
Kod: Zaznacz cały
loadrt [KINS]KINEMATICS
loadrt [EMCMOT]EMCMOT servo_period_nsec=[EMCMOT]SERVO_PERIOD num_joints=[KINS]JOINTS
loadusr -W my_machine_gui
# add motion controller functions to servo thread
addf motion-command-handler servo-thread
addf motion-controller servo-thread
# create HAL signals for position commands from motion module
# loop position commands back to motion module feedback
net J0pos joint.0.motor-pos-cmd => joint.0.motor-pos-fb
net J1pos joint.1.motor-pos-cmd => joint.1.motor-pos-fb
net J2pos joint.2.motor-pos-cmd => joint.2.motor-pos-fb
#net J3pos joint.3.motor-pos-cmd => joint.3.motor-pos-fb
#net J4pos joint.4.motor-pos-cmd => joint.4.motor-pos-fb
#net J5pos joint.5.motor-pos-cmd => joint.5.motor-pos-fb
#net J6pos joint.6.motor-pos-cmd => joint.6.motor-pos-fb
#net J7pos joint.7.motor-pos-cmd => joint.7.motor-pos-fb
#net J8pos joint.8.motor-pos-cmd => joint.8.motor-pos-fb
net J0cmd joint.0.pos-cmd => my_machine_gui.joint0
net J1cmd joint.1.pos-cmd => my_machine_gui.joint1
net J2cmd joint.2.pos-cmd => my_machine_gui.joint2
net pfr rotarydeltakins.platformradius => my_machine_gui.pfr
net tl rotarydeltakins.thighlength => my_machine_gui.tl
net sl rotarydeltakins.shinlength => my_machine_gui.sl
net fr rotarydeltakins.footradius => my_machine_gui.fr
sets pfr 485
sets tl 422
sets sl 640
sets fr 87
#setp deltakins.e 87
#setp deltakins.f 485
#setp deltakins.re 640
#setp deltakins.rf 422
# 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
Kod: Zaznacz cały
# This config file was created 2017-03-07 17:04:28.782048 by the update_ini script
# The original config files may be found in the /home/student/linuxcnc/configs/deltaW/deltaW.old directory
# EMC controller parameters for a simulated hexapod of the minitetra type.
# 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
######################################
# Megjegyzések a .hal-ban! #
######################################
###############################################################################
# General section
###############################################################################
# General section -------------------------------------------------------------
[EMC]
#- Version of this INI file
VERSION = 1.0
#+ Name of machine, for use with display, etc.
MACHINE = DELTA-RAIL-sbt
#- Name of NML file to use, default is emc.nml
######## NML_FILE = emc.nml
#+ 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., xemc
DISPLAY = axis
# DISPLAY = usrmot
# DISPLAY = mini
# DISPLAY = tkemc
#- Cycle time, in seconds, that display will sleep between polls
# CYCLE_TIME = 0.200
#- Path to help file
HELP_FILE = tkemc.txt
#OPEN_FILE = /home/jozsi/Munkaasztal/Gcode/Test-10/P3-m3m5.nc
#OPEN_FILE = /home/jozsi/Munkaasztal/Gcode/Test-8/50x50z-minus-10.nc
#OPEN_FILE = /home/jozsi/Munkaasztal/Gcode/Test-10/50x50-pj-z-minus10.nc
#OPEN_FILE = /home/jozsi/Munkaasztal/Gcode/Test-Rulers/kör100z10.nc
OPEN_FILE =/home/jozsi/Asztal/Gcode/Test-12/100x100.nc
#- Initial display setting for position, RELATIVE or MACHINE
#POSITION_OFFSET = 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.0
#+ Prefix to be used
#PROGRAM_PREFIX = ../../nc_files/
PROGRAM_PREFIX = /home/jozsi/Munkaasztal/Gcode
#- Introductory graphic
INTRO_GRAPHIC = emc2.gif
INTRO_TIME = 5
#PYVCP = laserpanel.xml
#PYVCP = custompanel.xml
#PYVCP = scara.xml
#PYVCP = puma.xml
#PYVCP = custompanel.xml
# Editor to be used with Axis
EDITOR = gedit
[FILTER]
PROGRAM_EXTENSION = .png,.gif,.jpg Grayscale Depth Image
PROGRAM_EXTENSION = .py Python Script
png = image-to-gcode
gif = image-to-gcode
jpg = image-to-gcode
py = python
###############################################################################
# Task controller section
###############################################################################
[RS274NGC]
#- File containing interpreter variables
#PARAMETER_FILE = puma.var
#PARAMETER_FILE = scara.var
PARAMETER_FILE = emc.var
###############################################################################
# Motion control section
###############################################################################
[EMCMOT]
EMCMOT = motmod
#SHMEM_KEY = 111
#- Timeout for comm to emcmot, in seconds
COMM_TIMEOUT = 1.0
#- Interval between tries to emcmot, in seconds
COMM_WAIT = 0.010
BASE_PERIOD = 50000
#- Servo task period, in nanoseconds
SERVO_PERIOD = 1000000
#- Trajectory Planner task period, in nanoseconds - will be rounded to an
# integer multiple of SERVO_PERIOD
TRAJ_PERIOD = 10000000
###############################################################################
# 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 = puma_sim_6.hal
#HALFILE = joypad_v3.hal
HALFILE = custom.hal
#POSTGUI_HALFILE = puma_postgui.hal
POSTGUI_HALFILE = custom_postgui.hal
#POSTGUI_HALFILE = scara_postgui.hal
#- list of halcmd commands to execute
# commands are executed in the order in which they appear
#HALCMD = save neta
#load halui to enable
#HALUI = halui
###############################################################################
# Trajectory planner section
###############################################################################
[HALUI]
#No Content
[TRAJ]
#+ machine specific settings
AXES = 3
# COORDINATES = X Y Z
COORDINATES = X Y Z
#HOME = 140 80 0
HOME = 0 0 90
LINEAR_UNITS = mm
ANGULAR_UNITS = deg
CYCLE_TIME = 0.010
#DEFAULT_LINEAR_VELOCITY = 5.0
DEFAULT_LINEAR_VELOCITY = 5.0
# MAX_VELOCITY = 80.0
MAX_LINEAR_VELOCITY = 80.0
DEFAULT_ACCELERATION = 50.0
MAX_LINEAR_ACCELERATION = 100.0
#DEFAULT_ACCELERATION = 10.0
#MAX_LINEAR_ACCELERATION = 30.0
###############################################################################
# Axes sections
###############################################################################
#+ First axis
[EMCIO]
#- Name of IO controller program, e.g., io
EMCIO = io
#- cycle time, in seconds
CYCLE_TIME = 0.100
#- tool table file
TOOL_TABLE = puma.tbl
[KINS]
KINEMATICS = rotarydeltakins
#This is a best-guess at the number of joints, it should be checked
JOINTS = 3
[AXIS_X]
MIN_LIMIT = -240.0
MAX_LIMIT = 240.0
MAX_VELOCITY = 80.0
MAX_ACCELERATION = 100.0
[JOINT_0]
TYPE = ANGULAR
#HOME = 230.000
HOME = 0.000
MAX_VELOCITY = 80.0
MAX_ACCELERATION = 100.0
#MAX_ACCELERATION = 150.0
#STEPGEN_MAXACCEL = 160.0
STEPGEN_MAXACCEL = 120.0
INPUT_SCALE = 4000
OUTPUT_SCALE = 2.22
#OUTPUT_SCALE = 320.0
#COMP_FILE_TYPE = 0
#COMP_FILE = axis0.comp
FERROR = 20.0
MIN_FERROR = 5
HOME_OFFSET = 0.000
MIN_LIMIT = -360.0
MAX_LIMIT = 360.0
#HOME_OFFSET = 0.
HOME_SEQUENCE = 0
#+ Second axis
[AXIS_Y]
MIN_LIMIT = -240.0
MAX_LIMIT = 240.0
MAX_VELOCITY = 80.0
MAX_ACCELERATION = 100.0
[JOINT_1]
TYPE = ANGULAR
HOME = 0.000
MAX_VELOCITY = 80.0
MAX_ACCELERATION = 100.0
STEPGEN_MAXACCEL = 120.0
INPUT_SCALE = 4000
OUTPUT_SCALE = 2.22
#OUTPUT_SCALE = 320.0
#COMP_FILE_TYPE = 0
#COMP_FILE = axis0.comp
FERROR = 20.0
MIN_FERROR = 5
HOME_OFFSET = 0.000
MIN_LIMIT = -360.0
MAX_LIMIT = 360.0
#HOME_OFFSET = 0.0
HOME_SEQUENCE = 0
#+ Third axis
[AXIS_Z]
MIN_LIMIT = -180.0
MAX_LIMIT = 180.0
MAX_VELOCITY = 80.0
MAX_ACCELERATION = 100.0
[JOINT_2]
TYPE = ANGULAR
HOME = 0.000
MAX_VELOCITY = 80.0
MAX_ACCELERATION = 100.0
STEPGEN_MAXACCEL = 120.0
INPUT_SCALE = 4000
OUTPUT_SCALE = 2.22
#OUTPUT_SCALE = 320.0
#COMP_FILE_TYPE = 0
#COMP_FILE = axis0.comp
FERROR = 20.0
MIN_FERROR = 5
HOME_OFFSET = 0.000
MIN_LIMIT = -360.0
MAX_LIMIT = 360.0
#HOME_OFFSET = 0.0
HOME_SEQUENCE = 0
#+ Fourth axis
#[AXIS_3]
#TYPE = ANGULAR
#HOME = 0.000
#MAX_VELOCITY = 6.0
#MAX_ACCELERATION = 30.0
#BACKLASH = 0.000
#INPUT_SCALE = 400
#OUTPUT_SCALE = 1.000
#MIN_LIMIT = -360.0
#MAX_LIMIT = 360.0
#FERROR = 20.0
#MIN_FERROR = 5.0
#HOME_OFFSET = 0.0
#HOME_SEARCH_VEL = 0.0
#HOME_LATCH_VEL = 0.0
#HOME_USE_INDEX = NO
#HOME_IGNORE_LIMITS = NO
#HOME_SEQUENCE = 0
#+ Fifth axis
#[AXIS_4]
#TYPE = ANGULAR
#HOME = 0.000
#MAX_VELOCITY = 6.0
#MAX_ACCELERATION = 30.0
#BACKLASH = 0.000
#INPUT_SCALE = 4000
#OUTPUT_SCALE = 1.000
#MIN_LIMIT = -360.0
#MAX_LIMIT = 360.0
#FERROR = 2.000
#MIN_FERROR = 0.200
#HOME_OFFSET = 0.0
#HOME_SEARCH_VEL = 0.0
#HOME_LATCH_VEL = 0.0
#HOME_USE_INDEX = NO
#HOME_IGNORE_LIMITS = NO
#HOME_SEQUENCE = 0
#+ Sixth axis
#[AXIS_5]
#TYPE = ANGULAR
#HOME = 0.000
#MAX_VELOCITY = 6.0
#MAX_ACCELERATION = 30.0
#BACKLASH = 0.000
#INPUT_SCALE = 4000
#OUTPUT_SCALE = 1.000
#MIN_LIMIT = -180.0
#MAX_LIMIT = 180.0
#FERROR = 2.000
#MIN_FERROR = 0.200
#HOME_OFFSET = 0.0
#HOME_SEARCH_VEL = 0.0
#HOME_LATCH_VEL = 0.0
#HOME_USE_INDEX = NO
#HOME_IGNORE_LIMITS = NO
#HOME_SEQUENCE = 0
###############################################################################
# section for main IO controller parameters
###############################################################################