Constructor
new Step(fix, mob)
Creates a step motor steps representation of a unity vector.
Parameters:
Name | Type | Default | Description |
---|---|---|---|
fix |
number | 0 | the fixed motor step (0 to this.maxSteps) coordinate. |
mob |
number | 0 | the mobile motor step (0 to this.maxSteps) coordinate. |
Members
fix
Set this.fix
fix
Get this.fix
mob
Set this.mob
mob
Get this.mob
Methods
clone() → {Step}
Make a copy of this vector.
Returns:
copy of this vector.
- Type
- Step
correctSteps()
Corrects coordinates to their boundary values.
fixFromRad(rad)
Set fix coordinate from angle in radians
Parameters:
Name | Type | Description |
---|---|---|
rad |
number | angle in radians that will set the fix coordinate |
fixToRad() → {number}
Returns fix coordinate in radians.
Returns:
this.fix in radians
- Type
- number
mobFromRad(rad)
Set mob coordinate from angle in radians
Parameters:
Name | Type | Description |
---|---|---|
rad |
number | angle in radians that will set the mob coordinate |
mobToRad() → {number}
Returns mob coordinate in radians.
Returns:
this.mob in radians
- Type
- number