# Brain-Computer Interfaces by Electrical Cortex Activity: Challenges in Creating a Cognitive System for Mobile Devices Using Steady-State Visually Evoked Potentials

Pedro Morais, Carla Quintão, Pedro Vieira

► To cite this version:

Pedro Morais, Carla Quintão, Pedro Vieira. Brain-Computer Interfaces by Electrical Cortex Activity: Challenges in Creating a Cognitive System for Mobile Devices Using Steady-State Visually Evoked Potentials. 7th Doctoral Conference on Computing, Electrical and Industrial Systems (DoCEIS), Apr 2016, Costa de Caparica, Portugal. pp.135-141, 10.1007/978-3-319-31165-4_14 . hal-01438237

HAL Id: hal-01438237

https://inria.hal.science/hal-01438237

Submitted on 17 Jan 2017

**HAL** is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
# Brain-Computer Interfaces by Electrical Cortex Activity: Challenges in Creating a Cognitive System for Mobile Devices using Steady-State Visually Evoked Potentials

Pedro Morais¹,²,³, Carla Quintão²,³, Pedro Vieira²,³

¹ Biomedical Engineering Doctoral Program

² Department of Physics,
Faculty of Sciences and Technology, Universidade NOVA de Lisboa, Portugal

³ Laboratory for Instrumentation, Biomedical Engineering and Radiation Physics
jpe.morais@campus.fct.unl.pt, {cmquintao,pmv}@fct.unl.pt

**Abstract.** The research field of *Brain-Computer Interfaces* (BCI) emerged in an attempt to enable communication between paralyzed patients and technology. Identifying an individual's mental state, through his brain's electric activity, a typical BCI system assigns to it a particular action in the computer. It is known that when the visual cortex is stimulated with a certain frequency, it shows activity with the same frequency. This *Steady-State Visually Evoked Potential* (SSVEP) activity can be used to achieve the aforementioned communication goal. In this work, we first analyze the spontaneous electrical activity of the brain, to distinguish two mental states (concentration/meditation). Then, following an SSVEP type of approach, we divide the stimulating screen in four areas, each of which flickering at a distinct frequency. By observing the responding frequency from the occipital lobe of the subject, we can then estimate the 2 bit decision he made. We observe that such a setup is efficient for real time BCI, and can be easily integrated in mobile devices. Besides, the user is able to change voluntarily her/his decisions, interacting with the system in a natural manner.

**Keywords:** BCI, EEG, SSVEP, Mobile Device, Tablet, Smartphone

## 1 Introduction

A biomedical cognitive control system must be able to interpret the electrical signals produced in our brain and distinguish different levels of activity. There have been various approaches taken in this area, such as event-related desynchronization and synchronization (ERD/ERS) [1], evoked potentials with latency of 300 ms (P300) [2,3] and visual evoked potentials in stationary mode (SSVEP) [4,5]. The ERD/ERS engaged in the study of alpha and beta waves, characterized by frequency between 8 Hz and 12 Hz and 12 Hz to 30 Hz, respectively, which can be observed, for example, during an imagination task motion. P300 in an evoked potential with a latency of about 300 ms, which appears after a visual or auditory stimulus that requires attention and cause some surprise. SSVEP are elicited by retinal stimulation with a signal
whose frequency can vary between 3.5 Hz and 75 Hz and consist of a continuous and periodic signal detected in the visual cortex with the same frequencies [6]. The publications in this area are many and varied, ranging from the presentation of tools to control different devices, to new technological solutions. Among the applications that resulted from the above described techniques, we highlight some technological advances such as: 1. Activation of a mobile robot using a BCI [7], wherein a robot is controlled through four imagined movement (foot, tongue, left arm and right arm) using ERD/ERS; 2. Application of dried EEG sensors to mobile BCIs [8], which are placed on the hair, and exhibit very similar results to traditional sensors that use saline solution or conductive gel for electrical contact; 3. Construction of a simple communication system using SSVEP based on BCI [9] where a user gives answers like "yes", "no", "good", "bad"; 4. Creation of an online BCI using static visual evoked potential [10] where through one EEG channel the user can write a word and perform a search on Google; 5. Characterization of stimuli based on P300 amplitude [11], wherein the study shows that there are several factors which influence the potential analyzed, for example, the effect of motivation as possible physiological influence on the amplitude P300 and, finally; 6. Development of a mobile phone based on BCI for communication on a day-to-day [12] through SSVEP stimulation.

In this context it is rather evident the importance of a transversal knowledge between neuroscience and computer science to reach new insights in BCI area, solving problems related to the acquisition, storage and retrieval of brain information, as well as creating new approaches to identify different actions on the same interface.

This work aims to answer the question: "How to develop a solution where an user can interact with mobile devices naturally changing voluntarily their mental task?". We propose a system consisting of two specific phases: First, the detection of an individual's state of concentration and second, the selection of the action to be taken through SSVEP after confirming the previous condition. To fulfill the first phase, the spontaneous electroencephalographic (EEG) signals were classified based on the traditional band frequency analysis (alpha band, between 8 to 13 Hz and beta band, between 13 and 30 Hz) [13,14]. In the second phase, the SSVEP permit to distinguish between at least 4 different actions that the subject would like to performed.

## 2 Relationship to Cyber-Physical Systems

A cyber-physical system (CPS) comprises the junction of computing elements with nature physical processes. This approach provides the development of more specific applications such as process control, instrumentation, medical devices and smart structures. In the coming age of *internet of everything*, the development of this type of system contributes to a new era of products where everyone will be connected everywhere. To reach such solution is necessary a flexible architecture with new interfaces. The research for user-friendly interfaces is increasing and one of the aims will be to replace keyboard and mouse computers for more effective means of communication. The use of touch screens, commonly available in tablets and smartphones, is a clear example of this demand. The project described in this paper presents a system that establishes the connection between machines and humans using
brain-computer interfaces (BCI) / Electroencephalography (EEG). The EEG is used as a non-invasive electrophysiological monitoring approach to identifying behavior patterns of brain electrical activity, while BCIs promote a direct communication channel between the brain and an electronic device. Using brain electrical activity recorded at scalp level enables intelligent monitoring systems in real-time. The use of sensory channels becomes a new form of input in addition to providing information about the status and user intent. Using this type of information, systems can adapt dynamically contributing to the task that one wants to run. To develop new solutions in this field, it is essential to understand how the brain works and manages the information. Referring to EEG and other biological signals such as electrocardiography (ECG) and electromyography (EMG), opens up a new form of communication between humans and electronic devices. This approach presents several challenges such as the efficiency of embedded systems, the implementation of algorithms using brain electrical impulses and distribution architectures that add autonomy to the devices and increase the efficiency to the communication mechanisms. At the end, this solution must have a high degree of robustness, and should enable connection to the cloud, not confined to the local control devices.

# 3 Materials and Methods

To answer the challenges in creating this BCI solution it is used the EPOC equipment [15] to record the EEG signals. The system comprises 14 channels (AF3, F7, F3, FC5, T7, P7, O1, O2, P8, T8, FC6, F4, F8, AF4) and two reference electrodes located in P3 and P4 channels (Common Mode Sense active electrode and Driven Right Leg passive electrode - CMS/DRL). The device records the signals sequentially with a rate of 128 Hz, with a resolution of 14 bits per channel and have a frequency response between 0.16 and 43 Hz. In addition, it provides wireless data transmission using a frequency of 2.4 GHz, with a battery allowing for 8 hours of continuous work. One of the greatest facilities of this device is the use of saline solution electrodes instead of the common conductive gel to establish the contact between the electrodes and the scalp. The acquisition control and the complete signal classification process were performed by two software platforms: *OpenVibe* and *EEGLAB*. The *OpenVibe* is an open source application, multi-platform, containing various pre-programmed modules for signal processing. In parallel, the *EEGlab*, a *Matlab* toolbox for EEG and event related potentials processing, is also used, being necessary to install the plug-in acquisition *BIOSIG* data for reading data in GDF format (*General Data Format*) [16].

## 3.1 Acquisition Protocol for Classification of the Mental State

The signals from the 14 channels are recorded while the subject is seated with a straight posture with the palms on the knees, avoiding any muscular movement. A complete test lasts a total of five minutes. The subject is asked to switch from one mental state (meditation) to the other (concentration), every 30 seconds, being notified with a beep. In meditation he should get away from any thought focusing his
attention on the breath which should be long and deep. For the state of concentration
he should countdown of 3 in 3 from 100, while he visualizes the results.

## 3.2 Signal Processing and Classification

