Commands
Use the commands below to configure, start, or stop your device.
# configure your device signal chain
synapsectl -u $DEVICE_IP configure $PATH_TO_CONFIG.json
# start recording
synapsectl -u $DEVICE_IP start
# OR send your configuration and start recording together
synapsectl -u $DEVICE_IP start $PATH_TO_CONFIG.json
# stop recording
synapsectl -u $DEVICE_IP stopSave Data
Neural data can either be saved on device using the DiskWriter node or streamed to a local computer running synapsectl using Taps.
The DiskWriter node saves data to the on-device directory specified in your configuration JSON. If the same directory name is used for multiple recordings, each subsequent directory will be appended numerically.
SciFi 2 data directories cannot be accessed via USB. Download on-device data via WiFi using the synapsectl file command. The first time you access a SciFi 2 device, you will be prompted to enter the password found at Settings > Device Info > DiskWriter Pass.
synapsectl -u $DEVICE_IP file ls disk_writer/
Listing directory: disk_writer/
| Permissions | Size | Date modified | Filename |
|-------------|--------|---------------|--------------|
│ drwxrwxr-x │ 4.0 kB │ Apr 22 15:27 │ Data/ │
│ drwxrwxr-x │ 4.0 kB │ Apr 22 15:32 │ Data_1/ │
│ drwxrwxr-x │ 4.0 kB │ Apr 22 16:29 │ Data_2/ │Download saved data to local storage using the get command:
synapsectl -u $DEVICE_IP file get -r disk_writer/$YOUR_DATA_FILENAMEUse Taps to Save Data
SciFi 2 data can be saved to a local client running synapsectl using Taps. Stream and save data from a specified tap in the signal chain using the read command. Data streamed using read requires a configuration file specified with the --output command.
Synapse API
Use the Synapse API command line interface to control your SciFi 2 and client functions. Run synapsectl --help for a full list of available commands.
$ synapsectl --help
usage: synapsectl [-h] [--uri URI] [--version] [--verbose]
{discover,info,query,start,stop,configure,logs,read,plot,file,taps,apps,settings} ...
Synapse Device Manager
options:
-h, --help show this help message and exit
--uri URI, -u URI The device identifier to connect to. Can either be the IP address or name
--version show program's version number and exit
--verbose, -v Enable verbose output
Commands:
{discover,info,query,start,stop,configure,logs,read,plot,file,taps,apps,settings}
discover Discover Synapse devices on the network
info Get device information
query Execute a query on the device
start Start the device or an application
stop Stop the device or an application
configure Write a configuration to the device
logs Get logs from the device
read Read from a device's Broadband Tap and save to HDF5
plot Plot recorded synapse data
file File commands
taps Interact with taps on the network
apps Manage applications on a Synapse device
settings Manage the persistent device settingsSynapse Apps
Synapse Apps are fully customizable, standalone applications deployed directly to your Synapse device. By running custom neural processing algorithms on-device within the signal chain, you can minimize latency. Apps read data from upstream nodes and can output it to downstream nodes or to your local client via WiFi using Taps.
See the Synapse App SDK for more information on building and deploying apps.
Measure Impedance
Construct an impedance query JSON to send to your SciFi 2 device. This example queries electrodes 1–5:
{
"query_type": "kImpedance",
"impedance_query": {
"electrode_ids": [1, 2, 3, 4, 5]
}
}Send the query to the device to start measuring. The command may take a few minutes for large electrode lists.
synapsectl -u $DEVICE_IP query $QUERY_JSON_PATHResults are saved as a CSV titled impedance_measurements_$DATE_$TIMESTAMP.csv. Each electrode is reported with magnitude (Ohms) and phase (degrees):
status {
}
impedance_response {
measurements {
electrode_id: 1
magnitude: 13414576.0
phase: -210.17554
}
measurements {
electrode_id: 2
magnitude: 28159914.0
phase: -184.9782
}
measurements {
electrode_id: 3
magnitude: 12796945.0
phase: -168.97946
}
measurements {
electrode_id: 4
magnitude: 31529048.0
phase: -248.70753
}
measurements {
electrode_id: 5
magnitude: 1768543.4
phase: -147.09204
}
}