General __prod_name Commands

These commands are general commands for __prod_name.  They are primarily used during configuration file processing to setup system wide options or control configuration file processing.

 -Break
Halts execution of the current configuration file and closes the file.  If the current configuration file was called from a different configuration file using the -ProcessConfigurationFile command, the calling configuration file will continue.

Example:   Assume you have two configuration files:
__prod_name.cfg (contains the following three lines):

-LogMessage Notice Message1
-ProcessConfigurationFile my_file.cfg
-LogMessage Notice Message3


my_file.cfg (contains the following two lines):

-Break
-LogMessage Notice Message2

__prod_name will exit the my_file.cfg file without processing the -LogMessage Notice Message2 command and continue with the -LogMessage Notice Message3 command in __prod_name.cfg.

Default: This command is an action, there is no default value.
Usage:   This command can be used at any time.

 -GetApplicationName
Gets the application name of the server for which the client is connected to.

Example :   -GetApplicationName
Default:  N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Application Name The name of the application for which the NetCom client application is currently connected to.

 -GetCreateNewFilesPerRecording
Returns an indicator of whether or not new files are being created every time recording is stopped.

Example :   -GetCreateNewFilesPerRecording
Default:  False
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Value This value will be one of the following:
  1. True:  New data files will be created every time recording is turned off.
  2. False:   The same data file will be used when recording is toggled.

 -GetDASBuildDate
Returns the build date for the __prod_name application for which the client is connected to.

Example :   -GetDASBuildDate
Default:  N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Build Date The build date of the __prod_name application for which the NetCom client application is currently connected to.

 -GetDASObjects
Returns a list of object name and object type pairs.

Example :   -GetDASObjects
Default:  N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Object List List of object names and types that currently exist in the application.  Each list item name will be in double quotes.


 -GetDASState
Returns the current data acquisition state.

Example :   -GetDASState
Default:  N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
State The current state of data acquisition formatted as a string.  This value will be set to one of the following:
  1. Idle : Acquisition and recording are turned off.
  2. Acquiring : Acquisition is on but recording is off.
  3. Recording : Acquisition and recording are turned on.


 -GetDASVersionNumber
Returns the version number for the __prod_name application for which the client is connected to.

Example :   -GetDASVersionNumber
Default:  N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Version Number The version number of the __prod_name application for which the NetCom client application is currently connected to.

 -GetDataDirectory
Returns the current data directory which includes the current timestamped directory.

Example :   -GetDataDirectory
Default:  N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Data Directory The current data directory being used by __prod_name to store data files in.

 -GetLogFilePath
Returns the current path for the log file.

Example :   -GetLogFilePath
Default:
 N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Path The current path for the log file.

 -GetMaxFileLength
Returns the maximum amount of time (in hours) that a data file can hold.

Example :   -GetMaxFileLength
Default:
 N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Maximum File Length An integer value indicating the maximum number of hours. A value of 0 means the file length is unlimited.

 -GetSessionName
Returns the current session name identifier.

Example :   -GetSessionName
Default:
 N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Session Name The current session name for the DAS.

 -GetSessionUUID
Returns the unique identifier associated with the current session.

Example :   -GetSessionUUID
Default:
 N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Session UUID The current unique identifier associated with the current session in string format.

 -GetSubject
Returns the current subject ID.

Example :   -GetSubject
Default:
 N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Subject ID The current subject ID assigned to the current subject.

 -GetSubjectInformationDirectory
Returns the current subject information directory.

Example :   -GetSubjectInformationDirectory
Default:
 N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Directory The current subject information directory.

 -GetSystemIdentifier
Returns the current system identifier for the DAS.

Example :   -GetSystemIdentifier
Default:
 N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
System ID The current system identifier for the DAS.  This value is stored as a string.

 -GetTimestamp
Returns the current timestamp from the DAS.

Example :   -GetTimestamp
Default:
 N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0.  Otherwise, the value will be equal to -1.
Timestamp The number of microseconds since midnight Jan 1, 1970 local time. This will be the timestamp of the system when this command is processed. There will be a delay between when the command is processed and when the return value is received.

 -LogMessage <Message Type> <Message> 
Logs the message to the current __prod_name logfile.

