Typing causes a bunch of EEG noises too

[EDIT 2015-04-29]: So I ran a few tests with my dad and had him wiggle his fingers and do typing
without a computer screen. Turns out that after inspecting the waveforms with dad typing,
the OpenBCI picked up on the difference between typing that has an emotional connection to
it and normal typing. I noticed this after I asked dad to think angry, sad, and happy thoughts
and noticed similar waveforms to the ones I saw when I was typing while doing my normal computer activities.

As the title says, apparently typing a lot causes EEG signals to trigger. The initial
plan was to lazily tag my mood while I was browsing the internet, coding, or doing art
using the application that I wrote to live tag it so extracting the relevant data snippets
for each mood would be easy. It turns out that this plan would fail fantastically since
typing generates a lot of EEG noise. Even after the bandpass filter limiting the frequencies
to the beta and gamma frequencies using the GUI (since I wanted to test first with the GUi
to check if the connections were snug), there was a lot of activity in that range
when I started typing. This'd make grabbing the test data for the emotions hard even though
most of the activity is sedentary.

LED Color Palette Draft

Sat down and started whipping up a palette for the robot's LEDs and ran it through
Visicheck to get a rough idea of how the palettes would look to color-blind people. The negative states are clearly
differentiable, but the positive emotions and the "I don't know" indicator isn't.

You can see the gallery here.

Crunchtime!

We give our presentation during the Natural Sciences Academic Festival in just under two weeks and the semester is coming to a close soon after. That means we're kicking our project development into top gear!

What have we been working on? Well our EEG headset is fully functional and capable of collecting data in realtime, but the trick is classifying incoming waveforms as emotional states from that incoming data. We're still trying to get that finalized.

The rover is fully operational and can perform a variety of different movements that can be placed in our database and selected by the artificial intelligence.

Finally, we need to get all of our devices happily talking to each other, which we're also still working on.

Hopefully our next update will include some nice results, wish us luck!

Troubles with the OpenBCI Python library only when used outside of the demo program

[EDIT]: Since Monday (2015-04-20), we've been able to implement the bug fix that the OpenBCI
developers have told us in the forum thread when we asked about why our program wouldn't write
to a *.tsv file even when the board was on. The reason why it wouldn't is that we forgot to
do the init sequence that the
demo program included with the OpenBCI python library was doing before it ran any of the
plugins.

Unfortunately, the project seems to drift farther and farther away even though
we're sure of the algorithms we will use to implement our robot. There's a draft EEG waveform processor that will most likely be using a bandpass filter in SciPy
to reduce as much noise as possible from the outside by limiting the data to
12.5 Hz to 30.0 Hz for the sensors that take EEG asymmetry into account for certain emotions (like sad
evoking beta waves primarily on the left and happy evoking beta waves primarily on the right). The other sensors will most likely read facial gestures to further narrow the idenitified emotion. Alternatively, more
complex classification trends can be found at an 10-20 function map.

While we're working out the EEG classification, we've also started drafting skeleton code for the
cart AI
making use of the EDB library to persistently store scores for action/response pairs. Currently the available actions for the robot haven't been merged into the main code yet.

However, the draft tool for quickly marking the OpenBCI board's data with emotion labels
is refusing to store any of the packets that're retrieved through the OpenBCI Python API.
This is troublesome because the draft classifier uses the same library as the small tool for manually marking
the data before we store those into a folder that can be easily copied into the Rubix A-10 board so the EEG classification data can be easily modified.
Additionally, working with the A-10 also allows us to not worry as much about RAM constraints for processing the data.

Currently, here's the terminal output for our program.

python2 manually_labeled_waveforms.py /dev/ttyUSB0 
@Connecting to /dev/ttyUSB0
@Serial established...
@ADS1299 Device ID: 0x3E
@LIS3DH Device ID: 0x33
@Free RAM: 447
@$$$
Warning: Warning: Unexpected END_BYTE found <97> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <109> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <32> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <116> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <105> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <109> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <101> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <100> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <32> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <111> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <117> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <116> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <13> instead of <192>,            discarted packet with id <79>
Warning: Warning: Unexpected END_BYTE found <10> instead of <192>,            discarted packet with id <79>

