P300: Basic P300 Speller demo

  • NB: Document updated for OpenViBE 1.2.0 (doc updated 20.may.2016).

This document describes the most basic OpenViBE P300 demo scenario. For better spelling accuracy, you may be interested in the XDAWN version of the P300 Speller.

Using the speller

The set of scenarios described here implements the P300 Speller BCI using only the OpenViBE Designer. You will find it in share/openvibe/scenarios/bci-examples/p300-speller. P300 is a well-known pattern in the brainwaves, a positive peak that occurs 300 ms after a relatively rare but expected event. The Speller application flashes randomly a grid of letter, and the user is instructed to focus on the letter (s)he wants to spell out. After some repetitions, a vote determines which letter the BCI system selects.

1. Acquisition setup
To use the P300 speller, first have the headset set up on the subject with a proper electrode configuration. Then, run the Acquisition Server and start the data acquisition. With the P300 as implemented by these scenarios, it may be beneficial to disable the drift correction in the acquisition server settings.

2. Running the scenarios
Then, execute the following three scenarios in order. The first two scenarios are needed to train a classifier that detects the P300 event.

  • p300-speller-1-acquisition.xml: First step is to acquire some data in order to train the LDA classifier that will detect the P300 brainwaves. The default training session is made of 10 trials. Each time the user is instructed to focus on a particular letter (instruction in blue). After 12 repetitions (12 flashes of each row and column, so 24 flashes for each letter on the grid) we move on to the next letter. Change the Lua Stimulator settings to configure the number of letter, the timings, the colors, etc.
  • p300-speller-2-train-classifier.xml: This scenario trains a LDA classifier that try to discriminate the two classes : P300 or not.
  • p300-speller-3-online.xml: This scenario allows the user to spell some text. (S)He can choose to spell the designated letters (in blue) or any other letter. However it is advised to follow the instructions as a well-formed online session can be used to train again the classifier if the results are not good enough. After the 12 repetitions, the system displays the letter it chose as the best candidate (in green). Change the Lua Stimulator settings to configure the number of letter, the timings, the colors, etc.

Note:In the training scenario, remember to change the Generic Stream Reader box to read from the file you recorded in the previous step.


Fig.1 The P300 Speller.

Some design notes

Starting from OpenViBE 1.2.0, the P300 scenarios rely on TCP Tagging. With this mechanism, the P300 Speller Visualization box sends the flash event markers directly to the Acquisition Server. This approach should allow improved time accuracy in the marker placement into the EEG stream, and subsequently improved spelling accuracy. Note that currently in order to use this, the Acquisition Server must be running on the same computer as Designer.

This entry was posted in Example scenarios and tagged , . Bookmark the permalink.