A band pass analog filter from 0.16 Hz to 85 Hz, together with a 50 Hz notch filter, is applied to the signals. Since the meditation/concentration detection states is the main purpose of this phase of the project, we focalized our analysis on the prefrontal cortex electrodes (AF3, AF4), relating with attention activities [17] and in occipital electrodes (O1, O2), where the alpha rhythm, which measure the level of arousal of the subject, is particularly intense.

We used the *OpenVibe* application to implement the following steps: 1. The electrodes are selected; 2. A 4^th^ order *Butterworth* digital band pass filter between the alpha band frequencies (8-12Hz) is applied to the signals; 3. The signal is sub-divided into various time windows lasting 5 seconds with an overlap of 4.9 seconds; 4. The power spectral density is computed; 5. A moving average is applied.

The identification of meditation and concentration states was performed by real-time signal acquisition using the following criteria: if the alpha band spectrum in AF3 electrode is below a certain threshold (in our arbitrary units this threshold is 20) then the state will be classified as “concentration”, else, the state will be classified as "meditation". If the alpha band spectrum exceeds the value 80 the corresponding EEG epoch is considered an artifact.

## 3.3 Choosing Actions using SSVEP

In a second stage, after checking the "concentrate" state, it is necessary to identify an action by means of SSVEP. To fulfill this objective it is presented to the subject a screen divided into four areas, each one with an image formed by a black/white checkerboard that oscillates at a predefined frequency. The subject option is identified depending on the area/image where the subject focuses its attention.

The stimulation is made using the Psychophysics version 3, a Matlab toolbox, which allows imposing frequencies at 8.6 Hz, 10 Hz, 12 Hz and 15 Hz to the screen. The detection of the frequency emitted by the different screen areas is performed through the analysis of the power spectrum obtained from the electrodes O1 and O2, located in primary visual areas in the occipital lobe. This process allows the recognition of the action to be taken in a natural way.

In this stage the signals were filtered using a 4^th^ order Butterworth digital band pass filter between 8-30 Hz, which comprises the alpha and beta bands. Once again, the analysis was performed on windows during 5 seconds with an overlap of 4.9 seconds. Finally, the spectrogram of those signals is generated and the results were compared with the frequencies of the visual stimuli in order to identify the action that should be taken.
# 4 Results

## 4.1 Meditation/Concentration

The states identification of meditation and concentration which corresponds to the 1st phase of the project was performed by real-time signal acquisition. One example is shown next, for electrodes AF3 and O1 [Figure 1].

<figure><img src="image_2.png" /><figcaption>Fig. 1. – Results of a 5 minutes essay in which the subject is switching from the meditation to concentration stage. Each state lasts 30 seconds starting with meditation. The graph represents the amplitude of the alpha waves in O1 and AF3 electrodes.</figcaption></figure>

As expected, during the concentration periods the alpha activity decreases substantially to values that rarely exceed the value 20 (arbitrary units). It should be noted in this example that the two peaks seen in between 30.0-60.0 and 150.0-180.0 observed in O1 electrode, it is a state deconcentration unscheduled during the visual imagination of the subtraction results. Analyzing the values obtained, there is a clear distinction between the two states meditation/concentration, both on the front and occipital zone, although in the latter the difference is more pronounced.

These results demonstrate that it is possible to search and identify patterns of brain activity consistent with the classification of this information in real time.

## 4.2 SSVEP Results

After completing the 1st stage of the process, with the concentration state identification, it follows the 2nd phase results, corresponding to the choice of the action using SSVEP. The results obtained in the spectrogram show a clear
identification of the 8.6 Hz, 10 Hz, 12 Hz and 15 Hz frequencies [Figure 2] (the ones
at which the four areas of the screen flick).

<figure><img src="image_3.png" /><figcaption>**Fig. 2.** – Spectrogram with frequencies 8.6 Hz, 10 Hz, 12 Hz and 15 Hz identification using the electrodes O1 and O2 during the SSVEP stimulation.</figcaption></figure>

It was also realized that the checkerboard images in which the oscillating
frequencies were applied, should be dispersed in the screen away from each other as
much as possible. Besides, it is expected that the use of preset options will provide
faster responses, compared to description of the desire. Taking an example of
someone who wants to quench his thirst, using a grid with the image of a glass of
water as one of the default options, will save significant time compared to writing this
same intention.

**5 Conclusions**

