Class PMAxisTorque

Nested Relationships

Nested Types

Class Documentation

class PMAxisTorque

This class contains TQ mode torque command functions for PM motion.

Public Functions

inline PMAxisTorque(PMMotion *f)
bool IsDeviceValid()
WMX3APIFUNC StartTrq(int axis)

Start a TQ mode torque command.

Start a TQ mode torque command.

This function will start a torque command. The axis will apply a constant torque in the direction of the torque. Depending on the load on the axis, the axis may move during a torque command.

Remark

The torque profile must be first set with the SetTrqProfile function.

Parameters:

axis[in] The axis to command.

WMX3APIFUNC StartTrq(int axis, long maxMotorSpeed)

Start a TQ mode torque command.

Start a TQ mode torque command.

This function is an overloaded function of StartTrq that also sets the max motor speed. After the torque command is stopped or overridden, the max motor speed will remain at the specified value until modified by another function.

Remark

The torque profile must be first set with the SetTrqProfile function.

Parameters:
  • axis[in] The axis to command.

  • maxMotorSpeed[in] The maximum motor speed to apply, in units of rpm.

WMX3APIFUNC StartTrq(TrqCommand *pTrqCommand)

Start a TQ mode torque command.

Start a TQ mode torque command.

This function will start a torque command. The axis will apply a constant torque in the specified direction. Depending on the load on the axis, the axis may move during a torque command.

Remark

Parameters:

pTrqCommand[in] A pointer to an object of the TrqCommand class that contains the parameters of the torque command.

WMX3APIFUNC StartTrq(TrqCommand *pTrqCommand, long maxMotorSpeed)

Start a TQ mode torque command and set the maximum motor speed.

Start a TQ mode torque command and set the maximum motor speed.

This function is an overloaded function of StartTrq that also sets the max motor speed. After the torque command is stopped or overridden, the max motor speed will remain at the specified value until modified by another function.

Remark

For EtherCAT

When using EtherCAT, this function sets the value of object 0x6080 (Max Motor Speed). To change the max motor speed, overwrite this object.

Parameters:
  • pTrqCommand[in] A pointer to an object of the TrqCommand class that contains the parameters of the torque command.

  • maxMotorSpeed[in] The maximum motor speed to apply, in units of rpm.

WMX3APIFUNC StartTrq(unsigned int numCommands, TrqCommand *pTrqCommand)

Start TQ mode torque commands for multiple axes.

Start TQ mode torque commands for multiple axes.

This function executes the StartTrq API function for multiple axes.

Remark

Parameters:
  • numCommands[in] The number of torque commands. Each command controls a single axis.

  • pTrqCommand[in] A pointer to an array of objects of the TrqCommand class that contain the parameters of the torque commands. The number of elements in the array must equal numCommands.

WMX3APIFUNC StartTrq(unsigned int numCommands, TrqCommand *pTrqCommand, long *maxMotorSpeeds)

Start TQ mode torque commands for multiple axes.

Start TQ mode torque commands for multiple axes.

This function is an overloaded function of StartTrq that also sets the max motor speed. After the torque command is stopped or overridden, the max motor speed will remain at the specified value until modified by another function.

Remark

Parameters:
  • numCommands[in] The number of torque commands. Each command controls a single axis.

  • pTrqCommand[in] A pointer to an array of objects of the TrqCommand class that contain the parameters of the torque commands. The number of elements in the array must equal numCommands.

  • maxMotorSpeeds[in] The maximum motor speeds to apply, in units of rpm.

WMX3APIFUNC StopTrq(int axis)

Stop a TQ mode torque command.

Stop a TQ mode torque command.

This function will stop the torque command for an axis executing a TQ mode torque command.

Remark

For EtherCAT

This function sends a halt signal to the servo. PP, HM, PV, and TQ mode motion will be halted.

Parameters:

axis[in] The axis to stop.

WMX3APIFUNC StopTrq(AxisSelection *pAxisSelection)

Stop TQ mode torque commands for multiple axes.

Stop TQ mode torque commands for multiple axes.

This function is an overloaded function of StopTrq API function that stops TQ mode torque commands for multiple axes.

Remark

Parameters:

pAxisSelection[in] A pointer to an AxisSelection class that specifies the axes to stop.

Public Members

PMMotion *pmApi
class TrqCommand

This class contains data for a torque command.

Public Functions

TrqCommand()
TrqCommand(int axis, long torque)

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.