Parameters_For_Kinematics - rmu75/linuxcnc-wiki GitHub Wiki


date: '2010-08-13T19:58:55' title: Parameters For Kinematics

-- Under construction --

Kinematics Parameter

will publish here how to create additional parameters in the ini file and pass them to a kinematics module

Why do we need parameters in Kinematics ?

How can we create parameters for Kinematics ?

By the following steps:

  • Use existing ini parameters or create new ones
  • in function ??? in your kinematic code create one or more hal parameter and assign it to a variable of the c-code
  • in hal, assign the value of the of the ini parameter to the hal parameter

ini parameter

You can use any existing parameter or add a new kinematic specific parameter.

create and assign hal parameter

in the hal file with a line like setp mykin.L0 [AXIS_0]HOME_OFFSET

we create a new parameter and it will receive its value from inifile, section AXIS_0, HOME_OFFSET

read hal parameter in kinematic module

with

hal_param_float_new("mykin.L0", HAL_RW, &My_Param, comp_id))

we assign this value to a previously created kinematic parameter. My_Param is data type hal_float_t.