The @'d lines only occur if the board is turned on precisely when the program starts.
After this, the program would write a file that contained none of the packets it tried to pick up.

Compare this to the terminal output from the demonstration program that came with the library

$ python2 ../OpenBCI_Python/user.py -p /dev/ttyUSB0 --add csv_collect

            USER.py

------------SETTINGS-------------
Notch filtering: True

-------INSTANTIATING BOARD-------
Connecting to /dev/ttyUSB0
Serial established...
No daisy: 8 EEG channels and 3 AUX channels at 250.0 Hz.

------------PLUGINS--------------
Found plugins: [ print ] [ udp_server ] [ csv_collect ] [ streamer_tcp ] [ sample_rate ]

Activating [ csv_collect ] plugin...
Will export CSV to: 2015-4-18_19-40-21.csv
Plugin [ csv_collect ] added to the list
--------------INFO---------------
User serial interface enabled...
View command map at http://docs.openbci.com.
Type /start to run -- and /stop before issuing new commands afterwards.
Type /exit to exit. 
Board outputs are automatically printed as: 
%  <tab>  message
$$$ signals end of message

-------------BEGIN---------------

--> /start
Warning: Skipped 158 bytes before start found
�
--> Warning: Warning: Unexpected END_BYTE found <160> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <1> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <130> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <243> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <224> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <130> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <252> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <246> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <129> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <124> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <148> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <128> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <130> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <228> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <157> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <130> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <240> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <154> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <129> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <90> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <200> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <128> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>
Warning: Warning: Unexpected END_BYTE found <0> instead of <192>,            discarted packet with id <0>

--> /exit
Warning: Stopping streaming...
Wait for buffer to flush...
Warning: Closing Serial...
Deactivating Plugins...
Closing, CSV saved to: 2015-4-18_19-40-21.csv
User.py exiting...

$ ls
total 848K
428K 2015-4-18_14-15-19.csv  4.0K CHANGELOG.md     12K open_bci_v3.pyc      4.0K plugin_interface.pyc  8.0K README.md  4.0K TODO.md  4.0K waveform_classify.py
348K 2015-4-18_19-40-21.csv   16K open_bci_v3.py  4.0K plugin_interface.py  4.0K plugins/              4.0K scripts/   8.0K user.py

As the output of ls shows, the data is successfully written to the file with the program that came with the library.

Spring Semester - A whole bunch of TODOs

Spring semester's a month in and we hadn't updated the blog until now. Part of
this was due to needing to find a new meeting time to meet with our advisor,
polishing what we had for the cart, understanding how to denoise data using
the FFT transformation of said data, and thumbing through the source code for
the OpenBCI boards.

There a few things that we discovered about using the OpenBCI boards in our project:

  • We'd need to find a way to install the RFDuino library so the Arduino IDE
    can access it and properly program the dongle and the board.
  • We had to resort to stitching some vinyl onto some velcro to make applying the
    electrodes to ourselves a lot easier.
  • Our master plan of powering the OpenBCI dongle with 3V from the Arduino pin
    didn't work. However, using a cut USB female cord does work to power it.
  • At some point, we need to solder the headers for the OpenBCI boards.
  • We'd need to find a way to write the firmware for the dongle so it can still talk
    to the OpenBCI GUI when plugged in. We're planning to have the dongle talk to the OpenBCI
    board as a middle man so the rover can receive data from the board wirelessly. This
    will be done over a serial established with two of the free pins on the dongle.
  • If the FFT calculations prove to be too much for the OpenBCI dongle, OpenBCI board,
    or the Arduino driving the cart, then we might need to get specialized hardware to do
    the FFT calculations. Chances of this are pretty slim though since we have plenty of Arduinos.

Running the OpenBCI GUI

We recently just tested running the OpenBCI GUI according to the docs.

However, what the documentation neglected to mention is that if you run the binary
from the archive without changing into the directory where it and its libraries are held,
then you will get the following output on the console and a nonfunctional GUI:

The font "Raleway-SemiBold.otf" is missing or inaccessible, make sure the URL is valid or that the file has been added to your sketch and is readable.
The font "Raleway-Regular.otf" is missing or inaccessible, make sure the URL is valid or that the file has been added to your sketch and is readable.
The font "Raleway-SemiBold.otf" is missing or inaccessible, make sure the URL is valid or that the file has been added to your sketch and is readable.
ControlP5 2.2.2 infos, comments, questions at http://www.sojamo.de/libraries/controlP5
Exception in thread "Animation Thread" java.lang.RuntimeException: java.lang.NullPointerException
    at com.jogamp.common.util.awt.AWTEDTExecutor.invoke(AWTEDTExecutor.java:58)
    at jogamp.opengl.awt.AWTThreadingPlugin.invokeOnOpenGLThread(AWTThreadingPlugin.java:103)
    at jogamp.opengl.ThreadingImpl.invokeOnOpenGLThread(ThreadingImpl.java:206)
    at javax.media.opengl.Threading.invokeOnOpenGLThread(Threading.java:172)
    at javax.media.opengl.Threading.invoke(Threading.java:191)
    at javax.media.opengl.awt.GLCanvas.display(GLCanvas.java:541)
    at processing.opengl.PJOGL.requestDraw(PJOGL.java:688)
    at processing.opengl.PGraphicsOpenGL.requestDraw(PGraphicsOpenGL.java:1651)
    at processing.core.PApplet.run(PApplet.java:2256)
    at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.NullPointerException
    at controlP5.ControlFont.checkFontSize(Unknown Source)
    at controlP5.ControlFont.<init>(Unknown Source)
    at controlP5.Label.setFont(Unknown Source)
    at controlP5.Textfield.setFont(Unknown Source)
    at OpenBCI_GUI$DataLogBox.<init>(OpenBCI_GUI.java:2892)
    at OpenBCI_GUI$ControlPanel.<init>(OpenBCI_GUI.java:2445)
    at OpenBCI_GUI.setup(OpenBCI_GUI.java:281)
    at processing.core.PApplet.handleDraw(PApplet.java:2361)
    at processing.opengl.PJOGL$PGLListener.display(PJOGL.java:862)
    at jogamp.opengl.GLDrawableHelper.displayImpl(GLDrawableHelper.java:665)
    at jogamp.opengl.GLDrawableHelper.display(GLDrawableHelper.java:649)
    at javax.media.opengl.awt.GLCanvas$10.run(GLCanvas.java:1289)
    at jogamp.opengl.GLDrawableHelper.invokeGLImpl(GLDrawableHelper.java:1119)
    at jogamp.opengl.GLDrawableHelper.invokeGL(GLDrawableHelper.java:994)
    at javax.media.opengl.awt.GLCanvas$11.run(GLCanvas.java:1300)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:302)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:733)
    at java.awt.EventQueue.access$200(EventQueue.java:103)
    at java.awt.EventQueue$3.run(EventQueue.java:694)
    at java.awt.EventQueue$3.run(EventQueue.java:692)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:703)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
RESIZED
The font "Raleway-SemiBold.otf" is missing or inaccessible, make sure the URL is valid or that the file has been added to your sketch and is readable.
The font "Raleway-Regular.otf" is missing or inaccessible, make sure the URL is valid or that the file has been added to your sketch and is readable.
The font "Raleway-SemiBold.otf" is missing or inaccessible, make sure the URL is valid or that the file has been added to your sketch and is readable.
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
    at controlP5.ControlFont.checkFontSize(Unknown Source)
    at controlP5.ControlFont.<init>(Unknown Source)
    at controlP5.Label.setFont(Unknown Source)
    at controlP5.Textfield.setFont(Unknown Source)
    at OpenBCI_GUI$DataLogBox.<init>(OpenBCI_GUI.java:2892)
    at OpenBCI_GUI$ControlPanel.<init>(OpenBCI_GUI.java:2445)
    at OpenBCI_GUI.setup(OpenBCI_GUI.java:281)
    at processing.core.PApplet.handleDraw(PApplet.java:2361)
    at processing.opengl.PJOGL$PGLListener.display(PJOGL.java:862)
    at jogamp.opengl.GLDrawableHelper.displayImpl(GLDrawableHelper.java:665)
    at jogamp.opengl.GLDrawableHelper.display(GLDrawableHelper.java:649)
    at javax.media.opengl.awt.GLCanvas$10.run(GLCanvas.java:1289)
    at jogamp.opengl.GLDrawableHelper.invokeGLImpl(GLDrawableHelper.java:1119)
    at jogamp.opengl.GLDrawableHelper.invokeGL(GLDrawableHelper.java:994)
    at javax.media.opengl.awt.GLCanvas$11.run(GLCanvas.java:1300)
    at javax.media.opengl.Threading.invoke(Threading.java:193)
    at javax.media.opengl.awt.GLCanvas.display(GLCanvas.java:541)
    at javax.media.opengl.awt.GLCanvas.paint(GLCanvas.java:595)
    at sun.awt.RepaintArea.paintComponent(RepaintArea.java:264)
    at sun.awt.X11.XRepaintArea.paintComponent(XRepaintArea.java:73)
    at sun.awt.RepaintArea.paint(RepaintArea.java:240)
    at sun.awt.X11.XComponentPeer.handleEvent(XComponentPeer.java:591)
    at java.awt.Component.dispatchEventImpl(Component.java:4948)
    at java.awt.Component.dispatchEvent(Component.java:4698)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:735)
    at java.awt.EventQueue.access$200(EventQueue.java:103)
    at java.awt.EventQueue$3.run(EventQueue.java:694)
    at java.awt.EventQueue$3.run(EventQueue.java:692)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
    at java.awt.EventQueue$4.run(EventQueue.java:708)
    at java.awt.EventQueue$4.run(EventQueue.java:706)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:705)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
X11Util.Display: Shutdown (JVM shutdown: true, open (no close attempt): 1/1, reusable (open, marked uncloseable): 0, pending (open in creation order): 1)
X11Util: Open X11 Display Connections: 1
X11Util: Open[0]: NamedX11Display[:0, 0x7f79186a7620, refCount 1, unCloseable false]

After we ran it from the commandline in the directory where the executable was held,
we were able to run the GUI.

Communicating over Serial

Today we got a basic serial communication setup between our Arduino and a command line running through Linux. The code for the demo is available in our Hardware Demos GitHub repository. This is important for the project because it enables us to begin connecting the two main aspects of the project, the rover and the Emotiv EPOC headpiece. In the demo we pass RGB decimal values from the command line to the Arduino and it returns the corresponding hexadecimal color code.

Advisor Meeting 3

We met with our advisor from 10:20-11:00 and reported our progress. Here were the major points of the meeting:

Joan

  • Got a test app to compile against the Emotiv EPOC SDK
  • Still confused on how to layout the sequence diagrams, so I put those on Google Drive for the advisor to look at
  • Start working on a rudimentary AI
  • Start working on basic Arduino <-> Computer <-> "EPOC" communication while waiting for the device to come in
  • The manufacturers of the EPOC had a delay in receiving the parts they needed, so they're going to come at the end of the month

Drew

  • Got an LED demonstration program running on the device
  • Got the front two motors hooked up to the device
  • Still puzzled on where to hook up the back tow motors

Test EDK program mostly compiles so far

[EDIT]: It is now working! See this commit for how we did it.

While we were working on our homework, I decided to try writing a test program that would simply. A lot of the code is just copied from /opt/EmotivResearch_2.0.0.20/doc/examples_Qt/example1/main.cpp. The Makefile for the program was written from scratch. Here were the instructions I ran to compile it.

