Hi,

I'm new to LinuxCNC and have issues getting started. I just treated
myself to a cheap import router and would like to get LinuxCNC to
control the machine. So far I'm struggling with the configuration.
Right now I'm in a position so LinuxCNC starts without errors (using
the axis or touchy GUI) but I can't seem to control the machine,
yet.

After failing to write a configuration from scratch, I'm now using
the following config as a base:

  https://github.com/ccatlett1984/LinuxCNC_configs/tree/main/7c80

This didn't quite work out of the box, so I modified it. My current
config is attached. No clue if that is a good or working
configuration for my setup. My goal right now is to just get it to
control the machine, make simple X, Y, Z movements. No limit
switches, spindle control, coolant as of now. I'll add that later if
I can get past the inital setup.

My wiring so far is quite simple:

  24V + GND on the 7C80 TB6
  40pin flat cable to the RPi5
  DM556 X - TB7, STEP/DIR 0
  DM556 Y - TB8, STEP/DIR 1
  DM556 Z - TB9, STEP/DIR 2
  XYZ steppers + 48V to the DM556s

Nothing else. Current state: LinuxCNC starts with no errors. But
when trying to jog by clicking "manual control" → Axis → “Plus“ I
get:

  joint 0 following error
  emc/task/taskintf.cc 976: Error on joint 0, command number 110

And the machine doesn't move. So I think my config is incorrect. Can
someone shed some light on what might be wrong here, or suggest a
working minimal config? If I've done my research well, my setup
should be quite common and therefore well supported.

If you need further info, please let me know.

LinuxCNC 2.9.8
  image: 
https://www.linuxcnc.org/iso/image_2026-01-21-raspios-lcnc-2.9.8-trixie-arm64.zip

My hardware:
  Pi5
  15.6" touchscreen + external keyboard
  Mesa 7C80
  3x DM556

Marco
[MESA]
VERSION = 3.0.0
BOARD_NAME = 7c80

[EMC]
VERSION = 1.1
EMC_VERSION = 2.9.7
MACHINE = 7c80
DEBUG = 0x00000000

[HM2]
DRIVER = hm2_spix

[DISPLAY]
DISPLAY = axis
PROGRAM_PREFIX = ~/linuxcnc/nc_files
INTRO_GRAPHIC = emc2.gif
INTRO_TIME = 1
OPEN_FILE = ""
MAX_FEED_OVERRIDE = 1.2
DEFAULT_LINEAR_VELOCITY = 1.5
MAX_LINEAR_VELOCITY = 25.0
INCREMENTS = 0.1mm,0.5mm,1mm,5mm,10mm
EDITOR = gedit
POSITION_OFFSET = RELATIVE
POSITION_FEEDBACK = COMMANDED

[RS274NGC]
PARAMETER_FILE = parameters.var

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

[TASK]
TASK = milltask
CYCLE_TIME = 0.010

[HAL]
HALFILE = main.hal

[TRAJ]
COORDINATES = XYZ
LINEAR_UNITS = mm
ANGULAR_UNITS = degree
MAX_LINEAR_VELOCITY = 150.0

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

[EMCIO]
EMCIO = iov2
CYCLE_TIME = 0.100
TOOL_TABLE = tool.tbl

[INPUTS]
INPUT_0_0 = Digital 0
INPUT_INVERT_0_0 = True
INPUT_SLOW_0_0 = False
INPUT_0_1 = Digital 1
INPUT_INVERT_0_1 = False
INPUT_SLOW_0_1 = True
INPUT_0_13 = Joint 2 Plus Home
INPUT_INVERT_0_13 = True
INPUT_SLOW_0_13 = False
INPUT_0_14 = Joint 1 Plus Home
INPUT_INVERT_0_14 = False
INPUT_SLOW_0_14 = False
INPUT_0_15 = Joint 0 Minus Home
INPUT_INVERT_0_15 = False
INPUT_SLOW_0_15 = False
INPUT_0_22 = E Stop 0
INPUT_INVERT_0_22 = True
INPUT_SLOW_0_22 = False
INPUT_0_23 = Probe Input
INPUT_INVERT_0_23 = False
INPUT_SLOW_0_23 = False

