Skip to content

Monitor a specific parameter value #63

Description

@tukusejssirs

It could be very useful if a user could easily configure fanuc-driver to collect one or more parameters (using rdparam) from machine.

It’d be nice if the user could:

  • provide a name for this dynamic collector;
  • provide a structure of the returned data:
    • this would be more useful when multiple parameters would be watched in a single collector;
    • order of parameter_id items and data_type items must match;
    • in format, one would use $1 to get the value of the first (0th) parameter value, $2 the second one, etc;
  • when format is not defined:
    • for single parameter, fanuc-driver would return {$collector_name: $1};
    • for multiple parameters, fanuc-driver would return {$collector_name: [$1, $2, ...]};

For example, the configuration could look something like this:

# Single parameter: configuration
some_collector_name:
   parameter_id: 1234
   data_type: string  # 'string' | 'number' | 'boolean' and possibly some others

# Multiple parameters: configuration
another_collector_name:
   parameter_id:
      - 1234
      - 4321
   data_type:  # 'string' | 'number' | 'boolean' and possibly some others
      - string
      - number
   format: '{"some_name": $1, "another_name": $2}'

Example of the returned data:

// Single parameter
{
   some_collector_name: 'some_value'
}

// Multiple parameters
{
   another_collector_name: {
      some_name: 'some_value',
      another_name: 4543
   }
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions