KM002100G MDW Serial Protocol Up to Version 6 05

download KM002100G MDW Serial Protocol Up to Version 6 05

of 14

Transcript of KM002100G MDW Serial Protocol Up to Version 6 05

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    1/14

    Service Book KM002100G

    Serial protocol for MDW

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    2/14

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    3/14

    1 - G ENGLISH

    1. MODBUS PROTOCOL FOR PIOVAN EQUIPMENT (MDW)

    1.1. Electronic interface

    The electronic interface installed on the Piovan Micro Processor controller is RS485. The serial communication line can link

    up to 31slaves. The wiring between the serial communication line and the Piovan Micro Processor controller is done

    through screw terminals.

    1.2. Network configuration

    MOD-BUS protocol is suitable for a 1-master / 255-slave network. The number of possible slaves can be limited by the elec-

    tronic interface used.

    The Piovan Micro Processor controller works as a slave.

    1.3. Transmission format

    This protocol uses a binary method, composed as follows:

    1 start bit, 8 data bits, 1 parity bit (optional), 1 stop bit.

    The communication speed can be selected from among 1200, 2400, 4800, 9600 and 19200 baud.

    1.4. Communication procedure

    The communication can be started only from the master unit. The slave unit can transmit only after a query from the master.

    The general format of the master / slave transmission is the following:

    The slave recognizes the transmission of a query frame when the time between two characters is greater than 3 T.U.(T.U. = time unit = necessary time to transmit one character).

    1.5. Function code 1 and 2: reading of "n" bit

    These function codes are used by the master unit to request the value of a certain number of bits, that represent the status

    of the slave unit.

    The slave answers the following:

    Range Byte

    Slave address 1

    Function code 1

    Data n

    Error check (crcl6) 2

    Range Byte

    Slave address (1-255) 1

    Function code (01-02) 1

    Bit starting address (high byte) 1

    Bit starting address (low byte) 1

    Number of bits (high byte) 1

    Number of bits (low byte) 1

    Error check (crc16) 2

    Range Byte

    Slave address (1-255) 1

    Function code (01-02) 1

    Byte count 1

    Data n

    Error check (crcl6) 2

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    4/14

    2 - GENGLISH

    The "data" field indicates the bit requested: the bit with lower address is the bit 0 of the first byte, the next is the bit 1 and

    so on.

    The possible bit necessary to complete the last byte must be put at 0.

    1.6. Function code 3 and 4: reading of n word

    These function codes are used by the master unit to read a group of words (16 bit) which contains the value of the variable

    of the slave unit.

    The slave answers the following:

    The "data" field indicates the requested words in the following format: high byte of the first word, low byte of the first word,

    high byte of the second word, and so on.

    For addresses not implemented, the "data" field will show 8000h.

    1.7. Function code 5: bit writing

    By using this command, the master unit can change the status of one bit of the slave unit.

    The slave answers the following:

    "Data" field = 0 to reset the bit

    = FF00h to set the bit

    Range Byte

    Slave address (1-255) 1

    Function code (03-04) 1

    Word starting address (high byte) 1

    Word starting address (low byte) 1

    Number of word (high byte) 1

    Number of word (low byte) 1

    Error check (crc16) 2

    Range Byte

    Slave address (1-255) 1

    Function code (03-04) 1

    Byte count 1

    Data n

    Error check (crc16) 2

    Range Byte

    Slave address (1-255) 1

    Function code (05) 1

    Bit address (high byte) 1

    Bit address (low byte) 1

    Data 2

    Error check (crc16) 2

    Range Byte

    Slave address (1-255) 1

    Function code (05) 1

    Bit address (high byte) 1

    Bit address (10w byte) 1

    Data 2

    Error check (crci6) 2

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    5/14

    3 - G ENGLISH

    1.8. Function code 6: word writing

    By using this command, the master unit can change the status of one word of the slave unit.

    The slave answers the following:

    1.9. Function code 15: writing of "n" bit

    By using this command, the master unit can change the status of one or more bits of the slave unit.

    The slave answers the following:

    Range Byte

    Slave address (1-255) 1

    Function code (06) 1

    Word address (high byte) 1

    Word address (low byte) 1

    Data 2

    Error check (crc16) 2

    Range Byte

    Slave address (1-255) 1

    Function code (06) 1Word address (high byte) 1

    Word address (low byte) 1

    Data 2

    Error check (crc16) 2

    Range Byte

    Slave address (1-255) 1

    Function code (i5) 1

    Bit starting address (high byte) 1

    Bit starting address (low byte) 1

    Number of bits (high byte) 1

    Number of bits (low byte) 1

    Number of data bytes 1

    Data n

    Error check (crc16) 2

    Range Byte

    Slave address (1-255) 1

    Function code (15) 1

    Bit starting address (high byte) 1

    Bit starting address (low byte) 1

    Number of bits (high byte) 1

    Number of bits (low byte) 1

    Error check (crc16) 2

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    6/14

    4 - GENGLISH

    1.10. Function code 16: writing of n word

    By using this command, the master unit can change the state of one or more words of the slave unit.

    The slave answers the following:

    NOTES:

    "Broadcast" address

    When using writing codes 5 and 6, the address 0 of the slave units is allowed. In this case all the slaves

    connected accept the command but do not give any answer.

    Words format

    Every time the information transfer is made by using 2 byte (1 word of 16 bit), the first byte transmitted is

    the most significant. For the negative numbers is used the "two complement" format.

    Error reply

    The slave unit can find out errors in the master query.

    If the "error check" is incorrect or the function code is not implemented, the slave does not send any an-

    swer to the master.

    If other errors are detected on query frame, the slave replies forcing at "1" the bit 7 of the byte "Function

    code" and gives an error code.

    Error reply

    List of error code

    Range Byte

    Slave address (1-255) 1

    Function code (16) 1

    Word starting address (high byte) 1

    Word starting address (low byte) 1

    Number of words (high byte) 1

    Number of words (low byte) 1

    Number of data bytes 1

    Data n

    Error check (crc16) 2

    Range Byte

    Slave address (1-255) 1

    Function code (16) 1

    Word starting address (high byte) 1

    Word starting address (low byte) 1

    Number of words (high byte) 1

    Number of words (low byte) 1

    Error check (crc16) 2

    Range Byte

    Slave address 1

    Function code (+80h) 1

    Error code 1

    Error check (crc16) 2

    Meaning Error #.

    illegal data address 2

    illegal data value 3

    illegal number of data 9

    the bit or word indicated cannot be modified 10

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    7/14

    5 - G ENGLISH

    Answer time

    The slave replies from 2 ms to 700 ms after the end of a query. (That is detected counting the received

    bytes).

    Decimal digits/ negative numbers

    In case of transmission of decimal digits and/or negative numbers, please see example.

    Example:Number to transmit 205.6 -----------> 2056 is transmitted

    Number to transmit -12.50 ----------> -1250 is transmitted

    WORDS

    Address Description Type Digits M.U. Notes

    27 COMMENT OF RECIPE IN PROGRESS R/W

    10 working SET of STATION 2 R/W xx,x %

    11 working SET of STATION 3 R/W xx,x %

    12 working SET of STATION 4 R/W xx,x %

    13 working SET of STATION 5 R/W xx,x %

    14 working SET of STATION 6 R/W xx,x %

    15 Alarm mode and calculation type of STATION 1 R/W x 1

    16 Alarm mode and calculation type of STATION 2 R/W x 2

    17 Alarm mode and calculation type of STATION 3 R/W x 3

    18 Alarm mode and calculation type of STATION 4 R/W x 4

    19 Alarm mode and calculation type of STATION 5 R/W x 4

    20 Alarm mode and calculation type of STATION 6 R/W x 4

    21 number of process recipe turbo-cycles R/W

    22 rotation time of process recipe mixer R/W xxx s

    23 weight of process batch R/W xx.x kg

    24,25 weight of process mixture R/W xxxxx hg

    26 % added to station 2 for slr1 R/W xx.x

    27 % added to station 2 for slr2 R/W xx.x

    28 maximum instantaneous total production R xxxx kg/h

    29 mdw controls W 8

    30 mdw controls W 9

    50 mdw state R 10

    51 1..16 alarms R 11

    52 17..32 alarms R 12

    53 33..48 alarms R 13

    54 state of digital inputs R 15

    55 state of digital outputs R 16

    56 or alarms R 17

    63,64 Weight of material dosed on station 1 R xxxxx,x g

    65,66 Weight of material dosed on station 2 R xxxxx,x g

    67,68 Weight of material dosed on station 3 R xxxxx,x g

    69,70 Weight of material dosed on station 4 R xxxxx,x g

    71,72 Weight of material dosed on station 5 R xxxxx,x g

    73,74 Weight of material dosed on station 6 R xxxxx,x g

    100 remote flag R/W 7

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    8/14

    6 - GENGLISH

    NOTES

    400,401 station 1 totalizator R xxxxx,xxx kg 36

    402,403 station 2 totalizator R xxxxx,xxx kg 36

    404,405 station 3 totalizator R xxxxx,xxx kg 36

    406,407 station 4 totalizator R xxxxx,xxx kg 36408,409 station 5 totalizator R xxxxx,xxx kg 36

    410,411 station 6 totalizator R xxxxx,xxx kg 36

    412,413 balance weight value R xxxxx,x g

    414 % of material dosed on station 1 R xx,x

    415 % of material dosed on station 2 R xx,x

    416 % of material dosed on station 3 R xx,x

    417 % of material dosed on station 4 R xx,x

    418 % of material dosed on station 5 R xx,x

    419 % of material dosed on station 6 R xx,x

    456,457 Weight of material to dose on station 1 R xxxxx,x g458,459 Weight of material to dose on station 2 R xxxxx,x g

    460,461 Weight of material to dose on station 3 R xxxxx,x g

    462,463 Weight of material to dose on station 4 R xxxxx,x g

    464,465 Weight of material to dose on station 5 R xxxxx,x g

    466,467 Weight of material to dose on station 6 R xxxxx,x g

    468,469 number of produced batches R xxxxxxxx

    Note 1 Variable Description

    1. [ON] read-only alarm

    2. [ON]+[STOP] alarm and doser stop

    Note 2 Variable Description

    From v 6.06.03: IF THE EXCHANGING FLAG OF STATIONS 2, 3 IS ON (note 30) SEE NOTE 3

    1. [ON][TOT] read-only alarm and percentage referring to batch

    2.[ON]+[STOP]

    [TOT]alarm and doser stop and percentage referring to batch

    3. [ON]+[2->1][TOT] alarm, dosage trans. to station 1 and percentage referring to batch

    4. NOT APPLICABLE

    5. [ON][1] read-only alarm and percentage referring to station 1

    6. [ON]+[STOP][1] alarm and doser stop and percentage referring to station 1

    7. [ON]+[2->1][1] alarm, dosage trans. to station 1 and percentage referring to station 1

    Address Description Type Digits M.U. Notes

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    9/14

    7 - G ENGLISH

    Note 3 Variable Description

    Fromv 6.06.03: IF THE EXCHANGING FLAG OF STATIONS 2, 3 IS ON (note 30) SEE NOTE 2

    1. [ON][TOT] read-only alarm and percentage referring to batch

    2.[ON]+[STOP]

    [TOT]alarm and doser stop and percentage referring to batch

    3. [ON]+[3->1][TOT] alarm, dosage trans. to station 1 and percentage referring to batch

    4.

    [ON]+

    [BATCH->1]

    [TOT]

    alarm, whole batch trans. to station 1 and percentage referring to batch

    5. [ON][1] read-only alarm and percentage referring to station 1

    6. [ON]+[STOP][1] alarm and doser stop and percentage referring to station 1

    7.

    [ON]+

    [BATCH->1][1]

    Up to v 6.06.02:alarm, whole batch trans. to station 1 and percentage referring

    to batch 1

    [ON]+[3->1][1]From v 6.06.03 on: alarm, dosage trans. to station 1 and percentage referring to

    station 1

    8.

    [ON]+[3->1][1]Up to v 6.06.02:alarm, dosage trans. to station 1 and percentage referring to

    station 1

    [ON]+

    [BATCH->1][1]

    From v 6.06.03 on: alarm, whole batch trans. to station 1 and percentage refer-

    ring to station 1

    9.

    Up to v 6.06.00: NOT APPLICABLE

    [ON][1+3]From v 6.06.01 on: read-only alarm and percentage referring to the addition

    [1+3]

    10.

    Up to v 6.06.00: NOT APPLICABLE

    [ON]+

    [STOP][1+3]

    From v 6.06.01 on:alarm and doser stop and percentage referring to the addi-

    tion [1+3]

    11.

    Up to v 6.06.00: NOT APPLICABLE

    [ON]+[3->1][1+3]From v 6.06.01 on:alarm, dosage trans. to station 1 and percentage referring to

    addition [1+3]

    12.Up to v 6.06.00: NOT APPLICABLE

    [ON]+

    [BATCH->1][1+3]

    From v 6.06.01 on: alarm, trans. of whole batch to station 1 and percentage

    referring to addition [1+3]

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    10/14

    8 - GENGLISH

    Note 4 Variable Description

    1. [ON][TOT] read-only alarm and percentage referring to batch

    2. [ON]+[STOP][TOT] alarm and doser stop and percentage referring to batch

    3.

    [ON]+

    [BATCH->1]

    [TOT]

    alarm, whole batch transfer to station 1 and percentage referring to the batch

    4. NOT APPLICABLE

    5. [ON][1] read-only alarm and percentage referring to the station 1

    6. [ON]+[STOP][1] alarm and doser stop and percentage referring to the station 1

    7.[ON]+

    [BATCH->1][1]

    alarm, whole batch trans. to station 1 and percentage referring to the station 1

    8. NOT APPLICABLE

    9. [ON][1+3] read-only alarm and percentage referring to the stations 1+3

    10.[ON]+

    [STOP][1+3]alarm and doser stop and percentage referring to the stations 1+3

    11.

    Up to v 6.06.02: NOT APPLICABLE

    [ON]+

    [BATCH->1][1+3]

    From v 6.06.03 on: alarm, whole batch transfer to station 1 and percentage

    referring to stations 1 + 3

    12.

    [ON]+[BATCH->1]

    [1+3]

    Up to v 6.06.02: alarm, whole batch transfer to station 1 and percentage referringto stations 1 + 3

    From v 6.06.03 on:NOT APPLICABLE

    Note 7 Description

    0. local

    1. remote

    Note 8 (bit) Description

    0. changed material start

    1. alarms acknowledge

    2. totalizators reset

    3. alarms reset

    4. unchanged material start

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    11/14

    9 - G ENGLISH

    Note 9 (bit) Description

    0. stop

    Note 10 (bit) Description

    0. stop state

    1. running state

    2. pause state

    3. local check state

    4. calibration state

    Note 11 (bit) Alarm Description

    0. 1 material minimum level on station 1

    1. 2 material minimum level on station 2

    2. 3 material minimum level on station 3

    3. 4 material minimum level on station 4

    4. 5 material minimum level on station 5

    5. 6 material minimum level on station 6

    6. 7 material flow failure on station 1

    7. 8 material flow failure on station 2

    8. 9 material flow failure on station 3

    9. 10 material flow failure on station 4

    10. 11 material flow failure on station 5

    11. 12 material flow failure on station 6

    12. 13 deviation of station 1 dosage

    13. 14 deviation of station 2 dosage

    14. 15 deviation of station 3 dosage

    15. 16 deviation of station 4 dosage

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    12/14

    10 - GENGLISH

    Note 12 (bit) Alarm Description

    0. 17 deviation of station 5 dosage

    1. 18 deviation of station 6 dosage

    2. 19 weighing system reading error

    3. 20 wrong functioning of lower slide gate

    4. 21 printer not ready

    5. 22 end of production (production preset)

    6. 23 volumetric functioning of the doser

    7. 24 safety devices intervention

    8. 25 too low working set for station 1

    9. 26 too low working set for station 2

    10. 27 too low working set for station 3

    11. 28 too low working set for station 4

    12. 29 too low working set for station 5

    13. 30 too low working set for station 6

    14. 31 component not dosed by station 1

    15. 32 component not dosed by station 2

    Note 13 (bit) Alarm Description

    0. 33 component not dosed by station 3

    1. 34 component not dosed by station 4

    2. 35 component not dosed by station 5

    3. 36 component not dosed by station 6

    4. 37 wrong functioning of weigh pan

    5. 38 dosage without station 2

    6. 39 dosage with station 1 only

    7. 40 mixer motor breakdown

    8. 41 lacking batch (start again)

    9. 42 overweight on weighing cell

    10. 43 scanty doser steadiness

    11. 44 dosage without station 3

    12. 45 prealarm for maintenance of station 1

    13. 46 prealarm for maintenance of station 2

    14. 47 prealarm for maintenance of station 3

    15. 48 prealarm for maintenance of station 4

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    13/14

    11 - G ENGLISH

    Note 15 (bit) Description

    0. hopper material level on station 1

    1. hopper material level on station 2

    2. hopper material level on station 3

    3. hopper material level on station 4

    4. hopper material level on station 5

    5. hopper material level on station 6

    6. mixer material level

    7. material level below lower slide gate

    8. safety devices

    9. lower level on regrind accumulation tank

    10. higher level on regrind accumulation tank

    11.

    12.

    13.

    14.

    15.

    Note 16 (bit) Description

    0. dosage control of station 1

    1. dosage control of station 2

    2. dosage control of station 3

    3. dosage control of station 4

    4. dosage control of station 5

    5. dosage control of station 6

    6. mixer control

    7. weighing slide gate control

    8. lower slide gate control

    9. siren control

    10. alarm exit control

    11.

    12.

    13.

    14.

    15.

  • 7/25/2019 KM002100G MDW Serial Protocol Up to Version 6 05

    14/14

    12 GENGLISH

    Note 17 (bit) Description

    0. any alarm

    1. one alarm is present

    Note 36 (bit) Description

    - To zero the totalizators, use the MODBUS 29 address.