Building BCI2000 with Visual Studio Code

This forum deals with BCI2000 configuration issues.
Post Reply
C_Coogan
Posts: 2
Joined: 06 Jul 2016, 17:45

Building BCI2000 with Visual Studio Code

Post by C_Coogan » 21 Jun 2019, 19:53

Here's an alternate method to build BCI2000. It's still using Visual Studio's build tools behind the scenes just with a lighter IDE.
  • Checkout source from SVN (known to work as of R5964)
  • Open project folder in Visual Studio Code
  • Install the following extensions: "CMake Tools", "CMake", and "C/C++"
  • Create a .vscode folder with a settings.json folder and add the following:
    settings.jpg
  • Open the command palette and select "CMake: Configure"
  • Select a kit (Known to work for 2017/2019 x86_amd64):
    selectKit.jpg
  • Edit generated CMakeCache.txt file to your liking:
    editCMakeCache.jpg
  • Select either Debug or Release (located at the bottom of the screen)
  • Run "CMake: Configure" again.
  • Run "CMake: Show CMake"
  • Find the module you wish to build, right-click, and select "Build"

C_Coogan
Posts: 2
Joined: 06 Jul 2016, 17:45

Re: Building BCI2000 with Visual Studio Code

Post by C_Coogan » 21 Jun 2019, 19:59

And in order to debug a module:
  • Switch to "CMake: Debug" located at the bottom of the screen
  • Start all other modules like normal.
  • Find the module you want to debug, right click and select "Run with debugger"
    BCI2000_debug.jpg
  • Add a breakpoint and when it is reached the VSCode/C++ debugger should open up:
    BCI2000_debugged.jpg

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest