Skip to content

LinuxCNC Module Definitions

TheRealBeef edited this page Oct 22, 2023 · 1 revision

Userspace Programs (INI File Settings)

TASK

  • Setting: [TASK]TASK=milltask
  • Description: Specifies the primary userspace program. The 'milltask' program is the default LinuxCNC userspace program. It includes a gcode interpreter and interfaces with other userspace programs (e.g., io, display) and the realtime motion module and HAL (Hardware Abstraction Layer). An alternative interpreter can be invoked using the setting: [TASK]INTERPRETER. An example of an alternative interpreter is canterp.

DISPLAY

  • Setting: [DISPLAY]DISPLAY=display_program_name
  • Description: Specifies a program that provides a user interface. Multiple programs are available within the LinuxCNC tree and from other developers. Some use graphics without OpenGL (e.g., touchy, tklinuxcnc) while others use OpenGL (e.g., axis, gmoccapy, qtvcp). The DISPLAY program can be an executable or script and can interact with other LinuxCNC programs and the realtime motion module and HAL. Examples of remote DISPLAY interfaces include halui and linuxcncrsh.

Realtime Modules (INI File Settings)

EMCMOT

  • Setting: [EMCMOT]EMCMOT=motmod [parameters ...]
  • Description: Specifies the realtime motion module. The 'motmod' module is the default LinuxCNC motion module. It interfaces with other realtime modules, including:
    • Homing (default: homemod)
    • Trajectory planning (default: tpmod)
    • Kinematics (no default)
    • The module also receives messages from the userspace task program and interacts with HAL.
    • Reference: motmod objects

TRAJ

  • Setting: [TRAJ]TPMOD=custom_trajectory_planner [optional_parameters ...]
  • Description: Specifies a trajectory planning module. If omitted, the default 'tpmod' module is used. Custom modules can be built with halcompile.

HOMEMOD

  • Setting: [EMCMOT]HOMEMOD=custom_homing_module [optional_parameters ...]
  • Description: Specifies a homing module. If omitted, the default 'homemod' module is used. Custom modules can be built with halcompile.

KINEMATICS

  • Settings:
    • [KINEMATICS]KINS=module_name [optional_parameters ...]
    • [KINS]JOINTS=number_of_joints
  • Description: Specifies a kinematics module based on the machine configuration. The number of joints must also be specified. Many machines use identity kinematics and invoke the provided trivkins module (short for trivial kinematics).

Additional Notes

  1. Default trajectory planning (tpmod) and homing (homemod) modules are loaded by the linuxcnc script without needing specific INI file settings.
  2. Homing and trajectory planner modules can be specified with command-line options for the linuxcnc script (use linuxcnc -h for details).
  3. The kinematics module and motion module are typically loaded in the required order by an INI file specified [HAL]HALFILE.

References

By understanding these configurations and settings, users can effectively set up and customize their LinuxCNC operations.