book collections email follower instructable user
Picture of Controlling Lights With Your Eyes
Screen Shot 2017-05-22 at 11.42.06 PM.png

This semester in college, I took a class called Instrumentation in Biomedicine in which I learned the basics of signal processing for medical applications. For the class's final project, my team worked on EOG (electrooculography) technology. Essentially, electrodes attached to someone's temples send a voltage difference (based on the corneo-retinal dipole) to a circuit designed to filter and amplify the signal. The signal is fed to an ADC (analog-to-digital converter - in my case, the ADC of an Arduino Uno) and used to change the colors of a neopixel jewel.

This tutorial is a way for me to record what I've learned, and also share with the regular reader how signals are isolated from the human body (so be warned: it's full of extra detail!). This circuit can actually be used, with a few minor alterations, to motor hearts' electrical impulses as an EKG waveform, and much more! While it's certainly nowhere near as advanced and perfected as machines you'd find in a hospital, this eye-position-controlled lamp is great for an initial understanding and glimpse.

Note: I'm no expert in signal processing so if there are any errors or if you have suggestions for improvements, please let me know! I still have much to learn so commentary is appreciated. Also, many of the papers that I reference in links throughout this tutorial require academic access that I have courtesy of my university; apologies in advance for those who won't have access.

Step 1: Materials

  • protoboard
  • resistors (100, 1k, 10k, 33k, 1M + 0.5M)
  • capacitor (0.1uF)
  • instrumentation amp (INA111 in my case, but there's a couple that should work relatively fine)
  • op amp (any - I happened to have an LM324N)
  • neopixel (any works, but I used a jewel)
  • 9V batteries x2
  • 9V battery headers x2
  • solid gel electrodes (electrode selection is discussed in step 5)
  • potentiometer
  • insulated wire
  • wire strippers
  • soldering iron + solder
  • alligator clips (with wires attached - solder some on if necessary)
  • hot glue (to stabilize wires that would be bent back and forth)
  • Arduino (pretty much board any works, but I used an Arduino Uno)

HIGHLY RECOMMEND: oscilloscope, multimeter, and function generator. Probe your outputs rather than just relying on my resistor values!

when you make a voltage divider instead of 3.3 volt where you connect the output of voltage divider
PinkyPie802 years ago

I love it! Is there a video too?

watchmeflyy (author)  PinkyPie802 years ago

There's a video at the bottom of the intro, and alternatively here's a link to two videos: one is a video in which you can see the waveforms on an oscilloscope, and the other video is of the actual light changes (my partner will say a color, and I'll look in the direction that color corresponds to). Enjoy!

Thanks!

IbrahimB312 years ago

Great! keep it on ^^

watchmeflyy (author)  IbrahimB312 years ago

Thank you!

virpimt2 years ago

Absolutely
mindblowing! This is so awesome! Thank You for sharing this knowledge. I voted
You for the Lights and Untouchable Challenge. You really deserve to win :)

watchmeflyy (author)  virpimt2 years ago

Thank you for your kind comments!

jammy12 years ago

wow

watchmeflyy (author)  jammy12 years ago

:)

WolfxPac2 years ago
I couldn't find the electrodes and the ones sold online are too expensive and they don't sell pieces.
can I use something else as a replacement??

Pretty much any gel electrodes will work just fine, you are not looking for precision here (not with these components and ADC). So your safe bet is to buy cheapest available, as long as they are AgCl-based. At least in our experiments with EMG, we found no significant difference in noise before we made much more complicated schematics with 16-bit ADC

watchmeflyy (author)  WolfxPac2 years ago

Hmm.. Electrodes do only coming in huge packs so it's inevitable that you'll have to shell out a bit to get them. You can buy cheaper electrodes like the aliexpress link, but just be warned that you do sacrifice quality. I got my pack of 100 pieces for about $30 dollars, so $0.30 each.

Maybe search in Aliexpres for "gel electrode pads" ( http://s.click.aliexpress.com/e/Rzn2Vvr ) I don't really know if they have the same electrical charactics as the mentioned in the article, but are pretty low cost

PDegrave2 years ago

Very good
work, indeed and well documented.

Suggestion
: in order to get a very high rejection of 60 Hz noise, you can use a sample
rate of a multiple of 16.67 ms (1/60 Hz). Then, if you include in the program a
delay corresponding to a loop time of 16.67 ms, you get a rejection of 60Hz noise.

watchmeflyy (author)  PDegrave2 years ago

Ah, thank you for the suggestion... Sorry if I'm missing something though, but, if you sample at 60Hz, wouldn't that result in aliasing of that 60Hz interference? And what is the delay's purpose?

Hi ! See my answer in the included image.
I am not very familiar with the image upload process. I hope it works.
Best regards.

You're amazing.

watchmeflyy (author)  HardlyHumanFX2 years ago

Ah shucks, thank you :)

Wow! a lot of scientific info underneath! Probably will work with gel pad electrodes like this ( http://s.click.aliexpress.com/e/Rzn2Vvr ) ?

Thanks for your comment!

TheThinker2 years ago
Vote button is not working otherwise would have voted! Nice work!
watchmeflyy (author)  TheThinker2 years ago

Glad you enjoyed this!

grebemic2 years ago

Pretty cool