Biomedical Research

Journal Banner

A new brain-computer interface system using the gaze on rotating vane.

Masoud Maleki*, Temel Kayikcioglu
Department of Electrical and Electronics Engineering, Faculty of Engineering, Karadeniz Technical University, Turkey
Corresponding Author: Masoud Maleki, Karadeniz Technical University Faculty of Engineering Department of Electrical and Electronics Engineering 61080 Trabzon/Turkey
Accepted December 08, 2015
Visit for more related articles at Biomedical Research


A brain-computer interface (BCI) is a device that enables direct communication between humans and computers by analyzing neural signals and transforming them into digital signals. A new braincomputer interface system based on the gaze on rotating vane-dependent EEG signal is presented. Classification of EEG signals is done in three sessions: 1-when vane rotates fast and slow in an anticlockwise manner, 2-when vane rotates slow in a clockwise and rotates fast in an anti-clockwise manner, 3-when vane rotates slow in a clockwise and rotates slow in an anti-clockwise manner. The features are extracted from the 1-sec epoch of the EEG using Fast Fourier Transform (FFT). We use k-nearest neighbor (k_NN) algorithm to classify these features. The proposed method is also applied to 2-sec, 3- sec, and 4-sec epochs. All the signals are obtained at department of electrical and electronics engineering, Karadeniz Technical University, from 8 healthy human subjects in age groups between 20 and 32 years old. The proposed algorithm is efficient in the classification phase, with the obtained accuracy of 56-94% for eight subjects in 1-sec epochs. The results show that the proposed BCI system is very fast and accurate.


Braincomputer interface; Classification; Electroencephalography; Feature extraction; Fast Fourier transform; k-nearest neighbor algorithm


A brain-computer interface (BCI) obtains a straight connection pathway between the brain of a physically disabled patient and an external device or computer. The first aim of BCI research is to create a non-muscular way for physically disabled patients to communicate with and control an external device such as a spelling system for speech or writing a letter. In the past few decades, BCI systems have been rapidly developed, because they may be the only possible way of communication for people who are unable to communicate via conventional means because of severe motor disabilities. Electroencephalography (EEG) signals in the field of biomedical engineering are often used in BCI systems.
Although BCI development is a very young research area, in the literature, many methods based on BCI have been proposed. In a recent study, researchers used EEG to control an electronic device [1]. This paper presented the classification of a three-class mental task-based brain–computer interface (BCI) that used the Hilbert–Huang transform for the feature extractor and fuzzy particle swarm optimization by cross-mutated-based artificial neural network for the classifier. These three relevant mental tasks for wheelchair control were letter composing, arithmetic, and Rubik's cube rolling forward that meant left, right, and forward commands to wheelchair, respectively. The monitoring of eye movement could help patients communicate with their environment and control devices. A number of techniques have been used to discern eye movements [2-4]. In a recent research, Abdelkader et al. proposed a simple algorithm for the offline recognition of four directions of eye movement from electroencephalographic signals [5]. A strategy without a prior model was used to distinguish the four cardinal directions and a single trial was used to make a decision. The proposed algorithm in this paper was efficient in the classification phase with the obtained accuracy of 50-85% for twenty subjects. Oddball paradigms were used in BCI to generate event-related potentials (ERPs), like the P300 wave, on the targets selected by the user. A P300 speller was based on this principle, in which the detection of P300 waves allowed the user to write characters. A new method for the detection of P300 waves was presented by Hubert et al. [6], which was based on a convolutional neural network (CNN). The topology of the method was adapted to the detection of P300 waves in the time domain. Bin He et al. developed a sensorimotor rhythm EEG-based BCI and aimed to improve BCI systems by inversely mapping scalp-recorded EEG signals to the cortical source domain, integrate BCI with noninvasive neuromodulation strategies to improve learning, and incorporate mind-body awareness training to enhance BCI learning and performance [7]. Given these issues, the end goal had still not reached by these algorithms. There is much work to be done to produce real-world-worthy systems that can be comfortably, conveniently, and reliably used by individuals. On the other side, many of these methods are computationally complex and the classification accuracy measured using EEG is only between 50% and 80%.
In this paper, a new fast and simple brain-computer interface system based on the gaze on rotating vane-dependent EEG signals was presented. Speed and simplicity in BCI systems are very important factors. This study is a beginning step to design and implement a new, fast, simple, and accurate BCI system. The proposed method can be used for a biomedical engineering application to control an electronic device, like an electronic wheelchair, a robotic arm, etc. Clinically, physicians could become aware of the subject's state using this method.
The organization of this paper is as follows: after the introduction section, the experimental setup is provided. Then, feature extraction and classification are described, respectively. In the fifth section, the results are provided. The conclusion and discussions are given in the sixth section.