[OUTPUTS]
OUTPUT_0_0 = Coolant Flood
OUTPUT_INVERT_0_0 = False
OUTPUT_0_7 = Digital Out 1
OUTPUT_INVERT_0_7 = False

[OPTIONS]
LOAD_CONFIG = False
MANUAL_TOOL_CHANGE = True
CUSTOM_HAL = False
POST_GUI_HAL = False
SHUTDOWN_HAL = False
HALUI = False
PYVCP = False
BACKUP = False

[JOINT_0]
TYPE = LINEAR
SCALE = 320
FERROR = 1
MIN_FERROR = 0.25
MAX_VELOCITY = 50
MAX_ACCELERATION = 200

[JOINT_1]
TYPE = LINEAR
SCALE = 320
FERROR = 1
MIN_FERROR = 0.25
MAX_VELOCITY = 50
MAX_ACCELERATION = 200

[JOINT_2]
TYPE = LINEAR
SCALE = 320
FERROR = 1
MIN_FERROR = 0.25
MAX_VELOCITY = 50
MAX_ACCELERATION = 200
# kinematics
loadrt [KINS](KINEMATICS)

# motion controller
loadrt [EMCMOT](EMCMOT) servo_period_nsec=[EMCMOT](SERVO_PERIOD) 
num_joints=[KINS](JOINTS)

# hostmot2 driver
loadrt hostmot2
loadrt hm2_spix
setp hm2_7c80.0.watchdog.timeout_ns 5000000

# THREADS
addf hm2_7c80.0.read servo-thread
addf motion-command-handler servo-thread
addf motion-controller servo-thread
addf hm2_7c80.0.write servo-thread

# amp enable
net motion-enable <= motion.motion-enabled

# joint-0 enable chain
net joint-0-index-enable <=> joint.0.index-enable

# Joint Enables
net x-enable <= joint.0.amp-enable-out
net x-enable <= hm2_7c80.0.stepgen.00.enable

# position command and feedback
net joint-0-pos-cmd <= joint.0.motor-pos-cmd
net joint-0-pos-fb => joint.0.motor-pos-fb

# joint-1 enable chain
net joint-1-index-enable <=> joint.1.index-enable

# Joint Enables
net y-enable <= joint.1.amp-enable-out
net y-enable <= hm2_7c80.0.stepgen.01.enable

# position command and feedback
net joint-1-pos-cmd <= joint.1.motor-pos-cmd
net joint-1-pos-fb => joint.1.motor-pos-fb

# joint-2 enable chain
# net joint-2-index-enable <=> pid.z.index-enable
net joint-2-index-enable <=> joint.2.index-enable

# Joint Enables
net z-enable <= joint.2.amp-enable-out
net z-enable <= hm2_7c80.0.stepgen.02.enable

# position command and feedback
net joint-2-pos-cmd <= joint.2.motor-pos-cmd
net joint-2-pos-fb => joint.2.motor-pos-fb

# Standard I/O Block - EStop, Etc
# create a signal for the estop loopback
net estop-loopback iocontrol.0.emc-enable-in <= iocontrol.0.user-enable-out

# Manual Tool Change Dialog
loadusr -W hal_manualtoolchange
net tool-number hal_manualtoolchange.number <= iocontrol.0.tool-prep-number
net tool-change-request hal_manualtoolchange.change <= iocontrol.0.tool-change
net tool-change-confirmed iocontrol.0.tool-changed => 
hal_manualtoolchange.changed

# tool prep loopback
net tool-prep-loop iocontrol.0.tool-prepare => iocontrol.0.tool-prepared
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to