From 52f65c3dad515d715f948fa5cc479398996a5e29 Mon Sep 17 00:00:00 2001 From: Ron Sluiter Date: Wed, 21 May 2014 16:43:51 +0000 Subject: [PATCH] Added Corey Bonnell's (Aerotech) support for the Aerotech A3200 motor controller. --- motorApp/AerotechSrc/A3200CommonStructures.h | 1281 ++++++++++++++++++ motorApp/AerotechSrc/A3200ParameterId.h | 1117 +++++++++++++++ motorApp/AerotechSrc/AerotechRegister.cc | 66 +- motorApp/AerotechSrc/AerotechRegister.h | 3 +- motorApp/AerotechSrc/Makefile | 1 + motorApp/AerotechSrc/devAerotech.dbd | 3 + motorApp/AerotechSrc/drvA3200Asyn.cc | 963 +++++++++++++ motorApp/AerotechSrc/drvA3200Asyn.h | 65 + 8 files changed, 3483 insertions(+), 16 deletions(-) create mode 100644 motorApp/AerotechSrc/A3200CommonStructures.h create mode 100644 motorApp/AerotechSrc/A3200ParameterId.h create mode 100644 motorApp/AerotechSrc/drvA3200Asyn.cc create mode 100644 motorApp/AerotechSrc/drvA3200Asyn.h diff --git a/motorApp/AerotechSrc/A3200CommonStructures.h b/motorApp/AerotechSrc/A3200CommonStructures.h new file mode 100644 index 00000000..785ba207 --- /dev/null +++ b/motorApp/AerotechSrc/A3200CommonStructures.h @@ -0,0 +1,1281 @@ +/// \file A3200CommonStructures.h +/// \brief Contains some common structures and enumerations. +/// +/// Copyright (c) Aerotech, Inc. 2010-2013. +/// + +#ifndef __A3200_COMMON_STRUCTURES_H__ +#define __A3200_COMMON_STRUCTURES_H__ + +/// \brief This value represents information about the state of this task. +typedef enum +{ + /// \brief The Professional Option is not installed. You cannot use this task. + TASKSTATE_Unavailable = 0, + /// \brief This task was disabled by the EnabledTasks parameter. + TASKSTATE_Inactive = 1, + /// \brief No program is associated or running. + TASKSTATE_Idle = 2, + /// \brief A program is associated but not running. + TASKSTATE_ProgramReady = 3, + /// \brief A program is associated and running. + TASKSTATE_ProgramRunning = 4, + /// \brief A program is associated, was run, and was feedheld. This state is active from the moment the motion begins to decelerate due to a feedhold until the moment the motion begins to accelerate back to speed due to a feedhold release. + TASKSTATE_ProgramFeedheld = 5, + /// \brief A program is associated, was run, and was paused. + TASKSTATE_ProgramPaused = 6, + /// \brief A program is associated, was run, and completed. + TASKSTATE_ProgramComplete = 7, + /// \brief A task error occurred on this task. + TASKSTATE_Error = 8, + /// \brief This task is running in the queue mode. + TASKSTATE_Queue = 9, + /// \brief This task is reserved for use by the PLC. + TASKSTATE_PLCReserved = 10, +} TASKSTATE; + +/// \brief This value provides status information about this axis. The following table describes each bit of this value. More status information for the axis is reported in Drive Status. +typedef enum +{ + /// \brief The axis is homed. + AXISSTATUS_Homed = (1u << 0), + /// \brief The axis is performing coordinated (LINEAR, CW, CCW, BEZIER), RAPID, or PVT motion. + AXISSTATUS_Profiling = (1u << 1), + /// \brief The controller finished waiting for motion on this axis to complete. The behavior of this bit depends on the selected wait mode. When in WAIT MODE MOVEDONE, this bit will mimic the Move Done bit, but when in WAIT MODE INPOS, this bit will not be active until both the Move Done bit and the In Position bit are both active. + AXISSTATUS_WaitDone = (1u << 2), + /// \brief Motion on the axis is controlled from the SMC. + AXISSTATUS_CommandValid = (1u << 3), + /// \brief The axis is currently homing. + AXISSTATUS_Homing = (1u << 4), + /// \brief The axis is currently enabling. + AXISSTATUS_Enabling = (1u << 5), + /// \brief This bit represents internal status. + AXISSTATUS_JogGenerating = (1u << 7), + /// \brief The axis is performing asynchronous motion (MOVEINC, MOVEABS, FREERUN). + AXISSTATUS_Jogging = (1u << 8), + /// \brief The SMC sent a command to the drive that will cause the drive to take control of the motion, but the drive has not yet done so. + AXISSTATUS_DrivePending = (1u << 9), + /// \brief The SMC sent an abort command to the drive, but the drive has not yet started the abort. + AXISSTATUS_DriveAbortPending = (1u << 10), + /// \brief Trajectory filtering is enabled for this axis using either the TrajectoryIIRFilter or TrajectoryFIRFilter parameters. + AXISSTATUS_TrajectoryFiltering = (1u << 11), + /// \brief Infinite Field of View (IFV) is enabled for this axis. Enable IFV by issuing the GALVO IFV ON command. Disable IFV by issuing the GALVO IFV OFF command. + AXISSTATUS_IFVEnabled = (1u << 12), + /// \brief A physical drive is associated with this axis. Axes with no drive attached will clear this bit and operate as virtual axes. + AXISSTATUS_NotVirtual = (1u << 13), + /// \brief The specified 1D calibration file contains a calibration table that corrects this axis. The state of this bit is not affected by the CALENABLE or CALDISABLE commands. + AXISSTATUS_CalibrationEnabled1D = (1u << 14), + /// \brief The specified 2D calibration file contains a calibration table that corrects this axis. The state of this bit is not affected by the CALENABLE or CALDISABLE commands. + AXISSTATUS_CalibrationEnabled2D = (1u << 15), + /// \brief The axis is currently performing motion under master/slave control (gearing, camming, or handwheel). + AXISSTATUS_MasterSlaveControl = (1u << 16), + /// \brief The axis is currently performing motion under control of the JOYSTICK command. + AXISSTATUS_JoystickControl = (1u << 17), + /// \brief Backlash compensation is enabled for this axis using the BacklashDistance parameter or the BACKLASH ON command. + AXISSTATUS_BacklashActive = (1u << 18), + /// \brief A Gain Mapping table was specified for this axis. + AXISSTATUS_GainMappingEnabled = (1u << 19), + /// \brief The axis is considered to be stable as configured by the Stability0Threshold and Stability0Time parameters. + AXISSTATUS_Stability0 = (1u << 20), + /// \brief Motion on this axis is being prevented by the BLOCKMOTION command. + AXISSTATUS_MotionBlocked = (1u << 21), + /// \brief Motion on this axis is done, meaning that the velocity command reached zero. + AXISSTATUS_MoveDone = (1u << 22), + /// \brief Motion on this axis is being clamped due to a software limit clamp or safe zone. Refer to the SoftwareLimitSetup parameter, and the Safe zone overview. + AXISSTATUS_MotionClamped = (1u << 23), + /// \brief This axis is part of a gantry pair and the gantry is correctly aligned. This bit will not be active until the gantry axes have been homed. + AXISSTATUS_GantryAligned = (1u << 24), + /// \brief The axis is currently performing gantry realignment motion. + AXISSTATUS_GantryRealigning = (1u << 25), + /// \brief The axis is considered to be stable as configured by the Stability1Threshold and Stability1Time parameters. + AXISSTATUS_Stability1 = (1u << 26), +} AXISSTATUS; +typedef enum +{ + /// \brief The axis is homed. + AXISSTATUSBITS_HomedBit = 0, + /// \brief The axis is performing coordinated (LINEAR, CW, CCW, BEZIER), RAPID, or PVT motion. + AXISSTATUSBITS_ProfilingBit = 1, + /// \brief The controller finished waiting for motion on this axis to complete. The behavior of this bit depends on the selected wait mode. When in WAIT MODE MOVEDONE, this bit will mimic the Move Done bit, but when in WAIT MODE INPOS, this bit will not be active until both the Move Done bit and the In Position bit are both active. + AXISSTATUSBITS_WaitDoneBit = 2, + /// \brief Motion on the axis is controlled from the SMC. + AXISSTATUSBITS_CommandValidBit = 3, + /// \brief The axis is currently homing. + AXISSTATUSBITS_HomingBit = 4, + /// \brief The axis is currently enabling. + AXISSTATUSBITS_EnablingBit = 5, + /// \brief This bit represents internal status. + AXISSTATUSBITS_JogGeneratingBit = 7, + /// \brief The axis is performing asynchronous motion (MOVEINC, MOVEABS, FREERUN). + AXISSTATUSBITS_JoggingBit = 8, + /// \brief The SMC sent a command to the drive that will cause the drive to take control of the motion, but the drive has not yet done so. + AXISSTATUSBITS_DrivePendingBit = 9, + /// \brief The SMC sent an abort command to the drive, but the drive has not yet started the abort. + AXISSTATUSBITS_DriveAbortPendingBit = 10, + /// \brief Trajectory filtering is enabled for this axis using either the TrajectoryIIRFilter or TrajectoryFIRFilter parameters. + AXISSTATUSBITS_TrajectoryFilteringBit = 11, + /// \brief Infinite Field of View (IFV) is enabled for this axis. Enable IFV by issuing the GALVO IFV ON command. Disable IFV by issuing the GALVO IFV OFF command. + AXISSTATUSBITS_IFVEnabledBit = 12, + /// \brief A physical drive is associated with this axis. Axes with no drive attached will clear this bit and operate as virtual axes. + AXISSTATUSBITS_NotVirtualBit = 13, + /// \brief The specified 1D calibration file contains a calibration table that corrects this axis. The state of this bit is not affected by the CALENABLE or CALDISABLE commands. + AXISSTATUSBITS_CalibrationEnabled1DBit = 14, + /// \brief The specified 2D calibration file contains a calibration table that corrects this axis. The state of this bit is not affected by the CALENABLE or CALDISABLE commands. + AXISSTATUSBITS_CalibrationEnabled2DBit = 15, + /// \brief The axis is currently performing motion under master/slave control (gearing, camming, or handwheel). + AXISSTATUSBITS_MasterSlaveControlBit = 16, + /// \brief The axis is currently performing motion under control of the JOYSTICK command. + AXISSTATUSBITS_JoystickControlBit = 17, + /// \brief Backlash compensation is enabled for this axis using the BacklashDistance parameter or the BACKLASH ON command. + AXISSTATUSBITS_BacklashActiveBit = 18, + /// \brief A Gain Mapping table was specified for this axis. + AXISSTATUSBITS_GainMappingEnabledBit = 19, + /// \brief The axis is considered to be stable as configured by the Stability0Threshold and Stability0Time parameters. + AXISSTATUSBITS_Stability0Bit = 20, + /// \brief Motion on this axis is being prevented by the BLOCKMOTION command. + AXISSTATUSBITS_MotionBlockedBit = 21, + /// \brief Motion on this axis is done, meaning that the velocity command reached zero. + AXISSTATUSBITS_MoveDoneBit = 22, + /// \brief Motion on this axis is being clamped due to a software limit clamp or safe zone. Refer to the SoftwareLimitSetup parameter, and the Safe zone overview. + AXISSTATUSBITS_MotionClampedBit = 23, + /// \brief This axis is part of a gantry pair and the gantry is correctly aligned. This bit will not be active until the gantry axes have been homed. + AXISSTATUSBITS_GantryAlignedBit = 24, + /// \brief The axis is currently performing gantry realignment motion. + AXISSTATUSBITS_GantryRealigningBit = 25, + /// \brief The axis is considered to be stable as configured by the Stability1Threshold and Stability1Time parameters. + AXISSTATUSBITS_Stability1Bit = 26, +} AXISSTATUSBITS; + +/// \brief Represents the faults of an axis +typedef enum +{ + /// \brief The absolute value of the difference between the position command and the position feedback exceeded the threshold specified by the PositionErrorThreshold parameter. + AXISFAULT_PositionErrorFault = (1u << 0), + /// \brief The average motor current exceeded the threshold specified by the AverageCurrentThreshold and AverageCurrentTime parameters. + AXISFAULT_OverCurrentFault = (1u << 1), + /// \brief The axis encountered the clockwise (positive) end-of-travel limit switch. + AXISFAULT_CwEndOfTravelLimitFault = (1u << 2), + /// \brief The axis encountered the counter-clockwise (negative) end-of-travel limit switch. + AXISFAULT_CcwEndOfTravelLimitFault = (1u << 3), + /// \brief The axis was commanded to move beyond the position specified by the SoftwareLimitHigh parameter. + AXISFAULT_CwSoftwareLimitFault = (1u << 4), + /// \brief The axis was commanded to move beyond the position specified by the SoftwareLimitLow parameter. + AXISFAULT_CcwSoftwareLimitFault = (1u << 5), + /// \brief The amplifier for this axis exceeded its maximum current rating or experienced an internal error. + AXISFAULT_AmplifierFault = (1u << 6), + /// \brief The drive detected a problem with the feedback device specified by the PositionFeedbackType and PositionFeedbackChannel parameters. + AXISFAULT_PositionFeedbackFault = (1u << 7), + /// \brief The drive detected a problem with the feedback device specified by the VelocityFeedbackType and VelocityFeedbackChannel parameters. + AXISFAULT_VelocityFeedbackFault = (1u << 8), + /// \brief The drive detected an invalid state (all high or all low) for the Hall-effect sensor inputs on this axis. + AXISFAULT_HallSensorFault = (1u << 9), + /// \brief The commanded velocity is more than the velocity command threshold. Before the axis is homed, this threshold is specified by the VelocityCommandThresholdBeforeHome parameter. After the axis is homed, this threshold is specified by the VelocityCommandThreshold parameter. + AXISFAULT_MaxVelocityCommandFault = (1u << 10), + /// \brief The emergency stop sense input, specified by the ESTOPFaultInput parameter, was triggered. + AXISFAULT_EmergencyStopFault = (1u << 11), + /// \brief The absolute value of the difference between the velocity command and the velocity feedback exceeded the threshold specified by the VelocityErrorThreshold parameter. + AXISFAULT_VelocityErrorFault = (1u << 12), + /// \brief The user-defined touch probe input was triggered. + AXISFAULT_ProbeInputFault = (1u << 14), + /// \brief The external fault input, specified by the ExternalFaultAnalogInput or ExternalFaultDigitalInput parameters, was triggered. + AXISFAULT_ExternalFault = (1u << 15), + /// \brief The motor thermistor input was triggered, which indicates that the motor exceeded its maximum recommended operating temperature. + AXISFAULT_MotorTemperatureFault = (1u << 17), + /// \brief The amplifier exceeded its maximum recommended operating temperature. + AXISFAULT_AmplifierTemperatureFault = (1u << 18), + /// \brief The encoder fault input on the motor feedback connector was triggered. + AXISFAULT_EncoderFault = (1u << 19), + /// \brief One or more of the drives on the network lost communications with the controller. + AXISFAULT_CommunicationLostFault = (1u << 20), + /// \brief The difference between the position command/feedback of the master axis and the position command/feedback of the slave axis of a gantry exceeded the value specified by the GantrySeparationThreshold parameter. + AXISFAULT_GantryMisalignFault = (1u << 22), + /// \brief The difference between the position feedback and the scaled (adjusted by GainKv) velocity feedback exceeds the threshold specified by the PositionErrorThreshold parameter. + AXISFAULT_FeedbackScalingFault = (1u << 23), + /// \brief The distance that the axis moved while searching for the marker exceeded the threshold specified by the MarkerSearchThreshold parameter. + AXISFAULT_MarkerSearchFault = (1u << 24), + /// \brief The axis decelerated to a stop because the motion violated a safe zone. + AXISFAULT_SafeZoneFault = (1u << 25), + /// \brief The axis did not achieve in position status in the period specified by the InPositionDisableTimeout parameter. + AXISFAULT_InPositionTimeoutFault = (1u << 26), +} AXISFAULT; +typedef enum +{ + /// \brief The absolute value of the difference between the position command and the position feedback exceeded the threshold specified by the PositionErrorThreshold parameter. + AXISFAULTBITS_PositionErrorFaultBit = 0, + /// \brief The average motor current exceeded the threshold specified by the AverageCurrentThreshold and AverageCurrentTime parameters. + AXISFAULTBITS_OverCurrentFaultBit = 1, + /// \brief The axis encountered the clockwise (positive) end-of-travel limit switch. + AXISFAULTBITS_CwEndOfTravelLimitFaultBit = 2, + /// \brief The axis encountered the counter-clockwise (negative) end-of-travel limit switch. + AXISFAULTBITS_CcwEndOfTravelLimitFaultBit = 3, + /// \brief The axis was commanded to move beyond the position specified by the SoftwareLimitHigh parameter. + AXISFAULTBITS_CwSoftwareLimitFaultBit = 4, + /// \brief The axis was commanded to move beyond the position specified by the SoftwareLimitLow parameter. + AXISFAULTBITS_CcwSoftwareLimitFaultBit = 5, + /// \brief The amplifier for this axis exceeded its maximum current rating or experienced an internal error. + AXISFAULTBITS_AmplifierFaultBit = 6, + /// \brief The drive detected a problem with the feedback device specified by the PositionFeedbackType and PositionFeedbackChannel parameters. + AXISFAULTBITS_PositionFeedbackFaultBit = 7, + /// \brief The drive detected a problem with the feedback device specified by the VelocityFeedbackType and VelocityFeedbackChannel parameters. + AXISFAULTBITS_VelocityFeedbackFaultBit = 8, + /// \brief The drive detected an invalid state (all high or all low) for the Hall-effect sensor inputs on this axis. + AXISFAULTBITS_HallSensorFaultBit = 9, + /// \brief The commanded velocity is more than the velocity command threshold. Before the axis is homed, this threshold is specified by the VelocityCommandThresholdBeforeHome parameter. After the axis is homed, this threshold is specified by the VelocityCommandThreshold parameter. + AXISFAULTBITS_MaxVelocityCommandFaultBit = 10, + /// \brief The emergency stop sense input, specified by the ESTOPFaultInput parameter, was triggered. + AXISFAULTBITS_EmergencyStopFaultBit = 11, + /// \brief The absolute value of the difference between the velocity command and the velocity feedback exceeded the threshold specified by the VelocityErrorThreshold parameter. + AXISFAULTBITS_VelocityErrorFaultBit = 12, + /// \brief The user-defined touch probe input was triggered. + AXISFAULTBITS_ProbeInputFaultBit = 14, + /// \brief The external fault input, specified by the ExternalFaultAnalogInput or ExternalFaultDigitalInput parameters, was triggered. + AXISFAULTBITS_ExternalFaultBit = 15, + /// \brief The motor thermistor input was triggered, which indicates that the motor exceeded its maximum recommended operating temperature. + AXISFAULTBITS_MotorTemperatureFaultBit = 17, + /// \brief The amplifier exceeded its maximum recommended operating temperature. + AXISFAULTBITS_AmplifierTemperatureFaultBit = 18, + /// \brief The encoder fault input on the motor feedback connector was triggered. + AXISFAULTBITS_EncoderFaultBit = 19, + /// \brief One or more of the drives on the network lost communications with the controller. + AXISFAULTBITS_CommunicationLostFaultBit = 20, + /// \brief The difference between the position command/feedback of the master axis and the position command/feedback of the slave axis of a gantry exceeded the value specified by the GantrySeparationThreshold parameter. + AXISFAULTBITS_GantryMisalignFaultBit = 22, + /// \brief The difference between the position feedback and the scaled (adjusted by GainKv) velocity feedback exceeds the threshold specified by the PositionErrorThreshold parameter. + AXISFAULTBITS_FeedbackScalingFaultBit = 23, + /// \brief The distance that the axis moved while searching for the marker exceeded the threshold specified by the MarkerSearchThreshold parameter. + AXISFAULTBITS_MarkerSearchFaultBit = 24, + /// \brief The axis decelerated to a stop because the motion violated a safe zone. + AXISFAULTBITS_SafeZoneFaultBit = 25, + /// \brief The axis did not achieve in position status in the period specified by the InPositionDisableTimeout parameter. + AXISFAULTBITS_InPositionTimeoutFaultBit = 26, +} AXISFAULTBITS; + +/// \brief Represents the motor type +typedef enum +{ + /// \brief AC Brushless (Hall-Effect Switches) + MOTORTYPE_ACBrushlessHallEffect = 0, + /// \brief AC Brushless (Auto-MSET) + MOTORTYPE_ACBrushlessAutoMSET = 1, + /// \brief DC Brush + MOTORTYPE_DCBrush = 2, + /// \brief Stepper Motor + MOTORTYPE_StepperMotor = 3, + /// \brief Ceramic + MOTORTYPE_Ceramic = 4, + /// \brief AC Brushless Actuator + MOTORTYPE_ACBrushlessActuator = 5, + /// \brief 2-Phase AC Brushless + MOTORTYPE_TwoPhaseACBrushless = 6, + /// \brief AC Brushless (Commutation Search) + MOTORTYPE_ACBrushlessCommutationSearch = 7, + /// \brief Piezo Actuator + MOTORTYPE_PiezoActuator = 8, +} MOTORTYPE; + +/// \brief This value provides status information from the drive connected to this axis. The following table describes each bit of this value. More status information for the axis is reported in Axis Status. +typedef enum +{ + /// \brief The axis is enabled. + DRIVESTATUS_Enabled = (1u << 0), + /// \brief This represents the state of the CW end of travel limit input. It is not affected by the active polarity, which is configured by the EndOfTravelLimitSetup parameter. + DRIVESTATUS_CwEndOfTravelLimitInput = (1u << 1), + /// \brief This represents the state of the CCW end of travel limit input. It is not affected by the active polarity, which is configured by the EndOfTravelLimitSetup parameter. + DRIVESTATUS_CcwEndOfTravelLimitInput = (1u << 2), + /// \brief This represents the state of the home limit input. It is not affected by the active polarity, which is configured by the EndOfTravelLimitSetup parameter. + DRIVESTATUS_HomeLimitInput = (1u << 3), + /// \brief This represents the state of the marker input. + DRIVESTATUS_MarkerInput = (1u << 4), + /// \brief This represents the state of the Hall-effect sensor A input. + DRIVESTATUS_HallAInput = (1u << 5), + /// \brief This represents the state of the Hall-effect sensor B input. + DRIVESTATUS_HallBInput = (1u << 6), + /// \brief This represents the state of the Hall-effect sensor C input. + DRIVESTATUS_HallCInput = (1u << 7), + /// \brief An error condition is present on the Sine encoder input of the position feedback device. + DRIVESTATUS_SineEncoderError = (1u << 8), + /// \brief An error condition is present on the Cosine encoder input of the position feedback device. + DRIVESTATUS_CosineEncoderError = (1u << 9), + /// \brief This represents the state of the emergency stop sense input. + DRIVESTATUS_EmergencyStopInput = (1u << 10), + /// \brief This represents the state of the dedicated brake output. + DRIVESTATUS_BrakeOutput = (1u << 11), + /// \brief The galvo command FIFO for this axis is full. + DRIVESTATUS_GalvoFifoFull = (1u << 12), + /// \brief The galvo axis is operating in submillisecond trajectory mode. + DRIVESTATUS_GalvoSubMsecMode = (1u << 13), + /// \brief The drive detected that no motor supply voltage is present. + DRIVESTATUS_NoMotorSupply = (1u << 14), + /// \brief The motor output is being clamped to the value specified by the MaxCurrentClamp parameter. + DRIVESTATUS_CurrentClamp = (1u << 15), + /// \brief The position of the marker is latched. + DRIVESTATUS_MarkerLatch = (1u << 16), + /// \brief The motor output is being limited to prevent damage to the amplifier. + DRIVESTATUS_PowerLimiting = (1u << 17), + /// \brief Internal drive state was latched by the PSOHALT logic. + DRIVESTATUS_PSOHaltLatch = (1u << 18), + /// \brief The amplifier is operating in high resolution current feedback mode. + DRIVESTATUS_HighResolutionMode = (1u << 19), + /// \brief The specified 2D calibration file contains a galvo calibration table that corrects this axis. + DRIVESTATUS_GalvoCalibrationEnabled = (1u << 20), + /// \brief The axis is operating under control of the AUTOFOCUS loop. + DRIVESTATUS_AutofocusActive = (1u << 21), + /// \brief The drive is programming its internal flash memory. + DRIVESTATUS_ProgrammingFlash = (1u << 22), + /// \brief The on-board encoder multiplier is performing a programming operation. + DRIVESTATUS_ProgrammingMXH = (1u << 23), + /// \brief The axis is operating under servo control. + DRIVESTATUS_ServoControl = (1u << 24), + /// \brief The axis is considered to be in position as configured by the InPositionDistance and InPositionTime parameters. + DRIVESTATUS_InPosition = (1u << 25), + /// \brief The axis is performing drive generated motion. + DRIVESTATUS_MoveActive = (1u << 26), + /// \brief The axis is accelerating. + DRIVESTATUS_AccelerationPhase = (1u << 27), + /// \brief The axis is decelerating. + DRIVESTATUS_DecelerationPhase = (1u << 28), + /// \brief The on-board encoder multiplier detected that the input signals may be exceeding the maximum input range, which results in clipping of the encoder signals. + DRIVESTATUS_EncoderClipping = (1u << 29), + /// \brief The axis is operating in dual-loop mode using two different feedback devices. + DRIVESTATUS_DualLoopActive = (1u << 30), + /// \brief The axis is considered to be in position as configured by the InPosition2Distance and InPosition2Time parameters. + DRIVESTATUS_InPosition2 = (1u << 31), +} DRIVESTATUS; +typedef enum +{ + /// \brief The axis is enabled. + DRIVESTATUSBITS_EnabledBit = 0, + /// \brief This represents the state of the CW end of travel limit input. It is not affected by the active polarity, which is configured by the EndOfTravelLimitSetup parameter. + DRIVESTATUSBITS_CwEndOfTravelLimitInputBit = 1, + /// \brief This represents the state of the CCW end of travel limit input. It is not affected by the active polarity, which is configured by the EndOfTravelLimitSetup parameter. + DRIVESTATUSBITS_CcwEndOfTravelLimitInputBit = 2, + /// \brief This represents the state of the home limit input. It is not affected by the active polarity, which is configured by the EndOfTravelLimitSetup parameter. + DRIVESTATUSBITS_HomeLimitInputBit = 3, + /// \brief This represents the state of the marker input. + DRIVESTATUSBITS_MarkerInputBit = 4, + /// \brief This represents the state of the Hall-effect sensor A input. + DRIVESTATUSBITS_HallAInputBit = 5, + /// \brief This represents the state of the Hall-effect sensor B input. + DRIVESTATUSBITS_HallBInputBit = 6, + /// \brief This represents the state of the Hall-effect sensor C input. + DRIVESTATUSBITS_HallCInputBit = 7, + /// \brief An error condition is present on the Sine encoder input of the position feedback device. + DRIVESTATUSBITS_SineEncoderErrorBit = 8, + /// \brief An error condition is present on the Cosine encoder input of the position feedback device. + DRIVESTATUSBITS_CosineEncoderErrorBit = 9, + /// \brief This represents the state of the emergency stop sense input. + DRIVESTATUSBITS_EmergencyStopInputBit = 10, + /// \brief This represents the state of the dedicated brake output. + DRIVESTATUSBITS_BrakeOutputBit = 11, + /// \brief The galvo command FIFO for this axis is full. + DRIVESTATUSBITS_GalvoFifoFullBit = 12, + /// \brief The galvo axis is operating in submillisecond trajectory mode. + DRIVESTATUSBITS_GalvoSubMsecModeBit = 13, + /// \brief The drive detected that no motor supply voltage is present. + DRIVESTATUSBITS_NoMotorSupplyBit = 14, + /// \brief The motor output is being clamped to the value specified by the MaxCurrentClamp parameter. + DRIVESTATUSBITS_CurrentClampBit = 15, + /// \brief The position of the marker is latched. + DRIVESTATUSBITS_MarkerLatchBit = 16, + /// \brief The motor output is being limited to prevent damage to the amplifier. + DRIVESTATUSBITS_PowerLimitingBit = 17, + /// \brief Internal drive state was latched by the PSOHALT logic. + DRIVESTATUSBITS_PSOHaltLatchBit = 18, + /// \brief The amplifier is operating in high resolution current feedback mode. + DRIVESTATUSBITS_HighResolutionModeBit = 19, + /// \brief The specified 2D calibration file contains a galvo calibration table that corrects this axis. + DRIVESTATUSBITS_GalvoCalibrationEnabledBit = 20, + /// \brief The axis is operating under control of the AUTOFOCUS loop. + DRIVESTATUSBITS_AutofocusActiveBit = 21, + /// \brief The drive is programming its internal flash memory. + DRIVESTATUSBITS_ProgrammingFlashBit = 22, + /// \brief The on-board encoder multiplier is performing a programming operation. + DRIVESTATUSBITS_ProgrammingMXHBit = 23, + /// \brief The axis is operating under servo control. + DRIVESTATUSBITS_ServoControlBit = 24, + /// \brief The axis is considered to be in position as configured by the InPositionDistance and InPositionTime parameters. + DRIVESTATUSBITS_InPositionBit = 25, + /// \brief The axis is performing drive generated motion. + DRIVESTATUSBITS_MoveActiveBit = 26, + /// \brief The axis is accelerating. + DRIVESTATUSBITS_AccelerationPhaseBit = 27, + /// \brief The axis is decelerating. + DRIVESTATUSBITS_DecelerationPhaseBit = 28, + /// \brief The on-board encoder multiplier detected that the input signals may be exceeding the maximum input range, which results in clipping of the encoder signals. + DRIVESTATUSBITS_EncoderClippingBit = 29, + /// \brief The axis is operating in dual-loop mode using two different feedback devices. + DRIVESTATUSBITS_DualLoopActiveBit = 30, + /// \brief The axis is considered to be in position as configured by the InPosition2Distance and InPosition2Time parameters. + DRIVESTATUSBITS_InPosition2Bit = 31, +} DRIVESTATUSBITS; + +/// \brief Represents the task execution modes +typedef enum +{ + /// \brief Run into subroutines + TASKEXECUTIONMODE_RunInto = 0, + /// \brief Step into subroutines + TASKEXECUTIONMODE_StepInto = 1, + /// \brief Step over subroutines + TASKEXECUTIONMODE_StepOver = 2, + /// \brief Run over subroutines + TASKEXECUTIONMODE_RunOver = 3, +} TASKEXECUTIONMODE; + +/// \brief Represents the program automation modes +typedef enum +{ + /// \brief Automatically include the given file into any program that is compiled + PROGRAMAUTOMATIONMODE_Include = 0, + /// \brief Download file so it can be called into later on + PROGRAMAUTOMATIONMODE_Download = 1, + /// \brief Run file silently + PROGRAMAUTOMATIONMODE_RunSilent = 2, + /// \brief Run file + PROGRAMAUTOMATIONMODE_Run = 3, + /// \brief Download file and associate to a task but do not start execution + PROGRAMAUTOMATIONMODE_DownloadAndAssociate = 5, +} PROGRAMAUTOMATIONMODE; + +/// \brief Represents the units types +typedef enum +{ + /// \brief Secondary units + UNITSTYPE_Secondary = 0, + /// \brief Primary units + UNITSTYPE_Primary = 1, +} UNITSTYPE; + +/// \brief This value provides status information about this task. The following table describes each bit of this value. More status information for the task is reported in Task Status 1, Task Status 2, and Task Mode. +typedef enum +{ + /// \brief A program is associated with this task. + TASKSTATUS0_ProgramAssociated = (1u << 0), + /// \brief An immediate command is executing concurrently with a program. + TASKSTATUS0_ImmediateConcurrent = (1u << 2), + /// \brief An immediate command is executing. + TASKSTATUS0_ImmediateExecuting = (1u << 3), + /// \brief A return motion is executing due to an INTERRUPTMOTION command. + TASKSTATUS0_ReturnMotionExecuting = (1u << 4), + /// \brief The program is stopped. + TASKSTATUS0_ProgramStopped = (1u << 5), + /// \brief The task is using step into mode. + TASKSTATUS0_SingleStepInto = (1u << 6), + /// \brief The task is using step over mode. + TASKSTATUS0_SingleStepOver = (1u << 7), + /// \brief The program is reset. + TASKSTATUS0_ProgramReset = (1u << 8), + /// \brief One or more axes are decelerating due to an abort, task stop, task error, feedhold, ongosub, or retrace direction reversal that occurs during a RAPID, LINEAR, CW, CCW, or BEZIER motion. + TASKSTATUS0_PendingAxesStop = (1u << 9), + /// \brief A Software Emergency Stop is active as configured by the SoftwareESTOPInput parameter. + TASKSTATUS0_SoftwareESTOPActive = (1u << 10), + /// \brief Bit turns on as soon as motion begins to decelerate due to a feedhold. Bit turns off when motion begins to accelerate back to speed due to a feedhold release. The FeedHeldAxesStopped bit of Task Status 1 indicates when deceleration due to a feedhold stops. + TASKSTATUS0_FeedHoldActive = (1u << 11), + /// \brief A callback command was issued and is waiting for a front-end application to acknowledge the command. + TASKSTATUS0_CallbackHoldActive = (1u << 12), + /// \brief A callback command was issued and is waiting for a front-end application to handle the command. + TASKSTATUS0_CallbackResponding = (1u << 13), + /// \brief Spindle 0 is active. + TASKSTATUS0_SpindleActive0 = (1u << 14), + /// \brief Spindle 1 is active. + TASKSTATUS0_SpindleActive1 = (1u << 15), + /// \brief Spindle 2 is active. + TASKSTATUS0_SpindleActive2 = (1u << 16), + /// \brief Spindle 3 is active. + TASKSTATUS0_SpindleActive3 = (1u << 17), + /// \brief Represents the state of the probe. + TASKSTATUS0_ProbeCycle = (1u << 18), + /// \brief Retrace is active. + TASKSTATUS0_Retrace = (1u << 19), + /// \brief The POSOFFSET Command was used to set position offsets. + TASKSTATUS0_SoftHomeActive = (1u << 20), + /// \brief Interrupt motion is active. + TASKSTATUS0_InterruptMotionActive = (1u << 21), + /// \brief The task is executing a JOYSTICK Command. + TASKSTATUS0_JoystickActive = (1u << 22), + /// \brief Corner rounding is enabled. + TASKSTATUS0_CornerRounding = (1u << 23), + /// \brief The task is reserved for use by the PLC + TASKSTATUS0_PLCReserved = (1u << 24), + /// \brief The joystick is using the low speed mode. + TASKSTATUS0_JoystickLowSpeedActive = (1u << 25), + /// \brief A canned function is active. + TASKSTATUS0_CannedFunctionActive = (1u << 26), + /// \brief A canned function is executing. + TASKSTATUS0_CannedFunctionExecuting = (1u << 27), + /// \brief The task is executing Galvo Commands. + TASKSTATUS0_GalvoMode = (1u << 28), + /// \brief The task has control restrictions enabled. + TASKSTATUS0_ProgramControlRestricted = (1u << 29), +} TASKSTATUS0; +typedef enum +{ + /// \brief A program is associated with this task. + TASKSTATUS0BITS_ProgramAssociatedBit = 0, + /// \brief An immediate command is executing concurrently with a program. + TASKSTATUS0BITS_ImmediateConcurrentBit = 2, + /// \brief An immediate command is executing. + TASKSTATUS0BITS_ImmediateExecutingBit = 3, + /// \brief A return motion is executing due to an INTERRUPTMOTION command. + TASKSTATUS0BITS_ReturnMotionExecutingBit = 4, + /// \brief The program is stopped. + TASKSTATUS0BITS_ProgramStoppedBit = 5, + /// \brief The task is using step into mode. + TASKSTATUS0BITS_SingleStepIntoBit = 6, + /// \brief The task is using step over mode. + TASKSTATUS0BITS_SingleStepOverBit = 7, + /// \brief The program is reset. + TASKSTATUS0BITS_ProgramResetBit = 8, + /// \brief One or more axes are decelerating due to an abort, task stop, task error, feedhold, ongosub, or retrace direction reversal that occurs during a RAPID, LINEAR, CW, CCW, or BEZIER motion. + TASKSTATUS0BITS_PendingAxesStopBit = 9, + /// \brief A Software Emergency Stop is active as configured by the SoftwareESTOPInput parameter. + TASKSTATUS0BITS_SoftwareESTOPActiveBit = 10, + /// \brief Bit turns on as soon as motion begins to decelerate due to a feedhold. Bit turns off when motion begins to accelerate back to speed due to a feedhold release. The FeedHeldAxesStopped bit of Task Status 1 indicates when deceleration due to a feedhold stops. + TASKSTATUS0BITS_FeedHoldActiveBit = 11, + /// \brief A callback command was issued and is waiting for a front-end application to acknowledge the command. + TASKSTATUS0BITS_CallbackHoldActiveBit = 12, + /// \brief A callback command was issued and is waiting for a front-end application to handle the command. + TASKSTATUS0BITS_CallbackRespondingBit = 13, + /// \brief Spindle 0 is active. + TASKSTATUS0BITS_SpindleActive0Bit = 14, + /// \brief Spindle 1 is active. + TASKSTATUS0BITS_SpindleActive1Bit = 15, + /// \brief Spindle 2 is active. + TASKSTATUS0BITS_SpindleActive2Bit = 16, + /// \brief Spindle 3 is active. + TASKSTATUS0BITS_SpindleActive3Bit = 17, + /// \brief Represents the state of the probe. + TASKSTATUS0BITS_ProbeCycleBit = 18, + /// \brief Retrace is active. + TASKSTATUS0BITS_RetraceBit = 19, + /// \brief The POSOFFSET Command was used to set position offsets. + TASKSTATUS0BITS_SoftHomeActiveBit = 20, + /// \brief Interrupt motion is active. + TASKSTATUS0BITS_InterruptMotionActiveBit = 21, + /// \brief The task is executing a JOYSTICK Command. + TASKSTATUS0BITS_JoystickActiveBit = 22, + /// \brief Corner rounding is enabled. + TASKSTATUS0BITS_CornerRoundingBit = 23, + /// \brief The task is reserved for use by the PLC + TASKSTATUS0BITS_PLCReservedBit = 24, + /// \brief The joystick is using the low speed mode. + TASKSTATUS0BITS_JoystickLowSpeedActiveBit = 25, + /// \brief A canned function is active. + TASKSTATUS0BITS_CannedFunctionActiveBit = 26, + /// \brief A canned function is executing. + TASKSTATUS0BITS_CannedFunctionExecutingBit = 27, + /// \brief The task is executing Galvo Commands. + TASKSTATUS0BITS_GalvoModeBit = 28, + /// \brief The task has control restrictions enabled. + TASKSTATUS0BITS_ProgramControlRestrictedBit = 29, +} TASKSTATUS0BITS; + +/// \brief This value provides status information about this task. The following table describes each bit of this value. More status information for the task is reported in Task Status 0, Task Status 2, and Task Mode. +typedef enum +{ + /// \brief Circular center points are specified in absolute coordinates. + TASKSTATUS1_MotionModeAbsOffsets = (1u << 0), + /// \brief An asynchronous motion is aborting. + TASKSTATUS1_AsyncSMCMotionAbortPending = (1u << 1), + /// \brief The controller interrupted execution of the program and decelerated all motion due to a change in the direction of MFO. The controller is pending execution of the program. + TASKSTATUS1_RetraceReversalPending = (1u << 2), + /// \brief A retrace operation was requested. + TASKSTATUS1_RetraceRequested = (1u << 3), + /// \brief An MSO change was issued. + TASKSTATUS1_MSOChange = (1u << 4), + /// \brief A spindle is feedheld. + TASKSTATUS1_SpindleFeedHeld = (1u << 5), + /// \brief Bit turns on as soon as deceleration due to a feedhold ends. Bit turns off when motion begins to accelerate back to speed due to a feedhold release. The FeedHoldActive bit of Task Status 0 indicates when a feedhold is issued. + TASKSTATUS1_FeedHeldAxesStopped = (1u << 6), + /// \brief Cutter radius compensation is performing a lead-on move. + TASKSTATUS1_CutterRadiusEnabling = (1u << 7), + /// \brief Cutter radius compensation is performing a lead-off move. + TASKSTATUS1_CutterRadiusDisabling = (1u << 8), + /// \brief Cutter offset compensation is performing a lead-on positive move. + TASKSTATUS1_CutterOffsetsEnablingPositive = (1u << 9), + /// \brief Cutter offset compensation is performing a lead-on negative move. + TASKSTATUS1_CutterOffsetsEnablingNegative = (1u << 10), + /// \brief Cutter offset compensation is performing a lead-off move. + TASKSTATUS1_CutterOffsetsDisabling = (1u << 11), + /// \brief An MFO change was issued. + TASKSTATUS1_MFOChange = (1u << 12), + /// \brief A axis fault or task error event was triggered. + TASKSTATUS1_InterruptFaultPending = (1u << 13), + /// \brief An ongosub is pending. + TASKSTATUS1_OnGosubPending = (1u << 15), + /// \brief A program stop is pending. + TASKSTATUS1_ProgramStopPending = (1u << 16), + /// \brief A canned function is pending. + TASKSTATUS1_CannedFunctionPending = (1u << 17), + /// \brief The MinimumMFO parameter is negative. + TASKSTATUS1_NoMFOFloor = (1u << 18), + /// \brief This bit represents internal status. + TASKSTATUS1_Interrupted = (1u << 19), + /// \brief The task is switching into Galvo mode. + TASKSTATUS1_GalvoSwitchingIn = (1u << 21), + /// \brief The task is switching out of Galvo mode. + TASKSTATUS1_GalvoSwitchingOut = (1u << 22), + /// \brief This bit represents internal status. + TASKSTATUS1_ProgramSuppressed = (1u << 23), + /// \brief This bit represents internal status. + TASKSTATUS1_GalvoIFVDeactivationPending = (1u << 24), +} TASKSTATUS1; +typedef enum +{ + /// \brief Circular center points are specified in absolute coordinates. + TASKSTATUS1BITS_MotionModeAbsOffsetsBit = 0, + /// \brief An asynchronous motion is aborting. + TASKSTATUS1BITS_AsyncSMCMotionAbortPendingBit = 1, + /// \brief The controller interrupted execution of the program and decelerated all motion due to a change in the direction of MFO. The controller is pending execution of the program. + TASKSTATUS1BITS_RetraceReversalPendingBit = 2, + /// \brief A retrace operation was requested. + TASKSTATUS1BITS_RetraceRequestedBit = 3, + /// \brief An MSO change was issued. + TASKSTATUS1BITS_MSOChangeBit = 4, + /// \brief A spindle is feedheld. + TASKSTATUS1BITS_SpindleFeedHeldBit = 5, + /// \brief Bit turns on as soon as deceleration due to a feedhold ends. Bit turns off when motion begins to accelerate back to speed due to a feedhold release. The FeedHoldActive bit of Task Status 0 indicates when a feedhold is issued. + TASKSTATUS1BITS_FeedHeldAxesStoppedBit = 6, + /// \brief Cutter radius compensation is performing a lead-on move. + TASKSTATUS1BITS_CutterRadiusEnablingBit = 7, + /// \brief Cutter radius compensation is performing a lead-off move. + TASKSTATUS1BITS_CutterRadiusDisablingBit = 8, + /// \brief Cutter offset compensation is performing a lead-on positive move. + TASKSTATUS1BITS_CutterOffsetsEnablingPositiveBit = 9, + /// \brief Cutter offset compensation is performing a lead-on negative move. + TASKSTATUS1BITS_CutterOffsetsEnablingNegativeBit = 10, + /// \brief Cutter offset compensation is performing a lead-off move. + TASKSTATUS1BITS_CutterOffsetsDisablingBit = 11, + /// \brief An MFO change was issued. + TASKSTATUS1BITS_MFOChangeBit = 12, + /// \brief A axis fault or task error event was triggered. + TASKSTATUS1BITS_InterruptFaultPendingBit = 13, + /// \brief An ongosub is pending. + TASKSTATUS1BITS_OnGosubPendingBit = 15, + /// \brief A program stop is pending. + TASKSTATUS1BITS_ProgramStopPendingBit = 16, + /// \brief A canned function is pending. + TASKSTATUS1BITS_CannedFunctionPendingBit = 17, + /// \brief The MinimumMFO parameter is negative. + TASKSTATUS1BITS_NoMFOFloorBit = 18, + /// \brief This bit represents internal status. + TASKSTATUS1BITS_InterruptedBit = 19, + /// \brief The task is switching into Galvo mode. + TASKSTATUS1BITS_GalvoSwitchingInBit = 21, + /// \brief The task is switching out of Galvo mode. + TASKSTATUS1BITS_GalvoSwitchingOutBit = 22, + /// \brief This bit represents internal status. + TASKSTATUS1BITS_ProgramSuppressedBit = 23, + /// \brief This bit represents internal status. + TASKSTATUS1BITS_GalvoIFVDeactivationPendingBit = 24, +} TASKSTATUS1BITS; + +/// \brief This value provides status information about this task. The following table describes each bit of this value. More status information for the task is reported in Task Status 0, Task Status 1, and Task Mode. +typedef enum +{ + /// \brief The Parts Rotation Transformation is active. + TASKSTATUS2_RotationActive = (1u << 0), + /// \brief The Polar Coordinate Transformation is active. + TASKSTATUS2_RThetaPolarActive = (1u << 1), + /// \brief The Cylindrical Coordinate Transformation is active. + TASKSTATUS2_RThetaCylindricalActive = (1u << 2), + /// \brief Parts scaling is active. + TASKSTATUS2_ScalingActive = (1u << 3), + /// \brief Fixture offsets are active. + TASKSTATUS2_OffsetFixtureActive = (1u << 4), + /// \brief Profile motion is active. + TASKSTATUS2_ProfileActive = (1u << 5), + /// \brief Rapid motion is active. + TASKSTATUS2_MotionModeRapid = (1u << 6), + /// \brief Coordinated motion is active. + TASKSTATUS2_MotionModeCoordinated = (1u << 7), + /// \brief PVT motion is being executed. + TASKSTATUS2_MotionPVT = (1u << 8), + /// \brief The task is actively velocity profiling. + TASKSTATUS2_MotionContinuousActive = (1u << 9), + /// \brief Instantaneous acceleration will occur at the beginning of the move. + TASKSTATUS2_MotionNoAccel = (1u << 10), + /// \brief FIBER motion is active. + TASKSTATUS2_MotionFiber = (1u << 11), + /// \brief Positive cutter offset compensation is active. + TASKSTATUS2_CutterOffsetsActivePos = (1u << 12), + /// \brief Cutter radius compensation left is active. + TASKSTATUS2_CutterRadiusActiveLeft = (1u << 13), + /// \brief Cutter radius compensation right is active. + TASKSTATUS2_CutterRadiusActiveRight = (1u << 14), + /// \brief Negative cutter offset compensation is active. + TASKSTATUS2_CutterOffsetsActiveNeg = (1u << 15), + /// \brief Normalcy left is active. + TASKSTATUS2_NormalcyActiveLeft = (1u << 16), + /// \brief Normalcy right is active. + TASKSTATUS2_NormalcyActiveRight = (1u << 17), + /// \brief A normalcy alignment move is being performed. + TASKSTATUS2_NormalcyAlignment = (1u << 18), + /// \brief The motion mode is CW. + TASKSTATUS2_MotionModeCW = (1u << 19), + /// \brief The motion mode is CCW. + TASKSTATUS2_MotionModeCCW = (1u << 20), + /// \brief Feedrate limiting is active. + TASKSTATUS2_LimitFeedRateActive = (1u << 21), + /// \brief MFO limiting is active. + TASKSTATUS2_LimitMFOActive = (1u << 22), + /// \brief Coordinate System 1 Plane 1 is active. + TASKSTATUS2_Coord1Plane1 = (1u << 23), + /// \brief Coordinate System 1 Plane 2 is active. + TASKSTATUS2_Coord1Plane2 = (1u << 24), + /// \brief Coordinate System 1 Plane 3 is active. + TASKSTATUS2_Coord1Plane3 = (1u << 25), + /// \brief Coordinate System 2 Plane 1 is active. + TASKSTATUS2_Coord2Plane1 = (1u << 26), + /// \brief Coordinate System 2 Plane 2 is active. + TASKSTATUS2_Coord2Plane2 = (1u << 27), + /// \brief Coordinate System 2 Plane 3 is active. + TASKSTATUS2_Coord2Plane3 = (1u << 28), + /// \brief Mirroring is active. + TASKSTATUS2_MirrorActive = (1u << 30), +} TASKSTATUS2; +typedef enum +{ + /// \brief The Parts Rotation Transformation is active. + TASKSTATUS2BITS_RotationActiveBit = 0, + /// \brief The Polar Coordinate Transformation is active. + TASKSTATUS2BITS_RThetaPolarActiveBit = 1, + /// \brief The Cylindrical Coordinate Transformation is active. + TASKSTATUS2BITS_RThetaCylindricalActiveBit = 2, + /// \brief Parts scaling is active. + TASKSTATUS2BITS_ScalingActiveBit = 3, + /// \brief Fixture offsets are active. + TASKSTATUS2BITS_OffsetFixtureActiveBit = 4, + /// \brief Profile motion is active. + TASKSTATUS2BITS_ProfileActiveBit = 5, + /// \brief Rapid motion is active. + TASKSTATUS2BITS_MotionModeRapidBit = 6, + /// \brief Coordinated motion is active. + TASKSTATUS2BITS_MotionModeCoordinatedBit = 7, + /// \brief PVT motion is being executed. + TASKSTATUS2BITS_MotionPVTBit = 8, + /// \brief The task is actively velocity profiling. + TASKSTATUS2BITS_MotionContinuousActiveBit = 9, + /// \brief Instantaneous acceleration will occur at the beginning of the move. + TASKSTATUS2BITS_MotionNoAccelBit = 10, + /// \brief FIBER motion is active. + TASKSTATUS2BITS_MotionFiberBit = 11, + /// \brief Positive cutter offset compensation is active. + TASKSTATUS2BITS_CutterOffsetsActivePosBit = 12, + /// \brief Cutter radius compensation left is active. + TASKSTATUS2BITS_CutterRadiusActiveLeftBit = 13, + /// \brief Cutter radius compensation right is active. + TASKSTATUS2BITS_CutterRadiusActiveRightBit = 14, + /// \brief Negative cutter offset compensation is active. + TASKSTATUS2BITS_CutterOffsetsActiveNegBit = 15, + /// \brief Normalcy left is active. + TASKSTATUS2BITS_NormalcyActiveLeftBit = 16, + /// \brief Normalcy right is active. + TASKSTATUS2BITS_NormalcyActiveRightBit = 17, + /// \brief A normalcy alignment move is being performed. + TASKSTATUS2BITS_NormalcyAlignmentBit = 18, + /// \brief The motion mode is CW. + TASKSTATUS2BITS_MotionModeCWBit = 19, + /// \brief The motion mode is CCW. + TASKSTATUS2BITS_MotionModeCCWBit = 20, + /// \brief Feedrate limiting is active. + TASKSTATUS2BITS_LimitFeedRateActiveBit = 21, + /// \brief MFO limiting is active. + TASKSTATUS2BITS_LimitMFOActiveBit = 22, + /// \brief Coordinate System 1 Plane 1 is active. + TASKSTATUS2BITS_Coord1Plane1Bit = 23, + /// \brief Coordinate System 1 Plane 2 is active. + TASKSTATUS2BITS_Coord1Plane2Bit = 24, + /// \brief Coordinate System 1 Plane 3 is active. + TASKSTATUS2BITS_Coord1Plane3Bit = 25, + /// \brief Coordinate System 2 Plane 1 is active. + TASKSTATUS2BITS_Coord2Plane1Bit = 26, + /// \brief Coordinate System 2 Plane 2 is active. + TASKSTATUS2BITS_Coord2Plane2Bit = 27, + /// \brief Coordinate System 2 Plane 3 is active. + TASKSTATUS2BITS_Coord2Plane3Bit = 28, + /// \brief Mirroring is active. + TASKSTATUS2BITS_MirrorActiveBit = 30, +} TASKSTATUS2BITS; + +/// \brief This value provides status information about this task. The following table describes each bit of this value. More status information for the task is reported in Task Status 0, Task Status 1, and Task Status 2. +typedef enum +{ + /// \brief Secondary units mode is in use. + TASKMODE_Secondary = (1u << 0), + /// \brief Absolute programming mode is in use. + TASKMODE_Absolute = (1u << 1), + /// \brief The acceleration type is configured for linear ramping. + TASKMODE_AccelTypeLinear = (1u << 2), + /// \brief The acceleration mode is rate-based. + TASKMODE_AccelModeRate = (1u << 3), + /// \brief Inverse dominance (G98) mode is active. + TASKMODE_InverseDominance = (1u << 4), + /// \brief Motion continuous (VELOCITY ON) mode is active. + TASKMODE_MotionContinuous = (1u << 5), + /// \brief Inverse circular (G111) mode is active. + TASKMODE_InverseCircular = (1u << 6), + /// \brief Spindles will abort on a program stop (G101). + TASKMODE_SpindleStopOnProgramHalt = (1u << 7), + /// \brief Block Delete mode is active (G112). + TASKMODE_BlockDelete = (1u << 8), + /// \brief Optional Pause mode is active (G114). + TASKMODE_OptionalPause = (1u << 9), + /// \brief The acceleration type is configured for scurve ramping. + TASKMODE_AccelTypeScurve = (1u << 10), + /// \brief MFO Lock mode is active (M48). + TASKMODE_MFOLock = (1u << 11), + /// \brief MSO Lock mode is active (M50). + TASKMODE_MSOLock = (1u << 12), + /// \brief The deceleration type is configured for linear ramping. + TASKMODE_DecelTypeLinear = (1u << 13), + /// \brief The deceleration type is configured for scurve ramping. + TASKMODE_DecelTypeScurve = (1u << 14), + /// \brief When this bit is true the task is executing in Auto mode. When this bit is false the task is executing in Step mode. + TASKMODE_AutoMode = (1u << 15), + /// \brief Programmed feed rates are specified in MPU (G93). + TASKMODE_ProgramFeedRateMPU = (1u << 16), + /// \brief Programmed feed rates are specified in units per revolution (G95). + TASKMODE_ProgramFeedRateUPR = (1u << 17), + /// \brief Block Delete 2 mode is active (G212). + TASKMODE_BlockDelete2 = (1u << 22), + /// \brief When this bit is true the task is executing in Over mode. When this bit is false the task is executing in Into mode. + TASKMODE_OverMode = (1u << 23), + /// \brief The deceleration mode is rate-based. + TASKMODE_DecelModeRate = (1u << 24), + /// \brief The task is using High-Speed Lookahead (LOOKAHEAD FAST). + TASKMODE_HighSpeedLookAhead = (1u << 25), + /// \brief MFO will affect asynchronous motion (OVERRIDEASYNC ON). + TASKMODE_MFOActiveOnJog = (1u << 26), + /// \brief The WAIT MODE INPOS wait mode is active. + TASKMODE_WaitForInPos = (1u << 27), + /// \brief When this bit is true the time mode is MINUTES. When this bit is false the time mode is SECONDS. + TASKMODE_Minutes = (1u << 28), + /// \brief The WAIT MODE AUTO wait mode is active. + TASKMODE_WaitAuto = (1u << 30), +} TASKMODE; +typedef enum +{ + /// \brief Secondary units mode is in use. + TASKMODEBITS_SecondaryBit = 0, + /// \brief Absolute programming mode is in use. + TASKMODEBITS_AbsoluteBit = 1, + /// \brief The acceleration type is configured for linear ramping. + TASKMODEBITS_AccelTypeLinearBit = 2, + /// \brief The acceleration mode is rate-based. + TASKMODEBITS_AccelModeRateBit = 3, + /// \brief Inverse dominance (G98) mode is active. + TASKMODEBITS_InverseDominanceBit = 4, + /// \brief Motion continuous (VELOCITY ON) mode is active. + TASKMODEBITS_MotionContinuousBit = 5, + /// \brief Inverse circular (G111) mode is active. + TASKMODEBITS_InverseCircularBit = 6, + /// \brief Spindles will abort on a program stop (G101). + TASKMODEBITS_SpindleStopOnProgramHaltBit = 7, + /// \brief Block Delete mode is active (G112). + TASKMODEBITS_BlockDeleteBit = 8, + /// \brief Optional Pause mode is active (G114). + TASKMODEBITS_OptionalPauseBit = 9, + /// \brief The acceleration type is configured for scurve ramping. + TASKMODEBITS_AccelTypeScurveBit = 10, + /// \brief MFO Lock mode is active (M48). + TASKMODEBITS_MFOLockBit = 11, + /// \brief MSO Lock mode is active (M50). + TASKMODEBITS_MSOLockBit = 12, + /// \brief The deceleration type is configured for linear ramping. + TASKMODEBITS_DecelTypeLinearBit = 13, + /// \brief The deceleration type is configured for scurve ramping. + TASKMODEBITS_DecelTypeScurveBit = 14, + /// \brief When this bit is true the task is executing in Auto mode. When this bit is false the task is executing in Step mode. + TASKMODEBITS_AutoModeBit = 15, + /// \brief Programmed feed rates are specified in MPU (G93). + TASKMODEBITS_ProgramFeedRateMPUBit = 16, + /// \brief Programmed feed rates are specified in units per revolution (G95). + TASKMODEBITS_ProgramFeedRateUPRBit = 17, + /// \brief Block Delete 2 mode is active (G212). + TASKMODEBITS_BlockDelete2Bit = 22, + /// \brief When this bit is true the task is executing in Over mode. When this bit is false the task is executing in Into mode. + TASKMODEBITS_OverModeBit = 23, + /// \brief The deceleration mode is rate-based. + TASKMODEBITS_DecelModeRateBit = 24, + /// \brief The task is using High-Speed Lookahead (LOOKAHEAD FAST). + TASKMODEBITS_HighSpeedLookAheadBit = 25, + /// \brief MFO will affect asynchronous motion (OVERRIDEASYNC ON). + TASKMODEBITS_MFOActiveOnJogBit = 26, + /// \brief The WAIT MODE INPOS wait mode is active. + TASKMODEBITS_WaitForInPosBit = 27, + /// \brief When this bit is true the time mode is MINUTES. When this bit is false the time mode is SECONDS. + TASKMODEBITS_MinutesBit = 28, + /// \brief The WAIT MODE AUTO wait mode is active. + TASKMODEBITS_WaitAutoBit = 30, +} TASKMODEBITS; + +/// \brief This value provides status information about the queue of a given task. The following table describes each bit of this value. +typedef enum +{ + /// \brief This task is running in the Queue mode. + QUEUESTATUS_QueueModeActive = (1u << 0), + /// \brief The Queue buffer for this task is empty. + QUEUESTATUS_QueueBufferEmpty = (1u << 1), + /// \brief The Queue buffer for this task is full. + QUEUESTATUS_QueueBufferFull = (1u << 2), + /// \brief The Queue buffer for this task started. + QUEUESTATUS_QueueBufferStarted = (1u << 3), + /// \brief The Queue buffer for this task was paused. + QUEUESTATUS_QueueBufferPaused = (1u << 4), + /// \brief The given task is executing a large program line-by-line in queue mode. + QUEUESTATUS_QueueLargeProgramExecuting = (1u << 5), +} QUEUESTATUS; +typedef enum +{ + /// \brief This task is running in the Queue mode. + QUEUESTATUSBITS_QueueModeActiveBit = 0, + /// \brief The Queue buffer for this task is empty. + QUEUESTATUSBITS_QueueBufferEmptyBit = 1, + /// \brief The Queue buffer for this task is full. + QUEUESTATUSBITS_QueueBufferFullBit = 2, + /// \brief The Queue buffer for this task started. + QUEUESTATUSBITS_QueueBufferStartedBit = 3, + /// \brief The Queue buffer for this task was paused. + QUEUESTATUSBITS_QueueBufferPausedBit = 4, + /// \brief The given task is executing a large program line-by-line in queue mode. + QUEUESTATUSBITS_QueueLargeProgramExecutingBit = 5, +} QUEUESTATUSBITS; + +/// \brief Represents the modes to wait for motion completion +typedef enum +{ + /// \brief Wait for MoveDone bit to be set + WAITOPTION_MoveDone = 0, + /// \brief Wait for InPosition bit to be set + WAITOPTION_InPosition = 1, +} WAITOPTION; + +/// \brief Specifies the status flags of data collection +typedef enum +{ + /// \brief Data collection was triggered + DATACOLLECTIONFLAGS_Triggered = (1u << 2), + /// \brief Data collection is done + DATACOLLECTIONFLAGS_Done = (1u << 3), + /// \brief Data collection buffer overflowed + DATACOLLECTIONFLAGS_Overflow = (1u << 4), + /// \brief Continuous data collection mode is active + DATACOLLECTIONFLAGS_ContinuousMode = (1u << 9), + /// \brief Data collection was started by a SCOPETRIG + DATACOLLECTIONFLAGS_IsScopeTrigInitiated = (1u << 11), + /// \brief Data is being uploaded to the SMC from the drive buffers + DATACOLLECTIONFLAGS_UploadingDriveBuffers = (1u << 16), +} DATACOLLECTIONFLAGS; +typedef enum +{ + /// \brief Data collection was triggered + DATACOLLECTIONFLAGSBITS_TriggeredBit = 2, + /// \brief Data collection is done + DATACOLLECTIONFLAGSBITS_DoneBit = 3, + /// \brief Data collection buffer overflowed + DATACOLLECTIONFLAGSBITS_OverflowBit = 4, + /// \brief Continuous data collection mode is active + DATACOLLECTIONFLAGSBITS_ContinuousModeBit = 9, + /// \brief Data collection was started by a SCOPETRIG + DATACOLLECTIONFLAGSBITS_IsScopeTrigInitiatedBit = 11, + /// \brief Data is being uploaded to the SMC from the drive buffers + DATACOLLECTIONFLAGSBITS_UploadingDriveBuffersBit = 16, +} DATACOLLECTIONFLAGSBITS; + +/// \brief The type of loop transmission disturbance to use +typedef enum +{ + /// \brief Turn off loop transmission + LOOPTRANSMISSIONMODE_Off = 0, + /// \brief Uses a sinusoid disturbance + LOOPTRANSMISSIONMODE_Sinusoid = 1, + /// \brief Uses a sinusoid disturbance and excites both axes of a gantry + LOOPTRANSMISSIONMODE_SinusoidGantry = 3, + /// \brief Uses a white noise disturbance + LOOPTRANSMISSIONMODE_WhiteNoise = 2, + /// \brief Use a white noise disturbance and excites both axes of a gantry + LOOPTRANSMISSIONMODE_WhiteNoiseGantry = 4, +} LOOPTRANSMISSIONMODE; + +/// \brief The loop transmission type to use +typedef enum +{ + /// \brief Open Loop + LOOPTRANSMISSIONTYPE_OpenLoop = 0, + /// \brief Closed Loop + LOOPTRANSMISSIONTYPE_ClosedLoop = 1, + /// \brief Current Loop + LOOPTRANSMISSIONTYPE_CurrentLoop = 2, + /// \brief AF Open Loop + LOOPTRANSMISSIONTYPE_AFOpenLoop = 3, + /// \brief AF Closed Loop + LOOPTRANSMISSIONTYPE_AFClosedLoop = 4, +} LOOPTRANSMISSIONTYPE; + +/// \brief Represents the OnOff mode in AeroBasic +typedef enum +{ + /// \brief Off or 0 is issued + ONOFF_Off = 0, + /// \brief On or 1 is issued + ONOFF_On = 1, +} ONOFF; + +/// \brief Represents the PSO Encoder in AeroBasic +typedef enum +{ + /// \brief Primary PSO encoder + PSOENCODER_Primary = 0, + /// \brief Auxiliary PSO encoder + PSOENCODER_Auxiliary = 1, +} PSOENCODER; + +/// \brief Represents the PSO mode in AeroBasic +typedef enum +{ + /// \brief Reset PSO + PSOMODE_Reset = 0, + /// \brief Turn off PSO + PSOMODE_Off = 1, + /// \brief Arm PSO + PSOMODE_Arm = 2, + /// \brief Fire PSO + PSOMODE_Fire = 3, + /// \brief Turn on PSO + PSOMODE_On = 4, + /// \brief Fire Continuous + PSOMODE_FireContinuous = 5, + /// \brief Arm PSO PWM + PSOMODE_ArmPwm = 6, +} PSOMODE; + +/// \brief Specifies the window control mode to use +typedef enum +{ + /// \brief The windows are codependent + PSOWINDOWDEPENDANCE_CoDependent = 0, + /// \brief The windows are independent + PSOWINDOWDEPENDANCE_Independent = 1, +} PSOWINDOWDEPENDANCE; + +/// \brief Modbus registers +typedef enum +{ + /// \brief Master input words (read only) + REGISTERTYPE_MasterInputWords = 0, + /// \brief Slave input words (read only) + REGISTERTYPE_SlaveInputWords = 1, + /// \brief Master Output words + REGISTERTYPE_MasterOutputWords = 2, + /// \brief Slave Output words + REGISTERTYPE_SlaveOutputWords = 3, + /// \brief Master input Bits (read only) + REGISTERTYPE_MasterInputBits = 4, + /// \brief Slave input Bits (read only) + REGISTERTYPE_SlaveInputBits = 5, + /// \brief Master Output Bits + REGISTERTYPE_MasterOutputBits = 6, + /// \brief Slave Output Bits + REGISTERTYPE_SlaveOutputBits = 7, +} REGISTERTYPE; + +/// \brief Specifies the button that was clicked as a result of callback +typedef enum +{ + /// \brief Ok button was clicked + INPUTBOXCLICKEDBUTTON_Ok = 1, + /// \brief Cancel button was clicked + INPUTBOXCLICKEDBUTTON_Cancel = 2, +} INPUTBOXCLICKEDBUTTON; + +/// \brief The kind of data to return in callbacks +typedef enum +{ + /// \brief Return a double + INPUTBOXKIND_Double = 0, + /// \brief Return an integer + INPUTBOXKIND_Integer = 8388608, + /// \brief Return a string + INPUTBOXKIND_String = 4194304, +} INPUTBOXKIND; + +/// \brief Specifies the build result kind +typedef enum +{ + /// \brief The build result describes some informational (non-critical) detail about the compilation + BUILDRESULTKIND_Information = 0, + /// \brief The build result describes a warning that occurred during the compilation + BUILDRESULTKIND_Warning = 1, + /// \brief The build result describes an error that occurred during the compilation + BUILDRESULTKIND_Error = 2, +} BUILDRESULTKIND; + +/// \brief +typedef enum +{ + /// \brief The dimensionality of the calibration file is unknown + AXISCALIBRATION_FILETYPE_UNKNOWN = 0, + /// \brief The axis calibration file is 1 dimensional + AXISCALIBRATION_FILETYPE_1D = 1, + /// \brief The axis calibration file is 2 dimensional + AXISCALIBRATION_FILETYPE_2D = 2, + /// \brief The galvo calibration file is 2 dimensional + AXISCALIBRATION_FILETYPE_GALVO_2D = 3, +} AXISCALIBRATION; + +/// \brief Represents the ramp type in AeroBasic +typedef enum +{ + /// \brief Linear-based ramp type + RAMPTYPE_Linear = 0, + /// \brief Scurve-based ramp type + RAMPTYPE_Scurve = 1, + /// \brief Sine-based ramp type + RAMPTYPE_Sine = 2, +} RAMPTYPE; + +/// \brief Represents the ramp mode in AeroBasic +typedef enum +{ + /// \brief Rate-based acceleration and deceleration + RAMPMODE_Rate = 0, + /// \brief Time-based acceleration and deceleration + RAMPMODE_Time = 1, +} RAMPMODE; + +/// \brief The signal from the master axis from which the slave axis is geared +typedef enum +{ + /// \brief Track the position feedback of the master + GEARINGTRACKINGMODE_PositionFeedback = 0, + /// \brief Track the position command of the master + GEARINGTRACKINGMODE_PositionCommand = 1, + /// \brief Track the auxiliary encoder channel of the master + GEARINGTRACKINGMODE_AuxiliaryEncoder = 2, +} GEARINGTRACKINGMODE; + +/// \brief Signal the cam table will track when real axis is used as the master +typedef enum +{ + /// \brief Track the position feedback of the master + CAMMINGTRACKINGMODE_PositionFeedback = 0, + /// \brief Track the position command of the master + CAMMINGTRACKINGMODE_PositionCommand = 1, + /// \brief Track the auxiliary encoder channel of the master + CAMMINGTRACKINGMODE_AuxiliaryEncoder = 2, +} CAMMINGTRACKINGMODE; + +/// \brief Represents the Interpolation Type to be used for the cam table being loaded +typedef enum +{ + /// \brief Use linear interpolation + CAMMINGINTERPOLATIONTYPE_Linear = 0, + /// \brief Use a cubic spline to interpolate between points + CAMMINGINTERPOLATIONTYPE_CubicSpline = 1, +} CAMMINGINTERPOLATIONTYPE; + +/// \brief The synchronization mode to use for camming +typedef enum +{ + /// \brief Stop the slave axis from synchronizing with the master + CAMMINGSYNCMODE_Stop = 0, + /// \brief Begin camming with relative synchronization + CAMMINGSYNCMODE_Relative = 1, + /// \brief Begin camming with absolute synchronization + CAMMINGSYNCMODE_Absolute = 2, + /// \brief Begin camming where slave values are interpreted as velocities and not positions + CAMMINGSYNCMODE_Velocity = 3, +} CAMMINGSYNCMODE; + +/// \brief The edge kinds that are available. +typedef enum +{ + /// \brief Represents a rising edge. + EDGE_Rising = 0, + /// \brief Represents a falling edge. + EDGE_Falling = 1, + /// \brief Represents a rising or falling edge. + EDGE_RisingOrFalling = 2, +} EDGE; + +/// \brief Specifies the time base units. +typedef enum +{ + /// \brief The time units are seconds. + TIMEUNIT_Seconds = 0, + /// \brief The time units are minutes. + TIMEUNIT_Minutes = 1, + /// \brief The time units are milliseconds. + TIMEUNIT_Milliseconds = 2, + /// \brief The time units are microseconds. + TIMEUNIT_Microseconds = 3, +} TIMEUNIT; + +/// \brief The window range activities that are available. +typedef enum +{ + /// \brief Represents entering a window range. + WINDOWEVENT_Entering = 0, + /// \brief Represents exiting a window range. + WINDOWEVENT_Exiting = 1, + /// \brief Represents entering or exiting a window range. + WINDOWEVENT_EnteringOrExiting = 2, +} WINDOWEVENT; + +/// \brief This value provides status information about Sensor Fusion Data Recording. The following table describes each bit of this value. +typedef enum +{ + /// \brief The Sensor Fusion is currently executing a data recording session. + DATARECORDINGFLAGS_Recording = (1u << 0), + /// \brief The Sensor Fusion data recording buffer overflowed. + DATARECORDINGFLAGS_Overflowed = (1u << 1), +} DATARECORDINGFLAGS; +typedef enum +{ + /// \brief The Sensor Fusion is currently executing a data recording session. + DATARECORDINGFLAGSBITS_RecordingBit = 0, + /// \brief The Sensor Fusion data recording buffer overflowed. + DATARECORDINGFLAGSBITS_OverflowedBit = 1, +} DATARECORDINGFLAGSBITS; + +/// \brief This value provides status information about Sensor Fusion Data Playback. The following table describes each bit of this value. +typedef enum +{ + /// \brief The Sensor Fusion is currently executing a data playback session. + DATAPLAYBACKFLAGS_Playing = (1u << 0), + /// \brief The Sensor Fusion data playback buffer underflowed. + DATAPLAYBACKFLAGS_Underflowed = (1u << 1), +} DATAPLAYBACKFLAGS; +typedef enum +{ + /// \brief The Sensor Fusion is currently executing a data playback session. + DATAPLAYBACKFLAGSBITS_PlayingBit = 0, + /// \brief The Sensor Fusion data playback buffer underflowed. + DATAPLAYBACKFLAGSBITS_UnderflowedBit = 1, +} DATAPLAYBACKFLAGSBITS; + +/// \brief Represents the callback argument type +typedef enum +{ + /// \brief Callback double type argument + CALLBACKARGUMENTTYPE_Double = 1, + /// \brief Callback string type argument containing up to 187 characters + CALLBACKARGUMENTTYPE_String = 3, +} CALLBACKARGUMENTTYPE; + +/// \brief This value specifies the type of a safe zone. +typedef enum +{ + /// \brief The zone cannot be entered. + SAFEZONETYPE_NoEnter = 0, + /// \brief The zone cannot be exited. + SAFEZONETYPE_NoExit = 1, + /// \brief The zone cannot be entered. A safe zone axis fault is generated after the decelerations complete. + SAFEZONETYPE_NoEnterAxisFault = 2, + /// \brief The zone cannot be exited. A safe zone axis fault is generated after the decelerations complete. + SAFEZONETYPE_NoExitAxisFault = 3, +} SAFEZONETYPE; + +#endif // __A3200_COMMON_STRUCTURES_H__ + diff --git a/motorApp/AerotechSrc/A3200ParameterId.h b/motorApp/AerotechSrc/A3200ParameterId.h new file mode 100644 index 00000000..519cb81c --- /dev/null +++ b/motorApp/AerotechSrc/A3200ParameterId.h @@ -0,0 +1,1117 @@ +/// \file A3200ParameterId.h +/// \brief Contains parameter identifiers +/// +/// This file is version dependent and needs to match the rest of the software +/// +/// Copyright (c) Aerotech, Inc. 2010-2013. +/// + +#ifndef __A3200_PARAMETER_ID_H__ +#define __A3200_PARAMETER_ID_H__ + + +/// \brief Represents a parameter identifier +typedef enum { + /// \brief The DataCollectionPoints parameter + PARAMETERID_DataCollectionPoints = ( (2 << 24) | 0 ), + /// \brief The DataCollectionItems parameter + PARAMETERID_DataCollectionItems = ( (2 << 24) | 1 ), + /// \brief The GlobalDoubles parameter + PARAMETERID_GlobalDoubles = ( (2 << 24) | 21 ), + /// \brief The CommandPort parameter + PARAMETERID_CommandPort = ( (2 << 24) | 24 ), + /// \brief The UserDouble0 parameter + PARAMETERID_UserDouble0 = ( (2 << 24) | 35 ), + /// \brief The UserDouble1 parameter + PARAMETERID_UserDouble1 = ( (2 << 24) | 36 ), + /// \brief The UserString0 parameter + PARAMETERID_UserString0 = ( (2 << 24) | 37 ), + /// \brief The UserString1 parameter + PARAMETERID_UserString1 = ( (2 << 24) | 38 ), + /// \brief The CommandSetup parameter + PARAMETERID_CommandSetup = ( (2 << 24) | 39 ), + /// \brief The RequiredAxes parameter + PARAMETERID_RequiredAxes = ( (2 << 24) | 45 ), + /// \brief The CommandTerminatingCharacter parameter + PARAMETERID_CommandTerminatingCharacter = ( (2 << 24) | 51 ), + /// \brief The CommandSuccessCharacter parameter + PARAMETERID_CommandSuccessCharacter = ( (2 << 24) | 52 ), + /// \brief The CommandInvalidCharacter parameter + PARAMETERID_CommandInvalidCharacter = ( (2 << 24) | 53 ), + /// \brief The CommandFaultCharacter parameter + PARAMETERID_CommandFaultCharacter = ( (2 << 24) | 54 ), + /// \brief The GlobalStrings parameter + PARAMETERID_GlobalStrings = ( (2 << 24) | 65 ), + /// \brief The SystemCompatibility parameter + PARAMETERID_SystemCompatibility = ( (2 << 24) | 66 ), + /// \brief The DependentSpeedScaleFactor parameter + PARAMETERID_DependentSpeedScaleFactor = ( (2 << 24) | 67 ), + /// \brief The GlobalAxisPoints parameter + PARAMETERID_GlobalAxisPoints = ( (2 << 24) | 68 ), + /// \brief The CallbackTimeout parameter + PARAMETERID_CallbackTimeout = ( (2 << 24) | 69 ), + /// \brief The CannedFunctions parameter + PARAMETERID_CannedFunctions = ( (2 << 24) | 70 ), + /// \brief The DisplayAxes parameter + PARAMETERID_DisplayAxes = ( (2 << 24) | 71 ), + /// \brief The SecondaryUnitsScaleFactor parameter + PARAMETERID_SecondaryUnitsScaleFactor = ( (2 << 24) | 75 ), + /// \brief The PrimaryUnitsMapping parameter + PARAMETERID_PrimaryUnitsMapping = ( (2 << 24) | 76 ), + /// \brief The SecondaryUnitsName parameter + PARAMETERID_SecondaryUnitsName = ( (2 << 24) | 77 ), + /// \brief The EnabledTasks parameter + PARAMETERID_EnabledTasks = ( (2 << 24) | 236 ), + /// \brief The FaultAckMoveOutOfLimit parameter + PARAMETERID_FaultAckMoveOutOfLimit = ( (2 << 24) | 237 ), + /// \brief The UserDouble2 parameter + PARAMETERID_UserDouble2 = ( (2 << 24) | 238 ), + /// \brief The UserDouble3 parameter + PARAMETERID_UserDouble3 = ( (2 << 24) | 239 ), + /// \brief The UserString2 parameter + PARAMETERID_UserString2 = ( (2 << 24) | 240 ), + /// \brief The UserString3 parameter + PARAMETERID_UserString3 = ( (2 << 24) | 241 ), + /// \brief The PLCReservedTasks parameter + PARAMETERID_PLCReservedTasks = ( (2 << 24) | 243 ), + /// \brief The SoftwareExternalFaultInput parameter + PARAMETERID_SoftwareExternalFaultInput = ( (2 << 24) | 244 ), + /// \brief The SignalLogSetup parameter + PARAMETERID_SignalLogSetup = ( (2 << 24) | 245 ), + /// \brief The SignalLogAxes parameter + PARAMETERID_SignalLogAxes = ( (2 << 24) | 246 ), + /// \brief The SignalLogTasks parameter + PARAMETERID_SignalLogTasks = ( (2 << 24) | 247 ), + /// \brief The SignalLogFaultMaskTrigger parameter + PARAMETERID_SignalLogFaultMaskTrigger = ( (2 << 24) | 248 ), + /// \brief The SignalLogSamplePeriod parameter + PARAMETERID_SignalLogSamplePeriod = ( (2 << 24) | 249 ), + /// \brief The SignalLogPointsBeforeTrigger parameter + PARAMETERID_SignalLogPointsBeforeTrigger = ( (2 << 24) | 250 ), + /// \brief The SignalLogPointsAfterTrigger parameter + PARAMETERID_SignalLogPointsAfterTrigger = ( (2 << 24) | 251 ), + /// \brief The MasterClockCorrectionFactor parameter + PARAMETERID_MasterClockCorrectionFactor = ( (2 << 24) | 252 ), + /// \brief The WebServerSetup parameter + PARAMETERID_WebServerSetup = ( (2 << 24) | 261 ), + /// \brief The WebServerPort parameter + PARAMETERID_WebServerPort = ( (2 << 24) | 262 ), + /// \brief The DefaultWaitMode parameter + PARAMETERID_DefaultWaitMode = ( (1 << 24) | 0 ), + /// \brief The DefaultSCurve parameter + PARAMETERID_DefaultSCurve = ( (1 << 24) | 1 ), + /// \brief The TaskErrorAbortAxes parameter + PARAMETERID_TaskErrorAbortAxes = ( (1 << 24) | 7 ), + /// \brief The JoystickInput1MinVoltage parameter + PARAMETERID_JoystickInput1MinVoltage = ( (1 << 24) | 8 ), + /// \brief The JoystickInput1MaxVoltage parameter + PARAMETERID_JoystickInput1MaxVoltage = ( (1 << 24) | 9 ), + /// \brief The JoystickInput1Deadband parameter + PARAMETERID_JoystickInput1Deadband = ( (1 << 24) | 10 ), + /// \brief The JoystickInput0MinVoltage parameter + PARAMETERID_JoystickInput0MinVoltage = ( (1 << 24) | 11 ), + /// \brief The JoystickInput0MaxVoltage parameter + PARAMETERID_JoystickInput0MaxVoltage = ( (1 << 24) | 12 ), + /// \brief The JoystickInput0Deadband parameter + PARAMETERID_JoystickInput0Deadband = ( (1 << 24) | 13 ), + /// \brief The TaskTerminationAxes parameter + PARAMETERID_TaskTerminationAxes = ( (1 << 24) | 14 ), + /// \brief The TaskStopAbortAxes parameter + PARAMETERID_TaskStopAbortAxes = ( (1 << 24) | 15 ), + /// \brief The DefaultCoordinatedSpeed parameter + PARAMETERID_DefaultCoordinatedSpeed = ( (1 << 24) | 16 ), + /// \brief The DefaultCoordinatedRampRate parameter + PARAMETERID_DefaultCoordinatedRampRate = ( (1 << 24) | 17 ), + /// \brief The DefaultDependentCoordinatedRampRate parameter + PARAMETERID_DefaultDependentCoordinatedRampRate = ( (1 << 24) | 18 ), + /// \brief The DefaultCoordinatedRampMode parameter + PARAMETERID_DefaultCoordinatedRampMode = ( (1 << 24) | 19 ), + /// \brief The DefaultCoordinatedRampTime parameter + PARAMETERID_DefaultCoordinatedRampTime = ( (1 << 24) | 20 ), + /// \brief The HCScanIncrement parameter + PARAMETERID_HCScanIncrement = ( (1 << 24) | 22 ), + /// \brief The HCMaxDisplacement parameter + PARAMETERID_HCMaxDisplacement = ( (1 << 24) | 23 ), + /// \brief The HCThreshold parameter + PARAMETERID_HCThreshold = ( (1 << 24) | 24 ), + /// \brief The HCAxis parameter + PARAMETERID_HCAxis = ( (1 << 24) | 25 ), + /// \brief The HCInputMode parameter + PARAMETERID_HCInputMode = ( (1 << 24) | 26 ), + /// \brief The HCInputChannelNum parameter + PARAMETERID_HCInputChannelNum = ( (1 << 24) | 27 ), + /// \brief The HCInvertSearch parameter + PARAMETERID_HCInvertSearch = ( (1 << 24) | 28 ), + /// \brief The HCWholeWindow parameter + PARAMETERID_HCWholeWindow = ( (1 << 24) | 29 ), + /// \brief The HCDelayTime parameter + PARAMETERID_HCDelayTime = ( (1 << 24) | 31 ), + /// \brief The SRMaxRadius parameter + PARAMETERID_SRMaxRadius = ( (1 << 24) | 32 ), + /// \brief The SRNumSpirals parameter + PARAMETERID_SRNumSpirals = ( (1 << 24) | 33 ), + /// \brief The SRSegmentLength parameter + PARAMETERID_SRSegmentLength = ( (1 << 24) | 34 ), + /// \brief The SRThreshold parameter + PARAMETERID_SRThreshold = ( (1 << 24) | 35 ), + /// \brief The SRAxis1 parameter + PARAMETERID_SRAxis1 = ( (1 << 24) | 36 ), + /// \brief The SRAxis2 parameter + PARAMETERID_SRAxis2 = ( (1 << 24) | 37 ), + /// \brief The SRInputMode parameter + PARAMETERID_SRInputMode = ( (1 << 24) | 38 ), + /// \brief The SRInputChannelNum parameter + PARAMETERID_SRInputChannelNum = ( (1 << 24) | 39 ), + /// \brief The SRInvertSearch parameter + PARAMETERID_SRInvertSearch = ( (1 << 24) | 40 ), + /// \brief The SRMotionType parameter + PARAMETERID_SRMotionType = ( (1 << 24) | 41 ), + /// \brief The SRDelayTime parameter + PARAMETERID_SRDelayTime = ( (1 << 24) | 43 ), + /// \brief The SFEndRadius parameter + PARAMETERID_SFEndRadius = ( (1 << 24) | 44 ), + /// \brief The SFNumSpirals parameter + PARAMETERID_SFNumSpirals = ( (1 << 24) | 45 ), + /// \brief The SFSegmentLength parameter + PARAMETERID_SFSegmentLength = ( (1 << 24) | 46 ), + /// \brief The SFAxis1 parameter + PARAMETERID_SFAxis1 = ( (1 << 24) | 47 ), + /// \brief The SFAxis2 parameter + PARAMETERID_SFAxis2 = ( (1 << 24) | 48 ), + /// \brief The SFInputMode parameter + PARAMETERID_SFInputMode = ( (1 << 24) | 49 ), + /// \brief The SFInputChannelNum parameter + PARAMETERID_SFInputChannelNum = ( (1 << 24) | 50 ), + /// \brief The SFInvertSearch parameter + PARAMETERID_SFInvertSearch = ( (1 << 24) | 51 ), + /// \brief The SFMotionType parameter + PARAMETERID_SFMotionType = ( (1 << 24) | 52 ), + /// \brief The SFDelayTime parameter + PARAMETERID_SFDelayTime = ( (1 << 24) | 54 ), + /// \brief The FASelectAxis1 parameter + PARAMETERID_FASelectAxis1 = ( (1 << 24) | 55 ), + /// \brief The FASelectAxis2 parameter + PARAMETERID_FASelectAxis2 = ( (1 << 24) | 56 ), + /// \brief The FASelectAxis3 parameter + PARAMETERID_FASelectAxis3 = ( (1 << 24) | 57 ), + /// \brief The FASelectAxis4 parameter + PARAMETERID_FASelectAxis4 = ( (1 << 24) | 58 ), + /// \brief The FASelectAxis5 parameter + PARAMETERID_FASelectAxis5 = ( (1 << 24) | 59 ), + /// \brief The FASelectAxis6 parameter + PARAMETERID_FASelectAxis6 = ( (1 << 24) | 60 ), + /// \brief The FAOffsetAxis1 parameter + PARAMETERID_FAOffsetAxis1 = ( (1 << 24) | 61 ), + /// \brief The FAOffsetAxis2 parameter + PARAMETERID_FAOffsetAxis2 = ( (1 << 24) | 62 ), + /// \brief The FAOffsetAxis3 parameter + PARAMETERID_FAOffsetAxis3 = ( (1 << 24) | 63 ), + /// \brief The FAOffsetAxis4 parameter + PARAMETERID_FAOffsetAxis4 = ( (1 << 24) | 64 ), + /// \brief The FAOffsetAxis5 parameter + PARAMETERID_FAOffsetAxis5 = ( (1 << 24) | 65 ), + /// \brief The FAOffsetAxis6 parameter + PARAMETERID_FAOffsetAxis6 = ( (1 << 24) | 66 ), + /// \brief The FAPosLimitAxis1 parameter + PARAMETERID_FAPosLimitAxis1 = ( (1 << 24) | 67 ), + /// \brief The FAPosLimitAxis2 parameter + PARAMETERID_FAPosLimitAxis2 = ( (1 << 24) | 68 ), + /// \brief The FAPosLimitAxis3 parameter + PARAMETERID_FAPosLimitAxis3 = ( (1 << 24) | 69 ), + /// \brief The FAPosLimitAxis4 parameter + PARAMETERID_FAPosLimitAxis4 = ( (1 << 24) | 70 ), + /// \brief The FAPosLimitAxis5 parameter + PARAMETERID_FAPosLimitAxis5 = ( (1 << 24) | 71 ), + /// \brief The FAPosLimitAxis6 parameter + PARAMETERID_FAPosLimitAxis6 = ( (1 << 24) | 72 ), + /// \brief The FANegLimitAxis1 parameter + PARAMETERID_FANegLimitAxis1 = ( (1 << 24) | 73 ), + /// \brief The FANegLimitAxis2 parameter + PARAMETERID_FANegLimitAxis2 = ( (1 << 24) | 74 ), + /// \brief The FANegLimitAxis3 parameter + PARAMETERID_FANegLimitAxis3 = ( (1 << 24) | 75 ), + /// \brief The FANegLimitAxis4 parameter + PARAMETERID_FANegLimitAxis4 = ( (1 << 24) | 76 ), + /// \brief The FANegLimitAxis5 parameter + PARAMETERID_FANegLimitAxis5 = ( (1 << 24) | 77 ), + /// \brief The FANegLimitAxis6 parameter + PARAMETERID_FANegLimitAxis6 = ( (1 << 24) | 78 ), + /// \brief The FATermTolerance parameter + PARAMETERID_FATermTolerance = ( (1 << 24) | 79 ), + /// \brief The FAMaxNumIterations parameter + PARAMETERID_FAMaxNumIterations = ( (1 << 24) | 80 ), + /// \brief The FASaturationValue parameter + PARAMETERID_FASaturationValue = ( (1 << 24) | 81 ), + /// \brief The FAReturnToStart parameter + PARAMETERID_FAReturnToStart = ( (1 << 24) | 82 ), + /// \brief The FAInputMode parameter + PARAMETERID_FAInputMode = ( (1 << 24) | 83 ), + /// \brief The FAInputChannelNum parameter + PARAMETERID_FAInputChannelNum = ( (1 << 24) | 84 ), + /// \brief The FAInvertSearch parameter + PARAMETERID_FAInvertSearch = ( (1 << 24) | 85 ), + /// \brief The FADelayTime parameter + PARAMETERID_FADelayTime = ( (1 << 24) | 86 ), + /// \brief The GCScanSize parameter + PARAMETERID_GCScanSize = ( (1 << 24) | 87 ), + /// \brief The GCScanIncrement parameter + PARAMETERID_GCScanIncrement = ( (1 << 24) | 88 ), + /// \brief The GCScanLines parameter + PARAMETERID_GCScanLines = ( (1 << 24) | 89 ), + /// \brief The GCEdgeValue parameter + PARAMETERID_GCEdgeValue = ( (1 << 24) | 90 ), + /// \brief The GCAxis1 parameter + PARAMETERID_GCAxis1 = ( (1 << 24) | 91 ), + /// \brief The GCAxis2 parameter + PARAMETERID_GCAxis2 = ( (1 << 24) | 92 ), + /// \brief The GCInputMode parameter + PARAMETERID_GCInputMode = ( (1 << 24) | 93 ), + /// \brief The GCInputChannelNum parameter + PARAMETERID_GCInputChannelNum = ( (1 << 24) | 94 ), + /// \brief The GCInvertSearch parameter + PARAMETERID_GCInvertSearch = ( (1 << 24) | 95 ), + /// \brief The GCSingleRasterMode parameter + PARAMETERID_GCSingleRasterMode = ( (1 << 24) | 96 ), + /// \brief The GCMotionType parameter + PARAMETERID_GCMotionType = ( (1 << 24) | 97 ), + /// \brief The GCDelayTime parameter + PARAMETERID_GCDelayTime = ( (1 << 24) | 99 ), + /// \brief The CMaxDisplacement1 parameter + PARAMETERID_CMaxDisplacement1 = ( (1 << 24) | 100 ), + /// \brief The CMaxDisplacement2 parameter + PARAMETERID_CMaxDisplacement2 = ( (1 << 24) | 101 ), + /// \brief The CMaxDisplacement3 parameter + PARAMETERID_CMaxDisplacement3 = ( (1 << 24) | 102 ), + /// \brief The CScanIncrement parameter + PARAMETERID_CScanIncrement = ( (1 << 24) | 103 ), + /// \brief The CEdgeValue parameter + PARAMETERID_CEdgeValue = ( (1 << 24) | 104 ), + /// \brief The CAxis1 parameter + PARAMETERID_CAxis1 = ( (1 << 24) | 105 ), + /// \brief The CAxis2 parameter + PARAMETERID_CAxis2 = ( (1 << 24) | 106 ), + /// \brief The CAxis3 parameter + PARAMETERID_CAxis3 = ( (1 << 24) | 107 ), + /// \brief The CInputMode parameter + PARAMETERID_CInputMode = ( (1 << 24) | 108 ), + /// \brief The CInputChannelNum parameter + PARAMETERID_CInputChannelNum = ( (1 << 24) | 109 ), + /// \brief The CInvertSearch parameter + PARAMETERID_CInvertSearch = ( (1 << 24) | 110 ), + /// \brief The CReturnToCenter parameter + PARAMETERID_CReturnToCenter = ( (1 << 24) | 111 ), + /// \brief The CDelayTime parameter + PARAMETERID_CDelayTime = ( (1 << 24) | 113 ), + /// \brief The HCPercentDrop parameter + PARAMETERID_HCPercentDrop = ( (1 << 24) | 114 ), + /// \brief The DefaultDependentCoordinatedSpeed parameter + PARAMETERID_DefaultDependentCoordinatedSpeed = ( (1 << 24) | 115 ), + /// \brief The CoordinatedAccelLimit parameter + PARAMETERID_CoordinatedAccelLimit = ( (1 << 24) | 116 ), + /// \brief The DependentCoordinatedAccelLimit parameter + PARAMETERID_DependentCoordinatedAccelLimit = ( (1 << 24) | 117 ), + /// \brief The CoordinatedCircularAccelLimit parameter + PARAMETERID_CoordinatedCircularAccelLimit = ( (1 << 24) | 118 ), + /// \brief The CoordinatedAccelLimitSetup parameter + PARAMETERID_CoordinatedAccelLimitSetup = ( (1 << 24) | 119 ), + /// \brief The MaxLookaheadMoves parameter + PARAMETERID_MaxLookaheadMoves = ( (1 << 24) | 120 ), + /// \brief The RadiusCorrectionThreshold parameter + PARAMETERID_RadiusCorrectionThreshold = ( (1 << 24) | 121 ), + /// \brief The RadiusErrorThreshold parameter + PARAMETERID_RadiusErrorThreshold = ( (1 << 24) | 122 ), + /// \brief The CutterTolerance parameter + PARAMETERID_CutterTolerance = ( (1 << 24) | 123 ), + /// \brief The SoftwareESTOPInput parameter + PARAMETERID_SoftwareESTOPInput = ( (1 << 24) | 124 ), + /// \brief The FeedholdInput parameter + PARAMETERID_FeedholdInput = ( (1 << 24) | 125 ), + /// \brief The FeedholdSetup parameter + PARAMETERID_FeedholdSetup = ( (1 << 24) | 126 ), + /// \brief The AnalogMFOInput parameter + PARAMETERID_AnalogMFOInput = ( (1 << 24) | 127 ), + /// \brief The Spindle0MSOInput parameter + PARAMETERID_Spindle0MSOInput = ( (1 << 24) | 128 ), + /// \brief The Spindle1MSOInput parameter + PARAMETERID_Spindle1MSOInput = ( (1 << 24) | 129 ), + /// \brief The Spindle2MSOInput parameter + PARAMETERID_Spindle2MSOInput = ( (1 << 24) | 130 ), + /// \brief The Spindle3MSOInput parameter + PARAMETERID_Spindle3MSOInput = ( (1 << 24) | 131 ), + /// \brief The Spindle0Axis parameter + PARAMETERID_Spindle0Axis = ( (1 << 24) | 132 ), + /// \brief The Spindle1Axis parameter + PARAMETERID_Spindle1Axis = ( (1 << 24) | 133 ), + /// \brief The Spindle2Axis parameter + PARAMETERID_Spindle2Axis = ( (1 << 24) | 134 ), + /// \brief The Spindle3Axis parameter + PARAMETERID_Spindle3Axis = ( (1 << 24) | 135 ), + /// \brief The CallStackSize parameter + PARAMETERID_CallStackSize = ( (1 << 24) | 136 ), + /// \brief The ModeStackSize parameter + PARAMETERID_ModeStackSize = ( (1 << 24) | 137 ), + /// \brief The TaskDoubles parameter + PARAMETERID_TaskDoubles = ( (1 << 24) | 138 ), + /// \brief The TaskStrings parameter + PARAMETERID_TaskStrings = ( (1 << 24) | 139 ), + /// \brief The TaskAxisPoints parameter + PARAMETERID_TaskAxisPoints = ( (1 << 24) | 140 ), + /// \brief The MonitorStatements parameter + PARAMETERID_MonitorStatements = ( (1 << 24) | 141 ), + /// \brief The MotionUpdateRate parameter + PARAMETERID_MotionUpdateRate = ( (1 << 24) | 142 ), + /// \brief The MotionBufferSize parameter + PARAMETERID_MotionBufferSize = ( (1 << 24) | 143 ), + /// \brief The ExecuteNumLines parameter + PARAMETERID_ExecuteNumLines = ( (1 << 24) | 144 ), + /// \brief The CoordinatedMoveDurationMinimum parameter + PARAMETERID_CoordinatedMoveDurationMinimum = ( (1 << 24) | 145 ), + /// \brief The DefaultMotionMode parameter + PARAMETERID_DefaultMotionMode = ( (1 << 24) | 146 ), + /// \brief The JoystickInput0 parameter + PARAMETERID_JoystickInput0 = ( (1 << 24) | 147 ), + /// \brief The JoystickInput1 parameter + PARAMETERID_JoystickInput1 = ( (1 << 24) | 148 ), + /// \brief The JoystickAxesSelect parameter + PARAMETERID_JoystickAxesSelect = ( (1 << 24) | 149 ), + /// \brief The JoystickSpeedSelect parameter + PARAMETERID_JoystickSpeedSelect = ( (1 << 24) | 150 ), + /// \brief The JoystickInterlock parameter + PARAMETERID_JoystickInterlock = ( (1 << 24) | 151 ), + /// \brief The JoystickInput2 parameter + PARAMETERID_JoystickInput2 = ( (1 << 24) | 152 ), + /// \brief The AnalogMFOMinVoltage parameter + PARAMETERID_AnalogMFOMinVoltage = ( (1 << 24) | 153 ), + /// \brief The AnalogMFOMaxVoltage parameter + PARAMETERID_AnalogMFOMaxVoltage = ( (1 << 24) | 154 ), + /// \brief The MaximumMFO parameter + PARAMETERID_MaximumMFO = ( (1 << 24) | 155 ), + /// \brief The JoystickInput2MinVoltage parameter + PARAMETERID_JoystickInput2MinVoltage = ( (1 << 24) | 156 ), + /// \brief The JoystickInput2MaxVoltage parameter + PARAMETERID_JoystickInput2MaxVoltage = ( (1 << 24) | 157 ), + /// \brief The JoystickInput2Deadband parameter + PARAMETERID_JoystickInput2Deadband = ( (1 << 24) | 158 ), + /// \brief The MinimumMFO parameter + PARAMETERID_MinimumMFO = ( (1 << 24) | 159 ), + /// \brief The AnalogMFOStep parameter + PARAMETERID_AnalogMFOStep = ( (1 << 24) | 160 ), + /// \brief The DefaultProgrammingMode parameter + PARAMETERID_DefaultProgrammingMode = ( (1 << 24) | 161 ), + /// \brief The DefaultCoordinatedRampType parameter + PARAMETERID_DefaultCoordinatedRampType = ( (1 << 24) | 162 ), + /// \brief The DefaultSpindle0Speed parameter + PARAMETERID_DefaultSpindle0Speed = ( (1 << 24) | 163 ), + /// \brief The DefaultSpindle1Speed parameter + PARAMETERID_DefaultSpindle1Speed = ( (1 << 24) | 164 ), + /// \brief The DefaultSpindle2Speed parameter + PARAMETERID_DefaultSpindle2Speed = ( (1 << 24) | 165 ), + /// \brief The DefaultSpindle3Speed parameter + PARAMETERID_DefaultSpindle3Speed = ( (1 << 24) | 166 ), + /// \brief The MotionInterpolationMode parameter + PARAMETERID_MotionInterpolationMode = ( (1 << 24) | 167 ), + /// \brief The DefaultTimeMode parameter + PARAMETERID_DefaultTimeMode = ( (1 << 24) | 168 ), + /// \brief The QueueBufferSize parameter + PARAMETERID_QueueBufferSize = ( (1 << 24) | 169 ), + /// \brief The AxisType parameter + PARAMETERID_AxisType = ( (0 << 24) | 0 ), + /// \brief The ReverseMotionDirection parameter + PARAMETERID_ReverseMotionDirection = ( (0 << 24) | 1 ), + /// \brief The CountsPerUnit parameter + PARAMETERID_CountsPerUnit = ( (0 << 24) | 2 ), + /// \brief The ServoSetup parameter + PARAMETERID_ServoSetup = ( (0 << 24) | 4 ), + /// \brief The GainKpos parameter + PARAMETERID_GainKpos = ( (0 << 24) | 5 ), + /// \brief The GainKi parameter + PARAMETERID_GainKi = ( (0 << 24) | 6 ), + /// \brief The GainKp parameter + PARAMETERID_GainKp = ( (0 << 24) | 7 ), + /// \brief The GainVff parameter + PARAMETERID_GainVff = ( (0 << 24) | 8 ), + /// \brief The GainAff parameter + PARAMETERID_GainAff = ( (0 << 24) | 9 ), + /// \brief The GainKv parameter + PARAMETERID_GainKv = ( (0 << 24) | 10 ), + /// \brief The GainKpi parameter + PARAMETERID_GainKpi = ( (0 << 24) | 11 ), + /// \brief The ServoFilter0CoeffN0 parameter + PARAMETERID_ServoFilter0CoeffN0 = ( (0 << 24) | 12 ), + /// \brief The ServoFilter0CoeffN1 parameter + PARAMETERID_ServoFilter0CoeffN1 = ( (0 << 24) | 13 ), + /// \brief The ServoFilter0CoeffN2 parameter + PARAMETERID_ServoFilter0CoeffN2 = ( (0 << 24) | 14 ), + /// \brief The ServoFilter0CoeffD1 parameter + PARAMETERID_ServoFilter0CoeffD1 = ( (0 << 24) | 15 ), + /// \brief The ServoFilter0CoeffD2 parameter + PARAMETERID_ServoFilter0CoeffD2 = ( (0 << 24) | 16 ), + /// \brief The ServoFilter1CoeffN0 parameter + PARAMETERID_ServoFilter1CoeffN0 = ( (0 << 24) | 17 ), + /// \brief The ServoFilter1CoeffN1 parameter + PARAMETERID_ServoFilter1CoeffN1 = ( (0 << 24) | 18 ), + /// \brief The ServoFilter1CoeffN2 parameter + PARAMETERID_ServoFilter1CoeffN2 = ( (0 << 24) | 19 ), + /// \brief The ServoFilter1CoeffD1 parameter + PARAMETERID_ServoFilter1CoeffD1 = ( (0 << 24) | 20 ), + /// \brief The ServoFilter1CoeffD2 parameter + PARAMETERID_ServoFilter1CoeffD2 = ( (0 << 24) | 21 ), + /// \brief The AmplifierDeadtime parameter + PARAMETERID_AmplifierDeadtime = ( (0 << 24) | 22 ), + /// \brief The RolloverCounts parameter + PARAMETERID_RolloverCounts = ( (0 << 24) | 23 ), + /// \brief The CurrentGainKi parameter + PARAMETERID_CurrentGainKi = ( (0 << 24) | 24 ), + /// \brief The CurrentGainKp parameter + PARAMETERID_CurrentGainKp = ( (0 << 24) | 25 ), + /// \brief The FaultMask parameter + PARAMETERID_FaultMask = ( (0 << 24) | 26 ), + /// \brief The FaultMaskDisable parameter + PARAMETERID_FaultMaskDisable = ( (0 << 24) | 27 ), + /// \brief The FaultMaskDecel parameter + PARAMETERID_FaultMaskDecel = ( (0 << 24) | 28 ), + /// \brief The EnableBrakeControl parameter + PARAMETERID_EnableBrakeControl = ( (0 << 24) | 29 ), + /// \brief The FaultMaskOutput parameter + PARAMETERID_FaultMaskOutput = ( (0 << 24) | 30 ), + /// \brief The ESTOPFaultInput parameter + PARAMETERID_ESTOPFaultInput = ( (0 << 24) | 31 ), + /// \brief The PositionErrorThreshold parameter + PARAMETERID_PositionErrorThreshold = ( (0 << 24) | 32 ), + /// \brief The AverageCurrentThreshold parameter + PARAMETERID_AverageCurrentThreshold = ( (0 << 24) | 33 ), + /// \brief The AverageCurrentTime parameter + PARAMETERID_AverageCurrentTime = ( (0 << 24) | 34 ), + /// \brief The VelocityCommandThreshold parameter + PARAMETERID_VelocityCommandThreshold = ( (0 << 24) | 35 ), + /// \brief The VelocityErrorThreshold parameter + PARAMETERID_VelocityErrorThreshold = ( (0 << 24) | 36 ), + /// \brief The SoftwareLimitLow parameter + PARAMETERID_SoftwareLimitLow = ( (0 << 24) | 37 ), + /// \brief The SoftwareLimitHigh parameter + PARAMETERID_SoftwareLimitHigh = ( (0 << 24) | 38 ), + /// \brief The MaxCurrentClamp parameter + PARAMETERID_MaxCurrentClamp = ( (0 << 24) | 39 ), + /// \brief The InPositionDistance parameter + PARAMETERID_InPositionDistance = ( (0 << 24) | 40 ), + /// \brief The MotorType parameter + PARAMETERID_MotorType = ( (0 << 24) | 41 ), + /// \brief The CyclesPerRev parameter + PARAMETERID_CyclesPerRev = ( (0 << 24) | 42 ), + /// \brief The CountsPerRev parameter + PARAMETERID_CountsPerRev = ( (0 << 24) | 43 ), + /// \brief The CommutationOffset parameter + PARAMETERID_CommutationOffset = ( (0 << 24) | 44 ), + /// \brief The AutoMsetTime parameter + PARAMETERID_AutoMsetTime = ( (0 << 24) | 45 ), + /// \brief The AutoMsetCurrent parameter + PARAMETERID_AutoMsetCurrent = ( (0 << 24) | 46 ), + /// \brief The PositionFeedbackType parameter + PARAMETERID_PositionFeedbackType = ( (0 << 24) | 47 ), + /// \brief The PositionFeedbackChannel parameter + PARAMETERID_PositionFeedbackChannel = ( (0 << 24) | 48 ), + /// \brief The VelocityFeedbackType parameter + PARAMETERID_VelocityFeedbackType = ( (0 << 24) | 49 ), + /// \brief The VelocityFeedbackChannel parameter + PARAMETERID_VelocityFeedbackChannel = ( (0 << 24) | 50 ), + /// \brief The EncoderMultiplicationFactor parameter + PARAMETERID_EncoderMultiplicationFactor = ( (0 << 24) | 51 ), + /// \brief The EncoderSineGain parameter + PARAMETERID_EncoderSineGain = ( (0 << 24) | 52 ), + /// \brief The EncoderSineOffset parameter + PARAMETERID_EncoderSineOffset = ( (0 << 24) | 53 ), + /// \brief The EncoderCosineGain parameter + PARAMETERID_EncoderCosineGain = ( (0 << 24) | 54 ), + /// \brief The EncoderCosineOffset parameter + PARAMETERID_EncoderCosineOffset = ( (0 << 24) | 55 ), + /// \brief The EncoderPhase parameter + PARAMETERID_EncoderPhase = ( (0 << 24) | 56 ), + /// \brief The GantryMasterAxis parameter + PARAMETERID_GantryMasterAxis = ( (0 << 24) | 57 ), + /// \brief The LimitDecelDistance parameter + PARAMETERID_LimitDecelDistance = ( (0 << 24) | 59 ), + /// \brief The LimitDebounceTime parameter + PARAMETERID_LimitDebounceTime = ( (0 << 24) | 60 ), + /// \brief The EndOfTravelLimitSetup parameter + PARAMETERID_EndOfTravelLimitSetup = ( (0 << 24) | 61 ), + /// \brief The BacklashDistance parameter + PARAMETERID_BacklashDistance = ( (0 << 24) | 62 ), + /// \brief The FaultOutputSetup parameter + PARAMETERID_FaultOutputSetup = ( (0 << 24) | 63 ), + /// \brief The FaultOutputState parameter + PARAMETERID_FaultOutputState = ( (0 << 24) | 64 ), + /// \brief The IOSetup parameter + PARAMETERID_IOSetup = ( (0 << 24) | 65 ), + /// \brief The BrakeOutput parameter + PARAMETERID_BrakeOutput = ( (0 << 24) | 66 ), + /// \brief The EncoderDivider parameter + PARAMETERID_EncoderDivider = ( (0 << 24) | 67 ), + /// \brief The ExternalFaultDigitalInput parameter + PARAMETERID_ExternalFaultDigitalInput = ( (0 << 24) | 68 ), + /// \brief The BrakeDisableDelay parameter + PARAMETERID_BrakeDisableDelay = ( (0 << 24) | 69 ), + /// \brief The MaxJogDistance parameter + PARAMETERID_MaxJogDistance = ( (0 << 24) | 70 ), + /// \brief The DefaultSpeed parameter + PARAMETERID_DefaultSpeed = ( (0 << 24) | 71 ), + /// \brief The DefaultRampRate parameter + PARAMETERID_DefaultRampRate = ( (0 << 24) | 72 ), + /// \brief The AbortDecelRate parameter + PARAMETERID_AbortDecelRate = ( (0 << 24) | 73 ), + /// \brief The HomeType parameter + PARAMETERID_HomeType = ( (0 << 24) | 74 ), + /// \brief The HomeSetup parameter + PARAMETERID_HomeSetup = ( (0 << 24) | 75 ), + /// \brief The HomeSpeed parameter + PARAMETERID_HomeSpeed = ( (0 << 24) | 76 ), + /// \brief The HomeOffset parameter + PARAMETERID_HomeOffset = ( (0 << 24) | 77 ), + /// \brief The HomeRampRate parameter + PARAMETERID_HomeRampRate = ( (0 << 24) | 78 ), + /// \brief The StepperResolution parameter + PARAMETERID_StepperResolution = ( (0 << 24) | 79 ), + /// \brief The StepperRunningCurrent parameter + PARAMETERID_StepperRunningCurrent = ( (0 << 24) | 80 ), + /// \brief The StepperHoldingCurrent parameter + PARAMETERID_StepperHoldingCurrent = ( (0 << 24) | 81 ), + /// \brief The StepperVerificationSpeed parameter + PARAMETERID_StepperVerificationSpeed = ( (0 << 24) | 82 ), + /// \brief The LimitDebounceDistance parameter + PARAMETERID_LimitDebounceDistance = ( (0 << 24) | 83 ), + /// \brief The ServoFilter2CoeffN0 parameter + PARAMETERID_ServoFilter2CoeffN0 = ( (0 << 24) | 84 ), + /// \brief The ServoFilter2CoeffN1 parameter + PARAMETERID_ServoFilter2CoeffN1 = ( (0 << 24) | 85 ), + /// \brief The ServoFilter2CoeffN2 parameter + PARAMETERID_ServoFilter2CoeffN2 = ( (0 << 24) | 86 ), + /// \brief The ServoFilter2CoeffD1 parameter + PARAMETERID_ServoFilter2CoeffD1 = ( (0 << 24) | 87 ), + /// \brief The ServoFilter2CoeffD2 parameter + PARAMETERID_ServoFilter2CoeffD2 = ( (0 << 24) | 88 ), + /// \brief The ServoFilter3CoeffN0 parameter + PARAMETERID_ServoFilter3CoeffN0 = ( (0 << 24) | 89 ), + /// \brief The ServoFilter3CoeffN1 parameter + PARAMETERID_ServoFilter3CoeffN1 = ( (0 << 24) | 90 ), + /// \brief The ServoFilter3CoeffN2 parameter + PARAMETERID_ServoFilter3CoeffN2 = ( (0 << 24) | 91 ), + /// \brief The ServoFilter3CoeffD1 parameter + PARAMETERID_ServoFilter3CoeffD1 = ( (0 << 24) | 92 ), + /// \brief The ServoFilter3CoeffD2 parameter + PARAMETERID_ServoFilter3CoeffD2 = ( (0 << 24) | 93 ), + /// \brief The MaxJogSpeed parameter + PARAMETERID_MaxJogSpeed = ( (0 << 24) | 96 ), + /// \brief The DecimalPlaces parameter + PARAMETERID_DecimalPlaces = ( (0 << 24) | 97 ), + /// \brief The UnitsName parameter + PARAMETERID_UnitsName = ( (0 << 24) | 98 ), + /// \brief The AxisName parameter + PARAMETERID_AxisName = ( (0 << 24) | 99 ), + /// \brief The EnDatEncoderSetup parameter + PARAMETERID_EnDatEncoderSetup = ( (0 << 24) | 100 ), + /// \brief The EnDatEncoderResolution parameter + PARAMETERID_EnDatEncoderResolution = ( (0 << 24) | 101 ), + /// \brief The EnDatEncoderTurns parameter + PARAMETERID_EnDatEncoderTurns = ( (0 << 24) | 102 ), + /// \brief The JoystickLowSpeed parameter + PARAMETERID_JoystickLowSpeed = ( (0 << 24) | 103 ), + /// \brief The JoystickHighSpeed parameter + PARAMETERID_JoystickHighSpeed = ( (0 << 24) | 104 ), + /// \brief The HomePositionSet parameter + PARAMETERID_HomePositionSet = ( (0 << 24) | 105 ), + /// \brief The FaultMaskDisableDelay parameter + PARAMETERID_FaultMaskDisableDelay = ( (0 << 24) | 106 ), + /// \brief The FaultAbortAxes parameter + PARAMETERID_FaultAbortAxes = ( (0 << 24) | 107 ), + /// \brief The HarmonicCancellation0Type parameter + PARAMETERID_HarmonicCancellation0Type = ( (0 << 24) | 108 ), + /// \brief The HarmonicCancellation0Period parameter + PARAMETERID_HarmonicCancellation0Period = ( (0 << 24) | 109 ), + /// \brief The HarmonicCancellation0Channel parameter + PARAMETERID_HarmonicCancellation0Channel = ( (0 << 24) | 110 ), + /// \brief The HarmonicCancellation0Gain parameter + PARAMETERID_HarmonicCancellation0Gain = ( (0 << 24) | 111 ), + /// \brief The HarmonicCancellation0Phase parameter + PARAMETERID_HarmonicCancellation0Phase = ( (0 << 24) | 112 ), + /// \brief The HarmonicCancellation1Type parameter + PARAMETERID_HarmonicCancellation1Type = ( (0 << 24) | 113 ), + /// \brief The HarmonicCancellation1Period parameter + PARAMETERID_HarmonicCancellation1Period = ( (0 << 24) | 114 ), + /// \brief The HarmonicCancellation1Channel parameter + PARAMETERID_HarmonicCancellation1Channel = ( (0 << 24) | 115 ), + /// \brief The HarmonicCancellation1Gain parameter + PARAMETERID_HarmonicCancellation1Gain = ( (0 << 24) | 116 ), + /// \brief The HarmonicCancellation1Phase parameter + PARAMETERID_HarmonicCancellation1Phase = ( (0 << 24) | 117 ), + /// \brief The HarmonicCancellation2Type parameter + PARAMETERID_HarmonicCancellation2Type = ( (0 << 24) | 118 ), + /// \brief The HarmonicCancellation2Period parameter + PARAMETERID_HarmonicCancellation2Period = ( (0 << 24) | 119 ), + /// \brief The HarmonicCancellation2Channel parameter + PARAMETERID_HarmonicCancellation2Channel = ( (0 << 24) | 120 ), + /// \brief The HarmonicCancellation2Gain parameter + PARAMETERID_HarmonicCancellation2Gain = ( (0 << 24) | 121 ), + /// \brief The HarmonicCancellation2Phase parameter + PARAMETERID_HarmonicCancellation2Phase = ( (0 << 24) | 122 ), + /// \brief The ResolverReferenceGain parameter + PARAMETERID_ResolverReferenceGain = ( (0 << 24) | 123 ), + /// \brief The ResolverSetup parameter + PARAMETERID_ResolverSetup = ( (0 << 24) | 124 ), + /// \brief The ResolverReferencePhase parameter + PARAMETERID_ResolverReferencePhase = ( (0 << 24) | 125 ), + /// \brief The SoftwareLimitSetup parameter + PARAMETERID_SoftwareLimitSetup = ( (0 << 24) | 126 ), + /// \brief The SSINet1Setup parameter + PARAMETERID_SSINet1Setup = ( (0 << 24) | 127 ), + /// \brief The SSINet2Setup parameter + PARAMETERID_SSINet2Setup = ( (0 << 24) | 128 ), + /// \brief The EmulatedQuadratureDivider parameter + PARAMETERID_EmulatedQuadratureDivider = ( (0 << 24) | 129 ), + /// \brief The HarmonicCancellation3Type parameter + PARAMETERID_HarmonicCancellation3Type = ( (0 << 24) | 130 ), + /// \brief The HarmonicCancellation3Period parameter + PARAMETERID_HarmonicCancellation3Period = ( (0 << 24) | 131 ), + /// \brief The HarmonicCancellation3Channel parameter + PARAMETERID_HarmonicCancellation3Channel = ( (0 << 24) | 132 ), + /// \brief The HarmonicCancellation3Gain parameter + PARAMETERID_HarmonicCancellation3Gain = ( (0 << 24) | 133 ), + /// \brief The HarmonicCancellation3Phase parameter + PARAMETERID_HarmonicCancellation3Phase = ( (0 << 24) | 134 ), + /// \brief The HarmonicCancellation4Type parameter + PARAMETERID_HarmonicCancellation4Type = ( (0 << 24) | 135 ), + /// \brief The HarmonicCancellation4Period parameter + PARAMETERID_HarmonicCancellation4Period = ( (0 << 24) | 136 ), + /// \brief The HarmonicCancellation4Channel parameter + PARAMETERID_HarmonicCancellation4Channel = ( (0 << 24) | 137 ), + /// \brief The HarmonicCancellation4Gain parameter + PARAMETERID_HarmonicCancellation4Gain = ( (0 << 24) | 138 ), + /// \brief The HarmonicCancellation4Phase parameter + PARAMETERID_HarmonicCancellation4Phase = ( (0 << 24) | 139 ), + /// \brief The EnhancedThroughputChannel parameter + PARAMETERID_EnhancedThroughputChannel = ( (0 << 24) | 140 ), + /// \brief The EnhancedThroughputGain parameter + PARAMETERID_EnhancedThroughputGain = ( (0 << 24) | 141 ), + /// \brief The HarmonicCancellationSetup parameter + PARAMETERID_HarmonicCancellationSetup = ( (0 << 24) | 142 ), + /// \brief The EnhancedThroughputCurrentClamp parameter + PARAMETERID_EnhancedThroughputCurrentClamp = ( (0 << 24) | 143 ), + /// \brief The Analog0Filter0CoeffN0 parameter + PARAMETERID_Analog0Filter0CoeffN0 = ( (0 << 24) | 144 ), + /// \brief The Analog0Filter0CoeffN1 parameter + PARAMETERID_Analog0Filter0CoeffN1 = ( (0 << 24) | 145 ), + /// \brief The Analog0Filter0CoeffN2 parameter + PARAMETERID_Analog0Filter0CoeffN2 = ( (0 << 24) | 146 ), + /// \brief The Analog0Filter0CoeffD1 parameter + PARAMETERID_Analog0Filter0CoeffD1 = ( (0 << 24) | 147 ), + /// \brief The Analog0Filter0CoeffD2 parameter + PARAMETERID_Analog0Filter0CoeffD2 = ( (0 << 24) | 148 ), + /// \brief The Analog0Filter1CoeffN0 parameter + PARAMETERID_Analog0Filter1CoeffN0 = ( (0 << 24) | 149 ), + /// \brief The Analog0Filter1CoeffN1 parameter + PARAMETERID_Analog0Filter1CoeffN1 = ( (0 << 24) | 150 ), + /// \brief The Analog0Filter1CoeffN2 parameter + PARAMETERID_Analog0Filter1CoeffN2 = ( (0 << 24) | 151 ), + /// \brief The Analog0Filter1CoeffD1 parameter + PARAMETERID_Analog0Filter1CoeffD1 = ( (0 << 24) | 152 ), + /// \brief The Analog0Filter1CoeffD2 parameter + PARAMETERID_Analog0Filter1CoeffD2 = ( (0 << 24) | 153 ), + /// \brief The Analog1Filter0CoeffN0 parameter + PARAMETERID_Analog1Filter0CoeffN0 = ( (0 << 24) | 154 ), + /// \brief The Analog1Filter0CoeffN1 parameter + PARAMETERID_Analog1Filter0CoeffN1 = ( (0 << 24) | 155 ), + /// \brief The Analog1Filter0CoeffN2 parameter + PARAMETERID_Analog1Filter0CoeffN2 = ( (0 << 24) | 156 ), + /// \brief The Analog1Filter0CoeffD1 parameter + PARAMETERID_Analog1Filter0CoeffD1 = ( (0 << 24) | 157 ), + /// \brief The Analog1Filter0CoeffD2 parameter + PARAMETERID_Analog1Filter0CoeffD2 = ( (0 << 24) | 158 ), + /// \brief The Analog1Filter1CoeffN0 parameter + PARAMETERID_Analog1Filter1CoeffN0 = ( (0 << 24) | 159 ), + /// \brief The Analog1Filter1CoeffN1 parameter + PARAMETERID_Analog1Filter1CoeffN1 = ( (0 << 24) | 160 ), + /// \brief The Analog1Filter1CoeffN2 parameter + PARAMETERID_Analog1Filter1CoeffN2 = ( (0 << 24) | 161 ), + /// \brief The Analog1Filter1CoeffD1 parameter + PARAMETERID_Analog1Filter1CoeffD1 = ( (0 << 24) | 162 ), + /// \brief The Analog1Filter1CoeffD2 parameter + PARAMETERID_Analog1Filter1CoeffD2 = ( (0 << 24) | 163 ), + /// \brief The DefaultRampMode parameter + PARAMETERID_DefaultRampMode = ( (0 << 24) | 164 ), + /// \brief The DefaultRampTime parameter + PARAMETERID_DefaultRampTime = ( (0 << 24) | 165 ), + /// \brief The ServoFilterSetup parameter + PARAMETERID_ServoFilterSetup = ( (0 << 24) | 167 ), + /// \brief The FeedbackSetup parameter + PARAMETERID_FeedbackSetup = ( (0 << 24) | 168 ), + /// \brief The EncoderMultiplierSetup parameter + PARAMETERID_EncoderMultiplierSetup = ( (0 << 24) | 169 ), + /// \brief The FaultSetup parameter + PARAMETERID_FaultSetup = ( (0 << 24) | 170 ), + /// \brief The ThresholdScheduleSetup parameter + PARAMETERID_ThresholdScheduleSetup = ( (0 << 24) | 171 ), + /// \brief The ThresholdRegion2High parameter + PARAMETERID_ThresholdRegion2High = ( (0 << 24) | 172 ), + /// \brief The ThresholdRegion2Low parameter + PARAMETERID_ThresholdRegion2Low = ( (0 << 24) | 173 ), + /// \brief The ThresholdRegion3GainKpos parameter + PARAMETERID_ThresholdRegion3GainKpos = ( (0 << 24) | 174 ), + /// \brief The ThresholdRegion3GainKp parameter + PARAMETERID_ThresholdRegion3GainKp = ( (0 << 24) | 175 ), + /// \brief The ThresholdRegion3GainKi parameter + PARAMETERID_ThresholdRegion3GainKi = ( (0 << 24) | 176 ), + /// \brief The ThresholdRegion3GainKpi parameter + PARAMETERID_ThresholdRegion3GainKpi = ( (0 << 24) | 177 ), + /// \brief The ThresholdRegion4High parameter + PARAMETERID_ThresholdRegion4High = ( (0 << 24) | 178 ), + /// \brief The ThresholdRegion4Low parameter + PARAMETERID_ThresholdRegion4Low = ( (0 << 24) | 179 ), + /// \brief The ThresholdRegion5GainKpos parameter + PARAMETERID_ThresholdRegion5GainKpos = ( (0 << 24) | 180 ), + /// \brief The ThresholdRegion5GainKp parameter + PARAMETERID_ThresholdRegion5GainKp = ( (0 << 24) | 181 ), + /// \brief The ThresholdRegion5GainKi parameter + PARAMETERID_ThresholdRegion5GainKi = ( (0 << 24) | 182 ), + /// \brief The ThresholdRegion5GainKpi parameter + PARAMETERID_ThresholdRegion5GainKpi = ( (0 << 24) | 183 ), + /// \brief The DynamicScheduleSetup parameter + PARAMETERID_DynamicScheduleSetup = ( (0 << 24) | 184 ), + /// \brief The DynamicGainKposScale parameter + PARAMETERID_DynamicGainKposScale = ( (0 << 24) | 185 ), + /// \brief The DynamicGainKpScale parameter + PARAMETERID_DynamicGainKpScale = ( (0 << 24) | 186 ), + /// \brief The DynamicGainKiScale parameter + PARAMETERID_DynamicGainKiScale = ( (0 << 24) | 187 ), + /// \brief The ServoFilter4CoeffN0 parameter + PARAMETERID_ServoFilter4CoeffN0 = ( (0 << 24) | 188 ), + /// \brief The ServoFilter4CoeffN1 parameter + PARAMETERID_ServoFilter4CoeffN1 = ( (0 << 24) | 189 ), + /// \brief The ServoFilter4CoeffN2 parameter + PARAMETERID_ServoFilter4CoeffN2 = ( (0 << 24) | 190 ), + /// \brief The ServoFilter4CoeffD1 parameter + PARAMETERID_ServoFilter4CoeffD1 = ( (0 << 24) | 191 ), + /// \brief The ServoFilter4CoeffD2 parameter + PARAMETERID_ServoFilter4CoeffD2 = ( (0 << 24) | 192 ), + /// \brief The ServoFilter5CoeffN0 parameter + PARAMETERID_ServoFilter5CoeffN0 = ( (0 << 24) | 193 ), + /// \brief The ServoFilter5CoeffN1 parameter + PARAMETERID_ServoFilter5CoeffN1 = ( (0 << 24) | 194 ), + /// \brief The ServoFilter5CoeffN2 parameter + PARAMETERID_ServoFilter5CoeffN2 = ( (0 << 24) | 195 ), + /// \brief The ServoFilter5CoeffD1 parameter + PARAMETERID_ServoFilter5CoeffD1 = ( (0 << 24) | 196 ), + /// \brief The ServoFilter5CoeffD2 parameter + PARAMETERID_ServoFilter5CoeffD2 = ( (0 << 24) | 197 ), + /// \brief The ServoFilter6CoeffN0 parameter + PARAMETERID_ServoFilter6CoeffN0 = ( (0 << 24) | 198 ), + /// \brief The ServoFilter6CoeffN1 parameter + PARAMETERID_ServoFilter6CoeffN1 = ( (0 << 24) | 199 ), + /// \brief The ServoFilter6CoeffN2 parameter + PARAMETERID_ServoFilter6CoeffN2 = ( (0 << 24) | 200 ), + /// \brief The ServoFilter6CoeffD1 parameter + PARAMETERID_ServoFilter6CoeffD1 = ( (0 << 24) | 201 ), + /// \brief The ServoFilter6CoeffD2 parameter + PARAMETERID_ServoFilter6CoeffD2 = ( (0 << 24) | 202 ), + /// \brief The ServoFilter7CoeffN0 parameter + PARAMETERID_ServoFilter7CoeffN0 = ( (0 << 24) | 203 ), + /// \brief The ServoFilter7CoeffN1 parameter + PARAMETERID_ServoFilter7CoeffN1 = ( (0 << 24) | 204 ), + /// \brief The ServoFilter7CoeffN2 parameter + PARAMETERID_ServoFilter7CoeffN2 = ( (0 << 24) | 205 ), + /// \brief The ServoFilter7CoeffD1 parameter + PARAMETERID_ServoFilter7CoeffD1 = ( (0 << 24) | 206 ), + /// \brief The ServoFilter7CoeffD2 parameter + PARAMETERID_ServoFilter7CoeffD2 = ( (0 << 24) | 207 ), + /// \brief The LinearAmpMaxPower parameter + PARAMETERID_LinearAmpMaxPower = ( (0 << 24) | 208 ), + /// \brief The LinearAmpDeratingFactor parameter + PARAMETERID_LinearAmpDeratingFactor = ( (0 << 24) | 209 ), + /// \brief The LinearAmpBusVoltage parameter + PARAMETERID_LinearAmpBusVoltage = ( (0 << 24) | 210 ), + /// \brief The MotorResistance parameter + PARAMETERID_MotorResistance = ( (0 << 24) | 211 ), + /// \brief The MotorBackEMFConstant parameter + PARAMETERID_MotorBackEMFConstant = ( (0 << 24) | 212 ), + /// \brief The GantrySetup parameter + PARAMETERID_GantrySetup = ( (0 << 24) | 213 ), + /// \brief The RolloverMode parameter + PARAMETERID_RolloverMode = ( (0 << 24) | 214 ), + /// \brief The GantrySeparationThreshold parameter + PARAMETERID_GantrySeparationThreshold = ( (0 << 24) | 215 ), + /// \brief The EmulatedQuadratureChannel parameter + PARAMETERID_EmulatedQuadratureChannel = ( (0 << 24) | 216 ), + /// \brief The ResolverCoarseChannel parameter + PARAMETERID_ResolverCoarseChannel = ( (0 << 24) | 217 ), + /// \brief The ResolverFeedbackRatio parameter + PARAMETERID_ResolverFeedbackRatio = ( (0 << 24) | 218 ), + /// \brief The ResolverFeedbackOffset parameter + PARAMETERID_ResolverFeedbackOffset = ( (0 << 24) | 219 ), + /// \brief The BrakeEnableDelay parameter + PARAMETERID_BrakeEnableDelay = ( (0 << 24) | 220 ), + /// \brief The MaxSpeedClamp parameter + PARAMETERID_MaxSpeedClamp = ( (0 << 24) | 221 ), + /// \brief The AutotuneAmplitude parameter + PARAMETERID_AutotuneAmplitude = ( (0 << 24) | 222 ), + /// \brief The AutotuneFrequency parameter + PARAMETERID_AutotuneFrequency = ( (0 << 24) | 223 ), + /// \brief The AutotuneBandwidth parameter + PARAMETERID_AutotuneBandwidth = ( (0 << 24) | 224 ), + /// \brief The AutotunePhaseMargin parameter + PARAMETERID_AutotunePhaseMargin = ( (0 << 24) | 225 ), + /// \brief The TrajectoryFIRFilter parameter + PARAMETERID_TrajectoryFIRFilter = ( (0 << 24) | 226 ), + /// \brief The TrajectoryIIRFilter parameter + PARAMETERID_TrajectoryIIRFilter = ( (0 << 24) | 227 ), + /// \brief The CalibrationIIRFilter parameter + PARAMETERID_CalibrationIIRFilter = ( (0 << 24) | 228 ), + /// \brief The BacklashIIRFilter parameter + PARAMETERID_BacklashIIRFilter = ( (0 << 24) | 229 ), + /// \brief The InPositionTime parameter + PARAMETERID_InPositionTime = ( (0 << 24) | 230 ), + /// \brief The InPositionDisableTimeout parameter + PARAMETERID_InPositionDisableTimeout = ( (0 << 24) | 231 ), + /// \brief The Stability0Threshold parameter + PARAMETERID_Stability0Threshold = ( (0 << 24) | 232 ), + /// \brief The Stability0Time parameter + PARAMETERID_Stability0Time = ( (0 << 24) | 233 ), + /// \brief The GainDff parameter + PARAMETERID_GainDff = ( (0 << 24) | 234 ), + /// \brief The StaticFrictionCompensation parameter + PARAMETERID_StaticFrictionCompensation = ( (0 << 24) | 235 ), + /// \brief The ServoOutputScaling parameter + PARAMETERID_ServoOutputScaling = ( (0 << 24) | 236 ), + /// \brief The ExternalFaultAnalogInput parameter + PARAMETERID_ExternalFaultAnalogInput = ( (0 << 24) | 238 ), + /// \brief The ExternalFaultThreshold parameter + PARAMETERID_ExternalFaultThreshold = ( (0 << 24) | 239 ), + /// \brief The Stability1Threshold parameter + PARAMETERID_Stability1Threshold = ( (0 << 24) | 241 ), + /// \brief The Stability1Time parameter + PARAMETERID_Stability1Time = ( (0 << 24) | 242 ), + /// \brief The AnalogFilterSetup parameter + PARAMETERID_AnalogFilterSetup = ( (0 << 24) | 243 ), + /// \brief The DefaultRampType parameter + PARAMETERID_DefaultRampType = ( (0 << 24) | 244 ), + /// \brief The ServoOutputOffsetA parameter + PARAMETERID_ServoOutputOffsetA = ( (0 << 24) | 245 ), + /// \brief The ServoOutputOffsetB parameter + PARAMETERID_ServoOutputOffsetB = ( (0 << 24) | 246 ), + /// \brief The AutoDisableTimeout parameter + PARAMETERID_AutoDisableTimeout = ( (0 << 24) | 247 ), + /// \brief The DriveIPAddress parameter + PARAMETERID_DriveIPAddress = ( (0 << 24) | 256 ), + /// \brief The DriveSubnetMask parameter + PARAMETERID_DriveSubnetMask = ( (0 << 24) | 257 ), + /// \brief The DriveDefaultGateway parameter + PARAMETERID_DriveDefaultGateway = ( (0 << 24) | 258 ), + /// \brief The CurrentOffsetA parameter + PARAMETERID_CurrentOffsetA = ( (0 << 24) | 259 ), + /// \brief The CurrentOffsetB parameter + PARAMETERID_CurrentOffsetB = ( (0 << 24) | 260 ), + /// \brief The CommandShaperSetup parameter + PARAMETERID_CommandShaperSetup = ( (0 << 24) | 261 ), + /// \brief The CommandShaperTime00 parameter + PARAMETERID_CommandShaperTime00 = ( (0 << 24) | 262 ), + /// \brief The CommandShaperTime01 parameter + PARAMETERID_CommandShaperTime01 = ( (0 << 24) | 263 ), + /// \brief The CommandShaperTime02 parameter + PARAMETERID_CommandShaperTime02 = ( (0 << 24) | 264 ), + /// \brief The CommandShaperTime03 parameter + PARAMETERID_CommandShaperTime03 = ( (0 << 24) | 265 ), + /// \brief The CommandShaperTime04 parameter + PARAMETERID_CommandShaperTime04 = ( (0 << 24) | 266 ), + /// \brief The CommandShaperTime05 parameter + PARAMETERID_CommandShaperTime05 = ( (0 << 24) | 267 ), + /// \brief The CommandShaperTime06 parameter + PARAMETERID_CommandShaperTime06 = ( (0 << 24) | 268 ), + /// \brief The CommandShaperTime07 parameter + PARAMETERID_CommandShaperTime07 = ( (0 << 24) | 269 ), + /// \brief The CommandShaperTime08 parameter + PARAMETERID_CommandShaperTime08 = ( (0 << 24) | 270 ), + /// \brief The CommandShaperTime09 parameter + PARAMETERID_CommandShaperTime09 = ( (0 << 24) | 271 ), + /// \brief The CommandShaperTime10 parameter + PARAMETERID_CommandShaperTime10 = ( (0 << 24) | 272 ), + /// \brief The CommandShaperTime11 parameter + PARAMETERID_CommandShaperTime11 = ( (0 << 24) | 273 ), + /// \brief The CommandShaperTime12 parameter + PARAMETERID_CommandShaperTime12 = ( (0 << 24) | 274 ), + /// \brief The CommandShaperTime13 parameter + PARAMETERID_CommandShaperTime13 = ( (0 << 24) | 275 ), + /// \brief The CommandShaperTime14 parameter + PARAMETERID_CommandShaperTime14 = ( (0 << 24) | 276 ), + /// \brief The CommandShaperTime15 parameter + PARAMETERID_CommandShaperTime15 = ( (0 << 24) | 277 ), + /// \brief The CommandShaperCoeff00 parameter + PARAMETERID_CommandShaperCoeff00 = ( (0 << 24) | 278 ), + /// \brief The CommandShaperCoeff01 parameter + PARAMETERID_CommandShaperCoeff01 = ( (0 << 24) | 279 ), + /// \brief The CommandShaperCoeff02 parameter + PARAMETERID_CommandShaperCoeff02 = ( (0 << 24) | 280 ), + /// \brief The CommandShaperCoeff03 parameter + PARAMETERID_CommandShaperCoeff03 = ( (0 << 24) | 281 ), + /// \brief The CommandShaperCoeff04 parameter + PARAMETERID_CommandShaperCoeff04 = ( (0 << 24) | 282 ), + /// \brief The CommandShaperCoeff05 parameter + PARAMETERID_CommandShaperCoeff05 = ( (0 << 24) | 283 ), + /// \brief The CommandShaperCoeff06 parameter + PARAMETERID_CommandShaperCoeff06 = ( (0 << 24) | 284 ), + /// \brief The CommandShaperCoeff07 parameter + PARAMETERID_CommandShaperCoeff07 = ( (0 << 24) | 285 ), + /// \brief The CommandShaperCoeff08 parameter + PARAMETERID_CommandShaperCoeff08 = ( (0 << 24) | 286 ), + /// \brief The CommandShaperCoeff09 parameter + PARAMETERID_CommandShaperCoeff09 = ( (0 << 24) | 287 ), + /// \brief The CommandShaperCoeff10 parameter + PARAMETERID_CommandShaperCoeff10 = ( (0 << 24) | 288 ), + /// \brief The CommandShaperCoeff11 parameter + PARAMETERID_CommandShaperCoeff11 = ( (0 << 24) | 289 ), + /// \brief The CommandShaperCoeff12 parameter + PARAMETERID_CommandShaperCoeff12 = ( (0 << 24) | 290 ), + /// \brief The CommandShaperCoeff13 parameter + PARAMETERID_CommandShaperCoeff13 = ( (0 << 24) | 291 ), + /// \brief The CommandShaperCoeff14 parameter + PARAMETERID_CommandShaperCoeff14 = ( (0 << 24) | 292 ), + /// \brief The CommandShaperCoeff15 parameter + PARAMETERID_CommandShaperCoeff15 = ( (0 << 24) | 293 ), + /// \brief The CommandShaper0Type parameter + PARAMETERID_CommandShaper0Type = ( (0 << 24) | 294 ), + /// \brief The CommandShaper0Frequency parameter + PARAMETERID_CommandShaper0Frequency = ( (0 << 24) | 295 ), + /// \brief The CommandShaper0Damping parameter + PARAMETERID_CommandShaper0Damping = ( (0 << 24) | 296 ), + /// \brief The CommandShaper1Type parameter + PARAMETERID_CommandShaper1Type = ( (0 << 24) | 297 ), + /// \brief The CommandShaper1Frequency parameter + PARAMETERID_CommandShaper1Frequency = ( (0 << 24) | 298 ), + /// \brief The CommandShaper1Damping parameter + PARAMETERID_CommandShaper1Damping = ( (0 << 24) | 299 ), + /// \brief The ResoluteEncoderSetup parameter + PARAMETERID_ResoluteEncoderSetup = ( (0 << 24) | 306 ), + /// \brief The ResoluteEncoderResolution parameter + PARAMETERID_ResoluteEncoderResolution = ( (0 << 24) | 307 ), + /// \brief The ResoluteEncoderUserResolution parameter + PARAMETERID_ResoluteEncoderUserResolution = ( (0 << 24) | 308 ), + /// \brief The AutofocusInput parameter + PARAMETERID_AutofocusInput = ( (0 << 24) | 312 ), + /// \brief The AutofocusTarget parameter + PARAMETERID_AutofocusTarget = ( (0 << 24) | 313 ), + /// \brief The AutofocusDeadband parameter + PARAMETERID_AutofocusDeadband = ( (0 << 24) | 314 ), + /// \brief The AutofocusGainKi parameter + PARAMETERID_AutofocusGainKi = ( (0 << 24) | 315 ), + /// \brief The AutofocusGainKp parameter + PARAMETERID_AutofocusGainKp = ( (0 << 24) | 316 ), + /// \brief The AutofocusLimitLow parameter + PARAMETERID_AutofocusLimitLow = ( (0 << 24) | 317 ), + /// \brief The AutofocusLimitHigh parameter + PARAMETERID_AutofocusLimitHigh = ( (0 << 24) | 318 ), + /// \brief The AutofocusSpeedClamp parameter + PARAMETERID_AutofocusSpeedClamp = ( (0 << 24) | 319 ), + /// \brief The AutofocusHoldInput parameter + PARAMETERID_AutofocusHoldInput = ( (0 << 24) | 320 ), + /// \brief The AutofocusSetup parameter + PARAMETERID_AutofocusSetup = ( (0 << 24) | 321 ), + /// \brief The TrajectoryDelayFilter parameter + PARAMETERID_TrajectoryDelayFilter = ( (0 << 24) | 322 ), + /// \brief The EncoderTrackingSensitivity parameter + PARAMETERID_EncoderTrackingSensitivity = ( (0 << 24) | 323 ), + /// \brief The MotorOutputConstant parameter + PARAMETERID_MotorOutputConstant = ( (0 << 24) | 334 ), + /// \brief The MotorOutputUnitsName parameter + PARAMETERID_MotorOutputUnitsName = ( (0 << 24) | 335 ), + /// \brief The TrajectoryDecimationTime parameter + PARAMETERID_TrajectoryDecimationTime = ( (0 << 24) | 336 ), + /// \brief The CrossAxisFeedforward00Axis parameter + PARAMETERID_CrossAxisFeedforward00Axis = ( (0 << 24) | 337 ), + /// \brief The CrossAxisFeedforward01Axis parameter + PARAMETERID_CrossAxisFeedforward01Axis = ( (0 << 24) | 338 ), + /// \brief The CrossAxisFeedforward02Axis parameter + PARAMETERID_CrossAxisFeedforward02Axis = ( (0 << 24) | 339 ), + /// \brief The CrossAxisFeedforward03Axis parameter + PARAMETERID_CrossAxisFeedforward03Axis = ( (0 << 24) | 340 ), + /// \brief The CrossAxisFeedforward04Axis parameter + PARAMETERID_CrossAxisFeedforward04Axis = ( (0 << 24) | 341 ), + /// \brief The CrossAxisFeedforward05Axis parameter + PARAMETERID_CrossAxisFeedforward05Axis = ( (0 << 24) | 342 ), + /// \brief The CrossAxisFeedforward00Gain parameter + PARAMETERID_CrossAxisFeedforward00Gain = ( (0 << 24) | 343 ), + /// \brief The CrossAxisFeedforward01Gain parameter + PARAMETERID_CrossAxisFeedforward01Gain = ( (0 << 24) | 344 ), + /// \brief The CrossAxisFeedforward02Gain parameter + PARAMETERID_CrossAxisFeedforward02Gain = ( (0 << 24) | 345 ), + /// \brief The CrossAxisFeedforward03Gain parameter + PARAMETERID_CrossAxisFeedforward03Gain = ( (0 << 24) | 346 ), + /// \brief The CrossAxisFeedforward04Gain parameter + PARAMETERID_CrossAxisFeedforward04Gain = ( (0 << 24) | 347 ), + /// \brief The CrossAxisFeedforward05Gain parameter + PARAMETERID_CrossAxisFeedforward05Gain = ( (0 << 24) | 348 ), + /// \brief The GainPff parameter + PARAMETERID_GainPff = ( (0 << 24) | 350 ), + /// \brief The AutofocusInitialRampTime parameter + PARAMETERID_AutofocusInitialRampTime = ( (0 << 24) | 351 ), + /// \brief The PositionAveragingChannel parameter + PARAMETERID_PositionAveragingChannel = ( (0 << 24) | 352 ), + /// \brief The EndOfTravelCurrentThresholdLow parameter + PARAMETERID_EndOfTravelCurrentThresholdLow = ( (0 << 24) | 353 ), + /// \brief The EndOfTravelCurrentThresholdHigh parameter + PARAMETERID_EndOfTravelCurrentThresholdHigh = ( (0 << 24) | 354 ), + /// \brief The AutofocusGainKi2 parameter + PARAMETERID_AutofocusGainKi2 = ( (0 << 24) | 355 ), + /// \brief The EnDatEncoderIncrementalResolution parameter + PARAMETERID_EnDatEncoderIncrementalResolution = ( (0 << 24) | 356 ), + /// \brief The MarkerSearchThreshold parameter + PARAMETERID_MarkerSearchThreshold = ( (0 << 24) | 357 ), + /// \brief The GainKd1 parameter + PARAMETERID_GainKd1 = ( (0 << 24) | 358 ), + /// \brief The GainKp1 parameter + PARAMETERID_GainKp1 = ( (0 << 24) | 359 ), + /// \brief The VelocityCommandThresholdBeforeHome parameter + PARAMETERID_VelocityCommandThresholdBeforeHome = ( (0 << 24) | 360 ), + /// \brief The SecondaryEncoderSineGain parameter + PARAMETERID_SecondaryEncoderSineGain = ( (0 << 24) | 361 ), + /// \brief The SecondaryEncoderSineOffset parameter + PARAMETERID_SecondaryEncoderSineOffset = ( (0 << 24) | 362 ), + /// \brief The SecondaryEncoderCosineGain parameter + PARAMETERID_SecondaryEncoderCosineGain = ( (0 << 24) | 363 ), + /// \brief The SecondaryEncoderCosineOffset parameter + PARAMETERID_SecondaryEncoderCosineOffset = ( (0 << 24) | 364 ), + /// \brief The SecondaryEncoderPhase parameter + PARAMETERID_SecondaryEncoderPhase = ( (0 << 24) | 365 ), + /// \brief The DriveOutputCommandDelay parameter + PARAMETERID_DriveOutputCommandDelay = ( (0 << 24) | 366 ), + /// \brief The InPosition2Distance parameter + PARAMETERID_InPosition2Distance = ( (0 << 24) | 367 ), + /// \brief The InPosition2Time parameter + PARAMETERID_InPosition2Time = ( (0 << 24) | 368 ), + /// \brief The StepperRunningCurrentDelay parameter + PARAMETERID_StepperRunningCurrentDelay = ( (0 << 24) | 369 ), + /// \brief The AbsoluteFeedbackOffset parameter + PARAMETERID_AbsoluteFeedbackOffset = ( (0 << 24) | 371 ), + /// \brief The CapSensorFilterLength parameter + PARAMETERID_CapSensorFilterLength = ( (0 << 24) | 373 ), + /// \brief The EnhancedTrackingScale parameter + PARAMETERID_EnhancedTrackingScale = ( (0 << 24) | 374 ), + /// \brief The EnhancedTrackingBandwidth parameter + PARAMETERID_EnhancedTrackingBandwidth = ( (0 << 24) | 375 ), + /// \brief The Analog0InputOffset parameter + PARAMETERID_Analog0InputOffset = ( (0 << 24) | 376 ), + /// \brief The Analog1InputOffset parameter + PARAMETERID_Analog1InputOffset = ( (0 << 24) | 377 ), + /// \brief The Analog2InputOffset parameter + PARAMETERID_Analog2InputOffset = ( (0 << 24) | 378 ), + /// \brief The Analog3InputOffset parameter + PARAMETERID_Analog3InputOffset = ( (0 << 24) | 379 ), + /// \brief The EnhancedTrackingSetup parameter + PARAMETERID_EnhancedTrackingSetup = ( (0 << 24) | 380 ), + /// \brief The EncoderMarkerAlignment parameter + PARAMETERID_EncoderMarkerAlignment = ( (0 << 24) | 381 ), + /// \brief The EncoderRadiusThresholdLow parameter + PARAMETERID_EncoderRadiusThresholdLow = ( (0 << 24) | 382 ), + /// \brief The EncoderRadiusThresholdHigh parameter + PARAMETERID_EncoderRadiusThresholdHigh = ( (0 << 24) | 383 ), + /// \brief The GainKsi1 parameter + PARAMETERID_GainKsi1 = ( (0 << 24) | 384 ), + /// \brief The GainKsi2 parameter + PARAMETERID_GainKsi2 = ( (0 << 24) | 385 ), +} PARAMETERID; + +#endif // __A3200_PARAMETER_ID_H__ diff --git a/motorApp/AerotechSrc/AerotechRegister.cc b/motorApp/AerotechSrc/AerotechRegister.cc index 784c23ba..13def787 100644 --- a/motorApp/AerotechSrc/AerotechRegister.cc +++ b/motorApp/AerotechSrc/AerotechRegister.cc @@ -41,26 +41,49 @@ static const iocshFuncDef setupSoloist = {"SoloistSetup", 2, SoloistSetupArgs} static const iocshFuncDef configSoloist = {"SoloistConfig", 2, SoloistConfigArgs}; // Ensemble Asyn Setup arguments -static const iocshArg asynSetupArg0 = {"Max. controller count", iocshArgInt}; +static const iocshArg ensembleAsynSetupArg0 = {"Max. controller count", iocshArgInt}; // Ensemble Asyn Config arguments -static const iocshArg asynConfigArg0 = {"Card being configured", iocshArgInt}; -static const iocshArg asynConfigArg1 = {"asyn port name", iocshArgString}; -static const iocshArg asynConfigArg2 = {"asyn address (GPIB)", iocshArgInt}; -static const iocshArg asynConfigArg3 = {"Number of Axes", iocshArgInt}; -static const iocshArg asynConfigArg4 = {"Moving poll rate", iocshArgInt}; -static const iocshArg asynConfigArg5 = {"Idle poll rate", iocshArgInt}; +static const iocshArg ensembleAsynConfigArg0 = {"Card being configured", iocshArgInt}; +static const iocshArg ensembleAsynConfigArg1 = {"asyn port name", iocshArgString}; +static const iocshArg ensembleAsynConfigArg2 = {"asyn address (GPIB)", iocshArgInt}; +static const iocshArg ensembleAsynConfigArg3 = {"Number of Axes", iocshArgInt}; +static const iocshArg ensembleAsynConfigArg4 = {"Moving poll rate", iocshArgInt}; +static const iocshArg ensembleAsynConfigArg5 = {"Idle poll rate", iocshArgInt}; -static const iocshArg * const EnsembleAsynSetupArgs[2] = {&asynSetupArg0}; -static const iocshArg * const EnsembleAsynConfigArgs[6] = {&asynConfigArg0, - &asynConfigArg1, - &asynConfigArg2, - &asynConfigArg3, - &asynConfigArg4, - &asynConfigArg5}; +// A3200 Asyn Setup arguments +static const iocshArg a3200AsynSetupArg0 = {"Max. controller count", iocshArgInt}; +// A3200 Asyn Config arguments +static const iocshArg a3200AsynConfigArg0 = {"Card being configured", iocshArgInt}; +static const iocshArg a3200AsynConfigArg1 = {"asyn port name", iocshArgString}; +static const iocshArg a3200AsynConfigArg2 = {"asyn address", iocshArgInt}; +static const iocshArg a3200AsynConfigArg3 = {"Number of Axes", iocshArgInt}; +static const iocshArg a3200AsynConfigArg4 = {"Task number", iocshArgInt}; +static const iocshArg a3200AsynConfigArg5 = {"Moving poll rate", iocshArgInt}; +static const iocshArg a3200AsynConfigArg6 = {"Idle poll rate", iocshArgInt}; -static const iocshFuncDef setupEnsembleAsyn = {"EnsembleAsynSetup",1, EnsembleAsynSetupArgs}; +static const iocshArg * const EnsembleAsynSetupArgs[2] = {&ensembleAsynSetupArg0}; +static const iocshArg * const EnsembleAsynConfigArgs[6] = {&ensembleAsynConfigArg0, + &ensembleAsynConfigArg1, + &ensembleAsynConfigArg2, + &ensembleAsynConfigArg3, + &ensembleAsynConfigArg4, + &ensembleAsynConfigArg5}; + +static const iocshFuncDef setupEnsembleAsyn = {"EnsembleAsynSetup", 1, EnsembleAsynSetupArgs}; static const iocshFuncDef configEnsembleAsyn = {"EnsembleAsynConfig", 6, EnsembleAsynConfigArgs}; +static const iocshArg * const A3200AsynSetupArgs[2] = {&a3200AsynSetupArg0}; +static const iocshArg * const A3200AsynConfigArgs[7] = {&a3200AsynConfigArg0, + &a3200AsynConfigArg1, + &a3200AsynConfigArg2, + &a3200AsynConfigArg3, + &a3200AsynConfigArg4, + &a3200AsynConfigArg5, + &a3200AsynConfigArg6}; + +static const iocshFuncDef setupA3200Asyn = {"A3200AsynSetup", 1, A3200AsynSetupArgs}; +static const iocshFuncDef configA3200Asyn = {"A3200AsynConfig", 7, A3200AsynConfigArgs}; + static void setupSoloistCallFunc(const iocshArgBuf *args) { SoloistSetup(args[0].ival, args[1].ival); @@ -80,14 +103,27 @@ static void configEnsembleAsynCallFunc(const iocshArgBuf *args) args[3].ival, args[4].ival, args[5].ival); } +static void setupA3200AsynCallFunc(const iocshArgBuf *args) +{ + A3200AsynSetup(args[0].ival); +} +static void configA3200AsynCallFunc(const iocshArgBuf *args) +{ + A3200AsynConfig(args[0].ival, args[1].sval, args[2].ival, + args[3].ival, args[4].ival, args[5].ival, args[6].ival); +} + static void AerotechRegister(void) { iocshRegister(&setupSoloist, setupSoloistCallFunc); iocshRegister(&configSoloist, configSoloistCallFunc); iocshRegister(&setupEnsembleAsyn, setupEnsembleAsynCallFunc); iocshRegister(&configEnsembleAsyn, configEnsembleAsynCallFunc); + iocshRegister(&setupA3200Asyn, setupA3200AsynCallFunc); + iocshRegister(&configA3200Asyn, configA3200AsynCallFunc); } epicsExportRegistrar(AerotechRegister); } // extern "C" + diff --git a/motorApp/AerotechSrc/AerotechRegister.h b/motorApp/AerotechSrc/AerotechRegister.h index 7a9937a0..977e2fe0 100644 --- a/motorApp/AerotechSrc/AerotechRegister.h +++ b/motorApp/AerotechSrc/AerotechRegister.h @@ -38,11 +38,12 @@ HeadURL: $URL$ * .01 2008/04/10 caw Initial support for Ensemble * .02 2009/04/29 hcf Added support for Soloist * .03 2009/07/28 cjb Added support for Ensemble asynMotor + * .04 2013/11/26 cjb Added support for A3200 asynMotor */ #include "motor.h" #include "motordrvCom.h" #include "drvEnsembleAsyn.h" #include "drvSoloist.h" - +#include "drvA3200Asyn.h" diff --git a/motorApp/AerotechSrc/Makefile b/motorApp/AerotechSrc/Makefile index 5cc847ff..e9ed0094 100644 --- a/motorApp/AerotechSrc/Makefile +++ b/motorApp/AerotechSrc/Makefile @@ -13,6 +13,7 @@ LIBRARY_IOC = Aerotech SRCS += AerotechRegister.cc SRCS += devSoloist.cc drvSoloist.cc SRCS += drvEnsembleAsyn.cc +SRCS += drvA3200Asyn.cc # EnsemblePSOFly.db support SRCS += concatString.c diff --git a/motorApp/AerotechSrc/devAerotech.dbd b/motorApp/AerotechSrc/devAerotech.dbd index 8706d7bd..1a742bf7 100644 --- a/motorApp/AerotechSrc/devAerotech.dbd +++ b/motorApp/AerotechSrc/devAerotech.dbd @@ -5,6 +5,9 @@ driver(drvSoloist) # Aerotech Ensemble asynMotor support driver(motorEnsemble) +# Aerotech A3200 asynMotor support +driver(motorA3200) + registrar(AerotechRegister) registrar(concatStringRegister) registrar(EnsembleTrajectoryScanRegistrar) diff --git a/motorApp/AerotechSrc/drvA3200Asyn.cc b/motorApp/AerotechSrc/drvA3200Asyn.cc new file mode 100644 index 00000000..2cee481c --- /dev/null +++ b/motorApp/AerotechSrc/drvA3200Asyn.cc @@ -0,0 +1,963 @@ +/* +FILENAME... drvA3200Asyn.cc +USAGE... Motor record asyn driver level support for Aerotech A3200. + +Version: $Revision$ +Modified By: $Author$ +Last Modified: $Date$ +HeadURL: $URL$ +*/ + +/* +* Original Author: Corey Bonnell +* Date: 11/15/13 +* Current Author: Aerotech, Inc. +* +----------------------------------------------------------------------------- +COPYRIGHT NOTICE +----------------------------------------------------------------------------- +Copyright (c) 2002 The University of Chicago, as Operator of Argonne +National Laboratory. +Copyright (c) 2002 The Regents of the University of California, as +Operator of Los Alamos National Laboratory. +Synapps Versions 4-5 +and higher are distributed subject to a Software License Agreement found +in file LICENSE that is included with this distribution. +----------------------------------------------------------------------------- +* NOTES +* ----- +* Verified with firmware: +* - 4.07.000 +* +* Modification Log: +* ----------------- +* +* .01 11-15-13 cjb Initialized from drvEnsembleAsyn.c (Aerotech) +*/ + +#include +#include "epicsThread.h" +#include +#include +#include +#include +#include + +#include "epicsFindSymbol.h" +#include "epicsTime.h" +#include "epicsThread.h" +#include "epicsEvent.h" +#include "epicsString.h" +#include "epicsMutex.h" +#include "ellLib.h" +#include "asynDriver.h" +#include "asynOctetSyncIO.h" +#include "errlog.h" + +#include "drvSup.h" +#define DEFINE_MOTOR_PROTOTYPES 1 +#include "motor_interface.h" + +#include "paramLib.h" +#include "drvA3200Asyn.h" +#include "epicsExport.h" + +/* NOTE: The following two files are copied from the A3200 C library include files. +* If changing the driver to target a different version of the A3200, copy the following two files from that version's C library include files */ +#include "A3200CommonStructures.h" +#include "A3200ParameterId.h" + +#define PRINT (drv.print) +#define FLOW motorAxisTraceFlow +#define TERROR motorAxisTraceError +#define IODRIVER motorAxisTraceIODriver + +#define A3200_MAX_AXES 32 +#define DRIVER_NAME "drvA3200Asyn" +#define BUFFER_SIZE 4096 /* Size of input and output buffers */ +#define TIMEOUT 2.0 /* Timeout for I/O in seconds */ + +/* The following should be defined to have the same value as +the A3200 parameters specified */ +#define ASCII_EOS_CHAR '\n' /* CommandTerminatingCharacter */ +#define ASCII_EOS_STR "\n" +#define ASCII_ACK_CHAR '%' /* CommandSuccessCharacter */ +#define ASCII_NAK_CHAR '!' /* CommandInvalidCharacter */ +#define ASCII_FAULT_CHAR '#' /* CommandFaultCharacter */ + +typedef union +{ + epicsUInt32 All; + struct + { +#ifdef MSB_First + unsigned int na5 :27; + unsigned int EOTswitch :1; + unsigned int LIF481mode :1; + unsigned int CWEOTSWstate :1; + unsigned int CCWEOTSWstate :1; + unsigned int HomeSWstate :1; +#else + unsigned int HomeSWstate :1; + unsigned int CCWEOTSWstate :1; + unsigned int CWEOTSWstate :1; + unsigned int LIF481mode :1; + unsigned int EOTswitch :1; + unsigned int na5 :27; +#endif + } Bits; +} Switch_Level; + +motorAxisDrvSET_t motorA3200 = +{ + 14, + motorAxisReport, /**< Standard EPICS driver report function (optional) */ + motorAxisInit, /**< Standard EPICS driver initialization function (optional) */ + motorAxisSetLog, /**< Defines an external logging function (optional) */ + motorAxisOpen, /**< Driver open function */ + motorAxisClose, /**< Driver close function */ + motorAxisSetCallback, /**< Provides a callback function the driver can call when the status updates */ + motorAxisSetDouble, /**< Pointer to function to set a double value */ + motorAxisSetInteger, /**< Pointer to function to set an integer value */ + motorAxisGetDouble, /**< Pointer to function to get a double value */ + motorAxisGetInteger, /**< Pointer to function to get an integer value */ + motorAxisHome, /**< Pointer to function to execute a move to reference or home */ + motorAxisMove, /**< Pointer to function to execute a position move */ + motorAxisVelocityMove, /**< Pointer to function to execute a velocity mode move */ + motorAxisStop, /**< Pointer to function to stop motion */ + motorAxisforceCallback, /**< Pointer to function to request a poller status update */ + motorAxisProfileMove, /**< Pointer to function to execute a profile move */ + motorAxisTriggerProfile /**< Pointer to function to trigger a profile move */ +}; + +extern "C" +{ + epicsExportAddress(drvet, motorA3200); +} + +typedef struct +{ + epicsMutexId controllerLock; + asynUser *pasynUser; + int numAxes; + double movingPollPeriod; + double idlePollPeriod; + epicsEventId pollEventId; + epicsMutexId sendReceiveMutex; + AXIS_HDL pAxis; /* array of axes */ + epicsUInt32 taskNumber; /* the task number to use for motion commands */ +} A3200Controller; + +typedef struct motorAxisHandle +{ + A3200Controller *pController; + PARAMS params; + double currentCmdPos; + double stepSize; + double homePreset; + int homeDirection; + int closedLoop; + int axisStatus; + int card; + int axis; + char axisName[128]; + int maxDigits; + motorAxisLogFunc print; + void *logParam; + epicsMutexId mutexId; + Switch_Level swconfig; + int lastFault; + bool reverseDirec; +} motorAxis; + +typedef struct +{ + AXIS_HDL pFirst; + epicsThreadId motorThread; + motorAxisLogFunc print; + void *logParam; + epicsTimeStamp now; +} motorA3200_t; + +extern "C" { static int motorA3200LogMsg(void *, const motorAxisLogMask_t, const char *, ...); } +static asynStatus sendAndReceive(A3200Controller *, const char *, char *, size_t); + +static motorA3200_t drv = { NULL, NULL, motorA3200LogMsg, 0, { 0, 0 } }; +static int numA3200Controllers; +/* Pointer to array of controller structures */ +static A3200Controller *pA3200Controller = NULL; + +#define MAX(a, b) ((a)>(b) ? (a) : (b)) +#define MIN(a, b) ((a)<(b) ? (a) : (b)) + +static void motorAxisReportAxis(AXIS_HDL pAxis, int level) +{ + if (level > 0) + { + printf("Axis %s\n", pAxis->axisName); + printf(" axisStatus: 0x%x\n", pAxis->axisStatus); + printf(" home preset: %f\n", pAxis->homePreset); + printf(" step size: %f\n", pAxis->stepSize); + printf(" max digits: %d\n", pAxis->maxDigits); + } +} + +static void motorAxisReport(int level) +{ + int i, j; + + for (i = 0; i < numA3200Controllers; i++) + { + if (level) + { + printf(" moving poll period: %f\n", pA3200Controller[i].movingPollPeriod); + printf(" idle poll period: %f\n", pA3200Controller[i].idlePollPeriod); + } + for (j = 0; j < pA3200Controller[i].numAxes; j++) + { + motorAxisReportAxis(&pA3200Controller[i].pAxis[j], level); + } + } +} + + +static int motorAxisInit(void) +{ + int controller, axis; + + for (controller = 0; controller < numA3200Controllers; controller++) + { + AXIS_HDL pAxis; + for (axis = 0; axis < pA3200Controller[controller].numAxes; axis++) + { + pAxis = &pA3200Controller[controller].pAxis[axis]; + if (!pAxis->mutexId) + break; + epicsMutexLock(pAxis->mutexId); + + /*Set GAIN_SUPPORT on so that at least, CNEN functions. */ + motorParam->setInteger(pAxis->params, motorAxisHasClosedLoop, 1); + + motorParam->callCallback(pAxis->params); + epicsMutexUnlock(pAxis->mutexId); + } + } + return MOTOR_AXIS_OK; +} + +static int motorAxisSetLog(AXIS_HDL pAxis, motorAxisLogFunc logFunc, void * param) +{ + if (pAxis == NULL) + { + if (logFunc == NULL) + { + drv.print= motorA3200LogMsg; + drv.logParam = NULL; + } + else + { + drv.print = logFunc; + drv.logParam = param; + } + } + else + { + if (logFunc == NULL) + { + pAxis->print = motorA3200LogMsg; + pAxis->logParam = NULL; + } + else + { + pAxis->print = logFunc; + pAxis->logParam = param; + } + } + return MOTOR_AXIS_OK; +} + +static AXIS_HDL motorAxisOpen(int card, int axis, char * param) +{ + AXIS_HDL pAxis; + + if (card >= numA3200Controllers) + return NULL; + if (axis >= pA3200Controller[card].numAxes) + return NULL; + + pAxis = &pA3200Controller[card].pAxis[axis]; + return pAxis; +} + +static int motorAxisClose(AXIS_HDL pAxis) +{ + return MOTOR_AXIS_OK; +} + +static int motorAxisGetInteger(AXIS_HDL pAxis, motorAxisParam_t function, int * value) +{ + if (pAxis == NULL || pAxis->params == NULL) + return MOTOR_AXIS_ERROR; + else + return motorParam->getInteger(pAxis->params, (paramIndex) function, value); +} + +static int motorAxisGetDouble(AXIS_HDL pAxis, motorAxisParam_t function, double * value) +{ + if (pAxis == NULL || pAxis->params == NULL) + return MOTOR_AXIS_ERROR; + else + return motorParam->getDouble(pAxis->params, (paramIndex) function, value); +} + +static int motorAxisSetCallback(AXIS_HDL pAxis, motorAxisCallbackFunc callback, void * param) +{ + if (pAxis == NULL || pAxis->params == NULL) + return MOTOR_AXIS_ERROR; + else + return motorParam->setCallback(pAxis->params, callback, param); +} + +static int motorAxisSetDouble(AXIS_HDL pAxis, motorAxisParam_t function, double value) +{ + asynStatus status = asynSuccess; + char inputBuff[BUFFER_SIZE], outputBuff[BUFFER_SIZE]; + + if (pAxis == NULL || pAxis->pController == NULL) + return asynError; + + epicsMutexLock(pAxis->mutexId); + + switch (function) + { + case motorAxisPosition: + { + double offset = value * fabs(pAxis->stepSize); + sprintf(outputBuff, "POSOFFSET SET %s %.*f", pAxis->axisName, pAxis->maxDigits, offset); + status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + if (inputBuff[0] != ASCII_ACK_CHAR) + status = asynError; + break; + } + case motorAxisEncoderRatio: + { + PRINT(pAxis->logParam, TERROR, "motorAxisSetDouble: A3200 does not support setting encoder ratio\n"); + break; + } + case motorAxisResolution: + { + /* we need to scale over a dozen other parameters if this changed in some cases, so the user should just use + * the Configuration Manager to change this setting to ensure that this is done correctly */ + PRINT(pAxis->logParam, TERROR, "motorAxisSetDouble: A3200 does not support setting motor resolution\n"); + break; + } + case motorAxisLowLimit: + { + PRINT(pAxis->logParam, TERROR, "motorAxisSetDouble: Driver does not set A3200's Low Limit\n"); + break; + } + case motorAxisHighLimit: + { + PRINT(pAxis->logParam, TERROR, "motorAxisSetDouble: Driver does not set A3200's High Limit\n"); + break; + } + case motorAxisPGain: + { + PRINT(pAxis->logParam, TERROR, "motorAxisSetDouble: A3200 does not support setting proportional gain\n"); + break; + } + case motorAxisIGain: + { + PRINT(pAxis->logParam, TERROR, "motorAxisSetDouble: A3200 does not support setting integral gain\n"); + break; + } + case motorAxisDGain: + { + PRINT(pAxis->logParam, TERROR, "motorAxisSetDouble: A3200 does not support setting derivative gain\n"); + break; + } + default: + PRINT(pAxis->logParam, TERROR, "motorAxisSetDouble: unknown function %d\n", function); + break; + } + if (status == asynSuccess) + { + motorParam->setDouble(pAxis->params, function, value); + motorParam->callCallback(pAxis->params); + } + epicsMutexUnlock(pAxis->mutexId); + + return status; +} + +static int motorAxisSetInteger(AXIS_HDL pAxis, motorAxisParam_t function, int value) +{ + int ret_status = MOTOR_AXIS_ERROR; + char inputBuff[BUFFER_SIZE], outputBuff[BUFFER_SIZE]; + + if (pAxis == NULL || pAxis->pController == NULL) + return MOTOR_AXIS_ERROR; + + epicsMutexLock(pAxis->mutexId); + + switch (function) + { + case motorAxisClosedLoop: + if (value == 0) + sprintf(outputBuff, "DISABLE %s", pAxis->axisName); + else + { + if(pAxis->lastFault) + { + sprintf(outputBuff, "FAULTACK %s", pAxis->axisName); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + } + sprintf(outputBuff, "ENABLE %s", pAxis->axisName); + } + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + break; + default: + PRINT(pAxis->logParam, TERROR, "motorAxisSetInteger: unknown function %d\n", function); + break; + } + if (ret_status != MOTOR_AXIS_ERROR) + { + motorParam->setInteger(pAxis->params, function, value); + motorParam->callCallback(pAxis->params); + } + epicsMutexUnlock(pAxis->mutexId); + return ret_status; +} + + +static int motorAxisMove(AXIS_HDL pAxis, double position, int relative, + double min_velocity, double max_velocity, double acceleration) +{ + int ret_status; + char inputBuff[BUFFER_SIZE], outputBuff[BUFFER_SIZE]; + const char *moveCommand; + bool posdir; + + if (pAxis == NULL || pAxis->pController == NULL) + return MOTOR_AXIS_ERROR; + + PRINT(pAxis->logParam, FLOW, "Set card %d, axis %s move to %f, min vel=%f, max_vel=%f, accel=%f\n", + pAxis->card, pAxis->axisName, position, min_velocity, max_velocity, acceleration); + + if (relative) + { + posdir = position >= 0.0; + moveCommand = "INCREMENTAL"; + } + else + { + posdir = position >= pAxis->currentCmdPos; + moveCommand = "ABSOLUTE"; + } + + ret_status = sendAndReceive(pAxis->pController, moveCommand, inputBuff, sizeof(inputBuff)); + if (ret_status) + return MOTOR_AXIS_ERROR; + + if (acceleration > 0) + { /* only use the acceleration if > 0 */ + sprintf(outputBuff, "RAMP RATE %.*f", pAxis->maxDigits, acceleration * fabs(pAxis->stepSize)); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + } + + sprintf(outputBuff, "LINEAR %s %.*f F%.*f", pAxis->axisName, pAxis->maxDigits, position * fabs(pAxis->stepSize), + pAxis->maxDigits, max_velocity * fabs(pAxis->stepSize)); + + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + if (ret_status) + return MOTOR_AXIS_ERROR; + + if (epicsMutexLock(pAxis->mutexId) == epicsMutexLockOK) + { + motorParam->setInteger(pAxis->params, motorAxisDirection, (int) posdir); + /* Ensure that the motor record's next status update sees motorAxisDone = False. */ + motorParam->setInteger(pAxis->params, motorAxisDone, 0); + motorParam->callCallback(pAxis->params); + epicsMutexUnlock(pAxis->mutexId); + } + + /* Send a signal to the poller task which will make it do a poll, and switch to the moving poll rate */ + epicsEventSignal(pAxis->pController->pollEventId); + + return MOTOR_AXIS_OK; +} + +static int motorAxisHome(AXIS_HDL pAxis, double min_velocity, double max_velocity, double acceleration, int forwards) +{ + int ret_status; + char inputBuff[BUFFER_SIZE], outputBuff[BUFFER_SIZE]; + epicsUInt32 hparam; + int axis; + + if (pAxis == NULL || pAxis->pController == NULL) + return MOTOR_AXIS_ERROR; + + axis = pAxis->axis; + + PRINT(pAxis->logParam, FLOW, "motorAxisHome: set card %d, axis %d to home, forwards = %d\n", + pAxis->card, axis, forwards); + + if (max_velocity > 0) + { + sprintf(outputBuff, "HomeSpeed.%s = %.*f", pAxis->axisName, pAxis->maxDigits, + max_velocity * fabs(pAxis->stepSize)); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + } + + if (acceleration > 0) + { + sprintf(outputBuff, "HomeRampRate.%s = %.*f", pAxis->axisName, pAxis->maxDigits, + acceleration * fabs(pAxis->stepSize)); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + } + hparam = pAxis->homeDirection; + hparam = forwards ? 0x00000001 : 0x0; + pAxis->homeDirection = hparam; + + sprintf(outputBuff, "HomeSetup.%s = %d", pAxis->axisName, hparam); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + + sprintf(outputBuff, "HOME %s", pAxis->axisName); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + + if (ret_status) + return(MOTOR_AXIS_ERROR); + if (epicsMutexLock(pAxis->mutexId) == epicsMutexLockOK) + { + motorParam->setInteger(pAxis->params, motorAxisDirection, forwards); + /* Ensure that the motor record's next status update sees motorAxisDone = False. */ + motorParam->setInteger(pAxis->params, motorAxisDone, 0); + motorParam->callCallback(pAxis->params); + epicsMutexUnlock(pAxis->mutexId); + } + + /* Send a signal to the poller task which will make it do a poll, and switch to the moving poll rate */ + epicsEventSignal(pAxis->pController->pollEventId); + + return MOTOR_AXIS_OK; +} + + +static int motorAxisVelocityMove(AXIS_HDL pAxis, double min_velocity, double velocity, double acceleration) +{ + char inputBuff[BUFFER_SIZE], outputBuff[BUFFER_SIZE]; + int ret_status; + + if (pAxis == NULL || pAxis->pController == NULL) + return MOTOR_AXIS_ERROR; + + sprintf(outputBuff, "AbortDecelRate.%s = %.*f", pAxis->axisName, pAxis->maxDigits, acceleration * fabs(pAxis->stepSize)); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + sprintf(outputBuff, "RAMP RATE %s %.*f", pAxis->axisName, pAxis->maxDigits, acceleration * fabs(pAxis->stepSize)); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + sprintf(outputBuff, "FREERUN %s %.*f", pAxis->axisName, pAxis->maxDigits, velocity * fabs(pAxis->stepSize)); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + + if (epicsMutexLock(pAxis->mutexId) == epicsMutexLockOK) + { + motorParam->setInteger(pAxis->params, motorAxisDirection, (velocity > 0.0 ? 1 : 0)); + /* Ensure that the motor record's next status update sees motorAxisDone = False. */ + motorParam->setInteger(pAxis->params, motorAxisDone, 0); + motorParam->callCallback(pAxis->params); + epicsMutexUnlock(pAxis->mutexId); + } + + /* Send a signal to the poller task which will make it do a poll, and switch to the moving poll rate */ + epicsEventSignal(pAxis->pController->pollEventId); + + return ret_status; +} + +static int motorAxisProfileMove(AXIS_HDL pAxis, int npoints, double positions[], double times[], int relative, int trigger) +{ + return MOTOR_AXIS_ERROR; +} + +static int motorAxisTriggerProfile(AXIS_HDL pAxis) +{ + return MOTOR_AXIS_ERROR; +} + +static int motorAxisStop(AXIS_HDL pAxis, double acceleration) +{ + int ret_status; + char inputBuff[BUFFER_SIZE], outputBuff[BUFFER_SIZE]; + + if (pAxis == NULL || pAxis->pController == NULL) + return MOTOR_AXIS_ERROR; + + PRINT(pAxis->logParam, FLOW, "Abort on card %d, axis %d\n", pAxis->card, pAxis->axis); + + /* we can't accurately determine which type of motion is occurring on the controller, + * so don't worry about the acceleration rate, just stop the motion on the axis */ + sprintf(outputBuff, "ABORT %s", pAxis->axisName); + ret_status = sendAndReceive(pAxis->pController, outputBuff, inputBuff, sizeof(inputBuff)); + return ret_status; +} + +static int motorAxisforceCallback(AXIS_HDL pAxis) +{ + if (pAxis == NULL || pAxis->pController == NULL) + return MOTOR_AXIS_ERROR; + + PRINT(pAxis->logParam, FLOW, "motorAxisforceCallback: request card %d, axis %d status update\n", pAxis->card, pAxis->axis); + + /* Force a status update. */ + motorParam->forceCallback(pAxis->params); + + /* Send a signal to the poller task which will make it do a status update */ + epicsEventSignal(pAxis->pController->pollEventId); + return MOTOR_AXIS_OK; +} + +static void A3200Poller(A3200Controller *pController) +{ + /* This is the task that polls the A3200 */ + double timeout; + AXIS_HDL pAxis; + int itera; + bool anyMoving; + char inputBuff[BUFFER_SIZE], outputBuff[BUFFER_SIZE]; + const char* STATUS_FORMAT_STRING = "~STATUS (%s, AxisStatus) (%s, DriveStatus) (%s, AxisFault) (%s, ProgramPositionFeedback) (%s, ProgramPositionCommand) (%s, ProgramVelocityFeedback)"; + int status; + int axis_status, drive_status, axis_fault; + double pfbk, pcmd, vfbk; + bool move_active; + + timeout = pController->idlePollPeriod; + epicsEventSignal(pController->pollEventId); /* Force on poll at startup */ + + while (1) + { + if (timeout != 0.) + status = epicsEventWaitWithTimeout(pController->pollEventId, timeout); + else + status = epicsEventWait(pController->pollEventId); + + anyMoving = false; + + for (itera = 0; itera < pController->numAxes; itera++) + { + PARAMS params; + + pAxis = &pController->pAxis[itera]; + params = pAxis->params; + + if (!pAxis->mutexId) + break; + epicsMutexLock(pAxis->mutexId); + sprintf(outputBuff, STATUS_FORMAT_STRING, + pAxis->axisName, + pAxis->axisName, + pAxis->axisName, + pAxis->axisName, + pAxis->axisName, + pAxis->axisName); + + status = sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + if (status != asynSuccess) + { + motorParam->setInteger(pAxis->params, motorAxisCommError, 1); + epicsMutexUnlock(pAxis->mutexId); + continue; + } + + if(inputBuff[0] != ASCII_ACK_CHAR) + { + motorParam->setInteger(pAxis->params, motorAxisCommError, 1); + epicsMutexUnlock(pAxis->mutexId); + continue; + } + + sscanf(&inputBuff[1], "%d %d %d %lf %lf %lf", &axis_status, &drive_status, &axis_fault, &pfbk, &pcmd, &vfbk); + + motorParam->setInteger(params, motorAxisCommError, 0); + + move_active = drive_status & DRIVESTATUS_MoveActive; + motorParam->setInteger(params, motorAxisDone, !move_active); + if (move_active) + anyMoving = true; + + motorParam->setInteger(pAxis->params, motorAxisPowerOn, (drive_status & DRIVESTATUS_Enabled) != 0); + motorParam->setInteger(pAxis->params, motorAxisHomeSignal, (axis_status & AXISSTATUS_Homed) != 0); + + if (pAxis->reverseDirec == false) + { + motorParam->setInteger(pAxis->params, motorAxisHighHardLimit, !((drive_status & DRIVESTATUS_CwEndOfTravelLimitInput) ^ pAxis->swconfig.Bits.CWEOTSWstate)); + motorParam->setInteger(pAxis->params, motorAxisLowHardLimit, !((drive_status & DRIVESTATUS_CcwEndOfTravelLimitInput) ^ pAxis->swconfig.Bits.CCWEOTSWstate)); + } + else + { + motorParam->setInteger(pAxis->params, motorAxisHighHardLimit, !((drive_status & DRIVESTATUS_CcwEndOfTravelLimitInput) ^ pAxis->swconfig.Bits.CCWEOTSWstate)); + motorParam->setInteger(pAxis->params, motorAxisLowHardLimit, !((drive_status & DRIVESTATUS_CwEndOfTravelLimitInput) ^ pAxis->swconfig.Bits.CWEOTSWstate)); + } + pAxis->axisStatus = axis_status; + + pfbk /= fabs(pAxis->stepSize); + motorParam->setDouble(pAxis->params, motorAxisEncoderPosn, pfbk); + + pcmd /= fabs(pAxis->stepSize); + motorParam->setDouble(pAxis->params, motorAxisPosition, pcmd); + pAxis->currentCmdPos = pcmd; + + PRINT(pAxis->logParam, IODRIVER, "A3200Poller: axis %s axisStatus=%x, position=%f\n", + pAxis->axisName, pAxis->axisStatus, pAxis->currentCmdPos); + + if(axis_fault && axis_fault != pAxis->lastFault) + { + PRINT(pAxis->logParam, TERROR, "A3200Poller: controller fault on axis=%s fault=0x%X\n", pAxis->axisName, axis_fault); + } + + pAxis->lastFault = axis_fault; + + vfbk /= fabs(pAxis->stepSize); + motorParam->setDouble(pAxis->params, motorAxisActualVel, vfbk); + + motorParam->callCallback(pAxis->params); + epicsMutexUnlock(pAxis->mutexId); + } /* Next axis */ + + timeout = anyMoving ? pController->movingPollPeriod : pController->idlePollPeriod; + } /* End while */ +} + +static int motorA3200LogMsg(void * param, const motorAxisLogMask_t mask, const char *pFormat, ...) +{ + va_list pvar; + int nchar; + + va_start(pvar, pFormat); + nchar = vfprintf(stdout, pFormat, pvar); + va_end (pvar); + printf("\n"); + return nchar; +} + +int A3200AsynSetup(int num_controllers) /* number of A3200 controllers in system. */ +{ + + if (num_controllers < 1) + { + printf("A3200AsynSetup, num_controllers must be > 0\n"); + return MOTOR_AXIS_ERROR; + } + numA3200Controllers = num_controllers; + pA3200Controller = (A3200Controller *)calloc(numA3200Controllers, sizeof(A3200Controller)); + if(pA3200Controller == NULL) + { + printf("A3200AsynSetup, could not allocate memory\n"); + return MOTOR_AXIS_ERROR; + } + return MOTOR_AXIS_OK; +} + +int A3200AsynConfig(int card, /* Controller number */ + const char *portName, /* asyn port name of serial or GPIB port */ + int asynAddress, /* asyn subaddress for GPIB */ + int numAxes, /* The number of axes that the driver controls */ + int taskNumber, /* the task number to use for motion commands */ + int movingPollPeriod, /* Time to poll (msec) when an axis is in motion */ + int idlePollPeriod) /* Time to poll (msec) when an axis is idle. 0 for no polling */ + +{ + A3200Controller *pController; + char threadName[20]; + int axis, status, digits, retry = 0; + char inputBuff[BUFFER_SIZE], outputBuff[BUFFER_SIZE]; + const char* GET_PARAM_FORMAT_STRING = "%s.%s"; + + if (numA3200Controllers < 1) + { + printf("A3200AsynConfig: no A3200 controllers allocated, call A3200 first\n"); + return MOTOR_AXIS_ERROR; + } + if ((card < 0) || (card >= numA3200Controllers)) + { + printf("A3200AsynConfig: card must in range 0 to %d\n", numA3200Controllers - 1); + return MOTOR_AXIS_ERROR; + } + + if(numAxes < 1 || numAxes > A3200_MAX_AXES) + { + printf("A3200AsynConfig: numAxes must be in the range of 1 to %u\n", A3200_MAX_AXES); + return MOTOR_AXIS_ERROR; + } + + pController = &pA3200Controller[card]; + + pController->numAxes = numAxes; + pController->taskNumber = taskNumber; + pController->movingPollPeriod = movingPollPeriod / 1000.; + pController->idlePollPeriod = idlePollPeriod / 1000.; + + pController->sendReceiveMutex = epicsMutexMustCreate(); + + status = pasynOctetSyncIO->connect(portName, asynAddress, &pController->pasynUser, NULL); + + if (status != asynSuccess) + { + printf("A3200AsynConfig: cannot connect to asyn port %s\n", portName); + return MOTOR_AXIS_ERROR; + } + + /* Set command End-of-string */ + pasynOctetSyncIO->setInputEos(pController->pasynUser, ASCII_EOS_STR, strlen(ASCII_EOS_STR)); + pasynOctetSyncIO->setOutputEos(pController->pasynUser, ASCII_EOS_STR, strlen(ASCII_EOS_STR)); + + pController->pAxis = (AXIS_HDL) calloc(numAxes, sizeof(motorAxis)); + if(pA3200Controller->pAxis == NULL) + { + printf("A3200AsynConfig, could not allocate memory\n"); + return MOTOR_AXIS_ERROR; + } + + retry = 0; + + do + { + sprintf(outputBuff, "~TASK %u", pController->taskNumber); + status = sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + retry++; + } while(status != asynSuccess && retry < 3); + + if(status != asynSuccess) + return MOTOR_AXIS_ERROR; + + sendAndReceive(pController, "~STOPTASK", inputBuff, sizeof(inputBuff)); // reset the task + + /* Get axes info */ + for (axis = 0; axis < numAxes; axis++) + { + sprintf(outputBuff, "$strtask0 = GETPARMSTRING %d, PARAMETERID_AxisName", axis); + sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + + sendAndReceive(pController, "~GETVARIABLE $strtask0", inputBuff, sizeof(inputBuff)); + if (inputBuff[0] == ASCII_ACK_CHAR) + { + AXIS_HDL pAxis = &pController->pAxis[axis]; + pAxis->pController = pController; + pAxis->card = card; + pAxis->axis = axis; + pAxis->mutexId = epicsMutexMustCreate(); + pAxis->params = motorParam->create(0, MOTOR_AXIS_NUM_PARAMS); + strncpy(pAxis->axisName, &inputBuff[1], sizeof(pAxis->axisName) - 1); + + sprintf(outputBuff, GET_PARAM_FORMAT_STRING, "PositionFeedbackType", pAxis->axisName); + sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + if (inputBuff[0] == ASCII_ACK_CHAR && atoi(&inputBuff[1]) > 0) + { + pAxis->closedLoop = 1; + motorParam->setInteger(pAxis->params, motorAxisHasEncoder, 1); + } + + sprintf(outputBuff, GET_PARAM_FORMAT_STRING, "CountsPerUnit", pAxis->axisName); + sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + if (inputBuff[0] == ASCII_ACK_CHAR) + pAxis->stepSize = 1 / atof(&inputBuff[1]); + else + pAxis->stepSize = 1; + digits = (int) -log10(fabs(pAxis->stepSize)) + 2; + pAxis->maxDigits = digits < 1 ? 1 : digits; + + sprintf(outputBuff, GET_PARAM_FORMAT_STRING, "HomeOffset", pAxis->axisName); + sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + if (inputBuff[0] == ASCII_ACK_CHAR) + pAxis->homePreset = atof(&inputBuff[1]); + + sprintf(outputBuff, GET_PARAM_FORMAT_STRING, "HomeSetup", pAxis->axisName); + sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + if (inputBuff[0] == ASCII_ACK_CHAR) + pAxis->homeDirection = atoi(&inputBuff[1]) & 0x1; + + sprintf(outputBuff, GET_PARAM_FORMAT_STRING, "EndOfTravelLimitSetup", pAxis->axisName); + sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + if (inputBuff[0] == ASCII_ACK_CHAR) + pAxis->swconfig.All = atoi(&inputBuff[1]); + + /* Set RAMP MODE to RATE. */ + sprintf(outputBuff, "RAMP MODE RATE %s", pAxis->axisName); + sendAndReceive(pController, outputBuff, inputBuff, sizeof(inputBuff)); + + /* Get Reverse Direction indicator. */ + sprintf(outputBuff, GET_PARAM_FORMAT_STRING, "ReverseMotionDirection", pAxis->axisName); + if (inputBuff[0] == ASCII_ACK_CHAR) + pAxis->reverseDirec = (bool) atoi(&inputBuff[1]); + } + } + + sendAndReceive(pController, "~INITQUEUE", inputBuff, sizeof(inputBuff)); + + pController->pollEventId = epicsEventMustCreate(epicsEventEmpty); + + /* Create the poller thread for this controller */ + epicsSnprintf(threadName, sizeof(threadName), "A3200:%d", card); + epicsThreadCreate(threadName, epicsThreadPriorityMedium, epicsThreadGetStackSize(epicsThreadStackMedium), + (EPICSTHREADFUNC) A3200Poller, (void *) pController); + + return MOTOR_AXIS_OK; +} + +static asynStatus sendAndReceive(A3200Controller *pController, const char *outputBuff, char *inputBuff, size_t inputSize) +{ + size_t nWriteRequested; + size_t nWrite, nRead; + int eomReason; + asynStatus status; + AXIS_HDL pAxis; + + if (pController == NULL) + return asynError; + + pAxis = &pController->pAxis[0]; + nWriteRequested = strlen(outputBuff); + + /* sendAndReceive is intended only for "fast" read-write operations (such as getting parameter/status values), + * so we don't expect much latency on read/writes */ + epicsMutexLock(pController->sendReceiveMutex); + + status = pasynOctetSyncIO->writeRead(pController->pasynUser, outputBuff, nWriteRequested, + inputBuff, inputSize, TIMEOUT, &nWrite, &nRead, &eomReason); + + if (nWrite != nWriteRequested) + status = asynError; + else if (status == asynTimeout) + { + int retry = 1; + + while (retry <= 3 && status == asynTimeout) + { + PRINT(pAxis->logParam, TERROR, "%s:sendAndReceive: Retrying read, retry# = %d.\n", DRIVER_NAME, retry); + status = pasynOctetSyncIO->read(pController->pasynUser, inputBuff, inputSize, TIMEOUT, &nRead, &eomReason); + retry++; + } + if (retry > 3) + PRINT(pAxis->logParam, TERROR, + "%s:sendAndReceive: Retries exhausted on response to command = %s.\n", DRIVER_NAME, outputBuff); + else + PRINT(pAxis->logParam, TERROR, + "%s:sendAndReceive: Retry succeeded for command = %s with response = %s\n", DRIVER_NAME, outputBuff, inputBuff); + } + + if (status != asynSuccess) + asynPrint(pController->pasynUser, ASYN_TRACE_ERROR, + "%s:sendAndReceive writeRead error, output=%s status=%d, error=%s\n", DRIVER_NAME, + outputBuff, status, pController->pasynUser->errorMessage); + else + { + /* read until we have an ACK followed by a string (most likely will be the numeric value we're looking for) */ + while (status == asynSuccess && nRead > 1 && inputBuff[0] == ASCII_ACK_CHAR && inputBuff[1] == ASCII_EOS_CHAR) + status = pasynOctetSyncIO->read(pController->pasynUser, inputBuff, inputSize, TIMEOUT, &nRead, &eomReason); + if (status != asynSuccess) + asynPrint(pController->pasynUser, ASYN_TRACE_ERROR, + "%s:sendAndReceive error calling read, status=%d, error=%s\n", DRIVER_NAME, + status, pController->pasynUser->errorMessage); + } + epicsMutexUnlock(pController->sendReceiveMutex); + return status; +} + diff --git a/motorApp/AerotechSrc/drvA3200Asyn.h b/motorApp/AerotechSrc/drvA3200Asyn.h new file mode 100644 index 00000000..53d768d8 --- /dev/null +++ b/motorApp/AerotechSrc/drvA3200Asyn.h @@ -0,0 +1,65 @@ +/* +FILENAME... drvA3200Asyn.h +USAGE... This file contains Aerotech A3200 Asyn driver "include" information. + +Version: $Revision$ +Modified By: $Author$ +Last Modified: $Date$ +HeadURL: $URL$ +*/ + +/* + * Original Author: Corey Bonnell + * Date: 11/15/2013 + * + * Experimental Physics and Industrial Control System (EPICS) + * + * Copyright 1991, the Regents of the University of California, + * and the University of Chicago Board of Governors. + * + * This software was produced under U.S. Government contracts: + * (W-7405-ENG-36) at the Los Alamos National Laboratory, + * and (W-31-109-ENG-38) at Argonne National Laboratory. + * + * Initial development by: + * The Controls and Automation Group (AT-8) + * Ground Test Accelerator + * Accelerator Technology Division + * Los Alamos National Laboratory + * + * Co-developed with + * The Controls and Computing Group + * Accelerator Systems Division + * Advanced Photon Source + * Argonne National Laboratory + * + * Modification Log: + * ----------------- + * .00 11-15-13 cjb initialized from drvEnsembleAsync.h (Aerotech) + */ + +#ifndef DRV_MOTOR_A3200_ASYN_H +#define DRV_MOTOR_A3200_ASYN_H + +#include "motor.h" + +#ifdef __cplusplus +extern "C" { +#endif + + int A3200AsynSetup(int numControllers); /* number of A3200 controllers in system. */ + + int A3200AsynConfig(int card, /* Controller number */ + const char *portName, /* asyn port name of serial or GPIB port */ + int asynAddress, /* asyn subaddress for GPIB */ + int numAxes, /* The number of axes that the driver controls */ + int taskNumber, /* The task number to use for motion commands */ + int movingPollPeriod, /* Time to poll (msec) when an axis is in motion */ + int idlePollPeriod); /* Time to poll (msec) when an axis is idle. 0 for no polling */ + +#ifdef __cplusplus +} +#endif + +#endif +