beautypg.com

Data exchange between plc and generator control, Transmission from the generator control to the plc, 9 data exchange between plc and generator control – HEIDENHAIN TNC 306 Technical Manual User Manual

Page 168

background image


4-68

TNC 406/TNC 306

4 Gap control

3/97

4.9 Data exchange between PLC and generator control

The TNC 406 can transfer data from the NC to the generator control and vice versa.

This data transmission is activated by the PLC and runs through the RS-422/V.11 interface. The
RS-422/V.11 interface is permanently allocated for transmission. It can be considered an extension
to the available PLC inputs and outputs. The data is transmitted in hexadecimal code in Motorola
format (first high-byte, then low-byte).

The data format has the following fixed setting:

1 start bit, 8 data bits, even parity, 1 stop bit, 9600 baud

After reception of one data block, the receiving unit checks whether the BCCs of the transmitted
and received data blocks match. If this is the case, the receiving unit confirms the data block by
transmitting . Otherwise it transmits and outputs an error message.

4.9.1 Transmission from the generator control to the PLC

The transmission protocol consists of the following sequence:

Generator transmits:

n

>

< > <....>

n

>

Meaning of the characters:

= Synchronization character (= CA)

= Number of following data bytes including without

. Maximum 100 data bytes are allowed (01H to 64H)

= Code for command to be executed

00 = Read 8 markers (all markers permitted)
02 = Set or reset a marker (permitted M0 to M1999 and M2930 to M3023)
04 = Read

x

bytes or read

x

words (permitted B0 to B1023)

06 = Load byte or load word (B0 to B255)

= Start address High Byte

= Start address Low Byte


<......>

= Number of data bytes or data bytes (1 to

n

), or none of either (depending of

the function)

= Block Check Character (generated to describe all bytes except SYNC)

If the PLC has received a data block, checked the BCC and acknowledged with ACK, it then
evaluates the command byte (ID character) and executes it. A new transmission must not be started
until the old transmission has been concluded with ACK.

This manual is related to the following products: