Table of Contents

Headstage Rhs2116 Port Status

The Onix system reports when a headstage/miniscope port connection enters or leaves an aberrant state. Such aberrant states include loss of communication lock, detection of parity or CRC error, reception of a badly formatted packet, etc. Knowing the time and type of an aberrant state can help track down its cause. The following excerpt from the Headstage Rhs2116 example workflow demonstrates port status functionality and saves timestamped port status data.

~/workflows/hardware/rhs2116/port-status.bonsai workflow

PortStatus emits a PortStatusFrame when PortStatusCode changes value i.e. when the Headstage Rhs2116 port connection enters or leaves an aberrant state. Its DeviceName property is set to "HeadstageRhs2116/PortController" which links the operator to the port controller where the Headstage Rhs2116 is connected.

The TimeStamp operator generates a sequence of UTC timestamped items from its input sequence. The CsvWriter operator writes Timestamp as well as Clock and StatusCode members from PortStatusFrame to a file with the following name format: port-status_<filecount>.csv.

NOTE

The PortStatus datastream is always enabled. ConfigureHeadstageRhs2116 does not have an Enable property for streaming port status data.