Operation manual, General information, Transfer protocol – Baumer NE213 Benutzerhandbuch

Seite 9

Advertising
background image

NE212 / NE213

www.baumer.com

9

Operation Manual

Interface Description for
NE212 / 213

1. General Information

The serial interface can do the same functions as counter display and keyboard. The interface enables calling off
data or alteration of parameters programmed. Normally the counter is PC- operated when working with interface,
that’s why in the following we call the external device shortly PC. However, any other device with similar
characteristics may be used.

2. Transfer Protocol

Transmission takes place on a character-by-character basis using the ASCII code. Each character consists of 8
bits. The 8th bit is the parity bit. With „no parity“, the 8th bit is always transmitted as a zero. Following every
request from the PC, the counter transmits a response via the serial interface, provided data transmission has
taken place correctly.
The transmission of characters is initiated using a start character <STX> and terminated with an end character
<ETX>. In addition, the counter adds a <CR> (carriage return) after the <ETX>. This permits a complete data
block to be read in (in high-level languages such as BASIC) with one command.
After the <STX> follows an address (which is assigned to the relevant counter). This allows a counter operated
as part of a serial network to be selectively addressed. After the address, the line (position) is specified which
you wish to read out or program. In the case of a programming command a „P“ follows (for programming) and
then the data (parameters).

The protocol is divided as follows into three groups:

a) Read-out from storage locations (READ instructions):
<STX> address line <ETX> [<CR>]

b) Programming storage locations (WRITE instructions):
<STX> address line P [VZ] data <ETX> [<CR>]

c) Special commands:
<STX> address parameters <ETX> [<CR>]

<STX> Start of text (02Hex)
Address 00 - 99 (device address)
Line 01 - XX (see operating plan)
P Programming instruction
VZ Sign, only specified for negative numbers
Data Programming data
Parameters Special commands
<ETX> End of text (03Hex)
<CR> 0DHex (control character carriage return) CR does not
have to be specified (optional), but is always
transmitted back from the counter.

Important!
The empty spaces shown between the individual characters in the commands are provided to improve clarity.
When entering at the PC, no empty spaces should be included. Control characters (smaller 20Hex) are shown in
pointed brackets in the description.
If an incorrect protocol is transmitted from the PC, the counter sense back an error signal, only, however, if the
NE212 is still addressable. For more details, see the section on error messages.

Advertising
Dieses Handbuch ist für die folgenden Produkte bezogen werden: