Quickstart¶
This quickstart guide is for using a single HackEEG board (8 channels), and assumes you are familiar with Arduino, Python, and OpenBCI. If not, please see HackEEG Software Installation.
Using a Laptop¶
HackEEG has been tested on macOS, Linux, and Windows 10. Windows 10 support is new, if you have problems, please contact the mailing list.
Install the Arduino IDE.
Launch the Arduino IDE. Use the Boards Manager (Tools > Port > Programming Port > Boards Manager, search for “Arduino Due”) to install the Arduino SAM Boards package for the Arduino Due.
Use the Library Manager (Sketch > Include Libraries > Manage Libraries) to install the ArduinoJson library (by Benoit Blanchon).
Clone the Arduino driver firmware located here: HackEEG Arduino driver
Use the Arduino IDE to compile the driver and upload it to the Arduino Due board.
Follow the software setup for the Python client: HackEEG Python client documentation
Install the Processing framework.
Install the fork of OpenBCI_GUI:
$ git clone https://github.com/adamfeuer/OpenBCI_GUI.git $ cd OpenBCI_GUI $ git checkout feature/lsl-input-and-clinical-eeg-bandpass-filter
Using Processing, open the
OpenBCI_GUI/OpenBCI_GUI
directory that you cloned above and run the sketch. The OpenBCI GUI should launch. Don’t try to connect to an LSL stream yet– the stream needs to be running before trying to connect to it.Using the USB A-to-micro cable, plug the laptop into the Arduino Due’s Native Port.
For a quick test to see if communication between the client and HackEEG board works, you can use the command line shell to blink the blue HackEEG board light. This will indicate whether the HackEEG is communicating with the laptop.
Activate the Python virtual environment:
$ pipenv shell
Start the HackEEG shell:
$ hackeeg_shell (hackeeg) blink Ok (hackeeg) version v0.3.0 Ok (hackeeg) exit $
The blue light on the HackEEG board should flash.
Streaming Data¶
To stream data from internal test signals, printing 2000 samples to the terminal– you will see the HackEEG blue board LED flash briefly before the data starts printing:
$ hackeeg_stream --channel-test --sps 500 --samples 2000
To stream data from internal test signals continuously and send via Lab Streaming Layer (LSL):
$ hackeeg_stream --channel-test --sps 500 --continuous --lsl
To stream data from internal test signals continuously and send via Lab Streaming Layer (LSL) without printing to the terminal:
$ hackeeg_stream --channel-test --sps 500 --continuous --lsl --quiet
To stream data continuously from electrode input at 500 samples per second (SPS) at 24x gain and send via Lab Streaming Layer (LSL) without printing to the terminal:
$ hackeeg_stream --sps 500 --gain 24 --continuous --lsl --quiet
OpenBCI¶
Start the HackEEG LSL stream:
$ hackeeg_stream --sps 500 --gain 24 --continuous --lsl --quiet
To display the stream’s data, select
Live (from Lab Streaming Layer)
from the System Control Panel dialog. Leave the channel setting at 8 (the other two don’t work on this branch). Click Start Session.You should see some status messages in the console as OpenBCI GUI finds the stream and connects to it.
Click Start Data Stream