Polhemus digitizer connection abstraction. More...
#include "../utils_global.h"#include "fastrak_parser.h"#include <QObject>#include <QQuaternion>#include <QSerialPort>#include <QSerialPortInfo>#include <QString>#include <QStringList>#include <QTimer>#include <QVector3D>

Go to the source code of this file.
Classes | |
| struct | UTILSLIB::PolhemusSerialConfig |
| Settings used to open a real Polhemus serial connection. More... | |
| class | UTILSLIB::PolhemusConnection |
| Polhemus digitizer connection (mock + serial-port backends). More... | |
Namespaces | |
| namespace | UTILSLIB |
| Shared utilities (I/O helpers, spectral analysis, layout management, warp algorithms). | |
Polhemus digitizer connection abstraction.
SPDX-License-Identifier: BSD-3-Clause Copyright (c) 2026 MNE-CPP Authors
Two backends share one signal interface:
1. **Mock** — emits a scripted sweep over a 10 cm sphere
every @c kMockTickIntervalMs. Always available so apps
and tests run on machines without a real digitizer.
2. **Fastrak / FastSCAN** — opens a `QSerialPort`, sends
the continuous-output command, and decodes the ASCII
record stream via @ref FastrakParser.
Backend selection is implicit: an empty @c portName picks
mock; a non-empty name picks the hardware backend.
@ref autoDetectPortName scans @ref availablePorts for a
likely Fastrak (FTDI USB-serial) and returns it, so the UI
can offer a one-click "connect" without asking the user to
type a device path.
Definition in file polhemus_connection.h.