make clean
env LD_LIBRARY_PATH=/opt/EmotivResearch_2.0.0.20/lib make
env LD_LIBRARY_PATH=/opt/EmotivResearch_2.0.0.20/lib ./test-bin

Running the second of the former commands produces the following output:

g++ -g -I/opt/EmotivResearch_2.0.0.20/include -L/opt/EmotivResearch_2.0.0.20/lib -o test-bin main.c -L/opt/intel/composer_xe_2015.0.090/compiler/lib/intel64 -L/opt/intel/composer_xe_2015.0.090/mkl/lib/intel64 -lcryptopp_64 -ludev -lmkl_rt -liomp5 -lboost_serialization -lboost_system -lboost_regex -lboost_filesystem -lpng12 -lQtCore -lQtGui -ledk_utils_linux -ledk 
/usr/bin/ld: warning: libboost_serialization.so.1.51.0, needed by /opt/EmotivResearch_2.0.0.20/lib/libedk.so, may conflict with libboost_serialization.so.1.56.0
/usr/bin/ld: warning: libboost_system.so.1.51.0, needed by /opt/EmotivResearch_2.0.0.20/lib/libedk.so, may conflict with libboost_system.so.1.56.0
/usr/bin/ld: warning: libboost_regex.so.1.51.0, needed by /opt/EmotivResearch_2.0.0.20/lib/libedk.so, may conflict with libboost_regex.so.1.56.0
/usr/bin/ld: warning: libboost_filesystem.so.1.51.0, needed by /opt/EmotivResearch_2.0.0.20/lib/libedk.so, may conflict with libboost_filesystem.so.1.56.0

Running the second of the former commands with -lboost_md5 added to the list of link flags produces a peculiar error even though the *.so is in one of the -L'd directories

g++ -g -I/opt/EmotivResearch_2.0.0.20/include -L/opt/EmotivResearch_2.0.0.20/lib -o test-bin main.c -L/opt/intel/composer_xe_2015.0.090/compiler/lib/intel64 -L/opt/intel/composer_xe_2015.0.090/mkl/lib/intel64 -lcryptopp_64 -ludev -lmkl_rt -liomp5 -lboost_serialization -lboost_system -lboost_md5 -lboost_regex -lboost_filesystem -lpng12 -lQtCore -lQtGui -ledk_utils_linux -ledk 
/usr/bin/ld: cannot find -lboost_md5
collect2: error: ld returned 1 exit status
Makefile:7: recipe for target 'test-bin' failed
make: *** [test-bin] Error 1

However, ls -l /opt/EmotivResearch_2.0.0.20/lib shows the following output:

total 9.4M
104K -rwxrwxr-x 1  500  500 102K Oct 22 12:44 libboost_filesystem.so.1.51.0*
 12K -rwxrwxr-x 1  500  500  11K Oct 22 12:44 libboost_md5.so.1.51.0*
952K -rwxrwxr-x 1  500  500 950K Oct 22 12:44 libboost_regex.so.1.51.0*
464K -rwxrwxr-x 1  500  500 461K Oct 22 12:44 libboost_serialization.so.1.51.0*
 12K -rwxrwxr-x 1  500  500  12K Oct 22 12:44 libboost_system.so.1.51.0*
   0 lrwxrwxrwx 1  500  500   18 Jul 15  2013 libcryptopp_64.so -> libcryptopp.so.1.0*
   0 lrwxrwxrwx 1  500  500   17 Jul 15  2013 libcryptopp.so.1 -> libcryptopp_64.so*
4.8M -rwxr-xr-x 1  500  500 4.8M Oct 22 12:44 libcryptopp.so.1.0*
   0 lrwxrwxrwx 1  500  500   15 Jul 15  2013 libedk.so -> libedk.so.1.0.0*
   0 lrwxrwxrwx 1  500  500   15 Jul 15  2013 libedk.so.1 -> libedk.so.1.0.0*
   0 lrwxrwxrwx 1  500  500   15 Jul 15  2013 libedk.so.1.0 -> libedk.so.1.0.0*
