Running Custom Presentation

This tutorial shows how to integerate a custom presentation module (such as the custom presentation module made in the Simple Presentation Tutorial), with the rest of the BCI run with the online_bci.py module. By the end of this tutorial you will know: * How to start the mindaffectBCI without automatically starting a presentation module * How to run your presentation module * How to cleanly shutdown the mindaffetBCI when you finish

Before running this tutorial you should have read how an evoked bci works and run through the Simple Presentation Tutorial to understand how to build a custom presentation module.

[ ]:
# Import the mindaffectBCI decoder and other required modules.
%load_ext autoreload
%autoreload 2
%gui qt
import mindaffectBCI.online_bci

Start the EEG processing components

That is start the; 1) Hub, 2) Acquisation, 3) Decoder - by starting the online_bci script with presentation disabled.

For more information on these components and why we need them please consult the Quickstart Tutorial

[ ]:
# load the config-file to use.  Here we use the default noisetag config file:
config = mindaffectBCI.online_bci.load_config("noisetag_bci")

Set the Presentation system to None and then start the online_bci.

[ ]:
config['presentation']=None
#uncomment the following line to use to the fakedata acquisition
config['acquisition']='fakedata'
mindaffectBCI.online_bci.run(**config)

Check all is running correctly.

[ ]:
mindaffectBCI.online_bci.check_is_running()

Run the Custom Presentation

We run our custom presentation module by first importing and then running it.

[ ]:
# import and run the presentation
from mindaffectBCI.examples.presentation import minimal_presentation

Shutdown the decoder

[ ]:
mindaffectBCI.online_bci.shutdown()