Inspiration

A few weeks ago, when I was cramming for my quarterlies I learned a valuable lesson. Cramming doesn't work. I kept thinking about how I could have studied better, and I came to the conclusion that I needed to study more efficiently. I played around with some strategies, but I got frustrated with the fact that the only way I would know how well I studied was by getting my grades back. I decided that I needed some data driven, instant, feedback on the efficiency of my studying. By using EEG to calculate how well I am concentrating, I can get concrete feedback on the quality of my study sessions.

What it does

Our project uses the headset from a simple Mind Flex toy. The headset, although it may seem simple, actually has a NeuroWave chip built into it. The silicon in it is equivalent to that found in high end medical EEG sensors, except for the fact that it is loaded with custom firmware. We hacked this headset by "wire tapping" the serial data lines it uses to communicate with the game, and sent the data to an Arduino which compiled the mess of data into a numerical value of 10 independent EEG channels. These channels, such as alpha, beta, theta, and delta can be used to see electrical activity in the brain. Activity in some parts could mean that the person is blinking, or sleeping, but we wanted the channel which indicated attention and relaxation. This data is compiled into a graph which represents each channel and the amount of activity at the frequency. This data can be used or compiled to optimize quality of education.

How we built it

In order to build it we took apart an old Mindflex headset and used it's electrical components to obtain the EEG data. We found the board which actually got the EEG data and found the serial data lines which were wirelessly broadcasted to the game. We "wiretapped" these lines with an Arduino and wrote a firmware that interpreted the mess of raw data from the headset into a easily interpretable array of data organized by the frequency of the signals. These signals which are sent to the computer let us put them into a graphic software which visualy represents the data.

Challenges we ran into

With the first headset we actually let the "magic smoke" out. (AKA I shorted it and something caught on fire). We also had some trouble with converting the jumble of computer code (ASCII) into the different channels. The main challenge we overcame was making sure that all the devices were running at the same frequency and were ready to recognize the communication protocols that we were using. Additionally we found out that our communication cable was too short to comfortably wear the headset, so I got an old cable and took it apart and then reconnected the two to make an extra long cable (we had to make our own USB cable). We attempted to utilize Bluetooth to minimize bulk and maximize safety, but the dongle we used ran on an incompatible baud frequency. As a result, we had to get rid of it and use a wire instead.

Accomplishments that we're proud of

-We hacked a cheap <$80 (including entire game) headset to have similar function to a $500+ headset -We got the Arduino to compile the jumble of data into a readable string of data -We integrated everything so that it could be controlled through an Arduino UNO, rather than a MEGA by using software serial ports (emulated serial ports) -The marority of processing is done inside the firmare (which we wrote) in the arduino.

What we learned

-Time is money during a hackathon -Things are never as easy as you thought -The different baud rates are not compatible with each other (9600 does not work with 57600) -If you don't tell the Arduino what to expect you will probably just get random letters -DON'T leave the headset plugged in while uploading firmware to the Arduino -unplug everything from the Arduino before uploading -1000 gain opamps kill batteries -A FTDI adapter is the same thing as a TTL adapter -Blinking serial LED means data is begin sent -There is a intentional delay on the LED -...like 50 more things that I dont have time to list

What's next for Using Electroencephalography for Quantitative feedback

-Finish the app that we planned to write to analyze the data -Integrate a Bluetooth serial transmitter into the system (the baud rate on our dongle was incorrect) -Integrate a sleep alert which detects when eyes are closed an certain frequencies are present

Built With

Share this project:

Updates