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

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 0 additions & 44 deletions configs/sim/axis/vismach/melfa-sim/melfa.txt

This file was deleted.

26 changes: 0 additions & 26 deletions configs/sim/axis/vismach/melfa-sim/remap_subs/430remap.ngc

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
This is modelled on a Mitsubishi RV6-SDL serial manipulator. A tutorial on how the required modified-DH-parameters were derived for this robot is available in the linuxcnc documentation.
This simulation is modelled on a Mitsubishi RV6-SDL serial manipulator.

Note that due to "gimbal lock" it is normal that the inverse kinematic fails when moving near such a singular point while in cartesian mode (ie genserkins). To move across such points it is necessary to switch from cartesian to joint (trivial) kinematics.
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
This simulation uses 'genserkins' kinematics and the 'modified' DH-parameters used by that particular kinematic model.

A tutorial on how the required modified-DH-parameters were derived for this robot is available in the linuxcnc documentation.


melfa-switchkins usage:

1) startup (after homing) is in
'genserkins' mode configured like
melfa-switchkins.ini as an mm-based machine
with 6 revolute joints.

2) pyvcp buttons are provided to switch
between 'genserkins' and 'identity'
kinematics. The buttons issue remapped
commands M428,M429. These commands
a) set the motion.switchkins-type pin and
b) force a synchronization using a
motion input read command.

3) when set for 'identity' kins, default
assignments are:

x : joint0
y : joint1
z : joint2
a : joint3
b : joint4
c : joint5
so the gcode commands:
'g0x10' moves joint0
'g0c10' moves joint5

4) when set for 'genserkins' the axis letters
represent the cartesian coordinates.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[EMC]
VERSION = 1.1
MACHINE = melfa (mm)
MACHINE = Melfa-Sim using 'genserkins' kinematics (mm)
DEBUG = 0

[KINS]
Expand All @@ -10,24 +10,22 @@ JOINTS= 6
[HAL]
HALUI = halui
HALFILE = LIB:basic_sim.tcl
HALFILE = melfa_dh.hal
HALCMD = loadusr -W melfagui
HALFILE = melfa_mdh.hal
HALCMD = loadusr -W ../melfagui.py
HALCMD = net :kinstype-select <= motion.analog-out-03 => motion.switchkins-type
POSTGUI_HALFILE = melfa-postgui.hal
POSTGUI_HALFILE = ../melfa-postgui.hal

[RS274NGC]
PARAMETER_FILE = melfa.var
SUBROUTINE_PATH = ./remap_subs
SUBROUTINE_PATH = ../remap_subs
HAL_PIN_VARS = 1
REMAP = M428 modalgroup=10 ngc=428remap
REMAP = M429 modalgroup=10 ngc=429remap
REMAP = M430 modalgroup=10 ngc=430remap
RS274NGC_STARTUP_CODE = G10 L2 P7 X0 Y0 Z0 A-180 B0 C0 G59.1 (debug, ini: startup offsets)

[HALUI]
MDI_COMMAND = M429
MDI_COMMAND = M428
MDI_COMMAND = M430


[DISPLAY]
Expand All @@ -42,9 +40,9 @@ MAX_FEED_OVERRIDE = 2.0
PROGRAM_PREFIX = ./
INTRO_GRAPHIC = linuxcnc.gif
INTRO_TIME = 5
PYVCP = melfa.xml
PYVCP = ../melfa.xml
EDITOR = geany
OPEN_FILE = example.ngc
OPEN_FILE = ../example.ngc

[TASK]
TASK = milltask
Expand All @@ -68,7 +66,7 @@ DEFAULT_LINEAR_ACCELERATION = 200.0
MAX_LINEAR_ACCELERATION = 400.0

[EMCIO]
TOOL_TABLE = melfa.tbl
TOOL_TABLE = ../melfa.tbl

[JOINT_0]
TYPE = ANGULAR
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
This simulation uses 'three21' kinematics and the 'standard' DH-parameters used by that particular kinematic model.


melfa-switchkins usage:

1) startup (after homing) is in
'three21' mode configured like
melfa-switchkins.ini as an mm-based machine
with 6 revolute joints.

2) pyvcp buttons are provided to switch
between 'three21' and 'identity'
kinematics. The buttons issue remapped
commands M428,M429. These commands
a) set the motion.switchkins-type pin and
b) force a synchronization using a
motion input read command.

3) when set for 'identity' kins, default
assignments are:

x : joint0
y : joint1
z : joint2
a : joint3
b : joint4
c : joint5
so the gcode commands:
'g0x10' moves joint0
'g0c10' moves joint5

4) when set for 'three21' the axis letters
represent the cartesian coordinates.
Original file line number Diff line number Diff line change
@@ -0,0 +1,141 @@
[EMC]
VERSION = 1.1
MACHINE = Melfa-Sim using 'three21' kinematics (mm)
DEBUG = 0

[KINS]
KINEMATICS= three21kins
JOINTS= 6

[HAL]
HALUI = halui
HALFILE = LIB:basic_sim.tcl
HALFILE = melfa_dh.hal
HALCMD = loadusr -W ../melfagui.py
HALCMD = net :kinstype-select <= motion.analog-out-03 => motion.switchkins-type
POSTGUI_HALFILE = ../melfa-postgui.hal

