Write drive data error example, Parameter access c-8 – Yaskawa Profibus-DP Option Card CM061 User Manual
Page 52
Parameter Access C-8
Write Drive Data Error Example
Table C.5 – Write Drive Data Error Example
PROFIBUS-DP Master Command
Initialize Data Structures
Drive Response
Function Code
00h
Function Code
03h
Starting Address MSB
00h
Starting Address MSB
01h
Starting Address LSB
00h
Starting Address LSB
00h
Data Quantity
00h
Data Quantity
02h
Data 1 MSB
00h
Data 1 MSB
00h
Data 1 LSB
00h
Data 1 LSB
00h
Handshaking (1000 0000)
80h
Set the command message handshake byte HS bit to the same state as the
response message handshake HS bit.
Handshaking (0110 0000)
60h
PROFIBUS-DP Master Command
Set PROFIBUS-DP Master Command Message
Drive Response
Function Code
10h
Function Code
03h
Starting Address MSB
10h
Starting Address MSB
00h
Starting Address LSB
00h
Starting Address LSB
37h
Data Quantity
02h
Data Quantity
02h
Data 1 MSB
00h
Data 1 MSB
00h
Data 1 LSB
01h
Data 1 LSB
00h
Handshaking (1000 0000)
80h
Set the Function Code, Starting Address, and Data Quantity. This
example configures the command message to retrieve data from drive
register at address 0037h, Output Power. For detailed information of
drive registers refer to the Technical Manual and the MODBUS
Technical Manual. For the purposes of this example an invalid Starting
Address was used.
Handshaking (1110 0000)
E0h
PROFIBUS-DP Master Command
Toggle the PROFIBUS-DP Master Handshake Bit
Drive Response
Function Code
10h
Function Code
Starting Address MSB
10h
Starting Address MSB
Starting Address LSB
00h
Starting Address LSB
Data Quantity
02h
Data Quantity
Data 1 MSB
00h
Data 1 MSB
Data 1 LSB
01h
Data 1 LSB
Handshaking (0000 0000)
00h
After the data bits have been set, toggle the HS bit, bit 7, of the command
handshake byte to signal the drive that the command message contains a
Parameter Access command. On receipt of the command message, the
HS bit, bit 7, of the response message handshake byte is set to the same
state as the HS bit of the command message handshake byte. As the
response message may contain invalid data, ignore all response message
data.
Handshaking (0000 0000)
00h
PROFIBUS-DP Master Command
Wait for Response
Drive Response
Function Code
10h
Function Code
Starting Address MSB
10h
Starting Address MSB
Starting Address LSB
00h
Starting Address LSB
Data Quantity
02h
Data Quantity
Data 1 MSB
00h
Data 1 MSB
Data 1 LSB
01h
Data 1 LSB
Handshaking (1000 0000)
00h
The PROFIBUS-DP Option formats the command message and transmits
it to the drive, setting bit 5 of the response handshake byte. As the
response message may contain invalid data, ignore all response message
data.
Handshaking (0010 0000)
20h
PROFIBUS-DP Master Command
Wait for Response
Drive Response
Function Code
10h
Function Code
Starting Address MSB
10h
Starting Address MSB
Starting Address LSB
00h
Starting Address LSB
Data Quantity
02h
Data Quantity
Data 1 MSB
00h
Data 1 MSB
Data 1 LSB
01h
Data 1 LSB
Handshaking (0000 0000)
00h
Bit 5 is reset and bit 6 set of the response handshake byte when the
message has been received by the drive and that the drive has begun
processing the message. As the response message may contain invalid
data, ignore all response message data.
Handshaking (0100 0000)
40h
PROFIBUS-DP Master Command
Process Response
Drive Response
Function Code
10h
Function Code
90h
Starting Address MSB
10h
Starting Address MSB
00h
Starting Address LSB
00h
Starting Address LSB
00h
Data Quantity
02h
Data Quantity
02h
Data 1 MSB
00h
Data 1 MSB
00h
Data 1 LSB
01h
Data 1 LSB
22h
Handshaking (0000 0000)
80h
Bits 5 and 6 of the response handshake byte are both set when the
processing has been completed and the response message contains valid
data. The MSB of the function code signifies an error response and Data
1 LSB contains the error code. Refer to Parameter Access Error Message
section of Chapter for error code description.
Handshaking (0110 0000)
60h