Professional Documents
Culture Documents
02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
Index
Elfolab Data Transfer Transmission Protocol ..................................................................................1
Protocol.............................................................................................................................................2
Export Data .............................................................................................................................2
Import Data .............................................................................................................................2
Packets ..............................................................................................................................................3
COMMAND PACKET (CP) ..................................................................................................3
ACKNOWLEGEMENT PACKET (AP)................................................................................3
RECORD PACKET (RP) .......................................................................................................4
Message format.................................................................................................................................5
Export 'Message' .....................................................................................................................5
Import 'Message' ...................................................................................................................10
Notes ...............................................................................................................................................12
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 1 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
Protocol
• The data transfer uses a Serial Port for both Import and Export.
• The bidirectional stream is encoded using ASCII.
• The Folder “Lis Interface” has to be inserted in the folder where Elfolab is installed.
• From Elfolab menu “Settings”->”Setting Host” it is possible to set the Com Port Settings.
• From Elfolab Settings> Host Setup it is possible to select if the graph fields 38 and 39 will be
exported. If the settings is “Not” the fields 38 and 39 exported will be have the value #NULL#.
Export Data
[Client] request export with a <Command Packet> with “Command Field” 'E' (ascii 69)
[Server] answer with an <Acknowledgement Packet> (ACK or NAK)
[Client] send one or more <Record Packet> with “Message field” containing data to export
[Server] answer with an <Acknowledgement Packet> to each record sent (ACK or NAK)
[Client] send <EOT> (ascii 4) to terminate transmission
Import Data
[Client] request import with a <Command Packet> with the “Command Field” 'I' (ascii 73)
[Server] answer with an <Acknowledgement Packet> (ACK or NAK)
[Server] send one or more <Record Packet> with “Message field” containing data to import
[Client] answer with an <Acknowledgement Packet> to each record sent (ACK or NAK)
[Server] send <EOT> (ascii 4) to terminate transmission
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 2 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
Packets
COMMAND PACKET (CP)
Client sends a <Command Packet> to the server to request an action
Fields:
1. ENQ: 1 byte, (ascii 5)
2. Version: 2 bytes, Int16 containing version of the protocol
3. Command: 1 char, containing the command requested to the server
4. Reserved: 4 bytes, reserved for future use
5. \r : 1 byte, Carriage Return (ascii 13)
6. \n: 1byte, Line Feed (ascii 10)
Command fields are
− 'E' (ascii 69) to start an export
− 'I' (ascii 73) to start an import
RESULT \r \n
(1 byte) (1 byte) (1 byte)
ACK/NAK
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 3 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 4 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
Message format
“Message” is a Packet-Field contained in the “Record Packet” between <STX> and <ETX> char
values, it's a 'string' containing all the data formatted as Comma-Separated-Values.
No ascii value under the 32 is allowed in the “Message Packet-field”.
Export 'Message'
“Export Message” has 81 message-fields described in the following table.
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 5 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 6 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
The format for the <Record Packet> while exporting is the following:
(<STX>, <ETX>,<\r> and <\n> are char values described under “Row Packet”)
<STX>"sample id", “Concentration Value", "department", "name", "sex", "birth date", "patient
id", "Type of Test", "Test Date", "Gel holder number", "trace number", "fractions", "scan
length", "Fraction 1 Name", "Fraction 1 Value", "Fraction 2 Name", "Fraction 2 Value",
"Fraction 3 Name", "Fraction 3 Value", "Fraction 4 Name", "Fraction 4 Value", "Fraction 5
Name", "Fraction 5 Value", "Fraction 6 Name", "Fraction 6 Value", "Fraction 7 Name",
"Fraction 7 Value", "Fraction 8 Name", "Fraction 8 Value", "Fraction 9 Name", "Fraction 9
Value", "Fraction 10 Name", "Fraction 10 Value", "Fraction 11 Name", "Fraction 11 Value",
“’A/G Ratio’", "value of A/G Ratio", "graphic quotes in hex format", "minima positions in hex
format", "notes", ”IgG Value”, ”IgA Value”, ”IgM Value”, ”IgE Value”, ”IgD Value”, ”Kappa
Value”, ”Lambda Value”, "Name of 1st Nephelometric free Field", "1st Nephelometric free Field
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 7 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
Value", Name of 2nd Nephelometric free Field ", 2nd Nephelometric free Value", “Measure Unit
of Nephelometric Values", “Gel ID”, “Free 1 Field”, “Free 2 Field”, “Free 3 Field”, “Free 4
Field”, “Free 5 Field”, “Free 6 Field”, “SMC1 Value”, “SMC2 Value”, “SMC3 Value“, SMC4
Value“, “SMC5 Value”, “SMC6 Value”, “SMC7 Value”, “SMC8 Value”, “ Patient Species”,
“Pathologic Field”, “Username Field”, “Conc. 1 Field”, “Conc. 2 Field”, “Conc. 3 Field”, “Conc.
4 Field”, “Conc. 5 Field”, “Conc. 6 Field”, “Conc. 7 Field”, “Conc. 8 Field”, “Conc. 9 Field”,
“Conc. 10 Field”, “Conc. 11 Field”<ETX><\r><\n>
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 8 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 9 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
Import 'Message'
The Import command can import a maximum of 999 records.
Import 'Message' has 26 message-fields described in the following table.
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 10 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
The format for the <Record Packet> while importing is the following:
(<STX>, <ETX>,<\r> and <\n> are char values described under “Row Packet”)
<STX>"sample id", "Concentration", "department", "name", "sex", "birth date", "patient id",
”IgG Value”, ”IgA Value”, ”IgM Value”, ”IgE Value”, ”IgD Value”, ”Kappa Value”, ”Lambda
Value”, "1st Nephelometric free Field Name", "1st Nephelometric free Field Value", 2nd
Nephelometric free Field Name ", 2nd Nephelometric free Value", “Measure Unit of
Nephelometric Values",“Gel ID”, “Free 1 Field”, “Free 2 Field”, “Free 3 Field”, “Free 4 Field”,
“Free 5 Field”, “Free 6 Field”<ETX><\r><\n>
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 11 di 12
ELFOLAB DATA TRANFER TRANSMISSION REV. 02
PROTOCOL VIA SERIAL COMMUNICATION 29.01.14
Notes
• If the field “Sampled ID" is empty (#NULL#) all the respective
line won’t import.
• If a field has value “NULL” then Elfolab will export #NULL# for
this field.
• STX =ASCII char 2
• ETX =ASCII char 3
• EOT =ASCII char 4
• ENQ =ASCII char 5
• ACK =ASCII char 6
• NAK =ASCII char 21
All the content of this Document, is a property of INTERLAB S.r.l. Via Rina Monti, 26 00155 Roma ITALY U.E Pag. 12 di 12