DeviceNet to Motor Drives

COMMAND BLOCK

Using I/O data to update and/or monitor motor drive parameters requires very little programming in your DeviceNet Host device – the configuration of the DN-3000 specifies which motor drive parameters are mapped to which words of I/O data. However, you can only access a total of 32 motor drive parameters this way, and those parameters are fixed when the DN-3000 is configured. If your application requires that you access more than 32 motor drive parameters, you must either use multiple DN-3000s, or use a Command Block.

A Command Block allows your DeviceNet Host to issue commands at run-time to read or write any valid parameter of any motor drive connected to Port 2 of the DN-3000. The Command Block reserves the first 3 words of Output data for commands issued by the Host, and the first 3 words of Input data for the results of those commands (along with any returned data). Commands are issued by moving a Motor Drive Address, Parameter Number, any required Parameter Data (for write commands only), and a Command code into the Command Block, as follows:

 

15

14

13

12

11

 

10

9

8

7

6

5

 

4

3

2

1

0

word 1

 

Motor Drive Address (0-255)

 

0

0

0

 

0

 

Command

 

word 2

 

 

 

 

 

 

 

Parameter

Number

 

 

 

 

 

 

 

word 3

 

 

 

 

 

Parameter Data (write command only)

 

 

 

 

 

The DN-3000 looks for changes in the Command Block data to determine when there is a new request to be processed, “throwing out” any invalid commands received. Valid Commands are 1 (read) and 2 (write). To ensure that partial commands are not processed (in systems where it is possible that Output data could be sent by the host before all 4 words of data have been moved into the command block), you should set the Command to 0 (indicating no command), then place the data in words 2-3, and only set the Command to 1 or 2 after all of the other data is in place. After a command has been processed by the DN- 3000, it will “echo” the command in the Command Result Block in the Input data, and set the Result Code and any Returned Parameter Data, as follows:

 

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

word 1

 

Motor Drive Address (0-255)

 

1

Result Code

 

Command

 

word 2

 

 

 

 

 

 

Parameter

Number

 

 

 

 

 

 

word 3

 

 

 

 

Returned Parameter Data (read command only)

 

 

 

 

If a read command (1) was issued, the Returned Parameter Data will contain the parameter data read from the specified Motor Drive. If a write command (2) was issued, the Returned Parameter Data will be the same as for the issued command. The Result Code indicates the result of processing the issued command. Valid Result Codes are as follows:

Result Code

Meaning

0Command was completed successfully.

1DN-3000 could not communicate with indicated motor drive.

2-6

Drive specific error code (see “Application Notes” for motor drive).

7

Command was invalid.

37

Page 43
Image 43
ICP DAS USA 100-700 PLCS, DB25, DN-3000 Word Motor Drive Address Command, Number Word Parameter Data write command only