10.07.2015 Views

IDRIVE Protocol Specification - Kollmorgen

IDRIVE Protocol Specification - Kollmorgen

IDRIVE Protocol Specification - Kollmorgen

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>IDRIVE</strong> <strong>Protocol</strong> <strong>Specification</strong>Revision 0.5Document Number 1100-xxx29-Sep-97AMERICAN PRECISION INDUSTRIESControls Division45 Hazelwood DriveAmherst, New York 14222-2278Phone: 716-691-9100 s Fax: 716-691-9181


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 2 of 95Packet Description .........................................................................................................................................................5Commands .....................................................................................................................................................................6Soft Reset Command .................................................................................................................................................6Get Variable Register Command ...............................................................................................................................7Set Position Register Command.................................................................................................................................8Get Position Register Command................................................................................................................................8Set Feedback Count Register Command....................................................................................................................9Get Feedback Count Register Command ...................................................................................................................9Set Target Velocity Register Command...................................................................................................................10Get Target Velocity Register Command..................................................................................................................10Set Input Debounce Mask Command.......................................................................................................................11Get Input Debounce Mask Command......................................................................................................................11Set Input Clockwise Limit Mask Command ............................................................................................................12Get Input Clockwise Limit Mask Command............................................................................................................13Set Input Counter-Clockwise Limit Mask Command ..............................................................................................14Get Input Counter-Clockwise Limit Mask Command..............................................................................................15Set Sequence Select Input Mask Command.............................................................................................................16Get Sequence Select Input Mask Command ............................................................................................................17Set Stop Input Mask Command ...............................................................................................................................18Get Stop Input Mask Command...............................................................................................................................19Set Enable Input Mask Command............................................................................................................................20Get Enable Input Mask Command...........................................................................................................................21Set Output State Command......................................................................................................................................22Get Output State Command .....................................................................................................................................23Set Fault Output Mask Command............................................................................................................................24Get Fault Output Mask Command ...........................................................................................................................25Set Moving Output Mask Command........................................................................................................................26Get Moving Output Mask Command.......................................................................................................................27Set Slew Output Mask Command ............................................................................................................................28Get Slew Output Mask Command............................................................................................................................29Set Stall Output Mask Command.............................................................................................................................30Get Stall Output Mask Command ............................................................................................................................31Set Sequence Active Output Mask Command .........................................................................................................32Get Sequence Active Output Mask Command.........................................................................................................33Set Acceleration Register Command .......................................................................................................................34Get Acceleration Register Command.......................................................................................................................34Set Feedback Scale Factor Register Command........................................................................................................35Get Feedback Scale Factor Register Command .......................................................................................................35Set Feedback Maximum Position Error Command..................................................................................................36Get Feedback Maximum Position Error Command .................................................................................................36Set PCB Revision Letter Command.........................................................................................................................37Get PCB Revision Letter Command ........................................................................................................................37Set PCB Revision Number Command .....................................................................................................................38Get PCB Revision Number Command.....................................................................................................................38Set Autostart Sequence Number Command .............................................................................................................39Get Autostart Sequence Number Command ............................................................................................................39Set Stall Sequence Number Command ....................................................................................................................40Get Stall Sequence Number Command....................................................................................................................40Set Hardware Fault Sequence Number Command ...................................................................................................41Get Hardware Fault Sequence Number Command ..................................................................................................41Set Software Fault Sequence Number Command ....................................................................................................42Get Software Fault Sequence Number Command....................................................................................................42Set Debounce Time Command ................................................................................................................................43Get Debounce Time Command................................................................................................................................43Set Running Power Command (DM-224i & DM-225i only)...................................................................................44Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 3 of 95Get Running Power Command (DM-224i & DM-225i only) ..................................................................................45Set Standing Power Command (DM-224i & DM-225i only) ..................................................................................46Get Standing Power Command (DM-224i & DM-225i only)..................................................................................47Set Power Up Delay Command (DM-224i & DM-225i only) .................................................................................48Get Power Up Delay Command (DM-224i & DM-225i only).................................................................................48Set Power Down Delay Command (DM-224i & DM-225i only).............................................................................49Get Power Down Delay Command (DM-224i & DM-225i only)............................................................................49Set Velocity Functions Command (DM-224i & DM-225i only) .............................................................................50Get Velocity Functions Command (DM-224i & DM-225i only).............................................................................51Set Midband Velocity Register Command (DM-224i & DM-225i only).................................................................52Get Midband Velocity Register Command (DM-224i & DM-225i only)................................................................52Set Analog Velocity Register Command (DM-224i only) .......................................................................................53Get Analog Velocity Register Command (DM-224i only) ......................................................................................53Set Deadband Velocity Register Command (DM-224i only)...................................................................................54Get Deadband Velocity Register Command (DM-224i only)..................................................................................54Set Fullstep Velocity Register Command (DM-224i & DM-225i only) ..................................................................55Get Fullstep Velocity Register Command (DM-224i & DM-225i only) .................................................................55Set Feedback Functions Command (DM-224i & DM-225i only)............................................................................56Get Feedback Functions Command (DM-224i & DM-225i only) ...........................................................................57Set Harmonic Command (DM-224i & DM-225i only)............................................................................................58Get Harmonic Command (DM-224i & DM-225i only) ...........................................................................................59Set Current Command (DM-224i only) ...................................................................................................................60Get Current Command (DM-224i only)...................................................................................................................62Get Software Version Command .............................................................................................................................64Get Current Velocity Command ..............................................................................................................................65Get Fault Register Command...................................................................................................................................66Get Input State Command........................................................................................................................................67Get Status Register Command .................................................................................................................................68Get Device Type Register Command.......................................................................................................................69Get Analog Input Register Command ......................................................................................................................70Get Sequence Length Command..............................................................................................................................71Get Sequence Data Command .................................................................................................................................71If Commands............................................................................................................................................................71If with Immediate Commands..................................................................................................................................73While Commands.....................................................................................................................................................74While with Immediate Commands...........................................................................................................................75Arithmetic Commands .............................................................................................................................................76Arithmetic with Immediate Commands....................................................................................................................77Continuous Move Command ...................................................................................................................................78Prepare Continuous Move Command ......................................................................................................................78Relative Move Variable Distance Command...........................................................................................................79Absolute Move Variable Position Command...........................................................................................................79Relative Move Command ........................................................................................................................................80Prepare Relative Move Command ...........................................................................................................................80Absolute Move Command .......................................................................................................................................81Prepare Absolute Move Command ..........................................................................................................................81Start Move Command ..............................................................................................................................................82Stop Move with Deceleration Command .................................................................................................................83Stop Move Immediate Command ............................................................................................................................83Delay Command ......................................................................................................................................................84Wait Motor Stop Command.....................................................................................................................................84Wait For Input(s) Active Command.........................................................................................................................85Input Configuration Command ................................................................................................................................86Output Configuration Command..............................................................................................................................88Execute Sequence Command...................................................................................................................................89Abort Sequence Command ......................................................................................................................................89Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 4 of 95Archive Sequences Command .................................................................................................................................90Delete Sequence Command .....................................................................................................................................90Start Sequence Storage Command ...........................................................................................................................91Start Sequence Storage with Execution Command ..................................................................................................91End Sequence Storage Command ............................................................................................................................92Begin Flash Upgrade Command ..............................................................................................................................92Flash Upgrade Data Command ................................................................................................................................93End Flash Upgrade Command .................................................................................................................................94Status Codes.................................................................................................................................................................95Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 5 of 95Packet DescriptionWhen the Host desires to communicate with an Axis, a packet similar to what is shown below istransmitted.START COMMAND DATA CHECKSUMThe start byte contains the target Axis ID for the packet currently being sent by the host. Axis ID 0xff isthe broadcast ID.7 6 5 4 3 2 1 0Axis NumberThe command byte is a unique opcode for each supported command.7 6 5 4 3 2 1 0OpcodeThe data is variable length and command specific.7 6 5 4 3 2 1 0Data...Data...Data...The sum of the start frame, command frame and data frames, and checksum (truncated to a byte) shouldbe zero hexidecimal (0x00).7 6 5 4 3 2 1 0ChecksumThe Axis will respond with the following packet.STATUS CODE DATA CHECKSUMConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 6 of 95CommandsThis section describes the command packet and responses for each of the commands supported by thisprotocol. All of the commands assume an Axis ID of zero.Soft Reset CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 0Packet ExampleResponse CodesThe Soft Reset Command (warm start) emulates power-up byresetting all variables, reloads and reorganizes all sequences.0x40, , Soft Reset0x00, 0x40, 0xc0NoneNote:This command does not respond with a “response packet”, and it make take as long as onesecond for the command to complete. During this time, the unit will not accept any othercommands.Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 7 of 95Set Variable Register CommandDescriptionOpcodeFormatRelated FunctionsThe Set Variable Register Command allows the interface set anyof the variable register. All registers are assumed as signed 32-bitregisters.The first 256 variables are reserved for use by the Generalinterface module (device independent variables). Of these, thefirst 128 (variable numbers 0x00-0x7f) are generic, and can beused for any purpose.The rest of the range is for device dependent variables (0x0100-0xffff).0x11, , , , Range -2147483648, 2147483648Command Length 9Response Length 2Get Get Variable Register CommandDescriptionOpcodeFormatRelated FunctionsThe Get Variable Register Command allows the interface read anyof the variable register. All registers are assumed as signed 32-bitregisters.The first 256 variables are reserved for use by the Generalinterface module (device independent variables). Of these, thefirst 128 (variable numbers 0x00-0x7f) are generic, and can beused for any purpose.The rest of the range is for device dependent variables (0x0100-0xffff).The Get Variable Register Command uses the same variables asthe Set, plus several read only variables.0x10, , , Range -2147483648, 2147483648Command Length 5Response Length 6Set Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 8 of 95Set Position Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Position Register indicates the current position. This registeris a signed 32-bit register, with units of position counts. Thiscommand is typically used to initialize the position register to zero,after system homing is complete.0x110x0080, , , , Range -2147483648, 2147483648Command Length 9Response Length 2Packet ExampleResponse CodesGet Position, Absolute Move, Relative MoveSet Position Register = 0x12345678 (305419896 decimal)0x00, 0x11, 0x00, 0x80, 0x12, 0x34, 0x56, 0x78, 0x5b0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Position Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Position Register indicates the current position. This registeris a signed 32-bit register, with units of position counts. Thiscommand is typically used to initialize the position register to zero,after system homing is complete.0x100x0080, , , Range -2147483648, 2147483648Command Length 5Response Length 6Response ExampleResponse CodesSet Position, Absolute Move, Relative MoveResponse Code = Good, Position Register = 0x123456780x06, 0x12, 0x34, 0x56, 0x78, 0xe60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 9 of 95Set Feedback Count Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Feedback Count Register indicates the current value in thefeedback register. This register is a signed 32-bit register, withunits of feedback counts. This command is typically used toinitialize the feedback count register to zero.0x110x0081, , , , Range -2147483648, 2147483648Command Length 9Response Length 2Packet ExampleResponse CodesGet Feedback Count, Get/Set Feedback Scale Factor, Get/SetFeedback Maximum Position ErrorSet Feedback Register = 0x12345678 (305419896 decimal)0x00, 0x11, 0x00, 0x81, 0x12, 0x34, 0x56, 0x78, 0x5a0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Feedback Count Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Feedback Count Register indicates the current value in thefeedback register. This register is a signed 32-bit register, withunits of feedback counts. This command is typically used toinitialize the feedback count register to zero.0x100x0081, , , Range -2147483648, 2147483648Command Length 5Response Length 6Response ExampleResponse CodesSet Feedback Count, Get/Set Feedback Scale Factor, Get/SetFeedback Maximum Position ErrorResponse Code = Good, Feedback Register = 0x123456780x06, 0x12, 0x34, 0x56, 0x78, 0xe60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 10 of 95Set Target Velocity Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Target Velocity Register is used to set the maximum (orminimum in the CCW direction) velocity the drive will turn the motorat. This register is a signed 32-bit register, with units of positioncounts/.0001 sec.0x110x0082, , , , Range -2147483648, 2147483648Command Length 9Response Length 2Packet ExampleResponse CodesGet Target Velocity Register, Get Current Velocity, Get/SetAcceleration Register, Absolute Move, Relative Move,Continuous MoveSet Target Velocity Register = 0x12345678 (305419896 decimal)0x00, 0x11, 0x00, 0x82, 0x12, 0x34, 0x56, 0x78, 0x590x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Target Velocity Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Target Velocity Register is used to set the maximum (orminimum in the CCW direction) velocity the drive will turn the motorat. This register is a signed 32-bit register, with units of positioncounts/.0001 sec.0x100x0082, , , Range -2147483648, 2147483648Command Length 5Response Length 6Response ExampleResponse CodesGet Target Velocity Register, Get Current Velocity, Get/SetAcceleration Register, Absolute Move, Relative Move,Continuous MoveResponse Code = Good, Velocity Register = 0x123456780x06, 0x12, 0x34, 0x56, 0x78, 0xe60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 11 of 95Set Input Debounce Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2Packet ExampleResponse CodesThe Input Debounce Mask indicates which input(s) are debounced.A “1” in the input’s bit position indicates that this input will bedebounced, while a “0” indicates that it is not debounced.0x110x00c1, , , , 0x000000000, 0x0000ffffGet Debounce Mask, Get/Set Debounce Time, Configure InputsSet Debounce Mask = Inputs 1,3,4,5,8,15,16 debounced0x00, 0x11, 0x00, 0xc1, 0x00, 0x00, 0xc1, 0xd1, 0x5d0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Get Input Debounce Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6Response ExampleResponse CodesThe Input Debounce Mask indicates which input(s) are debounced.A “1” in the input’s bit position indicates that this input will bedebounced, while a “0” indicates that it is not debounced.0x100x00c1, , , 0x000000000, 0x0000ffffSet Debounce Mask, Get/Set Debounce Time, Configure InputsResponse Code = Good, Velocity Register = 0x12340x06, 0x00, 0x00, 0x12, 0x34, 0xb40x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 12 of 95Set Input Clockwise Limit Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2The Input Clockwise Limit Mask indicates which input is used as theCW limit. A “1” in the input’s bit position indicates that this input willbe used as the CW limit, while a “0” indicates that it is not. Whenthe CW Limit input becomes “active” during motion in the CWdirection, motion will cease. Motion in the CW direction will not beallowed while this input is active (but motion in the CCW direction isnot prohibited by this input).0x110x00c2, , , , Get Input Clockwise Limit Mask, Get/Set Input Counter-Clockwise Limit Mask, Configure InputsPacket Example Set Input Clockwise Limit Mask = Input 15Response Codes0x00, 0x11, 0x00, 0xc2, 0x00, 0x00, 0x40, 0x00, 0xed0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 13 of 95Get Input Clockwise Limit Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Input Clockwise Limit Mask indicates which input is used as theCW limit. A “1” in the input’s bit position indicates that this input willbe used as the CW limit, while a “0” indicates that it is not. Whenthe CW Limit input becomes “active” during motion in the CWdirection, motion will cease. Motion in the CW direction will not beallowed while this input is active (but motion in the CCW direction isnot prohibited by this input).0x100x00c2, , , Set Input Clockwise Limit Mask, Get/Set Input Counter-Clockwise Limit Mask, Configure InputsResponse Example Response Code = Good, CW Input = Input 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 14 of 95Set Input Counter-Clockwise Limit Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2The Input Counter-Clockwise Limit Mask indicates which input isused as the CCW limit. A “1” in the input’s bit position indicates thatthis input will be used as the CCW limit, while a “0” indicates that itis not. When the CCW Limit input becomes “active” during motionin the CCW direction, motion will cease. Motion in the CCWdirection will not be allowed while this input is active (but motion inthe CW direction is not prohibited by this input).0x110x00c3, , , , Get Input Counter-Clockwise Limit Mask, Get/Set InputClockwise Limit Mask, Configure InputsPacket Example Set Input Counter-Clockwise Limit Mask = Input 4Response Codes0x00, 0x11, 0x00, 0xc3, 0x00, 0x00, 0x00, 0x08, 0x240x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 15 of 95Get Input Counter-Clockwise Limit Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Input Counter-Clockwise Limit Mask indicates which input isused as the CCW limit. A “1” in the input’s bit position indicates thatthis input will be used as the CCW limit, while a “0” indicates that itis not. When the CCW Limit input becomes “active” during motionin the CCW direction, motion will cease. Motion in the CCWdirection will not be allowed while this input is active (but motion inthe CW direction is not prohibited by this input).0x100x00c3, , , Set Input Counter-Clockwise Limit Mask, Get/Set InputClockwise Limit Mask, Configure InputsResponse Example Response Code = Good, CCW Input = Input 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 16 of 95Set Sequence Select Input Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2Packet ExampleResponse CodesThe Sequence Select Input Mask indicates which input(s) are usedas the Sequence Select input(s). A “1” in the input’s bit positionindicates that this input will be used as a Sequence Select input,while a “0” indicates that it is not. The Sequence Select maskdetermines which inputs will be used to generate the sequencenumber when the sequence start input becomes active. The inputsmust be contiguous (the drive will automatically dedicate any inputwith a number less than the highest defined Sequence Select inputas a Sequence Select input). The active state of the input isconsidered. Input 1 cannot be used (dedicated as the sequencestart input).0x110x00c4, , , , Get Sequence Select Input Mask, Configure Inputs, StartSequence Storage with Execution, Start Sequence Storage,Delete Sequence, Archive Sequence, Abort Sequence, ExecuteSequenceSet Sequence Select Input Mask = 16 Sequences0x00, 0x11, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x1e, 0x0d0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 XConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 17 of 95Get Sequence Select Input Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Sequence Select Input Mask indicates which input(s) are usedas the Sequence Select input(s). A “1” in the input’s bit positionindicates that this input will be used as a Sequence Select input,while a “0” indicates that it is not. The Sequence Select maskdetermines which inputs will be used to generate the sequencenumber when the sequence start input becomes active. The inputsmust be contiguous. The active state of the input is considered.Input 1 cannot be used (dedicated as the sequence start input).0x100x00c4, , , Set Sequence Select Input Mask, Configure Inputs, StartSequence Storage with Execution, Start Sequence Storage,Delete Sequence, Archive Sequence, Abort Sequence, ExecuteSequenceResponse Example Response Code = Good, Sequence Select Inputs = Input 2,3,4Response Codes0x06, 0x00, 0x00, 0x00, 0x0e, 0xec0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 19 of 95Get Stop Input Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Stop Input Mask indicates which input is used as the Stop input.A “1” in the input’s bit position indicates that this input will be usedas the Stop input, while a “0” indicates that it is not. When the Stopinput becomes “active”, any motion will cease. the current to themotor will reduce to the programmed standing power.0x100x00c5, , , Set Stop Input Mask, Configure InputsResponse Example Response Code = Good, Stop Input = Input 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 20 of 95Set Enable Input Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2The Enable Input Mask indicates which input is used as the Enableinput. A “1” in the input’s bit position indicates that this input will beused as the Enable input, while a “0” indicates that it is not. Whenthe Enable input becomes “active”, any motion will cease. thecurrent to the motor will reduce to zero.0x110x00c6, , , , Get Enable Input Mask, Configure InputsPacket Example Set Enable Input Mask = Input 1Response Codes0x00, 0x11, 0x00, 0xc6, 0x00, 0x00, 0x00, 0x01, 0x280x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 21 of 95Get Enable Input Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Enable Input Mask indicates which input is used as the Enableinput. A “1” in the input’s bit position indicates that this input will beused as the Enable input, while a “0” indicates that it is not. Whenthe Enable input becomes “active”, any motion will cease. thecurrent to the motor will reduce to zero.0x100x00c6, , , Set Enable Input Mask, Configure InputsResponse Example Response Code = Good, Enable Input = Input 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Input X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 22 of 95Set Output State CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2Packet ExampleResponse CodesThe Output State indicates which outputs are on and which are off.A “1” in the output’s bit position indicates that this output will be on,while a “0” indicates that it is off. The mask is used to determinewhich outputs are affected by this command. If the output’scorresponding mask bit is “1”, then the output is set to the statedefined by the transferred bits. If the output’s corresponding maskbit is “0”, then the output is unaffected by this command.0x110x0086, , , , Set Output State = Outputs 1, 2, 4, 9, 12 are ONOutputs 3, 10, 11, 13, 14, 15, 16 are OFFOutputs 5, 6, 7, 8 are UNCHANGED0x00, 0x11, 0x00, 0x86, 0xff, 0x0f, 0x09, 0x0b, 0x470x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16Mask 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 23 of 95Get Output State CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Output State indicates which outputs are on and which are off.A “1” in the output’s bit position indicates that this output will be on,while a “0” indicates that it is off. The mask is used to determinewhich outputs are affected by this command.0x100x0086, , , Configure OutputsResponse Example Response Code = Good, Outputs On - 1, 2, 3, 8, 12, 13, 14, 15Outputs Off - 4, 5, 6, 7, 9, 10, 11, 16Response Codes0x06, 0x00, 0x00, 0x78, 0x87, 0xfb0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 24 of 95Set Fault Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2The Fault Output Mask indicates which output is used as the FaultOutput. A “1” in the output’s bit position indicates that this output willbe used as the Fault output, while a “0” indicates that it is not.When the Fault output is ON, this indicates that a hardware orsoftware fault occurred.0x110x00ca, , , , Get Fault Output Mask, Configure OutputsPacket Example Set Fault Output Mask = Output 16Response Codes0x00, 0x11, 0x00, 0xca, 0x00, 0x00, 0x80, 0x00, 0xa50x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 25 of 95Get Fault Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Fault Output Mask indicates which output is used as the FaultOutput. A “1” in the output’s bit position indicates that this output willbe used as the Fault output, while a “0” indicates that it is not.When the Fault output is ON, this indicates that a hardware orsoftware fault occurred.0x100x00ca, , , Set Fault Output Mask, Configure OutputsResponse Example Response Code = Good, Fault Output Mask = Output 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 26 of 95Set Moving Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2The Moving Output Mask indicates which output is used as theMoving Output. A “1” in the output’s bit position indicates that thisoutput will be used as the Moving output, while a “0” indicates that itis not. When the Moving output is ON, this indicates that the motorvelocity is not zero.0x110x00cb, , , , Get Moving Output Mask, Configure OutputsPacket Example Set Moving Output Mask = Output 11Response Codes0x00, 0x11, 0x00, 0xcb, 0x00, 0x00, 0x04, 0x00, 0x200x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 27 of 95Get Moving Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Moving Output Mask indicates which output is used as theMoving Output. A “1” in the output’s bit position indicates that thisoutput will be used as the Moving output, while a “0” indicates that itis not. When the Moving output is ON, this indicates that the motorvelocity is not zero.0x100x00cb, , , Set Moving Output Mask, Configure OutputsResponse Example Response Code = Good, Moving Output Mask = Output 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 28 of 95Set Slew Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2The Slew Output Mask indicates which output is used as the SlewOutput. A “1” in the output’s bit position indicates that this output willbe used as the Slew output, while a “0” indicates that it is not. Whenthe Slew output is ON, this indicates that the motor is moving at theTarget Velocity (not accelerating or decelerating and not zerovelocity).0x110x00cc, , , , Get Slew Output Mask, Configure OutputsPacket Example Set Slew Output Mask = Output 8Response Codes0x00, 0x11, 0x00, 0xcc, 0x00, 0x00, 0x00, 0x80, 0xa30x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 29 of 95Get Slew Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Slew Output Mask indicates which output is used as the SlewOutput. A “1” in the output’s bit position indicates that this output willbe used as the Slew output, while a “0” indicates that it is not. Whenthe Slew output is ON, this indicates that the motor is moving at theTarget Velocity (not accelerating or decelerating and not zerovelocity).0x100x00cc, , , Set Slew Output Mask, Configure OutputsResponse Example Response Code = Good, Slew Output Mask = Output 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 30 of 95Set Stall Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2The Stall Output Mask indicates which output is used as the StallOutput. A “1” in the output’s bit position indicates that this output willbe used as the Stall output, while a “0” indicates that it is not. Whenthe Stall output is ON, this indicates that the motor has stalled.0x110x00cd, , , , Get Stall Output Mask, Configure OutputsPacket Example Set Stall Output Mask = Output 5Response Codes0x00, 0x11, 0x00, 0xcd, 0x00, 0x00, 0x00, 0x10, 0x120x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 31 of 95Get Stall Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Stall Output Mask indicates which output is used as the StallOutput. A “1” in the output’s bit position indicates that this output willbe used as the Stall output, while a “0” indicates that it is not. Whenthe Stall output is ON, this indicates that the motor has stalled.0x100x00cd, , , Set Stall Output Mask, Configure OutputsResponse Example Response Code = Good, Stall Output Mask = Output 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 32 of 95Set Sequence Active Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2The Sequence Active Output Mask indicates which output is usedas the Sequence Active Output. A “1” in the output’s bit positionindicates that this output will be used as the Sequence Activeoutput, while a “0” indicates that it is not. When the SequenceActive output is ON, this indicates that the drive is executing asequence.0x110x00ce, , , , Get Sequence Active Output Mask, Configure OutputsPacket Example Set Sequence Active Output Mask = Output 4Response Codes0x00, 0x11, 0x00, 0xce, 0x00, 0x00, 0x00, 0x08, 0x190x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 33 of 95Get Sequence Active Output Mask CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Sequence Active Output Mask indicates which output is usedas the Sequence Active Output. A “1” in the output’s bit positionindicates that this output will be used as the Sequence Activeoutput, while a “0” indicates that it is not. When the SequenceActive output is ON, this indicates that the drive is executing asequence.0x100x00ce, , , Set Sequence Active Output Mask, Configure OutputsResponse Example Response Code = Good, Sequence Active Mask = Output 7Response Codes0x06, 0x00, 0x00, 0x00, 0x40, 0xba0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31-16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Output X 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 34 of 95Set Acceleration Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Acceleration Register is used to set the acceleration. Thisregister is an unsigned 16-bit register, with units of positioncounts/.0001 sec 2 .0x110x00d0Range 0, 65535Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Acceleration Register, Get Current Velocity, Get/Set TargetVelocity Register, Absolute Move, Relative Move, ContinuousMoveSet Acceleration Register = 0x1234 (4660 decimal)0x00, 0x11, 0x00, 0xd0, 0x00, 0x00, 0x12, 0x34, 0xd90x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Acceleration Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Acceleration Register is used to set the acceleration. Thisregister is an unsigned 16-bit register, with units of positioncounts/.0001 sec 2 .0x100x00d0Range 0, 65535Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Acceleration Register, Get Current Velocity, Get/Set TargetVelocity Register, Absolute Move, Relative Move, ContinuousMoveResponse Code = Good, Acceleration = 0x12340x06, 0x00, 0x00, 0x12, 0x34, 0xb40x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 35 of 95Set Feedback Scale Factor Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Feedback Scale Factor Register is used to set the feedbackscale factor. This register is an unsigned 16-bit register, with unitsof feedback counts/rev.0x110x00d5Range 0, 65535Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Feedback Scale Factor, Get/Set Feedback Count, Get/SetFeedback Maximum Position ErrorSet Feedback Scale Factor Register = 0x0fa0 (4000 decimal)0x00, 0x11, 0x00, 0xd1, 0x00, 0x00, 0x0f, 0xa0, 0x6f0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Feedback Scale Factor Register CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Feedback Scale Factor Register is used to set the feedbackscale factor. This register is an unsigned 16-bit register, with unitsof feedback counts/rev.0x100x00d5Range 0, 65535Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Feedback Scale Factor, Get/Set Feedback Count, Get/SetFeedback Maximum Position ErrorResponse Code = Good, Feedback Scale Factor = 0x12340x06, 0x00, 0x00, 0x12, 0x34, 0xb40x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 36 of 95Set Feedback Maximum Position Error CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Feedback Maximum Position Error is used to set the feedbackmaximum position error. This register is an unsigned 16-bit register,with units of feedback counts.0x110x00d6Range 0, 65535Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Feedback Maximum Position Error, Get/Set FeedbackCount, Get/Set Feedback Scale Factor ErrorSet Feedback Maximum Position Error = 0x64 (100 decimal)0x00, 0x11, 0x00, 0xd2, 0x00, 0x00, 0x00, 0x64, 0xb90x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Feedback Maximum Position Error CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Feedback Maximum Position Error is used to set the feedbackmaximum position error. This register is an unsigned 16-bit register,with units of feedback counts.0x100x00d6Range 0, 65535Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Feedback Maximum Position Error, Get/Set FeedbackCount, Get/Set Feedback Scale Factor ErrorResponse Code = Good, Feedback Max Position Error = 0x12340x06, 0x00, 0x00, 0x12, 0x34, 0xb40x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 37 of 95Set PCB Revision Letter CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2Packet ExampleResponse CodesThe PCB Revision Letter indicates the major revision level of thePCB. This register is an unsigned 8-bit register.Warning: This command should be used by API productionpersonnel only!0x110x00e2, , , , ‘A’ - ‘Z’Get PCB Revision Letter, Get/Set PCB Revision NumberSet PCB Revision Letter = ‘c’ (0x63, or 99 decimal)0x00, 0x11, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x63, 0xaa0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet PCB Revision Letter CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6Response ExampleResponse CodesThe PCB Revision Letter indicates the major revision level of thePCB. This register is an unsigned 8-bit register.0x100x00e2, , , ‘A’ - ‘Z’Set PCB Revision Letter, Get/Set PCB Revision NumberResponse Code = Good, PCB Revision Letter = “b” (0x62)0x06, 0x00, 0x00, 0x00, 0x62, 0x980x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 38 of 95Set PCB Revision Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe PCB Revision Number indicates the minor revision level of thePCB. This register is an unsigned 8-bit register.Warning: This command should be used by API productionpersonnel only!0x110x00e3Range ‘0’ - ‘9’Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Set PCB Revision Number, Get/Set PCB Revision LetterSet PCB Revision Number = ‘4’ (0x34, or 52 decimal)0x00, 0x11, 0x00, 0xe3, 0x00, 0x00, 0x00, 0x34, 0xd80x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet PCB Revision Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe PCB Revision Number indicates the minor revision level of thePCB. This register is an unsigned 8-bit register.0x100x00e3Range ‘0’ - ‘9’Command Length 5Response Length 6Response ExampleResponse Codes, , , Get PCB Revision Number, Get/Set PCB Revision LetterResponse Code = Good, PCB Revision Number = “6” (0x36)0x06, 0x00, 0x00, 0x00, 0x36, 0xc40x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 39 of 95Set Autostart Sequence Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Autostart Sequence Number indicates the sequence to beexecuted at power up or after a soft reset (255 indicates nosequence). This register is an unsigned 8-bit register.0x110x00e4Range 0,255Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Autostart Sequence Number, Get/Set Hardware FaultSequence Number, Get/Set Software Fault Sequence Number,Get/Set Stall Sequence Number,Set Autostart Sequence Number = 0xff (255 decimal)0x00, 0x11, 0x00, 0xe4, 0x00, 0x00, 0x00, 0xff, 0x0c0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Autostart Sequence Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Autostart Sequence Number indicates the sequence to beexecuted at power up or after a soft reset (255 indicates nosequence). This register is an unsigned 8-bit register.0x100x00e4Range 0,255Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Autostart Sequence Number, Get/Set Hardware FaultSequence Number, Get/Set Software Fault Sequence Number,Get/Set Stall Sequence Number,Response Code = Good, Autostart Sequence Number = 0x220x06, 0x00, 0x00, 0x00, 0x22, 0xd80x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 40 of 95Set Stall Sequence Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Stall Sequence Number indicates the sequence to be executedwhen a stall occurs (255 indicates no sequence). This register is anunsigned 8-bit register.0x110x00e5Range 0,255Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Stall Sequence Number, Get/Set Hardware Fault SequenceNumber, Get/Set Software Fault Sequence Number, Get/SetAutostart Sequence Number,Set Stall Sequence Number = 0xff (255 decimal)0x00, 0x11, 0x00, 0xe5, 0x00, 0x00, 0x00, 0xff, 0x0b0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Stall Sequence Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Stall Sequence Number indicates the sequence to be executedwhen a stall occurs (255 indicates no sequence). This register is anunsigned 8-bit register.0x100x00e5Range 0,255Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Stall Sequence Number, Get/Set Hardware Fault SequenceNumber, Get/Set Software Fault Sequence Number, Get/SetAutostart Sequence Number,Response Code = Good, Stall Sequence Number = 0x220x06, 0x00, 0x00, 0x00, 0x22, 0xd80x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 41 of 95Set Hardware Fault Sequence Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Hardware Fault Sequence Number indicates the sequence tobe executed when a hardware fault occurs (255 indicates nosequence). This register is an unsigned 8-bit register.0x110x00e6Range 0,255Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Hardware Fault Sequence Number, Get/Set AutostartSequence Number, Get/Set Software Fault Sequence Number,Get/Set Stall Sequence Number,Set Hardware Fault Sequence Number = 0xff (255 decimal)0x00, 0x11, 0x00, 0xe6, 0x00, 0x00, 0x00, 0xff, 0x0a0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Hardware Fault Sequence Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Hardware Fault Sequence Number indicates the sequence tobe executed when a hardware fault occurs (255 indicates nosequence). This register is an unsigned 8-bit register.0x100x00e6Range 0,255Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Hardware Fault Sequence Number, Get/Set AutostartSequence Number, Get/Set Software Fault Sequence Number,Get/Set Stall Sequence Number,Response Code = Good, HW Fault Sequence Number = 0x220x06, 0x00, 0x00, 0x00, 0x22, 0xd80x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 42 of 95Set Software Fault Sequence Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Software Fault Sequence Number indicates the sequence to beexecuted when a software fault occurs (255 indicates no sequence).This register is an unsigned 8-bit register.0x110x00e7Range 0,255Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Software Fault Sequence Number, Get/Set Hardware FaultSequence Number, Get/Set Autostart Sequence Number,Get/Set Stall Sequence Number,Set Software Fault Sequence Number = 0xff (255 decimal)0x00, 0x11, 0x00, 0xe7, 0x00, 0x00, 0x00, 0xff, 0x090x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Software Fault Sequence Number CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Software Fault Sequence Number indicates the sequence to beexecuted when a software fault occurs (255 indicates no sequence).This register is an unsigned 8-bit register.0x100x00e7Range 0,255Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Software Fault Sequence Number, Get/Set Hardware FaultSequence Number, Get/Set Autostart Sequence Number,Get/Set Stall Sequence Number,Response Code = Good, SW Fault Sequence Number = 0x220x06, 0x00, 0x00, 0x00, 0x22, 0xd80x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 43 of 95Set Debounce Time CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Debounce Time indicates the number of milliseconds inputs aredebounced for. This register is an unsigned 8-bit register.0x110x00e8Range 0,255Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Debounce Time, Get/Set Debounce Mask, Configure InputsSet Debounce Time = 40 ms (0x28)0x00, 0x11, 0x00, 0xe8, 0x00, 0x00, 0x00, 0x28, 0xdf0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Debounce Time CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Debounce Time indicates the number of milliseconds inputs aredebounced for. This register is an unsigned 8-bit register.0x100x00e8Range 0,255Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Debounce Time, Get/Set Debounce Mask, Configure InputsResponse Code = Good, Debounce Time = 34 ms (0x22)0x06, 0x00, 0x00, 0x00, 0x22, 0xd80x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 44 of 95Set Running Power Command (DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Running Power indicates the percentage of maximum power(current) that will be applied to the motor while in motion. Thisregister is an unsigned 2-bit register.0x110x0100Range 0, 3Command Length 9Response Length 2, , , , Get Running Power, Get/Set Standing Power, Get/Set Power UpDelay, Get/Set Power Down DelayPacket Example Set Running Power = 100%Response Codes0x00, 0x11, 0x01, 0x00, 0x00, 0x00, 0x00, 0x03, 0xeb0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 1 Bit 0 Power Level0 0 0%0 1 33%1 0 66%1 1 100%Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 45 of 95Get Running Power Command (DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Running Power indicates the percentage of maximum power(current) that will be applied to the motor while in motion. Thisregister is an unsigned 2-bit register.0x100x0100Range 0, 3Command Length 5Response Length 6, , , Set Running Power, Get/Set Standing Power, Get/Set Power UpDelay, Get/Set Power Down DelayResponse Example Response Code = Good, Running Power = 100%Response Codes0x06, 0x00, 0x00, 0x00, 0x03, 0xf70x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 1 Bit 0 Power Level0 0 0%0 1 33%1 0 66%1 1 100%Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 46 of 95Set Standing Power Command (DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Standing Power indicates the percentage of maximum power(current) that will be applied to the motor while not in motion. Thisregister is an unsigned 2-bit register.0x110x0101Range 0, 3Command Length 9Response Length 2, , , , Get Standing Power, Get/Set Running Power, Get/Set Power UpDelay, Get/Set Power Down DelayPacket Example Set Standing Power = 66%Response Codes0x00, 0x11, 0x01, 0x01, 0x00, 0x00, 0x00, 0x02, 0xeb0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 1 Bit 0 Power Level0 0 0%0 1 33%1 0 66%1 1 100%Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 47 of 95Get Standing Power Command (DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Standing Power indicates the percentage of maximum power(current) that will be applied to the motor while not in motion. Thisregister is an unsigned 2-bit register.0x100x0101Range 0, 3Command Length 5Response Length 6, , , Set Standing Power, Get/Set Running Power, Get/Set Power UpDelay, Get/Set Power Down DelayResponse Example Response Code = Good, Standing Power = 33%Response Codes0x06, 0x00, 0x00, 0x00, 0x01, 0xf90x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 1 Bit 0 Power Level0 0 0%0 1 33%1 0 66%1 1 100%Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 48 of 95Set Power Up Delay Command (DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Power Up Delay indicates the time delay between the issuanceof a start of motion command and the first change in motion of themotor. The delay is only valid when the drive is in standing power,and the standing power is less than the running power.. Thisregister is an unsigned 8-bit register.0x110x0102Range 0, 255Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Power Up Delay, Get/Set Running Power, Get/Set StandingPower, Get/Set Power Down DelaySet Power Up Delay = 255 ms0x00, 0x11, 0x01, 0x02, 0x00, 0x00, 0x00, 0xff, 0xed0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Power Up Delay Command (DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Power Up Delay indicates the time delay between the issuanceof a start of motion command and the first change in motion of themotor. The delay is only valid when the drive is in standing power,and the standing power is less than the running power.. Thisregister is an unsigned 8-bit register.0x100x0102Range 0, 255Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Power Up Delay, Get/Set Running Power, Get/Set StandingPower, Get/Set Power Down DelayResponse Code = Good, Power Up Delay = 0x330x06, 0x00, 0x00, 0x00, 0x33, 0xc70x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 49 of 95Set Power Down Delay Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Power Down Delay indicates the time delay between the end ofmotion and the reduction of power (current) to the motor. The delayis only valid when the drive is in running power, and the runningpower is greater than the standing power.. This register is anunsigned 8-bit register.0x110x0103Range 0, 255Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Power Down Delay, Get/Set Running Power, Get/SetStanding Power, Get/Set Power Up DelaySet Power Down Delay = 100 ms0x00, 0x11, 0x01, 0x03, 0x00, 0x00, 0x00, 0x64, 0x870x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Power Down Delay Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Power Down Delay indicates the time delay between the end ofmotion and the reduction of power (current) to the motor. The delayis only valid when the drive is in running power, and the runningpower is greater than the standing power.. This register is anunsigned 8-bit register.0x100x0103Range 0, 255Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Power Down Delay, Get/Set Running Power, Get/SetStanding Power, Get/Set Power Up DelayResponse Code = Good, Power Down Delay = 0x330x06, 0x00, 0x00, 0x00, 0x33, 0xc70x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 50 of 95Set Velocity Functions Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Velocity Functions register is used to enable/disable Midbandcompensation and Fullstepping. Midband compensation allowsacceleration through resonant velocities, and fullstepping offersmore torque at higher velocities. This register is an unsigned 2-bitregister.0x110x0104Range 0, 3Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Velocity Functions, Get/Set Midband Velocity, Get/SetFullstep VelocitySet Velocity Functions = Midband Enabled, Fullstep Disabled,Analog Velocity Disabled0x00, 0x11, 0x01, 0x04, 0x00, 0x00, 0x00, 0x01, 0xe80x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 2 Bit 1 Bit 0 Analog Velocity Fullstep Midband0 0 0 Disabled Disabled Disabled0 0 1 Disabled Disabled Enabled0 1 0 Disabled Enabled Disabled0 1 1 Disabled Enabled Enabled1 0 0 Enabled Disabled Disabled1 0 1 Enabled Disabled Enabled1 1 0 Enabled Enabled Disabled1 1 1 Enabled Enabled EnabledConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 51 of 95Get Velocity Functions Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Velocity Functions register is used to enable/disable Midbandcompensation and Fullstepping. Midband compensation allowsacceleration through resonant velocities, and fullstepping offersmore torque at higher velocities. This register is an unsigned 2-bitregister.0x100x0104Range 0, 3Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Velocity Functions, Get/Set Midband Velocity, Get/SetFullstep VelocityResponse Code = Good, Midband & Fullstep Enabled0x06, 0x00, 0x00, 0x00, 0x03, 0xf70x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 2 Bit 1 Bit 0 Analog Velocity Fullstep Midband0 0 0 Disabled Disabled Disabled0 0 1 Disabled Disabled Enabled0 1 0 Disabled Enabled Disabled0 1 1 Disabled Enabled Enabled1 0 0 Enabled Disabled Disabled1 0 1 Enabled Disabled Enabled1 1 0 Enabled Enabled Disabled1 1 1 Enabled Enabled EnabledConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 52 of 95Set Midband Velocity Register Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Midband Velocity Register is used to set the velocity the drivewill enable Midband Compensation. This register is a signed 32-bitregister, with units of position counts/.0001 sec.0x110x0105, , , , Range -2147483648, 2147483648Command Length 9Response Length 2Packet ExampleResponse CodesGet Midband Velocity, Get/Set Velocity FunctionsSet Midband Velocity Register = 0x123456780x00, 0x11, 0x01, 0x05, 0x12, 0x34, 0x56, 0x78, 0xd50x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Midband Velocity Register Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Midband Velocity Register is used to set the velocity the drivewill enable Midband Compensation. This register is a signed 32-bitregister, with units of position counts/.0001 sec.0x100x0105, , , Range -2147483648, 2147483648Command Length 5Response Length 6Response ExampleResponse CodesSet Midband Velocity, Get/Set Velocity FunctionsResponse Code = Good, Midband Velocity = 0x123456780x06, 0x12, 0x34, 0x56, 0x78, 0xe60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 53 of 95Set Analog Velocity Register Command(DM-224i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Analog Velocity Register is used to set the maximum velocitythe drive will run under analog control. This register is a signed 32-bit register, with units of position counts/.0001 sec.0x110x010a, , , , Range -2147483648, 2147483648Command Length 9Response Length 2Packet ExampleResponse CodesGet Analog Velocity, Get/Set Velocity FunctionsSet Analog Velocity Register = 0x123456780x00, 0x11, 0x01, 0x0a, 0x12, 0x34, 0x56, 0x78, 0xd00x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Analog Velocity Register Command(DM-224i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Analog Velocity Register is used to set the maximum velocitythe drive will run under analog control. This register is a signed 32-bit register, with units of position counts/.0001 sec.0x100x010b, , , Range -2147483648, 2147483648Command Length 5Response Length 6Response ExampleResponse CodesSet Analog Velocity, Get/Set Velocity FunctionsResponse Code = Good, Analog Velocity = 0x123456780x06, 0x12, 0x34, 0x56, 0x78, 0xe60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 54 of 95Set Deadband Velocity Register Command (DM-224i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Deadband Velocity Register is used to set the minimum velocity(+/-) the drive will run under analog control. If this register is set to 1rps, then the drive will not perform motion if the commanded analogvelocity is between -1 rps and +1 rps. This register is a signed 32-bit register, with units of position counts/.0001 sec.0x110x010b, , , , Range -2147483648, 2147483648Command Length 9Response Length 2Packet ExampleResponse CodesGet Deadband Velocity, Get/Set Velocity FunctionsSet Deadband Velocity Register = 0x123456780x00, 0x11, 0x01, 0x0b, 0x12, 0x34, 0x56, 0x78, 0xef0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Deadband Velocity Register Command (DM-224i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Deadband Velocity Register is used to set the minimum velocity(+/-) the drive will run under analog control. If this register is set to 1rps, then the drive will not perform motion if the commanded analogvelocity is between -1 rps and +1 rps. This register is a signed 32-bit register, with units of position counts/.0001 sec.0x100x0105, , , Range -2147483648, 2147483648Command Length 5Response Length 6Response ExampleResponse CodesSet Deadband Velocity, Get/Set Velocity FunctionsResponse Code = Good, Deadband Velocity = 0x123456780x06, 0x12, 0x34, 0x56, 0x78, 0xe60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 55 of 95Set Fullstep Velocity Register Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Fullstep Velocity Register is used to set the velocity the drivewill enable Fullstepping. This register is a signed 32-bit register,with units of position counts/.0001 sec.0x110x0106, , , , Range -2147483648, 2147483648Command Length 9Response Length 2Packet ExampleResponse CodesGet Fullstep Velocity, Get/Set Velocity FunctionsSet Fullstep Velocity Register = 0x123456780x00, 0x11, 0x01, 0x06, 0x12, 0x34, 0x56, 0x78, 0xd40x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Fullstep Velocity Register Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Fullstep Velocity Register is used to set the velocity the drivewill enable Fullstepping. This register is a signed 32-bit register,with units of position counts/.0001 sec.0x100x0106, , , Range -2147483648, 2147483648Command Length 5Response Length 6Response ExampleResponse CodesSet Fullstep Velocity, Get/Set Velocity FunctionsResponse Code = Good, Midband Velocity = 0x123456780x06, 0x12, 0x34, 0x56, 0x78, 0xe60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 56 of 95Set Feedback Functions Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Feedback Functions register is used to enable/disable positionmaintenance, stall detect and z-channel homing. This register is aunsigned 3-bit register.0x110x0107Range 0, 7Command Length 9Response Length 2Packet ExampleResponse Codes, , , , Get Feedback FunctionsSet Feedback Functions = Position Maintenance - EnabledStall Detect - DisabledZ-Channel Homing - Enabled0x00, 0x11, 0x01, 0x07, 0x00, 0x00, 0x00, 0x05, 0xe20x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 2 Bit 1 Bit 0 Z-Channel Stall Pos Maint.0 0 0 Disabled Disabled Disabled0 0 1 Disabled Disabled Enabled0 1 0 Disabled Enabled Disabled0 1 1 Disabled Enabled Enabled1 0 0 Enabled Disabled Disabled1 0 1 Enabled Disabled Enabled1 1 0 Enabled Enabled Disabled1 1 1 Enabled Enabled EnabledConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 57 of 95Get Feedback Functions Command(DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe Feedback Functions register is used to enable/disable positionmaintenance, stall detect and z-channel homing. This register is aunsigned 3-bit register.0x100x0107Range 0, 7Command Length 5Response Length 6Response ExampleResponse Codes, , , Set Feedback FunctionsResponse Code = Good, Position Maintenance - EnabledStall Detect- EnabledZ-Channel Homing - Enabled0x06, 0x00, 0x00, 0x00, 0x07, 0xf30x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 2 Bit 1 Bit 0 Z-Channel Stall Pos Maint.0 0 0 Disabled Disabled Disabled0 0 1 Disabled Disabled Enabled0 1 0 Disabled Enabled Disabled0 1 1 Disabled Enabled Enabled1 0 0 Enabled Disabled Disabled1 0 1 Enabled Disabled Enabled1 1 0 Enabled Enabled Disabled1 1 1 Enabled Enabled EnabledConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 58 of 95Set Harmonic Command (DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe harmonic register is used select the potion of third harmoniccontent is added to the current waveform. This is used forenhancing smoothness and positional accuracy. This register is aunsigned 3-bit register.0x110x0108Range 1, 7Command Length 9Response Length 2, , , , Get Harmonic, Get/Set CurrentPacket Example Set Harmonic = +10%Response Codes0x00, 0x11, 0x01, 0x08, 0x00, 0x00, 0x00, 0x04, 0xe20x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 2 Bit 1 Bit 0 Harmonic0 0 1 0%0 1 0 +5%0 1 1 -5%1 0 0 +10%1 0 1 -10%1 1 0 +20%1 1 1 -20%Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 59 of 95Get Harmonic Command (DM-224i & DM-225i only)DescriptionOpcodeVariable NumberFormatRelated FunctionsThe harmonic register is used select the potion of third harmoniccontent is added to the current waveform. This is used forenhancing smoothness and positional accuracy. This register is aunsigned 3-bit register.0x100x0108Range 1, 7Command Length 5Response Length 6, , , Set Harmonic, Get/Set CurrentResponse Example Response Code = Good, Harmonic = +20%Response Codes0x06, 0x00, 0x00, 0x00, 0x06, 0xf40x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 2 Bit 1 Bit 0 Harmonic0 0 1 0%0 1 0 +5%0 1 1 -5%1 0 0 +10%1 0 1 -10%1 1 0 +20%1 1 1 -20%Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 60 of 95Set Current Command(DM-224i only)DescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 9Response Length 2Packet ExampleResponse CodesThe Current register is used select the maximum current.. Thisregister is a unsigned 5-bit register.0x110x0109, , , , 0, 0x1fGet Current, Get/Set HarmonicSet Current = 3A0x00, 0x11, 0x01, 0x09, 0x00, 0x00, 0x00, 0x1f, 0xc60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 7 Bit 6 Function0 0 Midband 10 1 Midband 21 0 Midband 31 1 Midband 4Bit 5 Function0 Motor Inductance 11 Motor Inductance 2Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 61 of 95Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 Current (A)x x x 0 0 0 0 0 0.09x x x 0 0 0 0 1 0.19x x x 0 0 0 1 0 0.28x x x 0 0 0 1 1 0.38x x x 0 0 1 0 0 0.47x x x 0 0 1 0 1 0.56x x x 0 0 1 1 0 0.66x x x 0 0 1 1 1 0.75x x x 0 1 0 0 0 0.84x x x 0 1 0 0 1 0.94x x x 0 1 0 1 0 1.03x x x 0 1 0 1 1 1.13x x x 0 1 1 0 0 1.22x x x 0 1 1 0 1 1.31x x x 0 1 1 1 0 1.41x x x 0 1 1 1 1 1.51x x x 1 0 0 0 0 1.60x x x 1 0 0 0 1 1.70x x x 1 0 0 1 0 1.79x x x 1 0 0 1 1 1.88x x x 1 0 1 0 0 1.98x x x 1 0 1 0 1 2.07x x x 1 0 1 1 0 2.17x x x 1 0 1 1 1 2.26x x x 1 1 0 0 0 2.35x x x 1 1 0 0 1 2.45x x x 1 1 0 1 0 2.54x x x 1 1 0 1 1 2.64x x x 1 1 1 0 0 2.73x x x 1 1 1 0 1 2.83x x x 1 1 1 1 0 2.92x x x 1 1 1 1 1 3.00Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 62 of 95Get Current Command(DM-224i only)DescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6The Current register is used select the maximum current.. Thisregister is a unsigned 5-bit register.0x100x0109, , , 0, 0x1fSet Current, Get/Set HarmonicResponse Example Response Code = Good, Current = 3.0AResponse Codes0x06, 0x00, 0x00, 0x00, 0xf1, 0x090x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 7 Bit 6 Function0 0 Midband 10 1 Midband 21 0 Midband 31 1 Midband 4Bit 5 Function0 Motor Inductance 11 Motor Inductance 2Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 63 of 95Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 Current (A)0 0 0 0 0 0.090 0 0 0 1 0.190 0 0 1 0 0.280 0 0 1 1 0.380 0 1 0 0 0.470 0 1 0 1 0.560 0 1 1 0 0.660 0 1 1 1 0.750 1 0 0 0 0.840 1 0 0 1 0.940 1 0 1 0 1.030 1 0 1 1 1.130 1 1 0 0 1.220 1 1 0 1 1.310 1 1 1 0 1.410 1 1 1 1 1.511 0 0 0 0 1.601 0 0 0 1 1.701 0 0 1 0 1.791 0 0 1 1 1.881 0 1 0 0 1.981 0 1 0 1 2.071 0 1 1 0 2.171 0 1 1 1 2.261 1 0 0 0 2.351 1 0 0 1 2.451 1 0 1 0 2.541 1 0 1 1 2.641 1 1 0 0 2.731 1 1 0 1 2.831 1 1 1 0 2.921 1 1 1 1 3.00Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 64 of 95Get Software Version CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6Packet ExampleThe Software Version is the current revision of firmware on the drivebeing communicated with.0x100x0083, , , Get/Set PCB Revision Letter, Get/Set PCB Revision NumberGet Software Version0x00, 0x10, 0x00, 0x83, 0x6dResponse Example Good Response - Version = 2.1aResponse Codes0x06, 0x32, 0x2e, 0x31, 0x61, 0x080x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 65 of 95Get Current Velocity CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Current Velocity is the current velocity at the time this commandwas issued (not to be confused with the target velocity). Duringacceleration and deceleration, the current velocity does not equalthe target velocity.0x100x0084, , , Range -2147483648, 2147483648Command Length 5Response Length 6Packet ExampleResponse ExampleResponse CodesGet/Set Target VelocityGet Current Velocity0x00, 0x10, 0x00, 0x84, 0x6cGood Response - Current Velocity = 0x123456780x06, 0x12, 0x34, 0x56, 0x78, 0xe60x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 66 of 95Get Fault Register CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6Packet ExampleResponse ExampleResponse CodesThe Fault Register is used to inquire about the status of drive faults.0x100x0085, , , 0, 0x1f1fGet Fault Register0x00, 0x10, 0x00, 0x85, 0x6bGood Response - No Faults0x06, 0x00, 0x00, 0x00, 0x00, 0xfa0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0Res Res Res Res CW CCW SC BOVBOVSCCCWCW- Bus Over Voltage- Short Circuit- Counter Clockwise Limit- Clockwise LimitConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 67 of 95Get Input State CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6Packet ExampleResponse ExampleResponse CodesThe Input State is the current raw state of the inputs, plus theiractive state.0x100x00c0, , , Configure InputsGet Input State0x00, 0x10, 0x00, 0xc0, 0x30Good Response - 1-8 Active High9-16 Active Low1,3,5,7,9,11,15 - Low2,4,6,8,10,12,14,16 - High0x06, 0x00, 0xff, 0xaa, 0xaa, 0xa70x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16Active St 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Raw Input 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 68 of 95Get Status Register CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6Packet ExampleResponse ExampleResponse CodesThe Status Register is used to inquire about the status of the drive.0x100x00e0, , , 0, 0x3fGet Status Register0x00, 0x10, 0x00, 0xe0, 0x10Good Response - Moving at slew0x06, 0x00, 0x00, 0x00, 0x03, 0xf70x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultBit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0Reserved Reserved Sequence in Disable Input Stop Input In Delay Moving At SlewProgressBit 15 Bit 14 Bit 13 Bit 12 Bit 11 Bit 10 Bit 9 Bit 8Reserved Reserved Reserved Axis ID0 Axis ID1 Axis ID2 Axis ID3 Axis ID4Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 69 of 95Get Device Type Register CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6Packet ExampleResponse ExampleResponse CodesThe Device Type Register is used to report the device type.0x100x00e1, , , 0, 0xffGet Device Type Register0x00, 0x10, 0x00, 0xe1, 0x0fGood Response - Device Type = DM-224i0x06, 0x00, 0x00, 0x00, 0x10, 0xea0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultDevice Type Code0x100x200x300x40DeviceDM-224iDM-225iI-ServoCentennialConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 70 of 95Get Analog Input Register CommandDescriptionOpcodeVariable NumberFormatRangeRelated FunctionsCommand Length 5Response Length 6Packet ExampleResponse ExampleResponse CodesThe Analog Input register is the digital value (after Analog-to-Digitalconversion) of the analog input. This can be used in conditionalstatements, or in arithmetic functions.0x100x00ff, , , 0, 0xffGet Analog Input Register0x00, 0x10, 0x00, 0xe1, 0x0fGood Response - Analog Input = 0x100x06, 0x00, 0x00, 0x00, 0x10, 0xea0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 71 of 95Get Sequence Length CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Get Sequence Length Command returns the length of thespecified sequence.0x100xff”nn” (where nn = sequence number), , , Range 0, 2147483648Command Length 5Response Length 6Packet ExampleResponse ExampleResponse CodesGet SequenceGet Sequence Length, sequence number = 65 (0x41)0x00, 0x10, 0xff, 0x41, 0xb0Good Response - sequence length = 0x12340x06, 0x00, 0x00, 0x12, 0x34, 0xb40x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultGet Sequence Data CommandDescriptionOpcodeVariable NumberFormatRelated FunctionsThe Get Sequence Data Command returns the data of the specifiedsequence.0x100xfe”nn” (where nn = sequence number), , , Range 0, 2147483648Command Length 5Response Length 6Packet ExampleGet SequenceGet Sequence, sequence number = 65 (0x41)0x00, 0x10, 0xfe, 0x41, 0xb1Response Example Good Response - sequence length = 7If CommandsResponse Codes0x06, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0xde0x06 - Good Response0x10 - Illegal Variable Code0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 72 of 95DescriptionOpcodeFormatRangeRelated FunctionsCommand Length 8Response Length 2Packet ExampleResponse Codes“If” commands are used for program flow control. The offset is asigned 16-bit offset used to specify the distance (in bytes) from thecurrent program counter that program execution will jump to (whenthe results of the expression evaluation are logically false). Notethat only the device independent variables can be used in thiscommand (0x00-0xff).0x30, , , , , ,If with Immediate, While, While with ImmediateIf (Position >= User Var. 22) Offset = 0x12340x00, 0x30, 0x80, 0x05, 0x22, 0x12, 0x34, 0xe30x06 - Good Response0x11 - Illegal Operand Code0x1c - Hardware FaultOperator Definition Operator CodeReserved Reserved 0x00== Equal 0x01 Not Equal 0x02> Greater Than 0x03< Less Than 0x04>= Greater Than or Equal To 0x05


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 73 of 95If with Immediate CommandsDescriptionOpcodeFormatRelated Functions“If” commands are used for program flow control. The offset is asigned 16-bit offset used to specify the distance (in bytes) from thecurrent program counter that program execution will jump to (whenthe results of the expression evaluation are logically false). Notethat only the device independent variables can be used in thiscommand (0x00-0xff).0x31, , , , , ,Range -2147483648, 2147483648Command Length 11Response Length 2Packet ExampleResponse CodesIf, While, While with ImmediateIf (Position >= 0x12345678) Offset = 0xabcd0x00, 0x31, 0x80, 0x05, 0x12, 0x34, 0x56, 0x78, 0xab, 0xcd, 0xbe0x06 - Good Response0x11 - Illegal Operand Code0x1c - Hardware FaultOperator Definition Operator CodeReserved Reserved 0x00== Equal 0x01 Not Equal 0x02> Greater Than 0x03< Less Than 0x04>= Greater Than or Equal To 0x05


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 74 of 95While CommandsDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 8Response Length 2Packet ExampleResponse Codes“While” commands are used for program flow control. The offset isa signed 16-bit offset used to specify the distance (in bytes) from thecurrent program counter that program execution will continue at(when the results of the expression evaluation are logically false).Note that only the device independent variables can be used in thiscommand (0x00-0xff).0xb0, , , , , ,While with Immediate, If, If with ImmediateWhile (Position >= User Var. 22) Offset = 0x12340x00, 0xb0, 0x80, 0x05, 0x22, 0x12, 0x34, 0x630x06 - Good Response0x11 - Illegal Operand Code0x1c - Hardware FaultOperator Definition Operator CodeReserved Reserved 0x00== Equal 0x01 Not Equal 0x02> Greater Than 0x03< Less Than 0x04>= Greater Than or Equal To 0x05


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 75 of 95While with Immediate CommandsDescriptionOpcodeFormatRelated Functions“While” commands are used for program flow control. The offset isa signed 16-bit offset used to specify the distance (in bytes) from thecurrent program counter that program execution will continue at(when the results of the expression evaluation are logically false).Note that only the device independent variables can be used in thiscommand (0x00-0xff).0xb1, , , , , ,Range -2147483648, 2147483648Command Length 11Response Length 2Packet ExampleResponse CodesWhile, If, If with ImmediateWhile (Position >= 0x12345678) Offset = 0xabcd0x00, 0xb1, 0x80, 0x05, 0x12, 0x34, 0x56, 0x78, 0xab, 0xcd, 0x3e0x06 - Good Response0x11 - Illegal Operand Code0x1c - Hardware FaultOperator Definition Operator CodeReserved Reserved 0x00== Equal 0x01 Not Equal 0x02> Greater Than 0x03< Less Than 0x04>= Greater Than or Equal To 0x05


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 76 of 95Arithmetic CommandsDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 6Response Length 2Arithmetic command are used to perform math functions onvariables. Note that only the device independent variables can beused in this command (0x00-0xff).0x32, , , , , ,Arithmetic with ImmediatePacket Example Position = Position + User Var. 22Response Codes0x00, 0x32, 0x80, 0x02, 0x22, 0x2a0x06 - Good Response0x11 - Illegal Operand Code0x1c - Hardware FaultOperator Definition Operator CodeReserved Reserved 0x00= Assign 0x01+ Add 0x02- Subtract 0x03* Multiply 0x04/ Divide 0x05// Logical OR 0x06&& Logical AND 0x07MOD Modulo 0x08>> Shift Right 0x09


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 77 of 95Arithmetic with Immediate CommandsDescriptionOpcodeFormatRelated FunctionsArithmetic command are used to perform math functions onvariables. Note that only the device independent variables can beused in this command (0x00-0xff).0x33, , , , , ,Range -2147483648, 2147483648Command Length 9Response Length 2Packet ExampleResponse CodesArithmeticPosition = 0x123456780x00, 0x33, 0x80, 0x01, 0x12, 0x34, 0x56, 0x78, 0x380x06 - Good Response0x11 - Illegal Operand Code0x1c - Hardware FaultOperator Definition Operator CodeReserved Reserved 0x00= Assign 0x01+ Add 0x02- Subtract 0x03* Multiply 0x04/ Divide 0x05// Logical OR 0x06&& Logical AND 0x07MOD Modulo 0x08>> Shift Right 0x09


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 78 of 95Continuous Move CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesContinuous move commands instruct the drive to accelerate (ordecelerate) to the target velocity.0x20, , Get/Set Target Velocity, Get/Set Acceleration, PrepareContinuous Move, Start Move, Stop Move0x00, 0x20, 0xe00x06 - Good Response0x1c - Hardware FaultPrepare Continuous Move CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesPrepare Continuous move command instruct the drive to prepare toaccelerate (or decelerate) to the target velocity. A start moveactually starts the motion. This is used to synchronous the start ofmultiple axis.0x21, , Get/Set Target Velocity, Get/Set Acceleration, ContinuousMove, Start Move, Stop Move0x00, 0x21, 0xdf0x06 - Good Response0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 79 of 95Relative Move Variable Distance CommandDescriptionOpcodeFormatRelated FunctionsThe Relative Move Variable Distance Command instructs the driveto perform a fixed length move of a distance, specified by thevariable, from the current position. The user defined variables(variable numbers 0-127) are allowed.0x29, , , Range -2147483648, 2147483648Command Length 4Response Length 2Get/Set Position, Get/Set Target Velocity, Get/Set Acceleration,Relative MovePacket Example Relative Move Variable Distance, using variable #14Response Codes0x00, 0x29, 0x0e, 0xc90x06 - Good Response0x10 - Illegal Variable Code0x12 - Motor Busy0x1c - Hardware FaultAbsolute Move Variable Position CommandDescriptionOpcodeFormatRelated FunctionsThe Absolute Move Variable Position Command instructs the driveto perform a fixed length move to a position, specified by thevariable. The user defined variables (variable numbers 0-127) areallowed.0x2a, , , Range -2147483648, 2147483648Command Length 4Response Length 2Get/Set Position, Get/Set Target Velocity, Get/Set Acceleration,Absolute MovePacket Example Absolute Move Variable Position, using variable #14Response Codes0x00, 0x2a, 0x0e, 0xc80x06 - Good Response0x10 - Illegal Variable Code0x12 - Motor Busy0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 80 of 95Relative Move CommandDescriptionOpcodeFormatRelated FunctionsThe Relative Move Command instructs the drive to perform a fixedlength move of a specified distance from the current position. Themove distance is a signed 32-bit value.0x22, , , Range -2147483648, 2147483648Command Length 7Response Length 2Packet ExampleResponse CodesGet/Set Position, Get/Set Target Velocity, Get/Set Acceleration,Prepare Relative Move, Start Move, Stop MoveRelative Move with Distance = 0x12345678 (305419896 decimal)0x00, 0x22, 0x12, 0x34, 0x56, 0x78, 0xca0x06 - Good Response0x12 - Motor Busy0x1c - Hardware FaultPrepare Relative Move CommandDescriptionOpcodeFormatRelated FunctionsThe Relative Move Command instructs the drive to prepare toperform a fixed length move of a specified distance from the currentposition. The move distance is a signed 32-bit value. A start moveactually starts the motion. This is used to synchronous the start ofmultiple axis.0x23, , , Range -2147483648, 2147483648Command Length 7Response Length 2Packet ExampleResponse CodesGet/Set Position, Get/Set Target Velocity, Get/Set Acceleration,Relative Move, Start Move, Stop MovePrepare Relative Move with Distance = 0x123456780x00, 0x23, 0x12, 0x34, 0x56, 0x78, 0xc90x06 - Good Response0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 81 of 95Absolute Move CommandDescriptionOpcodeFormatRelated FunctionsThe Relative Move Command instructs the drive to perform a moveto an absolute position The drive must determine the length of themove based on its current position and the requested position.. Theposition is a signed 32-bit value.0x24, , , Range -2147483648, 2147483648Command Length 7Response Length 2Packet ExampleResponse CodesGet/Set Position, Get/Set Target Velocity, Get/Set Acceleration,Prepare Absolute Move, Start Move, Stop MoveAbsolute Move to Position = 0x12345678 (305419896 decimal)0x00, 0x24, 0x12, 0x34, 0x56, 0x78, 0xc80x06 - Good Response0x12 - Motor Busy0x1c - Hardware FaultPrepare Absolute Move CommandDescriptionOpcodeFormatRelated FunctionsThe Relative Move Command instructs the drive to perform a moveto an absolute position The drive must determine the length of themove based on its current position and the requested position.. Theposition is a signed 32-bit value. A start move actually starts themotion. This is used to synchronous the start of multiple axis.0x25, , , Range -2147483648, 2147483648Command Length 7Response Length 2Packet ExampleResponse CodesGet/Set Position, Get/Set Target Velocity, Get/Set Acceleration,Absolute Move, Start Move, Stop MovePrepare Absolute Move to Position = 0x123456780x00, 0x25, 0x12, 0x34, 0x56, 0x78, 0xc70x06 - Good Response0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 82 of 95Start Move CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesThe Start Move command is used to start a previously preparedmove. A response code of “Motor Busy” can be received if the driveis current performing an Absolute Move or a Relative Move, and thiscommand is issued.0x28, , Continuous Move, Prepare Continuous Move, Absolute Move,Prepare Absolute Move, Relative Move, Prepare Relative Move,Stop Move0x00, 0x28, 0xd80x06 - Good Response0x12 - Motor Busy0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 83 of 95Stop Move with Deceleration CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesThe Stop Move with Deceleration command is used to terminatemotion by decelerating to a zero velocity.0x26, , Continuous Move, Prepare Continuous Move, Absolute Move,Prepare Absolute Move, Relative Move, Prepare Relative Move,Start Move0x00, 0x26, 0xda0x06 - Good Response0x1c - Hardware FaultStop Move Immediate CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesThe Stop Move Immediate command is used to terminate motion byimmediately stopping (no deceleration).0x27, , Continuous Move, Prepare Continuous Move, Absolute Move,Prepare Absolute Move, Relative Move, Prepare Relative Move,Start Move0x00, 0x27, 0xd90x06 - Good Response0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 84 of 95Delay CommandDescriptionOpcodeFormatRelated FunctionsThe Delay command instructs the drive to delay for a fixed period oftime. The delay is an unsigned 16-bit value, with units of ms.0x49Range 0, 65535Command Length 5Response Length 2Packet ExampleResponse Codes, , , Wait Motor Stop, Wait on Input(s)Delay 100ms0x00, 0x49, 0x00, 0x64, 0x530x06 - Good Response0x1c - Hardware FaultWait Motor Stop CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesThe Wait Motor Stop Command (used in stand alone mode only) isused to delay software execution of the next command until themotor stops moving.0x64, , Delay, Wait on Input(s)0x00, 0x64, 0x9c0x06 - Good Response0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 85 of 95Wait For Input(s) Active CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 7Response Length 2The Wait For Input(s) Active Command (used in stand alone modeonly) is used to delay software execution of the next command untilthe specified input(s) become active or inactive. The input usagemask indicates which input(s) will be used to determine programflow. The input state mask (1 - use input, 0 - don’t use) is used todetermine whether to wait for the active (1) or inactive (0) state ofthat input.0x65, , , , Delay, Wait Motor Stop, Configure InputsPacket Example Wait On Inputs - Use Inputs - 1, 2, 3, 4, 5, 6, 7, 8Don’t Use - 9, 10, 11, 12, 13, 14, 15, 16Input Active - 1, 2, 7, 8Input Inactive - 3, 4, 5, 6Response Codes0x00, 0x65, 0x00, 0xff, 0x00, 0xc3, 0xd90x06 - Good Response0x1c - Hardware FaultBit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0Mask 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0State 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 86 of 95Input Configuration CommandDescriptionOpcodeFormatRangeRelated FunctionsThe Input Configuration Command configures the state of eachinput to the required definition. The inputs can be defined as specialfunction inputs or standard. The active state (1-high, 0-low) is alsodefined in this command.0x70Command Length 13Response Length 2, , , , Get/Set Clockwise Limit Mask, Get/Set Counter-Clockwise LimitMask, Get/Set Sequence Select Input Mask, Get/Set Stop InputMask, Get/Set Enable Input MaskPacket Example Configure Inputs - Sequence Start Input - 1Sequence Select Inputs - 2, 3, 4Standard Inputs - 5 through 16Active Low Inputs - 1Active High Inputs - 2 through 16Response Codes0x00, 0x70, 0x30, 0x50, 0x50, 0x50, 0x00,0x00, 0x00, 0x00, 0x7f, 0xff, 0x9c0x06 - Good Response0x1c - Hardware FaultOpcodeInput 1 Input 5Input 2 Input 6Input 3 Input 7Input 4 Input 8Input 9 Input 13Input 10 Input 14Input 11 Input 15Input 12 Input 16Active State (15:8)Active State (7:0)Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 87 of 95Code Name Description0 Standard General Purpose Input1 CW_limit Clockwise Limit, when active decelerates to a stop.2 CCW_limit Counterclockwise Limit, when active decelerates to a stop.3 Sequence Start Start sequence (using select inputs). *** Input 1 only ***4 Sequence Start/Stop Start sequence, stop when input inactive. *** Inputs 2-8 only ***5 Sequence Select Input is used as one of the sequence select inputs.6 Stop Immediately stop motion (with no deceleration).7 Enable Enable current to the motor.8-15 Res. Reserved for future use.In order to use the sequence select inputs, these inputs can be grouped together to define thenumber of hardware sequences (up to 128). Shown below are three examples of how the numberof sequences (and the sequence numbers) are defined,example 1 - Defining up to 2 sequences (sequences 1-2)Input 1 Input 2 Input 3 Input 4 Input 5 Input 6 Input 7 Input 8Start Sel x x x x x xexample 2 - Defining up to 16 sequences (sequences 1-15)Input 1 Input 2 Input 3 Input 4 Input 5 Input 6 Input 7 Input 8Start Sel Sel Sel Sel x x xexample 3 - Defining up to 128 sequences (sequences 1-128)Input 1 Input 2 Input 3 Input 4 Input 5 Input 6 Input 7 Input 8Start Sel Sel Sel Sel Sel Sel SelThe active state defines whether the input is active high or active low.Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 88 of 95Output Configuration CommandDescriptionOpcodeFormatRangeRelated FunctionsThe Output Configuration Command configures the state of eachoutput to the required definition. The outputs can be defined asspecial function outputs or standard.0x71Command Length 11Response Length 2, , , Get/Set Fault Output Mask, Get/Set Moving Output Mask,Get/Set Fault Slew Mask, Get/Set Stall Output Mask, Get/SetSequence Active Output Mask,Packet Example Configure Inputs - Fault Output - 1Moving Output - 16Standard Inputs - 2 through 15Response Codes0x00, 0x71, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x7d0x06 - Good Response0x1c - Hardware FaultOpcodeOutput 1 Output 5Output 2 Output 6Output 3 Output 7Output 4 Output 8Output 9 Output 13Output 10 Output 14Output 11 Output 15Output 12 Output 16Code Name Description0 Standard General Purpose Output1 Fault A fault (hardware or software) has occurred.2 Moving The motor is in motion.3 Slew The motor is at programmed velocity.4 Stall The motor has stalled5 Sequence Active A sequence is in execution.6-15 Res. Reserved for future use.Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 89 of 95Execute Sequence CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 4Response Length 2Packet ExampleResponse CodesThe Execute sequence command instructs the drive to execute thespecified sequence. The sequence number is an 8-bit unsignedvalue.0x73, , , 0, 254 (255 reserved)Get/Set Sequence Select Input Mask, Configure Inputs, StartSequence Storage with Execution, Start Sequence Storage,Delete Sequence, Archive Sequence, Abort SequenceExecute Sequence 0x44 (68 decimal)0x00, 0x73, 0x44, 0x490x06 - Good Response0x15 - Sequence Does Not Exist0x19 - Sequence Does Not Exist0x1c - Hardware FaultAbort Sequence CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesThe Abort Sequence command instructs the drive to abort anysequence currently in execution.0x74, , Get/Set Sequence Select Input Mask, Configure Inputs, StartSequence Storage with Execution, Start Sequence Storage,Delete Sequence, Archive Sequence, Execute SequenceAbort Sequence0x00, 0x74, 0x8c0x06 - Good Response0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 90 of 95Archive Sequences CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesThe Archive Sequences command instructs the drive to archive allsequence into non-volatile memory.0x75, , Get/Set Sequence Select Input Mask, Configure Inputs, StartSequence Storage with Execution, Start Sequence Storage, DeleteSequence, Abort Sequence, Execute SequenceArchive Sequence0x00, 0x75, 0x8b0x06 - Good Response0x1b - Non-volatile memory overrun0x1c - Hardware FaultDelete Sequence CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 4Response Length 2Packet ExampleResponse CodesThe Delete sequence command instructs the drive to delete thespecified sequence. The sequence number is an 8-bit unsignedvalue.0x76, , , 0, 254 (255 reserved)Get/Set Sequence Select Input Mask, Configure Inputs, StartSequence Storage with Execution, Start Sequence Storage,Archive Sequence, Abort Sequence, Execute SequenceDelete Sequence 0x44 (68 decimal)0x00, 0x76, 0x44, 0x460x06 - Good Response0x1a - Sequence Does Not Exist0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 91 of 95Start Sequence Storage CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 4Response Length 2Packet ExampleResponse CodesThe Start Sequence Storage command instructs the drive to beginstorage the specified sequence. The sequence number is an 8-bitunsigned value.0x78, , , 0, 254 (255 reserved)Get/Set Sequence Select Input Mask, Configure Inputs, StartSequence Storage with Execution, Delete Sequence, ArchiveSequence, Abort Sequence, Execute SequenceStart Sequence Storage at Sequence 0x44 (68 decimal)0x00, 0x78, 0x44, 0x440x06 - Good Response0x14 - Sequence Already Exists0x16 - Already in Storage Mode0x1c - Hardware FaultStart Sequence Storage with Execution CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 4Response Length 2Packet ExampleResponse CodesThe Start Sequence Storage with Execution command instructs thedrive to begin storage the specified sequence, and execute eachcommand as it is stored. The sequence number is an 8-bitunsigned value.0x79, , , 0, 254 (255 reserved)Get/Set Sequence Select Input Mask, Configure Inputs StartSequence Storage, Delete Sequence, Archive Sequence, AbortSequence, Execute SequenceStart Sequence Storage with Execution at Sequence 0x440x00, 0x79, 0x44, 0x430x06 - Good Response0x14 - Sequence Already Exists0x16 - Already in Storage Mode0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 92 of 95End Sequence Storage CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 4Response Length 2Packet ExampleResponse CodesThe End Sequence Storage command instructs the drive to endstorage the specified sequence. The sequence number is an 8-bitunsigned value.0x77, , , 0, 254 (255 reserved)Get/Set Sequence Select Input Mask, Configure Inputs, StartSequence Storage with Execution, Start Sequence Storage,Delete Sequence, Archive Sequence, Abort Sequence, ExecuteSequenceStart Sequence Storage at Sequence 0x44 (68 decimal)0x00, 0x78, 0x44, 0x440x06 - Good Response0x1c - Hardware FaultBegin Flash Upgrade CommandDescriptionOpcodeFormatRangeRelated FunctionsCommand Length 3Response Length 2Packet ExampleResponse CodesThis command instructs the drive to prepare for firmware upgrade.Warning: This command should be used by authorized personnelonly!0x63, , Flash Upgrade Data, End Flash UpgradeBegin Flash Upgrade0x00, 0x63, 0x9d0x06 - Good Response0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 93 of 95Flash Upgrade Data CommandDescriptionOpcodeFormatRangeRelated FunctionsThis command send the drive to data for firmware upgrade. This must bepreceded by a Begin Flash Upgrade command, and after all of thesecommand are issued, followed with an End Flash Upgrade Command.Warning: This command should be used by authorized personnelonly!0xe3Command Length 4+Response Length 2Packet ExampleResponse Codes, , , , Begin Flash Upgrade, End Flash UpgradeFlash Upgrade Data - 10 data byte (0x01-0x0a)0x00, 0xe3, 0x0a, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08,0x09, 0x0a, 0x9d0x06 - Good Response0x1d - Bad Password (embedded in the upgrade data)0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 94 of 95End Flash Upgrade CommandDescriptionOpcodeFormatRangeRelated FunctionsThis command send the drive to data for firmware upgrade. This must bepreceded by a Begin Flash Upgrade command (minimum), and FlashUpgrade Data Commands.Warning: This command should be used by authorized personnelonly!0xe4Command Length 5+Response Length 2Packet ExampleResponse Codes, , , , , Begin Flash Upgrade, Flash Upgrade DataFlash Upgrade Data - 10 data byte (0x01-0x0a)- Upgrade Checksum = 0x450x00, 0xe4, 0x0a, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08,0x09, 0x0a, 0x45, 0x570x06 - Good Response0x1d - Bad Upgrade Checksum0x1c - Hardware FaultConfidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.


<strong>IDRIVE</strong> Firmware Design <strong>Specification</strong> Page 95 of 95Status CodesThe following status codes are reported in this protocol. Please refer to the individual commands todetermine error codes associated with the specific command.Code0x060x100x110x120x140x15, 0x19,0x1a0x160x1b0x1c0x1d0x1e0x1f0x20DescriptionNo error or warnings.Illegal Variable Number used during Get/Set Variable command.Illegal Operand Code used during Arithmetic, “If” or “While” commands.Motor Busy. A second move command was issued before the current move commandwas complete. This is only when the current move command is an absolute or relativemove (not continuous).Sequence Already Exists. This can occur if a sequence number is already reserved, and aSequence Store command is issued for that sequence number.Sequence Does Not Exists. This can occur when a Delete Sequence or ExecuteSequence command is issued with a sequence number that is not yet defined.Already in Sequence Storage. This can occur when a Sequence Store command is issuedtwice, without an End Sequence Store command issued in between.Out of non-volatile memory. this can only occur during an Archive Sequences command.Hardware Fault. This can occur as a response to any command.Invalid Checksum During Flash Upgrade. This can only occur on the End Flash UpgradeCommand.Invalid Password During Flash Upgrade. This can only occur on the Flash Upgrade DataCommand.Check Status - STOP or DISABLE active.A timeout occurred while writing the serial EEPROM during a non-volatile parameter save,or archiving a sequence.Confidential:This contents of this document are proprietary, and may not be released toanyone outside of American Precision Industries without written permission.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!