On 09/11/2015 03:59 AM, andy pugh wrote: > On 11 September 2015 at 05:33, Gene Heskett <ghesk...@wdtv.com> wrote: >> One hopefully last question then Andy, can hal or axis do the math such >> that there is one master place to specify this "scale", and set the >> pid's maxoutput to 0.98 * scale? > > > No, but yes. > > Mathematical expressions are not allowed in a HAL file. > Unless the HAL file is a TCL HAL file... > http://linuxcnc.org/docs/html/hal/haltcl.html > the 1st line in the referenced url says the halcmd language "offers no computational capabilities"
which is a bit confusing ( slight of hand, it says halcmd not haltcl ) but certainly the later example shows the haltcl language can do math """ setp scale.0.gain "6.28 / 360.0 * $::AXIS_0(radius) * 60.0" """ I'd have to try the section on auto-converting from .hal to .tcl by simple find&replace. Hard to believe its sufficient, but I bet its useful beginning. I'm not from Missouri but E.StLouis was just across the river ;) ( who's afraid of the big bad tickle? :) TomP tjtr33 ------------------------------------------------------------------------------ _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users