Event Acquisition Entity Commands

These commands are used to control how the event acquisition entities process events; what it does with the data after processing; and generate non-TTL events.


 -GetDataFile <Acq Ent Name>
Returns the data file name and path for the specified acquisition entity.

Example :   -GetDataFile Events
Default:  N/A
Usage:  This command should only be used from a NetCom client application after a connection to a server has been established.
Arguments
Acq Ent Name The name of the acquisition entity that the data file name is being requested for.
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 is the data file name and path for the specified acquisition entity.

 -PostEvent <Event String> <TTL Value> <Event ID> <Timestamp>
Posts an event to __prod_name.  __prod_name will log this event in the log file, and record it to the events data file if in recording mode.  

Example :   -PostEvent "Test Event" 256 0
Default: This command is an action, there is no default value.
Usage:  This command can be used at any time, but is only logged to a data file when __prod_name is recording.
Arguments
Event String
The string to be associated with this event.  This string must be less than 128 characters, including spaces.  
TTL Value This is a decimal value, between 0 and 65535 and is stored in the TTL field of an event record.  It does not have any effect on the output port.
Event ID This value represents the location from which the event is being posted.
Timestamp This is an optional parameter.  If  this value is not specified, __prod_name will use the current timestamp for the event.  This value is in microseconds.

 -RemoveNamedTTLEvent <Device Name> <Port Number>  <Bit Number>
Removes the custom event string for a named TTL event and resets it to the default event string. If no named TTL event was set for this TTL bit, the command will succeed, but do nothing.

Example :    -RemoveNamedTTLEvent AcqSystem1_0 0 4
Default:   All events will use the default event string for TTL events.
Usage:  This command can be used at any time.
Arguments
Device Name
The name of the Digital IO device where the desired TTL value originates.
Port Number
The number of the digital IO port that on the Digital IO device where the TTL value originates.
Bit Number
The bit whose named event you wish to remove. This value must be between 0 and NumBitsOnPort - 1 (e.g. for an 8 bit port, the value must be between 0 and 7).

 -SetDataFile <Acq Ent Name> <File Name> 
Sets the data file for the specified acquisition entity.  All data records recorded for this acquisition entity will be saved to this file.  

Example :   -SetDataFile Events "C:\My Events.nev"
Default: __prod_name will create a file using the name of the acquisition entity in the current data directory when the acquisition entity is created (i.e.__prod_name created Events.nev in the current data directory when the Events acquisition entity was created).
Usage:  This command can be used at any time.
Arguments
Acq Ent Name
The name of the acquisition entity which will be modified.
File Name Sets the file to use for data recording for the specified acquisition entity.  If only a filename is specified, __prod_name will create the file in the current data directory.  When the data directory is changed, the file's location will change with the data directory.

Example :   -SetDataFile  SE1 SE1.nse

If a complete path is specified, __prod_name will create the file in the specified location, and will not change the file's location when the data directory is changed.

  Example : -SetDataFile  CSC1 "C:\Data Directory\CSC1.ncs"

The directory C:\Data Directory must exist or this command will fail.  If the file CSC1.ncs exists, it will be overwritten.  The extension of the file will be changed to the appropriate Neuralynx extension for the specified acquisition entity type.  __prod_name will always create a file using the acquisition entity's name in the current data directory.  If this command is issued before any data is recorded, the file in the current data directory will only have header information.

 -SetDiskWriteEnabled <Acq Ent Name> <Value> 
Enables or disables disk writing of data records for the specified acquisition entity.  This command does not affect data records over NetCom or the data visible in all plots for this acquisition entity.  You may want to disable disk writing for control or stimulus signals that you want to see, but have no need for in data analysis.

Example :    -SetDiskWriteEnabled Events true  
Default:  __prod_name initially enables disk writing when an acquisition entity is created.
Usage:  This command can be used at any time.
Arguments
Acq Ent Name
The name of the acquisition entity which will be modified.
Value This value can be one of the following keywords:
  1. True :  Enables disk writing of data records.
  2. False :   Enables disk writing of data records. If disk writing is disabled prior to recording, a data file will be created for the specific acquisition entity, but only header information will be written to the file.  If disk writing is disabled after recording has begun, all records after disk writing has been disabled will not be written until disk writing is re-enabled.

 -SetNamedTTLEvent <Device Name> <Port Number>  <Bit Number> <Custom Event String>
Sets a custom event string for a specific TTL bit going from 0 (low) to 1 (high). If a __prod_name detects a change from low to high on the bit number of the specified port on the specified Digital IO device, the default event string will be replaced with your custom event string in the event record. If named TTL events are associated with multiple bits on the same port, one event will be generated for each bit number, using the appropriate custom event string.

NOTE : Replacing the default event string means that some information about the source of the TTL value will be lost. Specifically, the name of the DigitalIO device and the port number that generated the TTL.

Example :    -SetNamedTTLEvent AcqSystem1_0 0 3 "custom event text"
Default:   All events will use the default event string for TTL events.
Usage:  This command can be used at any time.
Arguments
Device Name
The name of the Digital IO device where the desired TTL value originates.
Port Number
The number of the digital IO port that on the Digital IO device where the TTL value originates.
Bit Number
The bit whose named event you wish to set. This value must be between 0 and NumBitsOnPort - 1 (e.g. for an 8 bit port, the value must be between 0 and 7).
Custom Event String
Any ASCII string that contains at least one non-space character up to 128 characters.