linuxcnc/tests/save.0
Dewey Garrett f9bdd7f3ae hal_lib: new pin,param for thread time,tmax
A 'pseudo' Hal component is created in order to make:
   threadname.time pin   (output only for halscope, hal-histogram, etc)
   threadname.tmax param (rw so it can be reset)

The pseudo component name is identified by the prefix:
  HAL_PSEUDO_COMP_PREFIX = "__"

Example:
  $ halcmd show comp __
  Loaded HAL Components:
  ID      Type  Name                  PID   State
      17  RT    __servo-thread              ready
      16  RT    __base-thread               ready

  $ halcmd show pin \*thread\*
  Component Pins:
  Owner   Type  Dir         Value  Name
      22  s32   OUT         26040  servo-thread.time ==> hhs-0

  $ halcmd show param \*thread\*
  Parameters:
  Owner   Type  Dir         Value  Name
      22  s32   RW         147280  servo-thread.tmax

Note:
  removed two #if 0 sections for comments about adding this functionality
  tested on
    ubuntu lucid   rtai
    debian wheezy  uspace

Alternate to using a coded prefix for a 'pseudo' component:
  Consider changing the hal_comp_t struct type field from an
  int to an enum and modifying hal_init() to accept an arg
  for special comp types.  As hal_init() is used many places,
  this method is probably too pervasive for upcoming 2.7 release.
Signed-off-by: Dewey Garrett <dgarrett@panix.com>
2015-05-25 07:33:13 -07:00
..
expected hal_lib: new pin,param for thread time,tmax 2015-05-25 07:33:13 -07:00
README test of 'halcmd save' 2006-10-26 14:55:47 +00:00
test.sh tests: save.0: use expected result as hal script too 2014-09-16 12:20:37 -05:00

Checks that 'halcmd save' produces the expected output, including
loadable module parameters, parameter settings, linked pins, and thread
functions.