Example :  -LogMessage Notice "Log Message To Logfile"
Default:  This command is an action, there is no default value.
Usage:   This command can be used at any time.
Arguments
Message Type
Specifies the message label to be for the specified message.  This must be one of the following message type keywords:
  1. Fatal:  Fatal messages are unrecoverable, and __prod_name should be restarted.
  2. Error:   Error messages are for errors in commands, incorrect keywords or values, or intermittent problems with a portion of the system 
  3. Warning:   Warning messages indicate that something happened out of the ordinary, but was handled by __prod_name.
  4. Notice:   Notices provide status information about __prod_name.  These messages are purely informational.
  5. Data:   Data messages are not generated by __prod_name.  These message types can be used to log information to the log file.  However, if you will use these messages for analysis, you would be better off posting an event with the message as the event string.
Message
This is an ascii string that must be between double quotes.

 -ProcessConfigurationFile <File Name> 
Tells __prod_name to process the specified configuration file.  __prod_name will process this file completely before continuing to the command after -ProcessConfigurationFile.  Any errors in the specified configuration file will cause all configuration file processing to stop.  

Example :  -ProcessConfigurationFile my_configuration.cfg
Default:  This command is an action, there is no default value.
Usage:   This command can be used at any time.
Arguments
File Name
The name of the configuration file to process.   If only a filename is specified, __prod_name will attempt to find the file by first looking in the working directory specified when the program started (usually the directory containing __prod_name.exe), then in the Configuration directory, and finally in the same directory as the configuration file containing this command. If the file does not exist in any of those directories, this command will fail.

Example :  -ProcessConfigurationFile my_configuration.cfg

If a complete path is specified, __prod_name will look for the specified file, if it is not found, this command will fail.

  Example : -ProcessConfigurationFile "C:\__prod_name Configurations\my_configuration.cfg"

 -SetCreateNewFilesPerRecording <Value> 
Sets a value that determines whether or not new data files will be created every time recording is turned off.

Example :  -SetCreateNewFilesPerRecording True
Default: False
Usage:   This command can be used at any time.
Arguments
Value
This value should be one of the following:
  1. True:  New data files will be created every time recording is turned off.
  2. False:   The same data file will be used when recording is toggled.

 -SetDataDirectory <Directory Path> 
Sets the base data directory for all of the files __prod_name creates.  The location of these files can be overridden by the -SetLogFile, -SetDataFile, -SetRawDataFile, or -SetVideoFileOutput commands.  A sub-directory will automatically be created with the date and time (in 24 hour format) at the time this command is processed.  __prod_name will use the C:\temp directory as the base data directory if this command is not used.  

Example :  -SetDataDirectory "C:\__prod_name Data"
Default: __prod_name will use C:\temp as the base data directory..
Usage:   This command can be used only if __prod_name is idle.
Arguments
Directory Path
The full path name of the directory to use as the base data directory .  If the directory doesn't exist, it will be created.

Example: -SetDataDirectory "C:\__prod_name Data"

If this command is run on October 13, 2007 at 1:57:07 PM, __prod_name will create the following directory (referred to as the Current Data Directory):

C:\__prod_name Data\2001-10-13_13_57_07

All files not overridden by the commands stated above will be created in that directory, and files will be created every time the -SetDataDirectory command is used.

 -SetLogFile <File Name> 
Sets the file where all __prod_name system messages will be logged.

Example :   -SetLogFile My_Logfile.txt
Default: __prod_name will use __prod_nameLogFile.txt in the current data directory as the logfile.
Usage:   This command can be used at any time.
Arguments
File Name
Sets the file to use for logging __prod_name system messages. The logfile normally uses a .TXT extension.  If only a filename is specified, __prod_name will create the file in the current data directory.  

Example :  -SetLogFile My_Logfile.txt

If a complete path is specified, __prod_name will create the file in the specified location.

  Example : -SetLogFile "C:\__prod_name Logs\My_Logfile.txt"

The directory C:\__prod_name Logs must exist or this command will fail.

 -SetMaxFileLength <Value> 
Sets the maximum amount of time (in hours) a data file can hold including gaps.

Example :  -SetMaxFileLength 3
Default: 24 4
Usage:   This command may only be used when recording is off.
Arguments
Value
This value must be an integer between 1 and 244 inclusive.

 -SetSystemIdentifier <System ID>
Sets the system identifier string value for the current session.

Example :   -SetSystemIdentifier "MyComputer"
Default:
 The PC name will be used as the default for this value.
Usage:  This command may be used at any time.
Arguments
System ID
String value used to identify the system.