[RS274NGC]
PARAMETER_FILE = melfa.var
SUBROUTINE_PATH = ../remap_subs
HAL_PIN_VARS = 1
REMAP = M428 modalgroup=10 ngc=428remap
REMAP = M429 modalgroup=10 ngc=429remap
RS274NGC_STARTUP_CODE = G10 L2 P7 X0 Y0 Z0 A-180 B0 C0 G59.1 (debug, ini: startup offsets)

[HALUI]
MDI_COMMAND = M429
MDI_COMMAND = M428


[DISPLAY]
DISPLAY = axis
GEOMETRY = XYZABC
CYCLE_TIME = 0.200
POSITION_OFFSET = RELATIVE
POSITION_FEEDBACK = ACTUAL
DEFAULT_LINEAR_VELOCITY = 60.0
DEFAULT_ANGULAR_VELOCITY = 40.0
MAX_FEED_OVERRIDE = 2.0
PROGRAM_PREFIX = ./
INTRO_GRAPHIC = linuxcnc.gif
INTRO_TIME = 5
PYVCP = ../melfa.xml
EDITOR = geany
OPEN_FILE = ../example.ngc

[TASK]
TASK = milltask
CYCLE_TIME = 0.010


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

[TRAJ]
COORDINATES = X Y Z A B C
LINEAR_UNITS = mm
ANGULAR_UNITS = deg
DEFAULT_LINEAR_VELOCITY = 60.0
DEFAULT_ANGULAR_VELOCITY = 60.0
MAX_LINEAR_VELOCITY = 200.0
MAX_ANGULAR_VELOCITY = 100.0
DEFAULT_LINEAR_ACCELERATION = 200.0
MAX_LINEAR_ACCELERATION = 400.0

[EMCIO]
TOOL_TABLE = ../melfa.tbl

[JOINT_0]
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
MIN_LIMIT = -170.0
MAX_LIMIT = 170.0
HOME_SEQUENCE = 0
HOME_OFFSET = 0
HOME = 0
[JOINT_1]
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
MIN_LIMIT = -182.0
MAX_LIMIT = 45.0
HOME_OFFSET = 0.0
HOME_SEQUENCE = 0
HOME = -90.001
[JOINT_2]
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
MIN_LIMIT = -219.0
MAX_LIMIT = 76.0
HOME_OFFSET = 0.0
HOME_SEQUENCE = 0
HOME = 0.001
[JOINT_3]
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
MIN_LIMIT = -160.0
MAX_LIMIT = 160.0
HOME_OFFSET = 0.0
HOME_SEQUENCE = 0
HOME = 0.001
[JOINT_4]
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
MIN_LIMIT = -120.0
MAX_LIMIT = 120.0
HOME_OFFSET = 0.0
HOME_SEQUENCE = 0
HOME = 90.001
[JOINT_5]
TYPE = ANGULAR
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
HOME_OFFSET = 0.0
HOME_SEQUENCE = 0
HOME = 0.001

[AXIS_X]
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
[AXIS_Y]
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
[AXIS_Z]
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
[AXIS_A]
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
[AXIS_B]
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
[AXIS_C]
MAX_VELOCITY = 60.0
MAX_ACCELERATION = 400.0
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# modified DH-parameters for RV-6SDL

setp three21kins.A1 85
setp three21kins.A2 380
setp three21kins.A3 100
setp three21kins.D1 350
setp three21kins.D2 0
setp three21kins.D3 0
setp three21kins.D4 425
#setp three21kins.D6 85 # distance to the flange
setp three21kins.D6 235


Original file line number Diff line number Diff line change
Expand Up @@ -42,19 +42,19 @@

try: # Expect files in working directory
# create toolholder from file
link7 = AsciiSTL(filename="link7.stl")
link7 = AsciiSTL(filename="../melfa_stl/link7.stl")
# create wrist from file
link6 = AsciiSTL(filename="link6.stl")
link6 = AsciiSTL(filename="../melfa_stl/link6.stl")
# create forearm from file
link5 = AsciiSTL(filename="link5.stl")
link5 = AsciiSTL(filename="../melfa_stl/link5.stl")
# create ellbow trom file
link4 = AsciiSTL(filename="link4.stl")
link4 = AsciiSTL(filename="../melfa_stl/link4.stl")
# create upper arm from file
link3 = AsciiSTL(filename="link3.stl")
link3 = AsciiSTL(filename="../melfa_stl/link3.stl")
# create shoulder from file
link2 = AsciiSTL(filename="link2.stl")
link2 = AsciiSTL(filename="../melfa_stl/link2.stl")
# create base (waist) from file
link1 = AsciiSTL(filename="link1.stl")
link1 = AsciiSTL(filename="../melfa_stl/link1.stl")
except Exception as detail:
print(detail)
raise SystemExit("melfagui requires files link[1-7].stl in working directory")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ DEFAULT_ANGULAR_ACCELERATION = 100.0
MAX_ANGULAR_ACCELERATION = 200.0

[EMCIO]
TOOL_TABLE = scara.tbl
#TOOL_TABLE = scara.tbl

[AXIS_X]
MAX_VELOCITY = 30.0
Expand Down
Loading
Loading