As I mentioned before, the guys at frontiernerds have done an excellent job at explaining how to perform this hack and of how to interface the Mind flex headset to the Arduino and graphing the output using Processing (which I did and worked fantastically!), so I will only go through the steps of getting the data to display on the mini monitor. (If you are familiar with processing, I recommend you try their project. It's really interesting!)



OK. Lets Start:



Initial software test to make sure your mind Flex is talking to the Arduino: Run the example BrainSerialOut sketch.



Note: You will not need the Mini display for this test, and if you have it connected nothing will display on it yet.



1.- You will need to download and install the Brain Library from the frontiernerds web site.Decompress the zip file and drag the "Brain" folder to the Arduino's "libraries" folder inside your sketch folder. Restart the Arduino IDE.



You should now be able to see the library and examples in select File > Examples > Brain > BrainSerialOut sketch.



If you were successful at installing the libraries, and loading the BrainSerialOut sketch, Click on the verify button to compile the sketch and make sure there are no errors.



It's time to connect your Arduino to your PC using the USB cable, and click on the upload button to upload the sketch to the Arduino.



Plug the two wires that you put in the Mind flex headset to the Arduino: the T signal wire from the mind flex to the rx pin in the Arduino; The ground wire from the Mind flex headset to the Arduino gnd pin.



Once the sketch is uploaded to the Arduino, make sure your Mind flex headset is connected to the Arduino, and turn it on. Open the serial monitor.You should see a stream of coma separated numbers scrolling by.



NOTE:

If the sketch doesn't upload and you get a message like the one below,



avrdude: stk500_getsync(): not in sync: resp=0x00



Disconnect the wire from the arduino rx pin, it sometimes interferes with the upload process.



Note that the connection to the Neurosky headset is half-duplex — it will use up the rx pin on your Arduino, but you will still be able to send data back to a PC via USB. (Although in this case you won't be able to send data to the Arduino from the PC.)



once disconnected click on the upload button again and, if successful, reconnect the wire to the rx pin.



If you got the serial data stream showing up an the serial monitor, you are ready to go to the next step.





