Dart and Flutter tools for Lab Streaming Layer
(LSL) and XDF recordings:
the liblsl bindings, a pure-Dart XDF reader and writer, and LSL Viewer, an
XDF file viewer and LSL stream viewer for desktop, Android and the web.
- Open XDF files (LabRecorder recordings) of any size, one tab per stream, in the browser (read locally, never uploaded) or on the desktop.
- View live LSL streams with filters, re-referencing, power spectra, signal quality and trigger decoding.
- Record LSL streams to XDF, and replay XDF recordings as LSL streams.
- Share LSL over the network: a WebSocket bridge and relay, so browsers can view and publish streams, and streams can cross networks multicast doesn't reach.
- OpenBCI Cyton and serial devices, including over WebSerial in the browser.
Open the web app ·
Downloads for Windows, macOS, Linux and Android
(lsl_viewer <version> releases; desktop archives include the lsl command
line tool) · Website ·
Bridge and relay setup guide ·
Source
| Package | What it is |
|---|---|
| liblsl |
Dart/Flutter bindings for liblsl, with full parity with the C library (JOSS paper) |
| xdf |
Read and write XDF files in pure Dart (all platforms, including the web); pyxdf's algorithms, tested against pyxdf |
| signal_core |
Format-agnostic multichannel signal engine (summary pyramids, filters) behind the viewer and xdf |
| lsl_tools | Record to XDF, the WebSocket bridge/relay, test outlets, and the lsl command line tool |
| lsl_viewer | The LSL Viewer app, built from signal_viewer and its _lsl, _xdf and _serial source providers |
| liblsl_test | Integration tests to try liblsl with Flutter on any platform |
| liblsl_timing / liblsl_analysis | Multi-device latency, sync and timing tests, and their analysis |
| peer_coordinator, liblsl_coordinator, webrtc_coordinator | Coordinating experiments across devices (LSL, WebSocket hub, WebRTC) |
You're most likely interested in the liblsl package, which is the main package for liblsl.dart. You can find installation instructions and usage examples in the README of that package. API documentation, and the Dart package are available on pub.dev: https://pub.dev/packages/liblsl.
This is a monorepo managed with melos and fvm. To get started, clone this repository including submodules:
git clone --recurse-submodulesInstall fvm, then run:
cd liblsl.dart
fvm dart pub getThere are some helpful melos commands for working with the monorepo:
fvm exec melos run <script>: run a script defined in themelosscriptssection of the rootpubspec.yamlacross all packages. For example,melos run formatrunsdart format .in all packages.fvm exec melos run lint:all: rundart analyzeanddart formatfor all packages, and fail if there are any warnings or formatting issues.fvm exec melos run test: rundart testfor all packages.
The lint and test scripts at the very least should be run before pushing any changes. For more scripts available, see the pubspec.yaml file.
See the CONTRIBUTING.md file for guidelines on how to contribute to this project.
This project and everyone participating in it must uphold Code of Conduct. By participating, you are expected to uphold this code.
Please see the SUPPORT.md file for information on how to get support for liblsl.dart and where to ask questions or discuss potential features.
Please see the SECURITY.md file for information on how to report security vulnerabilities for liblsl.dart.
This project is licensed under the MIT License - see the LICENSE file for details.