Overview | |
Server responses | |
Command reference | |
Output formats |
Back to the Tissue Properties Home Page |
The server program is a standard UNIX dæmon named Tissue Properties Dæmon (tpd in the following). tpd manages the table of the 14 parameters for each of the defined tissues and incorporates the procedures for the calculation of the relative permittivity, the electrical conductivity and other related quantities (the loss tangent, the wavelength and the penetration depth).
tpd is a multitasking application developed according to the standard model for UNIX concurrent TCP/IP dæmons. It runs on the Unix system (currently a Linux box) having Internet address niremf.ifac.cnr.it (please use this address, not the corresponding numeric IP, because the latter can change without notice), where it keeps listening to TCP port 5210 for requests from clients.
The client-server dialog is based on a simple ASCII protocol, consisting in text lines terminated by the carriage return + line feed sequence and organized in a command/response iterative process. You can test your link to the server issuing the following command on your system: telnet niremf.ifac.cnr.it 5210
If the request is detected, tpd will iniziate the dialog replying with the following standard positive message: +OK Tissue Dielectric Properties Server
and then will dispose itself to accept and execute your commands. From this point up, the dialog goes on with the client sending commands to the server and the server executing the commands and answering with data lines and answers, as described below. The dialog is terminated by the client issuing the QUIT command, causing the server to reply with: +OK Connection closed and shut down the connection.
As previously stated, the client-server dialog is based on a simple, text-oriented command/response protocol. The client sends commands to the server, the server replies with data lines and responses. With very few exceptions, messages from the server fall within one of the five categories described below. In the description, square brackets identify optional parameters, while angular brackets identify mandatory parameters.
more_infoparameter gives some more information on the job just performed.
error_messageparametes gives information on the occurred error.
number_of_data_linesparameter indicates the number of data lines that will follow, while the
more_infoparameter gives more information, when necessary.
Data linesare text lines through which the server sends the requested data to the client. There are several types of data lines, depending on the command issued by the client; for instance, a standard data line is sent to the client specifying the dielectric properties as requested, according to the current output format (see the Output formats section for a description of standard data lines).
Currently, tpd acknowledges the commands listed below. In the command syntax, square brackets identify optional parameters, while angular brackets identify mandatory parameters.
format_indexis not supplied, the command simply displays the current output format index;
format_indexshould be 0,1,2 or 3, otherwise the output format will remain unchanged.
format_indexis the current output format index.
nrepresents the number of tissues managed by the server.
There are four output formats available, numbered 0 to 3. They are
listed below, expressed in the C-language printf
function format
string style; for each format, an example is also provided. The parameters
to pass to the format string are, in order, as follow (the expected unit
of measurement in brackets).
%-*s f= %12.4le Hz sig= %12.4le S/m eps= %12.4le tgl= %12.4le wav= %12.4le m dep= %12.4le m\r\n
Example:
FORM 0
+OK 0 Tissue Dielectric Properties Server
GETS MUSCLE 1000000
Muscle f= 1.0000e+06 Hz sig= 5.0268e-01 S/m eps= 1.8364e+03 tgl= 4.9204e+00 wav= 4.0320e+00 m dep= 7.8524e-01 m
+OK Tissue Dielectric Properties Server
%-*s %12.4le %12.4le %12.4le %12.4le %12.4le %12.4le\r\n
Example:
FORM 1
+OK 1 Tissue Dielectric Properties Server
GETS MUSCLE 1000000
Muscle 1.0000e+06 5.0268e-01 1.8364e+03 4.9204e+00 4.0320e+00 7.8524e-01
+OK Tissue Dielectric Properties Server
%-*s f= %12.4le Hz sig= %12.4le S/m eps= %12.4le\r\n
Example:
FORM 2
+OK 2 Tissue Dielectric Properties Server
GETS MUSCLE 1000000
Muscle f= 1.0000e+06 Hz sig= 5.0268e-01 S/m eps= 1.8364e+03
+OK Tissue Dielectric Properties Server
%-*s %12.4le %12.4le %12.4le\r\n
Example:
FORM 3
+OK 3 Tissue Dielectric Properties Server
GETS MUSCLE 1000000
Muscle 1.0000e+06 5.0268e-01 1.8364e+03
+OK Tissue Dielectric Properties Server
Top of document |