# Conceptual Design of BCI for Mobile Robot Control
## 4 Discussion  
One of the research issues addressed in this work was the design of a BCI system and its implementation in mobile robot control. For this aim, the conceptual model of the BCI system was developed at the conceptual design phase first, and concrete construction of the BCI system including BCI control system were implemented at the detailed design phase after that. The BCI control system was designed to fulfil the control modes of mobile robot being controlled. Another research problem addressed in the work was the use of biological signal processing algorithms that would allow the extraction of characteristic parameters from the electroencephalographic signal that could be used to control the brain-computer interfaces. The main attention was paid to the analysis and detection of the characteristic parameters of Steady-State Visual Evoked Potentials (SSVEP) [10], generated in the brain by stimulation of the retina with a light stimulus at a frequency above 6 Hz. The development of the system using the characteristic parameters of the electroencephalographic signal to control the selected output device was preceded by experiments aimed at selecting the best light stimulus dedicated to BCI systems. When designing a new BCI control system, it was important to use the Model-Based Design (MBD) methodology of HS, i.e., design using systems models. This methodology is based on the implementation of each sub-system that is a part of the new system of higher level, using models built in the MATLAB/Simulink software. By preparing the object model, one can simulate the entire control system and check how it affects the objects before the construction of the prototype. The main advantage of the MBD methodology of HS is that the hierarchical connections between particular components of the designed system are strictly defined at the modeling stage of the conceptual and detailed design phases. After verifying the correctness of the system operation, using the automatic code generation tools available in the MATLAB (MATLAB Coder, Simulink Coder, Embedded Coder) package, one can implement the control algorithm on the target device. Control of the executive element in the designed BCI system was carried out based on the state machine, which was implemented in the MATLAB 2014a/Simulink environment. As part of the aforementioned Simulink environment, Stateflow module was used for modeling and simulation of event-controlled systems with finite state machines. The main advantage of the Stateflow module is the availability of linguistic elements; hierarchy; and deterministic executive semantics that allow to describe complex logic in a natural, understandable and legible way. In addition, Stateflow module has got the following advantages: (a) application of flow diagram notations and state changes on one diagram, traditional C language syntax with input and output arguments; (b) description of the operation of the finite machine proposed by [PERSON] [15], enabling the representation of the hierarchy; (c) parallel operation and history within the states; (d) scheduling state changes using time operators; and (e) equipping with an integrated debugger that allows viewing data step-by-step through the subsequent stages of the model. BCI system implementation requires a control system development that will meet the relevant requirements. The most important element of the designed BCI control system is the MainController unit, which contains the entire logic necessary to control BCI sub-systems, i.e., TruStan 24 electroencephalograph, a light stimulator and a mobile robot. The development of a BCI system using the characteristic parameters of the electroencephalographic signal to control the mobile robot allowed formulation of the following conclusions.