3.1M -rwxrwxr-x 1  500  500 3.1M Oct 22 12:44 libedk.so.1.0.0*
4.0K -rwxrwxrwx 1  500  500 3.8K Oct 22 12:44 libedk_utils_linux.so*
   0 lrwxrwxrwx 1 root root   19 Oct 22 12:44 libqwt.so.5 -> /usr/lib/libqwt5.so*
   0 lrwxrwxrwx 1 root root   15 Oct 22 12:44 libudev.so.0 -> /lib/libudev.so*
   0 lrwxrwxrwx 1 root root   12 Oct 18 14:27 libudev.so.1 -> libudev.so.0*

I initially shrugged off the output warnings that ld gave me until I tried connecting the test program to the EmoComposer. It crashed because it couldn't find the reference to libboost_md5

GNU gdb (GDB) 7.8
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from env...(no debugging symbols found)...done.
(gdb) run LD_LIBRARY_PATH=/opt/EmotivResearch_2.0.0.20/lib ./test-bin
Starting program: /usr/bin/env LD_LIBRARY_PATH=/opt/EmotivResearch_2.0.0.20/lib ./test-bin
Got object file from memory but can't read symbols: File truncated.
warning: Could not load shared library symbols for linux-vdso.so.1.
Do you need "set solib-search-path" or "set sysroot"?
process 7092 is executing new program: /home/shadowkyogre/School/csce499a/test-proggy/test-bin
warning: Could not load shared library symbols for linux-vdso.so.1.
Do you need "set solib-search-path" or "set sysroot"?
warning: the debug information found in "/opt/intel/composer_xe_2015.0.090/compiler/lib/intel64/libiomp5.dbg" does not match "/opt/intel/composer_xe_2015.0.090/compiler/lib/intel64/libiomp5.so" (CRC mismatch).

[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
===================================================================
Example to show how to log the EmoState from EmoEngine/EmoComposer.
===================================================================
Press '1' to start and connect to the EmoEngine                    
Press '2' to connect to the EmoComposer                            
>> 2
[New Thread 0x7fffed887700 (LWP 7097)]
Start receiving EmoState! Press any key to stop logging...


Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffed887700 (LWP 7097)]
0x00007ffff4a214c7 in void EmoEventPackage::serialize<boost::archive::text_iarchive>(boost::archive::text_iarchive&, unsigned int) () from /opt/EmotivResearch_2.0.0.20/lib/libedk.so.1
(gdb) bt
#0  0x00007ffff4a214c7 in void EmoEventPackage::serialize<boost::archive::text_iarchive>(boost::archive::text_iarchive&, unsigned int) () from /opt/EmotivResearch_2.0.0.20/lib/libedk.so.1
#1  0x00007ffff6a221d5 in boost::archive::detail::basic_iarchive::load_object(void*, boost::archive::detail::basic_iserializer const&) () from /usr/lib/libboost_serialization.so.1.56.0
#2  0x00007ffff4a1ffd9 in void SerializedObjectConnection::handle_read_data<EmoEventPackage, boost::_bi::bind_t<void, boost::_mfi::mf1<void, RemoteEmoEventClient, boost::system::error_code const&>, boost::_bi::list2<boost::_bi::value<RemoteEmoEventClient*>, boost::arg<1> (*)()> > >(boost::system::error_code const&, EmoEventPackage&, boost::tuples::tuple<boost::_bi::bind_t<void, boost::_mfi::mf1<void, RemoteEmoEventClient, boost::system::error_code const&>, boost::_bi::list2<boost::_bi::value<RemoteEmoEventClient*>, boost::arg<1> (*)()> >, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type>) ()
   from /opt/EmotivResearch_2.0.0.20/lib/libedk.so.1