Experimental Setup

EEG signals were obtained from 8 healthy human subjects (5 males and 3 females) in the age groups between 25 and 32 years old at Department of Electrical and Electronics Engineering, Karadeniz Technical University. Figure 1 shows the experiment framework and tools. All the subjects reported normal or corrected-to-normal vision. Before beginning to record, the subjects were asked to calm down and relax in a chair for 5 min. The chair was placed 1 m in front of the monitor, as shown in Figure 1. Using Matlab 2014a, a red rotating vane in a black screen was designed. In the center of the screen, the letter of ‘A’ was written in white. The vane rotated on the letter of ‘A’. Speed and direction of the rotation could be controlled. Two rotation speeds were defined: one rotation per 5 sec (called slow rotating) and one rotation per 1 sec (called fast rotating). Screenshot of the rotating vane is shown in Figure 2.
In this study, the EEG signals were acquired by Brain Quick EEG System (Micromed, Italy). The EEG signals were sampled at 512 Hz and filtered between 0.1 and 120 Hz. To eliminate line noise, a 50 Hz notch filter was used. The electrodes were used on the scalp in different locations based on the international 10-20 system. Twelve EEG electrodes from all lobes of the brain were located according to this system as shown in Figure 3 and referenced to the electrode Cz. These electrodes included Fp1, Fp2, F7, F3, F4, C3, C4, T3, T4, P3, P4, and O1. EEG recording was in three sessions. In the first session, each subject gazed at the clockwise rotating vane at slow speed for 4 min. There was a 2-min gap for relaxation. Afterwards, the subject was asked to gaze the anticlockwise rotating vane at fast speed for 4 min and, after 2 min of relaxation, in the third session, the subject gazed at the anticlockwise rotating vane at slow speed for 4 min. To synchronize, the subject received a beep sound and, at the same time, the vane began to rotate. In these three sessions, the generated signals (separately for each channel) were divided into 1 sec epochs. In this way, 240*3 epochs (240 epochs for each speed) were generated per subject. Epochs of each session were divided into two groups. The first group was called training set (which contained 120 epochs) and the second group was called testing set (which contained 120 epochs). Also, the proposed method was tested on 2-sec, 3-sec, and 4- sec epochs. Collection of the data set is described in Table 1.

Feature Extraction

Fast fourier transform (FFT)
The Fourier transform is a method to convert time domain signals into frequency domain that is defined as Equation 1. Discrete Fourier Transform (DFT) converts discrete-time sequences into discrete-frequency versions, which is derived by Equation 2. DFT of discrete-time signals and is widely used for spectrum analysis.
where in Equation 1, x(t) is the time domain signal and X(f) is its Fourier Transform; in Equation 2, x is the input sequence, X is its DFT, and n is the number of samples [8]. The FFT is an optimized implementation of a DFT, because DFT is computationally very intensive in theory [9].
In this study, the generated epochs were used for extracting features. As is known, there are 5 frequency rhythms in EEG signals: delta-band (0-4 Hz with 75 micro volt _Amplitude), theta-band (4-7 Hz with 50_75 micro volt _Amplitude), alphaband (8-12 Hz with 20_60 micro volt _ Amplitude), beta-band (13-49 Hz with 2_20 micro volt_ Amplitude), and gammaband (30-49 Hz with 20_60 micro volt _ Amplitude) [10]. These bands were extracted by fast Fourier transform (FFT) method. In this paper, we used fft( ) function in Matlab for the detection of EEG signal bands. Mean of absolute power of FFT in each epoch was used as features. In this way, for each epoch in one channel, 5 features were extracted and, as mentioned, 12 channels were used. So, 60 (12*5) features were prepared for each epoch.

Classification procedure

