Class PMAxisControl
Defined in File PMMotionApi.h
Nested Relationships
Nested Types
Class Documentation
-
class PMAxisControl
This class contains axis control functions for PM motion.
Public Functions
-
bool IsDeviceValid()
-
WMX3APIFUNC SetServoOn(int axis, int newStatus)
Turn a servo drive in the servo network on or off.
Turn a servo drive in the servo network on or off.
The servoOn status (obtained with GetStatus) should be checked to verify that the axis servo has turned on or off before continuing with operations that require the servo to be on or off.
Remark
- Parameters:
axis – [in] The axis of the servo drive to turn on or off.
newStatus – [in] 1: Turn on the servo, 0: Turn off the servo
-
WMX3APIFUNC SetServoOn(AxisSelection *axisSel, int newStatus)
Turn multiple servo drives in the servo network on or off.
Turn multiple servo drives in the servo network on or off.
This function is a variation of the SetServoOn function that operates on multiple axes at the same time.
Remark
- Parameters:
axisSel – [in] A pointer to an AxisSelection class that specifies which axes to turn on or off.
newStatus – [in] 1: Turn on the servo, 0: Turn off the servo
-
WMX3APIFUNC ClearAmpAlarm(int axis)
Clear the servo drive amp alarm on the specified axis.
Clear the servo drive amp alarm on the specified axis.
The ampAlarm status (obtained with GetStatus) can be checked to verify whether the amp alarm has been cleared.
Remark
- Parameters:
axis – [in] The axis to clear the amp alarm.
-
WMX3APIFUNC ClearAmpAlarm(AxisSelection *axisSel)
Clear the servo drive amp alarms on multiple axes.
Clear the servo drive amp alarms on multiple axes.
This function is a variation of the ClearAmpAlarm function that operates on multiple axes at the same time.
Remark
- Parameters:
axisSel – [in] A pointer to an AxisSelection class that specifies which axes to clear the amp alarm.
-
WMX3APIFUNC SetHomeProfile(HomeProfile *pHomeProfile)
Set the home profile.
Set the home profile.
The home profile set by this function is used for home commands executed by the axis.
Remark
- Parameters:
pHomeProfile – [in] A pointer to the home profile.
-
WMX3APIFUNC SetHomeProfiles(HomeProfiles *pHomeProfiles)
Set the home profile for multiple axes.
Set the home profile for multiple axes.
The home profile set by this function is used for home commands executed by the axis.
Remark
- Parameters:
pHomeProfiles – [in] A pointer to the home profiles.
-
WMX3APIFUNC SetVelProfile(VelocityProfile *pVelProfile)
Set the velocity profile.
Set the velocity profile.
The velocity profile set by this function is used for position commands and velocity commands executed by the axis.
Remark
- Parameters:
pVelProfile – [in] A pointer to the velocity profile.
-
WMX3APIFUNC SetVelProfiles(VelocityProfiles *pVelProfiles)
Set the velocity profile for multiple axes.
Set the velocity profile for multiple axes.
The velocity profile set by this function is used for position commands and velocity commands executed by the axis.
Remark
- Parameters:
pVelProfiles – [in] A pointer to the velocity profiles.
-
WMX3APIFUNC SetTrqProfile(TorqueProfile *pTrqProfile)
Set the torque profile.
Set the torque profile.
The torque profile set by this function is used for torque commands executed by the axis.
Remark
- Parameters:
pTrqProfile – [in] A pointer to the torque profile.
-
WMX3APIFUNC SetTrqProfiles(TorqueProfiles *pTrqProfiles)
Set the torque profile for multiple axes.
Set the torque profile for multiple axes.
The torque profile set by this function is used for torque commands executed by the axis.
Remark
- Parameters:
pTrqProfiles – [in] A pointer to the torque profiles.
-
WMX3APIFUNC GetPosCommand(int axis, long *pPosition)
Get the current cycle position command of the axis.
Get the current cycle position command of the axis.
This function obtains the current cycle position command of an axis. This value is identical to the posCmd status obtained with the GetStatus function.
Remark
- Parameters:
axis – [in] The axis to get the position command.
pPosition – [out] A pointer that will contain the position command.
-
WMX3APIFUNC GetPosFeedback(int axis, long *pPosition)
Get the current cycle position feedback of the axis.
Get the current cycle position feedback of the axis.
This function obtains the current cycle position feedback of an axis. This value is identical to the actualPos status obtained with the GetStatus function.
Remark
- Parameters:
axis – [in] The axis to get the position feedback.
pPosition – [out] A pointer that will contain the position feedback.
-
WMX3APIFUNC GetVelCommand(int axis, long *pVelocity)
Get the current cycle velocity command of the axis.
Get the current cycle velocity command of the axis.
This function obtains the current cycle velocity command of an axis. This value is identical to the velocityCmd status obtained with the GetStatus function.
Remark
- Parameters:
axis – [in] The axis to get the velocity command.
pVelocity – [out] A pointer that will contain the velocity command.
-
WMX3APIFUNC GetVelFeedback(int axis, long *pVelocity)
Get the current cycle velocity feedback of the axis.
Get the current cycle velocity feedback of the axis.
This function obtains the current cycle velocity feedback of an axis. This value is identical to the actualVelocity status obtained with the GetStatus function.
Remark
- Parameters:
axis – [in] The axis to get the velocity feedback.
pVelocity – [out] A pointer that will contain the velocity feedback.
-
class HomeProfile
This class contains profile data for a home command.
Public Functions
-
HomeProfile()
-
HomeProfile(int axis, unsigned char method, long speedForSwitch, long speedForZero, long acc, long homeOffset = 0)
Public Members
-
int axis
The axis to execute homing.
-
unsigned char method
The homing method.
-
long speedForSwitch
The velocity when searching for the switch, in units of pulses per second.
-
long speedForZero
The velocity when searching for the zero, in units of pulses per second.
-
long acc
The acceleration for homing, in units of pulses per second^2.
-
long homeOffset
The home offset.
-
HomeProfile()
-
class HomeProfiles
This class contains profile data for multiple home commands.
Public Functions
-
HomeProfiles()
Public Members
-
int axisCount
The number of axes to command.
-
HomeProfile profiles[constants::maxPMAxes]
The profiles of the home commands. The first axisCount indices contain the profiles.
-
HomeProfiles()
-
class TorqueProfile
This class contains profile data for a torque command.
Public Members
-
int axis
The axis of the motion command.
-
long torque
The torque of the motion command, in units of 0.1%. A positive value indicates torque in the positive direction and a negative value indicates torque in the negative direction.
-
long maxMotorSpeed
The maximum motor speed to apply, in units of rpm.
-
int axis
-
class TorqueProfiles
This class contains profile data for multiple torque commands.
Public Functions
-
TorqueProfiles()
Public Members
-
int axisCount
The number of axes to command.
-
TorqueProfile profiles[constants::maxPMAxes]
The profiles of the torque commands. The first axisCount indices contain the profiles.
-
TorqueProfiles()
-
class VelocityProfile
This class contains profile data for a velocity command.
Public Functions
-
VelocityProfile()
-
VelocityProfile(int axis, long vel, long acc, long maxTrqLimit = 0)
-
VelocityProfile(int axis, long vel, long acc, long dec, long maxTrqLimit = 0)
Public Members
-
int axis
The axis of the motion command.
-
long vel
The velocity of the motion command, in pulses per second.
-
long acc
The acceleration of the motion command, in pulses per second^2.
-
long dec
The deceleration of the motion command, in pulses per second^2.
-
long maxTrqLimit
The maximum torque limit to apply, in units of 0.1%.
-
VelocityProfile()
-
class VelocityProfiles
This class contains profile data for multiple velocity commands.
Public Functions
-
VelocityProfiles()
Public Members
-
int axisCount
The number of axes to command.
-
VelocityProfile profiles[constants::maxPMAxes]
The profiles of the velocity commands. The first axisCount indices contain the profiles.
-
VelocityProfiles()
-
bool IsDeviceValid()