#3  0x00007ffff4a297c9 in boost::asio::detail::read_op<boost::asio::basic_stream_socket<boost::asio::ip::tcp, boost::asio::stream_socket_service<boost::asio::ip::tcp> >, boost::asio::mutable_buffers_1, boost::asio::detail::transfer_all_t, boost::_bi::bind_t<void, boost::_mfi::mf3<void, SerializedObjectConnection, boost::system::error_code const&, EmoEventPackage&, boost::tuples::tuple<boost::_bi::bind_t<void, boost::_mfi::mf1<void, RemoteEmoEventClient, boost::system::error_code const&>, boost::_bi::list2<boost::_bi::value<RemoteEmoEventClient*>, boost::arg<1> (*)()> >, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type> >, boost::_bi::list4<boost::_bi::value<SerializedObjectConnection*>, boost::arg<1> (*)(), boost::reference_wrapper<EmoEventPackage>, boost::_bi::value<boost::tuples::tuple<boost::_bi::bind_t<void, boost::_mfi::mf1<void, RemoteEmoEventClient, boost::system::error_code const&>, boost::_bi::list2<boost::_bi::value<RemoteEmoEventClient*>, boost::arg<1> (*)()> >, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type> > > > >::operator()(boost::system::error_code const&, unsigned long, int) () from /opt/EmotivResearch_2.0.0.20/lib/libedk.so.1
#4  0x00007ffff4a29e02 in boost::asio::detail::reactive_socket_recv_op<boost::asio::mutable_buffers_1, boost::asio::detail::read_op<boost::asio::basic_stream_socket<boost::asio::ip::tcp, boost::asio::stream_socket_service<boost::asio::ip::tcp> >, boost::asio::mutable_buffers_1, boost::asio::detail::transfer_all_t, boost::_bi::bind_t<void, boost::_mfi::mf3<void, SerializedObjectConnection, boost::system::error_code const&, EmoEventPackage&, boost::tuples::tuple<boost::_bi::bind_t<void, boost::_mfi::mf1<void, RemoteEmoEventClient, boost::system::error_code const&>, boost::_bi::list2<boost::_bi::value<RemoteEmoEventClient*>, boost::arg<1> (*)()> >, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type> >, boost::_bi::list4<boost::_bi::value<SerializedObjectConnection*>, boost::arg<1> (*)(), boost::reference_wrapper<EmoEventPackage>, boost::_bi::value<boost::tuples::tuple<boost::_bi::bind_t<void, boost::_mfi::mf1<void, RemoteEmoEventClient, boost::system::error_code const&>, boost::_bi::list2<boost::_bi::value<RemoteEmoEventClient*>, boost::arg<1> (*)()> >, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type> > > > > >::do_complete(boost::asio::detail::task_io_service*, boost::asio::detail::task_io_service_operation*, boost::system::error_code const&, unsigned long) () from /opt/EmotivResearch_2.0.0.20/lib/libedk.so.1
#5  0x00007ffff4a2ac3c in boost::asio::detail::task_io_service::run(boost::system::error_code&) () from /opt/EmotivResearch_2.0.0.20/lib/libedk.so.1
#6  0x00007ffff4a18094 in RemoteEmoEventClient::run() () from /opt/EmotivResearch_2.0.0.20/lib/libedk.so.1
#7  0x00007ffff4a084e9 in Emotiv::EmotivThreadProc(void*) () from /opt/EmotivResearch_2.0.0.20/lib/libedk.so.1
#8  0x00007ffff3a14314 in start_thread () from /usr/lib/libpthread.so.0
#9  0x00007ffff3d113ed in clone () from /usr/lib/libc.so.6
(gdb) quit
A debugging session is active.

    Inferior 1 [process 7092] will be killed.

Quit anyway? (y or n) y

At least we can still write a rudimentary AI while trying to figure out why g++ isn't picking up the libboost_md5 from the Emotiv SDK tarball.

Tested Arduino SDK

We were able to get the sample programs included in the arduino SDK to run on the arduino board we ordered. Check out the screenshots! We'll also probably upload the code to the project site later (even though it's just a modified version of Blink to see if phora could understand the calls that the program made).