The junction of the identification of a concentrated state with SSVEP will allow the implementation of a hybrid system with high accuracy. BCI approach allows the user to change voluntarily their mental task interacting with the system naturally. This work aims to contribute to the development of an autonomous system which allows monitoring in real-time mobile devices from the electrical brain activity. Associated with this application are the interfaces that will interact with the user. The flickering stimuli using checkerboard images can be replaced with icons that identify the user's intent with a clear differentiation of the actions to be taken. At the same time it should be evaluate the disruption that may be caused by peripheral vision of a concentrated individual, in order to remove this undesirable activity from the signal. We also believe that the use of higher frequencies will provoke a decreasing in visual fatigue caused by the oscillation of the image, making the system more comfortable. The presented approach should be tested in a statistical significant number of individuals to identify more precisely the degree of accuracy of the results.
## References

1. F.H. Lopes da Silva, G. Pfurtscheller, Event-Related Desynchronization. Handbook of Electroencephalogr and Clinical Neurophysiology, Revised Edition, 6Elsevier, Amsterdam (1999), pp. 51–65.

2. Fazel-rezai, R, Abhari, K, & Region-based, A. speller for brain-computer interface. Can J. Electr. Comput. Eng. (2009), 300.

3. E. Sellers, Y. Arbel, and E. Donchin, “BCIs that uses P300 event-related potentials,” in Brain-Computer Interfaces: Principles and Practice, J. Wolpaw and E. W. Wolpaw, Eds., Oxford University Press, 2012.

4. B. Allison, J. Faller, and C. H. Neuper, “BCIs that use steady-state visual evoked potentials or slow cortical potentials,” in Brain-Computer Interfaces: Principles and Practice, Wolpaw and E. W. Wolpaw, Eds., Oxford University Press, 2012.

5. Silberstein, R. B. Steady state visually evoked potential (SSVEP) topography in a graded working memory task. International journal of psychophysiology (2001).

6. Pastor M, Artieda J, Arbizu J, Valencia M, Masdeu J (2003) Human cerebral activation during steady-state visual-evoked responses. Journal of Neuroscience 23(37): 621–627.

7. A. O. G. Barbosa, D. R. Achanccaray, and M. A. Meggiolaro, "Activation of a mobile robot through a brain computer interface," 2010 IEEE International Conference on Robotics and Automation, pp. 4815-4821.

8. Y. M. Chi, Y.-t. Wang, Y. Wang, C. Maier, T.-p. Jung, G. Cauwenberghs, Y.-T. Wang, and T.-P. Jung, "Dry and noncontact EEG sensors for mobile brain-computer interfaces," IEEE transactions on neural systems and rehabilitation engineering: a publication of the IEEE Engineering in Medicine and Biology Society, vol. 20, p. 228, 2011.

9. G. Sanchez, P. F. Diez, E. Avila, and E. L. Leber, "Simple communication using a SSVEP-based BCI," Journal of Physics: Conference Series, vol. 332, p. 012017, 2011.

10. T. Liu, L. Goldberg, S. Gao, and B. Hong, "An online brain-computer interface using non-flashing visual evoked potentials," Journal of Neural Engineering, vol. 7, p. 036003, doi:10.1088/1741-2560/7/3/036003, 2010.

11. S. C. Kleih, F. Nijboer, S. Halder, and A. Kübler, "Motivation modulates the P300 amplitude during brain–computer interface use," Clinical Neurophysiology, vol. 121, pp. 1023-1031, 2010.

12. Y.-t. Wang, Y. Wang, T.-p. Jung, Y.-T. Wang, and T.-P. Jung, "A cell-phone-based brain-computer interface for communication in daily life," Journal of Neural Engineering, vol. 8, p. 025018, doi:10/1088/1741-2560/8/2/025018, 2010.

13. Fisch B, Spehlmann R. Fisch and Spehlmann's EEG Primer. 3rd ed. Amsterdam: Elsevier; 1999.

14. Niedermeyer E, Lopes da Silva F. Electroencephalography: Basic Principles, Clinical Applications, and Related Fields. 5th ed. Baltimore: Williams & Wilkins; 1993.

15. Emotiv - EPOC neuroheadset, June 2012, http://emotiv.com/store/hardware/epoc bci/epoc-neuroheadset/.

16. A. Schlogl, O. Filz, H. Ramoser, G. Pfurtscheller, GDF - A general dataformat for biosignals, Technical Report, 2004.
138 P. Morais et al.

17. Rebollo, M. A. & Montiel; Atención y funciones ejecutivas. Revista de Neurología, 42 (Supl 2), S3-7, 2006.