EOG-Controlled Video Game

Eyes as Interface

There’s much be to learned about how electronics can interact with biological signals—not only to record, but also to see how they can be used as inputs for control applications. With ongoing research in fields such as virtual reality and prosthetics, new systems are being developed to interpret different types of signals for practical applications. Learn how these three Cornell graduates use electrooculography (EOG) to control a simple video game by measuring eye movements.

By Eric Cole, Evan Mok and Alex Huang

The human eye naturally acts as a dipole, in which the retina at the back of the eye is negatively charged, and the cornea at the front of the eye is positively charged. EOG is a recording technique that measures this potential difference, and can be used to

Figure 1
Electrode placement for recording. An Ag-AgCl (silver-silver chloride) electrode was placed at each of the labeled points. Points A and B record the EOG signal for the right and left eyes, and point C provides a ground reference.

quantify eye movement [1]. A typical electrode placement pattern for EOG is shown in Figure 1. Each of the electrodes A and B records a voltage related to eye movement, and an electrode at point C serves as a ground reference.

When a user looks left, the cornea is close to electrode B and it records a positive voltage, while the retina is closer to electrode A, yielding a negative voltage. Similarly, looking right produces a negative voltage at B and a positive voltage at A. The difference between VB and VA relative to ground at C changes monotonically with gaze direction, and can be reliably used to model horizontal eye movement.

System Overview

The system we designed uses eye movements to play a video game on a display screen. Electrodes are placed on a player’s head to record only the horizontal EOG signal as shown in Figure 2. This signal is then filtered and amplified via an analog circuit and sent to an ADC on a Microchip Technology PIC32 microcontroller (MCU) (Figure 3). The PIC32 MCU stores the reading as a digital value and uses it to control a cursor on an LCD display screen. A program on the PIC32 continually displays obstacles that move across the screen, and the player moves his or her eyes to control the cursor and avoid obstacles.

Figure 2
Characterization of EOG signal. An example signal output is shown for a gain of approximately 885.

Figure 3
System overview. “Eye recording” is accomplished with the raw electrode signal.

This system is entirely powered without connection to an AC power source, instead using a 9 V battery to provide power for amplification and a chargeable power source to power the PIC32. This choice of a power source was important, because it enforces necessary safety considerations for biomedical recording. Connecting a high voltage source to a human user and accidentally completing a circuit path to AC ground could result in serious injury, so great care was taken to use battery power for this project.

A secondary oscilloscope program was also necessarily designed to satisfy a key safety need: The ability to view the recorded EOG signal and test the recording hardware while the circuit is isolated. A normal oscilloscope cannot be used for this purpose for the reasons stated earlier. Care was also taken to apply and fasten the electrodes properly before every session.

Recording and Application

Three Ag-AgCl (silver-silver chloride) electrodes are placed around the eyes using a skin-safe adhesive gel—one beside each eye, and one on the forehead as a ground reference—at points A, B, and C respectively, in Figure 1. These electrodes provide the gateway between the biological signal and the digital world, detecting the voltage generated by ions at the skin surface and transducing it into an equivalent electron-based signal.

This voltage is generated directly at the eye, and has some attenuation through the skin surface. A typical magnitude of the raw EOG signal is several millivolts. The voltage readings from the two eye electrodes are sent to a Texas Instruments (TI) INA121 differential amplifier, which amplifies the difference between the two input signals. This yields a negative or positive voltage based on direction of eye movement. The INA121 provides low noise, a high common-mode rejection ratio, and is suitable for the high-input impedance requirement associated with recording biological signals. Figure 4 shows the full schematic of the implementation.

A second amplification stage using a TI LM358-based balanced subtractor configuration provides further amplification. This stage reduces the DC voltage component output from the differential amplifier, while further amplifying the difference to a range of 0 to 3.3 V—the scale allowed by the PIC32 MCU’s on-chip ADC. The resulting signal is a voltage centered at approximately 1.6 V when the user looks straight, with about a 1 V increase or decrease when the user looks left or right, respectively. …

Read the full article in the July 348 issue of Circuit Cellar
(Full article word count: 3023 words; Figure count: 6 Figures.)

Don’t miss out on upcoming issues of Circuit Cellar. Subscribe today!

Note: We’ve made the October 2017 issue of Circuit Cellar available as a free sample issue. In it, you’ll find a rich variety of the kinds of articles and information that exemplify a typical issue of the current magazine.