Programming Howto:Building and Customizing BCI2000: Difference between revisions

From BCI2000 Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
(25 intermediate revisions by the same user not shown)
Line 1: Line 1:
==Install prerequisites==
This tutorial walks you through the process of obtaining the [[Programming_Reference:BCI2000_Source_Code|BCI2000 source distribution]], and using it to build and test your own custom [[BCI2000_Glossary#Filter|filters]], implemented in C++ inside your own custom [[BCI2000_Glossary#Core_Module|core module]]. It assumes that you have a good working knowledge of the C++ language,  and basic familiarity with the compiler/IDE that you are going to use.
===TortoiseSVN===
Download TortoiseSVN installer from [https://tortoisesvn.net tortoisesvn.net]


Run installer
This tutorial is a simplified version of the previous [[Programming Howto:Quickstart Guide]], which is slightly outdated but kept in the wiki as it contains valuable suggestions and exercises.


[[File:TortoiseSVN_2-1985.png|center]]
==Howto steps==
*[[Programming Howto:Install Prerequisites|Install Prerequisites]]
:shows you how to install TortoiseSVN, CMake, VisualStudio, and Qt.
*[[Programming Howto:Register with BCI2000 Project|Register with the BCI2000 Project]]
:explains how to obtain a BCI2000 user account.
*[[Programming Howto:Download the BCI2000 Sourcecode|Download the BCI2000 Sourcecode]]
:details the steps how to use TortoiseSVN to download the BCI2000 sourcecode.
*[[Programming Howto:Configure BCI2000 for Compilation|Configure BCI2000 for Compilation]]
:demonstrates how to use CMake to create a BCI2000 solution file.
*[[Programming Howto:Compile BCI2000|Compile BCI2000]]
:illustrates how to compile BCI2000 using VisualStudio.
*[[Programming Howto:Create a custom Signal Processing Module|Create a custom Signal Processing Module]]
:shows how to create a new BCI2000 module from a template.
*[[Programming Howto:Attach the Debugger to a BCI2000 Module|Attach the Debugger to a BCI2000 Module]]
:explains how to attach the VisualStudio debugger to a running module.
*[[Programming Howto:Programmatically wait for the Debugger in a BCI2000 Module|Programmatically wait for the Debugger in a BCI2000 Module]]
:explains how to halt execution of a BCI2000 module, and wait for the user to attach a debugger.
*[[Programming Howto:Deploy a Release version of a BCI2000 Module|Deploy a Release version of a BCI2000 Module]]
:demonstrates how to build a self-contained version of your new module.


Don't forget to install command line client tools
[[Category:Howto]]
 
[[File:TortoiseSVN_3-1990.png|center]]
 
 
[[File:TortoiseSVN_4-2001.png|center]]
 
===CMake===
Download CMake installer from [https://cmake.org cmake.org]
 
Run installer
 
[[File:CMake_2-2013.png|center]]
 
Choose "Add to path for all users"
 
[[File:CMake_3-2019.png|center]]
 
 
[[File:CMake_4-2025.png|center]]
 
===VisualStudio===
Download VisualStudio Community installer from [https://visualstudio.com/downloads/ visualstudio.com]
 
Run installer
 
[[File:install_vs2017_community_1.png|center]]
 
Make sure to install the C++ compiler
 
[[File:install_vs2017_community_2.png|600px|center]]
 
===Qt===
Download the open source installer from [https://www.qt.io/download www.qt.io]
 
Run installer
 
[[File:qt_installer_1.png|center]]
 
Click "Skip" when prompted for a Qt account
 
[[File:qt_installer_2.png|center]]
 
 
[[File:qt_installer_3.png|center]]
 
 
[[File:qt_installer_4.png|center]]
 
Choose a Qt version that is consistent with the version of VisualStudio you downloaded earlier
 
[[File:qt_installer_5.png|center]]
 
 
[[File:qt_installer_6.png|center]]
 
 
[[File:qt_installer_7.png|center]]
 
 
[[File:qt_installer_8.png|center]]
 
 
[[File:qt_installer_9.png|center]]
 
 
[[File:qt_installer_10.png|center]]
 
Uncheck "Launch Qt Creator" before clicking "Finish"
 
[[File:qt_installer_11.png|center]]
 
==Register with BCI2000 Project==
 
[[File:BCI2000_registration_1-1886.png|center]]
 
 
[[File:BCI2000_registration_2-2199.png|center]]
 
 
[[File:BCI2000_registration_3-2218.png|center]]
 
 
[[File:BCI2000_registration_4-2228.png|center]]
 
 
[[File:BCI2000_registration_6-2238.png|center]]
 
 
[[File:BCI2000_registration_7-2245.png|center]]
 
 
[[File:BCI2000_registration_9-2257.png|center]]
 
 
[[File:BCI2000_registration_10-2264.png|center]]
 
 
[[File:BCI2000_registration_11-2270.png|center]]
 
==Download the BCI2000 source code==
[[File:SVN_1-2294.png|center]]
 
 
[[File:SVN_2-2305.png|center]]
 
Enter user name and password as chosen in the registration step
 
[[File:SVN_3-2315.png|center]]
 
 
[[File:SVN_4-2326.png|center]]
 
 
[[File:SVN_5-2333.png|center]]
 
==Configure BCI2000 for compilation==
[[File:use_cmake_1.PNG|center]]
 
 
[[File:use_cmake_2.PNG|center]]
 
 
[[File:use_cmake_3.PNG|center]]
 
 
[[File:use_cmake_4.PNG|center]]
 
 
[[File:use_cmake_5.PNG|center]]
 
 
[[File:use_cmake_6.PNG|center]]
 
 
[[File:use_cmake_7.PNG|center]]
 
 
[[File:use_cmake_8.PNG|center]]
 
 
[[File:use_cmake_9.PNG|center]]
 
 
[[File:use_cmake_10.PNG|center]]
 
==Compile BCI2000==
[[File:use_vs2017_0.png|center]]
 
 
[[File:use_cmake_10.PNG|center]]
 
 
[[File:use_vs2017_1.png|center]]
 
 
[[File:use_vs2017_2.png|center]]
 
 
[[File:use_vs2017_3.png|center]]
 
 
[[File:use_vs2017_4.png|center]]
 
 
[[File:use_vs2017_5.png|center]]

Revision as of 13:33, 16 August 2018

This tutorial walks you through the process of obtaining the BCI2000 source distribution, and using it to build and test your own custom filters, implemented in C++ inside your own custom core module. It assumes that you have a good working knowledge of the C++ language, and basic familiarity with the compiler/IDE that you are going to use.

This tutorial is a simplified version of the previous Programming Howto:Quickstart Guide, which is slightly outdated but kept in the wiki as it contains valuable suggestions and exercises.

Howto steps

shows you how to install TortoiseSVN, CMake, VisualStudio, and Qt.
explains how to obtain a BCI2000 user account.
details the steps how to use TortoiseSVN to download the BCI2000 sourcecode.
demonstrates how to use CMake to create a BCI2000 solution file.
illustrates how to compile BCI2000 using VisualStudio.
shows how to create a new BCI2000 module from a template.
explains how to attach the VisualStudio debugger to a running module.
explains how to halt execution of a BCI2000 module, and wait for the user to attach a debugger.
demonstrates how to build a self-contained version of your new module.