Skip to content

Program Structure

Michelle Sands edited this page Nov 11, 2025 · 7 revisions

In This Section

Structure Overview

StimControl is a programmatically generated MATLAB app. It uses handle structs and similar data types to manage its connected features:

  • GUI features are managed in h
  • connected devices are managed in d
  • save paths are managed in ``path```
  • general protocol parameters are managed in g
  • trial-specific stimulation parameters are managed in p
  • the timer that manages experiment execution logic is stored in t
  • state machine flags are handled in f

The Execution State Machine

In the Session tab, state logic is handled jointly by a timer, t, the dependent variable status, and the flags struct f.

Clone this wiki locally