Motors have three different position nodes: rawPosition, hardPosition, and softPosition.
- rawPosition is the positional value as read directly from the hardware. This will often be in steps, but in the case of VIPER motors, will already be in meaningful units (such as degrees). NICE always considers this node dimensionless.
- hardPosition is the rawPosition value converted into a unit that is meaningful for the user such as degrees or cm: hardPosition = rawPosition * conversion.
- softPosition provides flexibility in defining a motor's position and in most cases is the only node you need to use. softPosition = parity * (hardPosition - zero).
- conversion, partiy, and zero are all nodes as well.
- Motor's are good illustrations of how nodes interact on the system:
- Limit nodes are used to place constraints on motor's movement through NICE. There are two different types of limit nodes: soft, and raw; for each type there is an upper and lower node.
- A motor’s rawLowerLimit and rawUpperLimit nodes hold the minimum and maximum values, to which, the rawPosition node can be moved.
- As a convenience a motor also has a softLowerLimit and softUpperLimit nodes.
- These are derived from the raw limits and show the range, through which, the softPosition can moved.
- Moving soft limits indirectly moves raw limits, based on the current value of the zero, parity and conversion nodes. This works identically, to how moving softPosition, indirectly moves rawPosition.
- The consequence of this scheme is that once limits are set, changes to zero, parity and conversion, WILL NOT change the physical range of motion of a motor, however they will change the status values for softLowerLimit and softUpperLimit.
- A motor's posLimitState and negLimitState are boolean (true/false) values representing whether a motor has hit a physical limit on the track. Confusingly, these are referred to as "hard limits". They have nothing to do with hardPosition!