Out now! – TriggerBox Plus streams any trigger via LSL

by Dr. Alex Kreilinger (Brain Products Technical Product Manager)

The TriggerBox has been one of the core products in Brain Products’ portfolio since its creation almost 10 years ago. With the TriggerBox, it is very convenient to add event information to the recordings of our amplifiers or any other device with TTL trigger inputs. Hardware triggers can be sent directly from your stimulus presentation software of choice via USB or by connecting other sources, such as push buttons or other devices, to the TriggerBox.

TriggerBox Plus streams any trigger via LSL The TriggerBox Plus still has all these features but now offers you more flexibility and speed. On top of that, it is now possible to simultaneously send triggers to a local network as LabStreamingLayer (LSL) markers. Thereby, it is even easier to incorporate LSL into your experiments. You can use LSL in addition to hardware triggers or even instead of hardware triggers, for example if you want to record event information where the use of hardware triggers is not possible, or if you want to avoid having to use extra cables.

Previously, it was only possible to read inputs to the TriggerBox via USB to the computer from the 8-bit input, using a 100 Hz polling rate. Now, all the inputs (including all of the BNCs and the fiber-optic connector (FOC)) can be configured as readable. Another upgrade is that this new reading process is now interrupt-driven, resulting in delays of under 1 ms. Therefore, it is now much easier to read responses from participants into your stimulus presentation computer, or to record signals from other devices, such as MRI-scanners.

LSL Output

Brain Products has always been a supporter of LSL. You can download LSL connectors for all our current amplifiers on our own GitHub page, we provide a free LSL viewer on our website, and we share our knowledge on how LSL integrates with our solutions (e.g., “LSL markers versus hardware triggers“, “Hyperscanning with LSL“, “A complete data processing pipeline using LSL“, or “LSL markers and hardware triggers in stimulus presentation software tools“).

Up to now, you had to decide between either using TriggerBox or using LSL. With the new TriggerBox Plus, it is possible to use the TriggerBox Plus for only hardware triggers as before, hardware triggers and LSL together, or  LSL only. You have the choice: simply keep on using the TriggerBox Plus the way you are used to, try the new LSL function, or completely switch over to LSL. You don’t even have to be concerned about potential performance issues: LSL markers are created by the TriggerBox Plus within under 1 ms. By adding this alternative means of creating event markers, it is also no longer necessary to connect the TriggerBox to an amplifier. This means the use of the TriggerBox Plus is no longer tied to an actual amplifier that has a hardware input for receiving triggers.

The LSL markers that are created mirror the output that would normally go to the amplifier. The output to the amplifier consists of a 16-bit code. The full 16 bits are only used for amplifiers of the BrainAmp family, our other amplifiers only use the lower 8 bits. The LSL output can be configured to send only the lower 8 bits or the full 16 bits. Either way, the LSL marker is an integer value based on the binary code that is transformed to a decimal number. Depending on the configuration, it either ranges between ‘0–255’ or between ‘0–65535’.

The LSL stream containing these markers can be processed (e.g., visualized or recorded) by up to 12 clients simultaneously. The only requirement is that the TriggerBox Plus and the client are in the same local network. This network can either be cable-based or wireless. In fact, the TriggerBox Plus offers a lot of different configurations. All these configurations can now be easily managed from a new software, the Configuration tool, which is installed together with an upgraded version of the TriggerBox Test IO.

Configuration Tool

TriggerBox Plus streams any trigger via LSL

Figure 1: Configuration tool with default settings for the TriggerBox Plus.

The Configuration tool lets you make use of all the new features. If you do not touch it, the TriggerBox Plus behaves just like the TriggerBox (revision 2) you may already know. There are only some exceptions that may affect your experience when using the TriggerBox Plus default settings.

Differences between TriggerBox Plus (default settings) and TriggerBox revision 2:

  • When using a stimulus presentation tool, the baud rate is no longer irrelevant: instead, it is now necessary to set the baud rate to 2.000.000 bps. Don’t hesitate to ask if you have any questions regarding a specific software solution.

  • Read-in functionality is generalized in that it now reads from any 8–15 bits including the dedicated In 15 inputs.

  • Input In 8–15 is now read at the Amp output stage, no longer directly at the input. The consequence is that the bit stretcher’s effect can now be observed for Bit 15.

  • The default setting for the network is to use ethernet with the TriggerBox Plus as the DHCP server. A client can directly connect to the TriggerBox Plus via the new LAN output. In this scenario, the TriggerBox Plus will provide an IP address within its own subnet. LSL markers will only use the lower 8 bits.

Changing the default settings:

Of course, you are encouraged to change the settings, so they suit your needs best. With the TriggerBox Plus, you can either use ethernet or Wi-Fi for providing the LSL marker stream. When using ethernet, a cable must be connected to the new LAN output on the bottom of the TriggerBox Plus. You can configure the TriggerBox Plus as a DHCP server or client or give it a fixed static IP. When using Wi-Fi, the TriggerBox Plus can either connect to an access point or become one by itself. Please be aware that the TriggerBox Plus only supports 2.4 GHz networks.

Apart from the network settings, there are two more important changes that can be configured:

  • The Bit settings for LSL: as already mentioned, it is possible to use only the lower 8 bits, or the full 16 bits. Usually, the lower 8 bits are easier to understand and directly reflect the 8-bit codes that are sent from a stimulus presentation software. However, it is possible to include higher bits, for example, when using the Bit 15 input, or when connecting to a BrainAmp. Just keep in mind that open bits are typically counted as high, therefore resulting in large integer values.
  • The Bit settings for reading to the computer via USB: when setting this option to “Use bits 0–7”, it is possible to directly read the inputs from the BNC inputs (In 0 to In 7) or from the LPT input (PC 0–7).

The new TriggerBox Test IO

TriggerBox Plus streams any trigger via LSL

Figure 2: The new TriggerBox Test IO.

The new Test IO software works with both the TriggerBox (revision 2) and the TriggerBox Plus.

The name of the connected device is displayed in the software next to the respective COM port. If a TriggerBox Plus is connected, the In Bits can either be 0–7 or 8–15, depending on the settings in the Configuration tool.

Conclusion

With the new TriggerBox Plus it is now even more convenient to incorporate LSL and Brain Products solutions together in your experiments. It also makes the TriggerBox Plus much more attractive as an input device because the reading functionality is no longer limited to one single D-Sub connector but instead can be used for all inputs. Combined with the increased speed based on interrupts, we believe that the TriggerBox Plus can be the go-to event synchronization device in many more scenarios.

Please let us know what you think or tell us about how you are using or planning to use the TriggerBox Plus in your lab. We are always curious to learn from you and are happy to receive any kind of feedback.

Want to know more? … Get in touch!