State Matrix

What's that?

Each Bpod trial is programmed as a virtual finite state machine. This ensures precise timing of events - for any state machine you program, state transitions will be completed in less than 100 microseconds - so inefficient coding won't reduce the precision of events in your data.

Introduction to the Bpod state machine

  • Each state describes Bpod's outputs (Valves, LEDs, BNC channels, wire terminals, serial ports, etc.).

  • Events detected by Bpod's inputs can be set to trigger transitions between specific states.

Here is a simple finite state machine, describing a binary switch that controls a bulb with variable brightness: