yaq/traits/has-limits


The has-limits trait extends the has-positions trait with limits. It's assumed that any position within the limits is valid.

requires

has-position

configuration

Daemons with the has-limits trait expect the following configuration:

limits (array) default: [-inf, inf]
Configuration limits are strictly optional.

out_of_limits (enum) default: closest
Control behavior of daemon when set_position is given a value outside of limits.

state

Daemons with the has-limits trait will provide the following state information:

destination (double)
from has-position

hw_limits (array)

position (double)
from has-position

messages

Daemons with the has-limits trait expose the following public messages:

get_destination ➜ double
Get current daemon destination.
from has-position

get_limits ➜ {'items': 'double', 'type': 'array'}
Get daemon limits.Limits will be the intersection of config limits and driver limits (when appliciable).

get_position ➜ double
Get current daemon position.
from has-position

get_units ➜ ['null', 'string']
Get units of daemon. These units apply to the position and destination fields.
from has-position

in_limits ➜ boolean
Check if a given position is within daemon limits.
parameters:

position (double)

set_position
Give the daemon a new destination, and begin motion towards that destination.
from has-position
parameters:

position (double)

set_relative ➜ double
Give the daemon a new destination relative to its current position. Daemon will immediately begin motion towards new destination. Returns new destination.
from has-position
parameters:

distance (double)

daemons

The following daemons implement the has-limits trait:

acton-2150i
fake-continuous-hardware
fake-has-turret
lightcon-topas4-motor
micro-hr
newport-connex-agp
newport-smc100
pmc
thorlabs-bsc201
thorlabs-k10cr1
thorlabs-kdc101
thorlabs-kst101
thorlabs-lts150
thorlabs-lts300
wright-filter-wheel
zaber-binary


built 2020-10-27 13:47:08                                      CC0: no copyright