Beruflich Dokumente
Kultur Dokumente
1. Allgemeines
Die serielle Schnittstelle kann die gleichen Funktionen erfüllen, wie das Display und die Tastatur am Zähler.
Man kann über die Schnittstelle Daten abrufen und Parameter umprogrammieren. Im Allgemeinen wird der Zäh-
ler beim Betrieb mit der seriellen Schnittstelle von einem PC bedient. Es kann aber auch ein anderes Gerät mit
ähnlichen Eigenschaften verwendet werden.
2. Übertragungsprotokoll
Die Übertragung erfolgt zeichenweise im ASCII-Code. Jedes Zeichen besteht aus 8 Bit. Das 8. Bit ist das Parity
Bit, bei "no Parity" wird das 8. Bit immer Null gesendet.
Der Zähler sendet auf jede Anforderung vom PC über die serielle Schnittstelle eine Antwort, sofern die Daten-
Übertragung korrekt erfolgt ist.
Eine Übertragung von Zeichen wird mit einem Startzeichen <STX> eingeleitet und mit einem Endzeichen <ETX>
abgeschlossen. Zusätzlich wird vom Zähler nach dem <ETX> noch ein <CR> (Wagenrücklauf) gesendet. Dies
ermöglicht das Einlesen (in Hochsprachen wie BASIC) eines kompletten Datenblocks mit einem Befehl.
Nach dem <STX> folgt eine dem Zähler zugeordnete Adresse. Somit kann der Zähler in einem seriellen Netz-
werk gezielt angesprochen werden. Nach der Adresse gibt man die Zeile (Position) an, die man auslesen oder
programmieren möchte. Bei einem Programmierbefehl folgt dann noch ein "P" (programmieren) und die Daten
(Parameter).
c) Sonderbefehle:
Beispiel:
Wichtig ! Die Leerstellen zwischen den einzelnen Zeichen in den Befehlen dienen nur zur besseren Darstellung.
Die Eingabe am PC muss ohne Leerstellen erfolgen. Steuerzeichen (kleiner 20Hex) werden in der Beschreibung
in spitze Klammern eingefasst.
Wird ein falsches Protokoll vom PC gesendet, so sendet der Zähler eine Fehlermeldung zurück. Dies setzt vor-
aus, dass der NE218 noch ansprechbar bleibt. Lesen Sie dazu den Abschnitt Fehlermeldungen auf Seite 5.
www.baumer.com 2
NE218
Write-Befehl (allgemein):
www.baumer.com 3
NE218
5. Sonderbefehle
Bei den Sonderbefehlen handelt es sich mit Ausnahme des Befehls "Zählerstand löschen" um Anweisungen, die
sich auf keine Zeilennummer (Speicherplatz im Bedienerplan) beziehen.
www.baumer.com 4
NE218
Hinweis: Befindet sich der Zähler auf einer Zeile, die keine Daten beinhaltet (z.B. Zeile 10), wird eine Fehlermel-
dung "<CAN><NUL>" zurückgesendet.
Bei der Fehlerrückmeldung entfallen die beiden Positionen "Zeile" und "Status"
Fehlerbeschreibung im Einzelnen:
Fehler 1 : Formatfehler (<ETX> nicht an der richtigen Stelle). Dieser Fehler tritt
z.B. auf, wenn das Datenformat bei der Programmierung nicht eingehalten
wird.(z.B.: Beim Programmieren des Setzwertes werden nur 5 Daten-
Stellen anstatt 6 übertragen)
www.baumer.com 5
NE218
8. Bedienungsplan
Zeile Werkseinstellung Kundenprogramm Kurzbeschreibung
01 0 XP - Zählerstand Hauptzähler
02 1 0 0 P1 - Vorwahl 1
03 1 0 0 0 P2 - Vorwahl 2
04 0 SC - Setzwert
05 0 Σ - Summenzähler
06 0 § - Betriebstundenzähler
07 1.0 0 0 0 SF - Skalierungsfaktor
10 - - - - - - Trennzeile
11 S t a t 0 S t a t XP - Zählerstand Hauptzähler
12 S t a t 0 S t a t P1 - Vorwahl 1
13 S t a t 0 S t a t P2 - Vorwahl 2
14 S t a t 0 S t a t SC - Setzwert
15 S t a t 0 S t a t Σ - Zählerstand Hauptzähler
16 S t a t 0 S t a t § - Zählerstand Hauptzähler
17 S t a t 0 S t a t SF - Skalierungsfaktor
20 - - - - - - Trennzeile
22 2 2 0 2 2 Betriebsarten
24 2 4 0 2 4 Dezimalpunkt
25 2 5 0 2 5 Zählweise
26 2 6 0 2 6 Frequenz Hauptzähler Spur A
27 2 7 0 2 7 Frequenz Hauptzähler Spur B
28 2 8 0 2 8 Eingangslogik
29 2 9 0 2 9 Rückstellung Hauptzähler (Steuereingang 1)
31 3 1 0 3 1 Funktion Steuereingang 2
33 3 3 0 3 3 Ausgangslogik für Digitalausgang
35 3 5 t 1 3 5 Ausgangszeit P1
0.2 5
36 3 6 t 2 3 6 Ausgangszeit P2
0.2 5
37 3 7 0 3 7 Übernahme der Vorwahlen P1,P2
38 3 8 0 3 8 Einstellbereich P1,P2 und SC
39 3 9 0 3 9 Zuweisung Funktionstaste
40 4 0 C o d 4 0 Code-Einstellung
0
41 4 1 0 4 1 Funktion des Nebenzählers
42 4 2 1 4 2 Multiplikator des Nebenzählers
43 4 3 C o r 4 3 Istwert Korrektur
0
42 4 4 0 4 4 Anzeige Netzausfall
51 5 1 0 5 1 Baudrate
52 5 2 0 5 2 Parity
www.baumer.com 6
NE218
9. Programmierplan
Zl 11-17 Status für Zeile 1-7 Zeile 37 Übernahme der Vorwahlen P1,P2
0 Parameter kann geändert werden 0 Sofort wirksam
1 Löschen bzw. Eingabe gesperrt 1 Bei Rückstellung
2 Parameter wird übersprungen
Zeile 38 Einstellbereich P1,P2 und SC
Zeile 22 Betriebsarten 0 Nur im positiven Bereich
0 Stufenvorwahl 1 Im positiven und negativen Zählbereich
1 Hauptvorwahl
2 Parallelvergleich Zeile 39 Zuweisung Funktionstaste
3 P1-Schleppvorwahl 0 Ohne Funktion
1 XP
Zeile 24 Dezimalpunkt 2 P1
0 Kein Dezimalpunkt 3 P2
1 00000.0 4 SC
2 0000.00 5 Σ
3 000.000 6 §
4 00.0000 7 SF
www.baumer.com 7
NE218
Operating instructions
Interface description
NE218 Program 01
1. General information
A serial interface fulfills the same functionalities as display and counter keypad. The interface is used for data
requests and parameterizing. When utilizing a serial interface, the counter is usually operated by a PC. However,
any other device offering the same functionality will do as well.
2. Transmission protocol
Transmission is performed token by token in ASCII-Code. Every token comprises 8 bit. Bit number 8 is the parity
bit, in case of “no parity” this bit is ever transmitted as 0.
The counter will respond to every PC request via the serial interface, provided data transmission was correct.
The token transmission provides a starting header (start of text) <STX> and an ending footer <ETX> (end of
text). The counter will add affix <CR> (carriage return) after <ETX> to enable read-in of the complete data block
by a single command (for example in high level languages like BASIC).
<STX> is followed by the allocated counter address used to address the counter in the serial network. The ad-
dress is followed by the line (item) to be read out or programmed. A programming command is followed by “P”
(programming) and the data (parameters).
c) Special commands:
Example:
www.baumer.com 8
NE218
Important! The spaces between the individual command tokens are only for better understanding and must not
be entered in a PC operation. Control tokens (inferior to 20Hex) are in square brackets.
When receiving an incorrect PC protocol the counter will return an error message, provided NE218 is still ad-
dressable in the network. Please refer also to paragraph „Error messages“ on page 5.
www.baumer.com 9
NE218
All parameters entered in RUN mode are only saved non-volatile after having switched from PGM to RUN
mode. If there is no switching operation from PGM to RUN, the previously effective data will be restored
after power loss.
Write-command (general):
www.baumer.com 10
NE218
5. Special commands
Except the command „clear current counter value“, special commands do not relate to a specific memory loca-
tion (line number in the parameterization plan).
Repeating the command will switch the counter back to RUN mode.
Command: <STX>35<DC1><ETX>
Response: <STX>35R<ETX><CR>
www.baumer.com 11
NE218
Note: A line with no data content (for example line 10) will result in replying error message "<CAN><NUL>".
Error 1 : Format error (<ETX> not at the correct location. Error occurs if the
data format was not observed during parameterization (for example: when
programming the start count value only 5 digits were transferred instead
of 6)
Error 3 : Parameter error (Void values in the protocol), for example, the scaling
factor is not only composed of figures but also other void characters, or
a value is outside the permissible range.
www.baumer.com 12
NE218
8. Operating plan
Line Default Firmware Short explanation
01 0 XP – current value main counter
02 1 0 0 P1 - preset 1
03 1 0 0 0 P2 - preset 2
04 0 SC – start count value
05 0 Σ - totalizer
06 0 § - hour counter
07 1.0 0 0 0 SF – scaling factor
10 - - - - - - Separating line
20 - - - - - - Separating line
22 2 2 0 2 2 Operating modes
24 2 4 0 2 4 Decimal point
25 2 5 0 2 5 Count mode
26 2 6 0 2 6 Frequency main counter track A
27 2 7 0 2 7 Frequency main counter track B
28 2 8 0 2 8 Input logic
29 2 9 0 2 9 Main counter reset (control input 1)
31 3 1 0 3 1 Functionality control input 2
33 3 3 0 3 3 Output logic of digital output
35 3 5 t 1 3 5 Output time P1
0.2 5
36 3 6 t 2 3 6 Output time P2
0.2 5
37 3 7 0 3 7 Adopt presets P1,P2
38 3 8 0 3 8 Value range P1,P2 and SC
39 3 9 0 3 9 Function key assignment
40 4 0 C o d 4 0 Code
0
41 4 1 0 4 1 Batch counter functiopn
42 4 2 1 4 2 Batch counter multiplier
43 4 3 C o r 4 3 Offset
0
42 4 4 0 4 4 Display power loss
51 5 1 0 5 1 Baud rate
52 5 2 0 5 2 Parity
www.baumer.com 13
NE218
9. Parameterization plan
Zl 11-17 Status for lines 1-7
0 Parameter change enabled Line 38 Counting range P1,P2 and SC
1 Parameter lock (entry,clearing)
0 Only positive
2 Skip parameter
1 Positive and negative
Line 22 Operating modes
Line 39 Function key assignment
0 Step preset
0 Not operational
1 Main preset
1 XP
2 Parallel comparison
2 P1
3 P1-dragged preset
3 P2
4 SC
Line 24 Decimal point
0 No decimal point
5 Σ
1 00000.0
6 §
7 SF
2 0000.00
3 000.000
Line 40 Code
4 00.0000
0000 Code not active
Line 25 Count mode :
9999
0 Track A resp. UP/DOWN-signal on track B
1 Subtracting (A-B)
Line 41 Functionality batch counter
2 Adding (A+B)
3 Track A 90° B single evaluation 0 Totalizer
4 Track A 90° B double evaluation 1 When achieving P2
5 Track A 90° B four times evaluation
Line 42 Multiplier batch counter (Line 41=1)
Line 26 Frequency main counter track A 1 Default
0 10 kHz 0 Min.
1 25 Hz 999 Max.
2 3 Hz
Line 43 Offset
Line 27 Frequency main counter track B 0 No offset
0 10 kHz :
1 25 Hz 999999 Max. offset
2 3 Hz
Line 44 Power loss warning
Line 28 Input logic 0 No warning
0 PNP - Trigger threshold 10V 1 warning (display flashing)
1 NPN - Trigger threshold 10V
2 PNP - Trigger threshold 5V
3 NPN - Trigger threshold 5V
4 PNP - Trigger threshold 2,5V Line 51 Baudrate
5 NPN - Trigger threshold 2,5V 0 4800 Baud
1 2400 Baud
Line 29 Reset main counter (control input 1) 2 1200 Baud
0 Automated reset and ext. static 3 600 Baud
1 Automated reset and ext. differntiated
2 Extern static Line 52 Parity
3 Extern differentiated 0 Even Parity
4 Extern with "Start-functionality" 1 Odd Parity
2 No Parity
Line 31 Functionality control input 2
0 Stop Line 53 Stoppbits
1 Hold 0 1 Stoppbit
2 Keylock 1 2 Stoppbits
3 Hour counter on/off
4 Offset Line 54 Adresse
5 Print (only with interface) 00 Default
00 Min.
Line 33 Digital output logic 99 Max.
0 Both outputs normally closed
1 P1 Normally open, P2 Normally closed Line 55 Output assignment via interface
2 P1 Normally closed, P2 Normally open Line 31=5
3 Both outputs Normally open 0 Displayed value
1 XP
Line 35 Latch signal duration P1 2 P1
0.25 Default 3 P2
0.01 Min. 4 SC
99.99 Max. 5 Σ
6 §
Line 36 Latch signal duration P2 7 SF
0.25 Default
0.01 Min. Line 56 RS422: connections TxD+ , TxD-
99.99 Max. 0 In transmission direction during trans-
mission, in receiving direction upon
Line 37 Preset P1, P2 adoption receipt
0 Immediately effective 1 Ever in transmission direction
1 After reset
www.baumer.com 14