getPackets nodeURL [-between startTime endTime] [-default] [-types type(s)] [-skip subsampleInterval] [-timeout timeoutSec] [-maxbytes n] [-stale] [-nosave] deviceID


The getPackets utility retrieves packets from a specified instrument service, subject to subsampling and filtering specified by options specified on the command line. Retrieved packets are written to a device log in the current directory.

The device log consists of two files, one the .dat extension and one with .idx extension. The .dat file contains the data, and the .idx is an index to enable effient searches of the data file.

The file names use the format

<deviceID>_0.dat, <deviceID>_0.idx

For example, the log for device 1473 consists of files 1473_0.dat and 1473_0.idx. If the log files for the specified device already exist, getPackets will append to the log.

The logged packets can subsequently be displayed with the logView utility.


Option Description Values
deviceID IP address or host name of SIAM node e.g.,

long (64-bit) integer uniquely identifying the instrument service

filter utilities use deviceIDs instead of instrument ports to specify an instrument
14533,997,1003, etc.
-between startTime endTime Request packets from within the specified time window. startTime and endTime are date/time strings using the format:
The time should be specified in UTC(?)
04/01/2010, 03/15/2009T11:34
-default Use instrument default filters -
-types type(s) Specify filter packet types valid values are 'metadata', 'data', 'message', 'summary', or 'all'
-skip subsampleInterval Specify filter interval (decimation modulus)

4: skip 4 samples (i.e., receive every 5th packet of the specified type(s))

0: return all packets

-1: skip all packets (return no packets)

-timeout timeoutSec -
-maxbytes n maximum bytes per packetset Aggregate packets into groups < maxbytes in size. This number can reduce overhead when there are many small packets to transfer. If this number is smaller than the smallest single packet, no data will be returned.
-stale Include "stale" packets (packets older than the age specified by the dataShelfLifeHours property -
-nosave Don't save retrieved packets -

Example output:



The following environment variables must be set:

Variable Description Example
JAVA_HOME location of Java installation
/j9, /opt/java/jdk1.3.1, etc.
JAVA Path to JVM command For MMC

For Sun JVM (e.g. linux, win32, mac OS)
SIAM_HOME top of the SIAM directory tree -
SIAM_CLASSPATH Path including all SIAM and supporting classes For MMC

For linux/win32

See Also