An algorithm that has to be trained with labelled training samples to be able to distinguish new unlabelled samples between a fixed set of classes is called a classifier. In this study, k-NN algorithm was used to classify the extracted features from EEG signals. A summary of this algorithm is given below:

k-NN Algorithm

k-NN is one of the easiest algorithms for implementation among the existing classification algorithms. First, in this algorithm, the number of the nearest neighbour to the unknown sample must be determined. Euclidean distance method is commonly used to calculate the nearest neighbours to the sample. Then, the label that is maximum between these neighbours is diagnosed and the unknown sample is labelled with its maximum label. In binary classification problems, it is beneficial to use odd numbers for k, because they do not cause any problems for researchers while deciding upon a label [10].
In this study, to determine optimum k value, K-fold cross validation (K-FCV) technique was used. Minimum number of epochs in the training set for each speed was 40 (for 4-sec epochs); so, the optimum k value was searched in the interval between 1 and 39 with the step size of 2.


In this paper, we classified the pairwise of three sessions (as mentioned above). For each subject, we separately trained k- NN classifier. To verify the results, classification was repeated 10 times in each data set with different distributions of training and testing sets. The classification result (CR) was defined as the percentage of the number of epochs classified correctly over the size of the testing set. Mean of the classification results and standard deviations for 1-sec, 2-sec, 3-sec, and 4- sec epochs, when vane rotated fast and when it rotated slow in clockwise way, are provided as Table 2. Table 3 shows the classification results when vane rotated fast and slow in anticlockwise way. Finally, the result of classification, when vane rotated slow in clockwise and slow in anti-clockwise ways, are presented in Table 4.

Conclusion and Discussion

BCI is a kind of communication system that enables the control of devices or communication with others only through the brain's signal activities without using motor activities. This paper presented a novel approach for brain-computer interface systems. A simple algorithm was developed for the offline identification of rotating vane from EEG signals without any training phase. The results of this paper showed that EEG signals in during gaze on the vane with different speeds and directions have significant information. The proposed algorithm was promising for real-time applications.
In the future, we would like to design a suitable BCI system based on rotating vanes. Reduction channels to make the user more comfortable and using different methods for feature extraction and classification will be pursued in our future works. The goal is non-invasive, asynchronous, fast, and simple BCI system based on EEG, because a BCI system with these properties is very suitable for practical machine control, inexpensive, and potentially portable. We hope the proposed algorithm could be used for the real-time control of an electronic device, a wheelchair, or a robotic arm.


  1. R Chai, SH Ling, P Hunter, Y Tran, Nguyen HT. Brain-Computer Interface Classifier for Wheelchair Commands Using Neural Network With Fuzzy Particle Swarm Optimization, IEEE Journal Of Biomedical And Health Informatıcs 2014; 18: 5.
  2. Q Ji, H Wechsler, AT Duchowski, M Flickner. Special issue: eye detection and tracking. Comput Vis Image Underst 2005; 98: 1-3.
  3. SKawato, N Tetsutani. Detection and tracking of eyes for gaze-camera control. Image Vis Comput 2004; 22: 1031-1038.
  4. J Kim. A simple pupil-independent method for recording eye movements in rodents using video J Neurosci Methods 2004; 138: 165-171.
  5. N Abdelkader H Hideaki, Y Natsue, S Duk, K Yasuharu. Classification of Four Eye Directions from EEG Signals for Eye-Movement-Based Communication Systems. Journal of Medical and Biological Engineering 2014.
  6. C Hubert, G Axel. Convolutional Neural Networks for P300 Detection with Application to Brain-Computer Interfaces. IEEE Transactions on Pattern Analysıs and Machine Intelligence 2011; 33: 3.
  7. B He, B Baxter, BJ Edelman, Ch C Cline, Ye WW. Noninvasive Brain-Computer Interfaces Based on Sensorimotor Rhythms. Proceedings of the IEEE 2015; 103: 6.
  8. Oppenheim AV, Schafer RW. Discrete-Time Signal Processing, Prentice-Hall, 1989; p. 611-619.
  9. CS Burrus, TW Perks. DFT/FFT and Convolution Algorithms. Wiley Interscience, New York, 1985.
  10. Temel K, Masoud M, Kubra E. Fast and accurate PLS-based classification of EEG sleep using single channel data. Expert Systems with Applications 2015; 42: 7825-7830.